Re: [WebDNA] SOAP support

This WebDNA talk-list message is from

2014


It keeps the original formatting.
numero = 111780
interpreted = N
texte = --Apple-Mail=_4C93AD81-4219-4356-B772-846A2EA06708 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii I have just realised that in your situation this may not be correct, I = need to specify port in mine due to network setup. [/!]Host: [HO-HOSTURL]:[HO-HOSTPORT][UnURL]%0D%0A[/UnURL][!] should be [/!]Host: [HO-HOSTURL][UnURL]%0D%0A[/UnURL][!] Also here is a sample request, once again made with the help of SoapUI [TEXT]content=3D 1  Top3   = [Capitalize][_FIRSTNAME][/Capitalize] = [Capitalize][_LASTNAME][/Capitalize] [Capitalize][_COMPANY][/Capitalize] 
[Capitalize][_ADDRESS1][/Capitalize]
= [Capitalize][_ADDRESS2][/Capitalize] [Capitalize][_CITY][/Capitalize] [_STATE] [_ZIP] [_COUNTRY] = [LowerCase][_EMAILADDRESS][/LowerCase] [HideIf [URL][_MOBILE][/URL]=3D][GetChars = start=3D1&end=3D4][Grep = search=3D[URL][^0-9][/URL]&replace=3D][_MOBILE][/Grep][/GetChars] = [GetChars start=3D5&end=3D7][Grep = search=3D[URL][^0-9][/URL]&replace=3D][_MOBILE][/Grep][/GetChars] = [GetChars start=3D8][Grep = search=3D[URL][^0-9][/URL]&replace=3D][_MOBILE][/Grep][/GetChars][/HideIf]= [HideIf [URL][_PHONE][/URL]=3D][LOOKUP = db=3D^countries.db&value=3D[_COUNTRY]&Lookinfield=3DCOUNTRYNAME&Returnfiel= d=3DDIALCODE] ([Grep = search=3D[URL][^0-9][/URL]&replace=3D][_PHONEPREFIX][/Grep]) [GetChars = start=3D1&end=3D4][Grep = search=3D[URL][^0-9][/URL]&replace=3D][_PHONE][/Grep][/GetChars] = [GetChars start=3D5][Grep = search=3D[URL][^0-9][/URL]&replace=3D][_PHONE][/Grep][/GetChars][/HideIf]<= /SecondPhoneNumber> 1 1 = [URL][URL][Encrypt][_PASSWORD][/Encrypt][/URL][/URL] 
]]>
[/TEXT] Regards Stuart Tremain IDFK Web Developments AUSTRALIA webdna@idfk.com.au > On 17 Dec 2014, at 9:03 am, Stuart Tremain wrote: >=20 > Hey Ted >=20 > I have been doing SOAP on Linux & Windows servers for many years. >=20 > There are few tricks that I have come across that work depending on = the way the SOAP server is configured.. >=20 > Firstly this is a great tool for getting your query correct > http://www.soapui.org >=20 > Secondly, quite often I have made these things work by putting in a = browser type and content-length. >=20 > Your TCP is incorrect >> POST http://wsf.cdyne.com/WeatherWS/Weather.asmx = > Should be POST /WeatherWS/Weather.asmx = >=20 > You also have a space after your text var name [text]SOAPRequest*you = have a space here*=3D[UnURL] >=20 > Try using this: >=20 > [tcpconnect host=3D[HO-HOSTURL]&port=3D[HO-HOSTPORT]&ssl=3DF][!] > [/!][tcpsend skipheader=3DT]POST /[SERVICENAME]/[SERVICENAME].svc?wsdl = HTTP/1.0[UnURL]%0D%0A[/UnURL][!] > [/!]Accept-Encoding: gzip,deflate[UnURL]%0D%0A[/UnURL][!] > [/!]Content-Type: text/xml;charset=3DUTF-8[UnURL]%0D%0A[/UnURL][!] >=20 > I used SOAP UI to get this next line, you may need to do the same > [/!]SOAPAction: = http://tempuri.org/I[SERVICENAME]/GetData[UnURL]%0D%0A[/UnURL][ = !] >=20 > [/!]User-Agent: Mozilla/4.0 (compatible; MSIE 5.01; Windows NT = 5.0)[UnURL]%0D%0A[/UnURL][!] > [/!]Host: [HO-HOSTURL]:[HO-HOSTPORT][UnURL]%0D%0A[/UnURL][!] > [/!]Content-Length: = [CountChars][SOAPRequest][/CountChars][UnURL]%0D%0A[/UnURL][!] > [/!][UnURL]%0D%0A[/UnURL][!] > [/!][SOAPRequest][UnURL]%0D%0A[/UnURL][!] > [/!][UnURL]%0D%0A[/UnURL][!] > [/!][/TCPSend][!] > [/!][/tcpconnect] >=20 >=20 >=20 > HO-HOSTURL=3Dwsf.cdyne.com = > HO-HOSTPORT=3D80 > SERVICENAME=3DWeatherWS/Weather.asmx = >=20 >=20 >=20 >=20 >=20 >=20 >=20 > Regards >=20 > Stuart Tremain > IDFK Web Developments > AUSTRALIA > webdna@idfk.com.au >=20 >=20 >=20 >=20 >> On 17 Dec 2014, at 3:41 am, mainlighting . > wrote: >>=20 >> Has anyone been able to do SOAP requests successfully from WebDNA? = Below is an attempt with WebDNA to a weather web service that fails = (message: 'Data at the root level is invalid. Line 1, position 1'). Is = there something I am missing? >> =20 >> [text]SOAPRequest =3D[UnURL]%0D%0A[/UnURL][!] >> [/!][UnURL]%0D%0A[/UnURL][!] >> [/!]" = xmlns:xsd=3D"http://www.w3.org/2001/XMLSchema = " >> xmlns:soap12=3D"http://schemas.xmlsoap.org/soap/envelope/ = ">[UnURL]%0D%0A[/UnURL][!] >> [/!][UnURL]%0D%0A[/UnURL][!] >> [/!]'>[!] >> [/!]11743[!] >> [/!][!] >> [/!][!] >> [/!][/text] >> =20 >> [text]_SOAPResponse=3D[tcpconnect host=3Dwsf.cdyne.com = &port=3D80] >> [tcpsend]POST http://wsf.cdyne.com/WeatherWS/Weather.asmx = = HTTP/1.1[UnURL]%0D%0A[/UnURL][!] >> [/!]Host: wsf.cdyne.com = [UnURL]%0D%0A[/UnURL][!] >> [/!]Content-type: application/soap+xml; = charset=3D"utf-8"[UnURL]%0D%0A[/UnURL][!] >> [/!]Content-length: = [CountChars][SOAPRequest][/CountChars][UnURL]%0D%0A[/UnURL][!] >> [/!][UnURL]%0D%0A[/UnURL][!] >> [/!][unurl][SOAPRequest][/unurl][UnURL]%0D%0A[/UnURL][!] >> [/!][/TCPSend] >> [/tcpconnect][/text] >> [!][showif [p_returnVar]![raw][p_returnVar][/raw]] >> [text scope=3Dglobal][p_returnVar]=3D[convertchars = table=3Dstrip][_SOAPResponse][/convertchars][/text] >> [/showif][/!] >>
[_SOAPResponse] >> =20 >> Ted >> =20 >>=20 >> =20 >> --------------------------------------------------------- This = message is sent to you because you are subscribed to the mailing list . = To unsubscribe, E-mail to: archives: = http://mail.webdna.us/list/talk@webdna.us = Bug Reporting: = support@webdna.us > --------------------------------------------------------- This message = is sent to you because you are subscribed to the mailing list . To = unsubscribe, E-mail to: archives: = http://mail.webdna.us/list/talk@webdna.us Bug Reporting: = support@webdna.us --Apple-Mail=_4C93AD81-4219-4356-B772-846A2EA06708 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=us-ascii I have just realised that in your situation this may not be = correct, I need to specify port in mine due to network setup.

