Chart Elements - X Axis Menu - X Axis
Modify all of the axis attributes, line colour, grid colour, tick length and stroke.
Documentation: x_axis
This goes into the <head> of the page:
<script type="text/javascript" src="js/swfobject.js"></script>
<script type="text/javascript">
swfobject.embedSWF(
"open-flash-chart.swf", "my_chart",
"550", "240", "9.0.0", "expressInstall.swf",
{"data-file":"gallery/x-axis-look-and-feel.php"} );
</script>
This writes the chart into a div with id="my_chart",
right click and view source to see it in action,
[the tutorials have more details]
gallery/x-axis-look-and-feel.php
<?php
include '../php-ofc-library/open-flash-chart.php';
$chart = new open_flash_chart();
$title = new title( date("D M d Y") );
$line_dot = new line(); $line_dot->set_values( array(5,4,5,6,5,4) );
$chart->set_title( $title ); $chart->add_element( $line_dot );
// // create an X Axis object // $x = new x_axis(); $x->colour('#A2ACBA') ->grid_colour('#D7E4A3') ->tick_height(10) ->stroke(3);
// // Add the X Axis object to the chart: // $chart->set_x_axis( $x );
echo $chart->toPrettyString();
|
Adverts:
|