milfone Posted October 13, 2011 Author Share Posted October 13, 2011 This is response of the form and It seems a correct XML: <?xml version="1.0" encoding="ISO-8859-1" ?> - <response> <stato>OK</stato> <messaggio>Inserimento utente effettuato correttamente.</messaggio> <id_cliente>131852990468021</id_cliente> </response> I'm right? Quote Link to comment Share on other sites More sharing options...
ManiacDan Posted October 13, 2011 Share Posted October 13, 2011 The first time you posted the response you posted invalid XML. Data cannot exist outside a tag, you had data outside the tag. The second time (just now) you posted nearly the exact same document and yet now the data is magically back INSIDE the tag. Which is which? What is happening? Why does your output keep changing format? Quote Link to comment Share on other sites More sharing options...
requinix Posted October 13, 2011 Share Posted October 13, 2011 The first time you posted the response you posted invalid XML. Data cannot exist outside a tag, you had data outside the tag. The second time (just now) you posted nearly the exact same document and yet now the data is magically back INSIDE the tag. Which is which? What is happening? Why does your output keep changing format? He typed it from memory. Or as an example. Or something like that. Yes milfone, that's valid. So no problems there. Quote Link to comment Share on other sites More sharing options...
milfone Posted October 13, 2011 Author Share Posted October 13, 2011 The first time you posted the response you posted invalid XML. Data cannot exist outside a tag, you had data outside the tag. The second time (just now) you posted nearly the exact same document and yet now the data is magically back INSIDE the tag. Which is which? What is happening? Why does your output keep changing format? The first time is just an example. So now I have to use curl or only SimpleXMLElement? Can you send me an example code to able to retrieve XML tag? I'm pretty much desperate I don't know what I do. Quote Link to comment Share on other sites More sharing options...
requinix Posted October 13, 2011 Share Posted October 13, 2011 Use both. Use cURL to send the right form data request and to retrieve the XML response, then use SimpleXML to parse the XML for the data you want. Quote Link to comment Share on other sites More sharing options...
milfone Posted October 13, 2011 Author Share Posted October 13, 2011 Use both. Use cURL to send the right form data request and to retrieve the XML response, then use SimpleXML to parse the XML for the data you want. I think will be hard to implement both function and I'm not a PHP guru, If somebody can help me I'll be glad to pay the time spent to implement the code. So now it is impossible to me learn how to parse an XML, Curl and other method. I have to start from the beginning with PHP book, and right now I haven't enough time. Quote Link to comment Share on other sites More sharing options...
ManiacDan Posted October 13, 2011 Share Posted October 13, 2011 Post to the Freelancing board with the amount you're willing to pay. This is a simple task, the reason we can't help you is because the content of your question kept changing and we never got access to the actual form. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.