Email this Page
Log Support Call
Send Feedback
Print |
|||||
Using Variables in External HTML Files and TemplatesYou can use variables in any of the HTML templates or text based additional files used by Author-it, and these will be resolved when publishing to web based outputs. This allows you to substitute text and/or graphics used by the external files. Namespace declarationWhen used in external files, the variable must be defined using a namespace declaration, where the text "
In the world of XML and HTML, a namespace is a multi-part naming system that provides universally unique names for elements and attributes. This means the variable is always recognized as being unique, and won't conflict or trample over another element or tag used by another entity. For example, if the name of your variable was the same as a javascript or ASP function, you could get some rather unusual results in your published output. While we could simply sit back and say you need to take care when naming your variables, using namespaces removes the element of risk. Important: If a variable does not use the namespace declaration it will not be resolved. How does it work?Variable substitution can be made in any plain text files that have a file extension. These extensions are defined in the Author-it Administrator program, with the defaults set to: Substitution is carried out the same as it is usually - with Author-it first substituting the value assigned on specific objects. If an object does not have an assignment, the value assigned to the Book is used. If there are no assignments, the default value is substituted. So where would I use them?Variables can be used to include changeable information in headers, footers, banners, feedback forms, for user tracking, and numerous other mechanisms in your web based documentation. Let's look at some examples:
You can even use variables when you need to localize text elements called by javascript functions. External files and graphic substitutionVariable substitution in external files does not support File Object type variables. To include a changeable graphic, you need to use a Text or List of Values type variable defining the name of the graphic. For example, |
|||||
| Top of Page |
Email this Page
Log Support Call
Send Feedback
Print |
||||
|
|||||