•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the XML, XSLT and XPATH section within the Software Development category of DaniWeb, a massive community of 455,970 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,773 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our XML, XSLT and XPATH advertiser: Programming Forums
Views: 1033 | Replies: 2
![]() |
•
•
Join Date: Nov 2007
Posts: 2
Reputation:
Rep Power: 0
Solved Threads: 0
Hello all,
i want to get soap message with xpath
my code is:
so if i want to get "return" result, then i use Xpath code:
then i get exactelly what i want , but the problem what i have if i want for example to connect : "<ns1:initialize_sessionResponse> " then it doesn't fuction
i try with the following codes but no result:
xpath:xml/dynaments/Envelope/Body/initialize_sessionResponse/return/text()
or
xpath:xml/dynaments/SOAP-ENV:Envelope/SOAP-ENV:Body/ns1:initialize_sessionResponse/return/text()
thanks for your help
i want to get soap message with xpath
my code is:
<?xml version="1.0" encoding="UTF-8" ?> <!DOCTYPE xml (View Source for full doctype...)> <xml rde-rd:content="spreadshirt2.xml" rde-rd:datalanguage="de" rde-rd:leasingtime="0" rde-rd:locale="de" rde-rd:project="testwebservicegoogle" rde-rd:rdeContentType="0" xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:rde-dm="http://www.reddot.de/rde/ns/dm" xmlns:rde-fdl="http://www.reddot.de/rde/ns/fdl" xmlns:rde-idea="http://www.reddot.de/rde/ns/idea" xmlns:rde-rd="http://www.reddot.de/2000/rde/rd" xmlns:rde-rdf="http://www.reddot.de/rde/ns/rdf" xmlns:rde-xmaps="http://www.reddot.de/rde/ns/xmaps" xmlns:rdf="http://www.w3.org/TR/REC-rdf-syntax/" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xsl-template="http://www.reddot.de/rde/ns/template"> <dynaments> <SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="http://www.spreadshirt.net//services.php/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <SOAP-ENV:Body> <ns1:initialize_sessionResponse> <return xsi:type="xsd:string">5999f4388c2ced3b67ffacb0ed660fb7</return> </ns1:initialize_sessionResponse> </SOAP-ENV:Body> </SOAP-ENV:Envelope> </dynaments> ...
xpath:xml/dynaments/*/*/*/return/text()
i try with the following codes but no result:
xpath:xml/dynaments/Envelope/Body/initialize_sessionResponse/return/text()
or
xpath:xml/dynaments/SOAP-ENV:Envelope/SOAP-ENV:Body/ns1:initialize_sessionResponse/return/text()
thanks for your help
•
•
Join Date: Nov 2007
Posts: 1
Reputation:
Rep Power: 0
Solved Threads: 0
Your problem seems to be namespace related. I'm not sure what XPath processor you're using, but try the following:
/xml/dynaments/SOAP-ENV:Envelope/node()[local-name() = 'Body']/node()[local-name() = 'initialize_sessionResponse']/return
Phil Fearon
http://www.sketchpath.com
/xml/dynaments/SOAP-ENV:Envelope/node()[local-name() = 'Body']/node()[local-name() = 'initialize_sessionResponse']/return
Phil Fearon
http://www.sketchpath.com
![]() |
•
•
•
•
•
•
•
•
DaniWeb XML, XSLT and XPATH Marketplace
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
- Previous Thread: adding namespaces to XmlSerializer when deserializing (C#)
- Next Thread: XML in ASP


Linear Mode