Examples
<!-- AWP_In_Variable Name='"SERVER:current_user_id"' -->
In this example, the Web page writes the value of the HTTP special variable
"SERVER:current_user_id" to the PLC tag named "SERVER:current_user_id ".
<!-- AWP_In_Variable Name=SERVER:current_user_id' Use='"my_userid"'
-->
In this example, the Web page writes the value of the HTTP special variable
"SERVER:current_user_id" to the PLC tag named "my_userid".
Note
Only a user with privileges to modify variables can write data to the CPU. The Web server
ignores the commands if the user does not have modify privileges.
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
contain special characters (Page 1055)".
12.7.2.5
Using an alias for a variable reference
You can use an alias in your user-defined Web page for an In_Variable or an Out_Variable.
For example, you can use a different symbolic name in your HTML page than the one used
in the CPU, or you can equate a variable in the CPU with a special variable. The AWP Use
clause provides this capability.
Syntax
<-- AWP_In_Variable Name='<Varname1>' Use='<Varname2>' -->
<-- AWP_Out_Variable Name='<Varname1>' Use='<Varname2>' -->
Parameters
<Varname1>
<Varname2>
S7-1200 Programmable controller
System Manual, V4.2, 09/2016, A5E02486680-AK
The alias name or special variable name
Varname1 must be enclosed in single or double quotation marks.
Name of the PLC variable for which you want to assign an alias name. The variable
can be a PLC tag, a data block tag, or a special variable. Varname2 must be en-
closed in single quotation marks. Within the single quotes, use double quotation
marks around a PLC tag, special variable, 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.
Web server
12.7 User-defined Web pages
1049