[/!]Host: = [HO-HOSTURL]:[HO-HOSTPORT][UnURL]%0D%0A[/UnURL][!]

should be

[/!]Host: = [HO-HOSTURL][UnURL]%0D%0A[/UnURL][!]










Also= here is a sample request, once again made with the help of = SoapUI

[TEXT]content=3D<soapenv:Envelope xmlns:soapenv=3D"http://schemas.xmlsoap.org/soap/envelope/" xmlns:tem=3D"http://tempuri.org/"><soapenv:Header/>
<soapenv:Body><tem:GetData><tem:value>
<= div class=3D""><![CDATA[
<HOSCPC>
= <ID>1</ID>
= <Style>OnLine</Style>
= <Source>Top3</Source>
= <C>
= <Title></Title>
= <FirstName>[Capitalize][_FIRSTNAME][/Capitalize]</FirstNam= e>
= <LastName>[Capitalize][_LASTNAME][/Capitalize]</LastName&g= t;
= <Company>[Capitalize][_COMPANY][/Capitalize]</Company><= /div>
= <Address>[Capitalize][_ADDRESS1][/Capitalize]</Address>=
= <Address2>[Capitalize][_ADDRESS2][/Capitalize]</Address2&g= t;
= <City>[Capitalize][_CITY][/Capitalize]</City>
= <State>[_STATE]</State>
= <Zip>[_ZIP]</Zip>
= <Country>[_COUNTRY]</Country>
= <EmailAddress>[LowerCase][_EMAILADDRESS][/LowerCase]</Emai= lAddress>
= <PhoneNumber>[HideIf [URL][_MOBILE][/URL]=3D][GetChars = start=3D1&end=3D4][Grep = search=3D[URL][^0-9][/URL]&replace=3D][_MOBILE][/Grep][/GetChars] = [GetChars start=3D5&end=3D7][Grep = search=3D[URL][^0-9][/URL]&replace=3D][_MOBILE][/Grep][/GetChars] = [GetChars start=3D8][Grep = search=3D[URL][^0-9][/URL]&replace=3D][_MOBILE][/Grep][/GetChars][/Hid= eIf]</PhoneNumber>
= <SecondPhoneNumber>[HideIf [URL][_PHONE][/URL]=3D][LOOKUP = db=3D^countries.db&value=3D[_COUNTRY]&Lookinfield=3DCOUNTRYNAME&am= p;Returnfield=3DDIALCODE] ([Grep = search=3D[URL][^0-9][/URL]&replace=3D][_PHONEPREFIX][/Grep]) = [GetChars start=3D1&end=3D4][Grep = search=3D[URL][^0-9][/URL]&replace=3D][_PHONE][/Grep][/GetChars] = [GetChars start=3D5][Grep = search=3D[URL][^0-9][/URL]&replace=3D][_PHONE][/Grep][/GetChars][/Hide= If]</SecondPhoneNumber>
= <MailingList>1</MailingList>
= <Member>1</Member>
= <Password>[URL][URL][Encrypt][_PASSWORD][/Encrypt][/URL][/URL= ]</Password>
</C>
</HOSCPC>
]]>
</tem:value></tem:GetData></soapenv:Body>
</soapenv:Envelope>[/TEXT]



