Re: XML or rest services

2017-03-29 Thread Tom DeMeo via 4D_Tech
Chuck, 4D Tags will help you compose, but they won’t help you parse. If you get an response from a request, whether XML or JSON, you will start with text. If you use XML, see the XML DOM commands. You would use DOM Parse XML source. You can then use commands in the XML DOM theme to inspect

Re: XML or rest services

2017-03-29 Thread Tom DeMeo via 4D_Tech
Chuck, REST can return JSON or XML. JSON is always easier to work with than XML. You just parse the response into an object variable, then work with that. C_LONGINT($vl_ResponseStatusCode) C_BLOB($vx_Response) C_OBJECT($vo_Response) C_TEXT($vt_URL) C_TEXT($vt_JSONText) $vt_URL:= “Build Your

Re: XML or rest services

2017-03-29 Thread Charles Miller via 4D_Tech
On Wed, Mar 29, 2017 at 3:23 PM, Ortwin Zillgen via 4D_Tech < 4d_tech@lists.4d.com> wrote: > > 4D tags work just fine for creating XML I know that what I need to know is how to get data from XML into 4D without having access to source. I would have thought I could use 4D tags. That is question

Re: XML or rest services

2017-03-29 Thread Ortwin Zillgen via 4D_Tech
> Thanks that's kind of what I thought you would then use 4d tags to get data > into table and fields. Is that correct? Sorry for being dense but I do not do > any of this type of coding. 4D tags work just fine for creating XML Grüße/regards Ortwin Zillgen >

Re: XML or rest services

2017-03-29 Thread Chuck Miller via 4D_Tech
Thanks that's kind of what I thought you would then use 4d tags to get data into table and fields. Is that correct? Sorry for being dense but I do not do any of this type of coding. Regards Chuck Sent from my iPhone > On Mar 29, 2017, at 12:39 PM, Bruno LEGAY via 4D_Tech

XML or rest services

2017-03-29 Thread Bruno LEGAY via 4D_Tech
Hi, Since v13, you have a native http client, so it is easy to POST or GET some xml data over HTTP. So in essence : post : 1. create dom 2. set values in dom 3. export dom to xml blob 4. free dom 5 HTTP POST xml blob get 1. HTTP Get into a blob 2. Parse blob into a dom 3. read data in