Classes

Method HttpMessage() :setParameter() Foundation

Sets the value of a HTTP parameter.

Syntax
 
:setParameter( <cName>, <cValue> | <aValues> ) --> self
Parameters
<nName>
A character string with the name of the parameter.
<cValue>
A character string with the value of the parameter.
<aValues>
An array of parameter values, specified as character strings.
Return

:setParameter() returns the object executing the method.

Description

The method :setParameter() defines the value or values of a certain HTTP parameter. Existing values are replaced with the value or values specified.

If a character string is assigned to the <cValue> parameter, the value of the HTTP parameter is changed to the specified string. Alternatively, an array can be passed in <aValues> in which case the parameter value is set to the list of character values specified in the array elements.

HTTP parameters are transferred as part of the query string. The methods :addParameter(), :delParameter(), :getParameter(), :getParameters() and their respective :set..() counterparts allow direct and easy manipulation of this part of the HTTP query string. Use the method :getQueryString() for obtaining a reference to the complete string.

Feedback

If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.