Re: [WebDNA] how can i grab the contents of a post?

This WebDNA talk-list message is from

2011


It keeps the original formatting.
numero = 106777
interpreted = N
texte = Sorry to be late to the party on this response. A LONG time ago I had to = write an interface to talk to Ariba (a "Spend Management System"*) that = involved sending and receiving xml files via http requests.=20 Going thru my code i found we used [text]xmlRequest=3D[::params_string][/text] I don't remember the exact circumstances, but I'm about to be forced to.=20= For the project i'm working on this week I have to integrate to a new = payment processor that insists on using data mangled thru self written = encryption algorithm, and then squirted thru a SOAP interface. ("Just = use our PHP code." "no.") Brian. *If this phrase means nothing or just adds confusion to your brain, you = now understand they value they bring to standing in the middle of = corporate purchasers and vendors. On Jun 13, 2011, at 12:36 PM, Aaron Michael Kaczmarek wrote: > Windows server 2003 / iis 6 >=20 > On 6/13/11 12:09 PM, Olin Lagon wrote: >> Am running 6 on Linux. What platform are you using to get what you = have? That would make it possible to piece back the XML. >>=20 >> Am using an API from The Energy Detective (not published on their = site) which is a real time energy monitor. >>=20 >> Aaron Michael Kaczmarek wrote: >>> Could this potentially be a matter of webDNA version? =20 >>>=20 >>> I'm running 6 and am able to receive xml callbacks to a dna page = just fine; getting xml contents with formvariables. =20 >>>=20 >>> With formvariables, I get a single variable that is broken at the = first "=3D", so formvars returns this: >>> [name] =3D >> [value] =3D "1.0" encoding=3D"UTF-8"?>......and so on with the rest = of xml >>>=20 >>>=20 >>> what API are you working with by the way? >>>=20 >>> On 6/13/11 11:32 AM, Olin Lagon wrote: >>>> I had already written and tested the XML logic in webdna so to save = time I just wrote the following lines of PHP that grabbed the post = contents, assigned it to a form variable, and redirected it to a webdna = script for processing. The parse.tpl returns XML and this PHP script = sends it back to the requestor with the correct HTTP header. >>>>=20 >>>> >>> if ( $_SERVER['REQUEST_METHOD'] =3D=3D=3D 'POST' ){=20 >>>> $postText =3D file_get_contents('php://input');=20 >>>> } >>>> $content =3D = file_get_contents("http://www.kanuhawaii.org/ted/parse.tpl?thisxml=3D".url= encode($postText));=20 >>>> header("Content-type: text/xml"); >>>> echo $content; >>>> ?> >>>>=20 >>>> This could probably be collapsed to two lines but what I have above = works and it is good enough :) >>>>=20 >>>> >>> header("Content-type: text/xml"); >>>> echo = file_get_contents("http://yourserver/parse.tpl?thisxml=3D".urlencode(file_= get_contents('php://input')));=20 >>>> ?> >>>> =20 >>>>=20 >>>> Psi Prime Inc, Matthew A Perosi wrote: >>>>> Since I'm completely ignorant when it comes to PHP, what is the = code you used? =20 >>>>> Did you grab the incoming content, save it as a file then had = WebDNA trigger occasionally for the written file? >>>>>=20 >>>>> Matt Associated Messages, from the most recent to the oldest:

    
  1. Re: [WebDNA] how can i grab the contents of a post? ("Brian B. Burton" 2011)
  2. Re: [WebDNA] how can i grab the contents of a post? (Aaron Michael Kaczmarek 2011)
  3. Re: [WebDNA] how can i grab the contents of a post? (Olin Lagon 2011)
  4. Re: [WebDNA] how can i grab the contents of a post? (Aaron Michael Kaczmarek 2011)
  5. Re: [WebDNA] how can i grab the contents of a post? (Olin Lagon 2011)
  6. Re: [WebDNA] how can i grab the contents of a post? ("Psi Prime Inc, Matthew A Perosi " 2011)
  7. Re: [WebDNA] how can i grab the contents of a post? (Olin Lagon 2011)
  8. Re: [WebDNA] how can i grab the contents of a post? ("Psi Prime Inc, Matthew A Perosi " 2011)
  9. Re: [WebDNA] how can i grab the contents of a post? (Olin Lagon 2011)
  10. Re: [WebDNA] how can i grab the contents of a post? (Stuart Tremain 2011)
  11. Re: [WebDNA] how can i grab the contents of a post? (Olin Lagon 2011)
  12. Re: [WebDNA] how can i grab the contents of a post? (Stuart Tremain 2011)
  13. Re: [WebDNA] how can i grab the contents of a post? (Olin Lagon 2011)
  14. Re: [WebDNA] how can i grab the contents of a post? (Stuart Tremain 2011)
  15. Re: [WebDNA] how can i grab the contents of a post? (Olin Lagon 2011)
  16. Re: [WebDNA] how can i grab the contents of a post? (Stuart Tremain 2011)
  17. [WebDNA] how can i grab the contents of a post? (Olin Lagon 2011)