Regards

Stuart Tremain
IDFK Web Developments
AUSTRALIA




On 17 Dec 2014, at 9:03 am, Stuart Tremain <webdna@idfk.com.au> = wrote:

Hey Ted

I have been doing SOAP = on Linux & Windows servers for many years.

There are  few tricks that I have = come across that work depending on the way the SOAP server is = configured..

Firstly this is a great tool for getting your query = correct

Secondly, quite often I have made these = things work by putting in a browser type and content-length.

Your TCP is = incorrect
Should be POST /WeatherWS/Weather.asmx

You also have a space after your text = var name [text]SOAPRequest*you have a space here*=3D[UnURL]

Try using = this:

[tcpconnect = host=3D[HO-HOSTURL]&port=3D[HO-HOSTPORT]&ssl=3DF][!]
[/!][tcpsend skipheader=3DT]POST = /[SERVICENAME]/[SERVICENAME].svc?wsdl = HTTP/1.0[UnURL]%0D%0A[/UnURL][!]
[/!]Accept-Encoding:= gzip,deflate[UnURL]%0D%0A[/UnURL][!]
[/!]Content-Type: = text/xml;charset=3DUTF-8[UnURL]%0D%0A[/UnURL][!]

I used SOAP UI to get this next line, = you may need to do the same

[/!]User-Agent: Mozilla/4.0 (compatible; MSIE 5.01; Windows = NT 5.0)[UnURL]%0D%0A[/UnURL][!]
[/!]Host: = [HO-HOSTURL]:[HO-HOSTPORT][UnURL]%0D%0A[/UnURL][!]
[/!]Content-Length: = [CountChars][SOAPRequest][/CountChars][UnURL]%0D%0A[/UnURL][!]
[/!][UnURL]%0D%0A[/UnURL][!]
[/!][SOAPRequest][UnURL]%0D%0A[/UnURL][!]
[/!][UnURL]%0D%0A[/UnURL][!]
[/!][/TCPSend][!]
[/!][/tcpconnect]



