Click to See Complete Forum and Search --> : Help with xml import


mc124
06-13-2009, 04:13 AM
Hi, I am a bit of a newbie so please forgive my ignorance but I have a website that imports other peoples data using xml. I need to import a feed that isnt exactly to my spec.
For example
my spec says
<colour>red</colour> and the feed I need to import says

<background>red</background>
I currently have a php script that parses the xml file with the following
if( $xml_current_tag_state == "COLOUR" ) {
$property_data[$property_counter]["colour"] = $property_data[$property_counter]["colour"].$data;
}

How can I get it to import the background field as colour?
Thank you for your help