$Web Parm Lstr: Difference between revisions
(Automatically generated page update) |
(Automatically generated page update) |
||
Line 7: | Line 7: | ||
==Syntax== | ==Syntax== | ||
<p class="syntax"><span class="term">%string</span> = <span class="literal">$Web_Parm_Lstr</span>( name, occurrence ) | <p class="syntax"><span class="term">%string</span> = <span class="literal">$Web_Parm_Lstr</span>( <span class="term">name</span>, occurrence ) | ||
</p> | </p> | ||
Revision as of 01:40, 16 April 2013
Value of URL parameter or form field to longstring
$Web_Parm_Lstr retrieves the value of a URL parameter or form field as a longstring. $Web_Parm_Lstr first looks for isindex fields matching the name, then for matching form fields. $Web_Parm_Lstr can be used instead of $Web_IsIndex_Parm_Lstr and $Web_Form_Parm_Lstr to save typing and to make it easy to switch between using "method=GET" and "method=POST"<form> tags.
$Web_Parm_Lstr takes two arguments and returns a longstring (or null for any error condition).
Syntax
%string = $Web_Parm_Lstr( name, occurrence )
Syntax terms
name | The name of the URL parameter or form field, returned by $Web_IsIndex_Name. This is a required argument if occurrence is not specified; otherwise it is optional. |
---|---|
occurrence | The occurrence number of a URL parameter or form field, or the occurrence number of the URL parameter or form field matching name, if name is specified. This is an optional argument if name is specified; otherwise it is required. |
Usage notes
- $Web_Parm_Lstr works much like $Web_Parm, except for the following:
- It can return more than 255 bytes of data into a longstring.
- It causes request cancellation if the result would be truncated, either on assignment to the target STRING %variable, or as input to a STRING $function argument or subroutine parameter.
- It does not have position and length arguments (arguments 3 and 4).
Examples
The following statements retrieve the values of the Moe,Larry, and Curly fields into longstrings, regardless of whether these are URL parameters or form fields.
%moe = $web_form_parm_lstr('MOE') %larry = $web_form_parm_lstr('LARRY') %curly = $web_form_parm_lstr('CURLY')