PDA

View Full Version : CGI Module questions



ShadowEO
22-03-2007, 21:51
Hello, I was wondering exactly how do I use the Gets/CGI_Read command to get arguments from ThinBasic when it's used as a web scripting language? I had tried to use this before to create a System Administration Panel for my computer so that I could tell it to shutdown and stuff like that when I put a argument into the address. Can anyone provide me with the information to do use the Gets/CGI_Read command to get arguments passed to the script from the address? ???

RobertoBianchi
22-03-2007, 23:02
Hi ShadowEO,

what you mean with get arguments from ThinBasic, read a variable value (declared in the script) or retrive the parameters from script command line?
With the CGI_Read function (Gets it's just an alias of CGI_Read) you read data from standard input that is normally whatever coming from GET or POST method.
However now I can't but tomorrow I will see to supply you some example (at least I'll try).

Regards,
Roberto

ErosOlmi
22-03-2007, 23:43
See CGI_GetQueryValue function.
This will read a variable from POST or GET method.



IF UCASE$(CGI_GetQueryValue("ShutDown", %CGI_REQUEST_METHOD_GET)) = "TRUE" THEN
'---Do something
END IF


And your url can be something like:

http://www.myweb.com/index.tbasicc?shutdown=true

Till now very few asked about CGI module. Let me know if it works.
What web server are you using? IIS version ?

Thanks
Eros

ShadowEO
14-03-2009, 05:39
Thank you very much, I forgot I posted here XDDD and I was using Abyss X1.