User-defined JavaScript functions can be attached to individual fields on each add or edit screen within ExtraView. The JavaScript functions are not restricted in scope. This powerful feature allows you to generate virtually any functionality within an add or edit screen. Some typical uses of this feature are:
To accomplish the setting up of a user-defined JavaScript function, first note that each ExtraView form generated for most screens contains the following statement:
<SCRIPT LANGUAGE="JavaScript" SRC="xxxxxxx/user_javascript/UserJavaScript.js"> </SCRIPT>
where xxxxxxx is the environment name. This permits the programmer to reference JavaScript functions within the ExtraView environment.
There are occasions when you might want to include an entire existing JavaScript source library, file or source tree. This is achieved with the use of the behavior setting named USER_CUSTOM_JAVASCRIPT. Put the path name of the files you want to load into the value of this setting. The path is relative to the directory named javascript within your ExtraView environment. Separate multiple files with a semi-colon character.
No checking is done for the presence of this file, so be careful to make sure your JavaScript file exists at the location you provide.