104BWeb server
11.3 User-defined web pages
S7-1200 Programmable controller
498
System Manual, 11/2011, A5E02486680-05
Syntax
<!-- AWP_Out_Variable Name='<Type>:<Name>' [Use='Varname>'] -->
Parameters
<Type>
The type of special variable and is one of the following:
HEADER
COOKIE_VALUE
COOKIE_EXPIRES
<Name>
Refer to HTTP documentation for a list of all the names of HEADER variables. A
few examples are listed below:
Status: response code
Location: path for redirection
Retry-After: how long service is expected to be unavailable to the requesting client
For types COOKIE_VALUE and COOKIE_EXPIRES, <Name> is the name of a
specific cookie.
COOKIE_VALUE:name: value of the named cookie
COOKIE_EXPIRES:name: expiration time in seconds of named cookie
The Name clause must be enclosed in single or double quotation marks.
If no Use clause is specified, the special variable name corresponds to a PLC tag
name. Enclose the complete Name clause within single quotation marks and the
PLC tag in double quotation marks. The special variable name and PLC tag name
must match exactly.
<Varname>
Name of the PLC tag or data block tag for the variable to be read into
The Varname must be enclosed in single quotation marks. Within the single
quotes, use double quotation marks around a PLC tag or data block name. The
data block name is within the double quotes but not the data block tag name. Note
that for data block tags, you use the name of the block and not a data block
number.
Examples
<!-- AWP_Out_Variable Name='"HEADER:Status"' -->
In this example, the HTTP special variable "HEADER:Status" receives the value of the PLC
tag "HEADER:Status". The name in the PLC tag table must match the name of the special
variable exactly if no Use clause is specified.
<!-- AWP_Out_Variable Name='HEADER:Status' Use='"Status"' -->
In this example, the HTTP special variable "HEADER:Status" receives the value of the PLC
tag "Status".
If a tag name or data block name includes special characters, you must use additional
quotation marks or escape characters as described in the topic Handling tag names that