Re: [WebDNA] TCPConnect w/ user:pass

This WebDNA talk-list message is from

2009


It keeps the original formatting.
numero = 102535
interpreted = N
texte = --000e0cd341005152420469a5bd84 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Dan, Hmmmm... you tell the truth. I obviously didn't read the api docs closely ;-) I have however now tested it against an api call that requires authentication, and it does seem to work (code below). Just one thought - I'm pretty sure twitter expects UTF-8 encoding. Is it possible that your template that makes the call is using a different character set and maybe the username or password contains a character that is being encoded incorrectly? - Tom [!] ------------------------------------ ### Connect to twitter and pull down user's followers ### [/!][TCPConnect host=twitter.com][!] [/!][text]xmlresponse=[tcpsend skipheader=T]GET /statuses/followers.xml HTTP/1.0[unurl]%0D%0A[/unurl][!] [/!]Authorization: Basic [encrypt method=Base64][user_id]:[user_pw][/encrypt][unurl]%0D%0A[/unurl][!] [/!][unurl]%0D%0A%0D%0A[/unurl][/tcpsend][/text][!] [/!][/tcpconnect][!] [/!][xmlresponse] --000e0cd341005152420469a5bd84 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Dan,

Hmmmm... =C2=A0you tell the truth. =C2=A0I obviousl= y didn't read the api docs closely ;-) =C2=A0I have however now tested = it against an api call that requires authentication, and it does seem to wo= rk (code below).

Just one thought - I'm pretty sure twitter expects = UTF-8 encoding. =C2=A0Is it possible that your template that makes the call= is using a different character set and maybe the username or password cont= ains a character that is being encoded incorrectly?

- Tom





[!]<= /div>

----------= --------------------------
### =C2=A0Connect to twitter and pull down user's followers =C2=A0 ##= #

[/!][TCPConnect host=3Dtwitter.com][!]
[/!][text]xmlresponse= =3D[tcpsend skipheader=3DT]GET /statuses/followers.xml HTTP/1.0[unurl]%0D%0= A[/unurl][!]
[/!]Authorization: Basic [encrypt method=3DBase64][user_id]:[user_pw][= /encrypt][unurl]%0D%0A[/unurl][!]
[/!][unurl]%0D%0A%0D%0A[/unurl][/tcpsend][/text][!]
[/!][/tc= pconnect][!]

[/!][xmlresponse]

--000e0cd341005152420469a5bd84-- Associated Messages, from the most recent to the oldest:

    
  1. Re: [WebDNA] TCPConnect w/ user:pass ("Dan Strong" 2009)
  2. Re: [WebDNA] TCPConnect w/ user:pass (Tom Duke 2009)
  3. Re: [WebDNA] TCPConnect w/ user:pass ("Dan Strong" 2009)
  4. Re: [WebDNA] TCPConnect w/ user:pass (Tom Duke 2009)
  5. Re: [WebDNA] TCPConnect w/ user:pass ("Dan Strong" 2009)
  6. Re: [WebDNA] TCPConnect w/ user:pass (Stuart Tremain 2009)
  7. Re: [WebDNA] TCPConnect w/ user:pass (Stuart Tremain 2009)
  8. [WebDNA] TCPConnect w/ user:pass ("Dan Strong" 2009)
--000e0cd341005152420469a5bd84 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Dan, Hmmmm... you tell the truth. I obviously didn't read the api docs closely ;-) I have however now tested it against an api call that requires authentication, and it does seem to work (code below). Just one thought - I'm pretty sure twitter expects UTF-8 encoding. Is it possible that your template that makes the call is using a different character set and maybe the username or password contains a character that is being encoded incorrectly? - Tom [!] ------------------------------------ ### Connect to twitter and pull down user's followers ### [/!][TCPConnect host=twitter.com][!] [/!][text]xmlresponse=[tcpsend skipheader=T]GET /statuses/followers.xml HTTP/1.0[unurl]%0D%0A[/unurl][!] [/!]Authorization: Basic [encrypt method=Base64][user_id]:[user_pw][/encrypt][unurl]%0D%0A[/unurl][!] [/!][unurl]%0D%0A%0D%0A[/unurl][/tcpsend][/text][!] [/!][/tcpconnect][!] [/!][xmlresponse] --000e0cd341005152420469a5bd84 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Dan,

Hmmmm... =C2=A0you tell the truth. =C2=A0I obviousl= y didn't read the api docs closely ;-) =C2=A0I have however now tested = it against an api call that requires authentication, and it does seem to wo= rk (code below).

Just one thought - I'm pretty sure twitter expects = UTF-8 encoding. =C2=A0Is it possible that your template that makes the call= is using a different character set and maybe the username or password cont= ains a character that is being encoded incorrectly?

- Tom





[!]<= /div>

----------= --------------------------
### =C2=A0Connect to twitter and pull down user's followers =C2=A0 ##= #

[/!][TCPConnect host=3Dtwitter.com][!]
[/!][text]xmlresponse= =3D[tcpsend skipheader=3DT]GET /statuses/followers.xml HTTP/1.0[unurl]%0D%0= A[/unurl][!]
[/!]Authorization: Basic [encrypt method=3DBase64][user_id]:[user_pw][= /encrypt][unurl]%0D%0A[/unurl][!]
[/!][unurl]%0D%0A%0D%0A[/unurl][/tcpsend][/text][!]
[/!][/tc= pconnect][!]

[/!][xmlresponse]

--000e0cd341005152420469a5bd84-- Tom Duke

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:

Superfilous Characters (1998) Cookies not being set on PC/ Explorer (2000) Emailer help....! (1997) [WebDNA] search by range of dates (2009) [WebDNA] 30 Minute Cookies (2016) Date search and sendmail (1997) QuickBooks Import? (2007) Silly Question (1997) Verisign is at it again (2003) OT-listserver stuff -WAS-webcat method for waiting specific amount of time? (2000) Download URL & access on the fly ? (1997) [format 40s]text[/format] doesn't work (1997) RE: Error reading data -1 (1997) RE: Answer: WebDelivery downloads alias, not original ? (1997) Merging databases (1997) I forgot (1998) UPDATE PROBLEM (1997) Mac 2.1b4 unknown error: BadSuffix (1997) OBDC Support (1997) Help name our technology! (1997)