Please enable JavaScript to view this site.

thinBasic Help Manual

Navigation: ThinBASIC Modules > CGI

CGI_GetQueryValue

Scroll Prev Top Next More

* * HELP & MANUAL PREMIUM PACK 4 DEMO VERSION * *

This documentation was styled with a demo skin from the Premium Pack 4 add-on for Help & Manual. The contents of the skin are encrypted and not configurable. You can only publish HM projects with this skin. You cannot edit it or change it.

This version is copyright and may only be used for local testing purposes. It may not be distributed.

Please purchase the full version of the Premium Pack to get the configurable skins and remove this notice. The package will also include the Toolbox configuration utility for Premium Pack skins.

 

Description

 

Retrieves the value of specified query variable (GET or POST).

 

Syntax

 

s = CGI_GetQueryValue(sParamName, nMethod)

 

Returns

 

Return a string value.

The value of variable specified by sParamName argument.

 

Parameters

 

Name

Type

Optional

Meaning

sParamName

String

No

The name of variable to query the value

nMethod

Number

No

The type of method of FORM tag allowed. It can be:

%CGI_REQUEST_METHOD_GET

%CGI_REQUEST_METHOD_POST

 

 

Remarks

 

 

Restrictions

 

If the method used is different from nMethod the function will fail.

 

See also

 

CGI_GetRequestMethod

 

Examples

 

Dim sText As String

sText = CGI_GetQueryValue("Text", %CGI_REQUEST_METHOD_Get)

If Len(sText) Then

  echo("The value of Text is : " + sText)

Else

  echo("Sorry, the query var Text was not found!")

End If

Created with Help+Manual 8 and styled with Premium Pack Version 4 © by EC Software