HO-HOSTURL=3Dwsf.cdyne.com
HO-HOSTPORT=3D80
SERVICENAME=3DWeatherWS/Weather.asmx







Regards

Stuart Tremain
IDFK Web Developments
AUSTRALIA




On 17 Dec 2014, at 3:41 am, mainlighting . <mainlighting@gmail.com> wrote:

Has anyone been able to do SOAP requests = successfully from WebDNA?  Below is an attempt with WebDNA to a = weather web service that fails (message: 'Data at the root level is invalid. Line 1, = position 1'). Is there something I am missing?
 
 [text]SOAPRequest = =3D[UnURL]%0D%0A[/UnURL][!]
[/!]<?xml version=3D"1.0" = encoding=3D"utf-8"?>[UnURL]%0D%0A[/UnURL][!]
[/!]<soap12:Envelope xmlns:xsi=3D"http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd=3D"http://www.w3.org/2001/XMLSchema"
xmlns:soap12=3D"http://schemas.xmlsoap.org/soap/envelope/">[UnURL]%0D%0A= [/UnURL][!]
[/!]<soap12:Body>[UnURL]%0D%0A[/UnURL][!]
[/!]<ns1:GetCityForecastByZIP xmlns:ns1=3D'http://ws.cdyne.com/WeatherWS/'>[!]
[/!]<ns1:ZIP>11743</ns1:ZIP>[!]
[/!]</ns1:GetCityForecastByZIP>[!]
[/!]</soap12:Body>[!]
[/!]</soap12:Envelope>[/text]
  
 [text]_SOAPResponse=3D[tcpconnect host=3Dwsf.cdyne.com&port=3D80]
 [tcpsend]POST http://wsf.cdyne.com/WeatherWS/Weather.asmx = HTTP/1.1[UnURL]%0D%0A[/UnURL][!]
 [/!]Host: wsf.cdyne.com = [UnURL]%0D%0A[/UnURL][!]
 [/!]Content-type: = application/soap+xml; charset=3D"utf-8"[UnURL]%0D%0A[/UnURL][!]
 [/!]Content-length: = [CountChars][SOAPRequest][/CountChars][UnURL]%0D%0A[/UnURL][!]
 [/!][UnURL]%0D%0A[/UnURL][!]
 [/!][unurl][SOAPRequest][/unurl][UnURL]%0D%0A[/UnURL][!]<= br class=3D""> [/!][/TCPSend]
 [/tcpconnect][/text]
 [!][showif = [p_returnVar]![raw][p_returnVar][/raw]]
  [text = scope=3Dglobal][p_returnVar]=3D[convertchars = table=3Dstrip][_SOAPResponse][/convertchars][/text]
 [/showif][/!]
 <br>[_SOAPResponse]
 
Ted
 

 
--------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us

--------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us

= --Apple-Mail=_4C93AD81-4219-4356-B772-846A2EA06708-- Associated Messages, from the most recent to the oldest:

    
  1. Re: [WebDNA] SOAP support (Stuart Tremain 2014)
  2. [WebDNA] SOAP support ("mainlighting ." 2014)
  3. Re: [WebDNA] SOAP support (Stuart Tremain 2014)
  4. Re: [WebDNA] SOAP support (Donovan Brooke 2014)
  5. Re: [WebDNA] SOAP support (Stuart Tremain 2014)
  6. [WebDNA] SOAP support ("mainlighting ." 2014)
  7. [WebDNA] SOAP support ("mainlighting ." 2014)
  8. Re: [WebDNA] SOAP support (Stuart Tremain 2014)
  9. Re: [WebDNA] SOAP support (Stuart Tremain 2014)
  10. Re: [WebDNA] SOAP support (Donovan Brooke 2014)
  11. [WebDNA] SOAP support ("mainlighting ." 2014)
  12. [WebDNA] SOAP support ("mainlighting ." 2014)
  13. Re: [WebDNA] SOAP support (Toby Cox 2014)
  14. [WebDNA] SOAP support ("mainlighting ." 2014)
  15. [WebDNA] SOAP support ("mainlighting ." 2014)
  16. Re: [WebDNA] SOAP support (Toby Cox 2014)
  17. Re: [WebDNA] SOAP support (Tom Duke 2014)
  18. Re: [WebDNA] SOAP support (Donovan Brooke 2014)
  19. [WebDNA] SOAP support ("mainlighting ." 2014)
