alohaaaron
Programmer
Hi, I don't have access to curl or open xml.
I'm trying to put data into a database. In the fragment of code below it prints out the xml file correctly. Here is the XML File.
$xml_data = "<?xml version=\"1.0\"?><member><Email>abc@home.com me</Email></member>";
How would I insert the email address into a database when I don't know what the variable is called that outputs the data? Even though the email address abc@home.com is printed out correctly as Email: abc@home.com I don't see how to capture that variable and put it into a database? It's not $element_name since that's the field name and it's not an attribute. Where is the output coming from?
//Function to use at the start of an element
function start($parser,$element_name,$element_attrs)
{
switch($element_name)
{
case "EMAIL":
echo "Email: "; break;
}
}
I'm trying to put data into a database. In the fragment of code below it prints out the xml file correctly. Here is the XML File.
$xml_data = "<?xml version=\"1.0\"?><member><Email>abc@home.com me</Email></member>";
How would I insert the email address into a database when I don't know what the variable is called that outputs the data? Even though the email address abc@home.com is printed out correctly as Email: abc@home.com I don't see how to capture that variable and put it into a database? It's not $element_name since that's the field name and it's not an attribute. Where is the output coming from?
//Function to use at the start of an element
function start($parser,$element_name,$element_attrs)
{
switch($element_name)
{
case "EMAIL":
echo "Email: "; break;
}
}