php question please!

Soldato
Joined
16 Oct 2007
Posts
7,480
Location
UK
Hello all,

I am well and truly baffled and hoping you might be able to help.


basically - i have a PHP script that does some database lookups, and outputs it as text.

I have a flash file, that displays information - but only from "config.xml"

So, i've been trying to think of a way of getting the information from the PHP file, into the config.xml.


Any ideas?
I can format the PHP output so it looks exactly like the XML file - but how do i actually get this information inside the xml file? Or the PHP script to create it?

It's dynamically changing information....

Any help would be greatly appreciated, thank you!
 
That's exactly what you need to do, just have the php output the XML format, with your dynamic content in it.

Edit: have a little look at this thread on outputting xml content using php, you should get the idea...
 
Ideal, thank you! I'll try and get my head round this, but seems to be exactly what i'm after.
 
Ok, severe headache!

How will it dynamically change? I'm presuming the XML file only gets created/updated when the PHP script is run? So if i'm showing data from the xml file, the php script has to be run seperately? Via Cron?

Apologies for my seemingly stupid quesitons - but thank you for your help so far Chris!
 
The php code in the previous link generates XML from sql call, each time the user refreshes your flash content the 'flash' will call the xml/php script. Thus the content will be dynamic as it is a fresh sql call generating the xml file that flash is looking for.
No need to mess with crons :)

edit: not sure on flash, butto give you the idea:
change your include('config.xml') to include('config.php')
 
Back
Top Bottom