--Apple-Mail=_4C93AD81-4219-4356-B772-846A2EA06708 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii I have just realised that in your situation this may not be correct, I = need to specify port in mine due to network setup. [/!]Host: [HO-HOSTURL]:[HO-HOSTPORT][unurl]%0D%0A[/UnURL][!] should be [/!]Host: [HO-HOSTURL][unurl]%0D%0A[/UnURL][!] Also here is a sample request, once again made with the help of SoapUI [text]content=3D 1  Top3   = [capitalize][_FIRSTNAME][/Capitalize] = [capitalize][_LASTNAME][/Capitalize] [capitalize][_COMPANY][/Capitalize] 
[capitalize][_ADDRESS1][/Capitalize]
= [capitalize][_ADDRESS2][/Capitalize] [capitalize][_CITY][/Capitalize] [_STATE] [_ZIP] [_COUNTRY] = [lowercase][_EMAILADDRESS][/LowerCase] [HideIf [url][_MOBILE][/URL]=3D][GetChars = start=3D1&end=3D4][Grep = search=3D[url][^0-9][/URL]&replace=3D][_MOBILE][/Grep][/GetChars] = [GetChars start=3D5&end=3D7][Grep = search=3D[url][^0-9][/URL]&replace=3D][_MOBILE][/Grep][/GetChars] = [GetChars start=3D8][Grep = search=3D[url][^0-9][/URL]&replace=3D][_MOBILE][/Grep][/GetChars][/HideIf]= [HideIf [url][_PHONE][/URL]=3D][LOOKUP = db=3D^countries.db&value=3D[_COUNTRY]&Lookinfield=3DCOUNTRYNAME&Returnfiel= d=3DDIALCODE] ([Grep = search=3D[url][^0-9][/URL]&replace=3D][_PHONEPREFIX][/Grep]) [GetChars = start=3D1&end=3D4][Grep = search=3D[url][^0-9][/URL]&replace=3D][_PHONE][/Grep][/GetChars] = [GetChars start=3D5][Grep = search=3D[url][^0-9][/URL]&replace=3D][_PHONE][/Grep][/GetChars][/HideIf]<= /SecondPhoneNumber> 1 1 = [url][url][encrypt][_PASSWORD][/Encrypt][/URL][/URL] 
]]>
[/TEXT] Regards Stuart Tremain IDFK Web Developments AUSTRALIA webdna@idfk.com.au > On 17 Dec 2014, at 9:03 am, Stuart Tremain wrote: >=20 > Hey Ted >=20 > I have been doing SOAP on Linux & Windows servers for many years. >=20 > There are few tricks that I have come across that work depending on = the way the SOAP server is configured.. >=20 > Firstly this is a great tool for getting your query correct > http://www.soapui.org >=20 > Secondly, quite often I have made these things work by putting in a = browser type and content-length. >=20 > Your TCP is incorrect >> POST http://wsf.cdyne.com/WeatherWS/Weather.asmx = > Should be POST /WeatherWS/Weather.asmx = >=20 > You also have a space after your text var name [text]SOAPRequest*you = have a space here*=3D[unurl] >=20 > Try using this: >=20 > [tcpconnect host=3D[HO-HOSTURL]&port=3D[HO-HOSTPORT]&ssl=3DF][!] > [/!][tcpsend skipheader=3DT]POST /[SERVICENAME]/[SERVICENAME].svc?wsdl = HTTP/1.0[unurl]%0D%0A[/UnURL][!] > [/!]Accept-Encoding: gzip,deflate[unurl]%0D%0A[/UnURL][!] > [/!]Content-Type: text/xml;charset=3DUTF-8[unurl]%0D%0A[/UnURL][!] >=20 > I used SOAP UI to get this next line, you may need to do the same > [/!]SOAPAction: = http://tempuri.org/I[SERVICENAME]/GetData[unurl]%0D%0A[/UnURL][ = [unurl]%0D%0A[/UnURL][>!] >=20 > [/!]User-Agent: Mozilla/4.0 (compatible; MSIE 5.01; Windows NT = 5.0)[unurl]%0D%0A[/UnURL][!] > [/!]Host: [HO-HOSTURL]:[HO-HOSTPORT][unurl]%0D%0A[/UnURL][!] > [/!]Content-Length: = [countchars][SOAPRequest][/CountChars][unurl]%0D%0A[/UnURL][!] > [/!][unurl]%0D%0A[/UnURL][!] > [/!][SOAPRequest][unurl]%0D%0A[/UnURL][!] > [/!][unurl]%0D%0A[/UnURL][!] > [/!][/TCPSend][!] > [/!][/tcpconnect] >=20 >=20 >=20 > HO-HOSTURL=3Dwsf.cdyne.com = > HO-HOSTPORT=3D80 > SERVICENAME=3DWeatherWS/Weather.asmx = >=20 >=20 >=20 >=20 >=20 >=20 >=20 > Regards >=20 > Stuart Tremain > IDFK Web Developments > AUSTRALIA > webdna@idfk.com.au >=20 >=20 >=20 >=20 >> On 17 Dec 2014, at 3:41 am, mainlighting . > wrote: >>=20 >> Has anyone been able to do SOAP requests successfully from WebDNA? = Below is an attempt with WebDNA to a weather web service that fails = (message: 'Data at the root level is invalid. Line 1, position 1'). Is = there something I am missing? >> =20 >> [text]SOAPRequest =3D[unurl]%0D%0A[/UnURL][!] >> [/!][unurl]%0D%0A[/UnURL][!] >> [/!]" = xmlns:xsd=3D"http://www.w3.org/2001/XMLSchema = " >> xmlns:soap12=3D"http://schemas.xmlsoap.org/soap/envelope/ = ">[unurl]%0D%0A[/UnURL][!] >> [/!][unurl]%0D%0A[/UnURL][!] >> [/!]'>[!] >> [/!]11743[!] >> [/!][!] >> [/!][!] >> [/!][/text] >> =20 >> [text]_SOAPResponse=3D[tcpconnect host=3Dwsf.cdyne.com = &port=3D80] >> [tcpsend]POST http://wsf.cdyne.com/WeatherWS/Weather.asmx = = HTTP/1.1[unurl]%0D%0A[/UnURL][!] >> [/!]Host: wsf.cdyne.com = [unurl]%0D%0A[/UnURL][!] >> [/!]Content-type: application/soap+xml; = charset=3D"utf-8"[unurl]%0D%0A[/UnURL][!] >> [/!]Content-length: = [countchars][SOAPRequest][/CountChars][unurl]%0D%0A[/UnURL][!] >> [/!][unurl]%0D%0A[/UnURL][!] >> [/!][unurl][SOAPRequest][/unurl][unurl]%0D%0A[/UnURL][!] >> [/!][/TCPSend] >> [/tcpconnect][/text] >> [!][showif [p_returnVar]![raw][p_returnVar][/raw]] >> [text scope=3Dglobal][p_returnVar]=3D[convertchars = table=3Dstrip][_SOAPResponse][/convertchars][/text] >> [/showif][/!] >>
[_SOAPResponse] >> =20 >> Ted >> =20 >>=20 >> =20 >> --------------------------------------------------------- This = message is sent to you because you are subscribed to the mailing list . = To unsubscribe, E-mail to: archives: = http://mail.webdna.us/list/talk@webdna.us = Bug Reporting: = support@webdna.us > --------------------------------------------------------- This message = is sent to you because you are subscribed to the mailing list . To = unsubscribe, E-mail to: archives: = http://mail.webdna.us/list/talk@webdna.us Bug Reporting: = support@webdna.us --Apple-Mail=_4C93AD81-4219-4356-B772-846A2EA06708 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=us-ascii I have just realised that in your situation this may not be = correct, I need to specify port in mine due to network setup.

