# Generate XML by data from MySQL

**URL:** <https://forum.kirupa.com/t/generate-xml-by-data-from-mysql/70816>\
**Category:** programming\
**Created:** [November 17, 2004, 8:06pm UTC](https://forum.kirupa.com/t/generate-xml-by-data-from-mysql/70816 "2004-11-17T20:06:44Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Konijn](https://avatars.discourse-cdn.com/v4/letter/k/ea666f/32.png) [@Konijn](https://forum.kirupa.com/u/Konijn)\
**Post date:** [November 17, 2004, 8:06pm UTC](https://forum.kirupa.com/t/generate-xml-by-data-from-mysql/70816/1 "2004-11-17T20:06:44Z")

</div>

Hey,

I searched, but I couldn’t find anything.  
I have data in my MysQL database, and I want that php creats an xml file with it.  
And the xml file need to look like this:

```php
&lt;?xml version="1.0"?&gt;
	&lt;myMenu&gt;

			&lt;myItem doubleBurner="no" outlet1="90mm" outlet2="Regular Vent" file="images/A36.jpg" moreInfo="no" name="A36" lenght="650mm" depth="200mm" capacityM3="40-70" operatingInstructions="download" woodPebbles="-" electronicControl="no" flameVisible="yes" outputW="4100" floorCentreOutlet="320mm" gasaansluiting="3/8&quot; " height="610mm"/&gt;
	&lt;/myMenu&gt;
```
