Re: Fwd: XML - USPS Lookups - UPS Lookups
This WebDNA talk-list message is from 2003
It keeps the original formatting.
numero = 52004
interpreted = N
texte = Hi Velma,Here is the code that I am using to access UPS. I had some good help from Alain Russell (if I remember correctly) to sort some of it out. I was kind of at the same stage as you at the time! This requests UPS Ground, UPS Second Day Air and UPS Next Day Air rates for the package to e sent. It is sort of a pita to get the data back out of their return xml do to the worthlessness of the [middle] context. (Anyone find the way this things works useful? Sorry, Pet peeve of the day)Don't forget that none of this works until you sign up with UPS, set a username and password and get assigned an AccessLicenseNumber.Hope this helps,Larry Goodhew[text]crlf=[unurl]%0D%0A[/unurl][/text][text]the_Variables=[!][/!]
[!][/!]XXXXXXXXXXXXXXXXXX[!] [/!]XXXXXXXX[!][/!]XXXXXXXXX[!][/!][!][/!][!][/!]
[!][/!][!][/!][!] [/!]Rating and Service[!][/!]1.0001[!] [/!][!][/!]Rate[!][/!]shop[!] [/!][!][/!][!][/!]01
[!][/!][!] [/!][!][/!][!][/!][!][/!][Zip][!][/!][CountryCode][!][/!][!][/!][!][/!][!][/!][!][/!][ShippingZip][!][/!][ShippingCountryCode][!][/!][!][/!][!][/!][!][/!][!][/!]11
[!][/!][!][/!][!][/!][!][/!]02
[!][/!]Package[!][/!][!][/!]Rate Shopping[!][/!][!][/!][Ship_Weight][!][/!]LBS[!][/!][!][/!][!][/!][!][/!][!][/!][/text][text]UPS_Return=[TCPConnect host=www.ups.com&port=443&ssl=T][TCPSend]POST /ups.app/xml/Rate HTTP/1.0[crlf][!][/!]Referer: http:/[thisURL][crlf][!][/!]Host: wwwcie.ups.com[crlf][!][/!]Content-Type: application/x-www-form-urlencoded[crlf][!][/!]Content-length: [countchars][the_Variables][/countchars][crlf][!][/!][crlf][!][/!][the_Variables][crlf][!][/!][/TCPSend][/TCPConnect][/text]> > Anybody have an idea of how one submits an XML request via TCPConnect, to > save me hours or days of blathering around trying to figure out where to > get started?> > :-) Velma> > >Date: Mon, 28 Jul 2003 16:41:47 -0400> >To: WebDNA-Talk@talk.smithmicro.com> >From: Velma Kahn
> >Subject: XML - USPS Lookups - UPS Lookups> >> >I want to implement real time UPS & USPS lookups for some of my sites.> >> >I searched the talk-list archive, and couldn't make much out of what was > >there.> >> >I think I can follow both the UPS and USPS documentation, although if > >anyone would care to share a working example, that would be great. I can > >both build the XML request in code and parse the response in code, > >although maybe I'll venture into those new XML tools in WebDNA 5.1? (Is > >there any good documentation on those new features?)> >> >But what I really don't seem to know is how I'm submitting the XML > >request. Can I submit an XML request via TCPConnect? If so, a piece of > >sample code that shows what that TCPConnect and TCPSend might look like > >would be a great help. (And if not TCPConnect, how?)> >> >Thank you.> >> >Velma> >> >----------------------------------------> >Velma Kahn> >Glory Day Software Company> >200 Tanager Ln NW, Floyd, Virginia 24091, U.S.A.> >phone: 540-745-6469 * fax: 651-321-4884> >email: vkahn@glorydaysoftware.com> >http://www.glorydaysoftware.com> >http://www.communitymade.com> >http://www.floydcrafts.com> > ----------------------------------------> Velma Kahn> Glory Day Software Company> 200 Tanager Ln NW, Floyd, Virginia 24091, U.S.A.> phone: 540-745-6469 * fax: 651-321-4884> email: vkahn@glorydaysoftware.com> http://www.glorydaysoftware.com> http://www.communitymade.com> http://www.floydcrafts.com > > > -------------------------------------------------------------> This message is sent to you because you are subscribed to> the mailing list .> To unsubscribe, E-mail to: > To switch to the DIGEST mode, E-mail to > Web Archive of this list is at: http://webdna.smithmicro.com/> -------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/
Associated Messages, from the most recent to the oldest:
Hi Velma,Here is the code that I am using to access UPS. I had some good help from Alain Russell (if I remember correctly) to sort some of it out. I was kind of at the same stage as you at the time! This requests UPS Ground, UPS Second Day Air and UPS Next Day Air rates for the package to e sent. It is sort of a pita to get the data back out of their return xml do to the worthlessness of the [middle] context. (Anyone find the way this things works useful? Sorry, Pet peeve of the day)Don't forget that none of this works until you sign up with UPS, set a username and password and get assigned an AccessLicenseNumber.Hope this helps,Larry Goodhew[text]crlf=[unurl]%0D%0A[/unurl][/text][text]the_Variables=[!][/!][!][/!]XXXXXXXXXXXXXXXXXX[!] [/!]XXXXXXXX[!][/!]XXXXXXXXX[!][/!][!][/!][!][/!][!][/!][!][/!][!] [/!]Rating and Service[!][/!]1.0001[!] [/!][!][/!]Rate[!][/!]shop[!] [/!][!][/!][!][/!]01
[!][/!][!] [/!][!][/!][!][/!][!][/!][Zip][!][/!][CountryCode][!][/!][!][/!][!][/!][!][/!][!][/!][ShippingZip][!][/!][ShippingCountryCode][!][/!][!][/!][!][/!][!][/!][!][/!]11
[!][/!][!][/!][!][/!][!][/!]02
[!][/!]Package[!][/!][!][/!]Rate Shopping[!][/!][!][/!][Ship_Weight][!][/!]LBS[!][/!][!][/!][!][/!][!][/!][!][/!][/text][text]UPS_Return=[TCPConnect host=www.ups.com&port=443&ssl=T][tcpsend]POST /ups.app/xml/Rate HTTP/1.0[crlf][!][/!]Referer: http:/[thisurl][crlf][!][/!]Host: wwwcie.ups.com[crlf][!][/!]Content-Type: application/x-www-form-urlencoded[crlf][!][/!]Content-length: [countchars][the_Variables][/countchars][crlf][!][/!][crlf][!][/!][the_Variables][crlf][!][/!][/TCPSend][/TCPConnect][/text]> > Anybody have an idea of how one submits an XML request via TCPConnect, to > save me hours or days of blathering around trying to figure out where to > get started?> > :-) Velma> > >Date: Mon, 28 Jul 2003 16:41:47 -0400> >To: WebDNA-Talk@talk.smithmicro.com> >From: Velma Kahn > >Subject: XML - USPS Lookups - UPS Lookups> >> >I want to implement real time UPS & USPS lookups for some of my sites.> >> >I searched the talk-list archive, and couldn't make much out of what was > >there.> >> >I think I can follow both the UPS and USPS documentation, although if > >anyone would care to share a working example, that would be great. I can > >both build the XML request in code and parse the response in code, > >although maybe I'll venture into those new XML tools in WebDNA 5.1? (Is > >there any good documentation on those new features?)> >> >But what I really don't seem to know is how I'm submitting the XML > >request. Can I submit an XML request via TCPConnect? If so, a piece of > >sample code that shows what that TCPConnect and TCPSend might look like > >would be a great help. (And if not TCPConnect, how?)> >> >Thank you.> >> >Velma> >> >----------------------------------------> >Velma Kahn> >Glory Day Software Company> >200 Tanager Ln NW, Floyd, Virginia 24091, U.S.A.> >phone: 540-745-6469 * fax: 651-321-4884> >email: vkahn@glorydaysoftware.com> >http://www.glorydaysoftware.com> >http://www.communitymade.com> >http://www.floydcrafts.com> > ----------------------------------------> Velma Kahn> Glory Day Software Company> 200 Tanager Ln NW, Floyd, Virginia 24091, U.S.A.> phone: 540-745-6469 * fax: 651-321-4884> email: vkahn@glorydaysoftware.com> http://www.glorydaysoftware.com> http://www.communitymade.com> http://www.floydcrafts.com > > > -------------------------------------------------------------> This message is sent to you because you are subscribed to> the mailing list .> To unsubscribe, E-mail to: > To switch to the DIGEST mode, E-mail to > Web Archive of this list is at: http://webdna.smithmicro.com/> -------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/
"Larry Goodhew"
DOWNLOAD WEBDNA NOW!
Top Articles:
Talk List
The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...
Related Readings:
Still having math problems (1997)
emailer w/F2 (1997)
Multiple Pulldowns (1997)
question... no field names? (2002)
Need help with emailer- 2 issues (1997)
[createfolder] & [deletefolder] (1997)
Wierd problem with 3.08 WIN Version (2000)
RE: PIXO support (1997)
WebCat and image maps (1997)
Catalog Design (1999)
HTML encoding in URLs (1997)
Multiple SSL Keys (1998)
Custom WebCat Prefs ... (1997)
Unexceling (was I need a smart quote...) (1999)
How to put the Trademark Symbol (%99) in Sendmail? (2003)
Occasional crashes with $remove (1997)
formatting dates from a field ... (1997)
[OT] Read and weep (2003)
Reversing [ipaddress] normalization (1998)
[TaxableTotal] - not working with AOL and IE (1997)