[/!]Host: = [HO-HOSTURL]:[HO-HOSTPORT][unurl]%0D%0A[/UnURL][!]

should be

[/!]Host: = [HO-HOSTURL][unurl]%0D%0A[/UnURL][!]










Also= here is a sample request, once again made with the help of = SoapUI

[text]content=3D<soapenv:Envelope xmlns:soapenv=3D"http://schemas.xmlsoap.org/soap/envelope/" xmlns:tem=3D"http://tempuri.org/"><soapenv:Header/>
<soapenv:Body><tem:GetData><tem:value>
<= div class=3D""><![CDATA[
<HOSCPC>
= <ID>1</ID>
= <Style>OnLine</Style>
= <Source>Top3</Source>
= <C>
= <Title></Title>
= <FirstName>[capitalize][_FIRSTNAME][/Capitalize]</FirstNam= e>
= <LastName>[capitalize][_LASTNAME][/Capitalize]</LastName&g= t;
= <Company>[capitalize][_COMPANY][/Capitalize]</Company><= /div>
= <Address>[capitalize][_ADDRESS1][/Capitalize]</Address>=
= <Address2>[capitalize][_ADDRESS2][/Capitalize]</Address2&g= t;
= <City>[capitalize][_CITY][/Capitalize]</City>
= <State>[_STATE]</State>
= <Zip>[_ZIP]</Zip>
= <Country>[_COUNTRY]</Country>
= <EmailAddress>[lowercase][_EMAILADDRESS][/LowerCase]</Emai= lAddress>
= <PhoneNumber>[HideIf [url][_MOBILE][/URL]=3D][GetChars = start=3D1&end=3D4][Grep = search=3D[url][^0-9][/URL]&replace=3D][_MOBILE][/Grep][/GetChars] = [GetChars start=3D5&end=3D7][Grep = search=3D[url][^0-9][/URL]&replace=3D][_MOBILE][/Grep][/GetChars] = [GetChars start=3D8][Grep = search=3D[url][^0-9][/URL]&replace=3D][_MOBILE][/Grep][/GetChars][/Hid= eIf]</PhoneNumber>
= <SecondPhoneNumber>[HideIf [url][_PHONE][/URL]=3D][LOOKUP = db=3D^countries.db&value=3D[_COUNTRY]&Lookinfield=3DCOUNTRYNAME&am= p;Returnfield=3DDIALCODE] ([Grep = search=3D[url][^0-9][/URL]&replace=3D][_PHONEPREFIX][/Grep]) = [GetChars start=3D1&end=3D4][Grep = search=3D[url][^0-9][/URL]&replace=3D][_PHONE][/Grep][/GetChars] = [GetChars start=3D5][Grep = search=3D[url][^0-9][/URL]&replace=3D][_PHONE][/Grep][/GetChars][/Hide= If]</SecondPhoneNumber>
= <MailingList>1</MailingList>
= <Member>1</Member>
= <Password>[url][url][encrypt][_PASSWORD][/Encrypt][/URL][/URL= ]</Password>
</C>
</HOSCPC>
]]>
</tem:value></tem:GetData></soapenv:Body>
</soapenv:Envelope>[/TEXT]



