Topic complex |
CGI functions |
Function |
getquerystring() |
Short |
Gets a value from the environment variable "QUERY_STRING" |
Syntax |
GETQUERYSTRING(id : STRING) : STRING |
Parameter |
id : name of the CGI variable |
Return |
Value of the CGI variable if it exists
else empty string
|
See also: |
|
Description |
The environment variable QUERY_STRING is transmitted on the following way:
variable1=value1&variable2=value2&...
The whole variable is URL coded.
This variable is URL decoded automatically with an access over GETQUERYSTRING, so that you can work with the values directly.
Example:
From the URL
http://myhost.de/cgi-tdb/test.prg?name=Smith&firstname=Paul
GETQUERYSTRING('name') returns Smith
GETQUERYSTRING('firstname') returns Paul
GETQUERYSTRING('others') returns ''
|