This is a discussion on XML to php posting issue within the XML and SOAP forums, part of the Web Development category; Hi, Issue is when posting xml from one url to another url: While anybody posting xml with "&" ...
| |||||||
| Register | FAQ | Members List | Calendar | Mark Forums Read |
| |||
| Hi, Issue is when posting xml from one url to another url: While anybody posting xml with "&" in any attributes values we are not getting the full xml. i.e Xml attributes is lost after "&". Is there any solution in PHP to avoid this issue and get full xml. |
| Sponsored Links |
| |||
| Hi, we can solve this by using php configuration. By default the argument specifier is & , we can change to any character in php.ini file for the mentioned directive . arg_separator.input = ";&" |
| |||
| Hi Vivekanandan, Thanks for ur post. The idea is nice, but what is the probability if that new character wont come in XML. Then it would also cause a major problem. I think the function file_get_contents would be useful for this. Can any one explain about this function?? |
| |||
| Hi, fine, the probability is notes depends upon the application we are using, but when u use special character like these },{,|,. we will get low priority and make the application scalable. we have another good solution is file_get_contents('php://input') which works fine for the all suitation. Regards, vivekanandan. |
| |||
| Hi vivek Thanks. I checked and it works fine. But in some of the php pages we have given navigation links as below http://xxx.com/test.php?test=1&val=2 So when i use your logic then i need to find and replace in all pages.it will be tedious. Is there a way to change php.ini file for a particular page? |
| |||
| Hi Venkatesan, Yes, it is difficult for the Older application, but php provides dynamic php configuration using ini_set function which over rides the php configuration. we can use it any page as we need. Regards, Vivekanandan. |
| |||
| Vivek, This issue browser dependent or independent. If data having double quotes within tag then XML will generate or not? |
| |||
| Hi Vadivelan, Browser is just xml viewer. Every thing is depend on the XML and the usage of it. Note: we use attribute to mention common for all child tags in it, Here school name is rama krishna, when we metion double quoto inside value,it is meaning less as follows name="rama" krishna", how XML data <info> <school name="rama krishna"> <student> <name>vivek</name> <age>20</age> </student> <student> <name>velan</name> <age>21</age> </student> </school> </info> Regards, vivekanandan |
| |||
| Hi, This is tips for searching the xml content fastly by using Xpath mainly used in stype sheet. $oDomDoc = new DomDocument; $oDomDoc->loadXML($str); $xpath = new DOMXPath($oDomDoc); $xpath->preserveWhiteSpace = false; $result = $xpath->query("//Root/Element"); foreach($result as $node ) { print "<br>". $node -> getAttribute("Name"); } Regards, vivekanandan |
![]() |
| Thread Tools | |
| Display Modes | |
| |
LinkBacks (?)
LinkBack to this Thread: http://www.discussweb.com/xml-soap/2311-xml-php-posting-issue.html | |||
| Posted By | For | Type | Date |
| Programming | This thread | Refback | 07-20-2007 08:42 AM |
| Programming | This thread | Refback | 07-20-2007 05:39 AM |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Open Issue | vigneshgets | Software Testing | 2 | 01-24-2008 02:39 AM |
| Set focus issue | nssukumar | Flash Actionscript Programming | 1 | 10-26-2007 07:32 AM |
| NFS Performance issue | vivekanandan | Server Management | 0 | 09-20-2007 06:39 AM |
| Issue in Layout | Anandavinayagam | HTML, CSS and Javascript Coding Techniques | 1 | 08-10-2007 10:47 PM |
| Issue Matrix | shanmugamit | Software Testing | 0 | 05-24-2007 10:22 AM |