Regards

Stuart Tremain
IDFK Web Developments
AUSTRALIA




On 17 Dec 2014, at 9:03 am, Stuart Tremain <webdna@idfk.com.au> = wrote:

Hey Ted

I have been doing SOAP = on Linux & Windows servers for many years.

There are  few tricks that I have = come across that work depending on the way the SOAP server is = configured..

Firstly this is a great tool for getting your query = correct

Secondly, quite often I have made these = things work by putting in a browser type and content-length.

Your TCP is = incorrect
Should be POST /WeatherWS/Weather.asmx

You also have a space after your text = var name [text]SOAPRequest*you have a space here*=3D[unurl]

Try using = this:

[tcpconnect = host=3D[HO-HOSTURL]&port=3D[HO-HOSTPORT]&ssl=3DF][!]
[/!][tcpsend skipheader=3DT]POST = /[SERVICENAME]/[SERVICENAME].svc?wsdl = HTTP/1.0[unurl]%0D%0A[/UnURL][!]
[/!]Accept-Encoding:= gzip,deflate[unurl]%0D%0A[/UnURL][!]
[/!]Content-Type: = text/xml;charset=3DUTF-8[unurl]%0D%0A[/UnURL][!]

I used SOAP UI to get this next line, = you may need to do the same
[/!]SOAPAction: [unurl]%0D%0A[/UnURL][" = class=3D"">http://tempuri.org/I[SERVICENAME]/GetData[unurl]%0D%0A[/UnURL][= !]

[/!]User-Agent: Mozilla/4.0 (compatible; MSIE 5.01; Windows = NT 5.0)[unurl]%0D%0A[/UnURL][!]
[/!]Host: = [HO-HOSTURL]:[HO-HOSTPORT][unurl]%0D%0A[/UnURL][!]
[/!]Content-Length: = [countchars][SOAPRequest][/CountChars][unurl]%0D%0A[/UnURL][!]
[/!][unurl]%0D%0A[/UnURL][!]
[/!][SOAPRequest][unurl]%0D%0A[/UnURL][!]
[/!][unurl]%0D%0A[/UnURL][!]
[/!][/TCPSend][!]
[/!][/tcpconnect]



HO-HOSTURL=3Dwsf.cdyne.com
HO-HOSTPORT=3D80
SERVICENAME=3DWeatherWS/Weather.asmx







Regards

Stuart Tremain
IDFK Web Developments
AUSTRALIA




On 17 Dec 2014, at 3:41 am, mainlighting . <mainlighting@gmail.com> wrote:

Has anyone been able to do SOAP requests = successfully from WebDNA?  Below is an attempt with WebDNA to a = weather web service that fails (message: 'Data at the root level is invalid. Line 1, = position 1'). Is there something I am missing?
 
 [text]SOAPRequest = =3D[unurl]%0D%0A[/UnURL][!]
[/!]<?xml version=3D"1.0" = encoding=3D"utf-8"?>[unurl]%0D%0A[/UnURL][!]
[/!]<soap12:Envelope xmlns:xsi=3D"http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd=3D"http://www.w3.org/2001/XMLSchema"
xmlns:soap12=3D"http://schemas.xmlsoap.org/soap/envelope/">[unurl]%0D%0A= [/UnURL][!]
[/!]<soap12:Body>[unurl]%0D%0A[/UnURL][!]
[/!]<ns1:GetCityForecastByZIP xmlns:ns1=3D'http://ws.cdyne.com/WeatherWS/'>[!]
[/!]<ns1:ZIP>11743</ns1:ZIP>[!]
[/!]</ns1:GetCityForecastByZIP>[!]
[/!]</soap12:Body>[!]
[/!]</soap12:Envelope>[/text]
  
 [text]_SOAPResponse=3D[tcpconnect host=3Dwsf.cdyne.com&port=3D80]
 [tcpsend]POST http://wsf.cdyne.com/WeatherWS/Weather.asmx = HTTP/1.1[unurl]%0D%0A[/UnURL][!]
 [/!]Host: wsf.cdyne.com = [unurl]%0D%0A[/UnURL][!]
 [/!]Content-type: = application/soap+xml; charset=3D"utf-8"[unurl]%0D%0A[/UnURL][!]
 [/!]Content-length: = [countchars][SOAPRequest][/CountChars][unurl]%0D%0A[/UnURL][!]
 [/!][unurl]%0D%0A[/UnURL][!]
 [/!][unurl][SOAPRequest][/unurl][unurl]%0D%0A[/UnURL][!]<= br class=3D""> [/!][/TCPSend]
 [/tcpconnect][/text]
 [!][showif = [p_returnVar]![raw][p_returnVar][/raw]]
  [text = scope=3Dglobal][p_returnVar]=3D[convertchars = table=3Dstrip][_SOAPResponse][/convertchars][/text]
 [/showif][/!]
 <br>[_SOAPResponse]
 
Ted
 

 
--------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us

--------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: archives: http://mail.webdna.us/list/talk@webdna.us Bug Reporting: support@webdna.us

= --Apple-Mail=_4C93AD81-4219-4356-B772-846A2EA06708-- Stuart Tremain

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:

Redirect function (was Bug fixes for next WebDNA release) (2005) WebCat2 - [format thousands] (1997) WebCat b15 Mac plug-in (1997) WC2.0 Memory Requirements (1997) Anyone Using 4DMail (2004) Frames and WebCat (1997) [WebDNA] fastcgi 7+ & [cart]? (2010) WebCommerce: Folder organization ? (1997) question on *requiring* a 'cl' search comparison (amongst other required comparisons) (2000) Can't find templaes (1997) More on the email templates (1997) [addlineitems] display (1997) RAM variables (1997) Repost: WebMerchant crashing and other WebMerchant problem (2000) Attn: Bug in GeneralStore example b15 (1997) NewCart+Search with one click ? (1997) Exclamation point (1997) Ampersand (1997) Fw: [SQL] and [index] mystery solved (2001) Problems with ^ could be solved with [REPLACE CHARACTERS] (1997)