Rudiments
|
#include <urlhttprequest.h>
Inherits httprequest.
The urlhttprequest class extends httprequest, parsing the url and providing methods for accessing its components.
The SCRIPT_NAME part of the url is parsed as follows:
DOCUMENT_ROOT/"application"/"program".cgi ("application" may span multiple directories)
The PATH_INFO part url is parsed as follows:
/"skin"/"module"/"page".html ("module" may span multiple directories)
The following directories are presumed to exist:
DOCUMENT_ROOT/"application"/"skin"/"module"
These directories are searched for XML files with .var extensions, formatted as follows:
<skin> <var name="...name...">...value...</var> </skin>
These are parsed into "skin variables". Skin variables defined in deeper level .var files override skin variables defined in shallower files.
Returns the "application" part of the SCRIPT_NAME environment variable. SCRIPT_NAME is assumed to be constructed as follows: DOCUMENT_ROOT/"application"/"program".cgi
Returns the location in the filesystem corresponding to the "application" part of the SCRIPT_NAME environment variable. SCRIPT_NAME is assumed to be constructed as follows: DOCUMENT_ROOT/"application"/"program".cgi
Returns a URL corresponding to the "application" part of the SCRIPT_NAME environment variable. SCRIPT_NAME is assumed to be constructed as follows: DOCUMENT_ROOT/"application"/"program".cgi
Matches the REMOTE_ADDR environment variable against the "denied-ips" and "allowed-ips" skin variables (in that order) using regular expression syntax to determine whether the client's IP address is allowed to access this cgi.
This method may be overriden to provide customized ip-based security.
Matches the REQUEST_METHOD environment variable against the "denied-methods" and "allowed-methods" skin variables (in that order) using regular expression syntax to determine whether the client's IP address is allowed to access this cgi.
This method may be overriden to provide customized ip-based security.
Returns the "module" part of the PATH_INFO environment variable. PATH_INFO is assumed to be constructed as follows: /"skin"/"module"/"page".html
Returns the location in the filesystem corresponding to the "module" part of the PATH_INFO environment variable. PATH_INFO is assumed to be constructed as follows: /"skin"/"module"/"page".html
Returns a URL corresponding to the "module" part of the PATH_INFO environment variable. PATH_INFO is assumed to be constructed as follows: /"skin"/"module"/"page".html
Returns the "page" part of the PATH_INFO environment variable. PATH_INFO is assumed to be constructed as follows: /"skin"/"module"/"page".html
Returns the location in the filesystem corresponding to the "page" part of the PATH_INFO environment variable. PATH_INFO is assumed to be constructed as follows: /"skin"/"module"/"page".html
Returns a URL corresponding to the "path" part of the PATH_INFO environment variable. PATH_INFO is assumed to be constructed as follows: /"skin"/"module"/"page".html
Returns the "program" part of the SCRIPT_NAME environment variable. SCRIPT_NAME is assumed to be constructed as follows: DOCUMENT_ROOT/"application"/"program".cgi
Returns the location in the filesystem corresponding to the "program" part of the SCRIPT_NAME environment variable. SCRIPT_NAME is assumed to be constructed as follows: DOCUMENT_ROOT/"application"/"program".cgi
Returns a URL corresponding to the "program" part of the SCRIPT_NAME environment variable. SCRIPT_NAME is assumed to be constructed as follows: DOCUMENT_ROOT/"application"/"program".cgi
Matches the HTTP_REFERER environment variable against the "denied-referers" and "allowed-referers" skin variables (in that order) using regular expression syntax to determine whether the client's IP address is allowed to access this cgi.
This method may be overriden to provide customized referer-based security.
Returns the "skin" part of the PATH_INFO environment variable. PATH_INFO is assumed to be constructed as follows: /"skin"/"module"/"page".html
Returns the location in the filesystem corresponding to the "skin" part of the PATH_INFO environment variable. PATH_INFO is assumed to be constructed as follows: /"skin"/"module"/"page".html
Returns a URL corresponding to the "skin" part of the PATH_INFO environment variable. PATH_INFO is assumed to be constructed as follows: /"skin"/"module"/"page".html
Returns a null terminated list of values corresponding to the variables returned from getSkinVariables().
Returns the value of skin variable "name".
uint64_t urlhttprequest::getSkinVariableCount | ( | ) |
Returns the number of skin variables.
Returns a null terminated list of skin variables. The order of the list is the order the variables were received in.
Returns a null terminated list of values corresponding to the variables returned from getUrlVariables().
uint64_t urlhttprequest::getUrlVariableCount | ( | ) |
Returns the number of URL variables.
Returns a null terminated list of URL variables.
Creates a new skin variable with name "name" and value "value" or updates an existing skin variable "name" to have value "value".
|
virtual |
Writes all environment variable, parameters, file parameter, cookies, skin variables, and url variables to the browser.
Reimplemented from httprequest.