﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>FusionCharts Forum / FusionCharts v3 / Using FusionCharts / XML Issue  / &amp;dataURL=headcount.xml works why not &amp;dataURL=headcount.php? / Latest Posts</title><generator>InstantForum.NET v4.1.4</generator><description>FusionCharts Forum</description><link>http://www.fusioncharts.com/forum/</link><webMaster>support@fusioncharts.com</webMaster><lastBuildDate>Wed, 03 Dec 2008 02:44:01 GMT</lastBuildDate><ttl>20</ttl><item><title>RE: &amp;dataURL=headcount.xml works why not &amp;dataURL=headcount.php?</title><link>http://www.fusioncharts.com/forum/Topic2268-29-1.aspx</link><description>Stumbled upon the answer myself....&lt;/P&gt;&lt;P&gt;First, you want to inlcude header('Content-type: text/xml'); so you can directly view the xml data in a browser.  This showed me I was missing the top level element.  So I changed headcount.php to this and it works:&lt;/P&gt;&lt;FONT size=2&gt;&lt;P&gt;&amp;lt;?php&lt;/P&gt;&lt;P&gt;echo "&amp;lt;chart caption='Monthly Headcount'&amp;gt;";&lt;/P&gt;&lt;P&gt;echo "&amp;lt;set label='20070101' value='97'/&amp;gt;";&lt;/P&gt;&lt;P&gt;echo "&amp;lt;set label='20070201' value='96'/&amp;gt;";&lt;/P&gt;&lt;P&gt;echo "&amp;lt;set label='20070301' value='103'/&amp;gt;";&lt;/P&gt;&lt;P&gt;echo "&amp;lt;set label='20070401' value='108'/&amp;gt;";&lt;/P&gt;&lt;P&gt;echo "&amp;lt;set label='20070501' value='110'/&amp;gt;";&lt;/P&gt;&lt;P&gt;echo "&amp;lt;set label='20070601' value='115'/&amp;gt;";&lt;/P&gt;&lt;P&gt;echo "&amp;lt;set label='20070701' value='117'/&amp;gt;";&lt;/P&gt;&lt;P&gt;echo "&amp;lt;set label='20070801' value='123'/&amp;gt;";&lt;/P&gt;&lt;P&gt;echo "&amp;lt;set label='20070901' value='122'/&amp;gt;";&lt;/P&gt;&lt;P&gt;echo "&amp;lt;/chart&amp;gt;";&lt;/P&gt;&lt;P&gt;?&amp;gt;&lt;/P&gt;&lt;/FONT&gt;</description><pubDate>Fri, 07 Sep 2007 12:38:47 GMT</pubDate><dc:creator>ac</dc:creator></item><item><title>&amp;dataURL=headcount.xml works why not &amp;dataURL=headcount.php?</title><link>http://www.fusioncharts.com/forum/Topic2268-29-1.aspx</link><description>Why can't I do this:&lt;/P&gt;&lt;P&gt;.... &amp;lt;chart stuff&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;amp;dataURL=headcount.php&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Where, headcount.php is simply a bunch of php statements that return xml data:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;lt;?php&lt;BR&gt;echo "&amp;lt;chart caption='Monthly Headcount' &amp;gt;";&lt;BR&gt;echo "&amp;lt;set label='20070701' value='117'/&amp;gt;";&lt;BR&gt;echo "&amp;lt;set label='20070801' value='123'/&amp;gt;";&lt;BR&gt;echo "&amp;lt;set label='20070901' value='122'/&amp;gt;";&lt;BR&gt;echo "&amp;lt;/chart&amp;gt;";&lt;BR&gt;?&amp;gt;&lt;BR&gt;&lt;/P&gt;&lt;/STRONG&gt;&lt;P&gt;If I put this xml data into a file called 'headcount.xml' and change chart to use &amp;amp;dataURL=headcount.xml it works just fine. But I want the xml data to be generated dynamically.  Am I missing something here? I need a clue.</description><pubDate>Thu, 06 Sep 2007 19:34:18 GMT</pubDate><dc:creator>ac</dc:creator></item></channel></rss>