My fellow friend is building site in flash and he uses XML files to access data in Flash.
I want to build editable CMS so that client can edit stuff.
Now I don't' have any experience with XML.
I know PHP, HTML and Mysql very well.
So how can I change those already build XML files using Mysql and PHP?
You probably should look at the PEAR XML Serializer Package. It makes it easy to convert a multi-dimensional array into XML.
Here's a decent tutorial: http://articles.sitepoint.com/article/xml-php-pear-xml_serializer
Output the XML using PHP in exactly the same way the example XML file does and then put this at the top of your code:
To create the XML file from the database just ouput the data the way you normally would adding XML tags in the right place. Eg:
If you need more assistance, provide the XML file that was given to you with the flash file as a reference.
Maybe going through
http://library.creativecow.net/articles/brimelow_lee/php_mysql/video-tutorial.php
will clear things for you.
Though, use it only to understand the concepts of XML and how it relates to mysql, php and swf. For real work look at libraries that deal with XML such as serializer mentioned in AvatarKava's answer.