![Anybus CompactCom 40 EtherNet/IP Network Manual Download Page 44](http://html1.mh-extra.com/html/anybus/compactcom-40-ethernet-ip/compactcom-40-ethernet-ip_network-manual_2948758044.webp)
Server Side Include (SSI)
44
Doc.Id. HMSI-27-212
Anybus CompactCom 40 EtherNet/IP
Doc.Rev. 1.5
6.3.10 scanf()
This function is very similar to the printf() function described earlier, except that it is used for input rath-
er than output. The function reads a string passed from an HTML form object, parses the string as spec-
ified by a template string, and sends the resulting data to the specified argument. The formatting syntax
used is similar to that of the standard C-function scanf().
The function accepts a source, a template string containing zero or more formatting tags, followed by a
number of arguments. Each argument corresponds to a formatting tag, which determines how the data
read from the HTML form shall be interpreted prior sending it to the destination argument.
Note:
This command cannot be used in email messages.
Syntax:
<?--#exec cmd_argument='scanf("
source"
, "
template
" [,
argument1
, ...,
argumentN
])'-->
Default Output:
Example:
See also...
- “ABCCMessage()” on page 46
- “Example (Set_Attribute):” on page 48
Scenario
Default Output
Success
“Success”
Parsing error
“Incorrect data format ”
Too much data for argument
“Too much data ”
ABCC Message error
ABCCMessage error string ( “Errors” on page 49)
source -
Name of the HTML form object from which the string shall be extracted.
template-
Template which specifies how to parse and interpret the data. May contain
any number of formatting tags which determine the conversion prior to
sending the data to subsequent arguments. The number of formatting tags
must match the number of arguments; if not, the result is undefined.
Formatting tags are written as follows:
%[*][Width][Modifier]type
See also...
• “Formatting Tags” on page 45
argument-
Destination argument(s) specifying where to send the interpreted data.
The number of arguments must match the number of formatting tags; if
not, the result is undefined.
At the time of writing, the only allowed argument is ABCCMessage().
See also...