This section describes the ChartDirector Javascript Library, which is used to support browser side user interactions with charts.
The ChartDirector Javascript Library includes the following main parts:
- Javascript Chart Viewer: A browser side Javascript control for supporting advanced chart user interactions, such as programmable track cursors, zooming and scrolling and AJAX chart updates.
- Javascript Viewport Control: A browser side Javascript control to let the user visualize and manipulate the viewport managed by the Javascript Chart Viewer.
- Javascript Chart Model: An object model of ChartDirector charts, making chart data and configuration accessible on the browser side. This facilitates implementation of programmable track cursors and other advanced user interface features.
The ChartDirector Javascript Library is implemented in the file "cdjcv.js". To use the ChartDirector Javascript Library, please include the following line in the <HEAD> section of the HTML code:
<SCRIPT SRC="/path/to/cdjcv.js">
Note: Please replace
"/path/to"
above to the actual path you put the "cdjcv.js" to.
Note: If you are using a cgi-bin directory for your scripts, please note that "cdjcv.js" is not a CGI script file, but is a Javascript file. It should be put in a web document directory, not a "cgi-bin" directory.
The "cdjcv.js" in turn may load the following files, which should be located in the same directory as "cdjcv.js".
Filename | Description |
---|
wait.gif | Rotating clock wait symbol. |
spacer.gif | A 1-pixel transparent image. |
zoomin.cur | Zoom in cursor. |
zoomin.cur | Zoom out cursor. |
At runtime, "cdjcv.js" will detect the absolute URL of itself, and use it to load the above files. (It does use relative URL, because the browser will interpret it to be relative to the URL of the containing HTML web page, not the URL of the "cdjcv.js".) If you would like "cdjcv.js" to load the above files from an alternative directory, you may put the URL of the directory in a global Javascript variable "cdjcv_path". "cdjcv.js" will look for this variable first before deriving the path from its own URL.
© 2017 Advanced Software Engineering Limited. All rights reserved.