How to Publish Chart

Before publication you must create a Data File (see Data file specification) and choose or create a Style File (see Style file specification).

Upload Data File, Style File and zxchart.swf to your server.

To publicate chart on HTML page, please use following HTML-code:

<object classid = "clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="400" height="300">
<param name = movie value = "zxchart.swf?RefreshPeriod=15&datafile=data.txt&stylefile=style.txt">
<param name = quality value = high>
<embed src = "zxchart.swf?RefreshPeriod=15&datafile=data.txt&stylefile=style.txt" quality = high type = "application/x-shockwave-flash" width="400" height="300">
</embed>
</object>

http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0
It is a url to Macromedia Flash installation file. If you will use chart in the internal network (Intranet), You can download swflash.cab file and locate it on your internal server. Then change this url to your internal server. Whereupon users will able install Macromedia Flash Player from internal server.

width="400" height="300"
It is a chart size. You can change this size, but chart will scaled. If you wish change a realy size, you must use *.swf file for desired size. You can download a *.swf files from our site for following sizes: 400x300 600x400 You can get a source code (zxchart.fla file) change and build zxchart.swf by itself. How get zxchart.fla file read here: http://www.ankord.com/registration.html

value = "zxchart.swf?RefreshPeriod=15&datafile=data.txt&stylefile=style.txt"
It is a main parameters:
zxchart.swf - SWF file.
RefreshPeriod - Refresh period (in seconds).
datafile - Data file. File or script name.
stylefile - Style file name.

If you use script as data file, you can transfer it parameters. For example:
value = "zxchart.swf?RefreshPeriod=5&datafile=http://localhost/fl1.php?id=1%26p=3&stylefile=style2.txt"

URL to Data file:
datafile=http://localhost/fl1.php?id=1%26p=3

http://localhost/fl1.php - it is url to data file.
id=1%26p=3 - id and p parameter transfered to fl1.php.

Note: %26 - symbols to separate parameters. When you define a parameters for script, you must use %26, don't use symbol &!

See also
Samples
Step by step

Back to Contents