VAR actions
About VAR actions
<var-action>s are used to define and/or set an Internet Services script variable. Variables defined in this manner may be references later in the HeaderMatch document, or in any template(s) rendered in the response to the current request, as normal. Unlike SET options, VAR actions will be executed as many times as they appear in the file, with each subsequent value of the Internet Services script variable in question overwriting the preceeding value.
The syntax for a <var-action> is:
VAR <variable> [=] <var-value>
where
• <variable> is the name of an Internet Services script variable to define/set
• <var-value> is one of:
• <prefbag> which is one of:
• SITEPREF is the .sitepref form, or the global site pref form if there is no appropriate .sitepref form
• USERPREF is the user's preferences form
• PREF will first try to locate the specified value in the user's preferences, then fall back to the site prefrences if the user has not specified a value for this field
• .<field-id> is the field on the specified pref form
• [.<index>] is the index of the field
$<variable>
Where <variable> is the name of a previously defined variable to copy the value from
HEADER:<HTTP header name>
Where <HTTP header name> is the name of an http header, the value of which will be assigned to the variable in question
URLPARAM:<URL parameter name>
Where <URL parameter name> is the name of an url parameter, the value of which will be assigned to the variable in question
<value> is a literal value to assign to the variable, enclosed in double quotes if it contains spaces or tabs
HeaderMatch commands to support legacy template sets
New Internet Services versions have new template sets configured to work with them. If you want to continue to run older template sets on some web sites, you need to enable certain HeaderMatch switches, as follows:
To support |
Do this |
template sets from before FirstClass version 10.0 |
Set the urlspaceversion option to 1 Set the requirevalidationkeys option to 0 |
template sets from FirstClass versions 8.0 up to (but not including) 9.0 |
Set the calendaroptions option to 'Legacy80' |
template sets from before FirstClass version 8.1 |
Set the forcedircontacts option to 1 |
template sets from before FirstClass version 8.0 |
Set the legacyfileurls option to 1 Optional: set the legacybodyfontsize option to 1 NoteThe legacy font sizes do not match those of the FirstClass Client, impairing users' WYSIWYG web editing experience. |
template sets from FirstClass version 7.0 up to (but not including) 8.0 |
Set the calendaroptions option to 'Legacy70' |
template sets from before FirstClass version 7.0 |
Set the calendaroptions option to 'Legacy55' |
|