The servlet is setup here to read the configuration data from a text file
and the graph data from a server side process, in this case a PHP script running on our web server.
and here is the HTML code,
<img src="http://localhost:8080/servlet/AreaGraphServlet?
config=http://www.jpowered.com/graph_chart_collection/AreaGraph/Examples/areaprops.txt&
data=http://www.jpowered.com/graph_chart_collection/AreaGraph/Examples/areadata.php"
width="460" height="440">
The areadata.php ( click
here to view code ) is a simple PHP script designed to demonstrate how a server script can be used to return data to either
the graphing applet or servlet. In practice this routine would be expanded to first gather data from any number of data sources.
eg. databases, files other server processes.
For a full explanation of and range of values for the above parameters please
see the Documentation - Configuration Options».
« back to Examples Index
« back to Getting Started
|