Page 1 of 1

How to send http parameters

Posted: Sat Jun 02, 2018 4:42 pm
by debkosmonaut
Hi, would like an example on how to send the GET or POST parameters on an http request in spiderbasic.
I understand that to send the type post or get I have to use #PB_HTTP_Get or its counterpart. My question is where I actually put the "user=debk", "pass=mypass" or whatever other parameters on the function.

Thanks.

Re: How to send http parameters

Posted: Sat Jun 02, 2018 6:22 pm
by Paul

Code: Select all

Procedure HttpGetEventLogin(Success,Result$,UserData)
  If Success
    ;response from server
    Else
    ;error
  EndIf   
EndProcedure


HTTPRequest(#PB_HTTP_Post, "../cgi-bin/login.cgi", "user=username&pass=password", @HttpGetEventLogin())
The help file explains this pretty good.

Re: How to send http parameters

Posted: Sat Jun 02, 2018 8:30 pm
by debkosmonaut
Paul,
I don't find that code on the help file nor in the example.

Thank you very much.
JD