Regarding the xml

Dear jabba ,
I am raghavendra. I read your tutorial it was very easy to follow up and I need more information like i want to read the data from mysql and output in xml in this format [COLOR=#0000ff]<?xml version=“1.0” encoding=“utf-8” ?>[/COLOR]
[[FONT=Courier New][COLOR=#ff0000]-[/COLOR][/FONT]](file:///C:/Documents%20and%20Settings/ALIENWARE/My%20Documents/Flex%20Builder%203/Dashboard/src/data/revenue_by_region.xml#) [COLOR=#0000ff]<[/COLOR][COLOR=#990000]items[/COLOR][COLOR=#0000ff]>[/COLOR]
[COLOR=#0000ff]<[/COLOR][COLOR=#990000]item[/COLOR] [COLOR=#990000]region[/COLOR][COLOR=#0000ff]="[/COLOR]North America[COLOR=#0000ff]"[/COLOR][COLOR=#990000] value[/COLOR][COLOR=#0000ff]="[/COLOR]148[COLOR=#0000ff]" />[/COLOR]

[COLOR=#0000ff]<[/COLOR][COLOR=#990000]item[/COLOR] [COLOR=#990000]region[/COLOR][COLOR=#0000ff]="[/COLOR]South America[COLOR=#0000ff]"[/COLOR][COLOR=#990000] value[/COLOR][COLOR=#0000ff]="[/COLOR]75[COLOR=#0000ff]" />[/COLOR]

[COLOR=#0000ff]<[/COLOR][COLOR=#990000]item[/COLOR] [COLOR=#990000]region[/COLOR][COLOR=#0000ff]="[/COLOR]EMEA[COLOR=#0000ff]"[/COLOR][COLOR=#990000] value[/COLOR][COLOR=#0000ff]="[/COLOR]115[COLOR=#0000ff]" />[/COLOR]

[COLOR=#0000ff]<[/COLOR][COLOR=#990000]item[/COLOR] [COLOR=#990000]region[/COLOR][COLOR=#0000ff]="[/COLOR]APAC[COLOR=#0000ff]"[/COLOR][COLOR=#990000] value[/COLOR][COLOR=#0000ff]="[/COLOR]85[COLOR=#0000ff]" />[/COLOR]

[COLOR=#0000ff]</[/COLOR][COLOR=#990000]items[/COLOR][COLOR=#0000ff]> could you able to help me out please You can mail me to my [email protected] or [email protected] I will be waiting for your reply[/COLOR]

Easiest way imo to do this is to have a php file echo a xml header and the xml data with values coming from a mysql connection.

could you please give me some sample or explain with example…

please yar i am in urgent and trouble…

Thanking you

Raghavendra

HI,

Please help me why there is no response

HI,

Please help me why there is no response

Hi

Friends, i have same example with me that brings the mysql data to xml outputing could any one tell me how to do this …

^ I’ll post an example in an hour or two, but don’t keep posting same thing again.


<?php
header('Content-type: text/xml');
?>
<?xml version="1.0" encoding="utf-8" ?>
    <items>
<?php
/* Add your MySQL Connection here [mysql_connect(etc, etc, etc)] */
$result = mysql_query('SELECT region, id FROM tbl_places');
while ($row = mysql_fetch_assoc($result)) {
        echo '<item region="'.$row['region'].'" value="'.$row['id'].'" /> ';
}
?>
    </items>

Hope that helps