Sorry to be late to the party on this response. A LONG time ago I had to = write an interface to talk to Ariba (a "Spend Management System"*) that = involved sending and receiving xml files via http requests.=20 Going thru my code i found we used [text]xmlRequest=3D[::params_string][/text] I don't remember the exact circumstances, but I'm about to be forced to.=20= For the project i'm working on this week I have to integrate to a new = payment processor that insists on using data mangled thru self written = encryption algorithm, and then squirted thru a SOAP interface. ("Just = use our PHP code." "no.") Brian. *If this phrase means nothing or just adds confusion to your brain, you = now understand they value they bring to standing in the middle of = corporate purchasers and vendors. On Jun 13, 2011, at 12:36 PM, Aaron Michael Kaczmarek wrote: > Windows server 2003 / iis 6 >=20 > On 6/13/11 12:09 PM, Olin Lagon wrote: >> Am running 6 on Linux. What platform are you using to get what you = have? That would make it possible to piece back the XML. >>=20 >> Am using an API from The Energy Detective (not published on their = site) which is a real time energy monitor. >>=20 >> Aaron Michael Kaczmarek wrote: >>> Could this potentially be a matter of webDNA version? =20 >>>=20 >>> I'm running 6 and am able to receive xml callbacks to a dna page = just fine; getting xml contents with formvariables. =20 >>>=20 >>> With formvariables, I get a single variable that is broken at the = first "=3D", so formvars returns this: >>> [name] =3D >> [value] =3D "1.0" encoding=3D"UTF-8"?>......and so on with the rest = of xml >>>=20 >>>=20 >>> what API are you working with by the way? >>>=20 >>> On 6/13/11 11:32 AM, Olin Lagon wrote: >>>> I had already written and tested the XML logic in webdna so to save = time I just wrote the following lines of PHP that grabbed the post = contents, assigned it to a form variable, and redirected it to a webdna = script for processing. The parse.tpl returns XML and this PHP script = sends it back to the requestor with the correct HTTP header. >>>>=20 >>>> >>> if ( $_SERVER['REQUEST_METHOD'] =3D=3D=3D 'POST' ){=20 >>>> $postText =3D file_get_contents('php://input');=20 >>>> } >>>> $content =3D = file_get_contents("http://www.kanuhawaii.org/ted/parse.tpl?thisxml=3D".url= encode($postText));=20 >>>> header("Content-type: text/xml"); >>>> echo $content; >>>> ?> >>>>=20 >>>> This could probably be collapsed to two lines but what I have above = works and it is good enough :) >>>>=20 >>>> >>> header("Content-type: text/xml"); >>>> echo = file_get_contents("http://yourserver/parse.tpl?thisxml=3D".urlencode(file_= get_contents('php://input')));=20 >>>> ?> >>>> =20 >>>>=20 >>>> Psi Prime Inc, Matthew A Perosi wrote: >>>>> Since I'm completely ignorant when it comes to PHP, what is the = code you used? =20 >>>>> Did you grab the incoming content, save it as a file then had = WebDNA trigger occasionally for the written file? >>>>>=20 >>>>> Matt "Brian B. Burton"

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:

Help! Odd, irreproducible happenings. (1998) Setting up shop (1997) [WebDNA] Encryptng a password (2016) Details of shipping - Totalqty calculations (1997) Server Freeze (1998) Emailer pref's won't save (2005) Authenticate (1997) Handy Browser Counter Tip (1997) WebCat for Unix?? (1997) WebDNA for Dummies (2004) This list needs a digest: rant, rave... (1997) Email within tmpl ? (1997) Re:Searching for ALL / empty form field (1997) Nesting [RAW] (1998) taxRate is fine but taxTotal isn't (1997) [OT] JS snippet needed (2006) Test (2003) RAM variables (1997) Grep Question (2003) Grant, please help me ... (1997)