Wrox Programmer Forums
|
ASP E-commerce As of Oct 5, 2005, this forum is now locked. No posts have been deleted. Please use "Classic ASP Professional" at: http://p2p.wrox.com/forum.asp?FORUM_ID=56 for discussions similar to the old ASP Pro Code Clinic or one of the other many remaining ASP and ASP.NET forums here.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP E-commerce section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old January 25th, 2005, 07:05 PM
Friend of Wrox
 
Join Date: Oct 2004
Posts: 198
Thanks: 2
Thanked 0 Times in 0 Posts
Send a message via MSN to itHighway
Default Using ASP read xml string

I'm working on a shipping charges calculator gateway. The response string send by the gateway is in xml format.

<?xml version="1.0"?><version>2.0.0.0</version><shipmentID>88889</shipmentID><origination><name>Zeeshan Ahmed</name><weight unit="LB">3.0</weight><dimensions unit="IN"><length>1.0</length>


How can I read different nodes of xml string using ASP. Like suppose if I want to read "WEIGHT" from xml string. How can I read it?


Any Idea..
Any Help....

Will be appciated.


Thanks
Zeeshan Ahmed

 
Old January 25th, 2005, 07:33 PM
Friend of Wrox
 
Join Date: May 2004
Posts: 642
Thanks: 0
Thanked 43 Times in 42 Posts
Default

Please check the following URL:

http://www.w3schools.com/dom/dom_access.asp

Om Prakash
 
Old January 25th, 2005, 08:36 PM
Friend of Wrox
 
Join Date: Oct 2004
Posts: 198
Thanks: 2
Thanked 0 Times in 0 Posts
Send a message via MSN to itHighway
Default

The shipping system process all the data and then store the complete result into a variable "xmlString" and then send it to me.

So, I actually need to fetch the "WEIGHT" from "xmlString" variable and xmlString variable contains
<?xml version="1.0"?><version>2.0.0.0</version><shipmentID>88889</shipmentID><origination><name>Zeeshan Ahmed</name><weight unit="LB">3.0</weight><dimensions unit="IN"><length>1.0</length>

 
Old February 1st, 2005, 03:14 AM
Authorized User
 
Join Date: Dec 2004
Posts: 12
Thanks: 0
Thanked 0 Times in 0 Posts
Default

hi,
 try with getxmlbytagname() method to get the value of weight.






Similar Threads
Thread Thread Starter Forum Replies Last Post
DTS Package, XML task. Read XML file and store it Victoria SQL Server DTS 0 July 24th, 2006 02:43 PM
xml Files read in asp with formated data shaileshk Classic ASP XML 1 June 7th, 2006 04:53 AM
XSLT read through XML to transform another XML dendenx2 XSLT 8 July 7th, 2005 08:18 PM
I Need to Read an Xml from String anand_asv XML 3 March 18th, 2005 12:04 AM
Reading XML string using asp itHighway Classic ASP XML 2 March 10th, 2005 11:54 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.