diff --git a/.classpath b/java/.classpath
similarity index 100%
rename from .classpath
rename to java/.classpath
diff --git a/.project b/java/.project
similarity index 100%
rename from .project
rename to java/.project
diff --git a/.settings/org.eclipse.jdt.core.prefs b/java/.settings/org.eclipse.jdt.core.prefs
similarity index 100%
rename from .settings/org.eclipse.jdt.core.prefs
rename to java/.settings/org.eclipse.jdt.core.prefs
diff --git a/Californium.properties b/java/Californium.properties
similarity index 100%
rename from Californium.properties
rename to java/Californium.properties
diff --git a/README.md b/java/README.md
similarity index 100%
rename from README.md
rename to java/README.md
diff --git a/bin/boarderGateway/CoAPRessources$DataRessource.class b/java/bin/boarderGateway/CoAPRessources$DataRessource.class
similarity index 100%
rename from bin/boarderGateway/CoAPRessources$DataRessource.class
rename to java/bin/boarderGateway/CoAPRessources$DataRessource.class
diff --git a/bin/boarderGateway/CoAPRessources$RegisterRessource.class b/java/bin/boarderGateway/CoAPRessources$RegisterRessource.class
similarity index 100%
rename from bin/boarderGateway/CoAPRessources$RegisterRessource.class
rename to java/bin/boarderGateway/CoAPRessources$RegisterRessource.class
diff --git a/bin/boarderGateway/CoAPRessources.class b/java/bin/boarderGateway/CoAPRessources.class
similarity index 100%
rename from bin/boarderGateway/CoAPRessources.class
rename to java/bin/boarderGateway/CoAPRessources.class
diff --git a/bin/boarderGateway/CoAPServer.class b/java/bin/boarderGateway/CoAPServer.class
similarity index 100%
rename from bin/boarderGateway/CoAPServer.class
rename to java/bin/boarderGateway/CoAPServer.class
diff --git a/bin/boarderGateway/MySQL.class b/java/bin/boarderGateway/MySQL.class
similarity index 100%
rename from bin/boarderGateway/MySQL.class
rename to java/bin/boarderGateway/MySQL.class
diff --git a/lib/californium-core-1.0.4.jar b/java/lib/californium-core-1.0.4.jar
similarity index 100%
rename from lib/californium-core-1.0.4.jar
rename to java/lib/californium-core-1.0.4.jar
diff --git a/lib/json-20160212.jar b/java/lib/json-20160212.jar
similarity index 100%
rename from lib/json-20160212.jar
rename to java/lib/json-20160212.jar
diff --git a/lib/mysql-connector-java-5.1.39.jar b/java/lib/mysql-connector-java-5.1.39.jar
similarity index 100%
rename from lib/mysql-connector-java-5.1.39.jar
rename to java/lib/mysql-connector-java-5.1.39.jar
diff --git a/src/boarderGateway/CoAPClient.java b/java/src/boarderGateway/CoAPClient.java
similarity index 100%
rename from src/boarderGateway/CoAPClient.java
rename to java/src/boarderGateway/CoAPClient.java
diff --git a/src/boarderGateway/CoAPRessources.java b/java/src/boarderGateway/CoAPRessources.java
similarity index 100%
rename from src/boarderGateway/CoAPRessources.java
rename to java/src/boarderGateway/CoAPRessources.java
diff --git a/src/boarderGateway/CoAPServer.java b/java/src/boarderGateway/CoAPServer.java
similarity index 100%
rename from src/boarderGateway/CoAPServer.java
rename to java/src/boarderGateway/CoAPServer.java
diff --git a/src/boarderGateway/MySQL.java b/java/src/boarderGateway/MySQL.java
similarity index 100%
rename from src/boarderGateway/MySQL.java
rename to java/src/boarderGateway/MySQL.java
diff --git a/web/classes/SQL.php b/web/classes/SQL.php
new file mode 100644
index 0000000000000000000000000000000000000000..f34cc853e172a84ca803ba2fee5bd3ed8a2a3cb3
--- /dev/null
+++ b/web/classes/SQL.php
@@ -0,0 +1,23 @@
+<?php
+
+class SQL{
+
+	private $link;
+	private $dbHost = "localhost";
+	private $dbUser = "root";
+	private $dbPass = "";
+	private $dbName = "iot";
+
+	function __construct(){
+		$this->link = new mysqli($this->dbHost, $this->dbUser, $this->dbPass, $this->dbName);
+		$this->link->set_charset("utf8");
+	}
+
+	public function getLink(){
+		return $this->link;
+	}
+
+}
+
+
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/accbarex1.php b/web/classes/jpgraph/Examples/accbarex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..01796295325dc520ea064ed6ab438e0d5ca8b91d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/accbarex1.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$data1y=array(-8,8,9,3,5,6);
+$data2y=array(18,2,1,7,5,4);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(500,400); 
+$graph->SetScale("textlin");
+
+$graph->SetShadow();
+$graph->img->SetMargin(40,30,20,40);
+
+// Create the bar plots
+$b1plot = new BarPlot($data1y);
+$b1plot->SetFillColor("orange");
+$b1plot->value->Show();
+$b2plot = new BarPlot($data2y);
+$b2plot->SetFillColor("blue");
+$b2plot->value->Show();
+
+// Create the grouped bar plot
+$gbplot = new AccBarPlot(array($b1plot,$b2plot));
+
+// ...and add it to the graPH
+$graph->Add($gbplot);
+
+$graph->title->Set("Accumulated bar plots");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/accbarframeex01.php b/web/classes/jpgraph/Examples/accbarframeex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..8b56876cef90c7b89334b161e33bdf531eb46e70
--- /dev/null
+++ b/web/classes/jpgraph/Examples/accbarframeex01.php
@@ -0,0 +1,31 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay1=array(13,8,19,7,17,6);
+$datay2=array(4,5,2,7,5,25);
+
+// Create the graph.
+$graph = new Graph(350,250);
+$graph->SetScale('textlin');
+$graph->SetMarginColor('white');
+
+// Setup title
+$graph->title->Set('Acc bar with gradient');
+
+// Create the first bar
+$bplot = new BarPlot($datay1);
+$bplot->SetFillGradient('AntiqueWhite2','AntiqueWhite4:0.8',GRAD_VERT);
+$bplot->SetColor('darkred');
+
+// Create the second bar
+$bplot2 = new BarPlot($datay2);
+$bplot2->SetFillGradient('olivedrab1','olivedrab4',GRAD_VERT);
+$bplot2->SetColor('darkgreen');
+
+// And join them in an accumulated bar
+$accbplot = new AccBarPlot(array($bplot,$bplot2));
+$graph->Add($accbplot);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/accbarframeex02.php b/web/classes/jpgraph/Examples/accbarframeex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..aa150dec2396d76fc89d6b782a01a4086514621e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/accbarframeex02.php
@@ -0,0 +1,33 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay1=array(13,8,19,7,17,6);
+$datay2=array(4,5,2,7,5,25);
+
+// Create the graph.
+$graph = new Graph(350,250);
+$graph->SetScale('textlin');
+$graph->SetMarginColor('white');
+
+// Setup title
+$graph->title->Set('Acc bar with gradient');
+
+// Create the first bar
+$bplot = new BarPlot($datay1);
+$bplot->SetFillGradient('AntiqueWhite2','AntiqueWhite4:0.8',GRAD_VERT);
+$bplot->SetColor('darkred');
+
+// Create the second bar
+$bplot2 = new BarPlot($datay2);
+$bplot2->SetFillGradient('olivedrab1','olivedrab4',GRAD_VERT);
+$bplot2->SetColor('darkgreen');
+
+// And join them in an accumulated bar
+$accbplot = new AccBarPlot(array($bplot,$bplot2));
+$accbplot->SetColor('red');
+$accbplot->SetWeight(1);
+$graph->Add($accbplot);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/accbarframeex03.php b/web/classes/jpgraph/Examples/accbarframeex03.php
new file mode 100755
index 0000000000000000000000000000000000000000..37f3157bf8b639ea00c490e893f4d281c04663d3
--- /dev/null
+++ b/web/classes/jpgraph/Examples/accbarframeex03.php
@@ -0,0 +1,35 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay1=array(13,8,19,7,17,6);
+$datay2=array(4,5,2,7,5,25);
+
+// Create the graph.
+$graph = new Graph(350,250);
+$graph->SetScale('textlin');
+$graph->SetMarginColor('white');
+
+// Setup title
+$graph->title->Set('Acc bar with gradient');
+
+// Create the first bar
+$bplot = new BarPlot($datay1);
+$bplot->SetFillGradient('AntiqueWhite2','AntiqueWhite4:0.8',GRAD_VERT);
+$bplot->SetColor('darkred');
+$bplot->SetWeight(0);
+
+// Create the second bar
+$bplot2 = new BarPlot($datay2);
+$bplot2->SetFillGradient('olivedrab1','olivedrab4',GRAD_VERT);
+$bplot2->SetColor('darkgreen');
+$bplot2->SetWeight(0);
+
+// And join them in an accumulated bar
+$accbplot = new AccBarPlot(array($bplot,$bplot2));
+$accbplot->SetColor('darkgray');
+$accbplot->SetWeight(1);
+$graph->Add($accbplot);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/alphabarex1.php b/web/classes/jpgraph/Examples/alphabarex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..81c821cc343f16385679a9f64befa0836d6480ca
--- /dev/null
+++ b/web/classes/jpgraph/Examples/alphabarex1.php
@@ -0,0 +1,75 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+$datay1=array(140,110,50,60);
+$datay2=array(35,90,190,190);
+$datay3=array(20,60,70,140);
+
+// Create the basic graph
+$graph = new Graph(450,250,'auto');	
+$graph->SetScale("textlin");
+$graph->img->SetMargin(40,80,30,40);
+
+// Adjust the position of the legend box
+$graph->legend->Pos(0.02,0.15);
+
+// Adjust the color for theshadow of the legend
+$graph->legend->SetShadow('darkgray@0.5');
+$graph->legend->SetFillColor('lightblue@0.3');
+
+// Get localised version of the month names
+$graph->xaxis->SetTickLabels($gDateLocale->GetShortMonth());
+
+// Set a nice summer (in Stockholm) image
+$graph->SetBackgroundImage('stship.jpg',BGIMG_COPY);
+
+// Set axis titles and fonts
+$graph->xaxis->title->Set('Year 2002');
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetColor('white');
+
+$graph->xaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->SetColor('white');
+
+$graph->yaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->SetColor('white');
+
+//$graph->ygrid->Show(false);
+$graph->ygrid->SetColor('white@0.5');
+
+// Setup graph title
+$graph->title->Set('Using alpha blending with a background');
+// Some extra margin (from the top)
+$graph->title->SetMargin(3);
+$graph->title->SetFont(FF_ARIAL,FS_NORMAL,12);
+
+// Create the three var series we will combine
+$bplot1 = new BarPlot($datay1);
+$bplot2 = new BarPlot($datay2);
+$bplot3 = new BarPlot($datay3);
+
+// Setup the colors with 40% transparency (alpha channel)
+$bplot1->SetFillColor('orange@0.4');
+$bplot2->SetFillColor('brown@0.4');
+$bplot3->SetFillColor('darkgreen@0.4');
+
+// Setup legends
+$bplot1->SetLegend('Label 1');
+$bplot2->SetLegend('Label 2');
+$bplot3->SetLegend('Label 3');
+
+// Setup each bar with a shadow of 50% transparency
+$bplot1->SetShadow('black@0.4');
+$bplot2->SetShadow('black@0.4');
+$bplot3->SetShadow('black@0.4');
+
+$gbarplot = new GroupBarPlot(array($bplot1,$bplot2,$bplot3));
+$gbarplot->SetWidth(0.6);
+$graph->Add($gbarplot);
+
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/antispamex01.php b/web/classes/jpgraph/Examples/antispamex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..57fe6099fd47e0f62d5808ad894740f01340a647
--- /dev/null
+++ b/web/classes/jpgraph/Examples/antispamex01.php
@@ -0,0 +1,18 @@
+<?php // content="text/plain; charset=utf-8"
+// Antispam example using a random string
+require_once "jpgraph/jpgraph_antispam.php";
+
+// Create new anti-spam challenge creator
+// Note: Neither '0' (digit) or 'O' (letter) can be used to avoid confusion
+$spam = new AntiSpam();
+
+// Create a random 5 char challenge and return the string generated
+$chars = $spam->Rand(5);
+
+// Stroke random cahllenge
+if( $spam->Stroke() === false ) {
+    die('Illegal or no data to plot');
+}
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/aqua_example.php b/web/classes/jpgraph/Examples/aqua_example.php
new file mode 100755
index 0000000000000000000000000000000000000000..9c5a650b59d3c3f96c201a7aa7369ec395bceb37
--- /dev/null
+++ b/web/classes/jpgraph/Examples/aqua_example.php
@@ -0,0 +1,58 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$theme = isset($_GET['theme']) ? $_GET['theme'] : null;
+
+$data = array (
+  0 => array (0 => 79, 1 => -25, 2 => -7, 3 => 85, 4 => -26, 5 => -32, ),
+  1 => array (0 => 76, 1 => 51, 2 => 86, 3 => 12, 4 => -7, 5 => 94, ),
+  2 => array (0 => 49, 1 => 38, 2 => 7, 3 => -40, 4 => 9, 5 => -7, ),
+  3 => array ( 0 => 69, 1 => 96, 2 => 49, 3 => 7, 4 => 92, 5 => -38, ),
+  4 => array ( 0 => 68, 1 => 16, 2 => 82, 3 => -49, 4 => 50, 5 => 7, ),
+  5 => array ( 0 => -37, 1 => 28, 2 => 32, 3 => 6, 4 => 13, 5 => 57, ),
+  6 => array ( 0 => 24, 1 => -11, 2 => 7, 3 => 10, 4 => 51, 5 => 51, ),
+  7 => array ( 0 => 3, 1 => -1, 2 => -12, 3 => 61, 4 => 10, 5 => 47, ),
+  8 => array ( 0 => -47, 1 => -21, 2 => 43, 3 => 53, 4 => 36, 5 => 34, ),
+);
+
+
+// Create the graph. These two calls are always required
+$graph = new Graph(400,300);    
+
+$graph->SetScale("textlin");
+if ($theme) {
+  $graph->SetTheme(new $theme());
+}
+$theme_class = new AquaTheme;
+$graph->SetTheme($theme_class);
+
+$plot = array();
+// Create the bar plots
+for ($i = 0; $i < 4; $i++) {
+  $plot[$i] = new BarPlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.($i+1));
+}
+//$acc1 = new AccBarPlot(array($plot[0], $plot[1]));
+//$acc1->value->Show();
+$gbplot = new GroupBarPlot(array($plot[2], $plot[1] ));
+
+for ($i = 4; $i < 8; $i++) {
+  $plot[$i] = new LinePlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.$i);
+  $plot[$i]->value->Show();
+}
+
+$graph->Add($gbplot);
+$graph->Add($plot[4]);
+
+$title = "AquaTheme Example";
+$title = mb_convert_encoding($title,'UTF-8');
+$graph->title->Set($title);
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/axislabelbkgex01.php b/web/classes/jpgraph/Examples/axislabelbkgex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..99c098c2adb167854710a18fec03a5fcbc0d6dff
--- /dev/null
+++ b/web/classes/jpgraph/Examples/axislabelbkgex01.php
@@ -0,0 +1,35 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,19,3,9,15,10);
+
+// The code to setup a very basic graph
+$graph = new Graph(200,150);
+$graph->SetScale('intlin');
+$graph->SetMargin(30,15,40,30);
+$graph->SetMarginColor('white');
+$graph->SetFrame(true,'blue',3);
+
+$graph->title->Set('Label background');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+$graph->subtitle->SetFont(FF_ARIAL,FS_NORMAL,10);
+$graph->subtitle->SetColor('darkred');
+$graph->subtitle->Set('"LABELBKG_NONE"');
+
+$graph->SetAxisLabelBackground(LABELBKG_NONE,'orange','red','lightblue','red');
+
+// Use Ariel font
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->yaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->xgrid->Show();
+
+// Create the plot line
+$p1 = new LinePlot($ydata);
+$graph->Add($p1);
+
+// Output graph
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/axislabelbkgex02.php b/web/classes/jpgraph/Examples/axislabelbkgex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..2b1740fdfe2e4e726867aaf5c6d08aaa5d15e8d1
--- /dev/null
+++ b/web/classes/jpgraph/Examples/axislabelbkgex02.php
@@ -0,0 +1,37 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,19,3,9,15,10);
+
+// The code to setup a very basic graph
+$graph = new Graph(200,150);
+$graph->SetScale('intlin');
+$graph->SetMargin(30,15,40,30);
+$graph->SetMarginColor('white');
+$graph->SetFrame(true,'blue',3);
+
+$graph->title->Set('Label background');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+$graph->subtitle->SetFont(FF_ARIAL,FS_NORMAL,10);
+$graph->subtitle->SetColor('darkred');
+$graph->subtitle->Set('"LABELBKG_XAXIS"');
+
+$graph->SetAxisLabelBackground(LABELBKG_XAXIS,'orange','red','lightblue','red');
+
+// Use Ariel font
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->yaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->xgrid->Show();
+
+// Create the plot line
+$p1 = new LinePlot($ydata);
+$graph->Add($p1);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/axislabelbkgex03.php b/web/classes/jpgraph/Examples/axislabelbkgex03.php
new file mode 100755
index 0000000000000000000000000000000000000000..9e557112ab4087dbcf1214ecd4103b44c79b1a85
--- /dev/null
+++ b/web/classes/jpgraph/Examples/axislabelbkgex03.php
@@ -0,0 +1,37 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,19,3,9,15,10);
+
+// The code to setup a very basic graph
+$graph = new Graph(200,150);
+$graph->SetScale('intlin');
+$graph->SetMargin(30,15,40,30);
+$graph->SetMarginColor('white');
+$graph->SetFrame(true,'blue',3);
+
+$graph->title->Set('Label background');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+$graph->subtitle->SetFont(FF_ARIAL,FS_NORMAL,10);
+$graph->subtitle->SetColor('darkred');
+$graph->subtitle->Set('"LABELBKG_YAXIS"');
+
+$graph->SetAxisLabelBackground(LABELBKG_YAXIS,'orange','red','lightblue','red');
+
+// Use Ariel font
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->yaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->xgrid->Show();
+
+// Create the plot line
+$p1 = new LinePlot($ydata);
+$graph->Add($p1);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/axislabelbkgex04.php b/web/classes/jpgraph/Examples/axislabelbkgex04.php
new file mode 100755
index 0000000000000000000000000000000000000000..eb55a5ff4f61f931be509c42168cbf2b5d6bceac
--- /dev/null
+++ b/web/classes/jpgraph/Examples/axislabelbkgex04.php
@@ -0,0 +1,37 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,19,3,9,15,10);
+
+// The code to setup a very basic graph
+$graph = new Graph(200,150);
+$graph->SetScale('intlin');
+$graph->SetMargin(30,15,40,30);
+$graph->SetMarginColor('white');
+$graph->SetFrame(true,'blue',3);
+
+$graph->title->Set('Label background');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+$graph->subtitle->SetFont(FF_ARIAL,FS_NORMAL,10);
+$graph->subtitle->SetColor('darkred');
+$graph->subtitle->Set('"LABELBKG_YAXISFULL"');
+
+$graph->SetAxisLabelBackground(LABELBKG_YAXISFULL,'orange','red','lightblue','red');
+
+// Use Ariel font
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->yaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->xgrid->Show();
+
+// Create the plot line
+$p1 = new LinePlot($ydata);
+$graph->Add($p1);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/axislabelbkgex05.php b/web/classes/jpgraph/Examples/axislabelbkgex05.php
new file mode 100755
index 0000000000000000000000000000000000000000..29a04f0715681c1e2e1a273aacb1734f72ea4568
--- /dev/null
+++ b/web/classes/jpgraph/Examples/axislabelbkgex05.php
@@ -0,0 +1,37 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,19,3,9,15,10);
+
+// The code to setup a very basic graph
+$graph = new Graph(200,150);
+$graph->SetScale('intlin');
+$graph->SetMargin(30,15,40,30);
+$graph->SetMarginColor('white');
+$graph->SetFrame(true,'blue',3);
+
+$graph->title->Set('Label background');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+$graph->subtitle->SetFont(FF_ARIAL,FS_NORMAL,10);
+$graph->subtitle->SetColor('darkred');
+$graph->subtitle->Set('"LABELBKG_XAXISFULL"');
+
+$graph->SetAxisLabelBackground(LABELBKG_XAXISFULL,'orange','red','lightblue','red');
+
+// Use Ariel font
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->yaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->xgrid->Show();
+
+// Create the plot line
+$p1 = new LinePlot($ydata);
+$graph->Add($p1);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/axislabelbkgex06.php b/web/classes/jpgraph/Examples/axislabelbkgex06.php
new file mode 100755
index 0000000000000000000000000000000000000000..8ad0d812161a8282d3dd761221afd021f5e3cf7d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/axislabelbkgex06.php
@@ -0,0 +1,37 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,19,3,9,15,10);
+
+// The code to setup a very basic graph
+$graph = new Graph(200,150);
+$graph->SetScale('intlin');
+$graph->SetMargin(30,15,40,30);
+$graph->SetMarginColor('white');
+$graph->SetFrame(true,'blue',3);
+
+$graph->title->Set('Label background');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+$graph->subtitle->SetFont(FF_ARIAL,FS_NORMAL,10);
+$graph->subtitle->SetColor('darkred');
+$graph->subtitle->Set('"LABELBKG_XYFULL"');
+
+$graph->SetAxisLabelBackground(LABELBKG_XYFULL,'orange','red','lightblue','red');
+
+// Use Ariel font
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->yaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->xgrid->Show();
+
+// Create the plot line
+$p1 = new LinePlot($ydata);
+$graph->Add($p1);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/axislabelbkgex07.php b/web/classes/jpgraph/Examples/axislabelbkgex07.php
new file mode 100755
index 0000000000000000000000000000000000000000..c23d07fcee461ad46f84858e4feb1ba7feef731b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/axislabelbkgex07.php
@@ -0,0 +1,37 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,19,3,9,15,10);
+
+// The code to setup a very basic graph
+$graph = new Graph(200,150);
+$graph->SetScale('intlin');
+$graph->SetMargin(30,15,40,30);
+$graph->SetMarginColor('white');
+$graph->SetFrame(true,'blue',3);
+
+$graph->title->Set('Label background');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+$graph->subtitle->SetFont(FF_ARIAL,FS_NORMAL,10);
+$graph->subtitle->SetColor('darkred');
+$graph->subtitle->Set('"LABELBKG_XY"');
+
+$graph->SetAxisLabelBackground(LABELBKG_XY,'orange','red','lightblue','red');
+
+// Use Ariel font
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->yaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->xgrid->Show();
+
+// Create the plot line
+$p1 = new LinePlot($ydata);
+$graph->Add($p1);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/background_type_ex0.php b/web/classes/jpgraph/Examples/background_type_ex0.php
new file mode 100755
index 0000000000000000000000000000000000000000..1c4e7456558a7ae502231e12769607c930a41778
--- /dev/null
+++ b/web/classes/jpgraph/Examples/background_type_ex0.php
@@ -0,0 +1,38 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some data
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(350,250);
+$graph->SetScale("textlin");
+$graph->SetMargin(40,40,50,50);
+
+// Setup the grid and plotarea box
+$graph->ygrid->SetLineStyle('dashed');
+$graph->ygrid->setColor('darkgray');
+$graph->SetBox(true);
+
+// Steup graph titles
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->title->Set('Using background image');
+$graph->subtitle->SetFont(FF_COURIER,FS_BOLD,11);
+$graph->subtitle->Set('"BGIMG_COPY"');
+$graph->subtitle->SetColor('darkred');
+
+// Add background with 25% mix
+$graph->SetBackgroundImage('heat1.jpg',BGIMG_COPY);
+$graph->SetBackgroundImageMix(25);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor("blue");
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/background_type_ex1.php b/web/classes/jpgraph/Examples/background_type_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..cdd3cced9e7e656a8784516c1f1626a17c8943ae
--- /dev/null
+++ b/web/classes/jpgraph/Examples/background_type_ex1.php
@@ -0,0 +1,38 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some data
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(350,250);
+$graph->SetScale("textlin");
+$graph->SetMargin(40,40,50,50);
+
+// Setup the grid and plotarea box
+$graph->ygrid->SetLineStyle('dashed');
+$graph->ygrid->setColor('darkgray');
+$graph->SetBox(true);
+
+// Steup graph titles
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->title->Set('Using background image');
+$graph->subtitle->SetFont(FF_COURIER,FS_BOLD,11);
+$graph->subtitle->Set('"BGIMG_CENTER"');
+$graph->subtitle->SetColor('darkred');
+
+// Add background with 25% mix
+$graph->SetBackgroundImage('heat1.jpg',BGIMG_CENTER);
+$graph->SetBackgroundImageMix(25);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor("blue");
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/background_type_ex2.php b/web/classes/jpgraph/Examples/background_type_ex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..932f7a52bdceff837741ef413fc377614380eafa
--- /dev/null
+++ b/web/classes/jpgraph/Examples/background_type_ex2.php
@@ -0,0 +1,38 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some data
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(350,250);
+$graph->SetScale("textlin");
+$graph->SetMargin(40,40,50,50);
+
+// Setup the grid and plotarea box
+$graph->ygrid->SetLineStyle('dashed');
+$graph->ygrid->setColor('darkgray');
+$graph->SetBox(true);
+
+// Steup graph titles
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->title->Set('Using background image');
+$graph->subtitle->SetFont(FF_COURIER,FS_BOLD,11);
+$graph->subtitle->Set('"BGIMG_FREE"');
+$graph->subtitle->SetColor('darkred');
+
+// Add background with 25% mix
+$graph->SetBackgroundImage('heat1.jpg',BGIMG_FREE);
+$graph->SetBackgroundImageMix(25);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor("blue");
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/background_type_ex3.php b/web/classes/jpgraph/Examples/background_type_ex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..8b265c8527dc1fb41aa4444f8f969da1e1d3e4c4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/background_type_ex3.php
@@ -0,0 +1,38 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some data
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(350,250);
+$graph->SetScale("textlin");
+$graph->SetMargin(40,40,50,50);
+
+// Setup the grid and plotarea box
+$graph->ygrid->SetLineStyle('dashed');
+$graph->ygrid->setColor('darkgray');
+$graph->SetBox(true);
+
+// Steup graph titles
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->title->Set('Using background image');
+$graph->subtitle->SetFont(FF_COURIER,FS_BOLD,11);
+$graph->subtitle->Set('"BGIMG_FILLPLOT"');
+$graph->subtitle->SetColor('darkred');
+
+// Add background with 25% mix
+$graph->SetBackgroundImage('heat1.jpg',BGIMG_FILLPLOT);
+$graph->SetBackgroundImageMix(25);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor("blue");
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/background_type_ex4.php b/web/classes/jpgraph/Examples/background_type_ex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..3ff1cebaac49cb1056fa894852bc7aa8cd67707a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/background_type_ex4.php
@@ -0,0 +1,38 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some data
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(350,250);
+$graph->SetScale("textlin");
+$graph->SetMargin(40,40,50,50);
+
+// Setup the grid and plotarea box
+$graph->ygrid->SetLineStyle('dashed');
+$graph->ygrid->setColor('darkgray');
+$graph->SetBox(true);
+
+// Steup graph titles
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->title->Set('Using background image');
+$graph->subtitle->SetFont(FF_COURIER,FS_BOLD,11);
+$graph->subtitle->Set('"BGIMG_FILLFRAME"');
+$graph->subtitle->SetColor('darkred');
+
+// Add background with 25% mix
+$graph->SetBackgroundImage('heat1.jpg',BGIMG_FILLFRAME);
+$graph->SetBackgroundImageMix(25);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor("blue");
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/backgroundex01.php b/web/classes/jpgraph/Examples/backgroundex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..fac8e937dd869fab1429254acf8bdc65df51f977
--- /dev/null
+++ b/web/classes/jpgraph/Examples/backgroundex01.php
@@ -0,0 +1,51 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some data
+$datay = array(28,19,18,23,12,11);
+$data2y = array(14,18,33,29,39,55);
+
+// A nice graph with anti-aliasing
+$graph = new Graph(400,200);
+$graph->img->SetMargin(40,180,40,40);	
+$graph->SetBackgroundImage("tiger_bkg.png",BGIMG_FILLPLOT);
+
+$graph->img->SetAntiAliasing("white");
+$graph->SetScale("textlin");
+$graph->SetShadow();
+$graph->title->Set("Background image");
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Slightly adjust the legend from it's default position in the
+// top right corner. 
+$graph->legend->Pos(0.05,0.5,"right","center");
+
+// Create the first line
+$p1 = new LinePlot($datay);
+$p1->mark->SetType(MARK_FILLEDCIRCLE);
+$p1->mark->SetFillColor("red");
+$p1->mark->SetWidth(4);
+$p1->SetColor("blue");
+$p1->SetCenter();
+$p1->SetLegend("Triumph Tiger -98");
+$graph->Add($p1);
+
+// ... and the second
+$p2 = new LinePlot($data2y);
+$p2->mark->SetType(MARK_STAR);
+$p2->mark->SetFillColor("red");
+$p2->mark->SetWidth(4);
+$p2->SetColor("red");
+$p2->SetCenter();
+$p2->SetLegend("New tiger -99");
+$graph->Add($p2);
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/backgroundex02.php b/web/classes/jpgraph/Examples/backgroundex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..542be5d1b30eafa026202aa20a5eff6c771c649c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/backgroundex02.php
@@ -0,0 +1,51 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some data
+$datay = array(28,19,18,23,12,11);
+$data2y = array(14,18,33,29,39,55);
+
+// A nice graph with anti-aliasing
+$graph = new Graph(400,200);
+$graph->img->SetMargin(40,180,40,40);	
+$graph->SetBackgroundImage("tiger_bkg.png",BGIMG_FILLFRAME);
+
+$graph->img->SetAntiAliasing();
+$graph->SetScale("textlin");
+$graph->SetShadow();
+$graph->title->Set("Background image");
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Slightly adjust the legend from it's default position in the
+// top right corner. 
+$graph->legend->Pos(0.05,0.5,"right","center");
+
+// Create the first line
+$p1 = new LinePlot($datay);
+$p1->mark->SetType(MARK_FILLEDCIRCLE);
+$p1->mark->SetFillColor("red");
+$p1->mark->SetWidth(4);
+$p1->SetColor("blue");
+$p1->SetCenter();
+$p1->SetLegend("Triumph Tiger -98");
+$graph->Add($p1);
+
+// ... and the second
+$p2 = new LinePlot($data2y);
+$p2->mark->SetType(MARK_STAR);
+$p2->mark->SetFillColor("red");
+$p2->mark->SetWidth(4);
+$p2->SetColor("red");
+$p2->SetCenter();
+$p2->SetLegend("New tiger -99");
+$graph->Add($p2);
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/backgroundex03.php b/web/classes/jpgraph/Examples/backgroundex03.php
new file mode 100755
index 0000000000000000000000000000000000000000..a1c1337daec9e647fde56f6b78ee2a13e6be28a1
--- /dev/null
+++ b/web/classes/jpgraph/Examples/backgroundex03.php
@@ -0,0 +1,51 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some data
+$datay = array(28,19,18,23,12,11);
+$data2y = array(14,18,33,29,39,55);
+
+// A nice graph with anti-aliasing
+$graph = new Graph(400,200);
+$graph->img->SetMargin(40,180,40,40);	
+$graph->SetBackgroundImage("tiger_bkg.png",BGIMG_COPY);
+
+$graph->img->SetAntiAliasing("white");
+$graph->SetScale("textlin");
+$graph->SetShadow();
+$graph->title->Set("Background image");
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Slightly adjust the legend from it's default position in the
+// top right corner. 
+$graph->legend->Pos(0.05,0.5,"right","center");
+
+// Create the first line
+$p1 = new LinePlot($datay);
+$p1->mark->SetType(MARK_FILLEDCIRCLE);
+$p1->mark->SetFillColor("red");
+$p1->mark->SetWidth(4);
+$p1->SetColor("blue");
+$p1->SetCenter();
+$p1->SetLegend("Triumph Tiger -98");
+$graph->Add($p1);
+
+// ... and the second
+$p2 = new LinePlot($data2y);
+$p2->mark->SetType(MARK_STAR);
+$p2->mark->SetFillColor("red");
+$p2->mark->SetWidth(4);
+$p2->SetColor("red");
+$p2->SetCenter();
+$p2->SetLegend("New tiger -99");
+$graph->Add($p2);
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/balloonex1.php b/web/classes/jpgraph/Examples/balloonex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..c963d76c7b911b14729d2e208ef1e805498028d6
--- /dev/null
+++ b/web/classes/jpgraph/Examples/balloonex1.php
@@ -0,0 +1,56 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: balloonex1.php,v 1.5 2002/12/15 16:08:51 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+// Some data
+$datax = array(1,2,3,4,5,6,7,8);
+$datay = array(12,23,95,18,65,28,86,44);
+// Callback for markers
+// Must return array(width,color,fill_color)
+// If any of the returned values are "" then the
+// default value for that parameter will be used.
+function FCallback($aVal) {
+    // This callback will adjust the fill color and size of
+    // the datapoint according to the data value according to
+    if( $aVal < 30 ) $c = "blue";
+    elseif( $aVal < 70 ) $c = "green";
+    else $c="red";
+    return array(floor($aVal/3),"",$c);
+}
+
+// Setup a basic graph
+$graph = new Graph(400,300,'auto');
+$graph->SetScale("linlin");
+$graph->img->SetMargin(40,100,40,40);		
+$graph->SetShadow();
+$graph->title->Set("Example of ballon scatter plot");
+// Use a lot of grace to get large scales
+$graph->yaxis->scale->SetGrace(50,10);
+
+// Make sure X-axis as at the bottom of the graph
+$graph->xaxis->SetPos('min');
+
+// Create the scatter plot
+$sp1 = new ScatterPlot($datay,$datax);
+$sp1->mark->SetType(MARK_FILLEDCIRCLE);
+
+// Uncomment the following two lines to display the values
+$sp1->value->Show();
+$sp1->value->SetFont(FF_FONT1,FS_BOLD);
+
+// Specify the callback
+$sp1->mark->SetCallback("FCallback");
+
+// Setup the legend for plot
+$sp1->SetLegend('Year 2002');
+
+// Add the scatter plot to the graph
+$graph->Add($sp1);
+
+// ... and send to browser
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/balloonex2.php b/web/classes/jpgraph/Examples/balloonex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..257a66480a6499afb2a4b38736bc08658ddeae78
--- /dev/null
+++ b/web/classes/jpgraph/Examples/balloonex2.php
@@ -0,0 +1,81 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+// Each ballon is specificed by four values. 
+// (X,Y,Size,Color)
+$data = array(
+    array(1,12,10,'orange'),
+    array(3,41,15,'red'),
+    array(4,5,19,'lightblue'),
+    array(5,70,22,'yellow')
+);
+
+
+
+// We need to create X,Y data vectors suitable for the
+// library from the above raw data.
+$n = count($data);
+for( $i=0; $i < $n; ++$i ) {
+    
+    $datax[$i] = $data[$i][0];
+    $datay[$i] = $data[$i][1];
+
+    // Create a faster lookup array so we don't have to search
+    // for the correct values in the callback function
+    $format[strval($datax[$i])][strval($datay[$i])] = array($data[$i][2],$data[$i][3]);
+    
+}
+
+
+// Callback for markers
+// Must return array(width,border_color,fill_color,filename,imgscale)
+// If any of the returned values are '' then the
+// default value for that parameter will be used (possible empty)
+function FCallback($aYVal,$aXVal) {
+    global $format;
+    return array($format[strval($aXVal)][strval($aYVal)][0],'',
+		 $format[strval($aXVal)][strval($aYVal)][1],'','');
+}
+
+// Setup a basic graph
+$graph = new Graph(450,300,'auto');
+$graph->SetScale("intlin");
+$graph->SetMargin(40,40,40,40);		
+$graph->SetMarginColor('wheat');
+
+$graph->title->Set("Example of ballon scatter plot with X,Y callback");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->title->SetMargin(10);
+
+// Use a lot of grace to get large scales since the ballon have
+// size and we don't want them to collide with the X-axis
+$graph->yaxis->scale->SetGrace(50,10);
+$graph->xaxis->scale->SetGrace(50,10);
+
+// Make sure X-axis as at the bottom of the graph and not at the default Y=0
+$graph->xaxis->SetPos('min');
+
+// Set X-scale to start at 0
+$graph->xscale->SetAutoMin(0);
+
+// Create the scatter plot
+$sp1 = new ScatterPlot($datay,$datax);
+$sp1->mark->SetType(MARK_FILLEDCIRCLE);
+
+// Uncomment the following two lines to display the values
+$sp1->value->Show();
+$sp1->value->SetFont(FF_FONT1,FS_BOLD);
+
+// Specify the callback
+$sp1->mark->SetCallbackYX("FCallback");
+
+// Add the scatter plot to the graph
+$graph->Add($sp1);
+
+// ... and send to browser
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/bar2scalesex1.php b/web/classes/jpgraph/Examples/bar2scalesex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..9248e7c1074b92e8ea1c847fc6af06f087b1fed5
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bar2scalesex1.php
@@ -0,0 +1,48 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(20,30,50,80);
+$datay2=array(430,645,223,690);
+$datazero=array(0,0,0,0);
+
+// Create the graph. 
+$graph = new Graph(450,200);
+$graph->title->Set('Example with 2 scale bars');
+
+// Setup Y and Y2 scales with some "grace"	
+$graph->SetScale("textlin");
+$graph->SetY2Scale("lin");
+$graph->yaxis->scale->SetGrace(30);
+$graph->y2axis->scale->SetGrace(30);
+
+//$graph->ygrid->Show(true,true);
+$graph->ygrid->SetColor('gray','lightgray@0.5');
+
+// Setup graph colors
+$graph->SetMarginColor('white');
+$graph->y2axis->SetColor('darkred');
+
+
+// Create the "dummy" 0 bplot
+$bplotzero = new BarPlot($datazero);
+
+// Create the "Y" axis group
+$ybplot1 = new BarPlot($datay);
+$ybplot1->value->Show();
+$ybplot = new GroupBarPlot(array($ybplot1,$bplotzero));
+
+// Create the "Y2" axis group
+$ybplot2 = new BarPlot($datay2);
+$ybplot2->value->Show();
+$ybplot2->value->SetColor('darkred');
+$ybplot2->SetFillColor('darkred');
+$y2bplot = new GroupBarPlot(array($bplotzero,$ybplot2));
+
+// Add the grouped bar plots to the graph
+$graph->Add($ybplot);
+$graph->AddY2($y2bplot);
+
+// .. and finally stroke the image back to browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/bar_csimex1.php b/web/classes/jpgraph/Examples/bar_csimex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..6ae7dbfe3097df52dea5ecf2786e9d9067b2d9a0
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bar_csimex1.php
@@ -0,0 +1,52 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,26,9,17,31);
+
+// Create the graph. 
+// One minute timeout for the cached image
+// INLINE_NO means don't stream it back to the browser.
+$graph = new Graph(310,250,'auto');
+$graph->SetScale("textlin");
+$graph->img->SetMargin(60,30,20,40);
+$graph->yaxis->SetTitleMargin(45);
+$graph->yaxis->scale->SetGrace(30);
+$graph->SetShadow();
+
+// Turn the tickmarks
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+
+// Create targets for the image maps. One for each column
+$targ=array("bar_clsmex1.php#1","bar_clsmex1.php#2","bar_clsmex1.php#3","bar_clsmex1.php#4","bar_clsmex1.php#5","bar_clsmex1.php#6");
+$alts=array("val=%d","val=%d","val=%d","val=%d","val=%d","val=%d");
+$bplot->SetCSIMTargets($targ,$alts);
+$bplot->SetFillColor("orange");
+
+// Use a shadow on the bar graphs (just use the default settings)
+$bplot->SetShadow();
+$bplot->value->SetFormat(" $ %2.1f",70);
+$bplot->value->SetFont(FF_ARIAL,FS_NORMAL,9);
+$bplot->value->SetColor("blue");
+$bplot->value->Show();
+
+$graph->Add($bplot);
+
+$graph->title->Set("Image maps barex1");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Send back the HTML page which will call this script again
+// to retrieve the image.
+$graph->StrokeCSIM();
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/bar_csimex2.php b/web/classes/jpgraph/Examples/bar_csimex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..5a0cbce894858095a3e50d74518200160e8c594a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bar_csimex2.php
@@ -0,0 +1,51 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$data1y=array(12,8,19,3,10,5);
+$data2y=array(8,2,12,7,14,4);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(310,200,'auto');
+$graph->SetScale("textlin");
+$graph->img->SetMargin(40,30,20,40);
+$graph->SetShadow();
+
+// Create the bar plots
+$b1plot = new BarPlot($data1y);
+$b1plot->SetFillColor("orange");
+$targ=array("bar_clsmex2.php#1","bar_clsmex2.php#2","bar_clsmex2.php#3",
+"bar_clsmex2.php#4","bar_clsmex2.php#5","bar_clsmex2.php#6");
+$alts=array("val=%d","val=%d","val=%d","val=%d","val=%d","val=%d");
+$b1plot->SetCSIMTargets($targ,$alts);
+
+$b2plot = new BarPlot($data2y);
+$b2plot->SetFillColor("blue");
+$targ=array("bar_clsmex2.php#7","bar_clsmex2.php#8","bar_clsmex2.php#9",
+"bar_clsmex2.php#10","bar_clsmex2.php#11","bar_clsmex2.php#12");
+$alts=array("val=%d","val=%d","val=%d","val=%d","val=%d","val=%d");
+$b2plot->SetCSIMTargets($targ,$alts);
+
+// Create the grouped bar plot
+$abplot = new AccBarPlot(array($b1plot,$b2plot));
+
+$abplot->SetShadow();
+$abplot->value->Show();
+
+// ...and add it to the graPH
+$graph->Add($abplot);
+
+$graph->title->Set("Image map barex2");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+
+// Send back the HTML page which will call this script again
+// to retrieve the image.
+$graph->StrokeCSIM();
+
+?>
diff --git a/web/classes/jpgraph/Examples/bar_csimex3.php b/web/classes/jpgraph/Examples/bar_csimex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..6640319d5c64f3337ba816825c6bd0fa61131ed6
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bar_csimex3.php
@@ -0,0 +1,88 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: bar_csimex3.php,v 1.3 2002/08/31 20:03:46 aditus Exp $
+// Horiontal bar graph with image maps
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$data1y=array(5,8,19,3,10,5);
+$data2y=array(12,2,12,7,14,4);
+
+// Setup the basic parameters for the graph
+$graph = new Graph(400,700);
+$graph->SetAngle(90);
+$graph->SetScale("textlin");
+
+// The negative margins are necessary since we
+// have rotated the image 90 degress and shifted the 
+// meaning of width, and height. This means that the 
+// left and right margins now becomes top and bottom
+// calculated with the image width and not the height.
+$graph->img->SetMargin(-80,-80,210,210);
+
+$graph->SetMarginColor('white');
+
+// Setup title for graph
+$graph->title->Set('Horizontal bar graph');
+$graph->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->subtitle->Set("With image map\nNote: The URL just points back to this image");
+
+// Setup X-axis.
+$graph->xaxis->SetTitle("X-title",'center');
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetAngle(90);
+$graph->xaxis->SetTitleMargin(30);
+$graph->xaxis->SetLabelMargin(15);
+$graph->xaxis->SetLabelAlign('right','center');
+
+// Setup Y-axis
+
+// First we want it at the bottom, i.e. the 'max' value of the
+// x-axis
+$graph->yaxis->SetPos('max');
+
+// Arrange the title
+$graph->yaxis->SetTitle("Turnaround (mkr)",'center');
+$graph->yaxis->SetTitleSide(SIDE_RIGHT);
+$graph->yaxis->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->yaxis->title->SetAngle(0);
+$graph->yaxis->title->Align('center','top');
+$graph->yaxis->SetTitleMargin(30);
+
+// Arrange the labels
+$graph->yaxis->SetLabelSide(SIDE_RIGHT);
+$graph->yaxis->SetLabelAlign('center','top');
+
+// Create the bar plots with image maps
+$b1plot = new BarPlot($data1y);
+$b1plot->SetFillColor("orange");
+$targ=array("bar_clsmex2.php#1","bar_clsmex2.php#2","bar_clsmex2.php#3",
+            "bar_clsmex2.php#4","bar_clsmex2.php#5","bar_clsmex2.php#6");
+$alts=array("val=%d","val=%d","val=%d","val=%d","val=%d","val=%d");
+$b1plot->SetCSIMTargets($targ,$alts);
+
+$b2plot = new BarPlot($data2y);
+$b2plot->SetFillColor("blue");
+$targ=array("bar_clsmex2.php#7","bar_clsmex2.php#8","bar_clsmex2.php#9",
+            "bar_clsmex2.php#10","bar_clsmex2.php#11","bar_clsmex2.php#12");
+$alts=array("val=%d","val=%d","val=%d","val=%d","val=%d","val=%d");
+$b2plot->SetCSIMTargets($targ,$alts);
+
+// Create the accumulated bar plot
+$abplot = new AccBarPlot(array($b1plot,$b2plot));
+$abplot->SetShadow();
+
+// We want to display the value of each bar at the top
+$abplot->value->Show();
+$abplot->value->SetFont(FF_FONT1,FS_NORMAL);
+$abplot->value->SetAlign('left','center');
+$abplot->value->SetColor("black","darkred");
+$abplot->value->SetFormat('%.1f mkr');
+
+// ...and add it to the graph
+$graph->Add($abplot);
+
+// Send back the HTML page which will call this script again
+// to retrieve the image.
+$graph->StrokeCSIM();
+
+?>
diff --git a/web/classes/jpgraph/Examples/barcode_errhandling_ex0.php b/web/classes/jpgraph/Examples/barcode_errhandling_ex0.php
new file mode 100755
index 0000000000000000000000000000000000000000..4f5b5393bf53c865023746fd4ac164c22e988da6
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barcode_errhandling_ex0.php
@@ -0,0 +1,16 @@
+<?php
+// ==============================================
+// Output Image using Code 39 using only default values
+// ==============================================
+require_once ('jpgraph/jpgraph_barcode.php');
+
+try {
+$encoder = BarcodeFactory::Create(ENCODING_CODE39);
+$e = BackendFactory::Create(BACKEND_IMAGE,$encoder);
+$e->Stroke('abc123');
+} catch( JpGraphException $e ) {
+	//echo 'Error: ' . $e->getMessage()."\n";
+	JpGraphError::Raise($e->getMessage());
+}
+
+?>
diff --git a/web/classes/jpgraph/Examples/barcode_ex0.php b/web/classes/jpgraph/Examples/barcode_ex0.php
new file mode 100755
index 0000000000000000000000000000000000000000..021b5c7cc2fdec854072e19119f0fe863a84335c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barcode_ex0.php
@@ -0,0 +1,11 @@
+<?php
+// ==============================================
+// Output Image using Code 39 using only default values
+// ==============================================
+require_once ('jpgraph/jpgraph_barcode.php');
+
+$encoder = BarcodeFactory::Create(ENCODING_CODE39);
+$e = BackendFactory::Create(BACKEND_IMAGE,$encoder);
+$e->Stroke('ABC123');
+
+?>
diff --git a/web/classes/jpgraph/Examples/barcode_ex1.php b/web/classes/jpgraph/Examples/barcode_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..df7653b5cbc874b0eb36e425735675a9b838f8fb
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barcode_ex1.php
@@ -0,0 +1,14 @@
+<?php
+// ==============================================
+// Output Image using Code 128
+// ==============================================
+require_once ('jpgraph/jpgraph_barcode.php');
+
+$encoder = BarcodeFactory::Create(ENCODING_CODE128);
+$e = BackendFactory::Create(BACKEND_PS,$encoder);
+$e->SetModuleWidth(2);
+$e->SetHeight(20);
+echo nl2br($e->Stroke('3125134772'));
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/barcode_ex2.php b/web/classes/jpgraph/Examples/barcode_ex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..8fce58e62fb167fdbd8638a2f325f0d0d354f025
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barcode_ex2.php
@@ -0,0 +1,14 @@
+<?php
+// ==============================================
+// Output Postscript of nterleaved 2 of 5
+// ==============================================
+require_once ('jpgraph/jpgraph_barcode.php');
+
+$encoder = BarcodeFactory::Create(ENCODING_CODEI25);
+$e = BackendFactory::Create(BACKEND_PS,$encoder);
+$e->SetModuleWidth(2);
+$e->SetHeight(70);
+$ps = $e->Stroke('3125134772');
+echo nl2br(htmlspecialchars($ps));
+
+?>
diff --git a/web/classes/jpgraph/Examples/barcode_ex3.php b/web/classes/jpgraph/Examples/barcode_ex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..a63f4ad43b0e35bd4dcd5073057f98f2b8461ee3
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barcode_ex3.php
@@ -0,0 +1,17 @@
+<?php
+// ==============================================
+// Output Encapsulated Postscript of interleaved 2 of 5
+// ==============================================
+require_once ('jpgraph/jpgraph_barcode.php');
+
+echo "Start ...<br>";
+$encoder = BarcodeFactory::Create(ENCODING_CODEI25);
+$e = BackendFactory::Create(BACKEND_PS,$encoder);
+$e->SetModuleWidth(2);
+$e->SetHeight(70);
+$e->SetEPS();
+$ps = $e->Stroke('3125134772');
+echo nl2br(htmlspecialchars($ps));
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/barcode_ex4.php b/web/classes/jpgraph/Examples/barcode_ex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..721b56baff0b1da95a9830d65ffac02d0ac4ef45
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barcode_ex4.php
@@ -0,0 +1,12 @@
+<?php
+// ==============================================
+// Output Image using Code Interleaved 2 of 5
+// ==============================================
+require_once ('jpgraph/jpgraph_barcode.php');
+
+$encoder = BarcodeFactory::Create(ENCODING_CODEI25);
+$e = BackendFactory::Create(BACKEND_IMAGE,$encoder);
+$e->SetModuleWidth(2);
+$e->Stroke('1234');
+
+?>
diff --git a/web/classes/jpgraph/Examples/barcode_usps_example.php b/web/classes/jpgraph/Examples/barcode_usps_example.php
new file mode 100755
index 0000000000000000000000000000000000000000..80469beafa8dee3bb964f51cc1e16dd7ec8edeaa
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barcode_usps_example.php
@@ -0,0 +1,74 @@
+<?php
+// =======================================================
+// Example of how to format US Postal shipping information
+// =======================================================
+require_once ('jpgraph/jpgraph_barcode.php');
+
+// The Full barcode standard is described in
+// http://www.usps.com/cpim/ftp/pubs/pub91/91c4.html#508hdr1
+//
+// The data start with AI=420 which means
+// "Ship to/Deliver To Postal Code (within single authority)
+//
+class USPS_Confirmation {
+    function USPS_Confirmation() {
+    }
+
+    // Private utility function
+    function _USPS_chkd($aData) {
+	$n = strlen($aData);
+
+	// Add all even numbers starting from position 1 from the end
+	$et = 0 ;
+	for( $i=1; $i <= $n; $i+=2 ) {
+	    $d = intval(substr($aData,-$i,1));
+	    $et += $d;
+	}
+
+	// Add all odd numbers starting from position 2 from the end
+	$ot = 0 ;
+	for( $i=2; $i <= $n; $i+=2 ) {
+	    $d = intval(substr($aData,-$i,1));
+	    $ot += $d;
+	}
+	$tot = 3*$et + $ot;
+	$chkdigit = (10 - ($tot % 10))%10;;
+	return $chkdigit;
+    }
+
+    // Get type 1 of confirmation code (with ZIP)
+    function GetPICwithZIP($aZIP,$aServiceType,$aDUNS,$aSeqNbr) {
+	// Convert to USPS format with AI=420 and extension starting with AI=91
+	$data = '420'. $aZIP . '91' . $aServiceType . $aDUNS . $aSeqNbr;
+	// Only calculate the checkdigit from the AI=91 and forward
+	// and do not include the ~1 (FUNC1) in the calculation
+	$cd = $this->_USPS_chkd(substr($data,8));
+	$data = '420'. $aZIP . '~191' . $aServiceType . $aDUNS . $aSeqNbr;
+	return $data . $cd;
+    }
+
+    // Get type 2 of confirmation code (without ZIP)
+    function GetPIC($aServiceType,$aDUNS,$aSeqNbr) {
+	// Convert to USPS format with AI=91
+	$data = '91' . $aServiceType . $aDUNS . $aSeqNbr;
+	$cd = $this->_USPS_chkd($data);
+	return $data . $cd;
+    }
+
+}
+
+$usps = new USPS_Confirmation();
+$zip     = '92663';
+$service = '21';
+$DUNS    = '805213907';
+$seqnr   = '04508735';
+$data = $usps->GetPICwithZIP($zip,$service,$DUNS,$seqnr);
+//$data = $usps->GetPIC('01','123456789','00000001');
+
+$encoder = BarcodeFactory::Create(ENCODING_EAN128);
+$e = BackendFactory::Create(BACKEND_IMAGE,$encoder);
+$e->SetModuleWidth(2);
+$e->SetFont(FF_ARIAL,FS_NORMAL,14);
+$e->Stroke($data);
+
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/barcsim_details.php b/web/classes/jpgraph/Examples/barcsim_details.php
new file mode 100755
index 0000000000000000000000000000000000000000..68fb2166e075dd72776050f41dc53fd1cf7a58c5
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barcsim_details.php
@@ -0,0 +1,10 @@
+<?php // content="text/plain; charset=utf-8"
+
+if( empty($_GET['id']) ) {
+    echo 'Incorrect argument(s) to script <b>'.basename(__FILE__).'</b>.'; 
+}
+else {
+    echo 'Some details on bar with id='.$_GET['id'];
+}
+
+?>
diff --git a/web/classes/jpgraph/Examples/barcsim_popup.php b/web/classes/jpgraph/Examples/barcsim_popup.php
new file mode 100755
index 0000000000000000000000000000000000000000..57864584bdf9c176a99b0c2c37df7f01fe5365b5
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barcsim_popup.php
@@ -0,0 +1,41 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some random data to plot
+$datay=array(12,26,9,17,31);
+
+// Create the graph. 
+$graph = new Graph(400,250);
+$graph->SetScale("textlin");
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+
+// Create targets for the image maps so that the details are opened in a separate window
+$fmtStr = "javascript:window.open('barcsim_details.php?id=%d','_new','width=500,height=300');void(0)";
+$n = count($datay);
+$targ=array();
+$alts=array();
+for($i=0; $i < $n; ++$i) {
+    $targ[$i] = sprintf($fmtStr,$i+1);
+    $alts[$i] = 'val=%d'; 
+    // Note: The format placeholder val=%d will be replaced by the actual value in the ouput HTML by the 
+    // library so that when the user hoovers the mouse over the bar the actual numerical value of the bar 
+    // will be dísplayed
+}
+$bplot->SetCSIMTargets($targ,$alts);
+
+// Add plot to graph
+$graph->Add($bplot);
+
+// Setup the title, also wih a CSIM area
+$graph->title->Set("CSIM with popup windows");
+$graph->title->SetFont(FF_FONT2,FS_BOLD);
+// Assume we can give more details on the graph
+$graph->title->SetCSIMTarget(sprintf($fmtStr,-1),'Title for Bar'); 
+
+// Send back the HTML page which will call this script again to retrieve the image.
+$graph->StrokeCSIM();
+
+?>
diff --git a/web/classes/jpgraph/Examples/barformatcallbackex1.php b/web/classes/jpgraph/Examples/barformatcallbackex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..f49a9e289eba86a32b8f3aa3f5f15304be074bbc
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barformatcallbackex1.php
@@ -0,0 +1,30 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$data = array(0.1235,0.4567,0.67,0.45,0.832);
+
+// Callback function
+// Get called with the actual value and should return the
+// value to be displayed as a string
+function cbFmtPercentage($aVal) {
+    return sprintf("%.1f%%",100*$aVal); // Convert to string
+}
+
+// Create the graph. 
+$graph = new Graph(400,300);	
+$graph->SetScale("textlin");
+
+// Create a bar plots
+$bar1 = new BarPlot($data);
+
+// Setup the callback function
+$bar1->value->SetFormatCallback("cbFmtPercentage");
+$bar1->value->Show();
+
+// Add the plot to the graph
+$graph->Add($bar1);
+
+// .. and send the graph back to the browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/bargradex1.php b/web/classes/jpgraph/Examples/bargradex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..e325223fe6bdd962316d7d87dd9d416b09f3a57c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bargradex1.php
@@ -0,0 +1,47 @@
+<?php // content="text/plain; charset=utf-8"
+// Example for use of JpGraph,
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// We need some data
+$datay=array(0.13,0.25,0.21,0.35,0.31,0.06);
+$datax=array("January","February","March","April","May","June");
+
+// Setup the graph.
+$graph = new Graph(400,240);
+$graph->img->SetMargin(60,20,35,75);
+$graph->SetScale("textlin");
+$graph->SetMarginColor("lightblue:1.1");
+$graph->SetShadow();
+
+// Set up the title for the graph
+$graph->title->Set("Bar gradient with left reflection");
+$graph->title->SetMargin(8);
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+$graph->title->SetColor("darkred");
+
+// Setup font for axis
+$graph->xaxis->SetFont(FF_VERDANA,FS_NORMAL,10);
+$graph->yaxis->SetFont(FF_VERDANA,FS_NORMAL,10);
+
+// Show 0 label on Y-axis (default is not to show)
+$graph->yscale->ticks->SupressZeroLabel(false);
+
+// Setup X-axis labels
+$graph->xaxis->SetTickLabels($datax);
+$graph->xaxis->SetLabelAngle(50);
+
+// Create the bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetWidth(0.6);
+
+// Setup color for gradient fill style
+$bplot->SetFillGradient("navy:0.9","navy:1.85",GRAD_LEFT_REFLECTION);
+
+// Set color for the frame of each bar
+$bplot->SetColor("white");
+$graph->Add($bplot);
+
+// Finally send the graph to the browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/bargradex2.php b/web/classes/jpgraph/Examples/bargradex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..02da925d065abed52d253978ceb1f7d8f192cc81
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bargradex2.php
@@ -0,0 +1,48 @@
+<?php // content="text/plain; charset=utf-8"
+// Example for use of JpGraph, 
+// ljp, 01/03/01 20:32
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// We need some data
+$datay=array(-0.13,0.25,-0.21,0.35,0.31,0.04);
+$datax=array("Jan","Feb","Mar","Apr","May","June");
+
+// Setup the graph. 
+$graph = new Graph(400,200);	
+$graph->img->SetMargin(60,20,30,50);
+$graph->SetScale("textlin");
+$graph->SetMarginColor("silver");
+$graph->SetShadow();
+
+// Set up the title for the graph
+$graph->title->Set("Example negative bars");
+$graph->title->SetFont(FF_VERDANA,FS_NORMAL,18);
+$graph->title->SetColor("darkred");
+
+// Setup font for axis
+$graph->xaxis->SetFont(FF_VERDANA,FS_NORMAL,12);
+$graph->xaxis->SetColor("black","red");
+$graph->yaxis->SetFont(FF_VERDANA,FS_NORMAL,11);
+
+// Show 0 label on Y-axis (default is not to show)
+$graph->yscale->ticks->SupressZeroLabel(false);
+
+// Setup X-axis labels
+$graph->xaxis->SetTickLabels($datax);
+$graph->xaxis->SetLabelAngle(50);
+
+// Create the bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetWidth(0.6);
+
+// Setup color for gradient fill style 
+$bplot->SetFillGradient("navy","steelblue",GRAD_MIDVER);
+
+// Set color for the frame of each bar
+$bplot->SetColor("navy");
+$graph->Add($bplot);
+
+// Finally send the graph to the browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/bargradex3.php b/web/classes/jpgraph/Examples/bargradex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..8a3f99d58aad4f87a25141d76df465ca19e7f813
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bargradex3.php
@@ -0,0 +1,50 @@
+<?php // content="text/plain; charset=utf-8"
+// Example for use of JpGraph, 
+// ljp, 01/03/01 20:32
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// We need some data
+$datay=array(-0.13,0.25,-0.21,0.35,0.31,0.04);
+$datax=array("Jan","Feb","Mar","Apr","May","June");
+
+// Setup the graph. 
+$graph = new Graph(400,200);	
+$graph->img->SetMargin(60,20,30,50);
+$graph->SetScale("textlin");
+$graph->SetMarginColor("silver");
+$graph->SetShadow();
+
+// Set up the title for the graph
+$graph->title->Set("Example negative bars");
+$graph->title->SetFont(FF_VERDANA,FS_NORMAL,16);
+$graph->title->SetColor("darkred");
+
+// Setup font for axis
+$graph->xaxis->SetFont(FF_VERDANA,FS_NORMAL,10);
+$graph->yaxis->SetFont(FF_VERDANA,FS_NORMAL,10);
+
+// Show 0 label on Y-axis (default is not to show)
+$graph->yscale->ticks->SupressZeroLabel(false);
+
+// Setup X-axis labels
+$graph->xaxis->SetTickLabels($datax);
+$graph->xaxis->SetLabelAngle(50);
+
+// Set X-axis at the minimum value of Y-axis (default will be at 0)
+$graph->xaxis->SetPos("min");	// "min" will position the x-axis at the minimum value of the Y-axis
+
+// Create the bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetWidth(0.6);
+
+// Setup color for gradient fill style 
+$bplot->SetFillGradient("navy","steelblue",GRAD_MIDVER);
+
+// Set color for the frame of each bar
+$bplot->SetColor("navy");
+$graph->Add($bplot);
+
+// Finally send the graph to the browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/bargradex4.php b/web/classes/jpgraph/Examples/bargradex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..7de203ab7f86b67e0c2f1c8bdc9a64b30c826275
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bargradex4.php
@@ -0,0 +1,47 @@
+<?php // content="text/plain; charset=utf-8"
+// Example for use of JpGraph, 
+// ljp, 01/03/01 19:44
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// We need some data
+$datay=array(0.3031,0.3044,0.3049,0.3040,0.3024,0.3047);
+
+// Setup the graph. 
+$graph = new Graph(400,200);	
+$graph->img->SetMargin(60,30,30,40);
+$graph->SetScale("textlin");
+$graph->SetMarginColor("teal");
+$graph->SetShadow();
+
+// Set up the title for the graph
+$graph->title->Set("Bargraph with small variations");
+$graph->title->SetColor("white");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+
+// Setup color for axis and labels
+$graph->xaxis->SetColor("black","white");
+$graph->yaxis->SetColor("black","white");
+
+// Setup font for axis
+$graph->xaxis->SetFont(FF_VERDANA,FS_NORMAL,10);
+$graph->yaxis->SetFont(FF_VERDANA,FS_NORMAL,10);
+
+// Setup X-axis title (color & font)
+$graph->xaxis->title->Set("X-axis");
+$graph->xaxis->title->SetColor("white");
+$graph->xaxis->title->SetFont(FF_VERDANA,FS_BOLD,10);
+
+// Create the bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetWidth(0.6);
+
+// Setup color for gradient fill style 
+$tcol=array(100,100,255);
+$fcol=array(255,100,100);
+$bplot->SetFillGradient($fcol,$tcol,GRAD_HOR);
+$graph->Add($bplot);
+
+// Finally send the graph to the browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/bargradex5.php b/web/classes/jpgraph/Examples/bargradex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..e0122925249a5b2a2bbdec16268ac4b092f09615
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bargradex5.php
@@ -0,0 +1,52 @@
+<?php // content="text/plain; charset=utf-8"
+// Example for use of JpGraph, 
+// ljp, 01/03/01 19:44
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// We need some data
+$datay=array(0.3031,0.3044,0.3049,0.3040,0.3024,0.3047);
+
+// Setup the graph. 
+$graph = new Graph(400,200);	
+$graph->img->SetMargin(60,30,30,40);
+$graph->SetScale("textlin");
+$graph->SetMarginColor("teal");
+$graph->SetShadow();
+
+// Create the bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetWidth(0.6);
+
+// This is how you make the bar graph start from something other than 0
+$bplot->SetYMin(0.302);
+
+// Setup color for gradient fill style 
+$tcol=array(100,100,255);
+$fcol=array(255,100,100);
+$bplot->SetFillGradient($fcol,$tcol,GRAD_HOR);
+$bplot->SetFillColor("orange");
+$graph->Add($bplot);
+
+// Set up the title for the graph
+$graph->title->Set("Bargraph which doesn't start from y=0");
+$graph->title->SetColor("yellow");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+
+// Setup color for axis and labels
+$graph->xaxis->SetColor("black","white");
+$graph->yaxis->SetColor("black","white");
+
+// Setup font for axis
+$graph->xaxis->SetFont(FF_VERDANA,FS_NORMAL,10);
+$graph->yaxis->SetFont(FF_VERDANA,FS_NORMAL,10);
+
+// Setup X-axis title (color & font)
+$graph->xaxis->title->Set("X-axis");
+$graph->xaxis->title->SetColor("white");
+$graph->xaxis->title->SetFont(FF_VERDANA,FS_BOLD,10);
+
+// Finally send the graph to the browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/bargradex6.php b/web/classes/jpgraph/Examples/bargradex6.php
new file mode 100755
index 0000000000000000000000000000000000000000..43bf9664e549e34b99dc546285a2bf47b9912c1e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bargradex6.php
@@ -0,0 +1,51 @@
+<?php // content="text/plain; charset=utf-8"
+// Example for use of JpGraph, 
+// ljp, 01/03/01 20:32
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// We need some data
+$datay=array(-0.13,0.25,-0.21,0.35,0.31,0.04);
+$datax=array("Jan","Feb","Mar","Apr","May","June");
+
+// Setup the graph. 
+$graph = new Graph(500,200);	
+$graph->img->SetMargin(60,150,30,50);
+$graph->SetScale("textlin");
+$graph->SetMarginColor("silver");
+$graph->SetShadow();
+
+// Set up the title for the graph
+$graph->title->Set("Example negative bars");
+$graph->title->SetFont(FF_VERDANA,FS_NORMAL,16);
+$graph->title->SetColor("darkred");
+
+// Setup font for axis
+$graph->xaxis->SetFont(FF_VERDANA,FS_NORMAL,10);
+$graph->yaxis->SetFont(FF_VERDANA,FS_NORMAL,10);
+
+// Show 0 label on Y-axis (default is not to show)
+$graph->yscale->ticks->SupressZeroLabel(false);
+
+// Setup X-axis labels
+$graph->xaxis->SetTickLabels($datax);
+$graph->xaxis->SetLabelAngle(50);
+
+// Set X-axis at the minimum value of Y-axis (default will be at 0)
+$graph->xaxis->SetPos("min");	// "min" will position the x-axis at the minimum value of the Y-axis
+
+// Create the bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetWidth(0.6);
+$bplot->SetLegend("Result 1999","blue");
+
+// Setup color for gradient fill style 
+$bplot->SetFillGradient("navy","steelblue",GRAD_MIDVER);
+
+// Set color for the frame of each bar
+$bplot->SetColor("navy");
+$graph->Add($bplot);
+
+// Finally send the graph to the browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/bargradsmallex1.php b/web/classes/jpgraph/Examples/bargradsmallex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..83908a974ca933e8ee52a7b8b1ec6260e40b2b60
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bargradsmallex1.php
@@ -0,0 +1,34 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// We need some data
+$datay=array(4,8,6);
+
+// Setup the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->img->SetMargin(25,15,25,25);
+
+$graph->title->Set('"GRAD_MIDVER"');
+$graph->title->SetColor('darkred');
+
+// Setup font for axis
+$graph->xaxis->SetFont(FF_FONT1);
+$graph->yaxis->SetFont(FF_FONT1);
+
+// Create the bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetWidth(0.6);
+
+// Setup color for gradient fill style 
+$bplot->SetFillGradient("navy","lightsteelblue",GRAD_MIDVER);
+
+// Set color for the frame of each bar
+$bplot->SetColor("navy");
+$graph->Add($bplot);
+
+// Finally send the graph to the browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/bargradsmallex2.php b/web/classes/jpgraph/Examples/bargradsmallex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..1aa1037a692499883733d879198f033638a4cc22
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bargradsmallex2.php
@@ -0,0 +1,34 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// We need some data
+$datay=array(4,8,6);
+
+// Setup the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->img->SetMargin(25,15,25,25);
+
+$graph->title->Set('"GRAD_MIDHOR"');
+$graph->title->SetColor('darkred');
+
+// Setup font for axis
+$graph->xaxis->SetFont(FF_FONT1);
+$graph->yaxis->SetFont(FF_FONT1);
+
+// Create the bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetWidth(0.6);
+
+// Setup color for gradient fill style 
+$bplot->SetFillGradient("navy","lightsteelblue",GRAD_MIDHOR);
+
+// Set color for the frame of each bar
+$bplot->SetColor("navy");
+$graph->Add($bplot);
+
+// Finally send the graph to the browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/bargradsmallex3.php b/web/classes/jpgraph/Examples/bargradsmallex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..c5d31c1367d4a9dfdb28324b5a6a2883d41b32a7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bargradsmallex3.php
@@ -0,0 +1,34 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// We need some data
+$datay=array(4,8,6);
+
+// Setup the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->img->SetMargin(25,15,25,25);
+
+$graph->title->Set('"GRAD_HOR"');
+$graph->title->SetColor('darkred');
+
+// Setup font for axis
+$graph->xaxis->SetFont(FF_FONT1);
+$graph->yaxis->SetFont(FF_FONT1);
+
+// Create the bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetWidth(0.6);
+
+// Setup color for gradient fill style 
+$bplot->SetFillGradient("navy","lightsteelblue",GRAD_HOR);
+
+// Set color for the frame of each bar
+$bplot->SetColor("navy");
+$graph->Add($bplot);
+
+// Finally send the graph to the browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/bargradsmallex4.php b/web/classes/jpgraph/Examples/bargradsmallex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..030942d57d2ffd77b752e821973d0fbfda338b84
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bargradsmallex4.php
@@ -0,0 +1,34 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// We need some data
+$datay=array(4,8,6);
+
+// Setup the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->img->SetMargin(25,15,25,25);
+
+$graph->title->Set('"GRAD_VER"');
+$graph->title->SetColor('darkred');
+
+// Setup font for axis
+$graph->xaxis->SetFont(FF_FONT1);
+$graph->yaxis->SetFont(FF_FONT1);
+
+// Create the bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetWidth(0.6);
+
+// Setup color for gradient fill style 
+$bplot->SetFillGradient("navy","lightsteelblue",GRAD_VER);
+
+// Set color for the frame of each bar
+$bplot->SetColor("navy");
+$graph->Add($bplot);
+
+// Finally send the graph to the browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/bargradsmallex5.php b/web/classes/jpgraph/Examples/bargradsmallex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..8028269fad7aab045fb7719d5b2df3d751b01a98
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bargradsmallex5.php
@@ -0,0 +1,34 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// We need some data
+$datay=array(4,8,6);
+
+// Setup the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->img->SetMargin(25,15,25,25);
+
+$graph->title->Set('"GRAD_WIDE_MIDVER"');
+$graph->title->SetColor('darkred');
+
+// Setup font for axis
+$graph->xaxis->SetFont(FF_FONT1);
+$graph->yaxis->SetFont(FF_FONT1);
+
+// Create the bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetWidth(0.6);
+
+// Setup color for gradient fill style 
+$bplot->SetFillGradient("navy","lightsteelblue",GRAD_WIDE_MIDVER);
+
+// Set color for the frame of each bar
+$bplot->SetColor("navy");
+$graph->Add($bplot);
+
+// Finally send the graph to the browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/bargradsmallex6.php b/web/classes/jpgraph/Examples/bargradsmallex6.php
new file mode 100755
index 0000000000000000000000000000000000000000..9b1e45b8e1a1cca3bb03bbc1f3c908c62c800f0e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bargradsmallex6.php
@@ -0,0 +1,34 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// We need some data
+$datay=array(4,8,6);
+
+// Setup the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->img->SetMargin(25,15,25,25);
+
+$graph->title->Set('"GRAD_WIDE_MIDHOR"');
+$graph->title->SetColor('darkred');
+
+// Setup font for axis
+$graph->xaxis->SetFont(FF_FONT1);
+$graph->yaxis->SetFont(FF_FONT1);
+
+// Create the bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetWidth(0.6);
+
+// Setup color for gradient fill style 
+$bplot->SetFillGradient("navy","lightsteelblue",GRAD_WIDE_MIDHOR);
+
+// Set color for the frame of each bar
+$bplot->SetColor("navy");
+$graph->Add($bplot);
+
+// Finally send the graph to the browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/bargradsmallex7.php b/web/classes/jpgraph/Examples/bargradsmallex7.php
new file mode 100755
index 0000000000000000000000000000000000000000..5f011aa968a8446fa43948d9c839796dc762d0dd
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bargradsmallex7.php
@@ -0,0 +1,34 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// We need some data
+$datay=array(4,8,6);
+
+// Setup the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->img->SetMargin(25,15,25,25);
+
+$graph->title->Set('"GRAD_CENTER"');
+$graph->title->SetColor('darkred');
+
+// Setup font for axis
+$graph->xaxis->SetFont(FF_FONT1);
+$graph->yaxis->SetFont(FF_FONT1);
+
+// Create the bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetWidth(0.6);
+
+// Setup color for gradient fill style 
+$bplot->SetFillGradient("navy","lightsteelblue",GRAD_CENTER);
+
+// Set color for the frame of each bar
+$bplot->SetColor("navy");
+$graph->Add($bplot);
+
+// Finally send the graph to the browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/bargradsmallex8.php b/web/classes/jpgraph/Examples/bargradsmallex8.php
new file mode 100755
index 0000000000000000000000000000000000000000..f95cb49a40422112b20151c4766a07a989dfaaec
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bargradsmallex8.php
@@ -0,0 +1,34 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// We need some data
+$datay=array(4,8,6);
+
+// Setup the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->img->SetMargin(25,15,25,25);
+
+$graph->title->Set('"GRAD_RAISED_PANEL"');
+$graph->title->SetColor('darkred');
+
+// Setup font for axis
+$graph->xaxis->SetFont(FF_FONT1);
+$graph->yaxis->SetFont(FF_FONT1);
+
+// Create the bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetWidth(0.6);
+
+// Setup color for gradient fill style 
+$bplot->SetFillGradient('navy','orange',GRAD_RAISED_PANEL);
+
+// Set color for the frame of each bar
+$bplot->SetColor("navy");
+$graph->Add($bplot);
+
+// Finally send the graph to the browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/barimgex1.php b/web/classes/jpgraph/Examples/barimgex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..76aee8f934d029a1fb505e83c292520bfb858389
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barimgex1.php
@@ -0,0 +1,29 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay=array(5,3,11,6,3);
+
+$graph = new Graph(400,300,'auto');	
+$graph->SetScale("textlin");
+
+$graph->title->Set('Images on top of bars');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,13);
+
+$graph->SetTitleBackground('lightblue:1.1',TITLEBKG_STYLE1,TITLEBKG_FRAME_BEVEL);
+
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("orange");
+$bplot->SetWidth(0.5);
+
+$lplot = new LinePlot($datay);
+$lplot->SetColor('white@1');
+$lplot->SetBarCenter();
+$lplot->mark->SetType(MARK_IMG_LBALL,'red');
+
+$graph->Add($bplot);
+$graph->Add($lplot);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/barintex1.php b/web/classes/jpgraph/Examples/barintex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..9ba063d58378f86b6bf969f7c983ebed6be2ea1a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barintex1.php
@@ -0,0 +1,48 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: barintex1.php,v 1.3 2002/07/11 23:27:28 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+$datay=array(1,1,0.5);
+
+// Create the graph and setup the basic parameters 
+$graph = new Graph(460,200,'auto');	
+$graph->img->SetMargin(40,30,30,40);
+$graph->SetScale("textint");
+$graph->SetShadow();
+$graph->SetFrame(false); // No border around the graph
+
+// Add some grace to the top so that the scale doesn't
+// end exactly at the max value. 
+$graph->yaxis->scale->SetGrace(100);
+
+// Setup X-axis labels
+$a = $gDateLocale->GetShortMonth();
+$graph->xaxis->SetTickLabels($a);
+$graph->xaxis->SetFont(FF_FONT2);
+
+// Setup graph title ands fonts
+$graph->title->Set("Example of integer Y-scale");
+$graph->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->xaxis->title->Set("Year 2002");
+$graph->xaxis->title->SetFont(FF_FONT2,FS_BOLD);
+                              
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("orange");
+$bplot->SetWidth(0.5);
+$bplot->SetShadow();
+
+// Setup the values that are displayed on top of each bar
+$bplot->value->Show();
+// Must use TTF fonts if we want text at an arbitrary angle
+$bplot->value->SetFont(FF_ARIAL,FS_BOLD);
+$bplot->value->SetAngle(45);
+// Black color for positive values and darkred for negative values
+$bplot->value->SetColor("black","darkred");
+$graph->Add($bplot);
+
+// Finally stroke the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/barintex2.php b/web/classes/jpgraph/Examples/barintex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..59f3b73bf34b0d4fe4a57738117717f67c8cbdc1
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barintex2.php
@@ -0,0 +1,57 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+$datay=array(3,7,19,11,4,20);
+
+// Create the graph and setup the basic parameters 
+$graph = new Graph(350,200,'auto');	
+$graph->img->SetMargin(40,30,40,40);
+$graph->SetScale("textint");
+$graph->SetFrame(true,'blue',1); 
+$graph->SetColor('lightblue');
+$graph->SetMarginColor('lightblue');
+
+// Add some grace to the top so that the scale doesn't
+// end exactly at the max value. 
+//$graph->yaxis->scale->SetGrace(20);
+
+// Setup X-axis labels
+$a = $gDateLocale->GetShortMonth();
+$graph->xaxis->SetTickLabels($a);
+$graph->xaxis->SetFont(FF_FONT1);
+$graph->xaxis->SetColor('darkblue','black');
+
+// Stup "hidden" y-axis by given it the same color
+// as the background
+$graph->yaxis->SetColor('lightblue','darkblue');
+$graph->ygrid->SetColor('white');
+
+// Setup graph title ands fonts
+$graph->title->Set('Example of integer Y-scale');
+$graph->subtitle->Set('(With "hidden" y-axis)');
+
+$graph->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->xaxis->title->Set("Year 2002");
+$graph->xaxis->title->SetFont(FF_FONT2,FS_BOLD);
+                              
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor('darkblue');
+$bplot->SetColor('darkblue');
+$bplot->SetWidth(0.5);
+$bplot->SetShadow('darkgray');
+
+// Setup the values that are displayed on top of each bar
+$bplot->value->Show();
+// Must use TTF fonts if we want text at an arbitrary angle
+$bplot->value->SetFont(FF_ARIAL,FS_NORMAL,8);
+$bplot->value->SetFormat('$%d');
+// Black color for positive values and darkred for negative values
+$bplot->value->SetColor("black","darkred");
+$graph->Add($bplot);
+
+// Finally stroke the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/barline_csimex1.php b/web/classes/jpgraph/Examples/barline_csimex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..1ab37ec569162df84346626d2e5ddee3b46ea5af
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barline_csimex1.php
@@ -0,0 +1,42 @@
+<?php // content="text/plain; charset=utf-8" 
+require_once ('jpgraph/jpgraph.php'); 
+require_once ('jpgraph/jpgraph_line.php'); 
+require_once ('jpgraph/jpgraph_bar.php'); 
+
+$ydata = array(2,3,4,5,6,7,8,9,10,11); 
+$ydata2 = array(1,2,3,4,5,6,7,8,9,10); 
+$targ = array("#1","#2","#3","#4","#5","#6","#7","#8","#9","#10");
+$alt = array(1,2,3,4,5,6,7,8,9,10); 
+
+// Create the graph. 
+$graph = new Graph(300,200);     
+$graph->SetScale("textlin"); 
+$graph->img->SetMargin(40,20,30,40); 
+$graph->title->Set("CSIM example with bar and line"); 
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Setup axis titles
+$graph->xaxis->title->Set("X-title"); 
+$graph->yaxis->title->Set("Y-title"); 
+
+// Create the linear plot 
+$lineplot=new LinePlot($ydata); 
+$lineplot->mark->SetType(MARK_FILLEDCIRCLE);
+$lineplot->mark->SetWidth(5);
+$lineplot->mark->SetColor('black');
+$lineplot->mark->SetFillColor('red');
+$lineplot->SetCSIMTargets($targ,$alt);
+
+// Create line plot
+$barplot=new barPlot($ydata2); 
+$barplot->SetCSIMTargets($targ,$alt);
+
+// Add the plots to the graph 
+$graph->Add($lineplot); 
+$graph->Add($barplot); 
+
+$graph->StrokeCSIM();
+
+?> 
+
+
diff --git a/web/classes/jpgraph/Examples/barlinealphaex1.php b/web/classes/jpgraph/Examples/barlinealphaex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..95c8b98e0d2c89093b64ed3e1bb4a52758c4dc69
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barlinealphaex1.php
@@ -0,0 +1,74 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some "random" data
+$ydata  = array(10,120,80,190,260,170,60,40,20,230);
+$ydata2 = array(10,70,40,120,200,60,80,40,20,5);
+
+// Get a list of month using the current locale
+$months = $gDateLocale->GetShortMonth();
+
+// Create the graph. 
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+$graph->SetMarginColor('white');
+
+// Adjust the margin slightly so that we use the 
+// entire area (since we don't use a frame)
+$graph->SetMargin(30,1,20,5);
+
+// Box around plotarea
+$graph->SetBox(); 
+
+// No frame around the image
+$graph->SetFrame(false);
+
+// Setup the tab title
+$graph->tabtitle->Set('Year 2003');
+$graph->tabtitle->SetFont(FF_ARIAL,FS_BOLD,10);
+
+// Setup the X and Y grid
+$graph->ygrid->SetFill(true,'#DDDDDD@0.5','#BBBBBB@0.5');
+$graph->ygrid->SetLineStyle('dashed');
+$graph->ygrid->SetColor('gray');
+$graph->xgrid->Show();
+$graph->xgrid->SetLineStyle('dashed');
+$graph->xgrid->SetColor('gray');
+
+// Setup month as labels on the X-axis
+$graph->xaxis->SetTickLabels($months);
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,8);
+$graph->xaxis->SetLabelAngle(45);
+
+// Create a bar pot
+$bplot = new BarPlot($ydata);
+$bplot->SetWidth(0.6);
+$fcol='#440000';
+$tcol='#FF9090';
+
+$bplot->SetFillGradient($fcol,$tcol,GRAD_LEFT_REFLECTION);
+
+// Set line weigth to 0 so that there are no border
+// around each bar
+$bplot->SetWeight(0);
+
+$graph->Add($bplot);
+
+// Create filled line plot
+$lplot = new LinePlot($ydata2);
+$lplot->SetFillColor('skyblue@0.5');
+$lplot->SetColor('navy@0.7');
+$lplot->SetBarCenter();
+
+$lplot->mark->SetType(MARK_SQUARE);
+$lplot->mark->SetColor('blue@0.5');
+$lplot->mark->SetFillColor('lightblue');
+$lplot->mark->SetSize(6);
+
+$graph->Add($lplot);
+
+// .. and finally send it back to the browser
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/barlinefreq_csimex1.php b/web/classes/jpgraph/Examples/barlinefreq_csimex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..00c5977ddc2e5bf5df5b65fc803ba9b117294eaa
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barlinefreq_csimex1.php
@@ -0,0 +1,100 @@
+<?php // content="text/plain; charset=utf-8"
+//
+// Example of CSIM frequence bar that uses the cache
+//
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+
+// Utility function to calculate the accumulated frequence
+// for a set of values and ocurrences
+function accfreq($data) {
+    rsort($data);
+    $s = array_sum($data);
+    $as = array($data[0]);
+    $asp = array(100*$as[0]/$s);
+    $n = count($data);
+    for( $i=1; $i < $n; ++$i ) {
+	$as[$i] = $as[$i-1]+$data[$i];
+	$asp[$i] = 100.0*$as[$i]/$s;
+    }
+    return $asp;
+}
+
+// some data
+$data_freq = array(22,20,12,10,5,4,2);
+$data_accfreq = accfreq($data_freq);
+
+// Create the graph. 
+$graph = new Graph(350,250);
+
+// We need to make this extra call for CSIM scripts
+// that make use of the cache. If the cache contains this
+// graph the HTML wrapper will be returned and then the
+// method will call exit() and hence NO LINES AFTER THIS 
+// CALL WILL BE EXECUTED.
+// $graph->CheckCSIMCache('auto');
+
+// Setup some basic graph parameters
+$graph->SetScale("textlin");
+$graph->SetY2Scale('lin',0,100);
+$graph->img->SetMargin(50,70,30,40);
+$graph->yaxis->SetTitleMargin(30);
+$graph->SetMarginColor('#EEEEEE');
+
+// Setup titles and fonts
+$graph->title->Set("Frequence plot");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Turn the tickmarks
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+
+$graph->y2axis->SetTickSide(SIDE_RIGHT);
+$graph->y2axis->SetColor('black','blue');
+$graph->y2axis->SetLabelFormat('%3d.0%%');
+
+// Create a bar pot
+$bplot = new BarPlot($data_freq);
+
+// Create targets and alt texts for the image maps. One for each bar
+// (In this example this is just "dummy" targets)
+$targ=array("#1","#2","#3","#4","#5","#6","#7");
+$alts=array("val=%d","val=%d","val=%d","val=%d","val=%d","val=%d","val=%d");
+$bplot->SetCSIMTargets($targ,$alts);
+
+
+// Create accumulative graph
+$lplot = new LinePlot($data_accfreq);
+
+// We want the line plot data point in the middle of the bars
+$lplot->SetBarCenter();
+
+// Use transperancy
+$lplot->SetFillColor('lightblue@0.6');
+$lplot->SetColor('blue@0.6');
+//$lplot->SetColor('blue');
+$graph->AddY2($lplot);
+
+
+// Setup the bars
+$bplot->SetFillColor("orange@0.2");
+$bplot->SetValuePos('center');
+$bplot->value->SetFormat("%d");
+$bplot->value->SetFont(FF_ARIAL,FS_NORMAL,9);
+$bplot->value->Show();
+
+// Add it to the graph
+$graph->Add($bplot);
+
+// Send back the HTML page which will call this script again
+// to retrieve the image.
+$graph->StrokeCSIM();
+
+?>
diff --git a/web/classes/jpgraph/Examples/barlinefreqex1.php b/web/classes/jpgraph/Examples/barlinefreqex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..c5966bba07a59777f6ddc3813b5329878ba579b4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barlinefreqex1.php
@@ -0,0 +1,83 @@
+<?php // content="text/plain; charset=utf-8"
+//
+// Example of frequence bar 
+//
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Utility function to calculate the accumulated frequence
+// for a set of values and ocurrences
+function accfreq($data) {
+    rsort($data);
+    $s = array_sum($data);
+    $as = array($data[0]);
+    $asp = array(100*$as[0]/$s);
+    $n = count($data);
+    for( $i=1; $i < $n; ++$i ) {
+	$as[$i] = $as[$i-1]+$data[$i];
+	$asp[$i] = 100.0*$as[$i]/$s;
+    }
+    return $asp;
+}
+
+// some data
+$data_freq = array(22,20,12,10,5,4,2);
+$data_accfreq = accfreq($data_freq);
+
+// Create the graph. 
+$graph = new Graph(350,250);
+
+// Setup some basic graph parameters
+$graph->SetScale("textlin");
+$graph->SetY2Scale('lin',0,100);
+$graph->img->SetMargin(50,70,30,40);
+$graph->yaxis->SetTitleMargin(30);
+$graph->SetMarginColor('#EEEEEE');
+
+// Setup titles and fonts
+$graph->title->Set("Frequence plot");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Turn the tickmarks
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+
+$graph->y2axis->SetTickSide(SIDE_RIGHT);
+$graph->y2axis->SetColor('black','blue');
+$graph->y2axis->SetLabelFormat('%3d.0%%');
+
+// Create a bar pot
+$bplot = new BarPlot($data_freq);
+
+// Create accumulative graph
+$lplot = new LinePlot($data_accfreq);
+
+// We want the line plot data point in the middle of the bars
+$lplot->SetBarCenter();
+
+// Use transperancy
+$lplot->SetFillColor('lightblue@0.6');
+$lplot->SetColor('blue@0.6');
+$graph->AddY2($lplot);
+
+// Setup the bars
+$bplot->SetFillColor("orange@0.2");
+$bplot->SetValuePos('center');
+$bplot->value->SetFormat("%d");
+$bplot->value->SetFont(FF_ARIAL,FS_NORMAL,9);
+$bplot->value->Show();
+
+// Add it to the graph
+$graph->Add($bplot);
+
+// Send back the HTML page which will call this script again
+// to retrieve the image.
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/barpatternex1.php b/web/classes/jpgraph/Examples/barpatternex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..f0be38e1fd66ac130d6d92cc9421fd71cea6ea29
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barpatternex1.php
@@ -0,0 +1,33 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay=array(2,3,5,8.5,11.5,6,3);
+
+// Create the graph. 
+$graph = new Graph(350,300);	
+
+$graph->SetScale("textlin");
+
+$graph->SetMarginColor('navy:1.9');
+$graph->SetBox();
+
+$graph->title->Set('Bar Pattern');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,20);
+
+$graph->SetTitleBackground('lightblue:1.3',TITLEBKG_STYLE2,TITLEBKG_FRAME_BEVEL);
+$graph->SetTitleBackgroundFillStyle(TITLEBKG_FILLSTYLE_HSTRIPED,'lightblue','blue');
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor('darkorange');
+$bplot->SetWidth(0.6);
+
+$bplot->SetPattern(PATTERN_CROSS1,'navy');
+
+$graph->Add($bplot);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/barscalecallbackex1.php b/web/classes/jpgraph/Examples/barscalecallbackex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..7e73f201c8ce0b1b57c455cd17d986aedbe42cca
--- /dev/null
+++ b/web/classes/jpgraph/Examples/barscalecallbackex1.php
@@ -0,0 +1,63 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Callback function for Y-scale to get 1000 separator on labels
+function separator1000($aVal) {
+    return number_format($aVal);
+}
+
+function separator1000_usd($aVal) {
+    return '$'.number_format($aVal);
+}
+
+// Some data
+$datay=array(120567,134013,192000,87000);
+
+// Create the graph and setup the basic parameters
+$graph = new Graph(500,300,'auto');
+$graph->img->SetMargin(80,30,30,40);
+$graph->SetScale('textint');
+$graph->SetShadow();
+$graph->SetFrame(false); // No border around the graph
+
+// Add some grace to the top so that the scale doesn't
+// end exactly at the max value.
+// The grace value is the percetage of additional scale
+// value we add. Specifying 50 means that we add 50% of the
+// max value
+$graph->yaxis->scale->SetGrace(50);
+$graph->yaxis->SetLabelFormatCallback('separator1000');
+
+// Setup X-axis labels
+$a = $gDateLocale->GetShortMonth();
+$graph->xaxis->SetTickLabels($a);
+$graph->xaxis->SetFont(FF_FONT2);
+
+// Setup graph title ands fonts
+$graph->title->Set('Example of Y-scale callback formatting');
+$graph->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->xaxis->title->Set('Year 2002');
+$graph->xaxis->title->SetFont(FF_FONT2,FS_BOLD);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor('orange');
+$bplot->SetWidth(0.5);
+$bplot->SetShadow();
+
+// Setup the values that are displayed on top of each bar
+$bplot->value->Show();
+
+// Must use TTF fonts if we want text at an arbitrary angle
+$bplot->value->SetFont(FF_ARIAL,FS_BOLD);
+$bplot->value->SetAngle(45);
+$bplot->value->SetFormatCallback('separator1000_usd');
+
+// Black color for positive values and darkred for negative values
+$bplot->value->SetColor('black','darkred');
+$graph->Add($bplot);
+
+// Finally stroke the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/bartutex1.php b/web/classes/jpgraph/Examples/bartutex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..0c0f9c5116f35b9b0718dcc5628d046145d26676
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bartutex1.php
@@ -0,0 +1,35 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+$databary=array(12,7,16,5,7,14,9,3);
+
+// New graph with a drop shadow
+$graph = new Graph(300,200);
+$graph->SetShadow();
+
+// Use a "text" X-scale
+$graph->SetScale("textlin");
+
+// Set title and subtitle
+$graph->title->Set("Elementary barplot with a text scale");
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Create the bar plot
+$b1 = new BarPlot($databary);
+$b1->SetLegend("Temperature");
+//$b1->SetAbsWidth(6);
+//$b1->SetShadow();
+
+// The order the plots are added determines who's ontop
+$graph->Add($b1);
+
+// Finally output the  image
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/bartutex12.php b/web/classes/jpgraph/Examples/bartutex12.php
new file mode 100755
index 0000000000000000000000000000000000000000..6f97c5c64edbb89d3cbd42c7f4b7f4c9b405f098
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bartutex12.php
@@ -0,0 +1,90 @@
+<?php // content="text/plain; charset=utf-8"
+// A medium complex example of JpGraph
+// Note: You can create a graph in far fewwr lines of code if you are
+// willing to go with the defaults. This is an illustrative example of
+// some of the capabilities of JpGraph.
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$month=array(
+"Jan","Feb","Mar","Apr","Maj","Jun","Jul","Aug","Sep","Okt","Nov","Dec");
+
+// Create some datapoints 
+$steps=100;
+for($i=0; $i<$steps; ++$i) {
+	$databarx[]=sprintf("198%d %s",floor($i/12),$month[$i%12]);
+	$datay[$i]=log(pow($i,$i/10)+1)*sin($i/15)+35;
+	if( $i % 6 == 0 && $i<$steps-6) {
+		$databary[]=abs(25*sin($i)+5);
+	}
+	else {
+		$databary[]=0;
+	}
+}
+
+// New graph with a background image and drop shadow
+$graph = new Graph(450,300);
+$graph->SetBackgroundImage("tiger_bkg.png",BGIMG_FILLFRAME);
+$graph->SetShadow();
+
+// Use text X-scale so we can text labels on the X-axis
+$graph->SetScale("textlin");
+
+// Y2-axis is linear
+$graph->SetY2Scale("lin");
+
+// Color the two Y-axis to make them easier to associate
+// to the corresponding plot (we keep the axis black though)
+$graph->yaxis->SetColor("black","red");
+$graph->y2axis->SetColor("black","orange");
+
+// Set title and subtitle
+$graph->title->Set("Combined bar and line plot");
+$graph->subtitle->Set("100 data points, X-Scale: 'text'");
+
+// Use built in font (don't need TTF support)
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Make the margin around the plot a little bit bigger then default
+$graph->img->SetMargin(40,140,40,80);	
+
+// Slightly adjust the legend from it's default position in the
+// top right corner to middle right side
+$graph->legend->Pos(0.03,0.5,"right","center");
+
+// Display every 6:th tickmark
+$graph->xaxis->SetTextTickInterval(6);
+
+// Label every 2:nd tick mark
+$graph->xaxis->SetTextLabelInterval(2);
+
+// Setup the labels
+$graph->xaxis->SetTickLabels($databarx);
+$graph->xaxis->SetLabelAngle(90);
+
+// Create a red line plot
+$p1 = new LinePlot($datay);
+$p1->SetColor("red");
+$p1->SetLegend("Pressure");
+
+// Create the bar plot
+$b1 = new BarPlot($databary);
+$b1->SetLegend("Temperature");
+$b1->SetFillColor("orange");
+$b1->SetAbsWidth(8);
+
+// Drop shadow on bars adjust the default values a little bit
+$b1->SetShadow("steelblue",2,2);
+
+// The order the plots are added determines who's ontop
+$graph->Add($p1);
+$graph->AddY2($b1);
+
+// Finally output the  image
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/bartutex2.php b/web/classes/jpgraph/Examples/bartutex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..a911c337f6e0ae0a54a6112afad7d77219ef82d5
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bartutex2.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+$databary=array(12,7,16,6,7,14,9,3);
+$months=$gDateLocale->GetShortMonth();
+
+// New graph with a drop shadow
+$graph = new Graph(300,200,'auto');
+$graph->SetShadow();
+
+// Use a "text" X-scale
+$graph->SetScale("textlin");
+
+// Specify X-labels
+$graph->xaxis->SetTickLabels($months);
+
+// Set title and subtitle
+$graph->title->Set("Textscale with specified labels");
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Create the bar plot
+$b1 = new BarPlot($databary);
+$b1->SetLegend("Temperature");
+
+//$b1->SetAbsWidth(6);
+//$b1->SetShadow();
+
+// The order the plots are added determines who's ontop
+$graph->Add($b1);
+
+// Finally output the  image
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/bartutex3.php b/web/classes/jpgraph/Examples/bartutex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..addb91c4223c401e2c297350cb9698ca30e4dfb7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bartutex3.php
@@ -0,0 +1,44 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+$months=$gDateLocale->GetShortMonth();
+
+srand ((double) microtime() * 1000000);
+for( $i=0; $i<25; ++$i) {
+	$databary[]=rand(1,50);
+	$databarx[]=$months[$i%12];
+}
+	
+// New graph with a drop shadow
+$graph = new Graph(300,200,'auto');
+$graph->SetShadow();
+
+// Use a "text" X-scale
+$graph->SetScale("textlin");
+
+// Specify X-labels
+$graph->xaxis->SetTickLabels($databarx);
+
+// Set title and subtitle
+$graph->title->Set("Bar tutorial example 3");
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Create the bar plot
+$b1 = new BarPlot($databary);
+$b1->SetLegend("Temperature");
+//$b1->SetAbsWidth(6);
+//$b1->SetShadow();
+
+// The order the plots are added determines who's ontop
+$graph->Add($b1);
+
+// Finally output the  image
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/bartutex4.php b/web/classes/jpgraph/Examples/bartutex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..dffe16abec33d33ec4a4ab51a9c9f78cddae9226
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bartutex4.php
@@ -0,0 +1,47 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+$months=$gDateLocale->GetShortMonth();
+
+srand ((double) microtime() * 1000000);
+for( $i=0; $i<25; ++$i) {
+	$databary[]=rand(1,50);
+	$databarx[]=$months[$i%12];
+}
+	
+// New graph with a drop shadow
+$graph = new Graph(300,200,'auto');
+$graph->SetShadow();
+
+// Use a "text" X-scale
+$graph->SetScale("textlin");
+
+// Specify X-labels
+//$databarx = array('tXi','','','xxx','','','iXii','','','OOO','','','tOO');
+$graph->xaxis->SetFont(FF_FONT1,FS_NORMAL);
+$graph->xaxis->SetTickLabels($databarx);
+$graph->xaxis->SetTextLabelInterval(3);
+
+// Set title and subtitle
+$graph->title->Set("Displaying only every third label");
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Create the bar plot
+$b1 = new BarPlot($databary);
+$b1->SetLegend("Temperature");
+//$b1->SetAbsWidth(6);
+//$b1->SetShadow();
+
+// The order the plots are added determines who's ontop
+$graph->Add($b1);
+
+// Finally output the  image
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/bartutex5.php b/web/classes/jpgraph/Examples/bartutex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..e41a47b5f7884221e6586ae570c44e28346e1e50
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bartutex5.php
@@ -0,0 +1,45 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+$months=$gDateLocale->GetShortMonth();
+
+srand ((double) microtime() * 1000000);
+for( $i=0; $i<25; ++$i) {
+	$databary[]=rand(1,50);
+	$databarx[]=$months[$i%12];
+}
+	
+// New graph with a drop shadow
+$graph = new Graph(300,200,'auto');
+$graph->SetShadow();
+
+// Use a "text" X-scale
+$graph->SetScale("textlin");
+
+// Specify X-labels
+$graph->xaxis->SetTickLabels($databarx);
+$graph->xaxis->SetTextLabelInterval(1);
+$graph->xaxis->SetTextTickInterval(3);
+
+// Set title and subtitle
+$graph->title->Set("Bar tutorial example 5");
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Create the bar plot
+$b1 = new BarPlot($databary);
+$b1->SetLegend("Temperature");
+$b1->SetWidth(0.4);
+
+// The order the plots are added determines who's ontop
+$graph->Add($b1);
+
+// Finally output the  image
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/bartutex6.php b/web/classes/jpgraph/Examples/bartutex6.php
new file mode 100755
index 0000000000000000000000000000000000000000..13b0557f7453c01564072d565f8a6b69c0008e35
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bartutex6.php
@@ -0,0 +1,47 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+$months=$gDateLocale->GetShortMonth();
+srand ((double) microtime() * 1000000);
+for( $i=0; $i<25; ++$i) {
+	$databary[]=rand(1,50);
+	$databarx[]=$months[$i%12];
+}
+	
+// New graph with a drop shadow
+$graph = new Graph(300,200,'auto');
+$graph->SetShadow();
+
+// Use a "text" X-scale
+$graph->SetScale("textlin");
+
+// Specify X-labels
+$graph->xaxis->SetTickLabels($databarx);
+$graph->xaxis->SetTextLabelInterval(3);
+
+// Hide the tick marks
+$graph->xaxis->HideTicks();
+
+// Set title and subtitle
+$graph->title->Set("Bar tutorial example 6");
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Create the bar plot
+$b1 = new BarPlot($databary);
+$b1->SetLegend("Temperature");
+$b1->SetWidth(0.4);
+
+
+// The order the plots are added determines who's ontop
+$graph->Add($b1);
+
+// Finally output the  image
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/basic_contourex01.php b/web/classes/jpgraph/Examples/basic_contourex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..75d765a95d1f89bbfbbcb66fbc5a06fe8e834ff1
--- /dev/null
+++ b/web/classes/jpgraph/Examples/basic_contourex01.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+// Basic contour plot example
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contour.php');
+
+$data = array(
+            array (0.5,1.1,1.5,1,2.0,3,3,2,1,0.1),
+            array (1.0,1.5,3.0,5,6.0,2,1,1.2,1,4),
+            array (0.9,2.0,2.1,3,6.0,7,3,2,1,1.4),
+            array (1.0,1.5,3.0,4,6.0,5,2,1.5,1,2),
+            array (0.8,2.0,3.0,3,4.0,4,3,2.4,2,3),
+            array (0.6,1.1,1.5,1,4.0,3.5,3,2,3,4),
+            array (1.0,1.5,3.0,5,6.0,2,1,1.2,2.7,4),
+            array (0.8,2.0,3.0,3,5.5,6,3,2,1,1.4),
+            array (1.0,1.5,3.0,4,6.0,5,2,1,0.5,0.2));
+
+// Basic contour graph
+$graph = new Graph(350,250);
+$graph->SetScale('intint');
+
+// Adjust the margins to fit the margin
+$graph->SetMargin(30,100,40,30);
+
+// Setup
+$graph->title->Set('Basic contour plot');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+// A simple contour plot with default arguments (e.g. 10 isobar lines)
+$cp = new ContourPlot($data);
+
+// Display the legend
+$cp->ShowLegend();
+
+$graph->Add($cp);
+
+// ... and send the graph back to the browser
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/basic_contourex02.php b/web/classes/jpgraph/Examples/basic_contourex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..f63a650d89644874947ecf5f64bec433560e0df7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/basic_contourex02.php
@@ -0,0 +1,43 @@
+<?php // content="text/plain; charset=utf-8"
+// Basic contour plot example
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contour.php');
+
+$data = array(
+            array (0.5,1.1,1.5,1,2.0,3,3,2,1,0.1),
+            array (1.0,1.5,3.0,5,6.0,2,1,1.2,1,4),
+            array (0.9,2.0,2.1,3,6.0,7,3,2,1,1.4),
+            array (1.0,1.5,3.0,4,6.0,5,2,1.5,1,2),
+            array (0.8,2.0,3.0,3,4.0,4,3,2.4,2,3),
+            array (0.6,1.1,1.5,1,4.0,3.5,3,2,3,4),
+            array (1.0,1.5,3.0,5,6.0,2,1,1.2,2.7,4),
+            array (0.8,2.0,3.0,3,5.5,6,3,2,1,1.4),
+            array (1.0,1.5,3.0,4,6.0,5,2,1,0.5,0.2));
+
+// Basic contour graph
+$graph = new Graph(350,250);
+$graph->SetScale('intint');
+
+// Show axis on all sides
+$graph->SetAxisStyle(AXSTYLE_BOXOUT);
+
+// Adjust the margins to fit the margin
+$graph->SetMargin(30,100,40,30);
+
+// Setup
+$graph->title->Set('Basic contour plot with multiple axis');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+// A simple contour plot with default arguments (e.g. 10 isobar lines)
+$cp = new ContourPlot($data);
+
+// Display the legend
+$cp->ShowLegend();
+
+$graph->Add($cp);
+
+// ... and send the graph back to the browser
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/basic_contourex03-1.php b/web/classes/jpgraph/Examples/basic_contourex03-1.php
new file mode 100755
index 0000000000000000000000000000000000000000..26a01de6302b215369522adf3c62936b3b2b21d8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/basic_contourex03-1.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+// Basic contour plot example
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contour.php');
+
+$data = array(
+            array ( 12,7,3,15 ),
+            array ( 18,5,1, 9 ),
+            array ( 13,9,5,12),
+            array (  5,3,8, 9 ),
+            array (  1,8,5, 7 ));
+
+
+// Basic contour graph
+$graph = new Graph(350,250);
+$graph->SetScale('intint');
+
+// Show axis on all sides
+$graph->SetAxisStyle(AXSTYLE_BOXOUT);
+
+// Adjust the margins to fit the margin
+$graph->SetMargin(30,100,40,30);
+
+// Setup
+$graph->title->Set('Basic contour plot with multiple axis');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+// A simple contour plot with default arguments (e.g. 10 isobar lines)
+$cp = new ContourPlot($data,10,1);
+
+// Display the legend
+$cp->ShowLegend();
+
+$graph->Add($cp);
+
+// ... and send the graph back to the browser
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/basic_contourex03-2.php b/web/classes/jpgraph/Examples/basic_contourex03-2.php
new file mode 100755
index 0000000000000000000000000000000000000000..02b9376c778995c24ce43131addd9935dbe30735
--- /dev/null
+++ b/web/classes/jpgraph/Examples/basic_contourex03-2.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+// Basic contour plot example
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contour.php');
+
+$data = array(
+            array ( 12,7,3,15 ),
+            array ( 18,5,1, 9 ),
+            array ( 13,9,5,12),
+            array (  5,3,8, 9 ),
+            array (  1,8,5, 7 ));
+
+
+// Basic contour graph
+$graph = new Graph(350,250);
+$graph->SetScale('intint');
+
+// Show axis on all sides
+$graph->SetAxisStyle(AXSTYLE_BOXOUT);
+
+// Adjust the margins to fit the margin
+$graph->SetMargin(30,100,40,30);
+
+// Setup
+$graph->title->Set('Basic contour plot with multiple axis');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+// A simple contour plot with default arguments (e.g. 10 isobar lines)
+$cp = new ContourPlot($data,10,2);
+
+// Display the legend
+$cp->ShowLegend();
+
+$graph->Add($cp);
+
+// ... and send the graph back to the browser
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/basic_contourex03-3.php b/web/classes/jpgraph/Examples/basic_contourex03-3.php
new file mode 100755
index 0000000000000000000000000000000000000000..1de30b70a893605993f063f1dd18d0313b2fa80a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/basic_contourex03-3.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+// Basic contour plot example
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contour.php');
+
+$data = array(
+            array ( 12,7,3,15 ),
+            array ( 18,5,1, 9 ),
+            array ( 13,9,5,12),
+            array (  5,3,8, 9 ),
+            array (  1,8,5, 7 ));
+
+
+// Basic contour graph
+$graph = new Graph(350,250);
+$graph->SetScale('intint');
+
+// Show axis on all sides
+$graph->SetAxisStyle(AXSTYLE_BOXOUT);
+
+// Adjust the margins to fit the margin
+$graph->SetMargin(30,100,40,30);
+
+// Setup
+$graph->title->Set('Basic contour plot with multiple axis');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+// A simple contour plot with default arguments (e.g. 10 isobar lines)
+$cp = new ContourPlot($data,10,3);
+
+// Display the legend
+$cp->ShowLegend();
+
+$graph->Add($cp);
+
+// ... and send the graph back to the browser
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/basic_contourex04.php b/web/classes/jpgraph/Examples/basic_contourex04.php
new file mode 100755
index 0000000000000000000000000000000000000000..c32e83844aba41ee759fe9444aba64fbc51076bc
--- /dev/null
+++ b/web/classes/jpgraph/Examples/basic_contourex04.php
@@ -0,0 +1,43 @@
+<?php // content="text/plain; charset=utf-8"
+// Basic contour plot example
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contour.php');
+
+$data = array(
+            array (0.5,1.1,1.5,1,2.0,3,3,2,1,0.1),
+            array (1.0,1.5,3.0,5,6.0,2,1,1.2,1,4),
+            array (0.9,2.0,2.1,3,6.0,7,3,2,1,1.4),
+            array (1.0,1.5,3.0,4,6.0,5,2,1.5,1,2),
+            array (0.8,2.0,3.0,3,4.0,4,3,2.4,2,3),
+            array (0.6,1.1,1.5,1,4.0,3.5,3,2,3,4),
+            array (1.0,1.5,3.0,5,6.0,2,1,1.2,2.7,4),
+            array (0.8,2.0,3.0,3,5.5,6,3,2,1,1.4),
+            array (1.0,1.5,3.0,4,6.0,5,2,1,0.5,0.2));
+
+// Basic contour graph
+$graph = new Graph(350,250);
+$graph->SetScale('intint');
+
+// Show axis on all sides
+$graph->SetAxisStyle(AXSTYLE_BOXOUT);
+
+// Adjust the margins to fit the margin
+$graph->SetMargin(30,100,40,30);
+
+// Setup
+$graph->title->Set('Basic contour plot with multiple axis');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+// A simple contour plot with default arguments (e.g. 10 isobar lines)
+$cp = new ContourPlot($data,5);
+
+// Display the legend
+$cp->ShowLegend();
+
+$graph->Add($cp);
+
+// ... and send the graph back to the browser
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/basic_contourex05.php b/web/classes/jpgraph/Examples/basic_contourex05.php
new file mode 100755
index 0000000000000000000000000000000000000000..61936fce0125147b1ffc15e820b8fde39f2d5de2
--- /dev/null
+++ b/web/classes/jpgraph/Examples/basic_contourex05.php
@@ -0,0 +1,46 @@
+<?php // content="text/plain; charset=utf-8"
+// Basic contour plot example
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contour.php');
+
+$data = array(
+            array (0.5,1.1,1.5,1,2.0,3,3,2,1,0.1),
+            array (1.0,1.5,3.0,5,6.0,2,1,1.2,1,4),
+            array (0.9,2.0,2.1,3,6.0,7,3,2,1,1.4),
+            array (1.0,1.5,3.0,4,6.0,5,2,1.5,1,2),
+            array (0.8,2.0,3.0,3,4.0,4,3,2.4,2,3),
+            array (0.6,1.1,1.5,1,4.0,3.5,3,2,3,4),
+            array (1.0,1.5,3.0,5,6.0,2,1,1.2,2.7,4),
+            array (0.8,2.0,3.0,3,5.5,6,3,2,1,1.4),
+            array (1.0,1.5,3.0,4,6.0,5,2,1,0.5,0.2));
+
+// Basic contour graph
+$graph = new Graph(350,250);
+$graph->SetScale('intint');
+
+// Show axis on all sides
+$graph->SetAxisStyle(AXSTYLE_BOXOUT);
+
+// Adjust the margins to fit the margin
+$graph->SetMargin(30,100,40,30);
+
+// Setup
+$graph->title->Set('Basic contour plot with multiple axis');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+// A simple contour plot with default arguments (e.g. 10 isobar lines)
+$cp = new ContourPlot($data);
+
+// Flip the data around its center line
+$cp->SetInvert();
+
+// Display the legend
+$cp->ShowLegend();
+
+$graph->Add($cp);
+
+// ... and send the graph back to the browser
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/bezierex1.php b/web/classes/jpgraph/Examples/bezierex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..50fad510e9d958e717a2adccbe58e9118073d4d2
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bezierex1.php
@@ -0,0 +1,54 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+require_once ('jpgraph/jpgraph_regstat.php');
+
+// Original data points
+$xdata = array(1,3,12,15);
+$ydata = array(5,15,2,19);
+
+// Get the interpolated values by creating
+// a new Spline object.
+$bez = new Bezier($xdata,$ydata);
+
+// For the new data set we want 40 points to
+// get a smooth curve.
+list($newx,$newy) = $bez->Get(50);
+
+// Create the graph
+$g = new Graph(300,200);
+$g->SetMargin(30,20,40,30);
+$g->title->Set("Bezier interpolation");
+$g->title->SetFont(FF_ARIAL,FS_NORMAL,12);
+$g->subtitle->Set('(Control points shown in red)');
+$g->subtitle->SetColor('darkred');
+$g->SetMarginColor('lightblue');
+
+//$g->img->SetAntiAliasing();
+
+// We need a linlin scale since we provide both
+// x and y coordinates for the data points.
+$g->SetScale('linlin');
+
+// We want 1 decimal for the X-label
+$g->xaxis->SetLabelFormat('%1.1f');
+
+// We use a scatterplot to illustrate the original
+// contro points.
+$bplot = new ScatterPlot($ydata,$xdata);
+$bplot->mark->SetFillColor('red@0.3');
+$bplot->mark->SetColor('red@0.5');
+
+// And a line plot to stroke the smooth curve we got
+// from the original control points
+$lplot = new LinePlot($newy,$newx);
+$lplot->SetColor('navy');
+
+// Add the plots to the graph and stroke
+$g->Add($lplot);
+$g->Add($bplot);
+$g->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/bkgimgflagex1.php b/web/classes/jpgraph/Examples/bkgimgflagex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..1e47938397a150b7c23336b2e67506ecf843a371
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bkgimgflagex1.php
@@ -0,0 +1,79 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_flags.php');
+
+// Some data
+$datay1=array(140,110,50);
+$datay2=array(35,90,190);
+$datay3=array(20,60,70);
+
+// Create the basic graph
+$graph = new Graph(300,200);	
+$graph->SetScale('textlin');
+$graph->SetMargin(40,20,20,40);
+$graph->SetMarginColor('white:0.9');
+$graph->SetColor('white');
+$graph->SetShadow();
+
+// Adjust the position of the legend box
+$graph->legend->Pos(0.03,0.10);
+
+// Adjust the color for theshadow of the legend
+$graph->legend->SetShadow('darkgray@0.5');
+$graph->legend->SetFillColor('lightblue@0.1');
+$graph->legend->Hide();
+
+// Get localised version of the month names
+$graph->xaxis->SetTickLabels($gDateLocale->GetShortMonth());
+$graph->SetBackgroundCountryFlag('mais',BGIMG_COPY,50);
+
+// Set axis titles and fonts
+$graph->xaxis->title->Set('Year 2002');
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetColor('white');
+
+$graph->xaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->SetColor('navy');
+
+$graph->yaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->SetColor('navy');
+
+//$graph->ygrid->Show(false);
+$graph->ygrid->SetColor('white@0.5');
+
+// Setup graph title
+$graph->title->Set('Using a country flag background');
+
+// Some extra margin (from the top)
+$graph->title->SetMargin(3);
+$graph->title->SetFont(FF_ARIAL,FS_NORMAL,12);
+
+// Create the three var series we will combine
+$bplot1 = new BarPlot($datay1);
+$bplot2 = new BarPlot($datay2);
+$bplot3 = new BarPlot($datay3);
+
+// Setup the colors with 40% transparency (alpha channel)
+$bplot1->SetFillColor('yellow@0.4');
+$bplot2->SetFillColor('red@0.4');
+$bplot3->SetFillColor('darkgreen@0.4');
+
+// Setup legends
+$bplot1->SetLegend('Label 1');
+$bplot2->SetLegend('Label 2');
+$bplot3->SetLegend('Label 3');
+
+// Setup each bar with a shadow of 50% transparency
+$bplot1->SetShadow('black@0.4');
+$bplot2->SetShadow('black@0.4');
+$bplot3->SetShadow('black@0.4');
+
+$gbarplot = new GroupBarPlot(array($bplot1,$bplot2,$bplot3));
+$gbarplot->SetWidth(0.6);
+$graph->Add($gbarplot);
+
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/bkgimgflagex2.php b/web/classes/jpgraph/Examples/bkgimgflagex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..c6a27b3d8947831c41859d33b65e0fef6fc64acf
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bkgimgflagex2.php
@@ -0,0 +1,83 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_flags.php');
+
+// Some data
+$datay1=array(140,110,50);
+$datay2=array(35,90,190);
+$datay3=array(20,60,70);
+
+// Create the basic graph
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+$graph->SetMargin(40,20,20,40);
+$graph->SetMarginColor('white:0.9');
+$graph->SetColor('white');
+$graph->SetShadow();
+
+// Apply a perspective transformation at the end 
+$graph->Set3DPerspective(SKEW3D_UP,100,180);
+
+// Adjust the position of the legend box
+$graph->legend->Pos(0.03,0.10);
+
+// Adjust the color for theshadow of the legend
+$graph->legend->SetShadow('darkgray@0.5');
+$graph->legend->SetFillColor('lightblue@0.1');
+$graph->legend->Hide();
+
+// Get localised version of the month names
+$graph->xaxis->SetTickLabels($gDateLocale->GetShortMonth());
+
+$graph->SetBackgroundCountryFlag('mais',BGIMG_COPY,50);
+
+// Set axis titles and fonts
+$graph->xaxis->title->Set('Year 2002');
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetColor('white');
+
+$graph->xaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->SetColor('navy');
+
+$graph->yaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->SetColor('navy');
+
+//$graph->ygrid->Show(false);
+$graph->ygrid->SetColor('white@0.5');
+
+// Setup graph title
+$graph->title->Set('Using a country flag background');
+
+// Some extra margin (from the top)
+$graph->title->SetMargin(3);
+$graph->title->SetFont(FF_ARIAL,FS_NORMAL,12);
+
+// Create the three var series we will combine
+$bplot1 = new BarPlot($datay1);
+$bplot2 = new BarPlot($datay2);
+$bplot3 = new BarPlot($datay3);
+
+// Setup the colors with 40% transparency (alpha channel)
+$bplot1->SetFillColor('yellow@0.4');
+$bplot2->SetFillColor('red@0.4');
+$bplot3->SetFillColor('darkgreen@0.4');
+
+// Setup legends
+$bplot1->SetLegend('Label 1');
+$bplot2->SetLegend('Label 2');
+$bplot3->SetLegend('Label 3');
+
+// Setup each bar with a shadow of 50% transparency
+$bplot1->SetShadow('black@0.4');
+$bplot2->SetShadow('black@0.4');
+$bplot3->SetShadow('black@0.4');
+
+$gbarplot = new GroupBarPlot(array($bplot1,$bplot2,$bplot3));
+$gbarplot->SetWidth(0.6);
+$graph->Add($gbarplot);
+
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/bkgimgflagex3.php b/web/classes/jpgraph/Examples/bkgimgflagex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..be9afb73aa19e4b556f3c18474f2cb5feea88851
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bkgimgflagex3.php
@@ -0,0 +1,83 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_flags.php');
+
+// Some data
+$datay1=array(140,110,50);
+$datay2=array(35,90,190);
+$datay3=array(20,60,70);
+
+// Create the basic graph
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+$graph->SetMargin(40,20,20,40);
+$graph->SetMarginColor('white:0.9');
+$graph->SetColor('white');
+$graph->SetShadow();
+
+// Apply a perspective transformation at the end 
+$graph->Set3DPerspective(SKEW3D_DOWN,100,180);
+
+// Adjust the position of the legend box
+$graph->legend->Pos(0.03,0.10);
+
+// Adjust the color for theshadow of the legend
+$graph->legend->SetShadow('darkgray@0.5');
+$graph->legend->SetFillColor('lightblue@0.1');
+$graph->legend->Hide();
+
+// Get localised version of the month names
+$graph->xaxis->SetTickLabels($gDateLocale->GetShortMonth());
+
+$graph->SetBackgroundCountryFlag('mais',BGIMG_COPY,50);
+
+// Set axis titles and fonts
+$graph->xaxis->title->Set('Year 2002');
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetColor('white');
+
+$graph->xaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->SetColor('navy');
+
+$graph->yaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->SetColor('navy');
+
+//$graph->ygrid->Show(false);
+$graph->ygrid->SetColor('white@0.5');
+
+// Setup graph title
+$graph->title->Set('Using a country flag background');
+
+// Some extra margin (from the top)
+$graph->title->SetMargin(3);
+$graph->title->SetFont(FF_ARIAL,FS_NORMAL,12);
+
+// Create the three var series we will combine
+$bplot1 = new BarPlot($datay1);
+$bplot2 = new BarPlot($datay2);
+$bplot3 = new BarPlot($datay3);
+
+// Setup the colors with 40% transparency (alpha channel)
+$bplot1->SetFillColor('yellow@0.4');
+$bplot2->SetFillColor('red@0.4');
+$bplot3->SetFillColor('darkgreen@0.4');
+
+// Setup legends
+$bplot1->SetLegend('Label 1');
+$bplot2->SetLegend('Label 2');
+$bplot3->SetLegend('Label 3');
+
+// Setup each bar with a shadow of 50% transparency
+$bplot1->SetShadow('black@0.4');
+$bplot2->SetShadow('black@0.4');
+$bplot3->SetShadow('black@0.4');
+
+$gbarplot = new GroupBarPlot(array($bplot1,$bplot2,$bplot3));
+$gbarplot->SetWidth(0.6);
+$graph->Add($gbarplot);
+
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/bkgimgflagex4.php b/web/classes/jpgraph/Examples/bkgimgflagex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..d7db486a70e19255e42a72dbeec227b0edd49db3
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bkgimgflagex4.php
@@ -0,0 +1,83 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_flags.php');
+
+// Some data
+$datay1=array(140,110,50);
+$datay2=array(35,90,190);
+$datay3=array(20,60,70);
+
+// Create the basic graph
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+$graph->SetMargin(40,20,20,40);
+$graph->SetMarginColor('white:0.9');
+$graph->SetColor('white');
+$graph->SetShadow();
+
+// Apply a perspective transformation at the end 
+$graph->Set3DPerspective(SKEW3D_LEFT,350,320,true);
+
+// Adjust the position of the legend box
+$graph->legend->Pos(0.03,0.10);
+
+// Adjust the color for theshadow of the legend
+$graph->legend->SetShadow('darkgray@0.5');
+$graph->legend->SetFillColor('lightblue@0.1');
+$graph->legend->Hide();
+
+// Get localised version of the month names
+$graph->xaxis->SetTickLabels($gDateLocale->GetShortMonth());
+
+$graph->SetBackgroundCountryFlag('mais',BGIMG_COPY,50);
+
+// Set axis titles and fonts
+$graph->xaxis->title->Set('Year 2002');
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetColor('white');
+
+$graph->xaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->SetColor('navy');
+
+$graph->yaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->SetColor('navy');
+
+//$graph->ygrid->Show(false);
+$graph->ygrid->SetColor('white@0.5');
+
+// Setup graph title
+$graph->title->Set('Using a country flag background');
+
+// Some extra margin (from the top)
+$graph->title->SetMargin(3);
+$graph->title->SetFont(FF_ARIAL,FS_NORMAL,12);
+
+// Create the three var series we will combine
+$bplot1 = new BarPlot($datay1);
+$bplot2 = new BarPlot($datay2);
+$bplot3 = new BarPlot($datay3);
+
+// Setup the colors with 40% transparency (alpha channel)
+$bplot1->SetFillColor('yellow@0.4');
+$bplot2->SetFillColor('red@0.4');
+$bplot3->SetFillColor('darkgreen@0.4');
+
+// Setup legends
+$bplot1->SetLegend('Label 1');
+$bplot2->SetLegend('Label 2');
+$bplot3->SetLegend('Label 3');
+
+// Setup each bar with a shadow of 50% transparency
+$bplot1->SetShadow('black@0.4');
+$bplot2->SetShadow('black@0.4');
+$bplot3->SetShadow('black@0.4');
+
+$gbarplot = new GroupBarPlot(array($bplot1,$bplot2,$bplot3));
+$gbarplot->SetWidth(0.6);
+$graph->Add($gbarplot);
+
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/bkgimgflagex5.php b/web/classes/jpgraph/Examples/bkgimgflagex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..f45a85a019424542ec426aa05859dd6fc29325f5
--- /dev/null
+++ b/web/classes/jpgraph/Examples/bkgimgflagex5.php
@@ -0,0 +1,83 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_flags.php');
+
+// Some data
+$datay1=array(140,110,50);
+$datay2=array(35,90,190);
+$datay3=array(20,60,70);
+
+// Create the basic graph
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+$graph->SetMargin(40,20,20,40);
+$graph->SetMarginColor('white:0.9');
+$graph->SetColor('white');
+$graph->SetShadow();
+
+// Apply a perspective transformation at the end 
+$graph->Set3DPerspective(SKEW3D_RIGHT,350,320,true);
+
+// Adjust the position of the legend box
+$graph->legend->Pos(0.03,0.10);
+
+// Adjust the color for theshadow of the legend
+$graph->legend->SetShadow('darkgray@0.5');
+$graph->legend->SetFillColor('lightblue@0.1');
+$graph->legend->Hide();
+
+// Get localised version of the month names
+$graph->xaxis->SetTickLabels($gDateLocale->GetShortMonth());
+
+$graph->SetBackgroundCountryFlag('mais',BGIMG_COPY,50);
+
+// Set axis titles and fonts
+$graph->xaxis->title->Set('Year 2002');
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetColor('white');
+
+$graph->xaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->SetColor('navy');
+
+$graph->yaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->SetColor('navy');
+
+//$graph->ygrid->Show(false);
+$graph->ygrid->SetColor('white@0.5');
+
+// Setup graph title
+$graph->title->Set('Using a country flag background');
+
+// Some extra margin (from the top)
+$graph->title->SetMargin(3);
+$graph->title->SetFont(FF_ARIAL,FS_NORMAL,12);
+
+// Create the three var series we will combine
+$bplot1 = new BarPlot($datay1);
+$bplot2 = new BarPlot($datay2);
+$bplot3 = new BarPlot($datay3);
+
+// Setup the colors with 40% transparency (alpha channel)
+$bplot1->SetFillColor('yellow@0.4');
+$bplot2->SetFillColor('red@0.4');
+$bplot3->SetFillColor('darkgreen@0.4');
+
+// Setup legends
+$bplot1->SetLegend('Label 1');
+$bplot2->SetLegend('Label 2');
+$bplot3->SetLegend('Label 3');
+
+// Setup each bar with a shadow of 50% transparency
+$bplot1->SetShadow('black@0.4');
+$bplot2->SetShadow('black@0.4');
+$bplot3->SetShadow('black@0.4');
+
+$gbarplot = new GroupBarPlot(array($bplot1,$bplot2,$bplot3));
+$gbarplot->SetWidth(0.6);
+$graph->Add($gbarplot);
+
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/blueblack400x300grad.png b/web/classes/jpgraph/Examples/blueblack400x300grad.png
new file mode 100755
index 0000000000000000000000000000000000000000..8852862a747ba6df7a8e68c546535f0659ee714f
Binary files /dev/null and b/web/classes/jpgraph/Examples/blueblack400x300grad.png differ
diff --git a/web/classes/jpgraph/Examples/boxstockcsimex1.php b/web/classes/jpgraph/Examples/boxstockcsimex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..1cb765d3c974a72227cd2babf8de4c2c6d422e1e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/boxstockcsimex1.php
@@ -0,0 +1,37 @@
+<?php // content="text/plain; charset=utf-8"
+// Example of a stock chart
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_stock.php');
+
+// Data must be in the format : open,close,min,max,median
+$datay = array(
+    34,42,27,45,36,
+    55,25,14,59,40,
+    15,40,12,47,23,
+    62,38,25,65,57,
+    38,49,32,64,45);
+
+// Setup a simple graph
+$graph = new Graph(300,200);
+$graph->SetScale("textlin");
+$graph->SetMarginColor('lightblue');
+$graph->title->Set('Box Stock chart example');
+
+// Create a new stock plot
+$p1 = new BoxPlot($datay);
+
+// Setup URL target for image map
+$p1->SetCSIMTargets(array('#1','#2','#3','#4','#5'));
+
+// Width of the bars (in pixels)
+$p1->SetWidth(9);
+
+//$p1->SetCenter();
+// Uncomment the following line to hide the horizontal end lines
+//$p1->HideEndLines();
+
+// Add the plot to the graph and send it back to the browser
+$graph->Add($p1);
+$graph->StrokeCSIM();
+
+?>
diff --git a/web/classes/jpgraph/Examples/boxstockex1.php b/web/classes/jpgraph/Examples/boxstockex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..4e09833ee43b7d28ddce06ed72dbfa270ae1eeca
--- /dev/null
+++ b/web/classes/jpgraph/Examples/boxstockex1.php
@@ -0,0 +1,33 @@
+<?php // content="text/plain; charset=utf-8"
+// Example of a stock chart
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_stock.php');
+
+// Data must be in the format : open,close,min,max,median
+$datay = array(
+    34,42,27,45,36,
+    55,25,14,59,40,
+    15,40,12,47,23,
+    62,38,25,65,57,
+    38,49,32,64,45);
+
+// Setup a simple graph
+$graph = new Graph(300,200);
+$graph->SetScale('textlin');
+$graph->SetMarginColor('lightblue');
+$graph->title->Set('Box Stock chart example');
+
+// Create a new stock plot
+$p1 = new BoxPlot($datay);
+
+// Width of the bars (in pixels)
+$p1->SetWidth(9);
+
+// Uncomment the following line to hide the horizontal end lines
+//$p1->HideEndLines();
+
+// Add the plot to the graph and send it back to the browser
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/boxstockex2.php b/web/classes/jpgraph/Examples/boxstockex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..d3531f483a38330888fa94020730d7b2a9790300
--- /dev/null
+++ b/web/classes/jpgraph/Examples/boxstockex2.php
@@ -0,0 +1,38 @@
+<?php // content="text/plain; charset=utf-8"
+// Example of a stock chart
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_stock.php');
+
+// Data must be in the format : open,close,min,max,median
+$datay = array(
+    34,42,27,45,36,
+    55,25,14,59,40,
+    15,40,12,47,23,
+    62,38,25,65,57,
+    38,49,32,64,45);
+
+// Setup a simple graph
+$graph = new Graph(300,200);
+$graph->SetScale("textlin");
+$graph->SetMarginColor('lightblue');
+$graph->title->Set('Box Stock chart example');
+$graph->subtitle->Set('(Indented X-axis)');
+
+// Create a new stock plot
+$p1 = new BoxPlot($datay);
+
+// Width of the bars (in pixels)
+$p1->SetWidth(9);
+
+// Indent bars so they dont start and end at the edge of the
+// plot area
+$p1->SetCenter();
+
+// Uncomment the following line to hide the horizontal end lines
+//$p1->HideEndLines();
+
+// Add the plot to the graph and send it back to the browser
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/builtinplotmarksex1.php b/web/classes/jpgraph/Examples/builtinplotmarksex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..5d265facd2d99e050d7900c8075adebc18d57461
--- /dev/null
+++ b/web/classes/jpgraph/Examples/builtinplotmarksex1.php
@@ -0,0 +1,66 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_plotline.php');
+
+$datay1 = array(2,6,7,12,13,18);
+$datay2 = array(5,12,12,19,25,20);
+
+// Setup the graph
+$graph = new Graph(350,200);
+$graph->SetMargin(30,20,60,20);
+$graph->SetMarginColor('white');
+$graph->SetScale("linlin");
+
+// Hide the frame around the graph
+$graph->SetFrame(false);
+
+// Setup title
+$graph->title->Set("Using Builtin PlotMarks");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,14);
+
+// Note: requires jpgraph 1.12p or higher
+// $graph->SetBackgroundGradient('blue','navy:0.5',GRAD_HOR,BGRAD_PLOT);
+$graph->tabtitle->Set('Region 1' );
+$graph->tabtitle->SetWidth(TABTITLE_WIDTHFULL);
+
+// Enable X and Y Grid
+$graph->xgrid->Show();
+$graph->xgrid->SetColor('gray@0.5');
+$graph->ygrid->SetColor('gray@0.5');
+
+// Format the legend box
+$graph->legend->SetColor('navy');
+$graph->legend->SetFillColor('lightgreen');
+$graph->legend->SetLineWeight(1);
+$graph->legend->SetFont(FF_ARIAL,FS_BOLD,8);
+$graph->legend->SetShadow('gray@0.4',3);
+$graph->legend->SetAbsPos(15,120,'right','bottom');
+
+// Create the line plots
+
+$p1 = new LinePlot($datay1);
+$p1->SetColor("red");
+$p1->SetFillColor("yellow@0.5");
+$p1->SetWeight(2);
+$p1->mark->SetType(MARK_IMG_DIAMOND,5,0.6);
+$p1->SetLegend('2006');
+$graph->Add($p1);
+
+$p2 = new LinePlot($datay2);
+$p2->SetColor("darkgreen");
+$p2->SetWeight(2);
+$p2->SetLegend('2001');
+$p2->mark->SetType(MARK_IMG_MBALL,'red');
+$graph->Add($p2);
+
+// Add a vertical line at the end scale position '7'
+$l1 = new PlotLine(VERTICAL,7);
+$graph->Add($l1);
+
+// Output the graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/canvas_jpgarchex.php b/web/classes/jpgraph/Examples/canvas_jpgarchex.php
new file mode 100755
index 0000000000000000000000000000000000000000..a67c0cbe8784f232120ab7050e1d710d0945710c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/canvas_jpgarchex.php
@@ -0,0 +1,143 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: canvas_jpgarchex.php,v 1.3 2002/08/29 10:14:19 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_canvtools.php');
+
+// Scale we are using
+$ymax=24;
+$xmax=20;
+
+// Setup the basic canvas
+$g = new CanvasGraph(700,650,'auto');
+$g->SetMargin(2,3,2,3);
+$g->SetMarginColor("teal");
+$g->InitFrame();
+
+// ... and a scale
+$scale = new CanvasScale($g);
+$scale->Set(0,$xmax,0,$ymax);
+
+// ... we need shape since we want the indented rectangle
+$shape = new Shape($g,$scale);
+$shape->SetColor('black');
+
+// ... basic parameters for the overall image
+$l = 2;		// Left margin
+$r = 18;	// Row number to start the lowest line on
+$width = 16;	// Total width
+
+// Setup the two basic rectangle text object we  will use
+$tt = new CanvasRectangleText();
+$tt->SetFont(FF_ARIAL,FS_NORMAL,14);
+$tt->SetFillColor('');
+$tt->SetColor('');
+$tt->SetFontColor('navy');
+
+$t = new CanvasRectangleText();
+$t->SetFont(FF_ARIAL,FS_NORMAL,14);
+$t->SetFillColor('goldenrod1');
+$t->SetFontColor('navy');
+
+
+// Now start drawing the arch overview from the bottom and up
+// This is all pretty manual and one day I will write a proper
+// framework to make it easy to construct these types of architecture
+// overviews. But for now, just plain old coordinates..
+
+// Line: GD Library and image libraries
+$h=3;
+$s  = 3; $d=$l + $width-9;
+$t->SetFillColor('cadetblue3');
+$t->Set("TTF",$d,$r+2,$s,1);
+$t->Stroke($g->img,$scale);
+$t->Set("PNG",$d+$s,$r+2,$s,1);
+$t->Stroke($g->img,$scale);
+$t->Set("JPEG",$d+2*$s,$r+2,$s,1);
+$t->Stroke($g->img,$scale);
+$shape->IndentedRectangle($l,$r,$width,$h,$s*3,1,2,'lightgreen');
+$tt->Set("GD Basic library\n(1.8.x or 2.x)",$l,$r,$width,$h-1); 
+$tt->Stroke($g->img,$scale);
+
+
+// Area: Basic internal JpGraph architecture
+$t->SetFillColor('goldenrod1');
+$h = 2;
+$r -= $h; $d=8;
+$t->Set("Image primitives\n(RGB, Anti-aliasing,\nGD Abstraction)",$l,$r-0.5,$width*0.5,$h+0.5);
+$t->Stroke($g->img,$scale);
+$t->Set("Image Cache &\nStreaming",$l+0.5*$width,$r,$width*0.4,$h);
+$t->Stroke($g->img,$scale);
+
+$r -= $h; $d=8;
+$t->Set("2D Rot & Transformation",$l,$r,$width*0.5,$h-0.5); $t->Stroke($g->img,$scale);
+
+
+$r -= 2; $h = 4;
+$shape->IndentedRectangle($l,$r,$width*0.9,$h,$d,2,3,'goldenrod1');
+$tt->Set("Axis, Labelling, (Auto)-Scaling",$l,$r,$width*0.9,$h-2); $tt->Stroke($g->img,$scale);
+
+$r -= 1;
+$shape->IndentedRectangle($l,$r,$width,7,$width*0.9,6,3,'goldenrod1');
+$tt->Set("Error handling & Utility classes",$l,$r,$width,1); $tt->Stroke($g->img,$scale);
+
+
+// Area: Top area with graph components
+$t->SetFillColor('gold1');
+$r -= 3;
+$w = $width*0.55/4; $h = 2;
+$t->Set("Gantt\nGraph",$l,$r,$w,$h);
+$t->Stroke($g->img,$scale);
+
+$t->Set("Pie\nGraph",$l+$w,$r,$w,$h);
+$t->Stroke($g->img,$scale);
+$t->Set("Radar\nGraph",$l+$w*2,$r,$w,$h);
+$t->Stroke($g->img,$scale);
+
+$shape->IndentedRectangle($l,$r,$width,3,4*$w,2,0,'gold1');
+$tt->Set("Base Graph\n(Orthogonal\ncoordinate system)",$l+4*$w,$r,$width-$w*4,3); 
+$tt->Stroke($g->img,$scale);
+
+$r -= 2;
+$d = 0.7;
+$shape->IndentedRectangle($l+3*$w,$r,$w,4, $w*$d,2,0,'gold1');
+$t->Set("Canv\nUtil",$l+3*$w,$r,$w*$d,$h);     $t->Stroke($g->img,$scale);
+$tt->Set("Canvas\nGraph",$l+3*$w,$r+2,$w,2); $tt->Stroke($g->img,$scale);
+
+// Top line of plotting plugins
+$t->SetFillColor('cyan');
+$t->Set("Gantt\nPlot",$l,$r,$w,$h); $t->Stroke($g->img,$scale);
+$t->Set("2D\nPlot",$l+$w,$r,$w/2,$h);     $t->Stroke($g->img,$scale);
+$t->Set("3D\nPlot",$l+$w+$w/2,$r,$w/2,$h);$t->Stroke($g->img,$scale);
+$t->Set("Radar\nPlot",$l+2*$w,$r,$w,$h); $t->Stroke($g->img,$scale);
+
+$wp = ($width - 4*$w)/4; 
+$t->Set("Error\nPlot",$l+4*$w,$r,$wp,$h); $t->Stroke($g->img,$scale);
+$t->Set("Line\nPlot",$l+4*$w+$wp,$r,$wp,$h); $t->Stroke($g->img,$scale);
+$t->Set("Bar\nPlot",$l+4*$w+2*$wp,$r,$wp,$h); $t->Stroke($g->img,$scale);
+$t->Set("Scatter\nPlot",$l+4*$w+3*$wp,$r,$wp,$h); $t->Stroke($g->img,$scale);
+
+// Show application top
+$r -= 2.5; $h=2; 
+$t->SetFillColor('blue');
+$t->SetFontColor('white');
+$t->SetFont(FF_ARIAL,FS_BOLD,20);
+$t->Set("PHP Application",$l,$r,$width,$h); $t->Stroke($g->img,$scale);
+
+// Stroke title
+$r = 0.5;
+$tt->SetFontColor('black');
+$tt->SetFont(FF_TIMES,FS_BOLD,28);
+$tt->Set("JpGraph Architecture Overview",$l,$r,$width,1); 
+$tt->Stroke($g->img,$scale);
+
+// Stroke footer
+$tt->SetFont(FF_VERDANA,FS_NORMAL,10);
+$tt->Set("Generated: ".date("ymd H:m",time()),0.1,$ymax*0.95); 
+$tt->Stroke($g->img,$scale);
+
+// .. and stream it all back
+$g->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/canvasbezierex1.php b/web/classes/jpgraph/Examples/canvasbezierex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..36febdf5158a179e490d13c11127dae9eb8f41d5
--- /dev/null
+++ b/web/classes/jpgraph/Examples/canvasbezierex1.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: canvasbezierex1.php,v 1.1 2002/10/05 21:04:28 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_canvtools.php');
+
+// Setup canvas graph
+$g = new CanvasGraph(400,300);
+$scale = new CanvasScale($g);
+$shape = new Shape($g,$scale);
+
+$g->title->Set('Bezier line with control points');
+
+// Setup control point for bezier
+$p = array(3,6,
+	   6,9,
+	   5,3,
+	   7,4);
+
+// Visualize control points
+$shape->SetColor('blue');
+$shape->Line($p[0],$p[1],$p[2],$p[3]);
+$shape->FilledCircle($p[2],$p[3],-6);
+
+$shape->SetColor('red');
+$shape->Line($p[4],$p[5],$p[6],$p[7]);
+$shape->FilledCircle($p[4],$p[5],-6);
+
+// Draw bezier
+$shape->SetColor('black');
+$shape->Bezier($p);
+
+// Frame it with a square
+$shape->SetColor('navy');
+$shape->Rectangle(0.5,2,9.5,9.5);
+
+// ... and stroke it
+$g->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/canvasex01.php b/web/classes/jpgraph/Examples/canvasex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..68839155feb34925df2d54b6dbd0bbd1141c588a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/canvasex01.php
@@ -0,0 +1,37 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: canvasex01.php,v 1.3 2002/10/23 08:17:23 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+
+// Setup a basic canvas we can work 
+$g = new CanvasGraph(400,300,'auto');
+$g->SetMargin(5,11,6,11);
+$g->SetShadow();
+$g->SetMarginColor("teal");
+
+// We need to stroke the plotarea and margin before we add the
+// text since we otherwise would overwrite the text.
+$g->InitFrame();
+
+// Draw a text box in the middle
+$txt="This\nis\na TEXT!!!";
+$t = new Text($txt,200,10);
+$t->SetFont(FF_ARIAL,FS_BOLD,40);
+
+// How should the text box interpret the coordinates?
+$t->Align('center','top');
+
+// How should the paragraph be aligned?
+$t->ParagraphAlign('center');
+
+// Add a box around the text, white fill, black border and gray shadow
+$t->SetBox("white","black","gray");
+
+// Stroke the text
+$t->Stroke($g->img);
+
+// Stroke the graph
+$g->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/canvasex02.php b/web/classes/jpgraph/Examples/canvasex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..20807622334644c344dff3c279137297f6b7fe78
--- /dev/null
+++ b/web/classes/jpgraph/Examples/canvasex02.php
@@ -0,0 +1,42 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: canvasex02.php,v 1.1 2002/08/27 20:08:57 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+
+// Setup a basic canvas we can work 
+$g = new CanvasGraph(400,200,'auto');
+$g->SetMargin(5,11,6,11);
+$g->SetShadow();
+$g->SetMarginColor("teal");
+
+// We need to stroke the plotarea and margin before we add the
+// text since we otherwise would overwrite the text.
+$g->InitFrame();
+
+// Add a black line
+$g->img->SetColor('black');
+$g->img->Line(0,0,100,100);
+
+// .. and a circle (x,y,diameter)
+$g->img->Circle(100,100,50);
+
+// .. and a filled circle (x,y,diameter)
+$g->img->SetColor('red');
+$g->img->FilledCircle(200,100,50);
+
+// .. add a rectangle
+$g->img->SetColor('green');
+$g->img->FilledRectangle(10,10,50,50);
+
+// .. add a filled rounded rectangle
+$g->img->SetColor('green');
+$g->img->FilledRoundedRectangle(300,30,350,80,10);
+// .. with a darker border
+$g->img->SetColor('darkgreen');
+$g->img->RoundedRectangle(300,30,350,80,10);
+
+// Stroke the graph
+$g->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/canvasex03.php b/web/classes/jpgraph/Examples/canvasex03.php
new file mode 100755
index 0000000000000000000000000000000000000000..dad3c55b59f46d67c3aedc092e3f0b5059a1db91
--- /dev/null
+++ b/web/classes/jpgraph/Examples/canvasex03.php
@@ -0,0 +1,58 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: canvasex03.php,v 1.1 2002/08/27 20:08:57 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_canvtools.php');
+
+// Define work space
+$xmax=20;
+$ymax=20;
+
+// Setup a basic canvas we can work 
+$g = new CanvasGraph(400,200,'auto');
+$g->SetMargin(5,11,6,11);
+$g->SetShadow();
+$g->SetMarginColor("teal");
+
+// We need to stroke the plotarea and margin before we add the
+// text since we otherwise would overwrite the text.
+$g->InitFrame();
+
+// Create a new scale
+$scale = new CanvasScale($g);
+$scale->Set(0,$xmax,0,$ymax);
+
+// The shape class is wrapper around the Imgae class which translates
+// the coordinates for us
+$shape = new Shape($g,$scale);
+$shape->SetColor('black');
+
+
+// Add a black line
+$shape->SetColor('black');
+$shape->Line(0,0,20,20);
+
+// .. and a circle (x,y,diameter)
+$shape->Circle(5,14,2);
+
+// .. and a filled circle (x,y,diameter)
+$shape->SetColor('red');
+$shape->FilledCircle(11,8,3);
+
+// .. add a rectangle
+$shape->SetColor('green');
+$shape->FilledRectangle(15,8,19,14);
+
+// .. add a filled rounded rectangle
+$shape->SetColor('green');
+$shape->FilledRoundedRectangle(2,3,8,6);
+// .. with a darker border
+$shape->SetColor('darkgreen');
+$shape->RoundedRectangle(2,3,8,6);
+
+
+// Stroke the graph
+$g->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/canvasex04.php b/web/classes/jpgraph/Examples/canvasex04.php
new file mode 100755
index 0000000000000000000000000000000000000000..3e6ac9f93c08ce8446530fb9ac83f7ba5d179e0b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/canvasex04.php
@@ -0,0 +1,58 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: canvasex04.php,v 1.1 2002/08/27 20:08:57 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_canvtools.php');
+
+// Define work space
+$xmax=20;
+$ymax=20;
+
+// Setup a basic canvas we can work 
+$g = new CanvasGraph(200,100,'auto');
+$g->SetMargin(5,11,6,11);
+$g->SetShadow();
+$g->SetMarginColor("teal");
+
+// We need to stroke the plotarea and margin before we add the
+// text since we otherwise would overwrite the text.
+$g->InitFrame();
+
+// Create a new scale
+$scale = new CanvasScale($g);
+$scale->Set(0,$xmax,0,$ymax);
+
+// The shape class is wrapper around the Imgae class which translates
+// the coordinates for us
+$shape = new Shape($g,$scale);
+$shape->SetColor('black');
+
+
+// Add a black line
+$shape->SetColor('black');
+$shape->Line(0,0,20,20);
+
+// .. and a circle (x,y,diameter)
+$shape->Circle(5,14,2);
+
+// .. and a filled circle (x,y,diameter)
+$shape->SetColor('red');
+$shape->FilledCircle(11,8,3);
+
+// .. add a rectangle
+$shape->SetColor('green');
+$shape->FilledRectangle(15,8,19,14);
+
+// .. add a filled rounded rectangle
+$shape->SetColor('green');
+$shape->FilledRoundedRectangle(2,3,8,6);
+// .. with a darker border
+$shape->SetColor('darkgreen');
+$shape->RoundedRectangle(2,3,8,6);
+
+
+// Stroke the graph
+$g->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/canvasex05.php b/web/classes/jpgraph/Examples/canvasex05.php
new file mode 100755
index 0000000000000000000000000000000000000000..461398422c3897b23557cdb0ab76b0c92a98da48
--- /dev/null
+++ b/web/classes/jpgraph/Examples/canvasex05.php
@@ -0,0 +1,58 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: canvasex05.php,v 1.1 2002/08/27 20:08:57 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_canvtools.php');
+
+// Define work space
+$xmax=40;
+$ymax=40;
+
+// Setup a basic canvas we can work 
+$g = new CanvasGraph(400,200,'auto');
+$g->SetMargin(5,11,6,11);
+$g->SetShadow();
+$g->SetMarginColor("teal");
+
+// We need to stroke the plotarea and margin before we add the
+// text since we otherwise would overwrite the text.
+$g->InitFrame();
+
+// Create a new scale
+$scale = new CanvasScale($g);
+$scale->Set(0,$xmax,0,$ymax);
+
+// The shape class is wrapper around the Imgae class which translates
+// the coordinates for us
+$shape = new Shape($g,$scale);
+$shape->SetColor('black');
+
+
+// Add a black line
+$shape->SetColor('black');
+$shape->Line(0,0,20,20);
+
+// .. and a circle (x,y,diameter)
+$shape->Circle(5,14,2);
+
+// .. and a filled circle (x,y,diameter)
+$shape->SetColor('red');
+$shape->FilledCircle(11,8,3);
+
+// .. add a rectangle
+$shape->SetColor('green');
+$shape->FilledRectangle(15,8,19,14);
+
+// .. add a filled rounded rectangle
+$shape->SetColor('green');
+$shape->FilledRoundedRectangle(2,3,8,6);
+// .. with a darker border
+$shape->SetColor('darkgreen');
+$shape->RoundedRectangle(2,3,8,6);
+
+
+// Stroke the graph
+$g->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/canvasex06.php b/web/classes/jpgraph/Examples/canvasex06.php
new file mode 100755
index 0000000000000000000000000000000000000000..b475c68da25313bb114a145cb08112a595b40eb2
--- /dev/null
+++ b/web/classes/jpgraph/Examples/canvasex06.php
@@ -0,0 +1,42 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: canvasex06.php,v 1.1 2002/08/27 20:08:57 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_canvtools.php');
+
+// Define work space
+$xmax=40;
+$ymax=40;
+
+// Setup a basic canvas we can work 
+$g = new CanvasGraph(400,200,'auto');
+$g->SetMargin(5,11,6,11);
+$g->SetShadow();
+$g->SetMarginColor("teal");
+
+// We need to stroke the plotarea and margin before we add the
+// text since we otherwise would overwrite the text.
+$g->InitFrame();
+
+// Create a new scale
+$scale = new CanvasScale($g);
+$scale->Set(0,$xmax,0,$ymax);
+
+// The shape class is wrapper around the Imgae class which translates
+// the coordinates for us
+$shape = new Shape($g,$scale);
+$shape->SetColor('black');
+
+$shape->IndentedRectangle(1,2,15,15,8,8,CORNER_TOPLEFT,'khaki');
+
+$shape->IndentedRectangle(1,20,15,15,8,8,CORNER_BOTTOMLEFT,'khaki');
+
+$shape->IndentedRectangle(20,2,15,15,8,8,CORNER_TOPRIGHT,'khaki');
+
+$shape->IndentedRectangle(20,20,15,15,8,8,CORNER_BOTTOMRIGHT,'khaki');
+
+// Stroke the graph
+$g->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/canvaspiralex1.php b/web/classes/jpgraph/Examples/canvaspiralex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..5d72b9209b5fa5fd5d737e4caa5064d81246386b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/canvaspiralex1.php
@@ -0,0 +1,78 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: canvaspiralex1.php,v 1.1 2002/10/26 11:35:42 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+
+
+if( empty($_GET['r']) ) 
+    $r = 0.44;
+else
+    $r = $_GET['r'];
+
+if( empty($_GET['w']) ) 
+    $w=150;
+else
+    $w = $_GET['w'];
+
+if( empty($_GET['h']) ) 
+    $h=240;
+else
+    $h = $_GET['h'];
+
+if( $w < 60 ) $w=60;
+if( $h < 60 ) $h=60;
+
+
+function SeaShell($img,$x,$y,$w,$h,$r,$n=12,$color1='navy',$color2='red') {
+
+    $x += $w;
+    $w = (1-$r)/$r*$w;
+
+    $sa = 0;
+    $ea = 90;
+
+    $s1 = 1;
+    $s2 = -1;
+    $x_old=$x; $y_old=$y;
+    for($i=1; $i < $n; ++$i) {
+	$sa += 90;
+	$ea += 90;
+	if( $i % 2 == 1 ) {
+	    $y = $y + $s1*$h*$r;
+	    $h = (1-$r)*$h;
+	    $w = $w / (1-$r) * $r ;
+	    $s1 *= -1;
+	    $img->SetColor($color1);
+	    $img->Line($x,$y,$x+$s1*$w,$y);
+	}
+	else {
+	    $x = $x + $s2*$w*$r;
+	    $w = (1-$r)*$w;
+	    $h = $h / (1-$r) * $r;
+	    $s2 *= -1;
+	    $img->SetColor($color1);
+	    $img->Line($x,$y,$x,$y-$s2*$h);
+	}
+	$img->SetColor($color2);
+	$img->FilledRectangle($x-1,$y-1,$x+1,$y+1);
+	$img->Arc($x,$y,2*$w+1,2*$h+1,$sa,$ea);
+	$img->Arc($x,$y,2*$w,2*$h,$sa,$ea);
+	$img->Arc($x,$y,2*$w-1,2*$h-1,$sa,$ea);
+	$img->Line($x_old,$y_old,$x,$y);
+	$x_old=$x; $y_old=$y;
+    }
+}
+
+$g = new CanvasGraph($w,$h);
+//$gr = 1.61803398874989484820;
+
+$p = SeaShell($g->img,0,20,$w-1,$h-21,$r,19);
+$g->img->SetColor('black');
+$g->img->Rectangle(0,20,$w-1,$h-1);
+$g->img->SetFont(FF_FONT2,FS_BOLD);
+$g->img->SetTextAlign('center','top');
+$g->img->StrokeText($w/2,0,"Canvas Spiral");
+
+$g->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/ccbp_ex1.php b/web/classes/jpgraph/Examples/ccbp_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..5071fd342f44c1824410128babb7777c4d1d5aee
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ccbp_ex1.php
@@ -0,0 +1,36 @@
+<?php // content="text/plain; charset=utf-8" 
+require_once 'jpgraph/jpgraph.php';
+require_once 'jpgraph/jpgraph_line.php';
+require_once 'jpgraph/jpgraph_plotmark.inc.php';
+require_once 'jpgraph/jpgraph_scatter.php';
+require_once 'ccbpgraph.class.php';
+
+$graph = new CCBPGraph(600,400);
+$graph->SetTitle('Buffer penetration','(history added)');
+$graph->SetColorMap(0); 
+ 
+ // Two "fake tasks with hostory
+$datax=array(75,83); $datay=array(110,64);
+$datax1 = array(33,50,67,83); $datay1 = array(86,76,80,64);
+$datax2 = array(18,47,58,75); $datay2 = array(80,97,105,110);
+
+$sp = new ScatterPlot($datay,$datax);
+$sp->mark->SetType(MARK_DIAMOND);
+$sp->mark->SetFillColor('white');
+$sp->mark->SetSize(12);
+
+$sp_hist = array();
+$sp_hist[0] = new LinePlot($datay1,$datax1);
+$sp_hist[0]->SetWeight(1);
+$sp_hist[0]->SetColor('white');
+
+$sp_hist[1] = new LinePlot($datay2,$datax2);
+$sp_hist[1]->SetWeight(1);
+$sp_hist[1]->SetColor('white');
+
+$graph->Add($sp_hist);
+$graph->Add($sp);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/ccbp_ex2.php b/web/classes/jpgraph/Examples/ccbp_ex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..c5decd30133e0790fe258cfdab2a9dff4423f4b1
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ccbp_ex2.php
@@ -0,0 +1,36 @@
+<?php // content="text/plain; charset=utf-8" 
+require_once 'jpgraph/jpgraph.php';
+require_once 'jpgraph/jpgraph_line.php';
+require_once 'jpgraph/jpgraph_plotmark.inc.php';
+require_once 'jpgraph/jpgraph_scatter.php';
+require_once 'ccbpgraph.class.php';
+
+$graph = new CCBPGraph(600,400);
+$graph->SetTitle('Buffer penetration','(history added)');
+$graph->SetColorMap(1); 
+ 
+ // Two "fake tasks with hostory
+$datax=array(75,83); $datay=array(110,64);
+$datax1 = array(33,50,67,83); $datay1 = array(86,76,80,64);
+$datax2 = array(18,47,58,75); $datay2 = array(80,97,105,110);
+
+$sp = new ScatterPlot($datay,$datax);
+$sp->mark->SetType(MARK_DIAMOND);
+$sp->mark->SetFillColor('white');
+$sp->mark->SetSize(12);
+
+$sp_hist = array();
+$sp_hist[0] = new LinePlot($datay1,$datax1);
+$sp_hist[0]->SetWeight(1);
+$sp_hist[0]->SetColor('white');
+
+$sp_hist[1] = new LinePlot($datay2,$datax2);
+$sp_hist[1]->SetWeight(1);
+$sp_hist[1]->SetColor('white');
+
+$graph->Add($sp_hist);
+$graph->Add($sp);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/ccbpgraph.class.php b/web/classes/jpgraph/Examples/ccbpgraph.class.php
new file mode 100755
index 0000000000000000000000000000000000000000..91954e1e6f756269b585bcc668770c77fe7e85ab
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ccbpgraph.class.php
@@ -0,0 +1,257 @@
+<?php // content="text/plain; charset=utf-8" 
+/**
+* Class CCBPGraph
+* Utility class to create Critical Chain Buffer penetration charts
+*/
+class CCBPGraph {
+    const TickStep = 25;
+    const YTitle = '% Buffer used';
+    const XTitle = '% CC Completed';
+    const NColorMaps = 2;
+	private $graph=null;
+	private $iWidth,$iHeight;
+	private $iPlots=array();
+	private $iXMin=-50, $iXMax = 100;
+	private $iYMin=-50, $iYMax = 150;
+	private $iColorInd = array( 
+		array(5,75),   /* Green */
+		array(25,85),  /* Yellow */
+		array(50,100));/* Red */ 
+	private $iColorMap = 0;
+    private $iColorSpec = array(
+                array('darkgreen:1.0','yellow:1.4','red:0.8','darkred:0.85'),
+                array('#c6e9af','#ffeeaa','#ffaaaa','#de8787'));
+    private $iMarginColor = array('darkgreen@0.7','darkgreen@0.9');                
+	private $iSubTitle='',$iTitle = 'CC Buffer penetration';
+    /**
+    * Construct a new instance of CCBPGraph 
+    * 
+    * @param int $aWidth
+    * @param int $aHeight
+    * @return CCBPGraph
+    */
+	public function __construct($aWidth, $aHeight) {
+		$this->iWidth = $aWidth;
+		$this->iHeight = $aHeight;
+	}
+	/**
+    * Set the title and subtitle for the graph
+    * 
+    * @param string $aTitle
+    * @param string $aSubTitle
+    */
+	public function SetTitle($aTitle, $aSubTitle) {
+		$this->iTitle = $aTitle;
+		$this->iSubTitle = $aSubTitle;
+	}
+	/**
+    * Set the x-axis min and max values
+    * 
+    * @param int $aMin
+    * @param int $aMax
+    */
+	public function SetXMinMax($aMin, $aMax) {
+		$this->iXMin = floor($aMin/CCBPGraph::TickStep)*CCBPGraph::TickStep;
+		$this->iXMax = ceil($aMax/CCBPGraph::TickStep)*CCBPGraph::TickStep;
+	}
+    /**
+    * Specify what color map to use
+    * 
+    * @param int $aMap
+    */
+    public function SetColorMap($aMap) {
+        $this->iColorMap = $aMap % CCBPGraph::NColorMaps;
+    }
+	/**
+    * Set the y-axis min and max values
+    * 
+    * @param int $aMin
+    * @param int $aMax
+    */
+	public function SetYMinMax($aMin,$aMax) {
+		$this->iYMin = floor($aMin/CCBPGraph::TickStep)*CCBPGraph::TickStep;
+		$this->iYMax = ceil($aMax/CCBPGraph::TickStep)*CCBPGraph::TickStep;
+	}
+	/**
+    * Set the specification of the color backgrounds and also the
+    * optional exact colors to be used
+    * 
+    * @param mixed $aSpec  An array of 3 1x2 arrays. Each array specify the 
+    * color indication value at x=0 and x=max x in order to determine the slope
+    * @param mixed $aColors  An array with four elements specifying the colors
+    * of each color indicator
+    */
+	public function SetColorIndication(array $aSpec,array $aColors=null) {
+		if( count($aSpec) !== 3 ) {
+			JpgraphError::Raise('Specification of scale values for background indicators must be an array with three elements.');
+		}
+		$this->iColorInd = $aSpec;	
+		if( $aColors !== null ) {
+            if( is_array($aColors) && count($aColors) == 4 ) {
+			    $this->iColorSpec = $aColors;
+            }
+            else {
+                JpGraphError::Raise('Color specification for background indication must have four colors.');
+            }
+		}		
+	}
+	/**
+    * Construct the graph
+    * 
+    */
+	private function Init() {
+
+		// Setup limits for color indications
+		$lowx = $this->iXMin; $highx= $this->iXMax;
+		$lowy = $this->iYMin; $highy = $this->iYMax;
+ 		$width=$this->iWidth; $height=$this->iHeight;
+
+		// Margins
+		$lm=50; $rm=40;
+		$tm=60; $bm=40;
+        
+        if( $width <= 300 || $height <= 250 ) {
+            $labelsize = 8;
+            $lm=25; $rm=25;
+            $tm=45; $bm=25;
+        }				
+		elseif( $width <= 450 || $height <= 300 ) {
+			$labelsize = 8;
+			$lm=30; $rm=30;
+			$tm=50; $bm=30;
+		}
+		elseif( $width <= 600 || $height <= 400 ) {
+			$labelsize = 9;		
+		}
+		else {
+			$labelsize = 11;
+		}	
+        
+        if( $this->iSubTitle == '' ) {
+            $tm -= $labelsize+4;
+        } 	
+
+		$graph = new Graph($width,$height);
+		$graph->SetScale('intint',$lowy,$highy,$lowx,$highx);
+		$graph->SetMargin($lm,$rm,$tm,$bm);
+		$graph->SetMarginColor($this->iMarginColor[$this->iColorMap]);
+		$graph->SetClipping();
+		
+		$graph->title->Set($this->iTitle);
+		$graph->subtitle->Set($this->iSubTitle);
+		
+		$graph->title->SetFont(FF_ARIAL,FS_BOLD,$labelsize+4);
+		$graph->subtitle->SetFont(FF_ARIAL,FS_BOLD,$labelsize+1);
+		
+		$graph->SetBox(true,'black@0.3');
+
+		$graph->xaxis->SetFont(FF_ARIAL,FS_BOLD,$labelsize);
+		$graph->yaxis->SetFont(FF_ARIAL,FS_BOLD,$labelsize);
+		
+		$graph->xaxis->scale->ticks->Set(CCBPGraph::TickStep,CCBPGraph::TickStep);
+		$graph->yaxis->scale->ticks->Set(CCBPGraph::TickStep,CCBPGraph::TickStep);
+		
+		$graph->xaxis->HideZeroLabel();
+		$graph->yaxis->HideZeroLabel();
+		        
+        $graph->xaxis->SetLabelFormatString('%d%%');
+        $graph->yaxis->SetLabelFormatString('%d%%');
+        
+		// For the x-axis we adjust the color so labels on the left of the Y-axis are in black
+		$n1 = floor(abs($this->iXMin/25))+1;
+		$n2 = floor($this->iXMax/25);
+        if( $this->iColorMap == 0 ) {
+		    $xlcolors=array();
+		    for( $i = 0; $i < $n1; ++$i ) {
+			    $xlcolors[$i] = 'black';
+		    }
+		    for( $i = 0; $i < $n2; ++$i ) {
+			    $xlcolors[$n1+$i] = 'lightgray:1.5';
+		    }
+		    $graph->xaxis->SetColor('gray',$xlcolors);
+		    $graph->yaxis->SetColor('gray','lightgray:1.5');
+        }
+        else {
+            $graph->xaxis->SetColor('darkgray','darkgray:0.8');
+            $graph->yaxis->SetColor('darkgray','darkgray:0.8');            
+        }
+		$graph->SetGridDepth(DEPTH_FRONT);
+		$graph->ygrid->SetColor('gray@0.6');
+		$graph->ygrid->SetLineStyle('dotted');
+		
+		$graph->ygrid->Show();
+		
+		$graph->xaxis->SetWeight(1);
+		$graph->yaxis->SetWeight(1);
+		
+		$ytitle = new Text(CCBPGraph::YTitle,floor($lm*.75),($height-$tm-$bm)/2+$tm);
+		#$ytitle->SetFont(FF_VERA,FS_BOLD,$labelsize+1);
+		$ytitle->SetAlign('right','center');
+		$ytitle->SetAngle(90);
+		$graph->Add($ytitle);
+		
+		$xtitle = new Text(CCBPGraph::XTitle,($width-$lm-$rm)/2+$lm,$height - 10);
+		#$xtitle->SetFont(FF_VERA,FS_BOLD,$labelsize);
+		$xtitle->SetAlign('center','bottom');
+		$graph->Add($xtitle);
+		
+		$df = 'D j:S M, Y'; 
+		if( $width < 400 ) {
+			$df = 'D j:S M';
+		}
+		
+		$time = new Text(date($df),$width-10,$height-10);
+		$time->SetAlign('right','bottom');
+		#$time->SetFont(FF_VERA,FS_NORMAL,$labelsize-1);
+		$time->SetColor('darkgray');
+		$graph->Add($time);
+
+		// Use an accumulated fille line graph to create the colored bands
+       
+        $n = 3;
+        for( $i=0; $i < $n; ++$i ) {
+            $b = $this->iColorInd[$i][0];
+            $k = ($this->iColorInd[$i][1] - $this->iColorInd[$i][0])/$this->iXMax;
+            $colarea[$i] = array( array($lowx,$lowx*$k+$b), array($highx,$highx*$k+$b) );
+        }
+        $colarea[3] = array( array($lowx,$highy), array($highx,$highy) );
+        
+        
+		$cb = array();
+		for( $i=0; $i < 4; ++$i ) {
+			$cb[$i] = new LinePlot(array($colarea[$i][0][1],$colarea[$i][1][1]),
+								   array($colarea[$i][0][0],$colarea[$i][1][0]));
+			$cb[$i]->SetFillColor($this->iColorSpec[$this->iColorMap][$i]);
+			$cb[$i]->SetFillFromYMin();								   
+		}
+
+		$graph->Add(array_slice(array_reverse($cb),0,4));	
+		$this->graph = $graph;
+	}
+    /**
+    * Add a line or scatter plot to the graph
+    * 
+    * @param mixed $aPlots
+    */
+    public function Add($aPlots) {
+        if( is_array($aPlots) ) {
+            $this->iPlots = array_merge($this->iPlots,$aPlots);                
+        }
+        else {
+            $this->iPlots[] = $aPlots;
+        }
+    }
+    /**
+    * Stroke the graph back to the client or to a file
+    * 
+    * @param mixed $aFile
+    */
+	public function Stroke($aFile='') {
+		$this->Init();
+        if( count($this->iPlots) > 0 )  {
+		    $this->graph->Add($this->iPlots);
+        }
+		$this->graph->Stroke($aFile);
+	}
+}
+?>
diff --git a/web/classes/jpgraph/Examples/centeredlineex01.php b/web/classes/jpgraph/Examples/centeredlineex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..3642f3a43b518492ed0c9ed17f3dab04170566f0
--- /dev/null
+++ b/web/classes/jpgraph/Examples/centeredlineex01.php
@@ -0,0 +1,35 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_error.php');
+
+
+//$datax = array(3.5,3.7,3,4,6.2,6,3.5,8,14,8,11.1,13.7);
+$datay = array(1.23,1.9,1.6,3.1,3.4,2.8,2.1,1.9);
+$graph = new Graph(300,200);
+$graph->img->SetMargin(40,40,40,40);	
+$graph->img->SetAntiAliasing();
+$graph->SetScale("textlin");
+$graph->SetShadow();
+$graph->title->Set("Example of line centered plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+
+// Use 20% "grace" to get slightly larger scale then min/max of
+// data
+$graph->yscale->SetGrace(20);
+
+
+$p1 = new LinePlot($datay);
+$p1->mark->SetType(MARK_FILLEDCIRCLE);
+$p1->mark->SetFillColor("red");
+$p1->mark->SetWidth(4);
+$p1->SetColor("blue");
+$p1->SetCenter();
+$graph->Add($p1);
+
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/centeredlineex02.php b/web/classes/jpgraph/Examples/centeredlineex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..2b742290d71023eeb4287f83606cd69f2b81421e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/centeredlineex02.php
@@ -0,0 +1,30 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_error.php');
+
+
+//$datax = array(3.5,3.7,3,4,6.2,6,3.5,8,14,8,11.1,13.7);
+$datay = array(1.23,1.9,1.6,3.1,3.4,2.8,2.1,1.9);
+$graph = new Graph(300,200);
+$graph->img->SetMargin(40,40,40,40);	
+$graph->img->SetAntiAliasing();
+$graph->SetScale("textlin");
+$graph->SetShadow();
+$graph->title->Set("Example of filled line centered plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$p1 = new LinePlot($datay);
+$p1->SetFillColor("green");
+$p1->mark->SetType(MARK_FILLEDCIRCLE);
+$p1->mark->SetFillColor("red");
+$p1->mark->SetWidth(4);
+$p1->SetColor("blue");
+$p1->SetCenter();
+$graph->Add($p1);
+
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/centeredlineex03.php b/web/classes/jpgraph/Examples/centeredlineex03.php
new file mode 100755
index 0000000000000000000000000000000000000000..9c182a74a468f038a36812dc610b68e36f94c9a2
--- /dev/null
+++ b/web/classes/jpgraph/Examples/centeredlineex03.php
@@ -0,0 +1,31 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$labels = array("Oct 2000","Nov 2000","Dec 2000","Jan 2001","Feb 2001","Mar 2001","Apr 2001","May 2001");
+$datay = array(1.23,1.9,1.6,3.1,3.4,2.8,2.1,1.9);
+$graph = new Graph(300,250);
+$graph->img->SetMargin(40,40,40,80);	
+$graph->img->SetAntiAliasing();
+$graph->SetScale("textlin");
+$graph->SetShadow();
+$graph->title->Set("Example slanted X-labels");
+$graph->title->SetFont(FF_VERDANA,FS_NORMAL,14);
+
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,11);
+$graph->xaxis->SetTickLabels($labels);
+$graph->xaxis->SetLabelAngle(45);
+
+$p1 = new LinePlot($datay);
+$p1->mark->SetType(MARK_FILLEDCIRCLE);
+$p1->mark->SetFillColor("red");
+$p1->mark->SetWidth(4);
+$p1->SetColor("blue");
+$p1->SetCenter();
+$graph->Add($p1);
+
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/centerlinebarex1.php b/web/classes/jpgraph/Examples/centerlinebarex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..d686bc6b7bc5cbc0d2e7b7235f73f4ba2be7db61
--- /dev/null
+++ b/web/classes/jpgraph/Examples/centerlinebarex1.php
@@ -0,0 +1,35 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+
+$ydata = array(12,15,22,19,5);
+
+$graph = new Graph(400,200);
+$graph->img->SetMargin(40,80,40,40);	
+$graph->SetScale("textlin");
+$graph->SetShadow();
+
+$graph->title->Set('Center the line points in bars');
+
+$line = new LinePlot($ydata);
+$line->SetBarCenter();
+$line->SetWeight(2);
+
+$bar = new BarPlot($ydata);
+$bar2 = new BarPlot($ydata);
+$bar2->SetFillColor("red");
+
+$gbar = new GroupbarPlot(array($bar,$bar2));
+
+$graph->Add($gbar);
+$graph->Add($line);
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/checkgd.php b/web/classes/jpgraph/Examples/checkgd.php
new file mode 100755
index 0000000000000000000000000000000000000000..ad252bd21a1bad834f37e907177e94bf046f0fb4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/checkgd.php
@@ -0,0 +1,11 @@
+<?php // content="text/plain; charset=utf-8"
+$im = @imagecreate (200, 100) or die ( "cannot create a new gd image.");
+$background_color = imagecolorallocate ($im, 240, 240, 240);
+$border_color = imagecolorallocate ($im, 50, 50, 50);
+$text_color = imagecolorallocate ($im, 233, 14, 91);
+
+imagerectangle($im,0,0,199,99,$border_color);
+imagestring ($im, 5, 10, 40, "a simple text string", $text_color );
+header ("content-type: image/png");
+imagepng ($im);
+?>
diff --git a/web/classes/jpgraph/Examples/checkgd2.php b/web/classes/jpgraph/Examples/checkgd2.php
new file mode 100755
index 0000000000000000000000000000000000000000..e5e7b3c5e10fbfcea880f067bcd640903c24b210
--- /dev/null
+++ b/web/classes/jpgraph/Examples/checkgd2.php
@@ -0,0 +1,14 @@
+<?php // content="text/plain; charset=utf-8"
+$im =  imagecreatetruecolor ( 300, 200);
+$black = imagecolorallocate ($im,  0, 0, 0);
+$lightgray = imagecolorallocate ($im,  230, 230, 230);
+$darkgreen = imagecolorallocate ($im,  80, 140, 80);
+$white = imagecolorallocate ($im,  255, 255, 255);
+
+imagefilledrectangle ($im,0,0,299,199 ,$lightgray);
+imagerectangle ($im,0,0,299,199,$black);
+imagefilledellipse ($im,150,100,210,110,$white);
+imagefilledellipse ($im,150,100,200,100,$darkgreen);
+header ("Content-type: image/png");
+imagepng ($im);
+?>
diff --git a/web/classes/jpgraph/Examples/checkttf.php b/web/classes/jpgraph/Examples/checkttf.php
new file mode 100755
index 0000000000000000000000000000000000000000..5efe737f2660d56848791aea5d64e5fa94b8b71d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/checkttf.php
@@ -0,0 +1,22 @@
+<?php // content="text/plain; charset=utf-8"
+// Change this defines to where Your fonts are stored
+DEFINE("TTF_DIR","/usr/share/fonts/truetype/");
+
+// Change this define to a font file that You know that You have
+DEFINE("TTF_FONTFILE","arial.ttf");
+
+// Text to display
+DEFINE("TTF_TEXT","Hello World!");
+
+$im = imagecreatetruecolor (400, 100);
+$white = imagecolorallocate ($im, 255, 255, 255);
+$black = imagecolorallocate ($im, 0, 0, 0);
+$border_color = imagecolorallocate ($im, 50, 50, 50);
+
+imagefilledrectangle($im,0,0,399,99,$white);
+imagerectangle($im,0,0,399,99,$border_color);
+imagettftext ($im, 30, 0, 90, 60, $black, TTF_DIR.TTF_FONTFILE,TTF_TEXT);
+
+header ("Content-type: image/png");
+imagepng ($im);
+?>
diff --git a/web/classes/jpgraph/Examples/classroom.jpg b/web/classes/jpgraph/Examples/classroom.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..f4cc06c44b6fc8fe999cf856b565612d7c31688e
Binary files /dev/null and b/web/classes/jpgraph/Examples/classroom.jpg differ
diff --git a/web/classes/jpgraph/Examples/clipping_ex1.php b/web/classes/jpgraph/Examples/clipping_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..8629fce4d9829431c6ed3fc1961f0d7a37d51b48
--- /dev/null
+++ b/web/classes/jpgraph/Examples/clipping_ex1.php
@@ -0,0 +1,36 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,250);	
+$graph->SetScale('intlin',0,10);
+$graph->SetMargin(30,20,70,40);
+$graph->SetMarginColor(array(177,191,174));
+
+$graph->SetClipping(false);
+
+$graph->xaxis->SetFont(FF_FONT1,FS_BOLD);
+
+$graph->ygrid->SetLineStyle('dashed');
+
+$graph->title->Set("Manual scale");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph->title->SetColor('white');
+$graph->subtitle->Set("(No clipping)");
+$graph->subtitle->SetColor('white');
+$graph->subtitle->SetFont(FF_ARIAL,FS_BOLD,10);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor("red");
+$lineplot->SetWeight(2);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/clipping_ex2.php b/web/classes/jpgraph/Examples/clipping_ex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..aba939f9d2db250b1f55dcd9b03d662611076dbc
--- /dev/null
+++ b/web/classes/jpgraph/Examples/clipping_ex2.php
@@ -0,0 +1,36 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,250);	
+$graph->SetScale('intlin',0,10);
+$graph->SetMargin(30,20,70,40);
+$graph->SetMarginColor(array(177,191,174));
+
+$graph->SetClipping(true);
+
+$graph->xaxis->SetFont(FF_FONT1,FS_BOLD);
+
+$graph->ygrid->SetLineStyle('dashed');
+
+$graph->title->Set("Manual scale");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph->title->SetColor('white');
+$graph->subtitle->Set("(With clipping)");
+$graph->subtitle->SetColor('white');
+$graph->subtitle->SetFont(FF_ARIAL,FS_BOLD,10);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor("red");
+$lineplot->SetWeight(2);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/colormaps.php b/web/classes/jpgraph/Examples/colormaps.php
new file mode 100755
index 0000000000000000000000000000000000000000..2f9470f0d95f72164a22cce0997b32a0352697f1
--- /dev/null
+++ b/web/classes/jpgraph/Examples/colormaps.php
@@ -0,0 +1,133 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('../jpgraph.php');
+require_once ('../jpgraph_canvas.php');
+require_once ('../jpgraph_colormap.inc.php');
+
+class ColorMapDriver {
+	const WIDTH = 600; // Image width
+	const LMARG = 90;  // Left margin
+	const RMARG = 25;  // Right margin
+	const MAPMARG = 35;  // Map margin between each map
+	const MODHEIGHT = 30; // Module height (=Map height)
+	const YSTART = 60; // Start coordinate for map list
+
+    public function Draw($aTitle, $aStart, $aEnd, $n=64, $aReverse=false, $addColorNames = false ) {
+
+	    // Setup to draw colormap with names platoe colors
+	    $lmarg = ColorMapDriver::LMARG; // left margin
+	    $rmarg = ColorMapDriver::RMARG; // right margin
+	    $width = ColorMapDriver::WIDTH; // Overall image width
+
+	    // Module height
+	    $mh = ColorMapDriver::MODHEIGHT;
+
+	    // Step between each map
+	    $ymarg = $mh + ColorMapDriver::MAPMARG;
+
+	    if( $addColorNames ) {
+	    	$ymarg += 50;
+	    }
+
+        // Start position
+        $xs=$lmarg; $ys=ColorMapDriver::YSTART;
+
+    	// Setup a basic canvas graph
+        $height = ($aEnd-$aStart+1)*$ymarg+50;
+        $graph = new CanvasGraph($width,$height);
+        $graph->img->SetColor('darkgray');
+        $graph->img->Rectangle(0,0,$width-1,$height-1);
+
+	    $t = new Text($aTitle, $width/2,5);
+	    $t->SetAlign('center','top');
+	    $t->SetFont(FF_ARIAL,FS_BOLD,14);
+	    $t->Stroke($graph->img);
+
+	    // Instantiate a colormap
+		$cm = new ColorMap();
+		$cm->InitRGB($graph->img->rgb);
+
+        for( $mapidx=$aStart; $mapidx <= $aEnd; ++$mapidx, $ys += $ymarg ) {
+
+	        $cm->SetMap($mapidx,$aReverse);
+	        $n = $cm->SetNumColors($n);
+	        list( $mapidx, $maparray ) = $cm->GetCurrMap();
+	        $ncols = count($maparray);
+	        $colbuckets = $cm->GetBuckets();
+
+	        // The module width will depend on the actual number of colors
+	    	$mw = round(($width-$lmarg-$rmarg)/$n);
+
+	        // Draw color map title (name)
+	        $t->Set('Basic colors: '.$ncols.',   Total colors: '.$n);
+	        $t->SetAlign('center','bottom');
+	        $t->SetAngle(0);
+	        $t->SetFont(FF_TIMES,FS_NORMAL,14);
+	        $t->Stroke($graph->img,$width/2,$ys-3);
+
+	        // Add the name/number of the map to the left
+	        $t->SetAlign('right','center');
+	        $t->Set('Map: '.$mapidx);
+	        $t->SetFont(FF_ARIAL,FS_NORMAL,14);
+	        $t->Stroke($graph->img,$xs-20,round($ys+$mh/2));
+
+	        // Setup text properties for the color names
+	        if( $addColorNames ) {
+	        	$t->SetAngle(30);
+	        	$t->SetFont(FF_ARIAL,FS_NORMAL,12);
+	        	$t->SetAlign('right','top');
+	        }
+
+	        // Loop through all colors in the map
+	        $x = $xs; $y = $ys; $k=0;
+	        for($i=0; $i < $n; ++$i){
+	            $graph->img->SetColor($colbuckets[$i]);
+	            $graph->img->FilledRectangle($x,$y,$x+$mw,$y+$mh);
+
+	            // Mark all basic colors in the map with a bar and name
+	            if( $i % (($n-$ncols)/($ncols-1)+1) == 0 ) {
+	            	$graph->img->SetColor('black');
+	            	$graph->img->FilledRectangle($x,$y+$mh+4,$x+$mw-1,$y+$mh+6);
+	            	if( $addColorNames ) {
+	            		$t->Set($maparray[$k++]);
+	            		$t->Stroke($graph->img,$x+$mw/2,$y+$mh+10);
+	            	}
+	            }
+	            $x += $mw;
+	        }
+
+	        // Draw a border around the map
+	        $graph->img->SetColor('black');
+	        $graph->img->Rectangle($xs,$ys,$xs+$mw*$n,$ys+$mh);
+
+	    }
+
+        // Send back to client
+        $graph->Stroke();
+    }
+
+}
+
+$driver = new ColorMapDriver();
+
+$title = "Standard maps";
+$reverse = false;
+$n = 64; $s=0; $e=9;
+$showNames = false;
+
+
+/*
+$title = "Center maps";
+$reverse = false;
+$n = 64; $s=10; $e=14;
+$showNames = false;
+*/
+
+/*
+$title = "Continues maps";
+$reverse = false;
+$n = 64; $s=15; $e=21;
+$showNames = false;
+*/
+$driver->Draw($title,$s,$e,$n,$reverse,$showNames);
+
+?>
diff --git a/web/classes/jpgraph/Examples/comb90dategraphex01.php b/web/classes/jpgraph/Examples/comb90dategraphex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..32948225d8673753d5d996cb7017c28db45540e3
--- /dev/null
+++ b/web/classes/jpgraph/Examples/comb90dategraphex01.php
@@ -0,0 +1,96 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_date.php');
+require_once ('jpgraph/jpgraph_mgraph.php');
+
+// Setup some fake data to simulate some wind speed and direction
+
+DEFINE('NDATAPOINTS',420);
+DEFINE('SAMPLERATE',300);
+$start = time();
+$end = $start+NDATAPOINTS*SAMPLERATE;
+$data = array();
+$xdata = array();
+$data_winddirection[0] = rand(100,200);
+$data_windspeed[0] = rand(7,10);
+for( $i=0; $i < NDATAPOINTS-1; ++$i ) {
+    $data_winddirection[$i+1] = $data_winddirection[$i] + rand(-4,4);
+    if($data_winddirection[$i+1] < 0 || $data_winddirection[$i+1] > 359)
+        $data_winddirection[$i+1] = 0;
+
+    $data_windspeed[$i+1] = $data_windspeed[$i] + rand(-2,2);
+    if($data_windspeed[$i+1] < 0 )
+        $data_windspeed[$i+1] = 0;
+
+    $xdata[$i] = $start + $i * SAMPLERATE;
+}
+$xdata[$i] = $start + $i * SAMPLERATE;
+
+
+// Setup the Wind direction graph
+$graph = new Graph(300,800);
+$graph->SetMarginColor('lightgray:1.7');
+$graph->SetScale('datlin',0,360);
+$graph->Set90AndMargin(50,30,60,30);
+$graph->SetFrame(true,'white',0);
+$graph->SetBox();
+
+$graph->title->Set('Wind direction');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph->title->SetMargin(10);
+
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->xaxis->scale->SetDateFormat('h:i');
+$graph->xgrid->Show();
+
+$graph->yaxis->SetLabelAngle(45);
+$graph->yaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->yaxis->SetLabelMargin(0);
+$graph->yaxis->scale->SetAutoMin(0);
+
+$line = new LinePlot($data_winddirection,$xdata);
+$line->SetStepStyle();
+$line->SetColor('blue');
+
+$graph->Add($line);
+
+// Setup the wind speed graph
+$graph2 = new Graph(300,800);
+$graph2->SetScale('datlin');
+$graph2->Set90AndMargin(50,30,60,30);
+$graph2->SetMarginColor('lightgray:1.7');
+$graph2->SetFrame(true,'white',0);
+$graph2->SetBox();
+
+$graph2->title->Set('Windspeed');
+$graph2->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph2->title->SetMargin(10);
+
+$graph2->xaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph2->xaxis->scale->SetDateFormat('h:i');
+$graph2->xgrid->Show();
+
+$graph2->yaxis->SetLabelAngle(45);
+$graph2->yaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph2->yaxis->SetLabelMargin(0);
+$graph2->yaxis->scale->SetAutoMin(0);
+
+$line2 = new LinePlot($data_windspeed,$xdata);
+$line2->SetStepStyle();
+$line2->SetColor('red');
+
+$graph2->Add($line2);
+
+//-----------------------
+// Create a multigraph
+//----------------------
+$mgraph = new MGraph();
+$mgraph->SetMargin(2,2,2,2);
+$mgraph->SetFrame(true,'darkgray',2);
+$mgraph->SetFillColor('lightgray');
+$mgraph->Add($graph);
+$mgraph->Add($graph2,300,0);
+$mgraph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/comb90dategraphex02.php b/web/classes/jpgraph/Examples/comb90dategraphex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..b6671811c33d101a3ded656ea8a6e02c0b97eb28
--- /dev/null
+++ b/web/classes/jpgraph/Examples/comb90dategraphex02.php
@@ -0,0 +1,103 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_date.php');
+require_once ('jpgraph/jpgraph_mgraph.php');
+
+// Setup some fake data to simulate some wind speed and direction
+
+DEFINE('NDATAPOINTS',420);
+DEFINE('SAMPLERATE',300);
+$start = time();
+$end = $start+NDATAPOINTS*SAMPLERATE;
+$data = array();
+$xdata = array();
+$data_winddirection[0] = rand(100,200);
+$data_windspeed[0] = rand(7,10);
+for( $i=0; $i < NDATAPOINTS-1; ++$i ) {
+    $data_winddirection[$i+1] = $data_winddirection[$i] + rand(-4,4);
+    if($data_winddirection[$i+1] < 0 || $data_winddirection[$i+1] > 359)
+        $data_winddirection[$i+1] = 0;
+
+    $data_windspeed[$i+1] = $data_windspeed[$i] + rand(-2,2);
+    if($data_windspeed[$i+1] < 0 )
+        $data_windspeed[$i+1] = 0;
+
+    $xdata[$i] = $start + $i * SAMPLERATE;
+}
+$xdata[$i] = $start + $i * SAMPLERATE;
+
+
+DEFINE('BKG_COLOR','lightgray:1.7');
+DEFINE('WIND_HEIGHT',800);
+DEFINE('WIND_WIDTH',280);
+
+// Setup the Wind direction graph
+$graph = new Graph(WIND_WIDTH,WIND_HEIGHT);
+$graph->SetMarginColor(BKG_COLOR);
+$graph->SetScale('datlin',0,360);
+$graph->Set90AndMargin(50,10,60,30);
+$graph->SetFrame(true,'white',0);
+$graph->SetBox();
+
+$graph->title->Set('Wind direction');
+$graph->title->SetColor('blue');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph->title->SetMargin(5);
+
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->xaxis->scale->SetDateFormat('h:i');
+$graph->xgrid->Show();
+
+$graph->yaxis->SetLabelAngle(90);
+$graph->yaxis->SetColor('blue');
+$graph->yaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->yaxis->SetLabelMargin(0);
+$graph->yaxis->scale->SetAutoMin(0);
+
+$line = new LinePlot($data_winddirection,$xdata);
+$line->SetStepStyle();
+$line->SetColor('blue');
+
+$graph->Add($line);
+
+// Setup the wind speed graph
+$graph2 = new Graph(WIND_WIDTH-30,WIND_HEIGHT);
+$graph2->SetScale('datlin');
+$graph2->Set90AndMargin(5,20,60,30);
+$graph2->SetMarginColor(BKG_COLOR);
+$graph2->SetFrame(true,'white',0);
+$graph2->SetBox();
+
+$graph2->title->Set('Windspeed');
+$graph2->title->SetColor('red');
+$graph2->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph2->title->SetMargin(5);
+
+$graph2->xaxis->HideLabels();
+$graph2->xgrid->Show();
+
+$graph2->yaxis->SetLabelAngle(90);
+$graph2->yaxis->SetColor('red');
+$graph2->yaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph2->yaxis->SetLabelMargin(0);
+$graph2->yaxis->scale->SetAutoMin(0);
+
+$line2 = new LinePlot($data_windspeed,$xdata);
+$line2->SetStepStyle();
+$line2->SetColor('red');
+
+$graph2->Add($line2);
+
+//-----------------------
+// Create a multigraph
+//----------------------
+$mgraph = new MGraph();
+$mgraph->SetMargin(2,2,2,2);
+$mgraph->SetFrame(true,'darkgray',2);
+$mgraph->SetFillColor(BKG_COLOR);
+$mgraph->Add($graph);
+$mgraph->Add($graph2,280,0);
+$mgraph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/comb90dategraphex03.php b/web/classes/jpgraph/Examples/comb90dategraphex03.php
new file mode 100755
index 0000000000000000000000000000000000000000..2911f8b789fa275d75d5e160a37b49cb757e2625
--- /dev/null
+++ b/web/classes/jpgraph/Examples/comb90dategraphex03.php
@@ -0,0 +1,147 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_date.php');
+require_once ('jpgraph/jpgraph_mgraph.php');
+
+// Setup some fake data to simulate some wind speed and direction
+
+DEFINE('NDATAPOINTS',280);
+DEFINE('SAMPLERATE',300);
+
+$start = time();
+$end = $start+NDATAPOINTS*SAMPLERATE;
+$xdata = array();
+
+$data_winddirection[0] = rand(100,200);
+$data_windspeed[0] = rand(7,10);
+$data_windtemp[0] = rand(5,20);
+
+for( $i=0; $i < NDATAPOINTS-1; ++$i ) {
+    $data_winddirection[$i+1] = $data_winddirection[$i] + rand(-4,4);
+    if($data_winddirection[$i+1] < 0 || $data_winddirection[$i+1] > 359)
+        $data_winddirection[$i+1] = 0;
+
+    $data_windspeed[$i+1] = $data_windspeed[$i] + rand(-2,2);
+    if($data_windspeed[$i+1] < 0 )
+        $data_windspeed[$i+1] = 0;
+
+    $data_windtemp[$i+1] = $data_windtemp[$i] + rand(-1.5,1.5);
+
+    $xdata[$i] = $start + $i * SAMPLERATE;
+}
+$xdata[$i] = $start + $i * SAMPLERATE;
+
+
+//DEFINE('BKG_COLOR','lightgray:1.7');
+DEFINE('BKG_COLOR','green:1.98');
+DEFINE('WIND_HEIGHT',800);
+DEFINE('WIND_WIDTH',250);
+
+//------------------------------------------------------------------
+// Setup the Wind direction graph
+//------------------------------------------------------------------
+$graph = new Graph(WIND_WIDTH,WIND_HEIGHT);
+$graph->SetMarginColor(BKG_COLOR);
+$graph->SetScale('datlin',0,360);
+$graph->Set90AndMargin(50,10,70,30);
+$graph->SetFrame(true,'white',0);
+$graph->SetBox();
+
+$graph->title->Set('Wind direction');
+$graph->title->SetColor('blue');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph->title->SetMargin(5);
+
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->xaxis->scale->SetDateFormat('H:i');
+$graph->xgrid->Show();
+
+$graph->yaxis->SetLabelAngle(90);
+$graph->yaxis->SetColor('blue');
+$graph->yaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph->yaxis->SetLabelMargin(0);
+$graph->yaxis->scale->SetAutoMin(0);
+
+$line = new LinePlot($data_winddirection,$xdata);
+$line->SetStepStyle();
+$line->SetColor('blue');
+
+$graph->Add($line);
+
+//------------------------------------------------------------------
+// Setup the wind speed graph
+//------------------------------------------------------------------
+$graph2 = new Graph(WIND_WIDTH-30,WIND_HEIGHT);
+$graph2->SetScale('datlin');
+$graph2->Set90AndMargin(5,20,70,30);
+$graph2->SetMarginColor(BKG_COLOR);
+$graph2->SetFrame(true,'white',0);
+$graph2->SetBox();
+
+$graph2->title->Set('Windspeed');
+$graph2->title->SetColor('red');
+$graph2->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph2->title->SetMargin(5);
+
+$graph2->xaxis->HideLabels();
+$graph2->xgrid->Show();
+
+$graph2->yaxis->SetLabelAngle(90);
+$graph2->yaxis->SetColor('red');
+$graph2->yaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph2->yaxis->SetLabelMargin(0);
+$graph2->yaxis->scale->SetAutoMin(0);
+
+$line2 = new LinePlot($data_windspeed,$xdata);
+$line2->SetStepStyle();
+$line2->SetColor('red');
+
+$graph2->Add($line2);
+
+//------------------------------------------------------------------
+// Setup the wind temp graph
+//------------------------------------------------------------------
+$graph3 = new Graph(WIND_WIDTH-30,WIND_HEIGHT);
+$graph3->SetScale('datlin');
+$graph3->Set90AndMargin(5,20,70,30);
+$graph3->SetMarginColor(BKG_COLOR);
+$graph3->SetFrame(true,'white',0);
+$graph3->SetBox();
+
+$graph3->title->Set('Temperature');
+$graph3->title->SetColor('black');
+$graph3->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph3->title->SetMargin(5);
+
+$graph3->xaxis->HideLabels();
+$graph3->xgrid->Show();
+
+$graph3->yaxis->SetLabelAngle(90);
+$graph3->yaxis->SetColor('black');
+$graph3->yaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+$graph3->yaxis->SetLabelMargin(0);
+$graph3->yaxis->scale->SetAutoMin(-10);
+
+$line3 = new LinePlot($data_windtemp,$xdata);
+$line3->SetStepStyle();
+$line3->SetColor('black');
+
+$graph3->Add($line3);
+
+//-----------------------
+// Create a multigraph
+//----------------------
+$mgraph = new MGraph();
+$mgraph->SetMargin(2,2,2,2);
+$mgraph->SetFrame(true,'darkgray',2);
+$mgraph->SetFillColor(BKG_COLOR);
+$mgraph->Add($graph,0,50);
+$mgraph->Add($graph2,250,50);
+$mgraph->Add($graph3,460,50);
+$mgraph->title->Set('Climate diagram 12 March 2009');
+$mgraph->title->SetFont(FF_ARIAL,FS_BOLD,20);
+$mgraph->title->SetMargin(8);
+$mgraph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/combgraphex1.php b/web/classes/jpgraph/Examples/combgraphex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..b03b14bb4dbbe5e3f40cec15c0830af7d61a6469
--- /dev/null
+++ b/web/classes/jpgraph/Examples/combgraphex1.php
@@ -0,0 +1,89 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_utils.inc.php');
+require_once ('jpgraph/jpgraph_mgraph.php');
+
+//------------------------------------------------------------------
+// Create some random data for the plot. We use the current time for the
+// first X-position
+//------------------------------------------------------------------
+$datay = array();
+$datax = array();
+$ts = time();
+$n=70; // Number of data points
+for($i=0; $i < $n; ++$i ) {
+    $datax[$i] = $ts+$i*150000; 
+    $datay[$i] = rand(5,60);
+    $datay2[$i] = rand(1,8);
+}
+
+// Now get labels at the start of each month
+$dateUtils = new DateScaleUtils();
+list($tickPositions,$minTickPositions) = $dateUtils->getTicks($datax,DSUTILS_MONTH1);
+
+// Now create the real graph
+// Combine a line and a bar graph
+
+// We add some grace to the end of the X-axis scale so that the first and last
+// data point isn't exactly at the very end or beginning of the scale
+$grace = 400000;
+$xmin = $datax[0]-$grace;
+$xmax = $datax[$n-1]+$grace;;
+
+// Overall width of graphs
+$w = 450;
+// Left and right margin for each graph
+$lm=25; $rm=15; 
+
+//----------------------
+// Setup the line graph
+//----------------------
+$graph = new Graph($w,250);
+$graph->SetScale('linlin',0,0,$xmin,$xmax);
+$graph->SetMargin($lm,$rm,10,30);
+$graph->SetMarginColor('white');
+$graph->SetFrame(false);
+$graph->SetBox(true);
+$graph->title->Set('Example of combined graph');
+$graph->title->SetFont(FF_ARIAL,FS_NORMAL,14);
+$graph->xaxis->SetTickPositions($tickPositions,$minTickPositions);
+$graph->xaxis->SetLabelFormatString('My',true);
+$graph->xgrid->Show();
+$p1 = new LinePlot($datay,$datax);
+$graph->Add($p1);
+
+//----------------------
+// Setup the bar graph
+//----------------------
+$graph2 = new Graph($w,110);
+$graph2->SetScale('linlin',0,0,$xmin,$xmax);
+$graph2->SetMargin($lm,$rm,5,10);
+$graph2->SetMarginColor('white');
+$graph2->SetFrame(false);
+$graph2->SetBox(true);
+$graph2->xgrid->Show();
+$graph2->xaxis->SetTickPositions($tickPositions,$minTickPositions);
+$graph2->xaxis->SetLabelFormatString('My',true);
+$graph2->xaxis->SetPos('max');
+$graph2->xaxis->HideLabels();
+$graph2->xaxis->SetTickSide(SIDE_DOWN);
+$b1 = new BarPlot($datay2,$datax);
+$b1->SetFillColor('teal');
+$b1->SetColor('teal:1.2');
+$graph2->Add($b1);
+
+//-----------------------
+// Create a multigraph
+//----------------------
+$mgraph = new MGraph();
+$mgraph->SetMargin(2,2,2,2);
+$mgraph->SetFrame(true,'darkgray',2);
+$mgraph->Add($graph);
+$mgraph->Add($graph2,0,240);
+$mgraph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/combgraphex2.php b/web/classes/jpgraph/Examples/combgraphex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..27afa832da1c938475804ae641a24e863a1f720c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/combgraphex2.php
@@ -0,0 +1,90 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('../jpgraph.php');
+require_once ('../jpgraph_mgraph.php');
+require_once ('../jpgraph_line.php');
+require_once ('../jpgraph_bar.php');
+require_once ('../jpgraph_utils.inc.php');
+
+//------------------------------------------------------------------
+// Create some random data for the plot. We use the current time for the
+// first X-position
+//------------------------------------------------------------------
+$datay = array();
+$datax = array();
+$ts = time();
+$n=70; // Number of data points
+for($i=0; $i < $n; ++$i ) {
+    $datax[$i] = $ts+$i*150000; 
+    $datay[$i] = rand(5,60);
+    $datay2[$i] = rand(1,8);
+}
+
+// Now get labels at the start of each month
+list($tickPositions,$minTickPositions) = DateScaleUtils::getTicks($datax,DSUTILS_MONTH1);
+
+// Now create the real graph
+// Combine a line and a bar graph
+
+// We add some grace to the end of the X-axis scale so that the first and last
+// data point isn't exactly at the very end or beginning of the scale
+$grace = 400000;
+$xmin = $datax[0]-$grace;
+$xmax = $datax[$n-1]+$grace;;
+
+// Overall width of graphs
+$w = 450;
+// Left and right margin for each graph
+$lm=25; $rm=15; 
+
+//----------------------
+// Setup the line graph
+//----------------------
+$graph = new Graph($w,250);
+$graph->SetScale('linlin',0,0,$xmin,$xmax);
+$graph->SetMargin($lm,$rm,10,30);
+$graph->SetMarginColor('white');
+$graph->SetFrame(false);
+$graph->SetBox(true);
+$graph->title->Set('Example of combined graph with background');
+$graph->title->SetFont(FF_ARIAL,FS_NORMAL,14);
+$graph->xaxis->SetTickPositions($tickPositions,$minTickPositions);
+$graph->xaxis->SetLabelFormatString('My',true);
+$graph->xgrid->Show();
+$p1 = new LinePlot($datay,$datax);
+$graph->Add($p1);
+
+//----------------------
+// Setup the bar graph
+//----------------------
+$graph2 = new Graph($w,110);
+$graph2->SetScale('linlin',0,0,$xmin,$xmax);
+$graph2->SetMargin($lm,$rm,5,10);
+$graph2->SetMarginColor('white');
+$graph2->SetFrame(false);
+$graph2->SetBox(true);
+$graph2->xgrid->Show();
+$graph2->xaxis->SetTickPositions($tickPositions,$minTickPositions);
+$graph2->xaxis->SetLabelFormatString('My',true);
+$graph2->xaxis->SetPos('max');
+$graph2->xaxis->HideLabels();
+$graph2->xaxis->SetTickSide(SIDE_DOWN);
+$b1 = new BarPlot($datay2,$datax);
+$b1->SetFillColor('teal');
+$b1->SetColor('teal:1.2');
+$graph2->Add($b1);
+
+//-----------------------
+// Create a multigraph
+//----------------------
+$mgraph = new MGraph();
+$mgraph->SetImgFormat('jpeg',60);
+$mgraph->SetMargin(2,2,2,2);
+$mgraph->SetFrame(true,'darkgray',2);
+$mgraph->SetBackgroundImage('tiger1.jpg');
+$mgraph->AddMix($graph,0,0,85);
+$mgraph->AddMix($graph2,0,250,85);
+$mgraph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/contour2_ex1.php b/web/classes/jpgraph/Examples/contour2_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..764a8f29c034900777c70f41dba3a3968cfce434
--- /dev/null
+++ b/web/classes/jpgraph/Examples/contour2_ex1.php
@@ -0,0 +1,50 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contourf.php');
+
+// Setup some data to use for the contour
+$data = array(
+    array (12,12,10,10),
+    array (10,10,8,14),
+    array (7,7,13,17),
+    array (4,5,8,12),
+    array (10,8,7,8));
+
+// create a basic graph as a container
+$graph = new Graph(300,300);
+$graph->SetMargin(30, 30, 40, 30);
+$graph->SetScale('intint');
+$graph->SetMarginColor('white');
+
+// Setup title of graph
+$graph->title->Set('Filled contour plot');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+
+$graph->subtitle->Set('(With lines and labels)');
+$graph->subtitle->SetFont(FF_VERDANA,FS_ITALIC,10);
+
+// Create a new contour plot
+$cp = new FilledContourPlot($data);
+
+// Use only blue/red color schema
+$cp->UseHighContrastColor(true);
+
+// Flip visually 
+$cp->SetInvert();
+
+// Fill the contours
+$cp->SetFilled(true);
+
+// Display the labels
+$cp->ShowLabels(true,true);
+$cp->SetFont(FF_ARIAL,FS_BOLD,9);
+$cp->SetFontColor('white');
+
+// And add the plot to the graph
+$graph->Add($cp);
+
+// Send it back to the client
+$graph->stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/contour2_ex2.php b/web/classes/jpgraph/Examples/contour2_ex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..b702626bfd3870a68b182c392b69d1da4075c8f0
--- /dev/null
+++ b/web/classes/jpgraph/Examples/contour2_ex2.php
@@ -0,0 +1,51 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contourf.php');
+
+// Setup some data to use for the contour
+$data = array(
+    array (12,12,10,10),
+    array (10,10,8,14),
+    array (7,7,13,17),
+    array (4,5,8,12),
+    array (10,8,7,8));
+
+// create a basic graph as a container
+$graph = new Graph(300,300);
+$graph->SetMargin(30, 30, 40, 30);
+$graph->SetScale('intint');
+$graph->SetMarginColor('white');
+
+// Setup title of graph
+$graph->title->Set('Filled contour plot');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+
+$graph->subtitle->Set('(No lines, no labels)');
+$graph->subtitle->SetFont(FF_VERDANA,FS_ITALIC,10);
+
+// Create a new contour plot
+$cp = new FilledContourPlot($data);
+
+// Use only blue/red color schema
+$cp->UseHighContrastColor(true);
+
+// Flip visually 
+$cp->SetInvert();
+
+// Fill the contours
+$cp->SetFilled(true);
+
+// No labels
+$cp->ShowLabels(false);
+
+// No lines
+$cp->ShowLines(false);
+
+// And add the plot to the graph
+$graph->Add($cp);
+
+// Send it back to the client
+$graph->stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/contour2_ex3.php b/web/classes/jpgraph/Examples/contour2_ex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..93f7611ddadbe62c8818d559eeed6c00075e3992
--- /dev/null
+++ b/web/classes/jpgraph/Examples/contour2_ex3.php
@@ -0,0 +1,55 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contourf.php');
+
+// Setup some data to use for the contour
+$data = array(
+    array (12,12,10,10),
+    array (10,10,8,14),
+    array (7,7,13,17),
+    array (4,5,8,12),
+    array (10,8,7,8));
+
+// create a basic graph as a container
+$graph = new Graph(300,300);
+$graph->SetMargin(30, 30, 40, 30);
+$graph->SetScale('intint');
+$graph->SetMarginColor('white');
+
+// Setup title of graph
+$graph->title->Set('Filled contour plot');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+
+$graph->subtitle->Set('(Manual colors)');
+$graph->subtitle->SetFont(FF_VERDANA,FS_ITALIC,10);
+
+// Create a new contour plot with only 3 isobars
+$cp = new FilledContourPlot($data,3);
+
+// Specify the colors manually
+$isobar_colors = array('lightgray','teal:1.3','orange','red');
+$cp->SetIsobarColors($isobar_colors);
+
+// Use only blue/red color schema
+$cp->UseHighContrastColor(true);
+
+// Flip visually 
+$cp->SetInvert();
+
+// Fill the contours
+$cp->SetFilled(true);
+
+// Display labels
+$cp->ShowLabels(true);
+
+// No lines
+$cp->ShowLines(false);
+
+// And add the plot to the graph
+$graph->Add($cp);
+
+// Send it back to the client
+$graph->stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/contour2_ex4.php b/web/classes/jpgraph/Examples/contour2_ex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..79e43e89a6b3892c916edc8e512df47bba2f2ea2
--- /dev/null
+++ b/web/classes/jpgraph/Examples/contour2_ex4.php
@@ -0,0 +1,47 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contourf.php');
+
+// Setup some data to use for the contour
+$data = array(
+    array (12,12,10,10),
+    array (10,10,8,14),
+    array (7,7,13,17),
+    array (4,5,8,12),
+    array (10,8,7,8));
+
+// create a basic graph as a container
+$graph = new Graph(300,300);
+$graph->SetMargin(30, 30, 40, 30);
+$graph->SetScale('intint');
+$graph->SetMarginColor('white');
+
+// Setup title of graph
+$graph->title->Set('Filled contour plot');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+
+$graph->subtitle->Set('(labels follows gradients)');
+$graph->subtitle->SetFont(FF_VERDANA,FS_ITALIC,10);
+
+// Create a new contour plot
+$cp = new FilledContourPlot($data,8);
+
+// Flip visually 
+$cp->SetInvert();
+
+// Fill the contours
+$cp->SetFilled(true);
+
+// Display the labels
+$cp->ShowLabels(true,true);
+$cp->SetFont(FF_ARIAL,FS_BOLD,9);
+$cp->SetFontColor('black');
+
+// And add the plot to the graph
+$graph->Add($cp);
+
+// Send it back to the client
+$graph->stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/contour2_ex5.php b/web/classes/jpgraph/Examples/contour2_ex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..1d3ac433bb8e6b83a2adf1f485e6bab282384ab3
--- /dev/null
+++ b/web/classes/jpgraph/Examples/contour2_ex5.php
@@ -0,0 +1,52 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contourf.php');
+
+// Setup some data to use for the contour
+$data = array(
+    array (12,12,10,10),
+    array (10,10,8,14),
+    array (7,7,13,17),
+    array (4,5,8,12),
+    array (10,8,7,8));
+
+// create a basic graph as a container
+$graph = new Graph(300,300);
+$graph->SetMargin(30, 30, 40, 30);
+$graph->SetScale('intint');
+$graph->SetMarginColor('white');
+
+// Setup title of graph
+$graph->title->Set('Filled contour plot');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+
+$graph->subtitle->Set('(horizontal labels)');
+$graph->subtitle->SetFont(FF_VERDANA,FS_ITALIC,10);
+
+// Create a new contour plot
+$cp = new FilledContourPlot($data,8);
+
+// Use only black/and white schema
+$cp->UseHighContrastColor(true,true);
+
+// Flip visually 
+$cp->SetInvert();
+
+// Fill the contours
+$cp->SetFilled(true);
+// Show lines in red
+$cp->ShowLines(true,'red');
+
+// Display the labels
+$cp->ShowLabels(true,false);
+$cp->SetFont(FF_ARIAL,FS_BOLD,9);
+$cp->SetFontColor('white');
+
+// And add the plot to the graph
+$graph->Add($cp);
+
+// Send it back to the client
+$graph->stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/contour2_ex6.php b/web/classes/jpgraph/Examples/contour2_ex6.php
new file mode 100755
index 0000000000000000000000000000000000000000..49755bee3f07998731ca1e52dbdf5b8570ec6921
--- /dev/null
+++ b/web/classes/jpgraph/Examples/contour2_ex6.php
@@ -0,0 +1,53 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contourf.php');
+
+// Setup some data to use for the contour
+$data = array(
+    array (12,12,10,10),
+    array (10,10,8,14),
+    array (7,7,13,17),
+    array (4,5,8,12),
+    array (10,8,7,8));
+
+// create a basic graph as a container
+$graph = new Graph(300,300);
+$graph->SetMargin(30, 30, 40, 30);
+$graph->SetScale('intint');
+$graph->SetMarginColor('white');
+
+// Setup title of graph
+$graph->title->Set('Filled contour plot');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+
+$graph->subtitle->Set('(With lines and labels)');
+$graph->subtitle->SetFont(FF_VERDANA,FS_ITALIC,10);
+
+// Create a new contour plot
+$cp = new FilledContourPlot($data,7);
+
+// Use only blue/red color schema
+$cp->UseHighContrastColor(true);
+
+// Flip visually 
+$cp->SetInvert();
+
+// Fill the contours
+$cp->SetFilled(true);
+
+// Specify method to use
+$cp->SetMethod('rect');
+
+// Display the labels
+$cp->ShowLabels(true,true);
+$cp->SetFont(FF_ARIAL,FS_BOLD,9);
+$cp->SetFontColor('white');
+
+// And add the plot to the graph
+$graph->Add($cp);
+
+// Send it back to the client
+$graph->stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/contour2_ex7.php b/web/classes/jpgraph/Examples/contour2_ex7.php
new file mode 100755
index 0000000000000000000000000000000000000000..b83d3dd9e0f8abbf3285cf1fd9de87a3f741316f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/contour2_ex7.php
@@ -0,0 +1,53 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contourf.php');
+
+// Setup some data to use for the contour
+$data = array(
+    array (12,12,10,10),
+    array (10,10,8,14),
+    array (7,7,13,17),
+    array (4,5,8,12),
+    array (10,8,7,8));
+
+// create a basic graph as a container
+$graph = new Graph(300,300);
+$graph->SetMargin(30, 30, 40, 30);
+$graph->SetScale('intint');
+$graph->SetMarginColor('white');
+
+// Setup title of graph
+$graph->title->Set('Filled contour plot');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+
+$graph->subtitle->Set('(With lines and labels)');
+$graph->subtitle->SetFont(FF_VERDANA,FS_ITALIC,10);
+
+// Create a new contour plot
+$cp = new FilledContourPlot($data,7);
+
+// Use only blue/red color schema
+$cp->UseHighContrastColor(true);
+
+// Flip visually 
+$cp->SetInvert();
+
+// Fill the contours
+$cp->SetFilled(true);
+
+// Specify method to use
+$cp->SetMethod('tri');
+
+// Display the labels
+$cp->ShowLabels(true,true);
+$cp->SetFont(FF_ARIAL,FS_BOLD,9);
+$cp->SetFontColor('white');
+
+// And add the plot to the graph
+$graph->Add($cp);
+
+// Send it back to the client
+$graph->stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/contourex01.php b/web/classes/jpgraph/Examples/contourex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..eb2cb99c661e850b29cd0855b2ee2f68ee66549b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/contourex01.php
@@ -0,0 +1,48 @@
+<?php // content="text/plain; charset=utf-8"
+// Contour plot example 
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contour.php');
+
+$data = array( 
+            array (0.5,1.1,1.5,1,2.0,3,3,2,1,0.1),
+            array (1.0,1.5,3.0,5,6.0,2,1,1.2,1,4),
+            array (0.9,2.0,2.1,3,6.0,7,3,2,1,1.4),
+            array (1.0,1.5,3.0,4,6.0,5,2,1.5,1,2),
+            array (0.8,2.0,3.0,3,4.0,4,3,2.4,2,3),
+            array (0.6,1.1,1.5,1,4.0,3.5,3,2,3,4),
+            array (1.0,1.5,3.0,5,6.0,2,1,1.2,2.7,4),
+            array (0.8,2.0,3.0,3,5.5,6,3,2,1,1.4),
+            array (1.0,1.5,3.0,4,6.0,5,2,1,0.5,0.2));
+
+
+// Setup a basic graph context with some generous margins to be able
+// to fit the legend            
+$graph = new Graph(500,380);
+$graph->SetMargin(40,140,60,40);	
+
+$graph->title->Set('Example of contour plot');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+// For contour plots it is custom to use a box style ofr the axis
+$graph->legend->SetPos(0.05,0.5,'right','center');
+$graph->SetScale('intint');
+$graph->SetAxisStyle(AXSTYLE_BOXOUT);
+$graph->xgrid->Show();
+$graph->ygrid->Show();
+
+
+// A simple contour plot with default arguments (e.g. 10 isobar lines)
+$cp = new ContourPlot($data);
+
+// Display the legend
+$cp->ShowLegend();
+
+// Make the isobar lines slightly thicker
+$cp->SetLineWeight(2);
+$graph->Add($cp);
+
+// ... and send the graph back to the browser
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/contourex02.php b/web/classes/jpgraph/Examples/contourex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..73dee150349e1cc12dc3001f59076d2a882f2689
--- /dev/null
+++ b/web/classes/jpgraph/Examples/contourex02.php
@@ -0,0 +1,42 @@
+<?php // content="text/plain; charset=utf-8"
+// Contour plot example 02
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contour.php');
+
+$data = array(
+    array (12,12,10,10,8,4),
+    array (10,10,8,14,10,3),
+    array (7,7,13,17,12,8),
+    array (4,5,8,12,7,6),
+    array (10,8,7,8,10,4));
+
+// Setup a basic graph context with some generous margins to be able
+// to fit the legend
+$graph = new Graph(500,380);
+$graph->SetMargin(40,140,60,40);
+
+$graph->title->Set("Example of contour plot");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+// For contour plots it is custom to use a box style ofr the axis
+$graph->legend->SetPos(0.05,0.5,'right','center');
+$graph->SetScale('intint');
+$graph->SetAxisStyle(AXSTYLE_BOXOUT);
+$graph->xgrid->Show();
+$graph->ygrid->Show();
+
+
+// A simple contour plot with 12 isobar lines and flipped Y-coordinates
+$cp = new ContourPlot($data,12,true);
+
+// Display the legend
+$cp->ShowLegend();
+
+// Make the isobar lines slightly thicker
+$graph->Add($cp);
+
+// ... and send the graph back to the browser
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/contourex03.php b/web/classes/jpgraph/Examples/contourex03.php
new file mode 100755
index 0000000000000000000000000000000000000000..ea4308124599f8633be371075770caa69f39137e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/contourex03.php
@@ -0,0 +1,51 @@
+<?php // content="text/plain; charset=utf-8"
+// Contour plot example 
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contour.php');
+
+$data = array( 
+            array (0.5,1.1,1.5,1,2.0,3,3,2,1,0.1),
+            array (1.0,1.5,3.0,5,6.0,2,1,1.2,1,4),
+            array (0.9,2.0,2.1,3,6.0,7,3,2,1,1.4),
+            array (1.0,1.5,3.0,4,6.0,5,2,1.5,1,2),
+            array (0.8,2.0,3.0,3,4.0,4,3,2.4,2,3),
+            array (0.6,1.1,1.5,1,4.0,3.5,3,2,3,4),
+            array (1.0,1.5,3.0,5,6.0,2,1,1.2,2.7,4),
+            array (0.8,2.0,3.0,3,5.5,6,3,2,1,1.4),
+            array (1.0,1.5,3.0,4,6.0,5,2,1,0.5,0.2));
+
+
+// Setup a basic graph context with some generous margins to be able
+// to fit the legend            
+$graph = new Graph(500,380);
+$graph->SetMargin(40,140,60,40);	
+
+// Enable antialias. Note with antiaaliasing only line weight=1 is supported.
+$graph->img->SetAntiAliasing();
+
+$graph->title->Set("Example of contour plot");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+// For contour plots it is custom to use a box style ofr the axis
+$graph->legend->SetPos(0.05,0.5,'right','center');
+$graph->SetScale('intint');
+$graph->SetAxisStyle(AXSTYLE_BOXOUT);
+$graph->xgrid->Show();
+$graph->ygrid->Show();
+
+
+// A simple contour plot with 19 isobars and flipped vertical range
+$cp = new ContourPlot($data,10,true);
+
+// Display the legend
+$cp->ShowLegend();
+
+// Invert the legend to th lowest isobar is on top
+$cp->Invertlegend();
+$graph->Add($cp);
+
+// ... and send the graph back to the browser
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/contourex04.php b/web/classes/jpgraph/Examples/contourex04.php
new file mode 100755
index 0000000000000000000000000000000000000000..d37f13b5c3281fee3f72be2918fae0f997a93783
--- /dev/null
+++ b/web/classes/jpgraph/Examples/contourex04.php
@@ -0,0 +1,50 @@
+<?php // content="text/plain; charset=utf-8"
+// Contour plot example 04
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contour.php');
+
+$data = array(
+    array (12,12,10,10,8,4),
+    array (10,10,8,14,10,3),
+    array (7,7,13,17,12,8),
+    array (4,5,8,12,7,6),
+    array (10,8,7,8,10,4));
+
+// Setup a basic graph context with some generous margins to be able
+// to fit the legend
+$graph = new Graph(500,380);
+$graph->SetMargin(40,140,60,40);
+
+$graph->title->Set("Example of interpolated contour plot");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph->title->SetMargin(10);
+
+// For contour plots it is custom to use a box style ofr the axis
+$graph->legend->SetPos(0.05,0.5,'right','center');
+$graph->SetScale('intint');
+
+// Setup axis and grids
+$graph->SetAxisStyle(AXSTYLE_BOXOUT);
+$graph->xgrid->SetLineStyle('dashed');
+$graph->xgrid->Show(true);
+$graph->ygrid->SetLineStyle('dashed');
+$graph->ygrid->Show(true);
+
+// A simple contour plot with 10 isobar lines and flipped Y-coordinates
+// Make the data smoother by interpolate the original matrice by a factor of two
+// which will make each grid cell half the original size
+$cp = new ContourPlot($data,10, 2);
+
+$cp->UseHighContrastColor(true);
+
+// Display the legend
+$cp->ShowLegend();
+
+// Make the isobar lines slightly thicker
+$graph->Add($cp);
+
+// ... and send the graph back to the browser
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/contourex05.php b/web/classes/jpgraph/Examples/contourex05.php
new file mode 100755
index 0000000000000000000000000000000000000000..4af9ca8b49b007eecaf133eaa79bfd30cbffc150
--- /dev/null
+++ b/web/classes/jpgraph/Examples/contourex05.php
@@ -0,0 +1,59 @@
+<?php // content="text/plain; charset=utf-8"
+// Contour example 05
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_contour.php');
+
+$data = array(
+    array(0.000,0.001,0.002,0.005,-0.003,-0.053,-0.156,-0.245,-0.235,-0.143,-0.056,-0.014,-0.002,0.000,0.000),
+    array(0.000,0.002,0.009,0.015,-0.040,-0.308,-0.826,-1.257,-1.188,-0.719,-0.280,-0.070,-0.011,-0.001,0.000),
+    array(0.001,0.005,0.024,0.047,-0.103,-0.878,-2.432,-3.767,-3.591,-2.166,-0.828,-0.195,-0.026,-0.001,0.000),
+    array(0.001,0.007,0.046,0.145,0.096,-0.913,-3.472,-6.042,-6.038,-3.625,-1.283,-0.235,-0.005,0.007,0.002),
+    array(-0.003,-0.009,0.009,0.208,0.734,0.864,-0.937,-3.985,-4.866,-2.781,-0.560,0.194,0.151,0.043,0.007),
+    array(-0.013,-0.072,-0.229,-0.259,0.652,2.587,3.058,0.661,-1.097,0.014,1.336,1.154,0.474,0.113,0.017),
+    array(-0.028,-0.171,-0.653,-1.397,-1.091,1.421,3.424,1.942,0.403,1.784,2.986,2.120,0.821,0.191,0.028),
+    array(-0.037,-0.231,-0.934,-2.255,-2.780,-0.699,1.692,0.981,0.198,2.199,3.592,2.515,0.968,0.225,0.033),
+    array(-0.031,-0.201,-0.829,-2.076,-2.820,-1.399,0.610,0.408,0.122,1.882,3.004,2.085,0.800,0.186,0.027),
+    array(-0.018,-0.115,-0.469,-1.133,-1.343,0.011,1.921,2.256,1.824,2.115,2.141,1.312,0.481,0.110,0.016),
+    array(-0.007,-0.039,-0.130,-0.152,0.560,2.770,5.591,6.719,5.583,3.646,1.973,0.832,0.251,0.052,0.007),
+    array(-0.001,-0.003,0.024,0.273,1.297,3.628,6.515,7.832,6.517,3.875,1.690,0.546,0.130,0.022,0.003),
+    array(0.000,0.004,0.036,0.215,0.837,2.171,3.809,4.578,3.810,2.218,0.913,0.268,0.056,0.008,0.001),
+    array(0.000,0.002,0.014,0.076,0.284,0.721,1.257,1.511,1.257,0.728,0.294,0.083,0.017,0.002,0.000),                                        
+    array(0.000,0.000,0.003,0.016,0.057,0.144,0.250,0.300,0.250,0.144,0.058,0.016,0.003,0.000,0.000),        
+);
+    
+
+// Setup a basic graph context with some generous margins to be able
+// to fit the legend
+$graph = new Graph(480,390);
+$graph->SetMargin(40,120,60,50);
+
+$graph->title->Set("Contour plot, high contrast color");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->title->SetMargin(10);
+
+// For contour plots it is custom to use a box style ofr the axis
+$graph->SetScale('intint',0,56,0,56);
+
+// Setup axis and grids
+$graph->SetAxisStyle(AXSTYLE_BOXOUT);
+$graph->xgrid->Show(true);
+$graph->ygrid->Show(true);
+
+// A simple contour plot with 10 isobar lines and flipped Y-coordinates
+// Make the data smoother by interpolate the original matrice by a factor of two
+// which will make each grid cell half the original size
+$cp = new ContourPlot($data,10, 3);
+
+$cp->UseHighContrastColor(true);
+
+// Display the legend
+$cp->ShowLegend();
+
+// Make the isobar lines slightly thicker
+$graph->Add($cp);
+
+// ... and send the graph back to the browser
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/csim_in_html_ex1.php b/web/classes/jpgraph/Examples/csim_in_html_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..2c08e095780b81764afdf7a44e05bd98e4f77fe8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/csim_in_html_ex1.php
@@ -0,0 +1,61 @@
+<html>
+<body>
+
+<?php
+$_graphfilename = 'csim_in_html_graph_ex1.php';
+// This is the filename of this HTML file
+global $_wrapperfilename;
+$_wrapperfilename = basename (__FILE__);
+
+// Create a random mapname used to connect the image map with the image
+$_mapname = '__mapname'.rand(0,1000000).'__';
+
+// This is the first graph script
+require_once ($_graphfilename);
+
+// This line gets the image map and inserts it on the page
+$imgmap = $graph->GetHTMLImageMap($_mapname);
+echo $imgmap;
+
+?>
+
+<h2>This is an example page with CSIM graphs with arbitrary HTML text</h2>
+
+<?php
+if( empty($_GET['clickedon']) ) {
+   echo '<b style="color:darkred;">Clicked on bar: &lt;none></b>';
+}
+else {
+   echo '<b style="color:darkred;">Clicked on bar: '.$_GET['clickedon'].'</b>';
+}
+echo '<p />';
+?>
+
+<p>First we need to get hold of the image map and include it in the HTML
+  page.</p>
+<p>For this graph it is:</p>
+<?php
+
+// The we display the image map as well
+echo '<pre><b>'.htmlentities($imgmap).'</b></pre>';?>
+
+<?php
+// Construct the <img> tag and rebuild the
+$imgtag = $graph->GetCSIMImgHTML($_mapname,$_graphfilename);
+?>
+<p>The graph is then be displayed as shown in figure 1. With the following
+  created &lt;img> tag:</p>
+<pre><b>
+<?php echo htmlentities($imgtag); ?>
+</b></pre>
+
+
+<p>
+<?php
+echo $imgtag;
+?>
+<br><b>Figure 1. </b>The included CSIM graph.
+</p>
+
+</body>
+</html>
diff --git a/web/classes/jpgraph/Examples/csim_in_html_ex2.php b/web/classes/jpgraph/Examples/csim_in_html_ex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..c94bda3c3500421f24c6e9fbe1a6a5c3d0222309
--- /dev/null
+++ b/web/classes/jpgraph/Examples/csim_in_html_ex2.php
@@ -0,0 +1,100 @@
+<html>
+<body>
+
+<?php
+// The names of the graph scripts
+$_graphfilename1 = 'csim_in_html_graph_ex1.php';
+$_graphfilename2 = 'csim_in_html_graph_ex2.php';
+
+// This is the filename of this HTML file
+global $_wrapperfilename;
+$_wrapperfilename = basename (__FILE__);
+
+// Create a random mapname used to connect the image map with the image
+$_mapname1 = '__mapname'.rand(0,1000000).'__';
+$_mapname2 = '__mapname'.rand(0,1000000).'__';
+
+// Get the graph scripts
+require_once ($_graphfilename1);
+require_once ($_graphfilename2);
+
+// This line gets the image map and inserts it on the page
+$imgmap1 = $graph->GetHTMLImageMap($_mapname1);
+$imgmap2 = $piegraph->GetHTMLImageMap($_mapname2);
+echo $imgmap1;
+echo $imgmap2;
+
+?>
+
+<h2>This is an example page with CSIM graphs with arbitrary HTML text</h2>
+
+<?php
+if( empty($_GET['clickedon']) ) {
+   echo '<b style="color:darkred;">Clicked on bar: &lt;none></b>';
+}
+else {
+   echo '<b style="color:darkred;">Clicked on bar: '.$_GET['clickedon'].'</b>';
+}
+echo '<p />';
+if( empty($_GET['pie_clickedon']) ) {
+   echo '<b style="color:darkred;">Clicked on pie slice: &lt;none></b>';
+}
+else {
+   echo '<b style="color:darkred;">Clicked on pie slice: '.$_GET['pie_clickedon'].'</b>';
+}
+echo '<p />';
+?>
+
+<p>First we need to get hold of the image maps and include them in the HTML
+  page.</p>
+<p>For these graphs the maps are:</p>
+<?php
+// The we display the image map as well
+echo '<small><pre>'.htmlentities($imgmap1).'</pre></small>';
+?>
+<p>
+and
+</p>
+<?php
+// The we display the image map as well
+echo '<small><pre>'.htmlentities($imgmap2).'</pre></small>';
+?>
+
+<?php
+// Construct the <img> tags for Figure 1 &amp; 2 and rebuild the URL arguments
+$imgtag1 = $graph->GetCSIMImgHTML($_mapname1,$_graphfilename1);
+$imgtag2 = $piegraph->GetCSIMImgHTML($_mapname2,$_graphfilename2);
+?>
+<p>The graphs are then displayed as shown in figure 1 &amp; 2. With the following
+  created &lt;img> tags:</p>
+<small><pre>
+<?php 
+echo htmlentities($imgtag1); 
+echo htmlentities($imgtag2); 
+?>
+</pre></small>
+
+<p>
+Note: For the Pie the center is counted as the first slice.
+</p>
+
+<p>
+<table border=0>
+<tr><td valign="bottom">
+<?php
+echo $imgtag1;
+?>
+<br><b>Figure 1. </b>The included Bar CSIM graph.
+</p>
+</td>
+<td valign="bottom">
+<?php
+echo $imgtag2;
+?>
+<br><b>Figure 2. </b>The included Pie CSIM graph.
+</p>
+</td>
+</tr>
+</table>
+</body>
+</html>
diff --git a/web/classes/jpgraph/Examples/csim_in_html_graph_ex1.php b/web/classes/jpgraph/Examples/csim_in_html_graph_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..b734c8609e7b57648ae43244a1c888996d759e5d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/csim_in_html_graph_ex1.php
@@ -0,0 +1,46 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('../jpgraph.php');
+require_once ('../jpgraph_bar.php');
+
+$datay=array(12,26,9,17,31);
+
+// Create the graph.
+$graph = new Graph(400,250);
+$graph->SetScale('textlin');
+$graph->SetMargin(50,80,20,40);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+
+$n = count($datay) ; // Number of bars
+
+global $_wrapperfilename;
+
+// Create targets for the image maps. One for each column
+$targ = array(); $alt = array(); $wtarg = array();
+for( $i=0; $i < $n; ++$i ) {
+    $urlarg = 'clickedon='.($i+1);
+    $targ[] = $_wrapperfilename.'?'.$urlarg;
+    $alt[] = 'val=%d';
+    $wtarg[] = '';
+}
+$bplot->SetCSIMTargets($targ,$alt,$wtarg);
+
+$graph->Add($bplot);
+
+$graph->title->Set('Multiple Image maps');
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->title->SetCSIMTarget('#45','Title for Bar','_blank');
+
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetCSIMTarget('#55','Y-axis title');
+$graph->yaxis->title->Set("Y-title");
+
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetCSIMTarget('#55','X-axis title');
+$graph->xaxis->title->Set("X-title");
+
+// Send back the image when we are called from within the <img> tag
+$graph->StrokeCSIMImage();
+
+?>
diff --git a/web/classes/jpgraph/Examples/csim_in_html_graph_ex2.php b/web/classes/jpgraph/Examples/csim_in_html_graph_ex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..8c59c0c36331215943d5c9cc83e750746bc03640
--- /dev/null
+++ b/web/classes/jpgraph/Examples/csim_in_html_graph_ex2.php
@@ -0,0 +1,75 @@
+<?php // content="text/plain; charset=utf-8"
+// Example of pie with center circle
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+// Some data
+$data = array(50,28,25,27,31,20);
+
+// A new pie graph
+$piegraph = new PieGraph(400,320);
+
+$n = count($data) ; // Number of slices
+
+// No border around graph
+$piegraph->SetFrame(false);
+
+// Setup title
+$piegraph->title->Set("CSIM Center Pie plot");
+$piegraph->title->SetFont(FF_ARIAL,FS_BOLD,18);
+$piegraph->title->SetMargin(8); // Add a little bit more margin from the top
+
+// Create the pie plot
+$p1 = new PiePlotC($data);
+
+// Set the radius of pie (as fraction of image size)
+$p1->SetSize(0.32);
+
+// Label font and color setup
+$p1->value->SetFont(FF_ARIAL,FS_BOLD,11);
+$p1->value->SetColor('white');
+
+// Setup the title on the center circle
+$p1->midtitle->Set("Distribution\n2008 H1");
+$p1->midtitle->SetFont(FF_ARIAL,FS_NORMAL,12);
+
+// Set color for mid circle
+$p1->SetMidColor('yellow');
+
+// Use percentage values in the legends values (This is also the default)
+$p1->SetLabelType(PIE_VALUE_PER);
+
+// The label array values may have printf() formatting in them. The argument to the
+// form,at string will be the value of the slice (either the percetage or absolute
+// depending on what was specified in the SetLabelType() above.
+$lbl = array("Jan\n%.1f%%","Feb\n%.1f%%","March\n%.1f%%",
+             "Apr\n%.1f%%","May\n%.1f%%","Jun\n%.1f%%");
+$p1->SetLabels($lbl);
+
+// Add drop shadow to slices
+$p1->SetShadow();
+
+// Explode all slices 15 pixels
+$p1->ExplodeAll(15);
+
+// Setup the CSIM targets
+global $_wrapperfilename;
+$targ = array(); $alt = array(); $wtarg = array();
+for( $i=0; $i <= $n; ++$i ) {
+    $urlarg = 'pie_clickedon='.($i+1);
+    $targ[] = $_wrapperfilename.'?'.$urlarg;
+    $alt[] = 'val=%d';
+    $wtarg[] = '';
+}
+$p1->SetCSIMTargets($targ,$alt,$wtarg);
+$p1->SetMidCSIM($targ[0],$alt[0],$wtarg[0]);
+
+// Add plot to pie graph
+$piegraph->Add($p1);
+
+// Send back the image when we are called from within the <img> tag
+$piegraph->StrokeCSIMImage();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/datamatrix_ex0.php b/web/classes/jpgraph/Examples/datamatrix_ex0.php
new file mode 100755
index 0000000000000000000000000000000000000000..8de2522226b88e241b218e970eceef21b9f3ca4b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/datamatrix_ex0.php
@@ -0,0 +1,18 @@
+<?php
+require_once('jpgraph/datamatrix/datamatrix.inc.php');
+
+$data = 'The first datamatrix';
+$encoder = DatamatrixFactory::Create();
+$encoder->SetEncoding(ENCODING_ASCII);
+$backend = DatamatrixBackendFactory::Create($encoder);
+
+// We increase the module width to 3 pixels
+$backend->SetModuleWidth(3);
+
+try {
+    $backend->Stroke($data);
+} catch (Exception $e) {
+    echo 'Datamatrix error: '.$e->GetMessage()."\n";
+    exit(1);
+}
+?>
diff --git a/web/classes/jpgraph/Examples/datamatrix_ex00.php b/web/classes/jpgraph/Examples/datamatrix_ex00.php
new file mode 100755
index 0000000000000000000000000000000000000000..1aec89f39758824a27dcf186d5e259aa03f83cfd
--- /dev/null
+++ b/web/classes/jpgraph/Examples/datamatrix_ex00.php
@@ -0,0 +1,9 @@
+<?php
+require_once('jpgraph/datamatrix/datamatrix.inc.php');
+
+$data = 'The first datamatrix';
+
+$encoder = DatamatrixFactory::Create();
+$backend = DatamatrixBackendFactory::Create($encoder);
+$backend->Stroke($data);
+?>
diff --git a/web/classes/jpgraph/Examples/datamatrix_ex1.php b/web/classes/jpgraph/Examples/datamatrix_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..a2e735836ca136867f1cd66fe014bee43cde6059
--- /dev/null
+++ b/web/classes/jpgraph/Examples/datamatrix_ex1.php
@@ -0,0 +1,18 @@
+<?php
+require_once('jpgraph/datamatrix/datamatrix.inc.php');
+
+$data = '123456';
+
+$encoder = DatamatrixFactory::Create();
+$backend = DatamatrixBackendFactory::Create($encoder);
+$backend->SetModuleWidth(3);
+
+// Create the barcode from the given data string and write to output file
+try {
+    $backend->Stroke($data);
+} catch (Exception $e) {
+    $errstr = $e->GetMessage();
+    echo "Datamatrix error message: $errstr\n";
+}
+
+?>
diff --git a/web/classes/jpgraph/Examples/datamatrix_ex2.php b/web/classes/jpgraph/Examples/datamatrix_ex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..e7c9462b47c1ce3a23b536ab0fa20ee72bb3439b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/datamatrix_ex2.php
@@ -0,0 +1,21 @@
+<?php
+require_once('jpgraph/datamatrix/datamatrix.inc.php');
+
+$data = '123456';
+
+// Create and set parameters for the encoder
+$encoder = DatamatrixFactory::Create();
+$encoder->SetEncoding(ENCODING_BASE256);
+
+// Create the image backend (default)
+$backend = DatamatrixBackendFactory::Create($encoder);
+$backend->SetModuleWidth(3);
+
+try {
+    $backend->Stroke($data);
+} catch (Exception $e) {
+    $errstr = $e->GetMessage();
+    echo "Datamatrix error message: $errstr\n";
+}
+
+?>
diff --git a/web/classes/jpgraph/Examples/datamatrix_ex3.php b/web/classes/jpgraph/Examples/datamatrix_ex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..6b6b8279eb8f2103a316d2b066bef07104427c38
--- /dev/null
+++ b/web/classes/jpgraph/Examples/datamatrix_ex3.php
@@ -0,0 +1,21 @@
+<?php
+require_once('jpgraph/datamatrix/datamatrix.inc.php');
+
+$data = '123456';
+
+// Create and set parameters for the encoder
+$encoder = DatamatrixFactory::Create(DMAT_44x44);
+$encoder->SetEncoding(ENCODING_BASE256);
+
+// Create the image backend (default)
+$backend = DatamatrixBackendFactory::Create($encoder);
+$backend->SetModuleWidth(3);
+
+try {
+    $backend->Stroke($data);
+} catch (Exception $e) {
+    $errstr = $e->GetMessage();
+    echo "Datamatrix error message: $errstr\n";
+}
+
+?>
diff --git a/web/classes/jpgraph/Examples/datamatrix_ex4.php b/web/classes/jpgraph/Examples/datamatrix_ex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..77b36674d157fee5d357d5b2c67452742f26c270
--- /dev/null
+++ b/web/classes/jpgraph/Examples/datamatrix_ex4.php
@@ -0,0 +1,25 @@
+<?php
+require_once('jpgraph/datamatrix/datamatrix.inc.php');
+
+$data = 'This is a 64x64 datamatrix symbol';
+
+// Create and set parameters for the encoder
+$encoder = DatamatrixFactory::Create(DMAT_64x64);
+$encoder->SetEncoding(ENCODING_TEXT);
+
+// Create the image backend (default)
+$backend = DatamatrixBackendFactory::Create($encoder);
+$backend->SetModuleWidth(3);
+
+// Adjust the Quiet zone
+$backend->SetQuietZone(10);
+
+// Create the barcode from the given data string and write to output file
+try {
+    $backend->Stroke($data);
+} catch (Exception $e) {
+    $errstr = $e->GetMessage();
+    echo "Datamatrix error message: $errstr\n";
+}
+
+?>
diff --git a/web/classes/jpgraph/Examples/datamatrix_ex5.php b/web/classes/jpgraph/Examples/datamatrix_ex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..9242252eb1bb885cbc29da77f49d574cf646cd4c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/datamatrix_ex5.php
@@ -0,0 +1,30 @@
+<?php
+require_once('jpgraph/datamatrix/datamatrix.inc.php');
+
+$data = 'This is a 20x20 symbol';
+
+// Create and set parameters for the encoder
+$encoder = DatamatrixFactory::Create(DMAT_20x20);
+$encoder->SetEncoding(ENCODING_TEXT);
+
+// Create the image backend (default)
+$backend = DatamatrixBackendFactory::Create($encoder);
+
+// By default the module width is 2 pixel so we increase it a bit
+$backend->SetModuleWidth(4);
+
+// Set Quiet zone
+$backend->SetQuietZone(10);
+
+// Set other than default colors (one, zero, quiet zone/background)
+$backend->SetColor('navy','white','lightgray');
+
+// Create the barcode from the given data string and write to output file
+try {
+    $backend->Stroke($data);
+} catch (Exception $e) {
+    $errstr = $e->GetMessage();
+    echo "Datamatrix error message: $errstr\n";
+}
+
+?>
diff --git a/web/classes/jpgraph/Examples/datamatrix_ex6.php b/web/classes/jpgraph/Examples/datamatrix_ex6.php
new file mode 100755
index 0000000000000000000000000000000000000000..918bc4b1ee66a706362e9a1db15fb5a3e887e08e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/datamatrix_ex6.php
@@ -0,0 +1,33 @@
+<?php
+require_once('jpgraph/datamatrix/datamatrix.inc.php');
+
+$data = 'This is a datamatrix symbol';
+
+$outputfile = 'dm_ex6.png';
+
+// Create and set parameters for the encoder
+$encoder = DatamatrixFactory::Create();
+$encoder->SetEncoding(ENCODING_TEXT);
+
+// Create the image backend (default)
+$backend = DatamatrixBackendFactory::Create($encoder);
+$backend->SetModuleWidth(5);
+$backend->SetQuietZone(10);
+
+// Set other than default colors (one, zero, background)
+$backend->SetColor('navy','white');
+
+// Create the barcode from the given data string and write to output file
+$dir = dirname(__FILE__);
+$file = '<span style="font-weight:bold;">"'.$dir.'/'.$outputfile.'"</span>';
+try {
+    $backend->Stroke($data,$outputfile);
+    echo 'Barcode sucessfully written to file: '.$file;
+} catch (Exception $e) {
+    $errstr = $e->GetMessage();
+    $errcode = $e->GetCode();
+    echo "Failed writing file: ".$file.'<br>';
+    echo "Datamatrix error ($errcode). Message: $errstr\n";
+}
+
+?>
diff --git a/web/classes/jpgraph/Examples/datamatrix_ex7.php b/web/classes/jpgraph/Examples/datamatrix_ex7.php
new file mode 100755
index 0000000000000000000000000000000000000000..a27d42cf52a997fe3945731c1a70b450d31804f5
--- /dev/null
+++ b/web/classes/jpgraph/Examples/datamatrix_ex7.php
@@ -0,0 +1,22 @@
+<?php
+require_once('jpgraph/datamatrix/datamatrix.inc.php');
+
+$data = 'A Datamatrix barcode';
+
+// Create and set parameters for the encoder
+$encoder = DatamatrixFactory::Create();
+$encoder->SetEncoding(ENCODING_BASE256);
+
+// Create the image backend (default)
+$backend = DatamatrixBackendFactory::Create($encoder, BACKEND_ASCII);
+$backend->SetModuleWidth(3);
+
+try {
+    $ps_txt = $backend->Stroke($data);
+    echo '<pre>'.$ps_txt.'</pre>';
+} catch (Exception $e) {
+    $errstr = $e->GetMessage();
+    echo "Datamatrix error message: $errstr\n";
+}
+
+?>
diff --git a/web/classes/jpgraph/Examples/dataset01.inc.php b/web/classes/jpgraph/Examples/dataset01.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..6ac7f2b09b91454d73744a10aa015c1b2cc44548
--- /dev/null
+++ b/web/classes/jpgraph/Examples/dataset01.inc.php
@@ -0,0 +1,275 @@
+<?php
+
+// Dataset to be used by some date scale utils examples
+
+$ydata = array(
+    0 => 1.0885908919277, 1 =>
+    0.99034385297982, 2 => 0.97005467188578, 3 =>
+    0.99901201350824, 4 => 1.1263167971152, 5 =>
+    1.0582808133448, 6 => 1.0216740689064, 7 =>
+    0.96626236356644, 8 => 1.0125912828768, 9 =>
+    0.99047473992496, 10 => 0.99102472104561, 11 =>
+    0.98500781573283, 12 => 0.91933668914198, 13 =>
+    0.92234602792711, 14 => 0.88933863410054, 15 =>
+    0.94236150975178, 16 => 0.98924287679116, 17 =>
+    1.0342765545566, 18 => 1.0538510278089, 19 =>
+    0.93496076181191, 20 => 0.90944479677235, 21 =>
+    0.80831866316983, 22 => 0.81912434615535, 23 =>
+    0.83143770042109, 24 => 0.86972168159496, 25 =>
+    0.92645774571577, 26 => 0.81169120061422, 27 =>
+    0.84409853057606, 28 => 0.89065856249272, 29 =>
+    0.83551478929348, 30 => 0.87015680306726, 31 =>
+    0.76063327042172, 32 => 0.82720958380697, 33 =>
+    0.86565279505723, 34 => 0.77858966246836, 35 =>
+    0.81009606378237, 36 => 0.80485136798149, 37 =>
+    0.82641461943804, 38 => 0.87442020676513, 39 =>
+    0.89589150146825, 40 => 0.92082995956816, 41 =>
+    0.92614241931726, 42 => 0.96915564652581, 43 =>
+    1.003753706293, 44 => 0.97438809368023, 45 =>
+    1.011556766867, 46 => 1.0785692014115, 47 =>
+    1.0586915420364, 48 => 1.284210059027, 49 =>
+    1.3424512661794, 50 => 1.1743365450983, 51 =>
+    1.2387345559532, 52 => 1.2485728609648, 53 =>
+    1.2330096418558, 54 => 1.1857882621709, 55 =>
+    1.2344956522411, 56 => 1.2047675730648, 57 =>
+    1.292419000136, 58 => 1.3405480219013, 59 =>
+    1.3971752198648, 60 => 1.4359555309649, 61 =>
+    1.3243735045701, 62 => 1.2359389187087, 63 =>
+    1.2201320423161, 64 => 1.3602246705197, 65 =>
+    1.360886940568, 66 => 1.3493553211075, 67 =>
+    1.4401769929405, 68 => 1.3979767849951, 69 =>
+    1.4545882591647, 70 => 1.337801210539, 71 =>
+    1.3793601365977, 72 => 1.4586769476223, 73 =>
+    1.5230946076475, 74 => 1.4124735946125, 75 =>
+    1.4030318592551, 76 => 1.349158816711, 77 =>
+    1.3994840622105, 78 => 1.4239672612346, 79 =>
+    1.40812256221, 80 => 1.4583856197192, 81 =>
+    1.4613314581567, 82 => 1.6756755916668, 83 =>
+    1.8580313939158, 84 => 1.8342360959805, 85 =>
+    1.9216082598086, 86 => 1.9478846253628, 87 =>
+    2.0244872112436, 88 => 1.9560660777181, 89 =>
+    1.8415152640121, 90 => 1.8471764273372, 91 =>
+    1.8889886695023, 92 => 1.8195007209252, 93 =>
+    1.8960270595999, 94 => 1.8644490575386, 95 =>
+    1.971196340772, 96 => 2.015583152659, 97 =>
+    1.9959882430428, 98 => 2.1063668082622, 99 =>
+    2.1719175769191, 100 => 2.1875938345039, 101 =>
+    2.1587594039981, 102 => 2.1278241823627, 103 =>
+    2.298793912594, 104 => 2.3723774302753, 105 =>
+    2.4413392788904, 106 => 2.4834594954125, 107 =>
+    2.5164271989421, 108 => 2.48274719503, 109 =>
+    2.4492997581034, 110 => 2.1412357263019, 111 =>
+    2.0314268112566, 112 => 1.9596098764628, 113 =>
+    2.0250983127109, 114 => 1.924959829851, 115 =>
+    1.9603612943993, 116 => 2.0540576271866, 117 =>
+    2.0568349960689, 118 => 2.0811524692325, 119 =>
+    2.0581964759165, 120 => 2.020162840272, 121 =>
+    2.0626517638667, 122 => 1.9286563823225, 123 =>
+    2.0127912437563, 124 => 1.9491858277931, 125 =>
+    1.8692310150316, 126 => 1.6993275416762, 127 =>
+    1.5849680675709, 128 => 1.5422481968304, 129 =>
+    1.603188853916, 130 => 1.6449504349551, 131 =>
+    1.6570332084417, 132 => 1.7563884552262, 133 =>
+    1.7346008663135, 134 => 1.741307942998, 135 =>
+    1.7415848536123, 136 => 1.7014366147405, 137 =>
+    1.6719646364256, 138 => 1.7092888030342, 139 =>
+    1.7371529028402, 140 => 1.7019154041991, 141 =>
+    1.7662473702497, 142 => 1.8480766044197, 143 =>
+    1.8355114169662, 144 => 1.7819817315586, 145 =>
+    1.7148079481036, 146 => 1.6241989833489, 147 =>
+    1.4624626548138, 148 => 1.5040542012939, 149 =>
+    1.442295346913, 150 => 1.4187087000604, 151 =>
+    1.4225097958511, 152 => 1.5001324671865, 153 =>
+    1.4584802723727, 154 => 1.5342572961469, 155 =>
+    1.514133174734, 156 => 1.5443934302345, 157 =>
+    1.5476883863698, 158 => 1.6080128685721, 159 =>
+    1.5816649899396, 160 => 1.5310436755918, 161 =>
+    1.518280754595, 162 => 1.5216184249044, 163 =>
+    1.4393414811719, 164 => 1.409379582707, 165 =>
+    1.436861898056, 166 => 1.4739894373751, 167 =>
+    1.4512785421546, 168 => 1.496057581316, 169 =>
+    1.3817455776456, 170 => 1.2990312802211, 171 =>
+    1.3073949130374, 172 => 1.2473214566896, 173 =>
+    1.1105915111374, 174 => 1.0420360580822, 175 =>
+    1.1744654786356, 176 => 1.0602876800127, 177 =>
+    1.074408841208, 178 => 1.18387615056, 179 =>
+    1.1890999077101, 180 => 1.0549293038746, 181 =>
+    1.0570601708416, 182 => 1.0800216692849, 183 =>
+    0.96274117702549, 184 => 0.9501673977047, 185 =>
+    0.97710108451711, 186 => 0.89886322996001, 187 =>
+    0.9239453369566, 188 => 0.96299807255386, 189 =>
+    1.0105532418267, 190 => 1.0164009465948, 191 =>
+    1.0413107606824, 192 => 1.0475248122459, 193 =>
+    1.0266007451985, 194 => 1.0159556206533, 195 =>
+    1.0943852922517, 196 => 1.0750418553654, 197 =>
+    0.97774129938915, 198 => 0.98590717162284, 199 =>
+    0.87713795242119, 200 => 0.90770624057599, 201 =>
+    0.87557547650302, 202 => 0.95754187545856, 203 =>
+    1.0111465867283, 204 => 0.93224663470275, 205 =>
+    0.93886113881632, 206 => 0.94128877256653, 207 =>
+    0.9559086414866, 208 => 0.97782683000598, 209 =>
+    1.0648991708916, 210 => 1.1759619281479, 211 =>
+    1.1323001889786, 212 => 1.2173222321276, 213 =>
+    1.192219780365, 214 => 1.1507367671992, 215 =>
+    1.0062415877475, 216 => 1.0017043563084, 217 =>
+    0.94468309902865, 218 => 0.99384124056529, 219 =>
+    1.0514822705943, 220 => 1.0451723914426, 221 =>
+    1.0776122119814, 222 => 1.2013601009631, 223 =>
+    1.1765086398423, 224 => 1.2387735028784, 225 =>
+    1.2441365026242, 226 => 1.2694500268723, 227 =>
+    1.2789962941485, 228 => 1.2442094256309, 229 =>
+    1.2352688438234, 230 => 1.2571277155372, 231 =>
+    1.3291795377077, 232 => 1.2703480599183, 233 =>
+    1.30729508393, 234 => 1.3233030218068, 235 =>
+    1.2861232143244, 236 => 1.3168684998023, 237 =>
+    1.2499001566772, 238 => 1.2622769692485, 239 =>
+    1.2160789893735, 240 => 1.2288877111321, 241 =>
+    1.222967255453, 242 => 1.2998243638567, 243 =>
+    1.3443008723449, 244 => 1.339680674028, 245 =>
+    1.3779965791538, 246 => 1.3560080691721, 247 =>
+    1.3470544172094, 248 => 1.3166882067851, 249 =>
+    1.4452459865932, 250 => 1.4514278120119, 251 =>
+    1.413690283372, 252 => 1.4178934332405, 253 =>
+    1.4237414657565, 254 => 1.3777636409301, 255 =>
+    1.4041849448389, 256 => 1.4049533546771, 257 =>
+    1.4277375831259, 258 => 1.4224090113077, 259 =>
+    1.4647907974628, 260 => 1.4243190632657, 261 =>
+    1.4286580133998, 262 => 1.4348828641501, 263 =>
+    1.415409243977, 264 => 1.4476028555859, 265 =>
+    1.4538821661641, 266 => 1.4883184435336, 267 =>
+    1.4205032194634, 268 => 1.3856543933372, 269 =>
+    1.2716906168086, 270 => 1.3462117624752, 271 =>
+    1.3003015423298, 272 => 1.2148491725878, 273 =>
+    1.2605381058318, 274 => 1.2690047369619, 275 =>
+    1.3327723638582, 276 => 1.3118643588249, 277 =>
+    1.293007944258, 278 => 1.2548761810876, 279 =>
+    1.3335015938603, 280 => 1.3152744239077, 281 =>
+    1.2564376463182, 282 => 1.2478417859372, 283 =>
+    1.2518821298414, 284 => 1.2036453589032, 285 =>
+    1.1798564480155, 286 => 1.2062515260098, 287 =>
+    1.2129817801455, 288 => 1.1405762096618, 289 =>
+    1.0161049810033, 290 => 1.0030124197677, 291 =>
+    1.0111565082559, 292 => 1.0084286839061, 293 =>
+    0.95068297130577, 294 => 1.0450005357207, 295 =>
+    1.211596899292, 296 => 1.3762615912002, 297 =>
+    1.530127116787, 298 => 1.5167370832585, 299 =>
+    1.6259521507076, 300 => 1.6518467383405, 301 =>
+    1.7713043850286, 302 => 1.6396708687084, 303 =>
+    1.6116177484122, 304 => 1.5225729470695, 305 =>
+    1.6101471149808);
+
+
+$xdata = array(
+
+    0 => 444348000, 1 => 446853600, 2 =>
+    449532000, 3 => 452124000, 4 => 454802400, 5 =>
+    457394400, 6 => 460072800, 7 => 462751200, 8 =>
+    465343200, 9 => 468021600, 10 => 470613600, 11 =>
+    473292000, 12 => 475970400, 13 => 478389600, 14 =>
+    481068000, 15 => 483660000, 16 => 486338400, 17 =>
+    488930400, 18 => 491608800, 19 => 494287200, 20 =>
+    496879200, 21 => 499557600, 22 => 502149600, 23 =>
+    504828000, 24 => 507506400, 25 => 509925600, 26 =>
+    512604000, 27 => 515196000, 28 => 517874400, 29 =>
+    520466400, 30 => 523144800, 31 => 525823200, 32 =>
+    528415200, 33 => 531093600, 34 => 533685600, 35 =>
+    536364000, 36 => 539042400, 37 => 541461600, 38 =>
+    544140000, 39 => 546732000, 40 => 549410400, 41 =>
+    552002400, 42 => 554680800, 43 => 557359200, 44 =>
+    559951200, 45 => 562629600, 46 => 565221600, 47 =>
+    567900000, 48 => 570578400, 49 => 573084000, 50 =>
+    575762400, 51 => 578354400, 52 => 581032800, 53 =>
+    583624800, 54 => 586303200, 55 => 588981600, 56 =>
+    591573600, 57 => 594252000, 58 => 596844000, 59 =>
+    599522400, 60 => 602200800, 61 => 604620000, 62 =>
+    607298400, 63 => 609890400, 64 => 612568800, 65 =>
+    615160800, 66 => 617839200, 67 => 620517600, 68 =>
+    623109600, 69 => 625788000, 70 => 628380000, 71 =>
+    631058400, 72 => 633736800, 73 => 636156000, 74 =>
+    638834400, 75 => 641426400, 76 => 644104800, 77 =>
+    646696800, 78 => 649375200, 79 => 652053600, 80 =>
+    654645600, 81 => 657324000, 82 => 659916000, 83 =>
+    662594400, 84 => 665272800, 85 => 667692000, 86 =>
+    670370400, 87 => 672962400, 88 => 675640800, 89 =>
+    678232800, 90 => 680911200, 91 => 683589600, 92 =>
+    686181600, 93 => 688860000, 94 => 691452000, 95 =>
+    694130400, 96 => 696808800, 97 => 699314400, 98 =>
+    701992800, 99 => 704584800, 100 => 707263200, 101 =>
+    709855200, 102 => 712533600, 103 => 715212000, 104 =>
+    717804000, 105 => 720482400, 106 => 723074400, 107 =>
+    725752800, 108 => 728431200, 109 => 730850400, 110 =>
+    733528800, 111 => 736120800, 112 => 738799200, 113 =>
+    741391200, 114 => 744069600, 115 => 746748000, 116 =>
+    749340000, 117 => 752018400, 118 => 754610400, 119 =>
+    757288800, 120 => 759967200, 121 => 762386400, 122 =>
+    765064800, 123 => 767656800, 124 => 770335200, 125 =>
+    772927200, 126 => 775605600, 127 => 778284000, 128 =>
+    780876000, 129 => 783554400, 130 => 786146400, 131 =>
+    788824800, 132 => 791503200, 133 => 793922400, 134 =>
+    796600800, 135 => 799192800, 136 => 801871200, 137 =>
+    804463200, 138 => 807141600, 139 => 809820000, 140 =>
+    812412000, 141 => 815090400, 142 => 817682400, 143 =>
+    820360800, 144 => 823039200, 145 => 825544800, 146 =>
+    828223200, 147 => 830815200, 148 => 833493600, 149 =>
+    836085600, 150 => 838764000, 151 => 841442400, 152 =>
+    844034400, 153 => 846712800, 154 => 849304800, 155 =>
+    851983200, 156 => 854661600, 157 => 857080800, 158 =>
+    859759200, 159 => 862351200, 160 => 865029600, 161 =>
+    867621600, 162 => 870300000, 163 => 872978400, 164 =>
+    875570400, 165 => 878248800, 166 => 880840800, 167 =>
+    883519200, 168 => 886197600, 169 => 888616800, 170 =>
+    891295200, 171 => 893887200, 172 => 896565600, 173 =>
+    899157600, 174 => 901836000, 175 => 904514400, 176 =>
+    907106400, 177 => 909784800, 178 => 912376800, 179 =>
+    915055200, 180 => 917733600, 181 => 920152800, 182 =>
+    922831200, 183 => 925423200, 184 => 928101600, 185 =>
+    930693600, 186 => 933372000, 187 => 936050400, 188 =>
+    938642400, 189 => 941320800, 190 => 943912800, 191 =>
+    946591200, 192 => 949269600, 193 => 951775200, 194 =>
+    954453600, 195 => 957045600, 196 => 959724000, 197 =>
+    962316000, 198 => 964994400, 199 => 967672800, 200 =>
+    970264800, 201 => 972943200, 202 => 975535200, 203 =>
+    978213600, 204 => 980892000, 205 => 983311200, 206 =>
+    985989600, 207 => 988581600, 208 => 991260000, 209 =>
+    993852000, 210 => 996530400, 211 => 999208800, 212 =>
+    1001800800, 213 => 1004479200, 214 => 1007071200,
+    215 => 1009749600, 216 => 1012428000, 217 =>
+    1014847200, 218 => 1017525600, 219 => 1020117600,
+    220 => 1022796000, 221 => 1025388000, 222 =>
+    1028066400, 223 => 1030744800, 224 => 1033336800,
+    225 => 1036015200, 226 => 1038607200, 227 =>
+    1041285600, 228 => 1043964000, 229 => 1046383200,
+    230 => 1049061600, 231 => 1051653600, 232 =>
+    1054332000, 233 => 1056924000, 234 => 1059602400,
+    235 => 1062280800, 236 => 1064872800, 237 =>
+    1067551200, 238 => 1070143200, 239 => 1072821600,
+    240 => 1075500000, 241 => 1078005600, 242 =>
+    1080684000, 243 => 1083276000, 244 => 1085954400,
+    245 => 1088546400, 246 => 1091224800, 247 =>
+    1093903200, 248 => 1096495200, 249 => 1099173600,
+    250 => 1101765600, 251 => 1104444000, 252 =>
+    1107122400, 253 => 1109541600, 254 => 1112220000,
+    255 => 1114812000, 256 => 1117490400, 257 =>
+    1120082400, 258 => 1122760800, 259 => 1125439200,
+    260 => 1128031200, 261 => 1130709600, 262 =>
+    1133301600, 263 => 1135980000, 264 => 1138658400,
+    265 => 1141077600, 266 => 1143756000, 267 =>
+    1146348000, 268 => 1149026400, 269 => 1151618400,
+    270 => 1154296800, 271 => 1156975200, 272 =>
+    1159567200, 273 => 1162245600, 274 => 1164837600,
+    275 => 1167516000, 276 => 1170194400, 277 =>
+    1172613600, 278 => 1175292000, 279 => 1177884000,
+    280 => 1180562400, 281 => 1183154400, 282 =>
+    1185832800, 283 => 1188511200, 284 => 1191103200,
+    285 => 1193781600, 286 => 1196373600, 287 =>
+    1199052000, 288 => 1201730400, 289 => 1204236000,
+    290 => 1206914400, 291 => 1209506400, 292 =>
+    1212184800, 293 => 1214776800, 294 => 1217455200,
+    295 => 1220133600, 296 => 1222725600, 297 =>
+    1225404000, 298 => 1227996000, 299 => 1230674400,
+    300 => 1233352800, 301 => 1235772000, 302 =>
+    1238450400, 303 => 1241042400, 304 => 1243720800,
+    305 => 1246312800,
+    );
+
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/dateaxisex1.php b/web/classes/jpgraph/Examples/dateaxisex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..58e4348f4d9c611b0f552d516bbf998baeb7d8dc
--- /dev/null
+++ b/web/classes/jpgraph/Examples/dateaxisex1.php
@@ -0,0 +1,55 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// The callback that converts timestamp to minutes and seconds
+function TimeCallback($aVal) {
+    return Date('H:i:s',$aVal);
+}
+
+// Fake some suitable random data
+$now = time();
+$datax = array($now);
+for( $i=0; $i < 360; $i += 10 ) {
+    $datax[] = $now + $i;
+}
+$n = count($datax);
+$datay=array();
+for( $i=0; $i < $n; ++$i ) {
+    $datay[] = rand(30,150);
+}
+
+// Setup the basic graph
+$graph = new Graph(324,250);
+$graph->SetMargin(40,40,30,70);	
+$graph->title->Set('Date: '.date('Y-m-d',$now));
+$graph->SetAlphaBlending();
+
+// Setup a manual x-scale (We leave the sentinels for the
+// Y-axis at 0 which will then autoscale the Y-axis.)
+// We could also use autoscaling for the x-axis but then it
+// probably will start a little bit earlier than the first value
+// to make the first value an even number as it sees the timestamp
+// as an normal integer value.
+$graph->SetScale("intlin",0,200,$now,$datax[$n-1]);
+
+// Setup the x-axis with a format callback to convert the timestamp
+// to a user readable time
+$graph->xaxis->SetLabelFormatCallback('TimeCallback');
+$graph->xaxis->SetLabelAngle(90);
+
+// Create the line
+$p1 = new LinePlot($datay,$datax);
+$p1->SetColor("blue");
+
+// Set the fill color partly transparent
+$p1->SetFillColor("blue@0.4");
+
+// Add lineplot to the graph
+$graph->Add($p1);
+
+// Output line
+$graph->Stroke();
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/dateaxisex2.php b/web/classes/jpgraph/Examples/dateaxisex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..c0a306c1bfaec95a37876c1c1aa487716ee7a3b1
--- /dev/null
+++ b/web/classes/jpgraph/Examples/dateaxisex2.php
@@ -0,0 +1,38 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_date.php');
+
+// Create a data set in range (50,70) and X-positions
+DEFINE('NDATAPOINTS',360);
+DEFINE('SAMPLERATE',240); 
+$start = time();
+$end = $start+NDATAPOINTS*SAMPLERATE;
+$data = array();
+$xdata = array();
+for( $i=0; $i < NDATAPOINTS; ++$i ) {
+    $data[$i] = rand(50,70);
+    $xdata[$i] = $start + $i * SAMPLERATE;
+}
+
+
+// Create the new graph
+$graph = new Graph(540,300);
+
+// Slightly larger than normal margins at the bottom to have room for
+// the x-axis labels
+$graph->SetMargin(40,40,30,130);
+
+// Fix the Y-scale to go between [0,100] and use date for the x-axis
+$graph->SetScale('datlin',0,100);
+$graph->title->Set("Example on Date scale");
+
+// Set the angle for the labels to 90 degrees
+$graph->xaxis->SetLabelAngle(90);
+
+$line = new LinePlot($data,$xdata);
+$line->SetLegend('Year 2005');
+$line->SetFillColor('lightblue@0.5');
+$graph->Add($line);
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/dateaxisex3.php b/web/classes/jpgraph/Examples/dateaxisex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..02db7cc5cdb96dd984da73e8348bcc752d3a1488
--- /dev/null
+++ b/web/classes/jpgraph/Examples/dateaxisex3.php
@@ -0,0 +1,48 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_date.php');
+
+// Create a data set in range (50,70) and X-positions
+DEFINE('NDATAPOINTS',360);
+DEFINE('SAMPLERATE',240); 
+$start = time();
+$end = $start+NDATAPOINTS*SAMPLERATE;
+$data = array();
+$xdata = array();
+for( $i=0; $i < NDATAPOINTS; ++$i ) {
+    $data[$i] = rand(50,70);
+    $xdata[$i] = $start + $i * SAMPLERATE;
+}
+
+
+// Create the new graph
+$graph = new Graph(540,300);
+
+// Slightly larger than normal margins at the bottom to have room for
+// the x-axis labels
+$graph->SetMargin(40,40,30,130);
+
+// Fix the Y-scale to go between [0,100] and use date for the x-axis
+$graph->SetScale('datlin',0,100);
+$graph->title->Set("Example on Date scale");
+
+// Set the angle for the labels to 90 degrees
+$graph->xaxis->SetLabelAngle(90);
+
+// It is possible to adjust the density for the X-axis as well
+// The following call makes the dates a little more sparse
+// $graph->SetTickDensity(TICKD_NORMAL,TICKD_SPARSE);
+
+// The automatic format string for dates can be overridden
+// $graph->xaxis->scale->SetDateFormat('h:i');
+
+// Adjust the start/end to a specific alignment
+$graph->xaxis->scale->SetTimeAlign(MINADJ_15);
+
+$line = new LinePlot($data,$xdata);
+$line->SetLegend('Year 2005');
+$line->SetFillColor('lightblue@0.5');
+$graph->Add($line);
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/dateaxisex4.php b/web/classes/jpgraph/Examples/dateaxisex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..dab6cd6f3c85cd429082ca7c604b82af6be75093
--- /dev/null
+++ b/web/classes/jpgraph/Examples/dateaxisex4.php
@@ -0,0 +1,44 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_date.php');
+
+// Create a data set in range (50,70) and X-positions
+DEFINE('NDATAPOINTS',360);
+DEFINE('SAMPLERATE',240); 
+$start = time();
+$end = $start+NDATAPOINTS*SAMPLERATE;
+$data = array();
+$xdata = array();
+for( $i=0; $i < NDATAPOINTS; ++$i ) {
+    $data[$i] = rand(50,70);
+    $xdata[$i] = $start + $i * SAMPLERATE;
+}
+
+
+// Create the new graph
+$graph = new Graph(540,300);
+
+// Slightly larger than normal margins at the bottom to have room for
+// the x-axis labels
+$graph->SetMargin(40,40,30,130);
+
+// Fix the Y-scale to go between [0,100] and use date for the x-axis
+$graph->SetScale('datlin',0,100);
+$graph->title->Set("Example on Date scale");
+
+// Set the angle for the labels to 90 degrees
+$graph->xaxis->SetLabelAngle(90);
+
+// The automatic format string for dates can be overridden
+$graph->xaxis->scale->SetDateFormat('H:i');
+
+// Adjust the start/end to a specific alignment
+$graph->xaxis->scale->SetTimeAlign(MINADJ_10);
+
+$line = new LinePlot($data,$xdata);
+$line->SetLegend('Year 2005');
+$line->SetFillColor('lightblue@0.5');
+$graph->Add($line);
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/datescaleticksex01.php b/web/classes/jpgraph/Examples/datescaleticksex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..5bdcbe54c06db89819c1168be3f7e6acf428bc7a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/datescaleticksex01.php
@@ -0,0 +1,63 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('../jpgraph.php');
+require_once ('../jpgraph_line.php');
+require_once ('../jpgraph_date.php');
+
+DEFINE('INTERVAL', 5*60);
+
+// First create some "dummy" data
+$m = 5; // Number of data sets
+$n = 4; // Number of bids to show
+$startbid = 8000;
+
+for( $i=0; $i < $m; ++$i ) {
+    $bids[$i] = array($startbid + rand(100,500)*10 );
+    for( $j=1; $j < $n; ++$j ) {
+        $bids[$i][$j] = $bids[$i][$j-1] + rand(20,500)*10;
+    }
+}
+
+$start = floor(time()/INTERVAL)*INTERVAL;
+$times = array($start);
+for( $i=1; $i < $n; ++$i ) {
+    // Create a timestamp for every 5 minutes
+    $times[$i] = $times[$i-1]+INTERVAL;
+}
+
+// Setup the bid graph
+$graph = new Graph(600,250);
+$graph->SetMargin(80,30,50,40);
+$graph->SetMarginColor('white');
+$graph->SetScale('dateint');
+$graph->title->Set('Current Bids');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set('(Updated every 5 minutes)');
+$graph->subtitle->SetFont(FF_ARIAL,FS_ITALIC,10);
+
+// Enable antialias
+$graph->img->SetAntiAliasing();
+
+// Setup the y-axis to show currency values
+$graph->yaxis->SetLabelFormatCallback('number_format');
+$graph->yaxis->SetLabelFormat('$%s');
+
+//Use hour:minute format for the labels
+$graph->xaxis->scale->SetDateFormat('H:i');
+
+// Force labels to only be displayed every 5 minutes
+$graph->xaxis->scale->ticks->Set(INTERVAL);
+
+// Adjust the start time for an "even" 5 minute, i.e. 5,10,15,20,25, ...
+$graph->xaxis->scale->SetTimeAlign(MINADJ_5);
+
+// Create the plots using the dummy data created at the beginning
+$line = array();
+for( $i=0; $i < $m; ++$i ) {
+    $line[$i] = new LinePlot($bids[$i],$times);
+    $line[$i]->mark->SetType(MARK_SQUARE);
+}
+$graph->Add($line);
+
+// Send the graph back to the client
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/dateutilex01.php b/web/classes/jpgraph/Examples/dateutilex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..75f0d331b7998a96c2d6b1f81c953e0d4657c2ce
--- /dev/null
+++ b/web/classes/jpgraph/Examples/dateutilex01.php
@@ -0,0 +1,53 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_utils.inc.php');
+
+// Get a dataset stored in $xdata and $ydata
+require_once ('dataset01.inc.php');
+
+$dateUtils = new DateScaleUtils();
+
+// Setup a basic graph
+$width=500; $height=300;
+$graph = new Graph($width, $height);
+
+// We set the x-scale min/max values to avoid empty space
+// on the side of the plot
+$graph->SetScale('intlin',0,0,min($xdata),max($xdata));
+$graph->SetMargin(60,20,40,60);
+
+// Setup the titles
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->title->Set('Development since 1984');
+$graph->subtitle->SetFont(FF_ARIAL,FS_ITALIC,10);
+$graph->subtitle->Set('(Example using DateScaleUtils class)');
+
+// Setup the labels to be correctly format on the X-axis
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,8);
+$graph->xaxis->SetLabelAngle(30);
+
+// The second paramter set to 'true' will make the library interpret the
+// format string as a date format. We use a Month + Year format
+$graph->xaxis->SetLabelFormatString('M, Y',true);
+
+// Get manual tick every second year
+list($tickPos,$minTickPos) = $dateUtils->getTicks($xdata,DSUTILS_YEAR2);
+$graph->xaxis->SetTickPositions($tickPos,$minTickPos);
+
+// First add an area plot
+$lp1 = new LinePlot($ydata,$xdata);
+$lp1->SetWeight(0);
+$lp1->SetFillColor('orange@0.85');
+$graph->Add($lp1);
+
+// And then add line. We use two plots in order to get a
+// more distinct border on the graph
+$lp2 = new LinePlot($ydata,$xdata);
+$lp2->SetColor('orange');
+$graph->Add($lp2);
+
+// And send back to the client
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/dateutilex02.php b/web/classes/jpgraph/Examples/dateutilex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..f95db471e56b662a21ddfcd87fc2266ec8a34f5c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/dateutilex02.php
@@ -0,0 +1,47 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_date.php');
+require_once ('jpgraph/jpgraph_utils.inc.php');
+
+// Get a dataset stored in $xdata and $ydata
+require_once ('dataset01.inc.php');
+
+$dateUtils = new DateScaleUtils();
+
+// Setup a basic graph
+$width=500; $height=300;
+$graph = new Graph($width, $height);
+$graph->SetScale('datlin');
+$graph->SetMargin(60,20,40,60);
+
+// Setup the titles
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->title->Set('Development since 1984');
+$graph->subtitle->SetFont(FF_ARIAL,FS_ITALIC,10);
+$graph->subtitle->Set('(Example using the builtin date scale)');
+
+// Setup the labels to be correctly format on the X-axis
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,8);
+$graph->xaxis->SetLabelAngle(30);
+
+// The second paramter set to 'true' will make the library interpret the
+// format string as a date format. We use a Month + Year format
+// $graph->xaxis->SetLabelFormatString('M, Y',true);
+
+// First add an area plot
+$lp1 = new LinePlot($ydata,$xdata);
+$lp1->SetWeight(0);
+$lp1->SetFillColor('orange@0.85');
+$graph->Add($lp1);
+
+// And then add line. We use two plots in order to get a
+// more distinct border on the graph
+$lp2 = new LinePlot($ydata,$xdata);
+$lp2->SetColor('orange');
+$graph->Add($lp2);
+
+// And send back to the client
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/dm_ex6.png b/web/classes/jpgraph/Examples/dm_ex6.png
new file mode 100755
index 0000000000000000000000000000000000000000..b389990b02d26b4db7632114c8ccea5de779c3d6
Binary files /dev/null and b/web/classes/jpgraph/Examples/dm_ex6.png differ
diff --git a/web/classes/jpgraph/Examples/dupyaxisex1.php b/web/classes/jpgraph/Examples/dupyaxisex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..b4b63fe700bfa439ec79b3ee6ecfe8bf7e0a8048
--- /dev/null
+++ b/web/classes/jpgraph/Examples/dupyaxisex1.php
@@ -0,0 +1,31 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_utils.inc.php');
+
+$f = new FuncGenerator('cos($i)','$i*$i*$i');
+list($xdata,$ydata) = $f->E(-M_PI,M_PI,25);
+
+$graph = new Graph(300,200);
+$graph->SetScale("linlin");
+$graph->SetMargin(50,50,20,30);	
+$graph->SetFrame(false);
+$graph->SetBox(true,'black',2);	
+$graph->SetMarginColor('white');
+$graph->SetColor('lightyellow');
+
+$graph->title->Set('Duplicating Y-axis');
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$graph->SetAxisStyle(AXSTYLE_YBOXIN);
+$graph->xgrid->Show();
+
+$lp1 = new LinePlot($ydata,$xdata);
+$lp1->SetColor("blue");
+$lp1->SetWeight(2);
+$graph->Add($lp1);
+
+$graph->Stroke();
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/example0-0.php b/web/classes/jpgraph/Examples/example0-0.php
new file mode 100755
index 0000000000000000000000000000000000000000..d281824a7f105d7ee1153faee17d691d29076b6d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example0-0.php
@@ -0,0 +1,25 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some (random) data
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Size of the overall graph
+$width=350;
+$height=250;
+
+// Create the graph and set a scale.
+// These two calls are always required
+$graph = new Graph($width,$height);
+$graph->SetScale('intlin');
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example0.php b/web/classes/jpgraph/Examples/example0.php
new file mode 100755
index 0000000000000000000000000000000000000000..2667e9f8d34577a4401f2edd4eff2c9e35a5abb0
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example0.php
@@ -0,0 +1,21 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some data
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(350,250);
+$graph->SetScale('textlin');
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor('blue');
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example1.1.php b/web/classes/jpgraph/Examples/example1.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..e171e3bac22837128a4a6c3d005eb0002cc36ce4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example1.1.php
@@ -0,0 +1,25 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+ 
+$ydata = array(11,11,11);
+
+// Create the graph. 
+$graph = new Graph(350,250);	
+$graph->SetScale("textlin");
+$graph->img->SetMargin(30,90,40,50);
+$graph->xaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->title->Set("Example 1.1 same y-values");
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetLegend("Test 1");
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(5);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example1.2.php b/web/classes/jpgraph/Examples/example1.2.php
new file mode 100755
index 0000000000000000000000000000000000000000..bbac21f1f4c5b6fc3255e9bc6ac34df835b7c530
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example1.2.php
@@ -0,0 +1,29 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(350,250);	
+$graph->SetScale("textlin");
+$graph->img->SetMargin(30,90,40,50);
+$graph->xaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->title->Set("Dashed lineplot");
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetLegend("Test 1");
+$lineplot->SetColor("blue");
+
+// Style can also be specified as SetStyle([1|2|3|4]) or
+// SetStyle("solid"|"dotted"|"dashed"|"lobgdashed")
+$lineplot->SetStyle("dashed");
+
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example1.php b/web/classes/jpgraph/Examples/example1.php
new file mode 100755
index 0000000000000000000000000000000000000000..31437f2dc812258e4dfa2e7bc9c367b9c28c40c8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example1.php
@@ -0,0 +1,25 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+$graph->img->SetMargin(50,90,40,50);
+$graph->xaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->title->Set("Examples for graph");
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetLegend("Test 1");
+$lineplot->SetColor("blue");
+
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example10.php b/web/classes/jpgraph/Examples/example10.php
new file mode 100755
index 0000000000000000000000000000000000000000..8b9d4c6e82f120adc8521a461b73105edd521d56
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example10.php
@@ -0,0 +1,59 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_log.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+$y2data = array(354,200,265,99,111,91,198,225,293,251);
+$datax=array("Jan","Feb","Mar","Apr","Maj","Jun","Jul","Aug","Sep");
+
+// Create the graph. These two calls are always required
+$graph = new Graph(350,200);	
+$graph->img->SetMargin(40,110,20,40);
+$graph->SetScale("textlog");
+$graph->SetY2Scale("log");
+$graph->SetShadow();
+
+$graph->ygrid->Show(true,true);
+$graph->xgrid->Show(true,false);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot2=new LinePlot($y2data);
+
+$graph->yaxis->scale->ticks->SupressFirst();
+$graph->y2axis->scale->ticks->SupressFirst();
+// Add the plot to the graph
+$graph->Add($lineplot);
+$graph->AddY2($lineplot2);
+$lineplot2->SetColor("orange");
+$lineplot2->SetWeight(2);
+$graph->y2axis->SetColor("orange");
+
+$graph->title->Set("Example 10");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+
+$lineplot2->SetColor("orange");
+$lineplot2->SetWeight(2);
+
+$graph->yaxis->SetColor("blue");
+
+$lineplot->SetLegend("Plot 1");
+$lineplot2->SetLegend("Plot 2");
+
+$graph->legend->Pos(0.05,0.5,"right","center");
+
+$graph->xaxis->SetTickLabels($datax);
+$graph->xaxis->SetTextTickInterval(2);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example11.php b/web/classes/jpgraph/Examples/example11.php
new file mode 100755
index 0000000000000000000000000000000000000000..898447a24ef623deee021abe2c026fd32344786b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example11.php
@@ -0,0 +1,50 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+$ydata2 = array(1,19,15,7,22,14,5,9,21,13);
+
+$timer = new JpgTimer();
+$timer->Push();
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);
+$graph->SetScale("textlin");
+
+$graph->SetMargin(40,20,20,60);
+
+$graph->title->Set("Timing a graph");
+$graph->footer->right->Set('Timer (ms): ');
+$graph->footer->right->SetFont(FF_COURIER,FS_ITALIC);
+$graph->footer->SetTimer($timer);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+
+$lineplot2=new LinePlot($ydata2);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+$graph->Add($lineplot2);
+
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+
+$lineplot2->SetColor("orange");
+$lineplot2->SetWeight(2);
+
+$graph->yaxis->SetColor("red");
+$graph->yaxis->SetWeight(2);
+$graph->SetShadow();
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example13.php b/web/classes/jpgraph/Examples/example13.php
new file mode 100755
index 0000000000000000000000000000000000000000..ae0eb952481062cbc01fb400222b7b6c9f5761da
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example13.php
@@ -0,0 +1,36 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_error.php');
+
+$errdatay = array(11,9,2,4,19,26,13,19,7,12);
+
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+
+$graph->img->SetMargin(40,30,20,40);
+$graph->SetShadow();
+
+// Create the error plot
+$errplot=new ErrorPlot($errdatay);
+$errplot->SetColor("red");
+$errplot->SetWeight(2);
+
+// Add the plot to the graph
+$graph->Add($errplot);
+
+$graph->title->Set("Simple error plot");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$datax = $gDateLocale->GetShortMonth();
+$graph->xaxis->SetTickLabels($datax);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example14.php b/web/classes/jpgraph/Examples/example14.php
new file mode 100755
index 0000000000000000000000000000000000000000..cc591cbf44fafce2adfc4e7fcc193a020b2ddd51
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example14.php
@@ -0,0 +1,37 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_error.php');
+
+$errdatay = array(11,9,2,4,19,26,13,19,7,12);
+
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+
+$graph->img->SetMargin(40,30,20,40);
+$graph->SetShadow();
+
+// Create the error plot
+$errplot=new ErrorPlot($errdatay);
+$errplot->SetColor("red");
+$errplot->SetWeight(2);
+$errplot->SetCenter();
+
+// Add the plot to the graph
+$graph->Add($errplot);
+
+$graph->title->Set("Simple error plot");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$datax = $gDateLocale->GetShortMonth();
+$graph->xaxis->SetTickLabels($datax);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example15.php b/web/classes/jpgraph/Examples/example15.php
new file mode 100755
index 0000000000000000000000000000000000000000..79ebb9eabc8124065b2c8048ac858fa2608a97dc
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example15.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_error.php');
+
+$errdatay = array(11,9,2,4,19,26,13,19,7,12);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+
+$graph->img->SetMargin(40,30,20,40);
+$graph->SetShadow();
+
+// Create the linear plot
+$errplot=new ErrorLinePlot($errdatay);
+$errplot->SetColor("red");
+$errplot->SetWeight(2);
+$errplot->SetCenter();
+$errplot->line->SetWeight(2);
+$errplot->line->SetColor("blue");
+
+// Add the plot to the graph
+$graph->Add($errplot);
+
+$graph->title->Set("Linear error plot");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$datax = $gDateLocale->GetShortMonth();
+$graph->xaxis->SetTickLabels($datax);
+
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example16.1.php b/web/classes/jpgraph/Examples/example16.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..edbb010fa9dd3fcdb8905398d634268fa6ce5846
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example16.1.php
@@ -0,0 +1,44 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$l1datay = array(11,9,2,4,3,13,17);
+$l2datay = array(23,12,5,19,17,10,15);
+$datax=array('Jan','Feb','Mar','Apr','May');
+
+// Create the graph. 
+$graph = new Graph(400,200);	
+$graph->SetScale('textlin');
+
+$graph->img->SetMargin(40,130,20,40);
+$graph->SetShadow();
+
+// Create the linear error plot
+$l1plot=new LinePlot($l1datay);
+$l1plot->SetColor('red');
+$l1plot->SetWeight(2);
+$l1plot->SetLegend('Prediction');
+
+// Create the bar plot
+$l2plot = new LinePlot($l2datay);
+$l2plot->SetFillColor('orange');
+$l2plot->SetLegend('Result');
+
+// Add the plots to the graph
+$graph->Add($l2plot);
+$graph->Add($l1plot);
+
+$graph->title->Set('Mixing line and filled line');
+$graph->xaxis->title->Set('X-title');
+$graph->yaxis->title->Set('Y-title');
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+//$graph->xaxis->SetTickLabels($datax);
+//$graph->xaxis->SetTextTickInterval(2);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example16.2.php b/web/classes/jpgraph/Examples/example16.2.php
new file mode 100755
index 0000000000000000000000000000000000000000..649a7a94d00c761c717425ed23fd077367d0d0eb
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example16.2.php
@@ -0,0 +1,46 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$l1datay = array(11,9,2,4,3,13,17);
+$l2datay = array(23,12,5,19,17,10,15);
+$datax=array("Jan","Feb","Mar","Apr","May");
+
+// Create the graph. 
+$graph = new Graph(400,200);	
+$graph->SetScale("textlin");
+
+$graph->img->SetMargin(40,130,20,40);
+$graph->SetShadow();
+
+// Create the linear error plot
+$l1plot=new LinePlot($l1datay);
+$l1plot->SetColor("red");
+$l1plot->SetWeight(2);
+$l1plot->SetLegend("Prediction");
+
+// Create the bar plot
+$bplot = new BarPlot($l2datay);
+$bplot->SetFillColor("orange");
+$bplot->SetLegend("Result");
+
+// Add the plots to t'he graph
+$graph->Add($l1plot);
+$graph->Add($bplot);
+
+
+$graph->title->Set("Adding a line plot to a bar graph v1");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+//$graph->xaxis->SetTickLabels($datax);
+//$graph->xaxis->SetTextTickInterval(2);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example16.3.php b/web/classes/jpgraph/Examples/example16.3.php
new file mode 100755
index 0000000000000000000000000000000000000000..f184fa2ca282d249f84234570c38218cbcf76363
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example16.3.php
@@ -0,0 +1,45 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$l1datay = array(11,9,2,4,3,13,17);
+$l2datay = array(23,12,5,19,17,10,15);
+$datax=array('Jan','Feb','Mar','Apr','May','Jun','Jul','Aug');
+
+// Create the graph. 
+$graph = new Graph(400,200);	
+$graph->SetScale('textlin');
+
+$graph->img->SetMargin(40,130,20,40);
+$graph->SetShadow();
+
+// Create the linear error plot
+$l1plot=new LinePlot($l1datay);
+$l1plot->SetColor('red');
+$l1plot->SetWeight(2);
+$l1plot->SetLegend('Prediction');
+
+// Create the bar plot
+$bplot = new BarPlot($l2datay);
+$bplot->SetFillColor('orange');
+$bplot->SetLegend('Result');
+
+// Add the plots to t'he graph
+$graph->Add($bplot);
+$graph->Add($l1plot);
+
+$graph->title->Set('Adding a line plot to a bar graph v1');
+$graph->xaxis->title->Set('X-title');
+$graph->yaxis->title->Set('Y-title');
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$graph->xaxis->SetTickLabels($datax);
+//$graph->xaxis->SetTextTickInterval(2);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example16.4.php b/web/classes/jpgraph/Examples/example16.4.php
new file mode 100755
index 0000000000000000000000000000000000000000..a23c2a54f1fe0ac28c096957823b7b7a390ba575
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example16.4.php
@@ -0,0 +1,46 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$l1datay = array(11,9,2,4,3,13,17);
+$l2datay = array(23,12,5,19,17,10,15);
+JpgraphError::SetImageFlag(false);
+JpGraphError::SetLogFile('syslog');
+
+// Create the graph. 
+$graph = new Graph(400,200);	
+$graph->SetScale('intlin');
+
+$graph->img->SetMargin(40,130,20,40);
+$graph->SetShadow();
+
+// Create the linear error plot
+$l1plot=new LinePlot($l1datay);
+$l1plot->SetColor('red');
+$l1plot->SetWeight(2);
+$l1plot->SetLegend('Prediction');
+
+// Create the bar plot
+$bplot = new BarPlot($l2datay);
+$bplot->SetFillColor('orange');
+$bplot->SetLegend('Result');
+
+// Add the plots to t'he graph
+$graph->Add($bplot);
+$graph->Add($l1plot);
+
+$graph->title->Set('Adding a line plot to a bar graph v3');
+$graph->xaxis->title->Set('X-title');
+$graph->yaxis->title->Set('Y-title');
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$datax = $gDateLocale->GetShortMonth();
+$graph->xaxis->SetTickLabels($datax);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example16.5.php b/web/classes/jpgraph/Examples/example16.5.php
new file mode 100755
index 0000000000000000000000000000000000000000..bfad3ce8035ff0513ab9a809e89143458790a4b5
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example16.5.php
@@ -0,0 +1,57 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_error.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$l1datay = array(11,9,2,4,3,13,17);
+$l2datay = array(23,12,5,19,17,10,15);
+$datax=array("Jan","Feb","Mar","Apr","May","Jun","Jul");
+
+// Create the graph. 
+$graph = new Graph(350,200);	
+$graph->img->SetMargin(40,70,20,40);
+$graph->SetScale("textlin");
+$graph->SetShadow();
+$graph->SetColor(array(250,250,250));
+
+$graph->img->SetTransparent("white");
+
+$t1 = new Text("This is a text");
+$t1->SetPos(0.5,0.5);
+$t1->SetOrientation("h");
+$t1->SetFont(FF_FONT1,FS_BOLD);
+$t1->SetBox("white","black","gray");
+$t1->SetColor("black");
+$graph->AddText($t1);
+
+// Create the linear error plot
+$l1plot=new LinePlot($l1datay);
+$l1plot->SetColor("blue");
+$l1plot->SetWeight(2);
+$l1plot->SetLegend("Prediction");
+
+// Create the bar plot
+$l2plot = new BarPlot($l2datay);
+$l2plot->SetFillColor("orange");
+$l2plot->SetLegend("Result");
+
+// Add the plots to the graph
+$graph->Add($l1plot);
+$graph->Add($l2plot);
+
+
+$graph->title->Set("Example 16.3");
+$graph->xaxis->title->Set("Month");
+$graph->yaxis->title->Set("x10,000 US$");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$graph->xaxis->SetTickLabels($datax);
+//$graph->xaxis->SetTextTickInterval(2);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example16.6.php b/web/classes/jpgraph/Examples/example16.6.php
new file mode 100755
index 0000000000000000000000000000000000000000..8dac3128cd4d6b078ec53a2aca18991d3638274c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example16.6.php
@@ -0,0 +1,59 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_utils.inc.php');
+
+// Create some "fake" regression data
+$datay = array();
+$datax = array();
+$a= 3.2;
+$b= 2.5;
+for($x=0; $x < 20; ++$x) {
+    $datax[$x] = $x;
+    $datay[$x] = $a + $b*$x + rand(-20,20);
+}
+
+$lr = new LinearRegression($datax, $datay);
+list( $stderr, $corr ) = $lr->GetStat();
+list( $xd, $yd ) = $lr->GetY(0,19);
+
+// Create the graph
+$graph = new Graph(300,250);
+$graph->SetScale('linlin');
+
+// Setup title
+$graph->title->Set("Linear regression");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+$graph->subtitle->Set('(stderr='.sprintf('%.2f',$stderr).', corr='.sprintf('%.2f',$corr).')');
+$graph->subtitle->SetFont(FF_ARIAL,FS_NORMAL,12);
+
+// make sure that the X-axis is always at the
+// bottom at the plot and not just at Y=0 which is
+// the default position
+$graph->xaxis->SetPos('min');
+
+// Create the scatter plot with some nice colors
+$sp1 = new ScatterPlot($datay,$datax);
+$sp1->mark->SetType(MARK_FILLEDCIRCLE);
+$sp1->mark->SetFillColor("red");
+$sp1->SetColor("blue");
+$sp1->SetWeight(3);
+$sp1->mark->SetWidth(4);
+
+// Create the regression line
+$lplot = new LinePlot($yd);
+$lplot->SetWeight(2);
+$lplot->SetColor('navy');
+
+// Add the pltos to the line
+$graph->Add($sp1);
+$graph->Add($lplot);
+
+// ... and stroke
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/example16.php b/web/classes/jpgraph/Examples/example16.php
new file mode 100755
index 0000000000000000000000000000000000000000..04c24272e62814289318fa3c8fa9b3aa06450482
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example16.php
@@ -0,0 +1,44 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_error.php');
+
+$errdatay = array(11,9,2,4,19,26,13,19,7,12);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+
+$graph->img->SetMargin(40,30,20,40);
+$graph->SetShadow();
+
+// Create the linear plot
+$errplot=new ErrorLinePlot($errdatay);
+$errplot->SetColor("red");
+$errplot->SetWeight(2);
+$errplot->SetCenter();
+$errplot->line->SetWeight(2);
+$errplot->line->SetColor("blue");
+
+// Setup the legends
+$errplot->SetLegend("Min/Max");
+$errplot->line->SetLegend("Average");
+
+// Add the plot to the graph
+$graph->Add($errplot);
+
+$graph->title->Set("Linear error plot");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$datax = $gDateLocale->GetShortMonth();
+$graph->xaxis->SetTickLabels($datax);
+
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example17.php b/web/classes/jpgraph/Examples/example17.php
new file mode 100755
index 0000000000000000000000000000000000000000..a394ddf71c541709bd9491341b7d1d1876790244
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example17.php
@@ -0,0 +1,41 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay1 = 	array(11,7,5,8,3,5,5,4,8,6,5,5,3,2,5,1,2,0);
+$datay2 = 	array( 4,5,4,5,6,5,7,4,7,4,4,3,2,4,1,2,2,1);
+$datay3 = 	array(4,5,7,10,13,15,15,22,26,26,30,34,40,43,47,55,60,62);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);
+$graph->SetScale("textlin");
+$graph->SetShadow();
+$graph->img->SetMargin(40,30,20,40);
+
+// Create the linear plots for each category
+$dplot[] = new LinePLot($datay1);
+$dplot[] = new LinePLot($datay2);
+$dplot[] = new LinePLot($datay3);
+
+$dplot[0]->SetFillColor("red");
+$dplot[1]->SetFillColor("blue");
+$dplot[2]->SetFillColor("green");
+
+// Create the accumulated graph
+$accplot = new AccLinePlot($dplot);
+
+// Add the plot to the graph
+$graph->Add($accplot);
+
+$graph->xaxis->SetTextTickInterval(2);
+$graph->title->Set("Example 17");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example18.php b/web/classes/jpgraph/Examples/example18.php
new file mode 100755
index 0000000000000000000000000000000000000000..458219c8c5cc5c4c7143122784f2310fd02c7947
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example18.php
@@ -0,0 +1,32 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,8,19,3,10,5);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+
+// Add a drop shadow
+$graph->SetShadow();
+
+// Adjust the margin a bit to make more room for titles
+$graph->img->SetMargin(40,30,20,40);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$graph->Add($bplot);
+
+// Setup the titles
+$graph->title->Set("A simple bar graph");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example19.1.php b/web/classes/jpgraph/Examples/example19.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..feddf707814aed33258c97047ed1a2ead3a0ef81
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example19.1.php
@@ -0,0 +1,35 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,8,19,3,10,5);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);
+$graph->SetScale('intlin');
+
+// Add a drop shadow
+$graph->SetShadow();
+
+// Adjust the margin a bit to make more room for titles
+$graph->SetMargin(40,30,20,40);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+
+// Adjust fill color
+$bplot->SetFillColor('orange');
+$graph->Add($bplot);
+
+// Setup the titles
+$graph->title->Set('A basic bar graph');
+$graph->xaxis->title->Set('X-title');
+$graph->yaxis->title->Set('Y-title');
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example19.php b/web/classes/jpgraph/Examples/example19.php
new file mode 100755
index 0000000000000000000000000000000000000000..13af5c01740b2d45a3a10731bf2496d6f1eb22df
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example19.php
@@ -0,0 +1,35 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,8,19,3,10,5);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);
+$graph->SetScale('textlin');
+
+// Add a drop shadow
+$graph->SetShadow();
+
+// Adjust the margin a bit to make more room for titles
+$graph->SetMargin(40,30,20,40);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+
+// Adjust fill color
+$bplot->SetFillColor('orange');
+$graph->Add($bplot);
+
+// Setup the titles
+$graph->title->Set('A basic bar graph');
+$graph->xaxis->title->Set('X-title');
+$graph->yaxis->title->Set('Y-title');
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example2.1.php b/web/classes/jpgraph/Examples/example2.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..1114b1a09dd741abf1f969814e1375db090fed8c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example2.1.php
@@ -0,0 +1,30 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,-3,-8,7,5,-1,9,13,5,-7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+
+$lineplot->value->Show();
+$lineplot->value->SetColor("red");
+$lineplot->value->SetFont(FF_FONT1,FS_BOLD);
+
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+$graph->img->SetMargin(40,20,20,40);
+$graph->title->Set("Example 2.1");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example2.5.php b/web/classes/jpgraph/Examples/example2.5.php
new file mode 100755
index 0000000000000000000000000000000000000000..a6e5535c70e9a8f94dbb258e91380b8e4d9bce34
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example2.5.php
@@ -0,0 +1,26 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,-3,-8,7,5,-1,9,13,5,-7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+$graph->img->SetMargin(40,20,20,40);
+$graph->title->Set("Example 2.5");
+$graph->xaxis->title->Set("X-title");
+$graph->xaxis->SetPos("min");
+$graph->yaxis->title->Set("Y-title");
+
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example2.6.php b/web/classes/jpgraph/Examples/example2.6.php
new file mode 100755
index 0000000000000000000000000000000000000000..215eb4a5f19483d0f050a1c7d66f5670e49d4bd0
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example2.6.php
@@ -0,0 +1,27 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,-3,-8,7,5,-1,9,13,5,-7,-7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetStepStyle();
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+$graph->img->SetMargin(40,20,20,40);
+$graph->title->Set("Example 2.6 (Line with stepstyle)");
+$graph->xaxis->title->Set("X-title");
+$graph->xaxis->SetPos("min");
+$graph->yaxis->title->Set("Y-title");
+
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example2.php b/web/classes/jpgraph/Examples/example2.php
new file mode 100755
index 0000000000000000000000000000000000000000..ef3731e7ddd5fab914c0d44faa59e1986de7ba64
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example2.php
@@ -0,0 +1,33 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some (random) data
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Size of the overall graph
+$width=350;
+$height=250;
+
+// Create the graph and set a scale.
+// These two calls are always required
+$graph = new Graph($width,$height);
+$graph->SetScale('intlin');
+
+// Setup margin and titles
+$graph->SetMargin(40,20,20,40);
+$graph->title->Set('Calls per operator');
+$graph->subtitle->Set('(March 12, 2008)');
+$graph->xaxis->title->Set('Operator');
+$graph->yaxis->title->Set('# of calls');
+
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example20.1.php b/web/classes/jpgraph/Examples/example20.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..0b2514496c33ec51abad2b858ccd4a90767f8864
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example20.1.php
@@ -0,0 +1,36 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,8,19,3,10,5);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+
+// Add a drop shadow
+$graph->SetShadow();
+
+// Adjust the margin a bit to make more room for titles
+$graph->img->SetMargin(40,30,20,40);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+
+// Adjust fill color
+$bplot->SetFillColor('orange');
+$bplot->value->Show();
+$graph->Add($bplot);
+
+// Setup the titles
+$graph->title->Set("Bar graph");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example20.2.php b/web/classes/jpgraph/Examples/example20.2.php
new file mode 100755
index 0000000000000000000000000000000000000000..b623219f26fbafbd53acaf70d3e1fc8e9fe7767d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example20.2.php
@@ -0,0 +1,37 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,8,19,3,10,5);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+$graph->yaxis->scale->SetGrace(20);
+
+// Add a drop shadow
+$graph->SetShadow();
+
+// Adjust the margin a bit to make more room for titles
+$graph->img->SetMargin(40,30,20,40);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+
+// Adjust fill color
+$bplot->SetFillColor('orange');
+$bplot->value->Show();
+$graph->Add($bplot);
+
+// Setup the titles
+$graph->title->Set("Bar graph with Y-scale grace");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example20.3.php b/web/classes/jpgraph/Examples/example20.3.php
new file mode 100755
index 0000000000000000000000000000000000000000..ac2df48387732a37d0c002cd0752511a897dbdd9
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example20.3.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,8,19,3,10,5);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+$graph->yaxis->scale->SetGrace(20);
+
+// Add a drop shadow
+$graph->SetShadow();
+
+// Adjust the margin a bit to make more room for titles
+$graph->img->SetMargin(40,30,20,40);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+
+// Adjust fill color
+$bplot->SetFillColor('orange');
+$bplot->value->Show();
+$bplot->value->SetFont(FF_ARIAL,FS_BOLD,10);
+$bplot->value->SetAngle(45);
+$bplot->value->SetFormat('%0.1f');
+$graph->Add($bplot);
+
+// Setup the titles
+$graph->title->Set("Bar graph with Y-scale grace");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example20.4.php b/web/classes/jpgraph/Examples/example20.4.php
new file mode 100755
index 0000000000000000000000000000000000000000..6786efbfd65c195f7cb00b36e54a13aa0b2af90b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example20.4.php
@@ -0,0 +1,41 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,8,19,3,10,5);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+$graph->yaxis->scale->SetGrace(20);
+
+// Add a drop shadow
+$graph->SetShadow();
+
+// Adjust the margin a bit to make more room for titles
+$graph->img->SetMargin(40,30,20,40);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+
+// Adjust fill color
+$bplot->SetFillColor('orange');
+$bplot->SetShadow();
+$bplot->value->Show();
+$bplot->value->SetFont(FF_ARIAL,FS_BOLD,10);
+$bplot->value->SetAngle(45);
+$bplot->value->SetFormat('%0.1f');
+$graph->Add($bplot);
+
+// Setup the titles
+$graph->title->Set("Bar graph with drop shadow");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example20.5.php b/web/classes/jpgraph/Examples/example20.5.php
new file mode 100755
index 0000000000000000000000000000000000000000..a191e5a31857cd86e75976377c05c742808f000e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example20.5.php
@@ -0,0 +1,47 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,8,19,3,10,5);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+
+// Add a drop shadow
+$graph->SetShadow();
+
+// Adjust the margin a bit to make more room for titles
+$graph->img->SetMargin(40,30,20,40);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+
+// Adjust fill color
+$bplot->SetFillColor('orange');
+
+// Setup values
+$bplot->value->Show();
+$bplot->value->SetFormat('%d');
+$bplot->value->SetFont(FF_FONT1,FS_BOLD);
+
+// Center the values in the bar
+$bplot->SetValuePos('center');
+
+// Make the bar a little bit wider
+$bplot->SetWidth(0.7);
+
+$graph->Add($bplot);
+
+// Setup the titles
+$graph->title->Set("Centered values for bars");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example20.php b/web/classes/jpgraph/Examples/example20.php
new file mode 100755
index 0000000000000000000000000000000000000000..434860f1aa2cf56acbd18f29741a4d421e7ea3e5
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example20.php
@@ -0,0 +1,36 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,8,19,3,10,5);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+
+// Add a drop shadow
+$graph->SetShadow();
+
+// Adjust the margin a bit to make more room for titles
+$graph->img->SetMargin(40,30,20,40);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+
+// Adjust fill color
+$bplot->SetFillColor('orange');
+$bplot->SetWidth(1.0);
+$graph->Add($bplot);
+
+// Setup the titles
+$graph->title->Set("Bar graph");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example21.php b/web/classes/jpgraph/Examples/example21.php
new file mode 100755
index 0000000000000000000000000000000000000000..81debb2d35ede3e0db63529fd6b2b74b1cf9f789
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example21.php
@@ -0,0 +1,37 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$data1y=array(12,8,19,3,10,5);
+$data2y=array(8,2,11,7,14,4);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(310,200);	
+$graph->SetScale("textlin");
+
+$graph->SetShadow();
+$graph->img->SetMargin(40,30,20,40);
+
+// Create the bar plots
+$b1plot = new BarPlot($data1y);
+$b1plot->SetFillColor("orange");
+$b2plot = new BarPlot($data2y);
+$b2plot->SetFillColor("blue");
+
+// Create the grouped bar plot
+$gbplot = new GroupBarPlot(array($b1plot,$b2plot));
+
+// ...and add it to the graPH
+$graph->Add($gbplot);
+
+$graph->title->Set("Example 21");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example22.php b/web/classes/jpgraph/Examples/example22.php
new file mode 100755
index 0000000000000000000000000000000000000000..f5223d08a5035fa512f6b4edd2ee67f72a276f93
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example22.php
@@ -0,0 +1,38 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$data1y=array(12,8,19,3,10,5);
+$data2y=array(8,2,11,7,14,4);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(310,200);	
+$graph->SetScale("textlin");
+$graph->SetShadow();
+
+$graph->img->SetMargin(40,30,20,40);
+
+// Create the bar plots
+$b1plot = new BarPlot($data1y);
+$b1plot->SetFillColor("orange");
+$b2plot = new BarPlot($data2y);
+$b2plot->SetFillColor("blue");
+
+// Create the grouped bar plot
+$gbplot = new GroupBarPlot(array($b1plot,$b2plot));
+$gbplot->SetWidth(0.9);
+
+// ...and add it to the graPH
+$graph->Add($gbplot);
+
+$graph->title->Set("Adjusting the width");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example23.php b/web/classes/jpgraph/Examples/example23.php
new file mode 100755
index 0000000000000000000000000000000000000000..fcec9de0bd2f71df9a8648cc922ff4b5cc63afc7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example23.php
@@ -0,0 +1,39 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+setlocale (LC_ALL, 'et_EE.ISO-8859-1');
+
+$data1y=array(12,8,19,3,10,5);
+$data2y=array(8,2,11,7,14,4);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(310,200);	
+$graph->SetScale("textlin");
+
+$graph->SetShadow();
+$graph->img->SetMargin(40,30,20,40);
+
+// Create the bar plots
+$b1plot = new BarPlot($data1y);
+$b1plot->SetFillColor("orange");
+$b2plot = new BarPlot($data2y);
+$b2plot->SetFillColor("blue");
+
+// Create the grouped bar plot
+$gbplot = new AccBarPlot(array($b1plot,$b2plot));
+
+// ...and add it to the graPH
+$graph->Add($gbplot);
+
+$graph->title->Set("Accumulated bar plots");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example24.php b/web/classes/jpgraph/Examples/example24.php
new file mode 100755
index 0000000000000000000000000000000000000000..48d48da522b324acf7526276e41bd92dc053be9c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example24.php
@@ -0,0 +1,46 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$data1y=array(12,8,19,3,10,5);
+$data2y=array(8,2,11,7,14,4);
+$data3y=array(3,9,2,7,5,8);
+$data4y=array(1,5,11,2,14,4);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(310,200);	
+$graph->SetScale("textlin");
+
+$graph->SetShadow();
+$graph->img->SetMargin(40,30,20,40);
+
+$b1plot = new BarPlot($data1y);
+$b1plot->SetFillColor("orange");
+$b2plot = new BarPlot($data2y);
+$b2plot->SetFillColor("blue");
+$b3plot = new BarPlot($data3y);
+$b3plot->SetFillColor("green");
+$b4plot = new BarPlot($data4y);
+$b4plot->SetFillColor("brown");
+
+// Create the accumulated bar plots
+$ab1plot = new AccBarPlot(array($b1plot,$b2plot));
+$ab2plot = new AccBarPlot(array($b3plot,$b4plot));
+
+// Create the grouped bar plot
+$gbplot = new GroupBarPlot(array($ab1plot,$ab2plot));
+
+// ...and add it to the graph
+$graph->Add($gbplot);
+
+$graph->title->Set("Grouped Accumulated bar plots");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example25.1.php b/web/classes/jpgraph/Examples/example25.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..a3afb03ad1cc5bc317cdacfbef96249b053520cf
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example25.1.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,8,19,3,10,5);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);
+$graph->SetScale('textlin');
+
+// Add a drop shadow
+$graph->SetShadow();
+
+// Adjust the margin a bit to make more room for titles
+$graph->img->SetMargin(40,30,40,40);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$graph->Add($bplot);
+
+// Create and add a new text
+$txt=new Text('This is a text');
+$txt->SetPos(10,20);
+$txt->SetColor('darkred');
+$txt->SetFont(FF_FONT2,FS_BOLD);
+$txt->SetBox('yellow','navy','gray@0.5');
+$graph->AddText($txt);
+
+// Setup the titles
+$graph->title->Set("A simple bar graph");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example25.2.php b/web/classes/jpgraph/Examples/example25.2.php
new file mode 100755
index 0000000000000000000000000000000000000000..53f8479e26d142e0ee66c26530de466db73fad74
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example25.2.php
@@ -0,0 +1,41 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,8,19,3,10,5);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);
+$graph->SetScale('textlin');
+
+// Add a drop shadow
+$graph->SetShadow();
+
+// Adjust the margin a bit to make more room for titles
+$graph->img->SetMargin(40,30,20,40);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$graph->Add($bplot);
+
+// Create and add a new text
+$txt=new Text("This is a text\nwith many\nand even\nmore\nlines of text");
+$txt->SetPos(0.5,0.5,'center','center');
+$txt->SetFont(FF_FONT2,FS_BOLD);
+$txt->ParagraphAlign('center');
+$txt->SetBox('yellow','navy','gray');
+$txt->SetColor('red');
+$graph->AddText($txt);
+
+// Setup the titles
+$graph->title->Set("A simple bar graph");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example25.php b/web/classes/jpgraph/Examples/example25.php
new file mode 100755
index 0000000000000000000000000000000000000000..35802aedea4c4812c3e632f8a3f4ac23600fd94d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example25.php
@@ -0,0 +1,39 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,8,19,3,10,5);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);
+$graph->SetScale('textlin');
+
+// Add a drop shadow
+$graph->SetShadow();
+
+// Adjust the margin a bit to make more room for titles
+$graph->img->SetMargin(40,30,40,40);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$graph->Add($bplot);
+
+// Create and add a new text
+$txt=new Text('This is a text');
+$txt->SetPos(0,20);
+$txt->SetColor('darkred');
+$txt->SetFont(FF_FONT2,FS_BOLD);
+$graph->AddText($txt);
+
+// Setup the titles
+$graph->title->Set("A simple bar graph");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example26.1.php b/web/classes/jpgraph/Examples/example26.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..63a9d267e3326a0831adf5fcff225749f8a4cd46
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example26.1.php
@@ -0,0 +1,22 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+$data = array(40,60,21,33);
+
+$graph = new PieGraph(300,200);
+$graph->SetShadow();
+
+$graph->title->Set("A simple Pie plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$p1 = new PiePlot($data);
+$p1->SetLegends($gDateLocale->GetShortMonth());
+$p1->SetCenter(0.4);
+
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/example26.php b/web/classes/jpgraph/Examples/example26.php
new file mode 100755
index 0000000000000000000000000000000000000000..9cb57ebe74addc543ae913e06c26315e02e865dd
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example26.php
@@ -0,0 +1,18 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+$data = array(40,60,21,33);
+
+$graph = new PieGraph(300,200);
+$graph->SetShadow();
+
+$graph->title->Set("A simple Pie plot");
+
+$p1 = new PiePlot($data);
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/example27.1.php b/web/classes/jpgraph/Examples/example27.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..51d52e3aaeb13da9255a2edc45e5de88053fd1e8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example27.1.php
@@ -0,0 +1,25 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+require_once ('jpgraph/jpgraph_pie3d.php');
+
+$data = array(40,60,21,33);
+
+$graph = new PieGraph(300,200);
+$graph->SetShadow();
+
+$graph->title->Set("A simple Pie plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$p1 = new PiePlot3D($data);
+$p1->SetAngle(20);
+$p1->SetSize(0.5);
+$p1->SetCenter(0.45);
+$p1->SetLegends($gDateLocale->GetShortMonth());
+
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/example27.2.php b/web/classes/jpgraph/Examples/example27.2.php
new file mode 100755
index 0000000000000000000000000000000000000000..aad23a38e7f717c98a3c180d69471916f18aea19
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example27.2.php
@@ -0,0 +1,24 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+require_once ('jpgraph/jpgraph_pie3d.php');
+
+$data = array(40,60,21,33);
+
+$graph = new PieGraph(300,200);
+$graph->SetShadow();
+
+$graph->title->Set("A simple Pie plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$p1 = new PiePlot($data);
+$p1->ExplodeSlice(1);
+$p1->SetCenter(0.45);
+$p1->SetLegends($gDateLocale->GetShortMonth());
+
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/example27.3.php b/web/classes/jpgraph/Examples/example27.3.php
new file mode 100755
index 0000000000000000000000000000000000000000..fb2a56ec75d2ba6ceb24f1fa9e119e69fda07a96
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example27.3.php
@@ -0,0 +1,24 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+require_once ('jpgraph/jpgraph_pie3d.php');
+
+$data = array(40,60,21,33);
+
+$graph = new PieGraph(330,200);
+$graph->SetShadow();
+
+$graph->title->Set("A simple 3D Pie plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$p1 = new PiePlot3D($data);
+$p1->ExplodeSlice(1);
+$p1->SetCenter(0.45);
+$p1->SetLegends($gDateLocale->GetShortMonth());
+
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/example27.php b/web/classes/jpgraph/Examples/example27.php
new file mode 100755
index 0000000000000000000000000000000000000000..3feee435ce9096220b29e2ed9c87f6dddfd47b25
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example27.php
@@ -0,0 +1,24 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+require_once ('jpgraph/jpgraph_pie3d.php');
+
+$data = array(40,60,21,33);
+
+$graph = new PieGraph(300,200);
+$graph->SetShadow();
+
+$graph->title->Set("A simple Pie plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$p1 = new PiePlot3D($data);
+$p1->SetSize(0.5);
+$p1->SetCenter(0.45);
+$p1->SetLegends($gDateLocale->GetShortMonth());
+
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/example28.1.php b/web/classes/jpgraph/Examples/example28.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..7dce5d8ad3cb8c60e4aadad3db1c52d41fcab0f7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example28.1.php
@@ -0,0 +1,22 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+$data = array(40,60,21,33,12,33);
+
+$graph = new PieGraph(150,150);
+$graph->SetShadow();
+
+$graph->title->Set("'earth' Theme");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$p1 = new PiePlot($data);
+$p1->SetTheme("earth");
+$p1->SetCenter(0.5,0.55);
+$p1->value->Show(false);
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/example28.2.php b/web/classes/jpgraph/Examples/example28.2.php
new file mode 100755
index 0000000000000000000000000000000000000000..905be8dac33c92302d7875e42da485e0c0a1b65a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example28.2.php
@@ -0,0 +1,22 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+$data = array(40,60,21,33,12,33);
+
+$graph = new PieGraph(150,150);
+$graph->SetShadow();
+
+$graph->title->Set("'pastel' Theme");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$p1 = new PiePlot($data);
+$p1->SetTheme("pastel");
+$p1->SetCenter(0.5,0.55);
+$p1->value->Show(false);
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/example28.3.php b/web/classes/jpgraph/Examples/example28.3.php
new file mode 100755
index 0000000000000000000000000000000000000000..bc4fdbd1fcf4a66384776a16672b6f071538a0b7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example28.3.php
@@ -0,0 +1,22 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+$data = array(40,60,21,33,12,33);
+
+$graph = new PieGraph(150,150);
+$graph->SetShadow();
+
+$graph->title->Set("'water' Theme");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$p1 = new PiePlot($data);
+$p1->SetTheme("water");
+$p1->SetCenter(0.5,0.55);
+$p1->value->Show(false);
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/example28.php b/web/classes/jpgraph/Examples/example28.php
new file mode 100755
index 0000000000000000000000000000000000000000..08d28bdc4de10d455bc33c19ab145840f01965de
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example28.php
@@ -0,0 +1,22 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+$data = array(40,60,21,33,12,33);
+
+$graph = new PieGraph(150,150);
+$graph->SetShadow();
+
+$graph->title->Set("'sand' Theme");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$p1 = new PiePlot($data);
+$p1->SetTheme("sand");
+$p1->SetCenter(0.5,0.55);
+$p1->value->Show(false);
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/example3.0.1.php b/web/classes/jpgraph/Examples/example3.0.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..dd10c9e98c2e92df0e9da047ddf3f3a771819a8d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example3.0.1.php
@@ -0,0 +1,41 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some (random) data
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Size of the overall graph
+$width=350;
+$height=250;
+
+// Create the graph and set a scale.
+// These two calls are always required
+$graph = new Graph($width,$height);
+$graph->SetScale('intlin');
+$graph->SetShadow();
+
+// Setup margin and titles
+$graph->SetMargin(40,20,20,40);
+$graph->title->Set('Calls per operator');
+$graph->subtitle->Set('(March 12, 2008)');
+$graph->xaxis->title->Set('Operator');
+$graph->yaxis->title->Set('# of calls');
+
+$graph->yaxis->title->SetFont( FF_FONT1 , FS_BOLD );
+$graph->xaxis->title->SetFont( FF_FONT1 , FS_BOLD );
+
+$graph->yaxis->SetColor('blue');
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor( 'blue' );
+$lineplot->SetWeight( 2 );   // Two pixel wide
+
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example3.0.2.php b/web/classes/jpgraph/Examples/example3.0.2.php
new file mode 100755
index 0000000000000000000000000000000000000000..3c8b1e62138e0d86e6491b0d1ee68d9c383e546d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example3.0.2.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some (random) data
+$ydata = array(17,3,'-',10,7,'-',3,19,9,7);
+
+// Size of the overall graph
+$width=350;
+$height=250;
+
+// Create the graph and set a scale.
+// These two calls are always required
+$graph = new Graph($width,$height);
+$graph->SetScale('intlin');
+$graph->SetShadow();
+
+// Setup margin and titles
+$graph->SetMargin(40,20,20,40);
+$graph->title->Set('Interpolated values');
+$graph->xaxis->title->Set('x-title');
+$graph->yaxis->title->Set('y-title');
+
+$graph->yaxis->title->SetFont( FF_ARIAL , FS_BOLD, 9 );
+$graph->xaxis->title->SetFont( FF_ARIAL , FS_BOLD, 9 );
+
+$graph->yaxis->SetColor('blue');
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor( 'blue' );
+$lineplot->SetWeight( 2 );   // Two pixel wide
+
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example3.0.3.php b/web/classes/jpgraph/Examples/example3.0.3.php
new file mode 100755
index 0000000000000000000000000000000000000000..cc39f638ab1faa6fab1bd07d333a72a44f08bdbb
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example3.0.3.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some (random) data
+$ydata = array(17,3,'',10,7,'',3,19,9,7);
+
+// Size of the overall graph
+$width=350;
+$height=250;
+
+// Create the graph and set a scale.
+// These two calls are always required
+$graph = new Graph($width,$height);
+$graph->SetScale('intlin');
+$graph->SetShadow();
+
+// Setup margin and titles
+$graph->SetMargin(40,20,20,40);
+$graph->title->Set('NULL values');
+$graph->xaxis->title->Set('x-title');
+$graph->yaxis->title->Set('y-title');
+
+$graph->yaxis->title->SetFont( FF_ARIAL , FS_BOLD, 9 );
+$graph->xaxis->title->SetFont( FF_ARIAL , FS_BOLD, 9 );
+
+$graph->yaxis->SetColor('blue');
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor( 'blue' );
+$lineplot->SetWeight( 2 );   // Two pixel wide
+
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example3.1.1.php b/web/classes/jpgraph/Examples/example3.1.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..32e2cef8b06b104371bb3596b6e18619c7b080be
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example3.1.1.php
@@ -0,0 +1,43 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some (random) data
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Size of the overall graph
+$width=350;
+$height=250;
+
+// Create the graph and set a scale.
+// These two calls are always required
+$graph = new Graph($width,$height);
+$graph->SetScale('intlin');
+$graph->SetShadow();
+
+// Setup margin and titles
+$graph->SetMargin(40,20,20,40);
+$graph->title->Set('Calls per operator');
+$graph->subtitle->Set('(March 12, 2008)');
+$graph->xaxis->title->Set('Operator');
+$graph->yaxis->title->Set('# of calls');
+
+$graph->yaxis->title->SetFont( FF_FONT1 , FS_BOLD );
+$graph->xaxis->title->SetFont( FF_FONT1 , FS_BOLD );
+
+$graph->yaxis->SetColor('blue');
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor( 'blue' );
+$lineplot->SetWeight( 2 );   // Two pixel wide
+
+// Add an image mark scaled to 50%
+$lineplot->mark->SetType(MARK_IMG_DIAMOND,'red',0.5);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example3.1.php b/web/classes/jpgraph/Examples/example3.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..1c4e0adc960fc3852f54cecfb13d775820c4a35b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example3.1.php
@@ -0,0 +1,43 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some (random) data
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Size of the overall graph
+$width=350;
+$height=250;
+
+// Create the graph and set a scale.
+// These two calls are always required
+$graph = new Graph($width,$height);
+$graph->SetScale('intlin');
+$graph->SetShadow();
+
+// Setup margin and titles
+$graph->SetMargin(40,20,20,40);
+$graph->title->Set('Calls per operator');
+$graph->subtitle->Set('(March 12, 2008)');
+$graph->xaxis->title->Set('Operator');
+$graph->yaxis->title->Set('# of calls');
+
+$graph->yaxis->title->SetFont( FF_FONT1 , FS_BOLD );
+$graph->xaxis->title->SetFont( FF_FONT1 , FS_BOLD );
+
+$graph->yaxis->SetColor('blue');
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor( 'blue' );
+$lineplot->SetWeight( 2 );   // Two pixel wide
+$lineplot->mark->SetType(MARK_UTRIANGLE);
+$lineplot->mark->SetColor('blue');
+$lineplot->mark->SetFillColor('red');
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example3.2.1.php b/web/classes/jpgraph/Examples/example3.2.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..c739ce806c88e80a9b574f4af340c105294632c9
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example3.2.1.php
@@ -0,0 +1,35 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,15,5,7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+$graph->yaxis->scale->SetGrace(10,10);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->mark->SetType(MARK_CIRCLE);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+$graph->img->SetMargin(40,20,20,40);
+$graph->title->Set("Grace value, version 1");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+$graph->yaxis->SetWeight(2);
+$graph->SetShadow();
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example3.2.2.php b/web/classes/jpgraph/Examples/example3.2.2.php
new file mode 100755
index 0000000000000000000000000000000000000000..03d22c8ce73b26d6ca0dd1bb41a6e3dabf3e0b67
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example3.2.2.php
@@ -0,0 +1,37 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,15,5,7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+$graph->yaxis->scale->SetGrace(10,10);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->mark->SetType(MARK_CIRCLE);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+$graph->img->SetMargin(40,20,20,40);
+$graph->title->Set("Grace value version 2");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->xaxis->SetPos('min');
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+$graph->yaxis->SetWeight(2);
+$graph->SetShadow();
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example3.2.php b/web/classes/jpgraph/Examples/example3.2.php
new file mode 100755
index 0000000000000000000000000000000000000000..f7c05c5cd3b6303c101ae82175c98e5811a05e52
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example3.2.php
@@ -0,0 +1,34 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,15,5,7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->SetScale("textlin");
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->mark->SetType(MARK_CIRCLE);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+$graph->img->SetMargin(40,20,20,40);
+$graph->title->Set("Example 3.2");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+$graph->yaxis->SetWeight(2);
+$graph->SetShadow();
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example3.3.php b/web/classes/jpgraph/Examples/example3.3.php
new file mode 100755
index 0000000000000000000000000000000000000000..c20cd98cff3120d07b26ee0a19ecaf4ef7dfe38d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example3.3.php
@@ -0,0 +1,45 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some (random) data
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Size of the overall graph
+$width=350;
+$height=250;
+
+// Create the graph and set a scale.
+// These two calls are always required
+$graph = new Graph($width,$height);
+$graph->SetScale('intlin');
+$graph->SetShadow();
+
+// Setup margin and titles
+$graph->SetMargin(40,20,20,40);
+$graph->title->Set('Calls per operator');
+$graph->subtitle->Set('(March 12, 2008)');
+$graph->xaxis->title->Set('Operator');
+$graph->yaxis->title->Set('# of calls');
+
+$graph->yaxis->title->SetFont( FF_FONT1 , FS_BOLD );
+$graph->xaxis->title->SetFont( FF_FONT1 , FS_BOLD );
+
+$graph->yaxis->SetColor('blue');
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor( 'blue' );
+$lineplot->SetWeight( 2 );   // Two pixel wide
+$lineplot->mark->SetType(MARK_UTRIANGLE);
+$lineplot->mark->SetColor('blue');
+$lineplot->mark->SetFillColor('red');
+
+$lineplot->value->Show();
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example3.4.1.php b/web/classes/jpgraph/Examples/example3.4.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..77c0b24b72f2e3f637d2e19f9f80b161524ef017
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example3.4.1.php
@@ -0,0 +1,81 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// A function to return the Roman Numeral, given an integer
+ function numberToRoman($aNum)
+ {
+     // Make sure that we only use the integer portion of the value
+     $n = intval($aNum);
+     $result = '';
+
+     // Declare a lookup array that we will use to traverse the number:
+     $lookup = array('M' => 1000, 'CM' => 900, 'D' => 500, 'CD' => 400,
+     'C' => 100, 'XC' => 90, 'L' => 50, 'XL' => 40,
+     'X' => 10, 'IX' => 9, 'V' => 5, 'IV' => 4, 'I' => 1);
+
+     foreach ($lookup as $roman => $value)
+     {
+         // Determine the number of matches
+         $matches = intval($n / $value);
+
+         // Store that many characters
+         $result .= str_repeat($roman, $matches);
+
+         // Substract that from the number
+         $n = $n % $value;
+     }
+
+     // The Roman numeral should be built, return it
+     return $result;
+}
+
+function formatCallback($aVal) {
+	return '('.numberToRoman($aVal).')';
+}
+
+
+ // Some (random) data
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Size of the overall graph
+$width=350;
+$height=250;
+
+// Create the graph and set a scale.
+// These two calls are always required
+$graph = new Graph($width,$height);
+$graph->SetScale('intlin');
+$graph->SetShadow();
+
+// Setup margin and titles
+$graph->SetMargin(40,20,20,40);
+$graph->title->Set('Calls per operator');
+$graph->subtitle->Set('(March 12, 2008)');
+$graph->xaxis->title->Set('Operator');
+$graph->yaxis->title->Set('# of calls');
+
+$graph->yaxis->title->SetFont( FF_FONT1 , FS_BOLD );
+$graph->xaxis->title->SetFont( FF_FONT1 , FS_BOLD );
+
+$graph->yaxis->SetColor('blue');
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor( 'blue' );
+$lineplot->SetWeight( 2 );   // Two pixel wide
+$lineplot->mark->SetType(MARK_UTRIANGLE);
+$lineplot->mark->SetColor('blue');
+$lineplot->mark->SetFillColor('red');
+
+$lineplot->value->Show();
+$lineplot->value->SetFont(FF_ARIAL,FS_BOLD,10);
+$lineplot->value->SetColor('darkred');
+$lineplot->value->SetFormatCallback('formatCallback');
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example3.4.php b/web/classes/jpgraph/Examples/example3.4.php
new file mode 100755
index 0000000000000000000000000000000000000000..0d223c1788f0d30497895a43c9a6419e8c19b857
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example3.4.php
@@ -0,0 +1,48 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some (random) data
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Size of the overall graph
+$width=350;
+$height=250;
+
+// Create the graph and set a scale.
+// These two calls are always required
+$graph = new Graph($width,$height);
+$graph->SetScale('intlin');
+$graph->SetShadow();
+
+// Setup margin and titles
+$graph->SetMargin(40,20,20,40);
+$graph->title->Set('Calls per operator');
+$graph->subtitle->Set('(March 12, 2008)');
+$graph->xaxis->title->Set('Operator');
+$graph->yaxis->title->Set('# of calls');
+
+$graph->yaxis->title->SetFont( FF_FONT1 , FS_BOLD );
+$graph->xaxis->title->SetFont( FF_FONT1 , FS_BOLD );
+
+$graph->yaxis->SetColor('blue');
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor( 'blue' );
+$lineplot->SetWeight( 2 );   // Two pixel wide
+$lineplot->mark->SetType(MARK_UTRIANGLE);
+$lineplot->mark->SetColor('blue');
+$lineplot->mark->SetFillColor('red');
+
+$lineplot->value->Show();
+$lineplot->value->SetFont(FF_ARIAL,FS_BOLD,10);
+$lineplot->value->SetColor('darkred');
+$lineplot->value->SetFormat('(%d)');
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example3.php b/web/classes/jpgraph/Examples/example3.php
new file mode 100755
index 0000000000000000000000000000000000000000..4c79c1d49f7e6a75ae8cb78f42459c87fa0a0a72
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example3.php
@@ -0,0 +1,38 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some (random) data
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Size of the overall graph
+$width=350;
+$height=250;
+
+// Create the graph and set a scale.
+// These two calls are always required
+$graph = new Graph($width,$height);
+$graph->SetScale('intlin');
+
+// Setup margin and titles
+$graph->SetMargin(40,20,20,40);
+$graph->title->Set('Calls per operator');
+$graph->subtitle->Set('(March 12, 2008)');
+$graph->xaxis->title->Set('Operator');
+$graph->yaxis->title->Set('# of calls');
+
+$graph->yaxis->title->SetFont( FF_FONT1 , FS_BOLD );
+$graph->xaxis->title->SetFont( FF_FONT1 , FS_BOLD );
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor( 'blue' );
+$lineplot->SetWeight( 2 );   // Two pixel wide
+
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example4.php b/web/classes/jpgraph/Examples/example4.php
new file mode 100755
index 0000000000000000000000000000000000000000..42549d885bbaf310ba195d88cf2a17e3fee2e77e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example4.php
@@ -0,0 +1,45 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+ // Some (random) data
+$ydata   = array(11, 3, 8, 12, 5, 1, 9, 13, 5, 7);
+$ydata2  = array(1, 19, 15, 7, 22, 14, 5, 9, 21, 13 );
+
+// Size of the overall graph
+$width=350;
+$height=250;
+
+// Create the graph and set a scale.
+// These two calls are always required
+$graph = new Graph($width,$height);
+$graph->SetScale('intlin');
+$graph->SetShadow();
+
+// Setup margin and titles
+$graph->SetMargin(40,20,20,40);
+$graph->title->Set('Calls per operator (June,July)');
+$graph->subtitle->Set('(March 12, 2008)');
+$graph->xaxis->title->Set('Operator');
+$graph->yaxis->title->Set('# of calls');
+
+$graph->yaxis->title->SetFont( FF_FONT1 , FS_BOLD );
+$graph->xaxis->title->SetFont( FF_FONT1 , FS_BOLD );
+
+// Create the first data series
+$lineplot=new LinePlot($ydata);
+$lineplot->SetWeight( 2 );   // Two pixel wide
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Create the second data series
+$lineplot2=new LinePlot($ydata2);
+$lineplot2->SetWeight( 2 );   // Two pixel wide
+
+// Add the second plot to the graph
+$graph->Add($lineplot2);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example5.1.php b/web/classes/jpgraph/Examples/example5.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..383455847a06ec5785e5d1fe3304267294cb8232
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example5.1.php
@@ -0,0 +1,47 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+$y2data = array(354,200,265,99,111,91,198,225,293,251);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->img->SetMargin(40,40,20,40);
+$graph->SetScale("textlin");
+$graph->SetY2Scale("lin");
+$graph->SetShadow();
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot2=new LinePlot($y2data);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+$graph->AddY2($lineplot2);
+$lineplot2->SetColor("orange");
+$lineplot2->SetWeight(2);
+$graph->y2axis->SetColor("orange");
+
+$graph->title->Set("Example 5");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+
+$lineplot2->SetColor("orange");
+$lineplot2->SetWeight(2);
+
+$graph->yaxis->SetColor("blue");
+
+$lineplot->SetLegend("Plot 1");
+$lineplot2->SetLegend("Plot 2");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example5.php b/web/classes/jpgraph/Examples/example5.php
new file mode 100755
index 0000000000000000000000000000000000000000..d4b6838b644e67e32214ee7acd0384e8c9ae33f8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example5.php
@@ -0,0 +1,44 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+$y2data = array(354,200,265,99,111,91,198,225,293,251);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(300,200);	
+$graph->img->SetMargin(40,40,20,40);
+$graph->SetScale("textlin");
+$graph->SetY2Scale("lin");
+$graph->SetShadow();
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot2=new LinePlot($y2data);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+$graph->AddY2($lineplot2);
+$lineplot2->SetColor("orange");
+$lineplot2->SetWeight(2);
+$graph->y2axis->SetColor("orange");
+
+$graph->title->Set("Example 5");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+
+$lineplot2->SetColor("orange");
+$lineplot2->SetWeight(2);
+
+$graph->yaxis->SetColor("blue");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example6.1.php b/web/classes/jpgraph/Examples/example6.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..50007592a1062732839761a8b9ff5d07febc28cc
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example6.1.php
@@ -0,0 +1,55 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+$y2data = array(354,200,265,99,111,91,198,225,293,251);
+
+// Create the graph and specify the scale for both Y-axis
+$graph = new Graph(300,240);	
+$graph->SetScale("textlin");
+$graph->SetY2Scale("lin");
+$graph->SetShadow();
+
+// Adjust the margin
+$graph->img->SetMargin(40,40,20,70);
+
+// Create the two linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot2=new LinePlot($y2data);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+$graph->AddY2($lineplot2);
+$lineplot2->SetColor("orange");
+$lineplot2->SetWeight(2);
+
+// Adjust the axis color
+$graph->y2axis->SetColor("orange");
+$graph->yaxis->SetColor("blue");
+
+$graph->title->Set("Example 6.1");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Set the colors for the plots 
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+$lineplot2->SetColor("orange");
+$lineplot2->SetWeight(2);
+
+// Set the legends for the plots
+$lineplot->SetLegend("Plot 1");
+$lineplot2->SetLegend("Plot 2");
+
+// Adjust the legend position
+$graph->legend->SetLayout(LEGEND_HOR);
+$graph->legend->Pos(0.4,0.95,"center","bottom");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example6.2.php b/web/classes/jpgraph/Examples/example6.2.php
new file mode 100755
index 0000000000000000000000000000000000000000..7d0a75561f5bbad0f5288fe187f2a0fe4bbb35ac
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example6.2.php
@@ -0,0 +1,47 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+$y2data = array(354,200,265,99,111,91,198,225,293,251);
+
+// Create the graph and specify the scale for both Y-axis
+$graph = new Graph(300,240);	
+$graph->SetScale("textlin");
+$graph->SetShadow();
+
+// Adjust the margin
+$graph->img->SetMargin(40,40,20,70);
+
+// Create the two linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetStepStyle();
+
+// Adjust the axis color
+$graph->yaxis->SetColor("blue");
+
+$graph->title->Set("Example 6.2");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Set the colors for the plots 
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+
+// Set the legends for the plots
+$lineplot->SetLegend("Plot 1");
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Adjust the legend position
+$graph->legend->SetLayout(LEGEND_HOR);
+$graph->legend->Pos(0.4,0.95,"center","bottom");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example6.php b/web/classes/jpgraph/Examples/example6.php
new file mode 100755
index 0000000000000000000000000000000000000000..6cdc630358ffdac03c9e5b0a2e112bbceba0f1e4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example6.php
@@ -0,0 +1,54 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+$y2data = array(354,200,265,99,111,91,198,225,293,251);
+
+// Create the graph and specify the scale for both Y-axis
+$graph = new Graph(400,200);
+$graph->SetScale('textlin');
+$graph->SetY2Scale('lin');
+$graph->SetShadow();
+
+// Adjust the margin
+$graph->img->SetMargin(40,140,20,40);
+
+// Create the two linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot2=new LinePlot($y2data);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+$graph->AddY2($lineplot2);
+$lineplot2->SetColor('orange');
+$lineplot2->SetWeight(2);
+
+// Adjust the axis color
+$graph->y2axis->SetColor('orange');
+$graph->yaxis->SetColor('blue');
+
+$graph->title->Set('Example 6');
+$graph->xaxis->title->Set('X-title');
+$graph->yaxis->title->Set('Y-title');
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Set the colors for the plots
+$lineplot->SetColor('blue');
+$lineplot->SetWeight(2);
+$lineplot2->SetColor('orange');
+$lineplot2->SetWeight(2);
+
+// Set the legends for the plots
+$lineplot->SetLegend('Plot 1');
+$lineplot2->SetLegend('Plot 2');
+
+// Adjust the legend position
+$graph->legend->Pos(0.05,0.5,'right','center');
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example7.php b/web/classes/jpgraph/Examples/example7.php
new file mode 100755
index 0000000000000000000000000000000000000000..e8f75c4c324cda4b4554b676568cebf797fb3ffc
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example7.php
@@ -0,0 +1,44 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_log.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+$y2data = array(354,70,265,29,111,91,198,225,593,251);
+
+// Create the graph.
+$graph = new Graph(350,200);	
+$graph->SetScale("textlin");
+$graph->SetY2Scale("log");
+$graph->SetShadow();
+$graph->img->SetMargin(40,110,20,40);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot2=new LinePlot($y2data);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+$graph->AddY2($lineplot2);
+$graph->yaxis->SetColor('blue');
+
+$graph->title->Set("Example 7");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+$lineplot2->SetWeight(2);
+
+$lineplot->SetLegend("Plot 1");
+$lineplot2->SetLegend("Plot 2");
+
+$graph->legend->Pos(0.05,0.5,"right","center");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example8.1.php b/web/classes/jpgraph/Examples/example8.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..8cab7e421b53b08d0cbb659ff26687af6450b044
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example8.1.php
@@ -0,0 +1,57 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_log.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+$y2data = array(354,200,265,99,111,91,198,225,293,251);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(350,200);	
+$graph->SetScale("textlog");
+$graph->SetY2Scale("log");
+
+$graph->SetShadow();
+$graph->SetMargin(40,110,20,40);
+
+$graph->ygrid->Show(true,true);
+$graph->xgrid->Show(true,false);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+
+$lineplot2=new LinePlot($y2data);
+$lineplot2->SetColor("orange");
+$lineplot2->SetWeight(2);
+
+$graph->yaxis->scale->ticks->SupressFirst();
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+$graph->AddY2($lineplot2);
+
+$graph->title->Set("Example 8");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+
+$lineplot2->SetColor("orange");
+$lineplot2->SetWeight(2);
+
+$graph->yaxis->SetColor("blue");
+$graph->y2axis->SetColor("orange");
+
+$lineplot->SetLegend("Plot 1");
+$lineplot2->SetLegend("Plot 2");
+
+$graph->legend->Pos(0.05,0.5,"right","center");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example8.php b/web/classes/jpgraph/Examples/example8.php
new file mode 100755
index 0000000000000000000000000000000000000000..773265bda5a2289e25d5adea9b288f0f72eac9b8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example8.php
@@ -0,0 +1,48 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_log.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+$y2data = array(354,200,265,99,111,91,198,225,293,251);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(350,200);	
+$graph->SetScale("textlog");
+$graph->SetShadow();
+$graph->img->SetMargin(40,110,20,40);
+
+// Show the gridlines
+$graph->ygrid->Show(true,true);
+$graph->xgrid->Show(true,false);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot2=new LinePlot($y2data);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+$graph->title->Set("Example 8");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+
+// Adjust the color of the Y axis
+$graph->yaxis->SetColor("blue");
+
+// Specifya a legend
+$lineplot->SetLegend("Plot 1");
+
+// Adjust the position of the grid box
+$graph->legend->Pos(0.05,0.5,"right","center");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example9.1.php b/web/classes/jpgraph/Examples/example9.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..addcb5f49df551992dcf5823e2014857d74aa098
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example9.1.php
@@ -0,0 +1,50 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_log.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+
+$ydata = array(11,3,8,42,5,1,9,13,5,7);
+$datax = array("Jan","Feb","Mar","Apr","Maj","Jun","Jul","aug","Sep","Oct");
+
+// Create the graph. These two calls are always required
+$graph = new Graph(350,200);
+$graph->SetScale("textlog");
+
+$graph->img->SetMargin(40,110,20,40);
+$graph->SetShadow();
+
+$graph->ygrid->Show(true,true);
+$graph->xgrid->Show(true,false);
+
+// Specify the tick labels
+$a = $gDateLocale->GetShortMonth();
+$graph->xaxis->SetTickLabels($a);
+$graph->xaxis->SetTextLabelInterval(2);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+$graph->title->Set("Examples 9");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+
+$graph->yaxis->SetColor("blue");
+
+$lineplot->SetLegend("Plot 1");
+
+$graph->legend->Pos(0.05,0.5,"right","center");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example9.2.php b/web/classes/jpgraph/Examples/example9.2.php
new file mode 100755
index 0000000000000000000000000000000000000000..c765981e069de946db17e90a39211c28d328b7e1
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example9.2.php
@@ -0,0 +1,52 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_log.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+
+$ydata = array(11,3,8,42,5,1,9,13,5,7);
+$datax = array("Jan","Feb","Mar","Apr","Maj","Jun","Jul","aug","Sep","Oct");
+
+// Create the graph. These two calls are always required
+$graph = new Graph(350,200);
+$graph->SetScale("textlog");
+
+$graph->img->SetMargin(40,110,20,50);
+$graph->SetShadow();
+
+$graph->ygrid->Show(true,true);
+$graph->xgrid->Show(true,false);
+
+// Specify the tick labels
+$a = $gDateLocale->GetShortMonth();
+$graph->xaxis->SetTickLabels($a);
+//$graph->xaxis->SetTextLabelInterval(2);
+$graph->xaxis->SetLabelAngle(90);
+
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+$graph->title->Set("Examples 9");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+
+$graph->yaxis->SetColor("blue");
+
+$lineplot->SetLegend("Plot 1");
+
+$graph->legend->Pos(0.05,0.5,"right","center");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/example9.php b/web/classes/jpgraph/Examples/example9.php
new file mode 100755
index 0000000000000000000000000000000000000000..03c54790d85f072ee3ecfb688e040dd2a4c7d439
--- /dev/null
+++ b/web/classes/jpgraph/Examples/example9.php
@@ -0,0 +1,49 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_log.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+
+$ydata = array(11,3,8,42,5,1,9,13,5,7);
+$datax = array("Jan","Feb","Mar","Apr","Maj","Jun","Jul","aug","Sep","Oct");
+
+// Create the graph. These two calls are always required
+$graph = new Graph(350,200);
+$graph->SetScale("textlog");
+
+$graph->img->SetMargin(40,110,20,40);
+$graph->SetShadow();
+
+$graph->ygrid->Show(true,true);
+$graph->xgrid->Show(true,false);
+
+// Specify the tick labels
+$a = $gDateLocale->GetShortMonth();
+$graph->xaxis->SetTickLabels($a);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+$graph->title->Set("Examples 9");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+
+$graph->yaxis->SetColor("blue");
+
+$lineplot->SetLegend("Plot 1");
+
+$graph->legend->Pos(0.05,0.5,"right","center");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/exampleex9.php b/web/classes/jpgraph/Examples/exampleex9.php
new file mode 100755
index 0000000000000000000000000000000000000000..9d87985f86cc43310ce6baa3a6a789f4d61a7d47
--- /dev/null
+++ b/web/classes/jpgraph/Examples/exampleex9.php
@@ -0,0 +1,63 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_log.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+$y2data = array(354,200,265,99,111,91,198,225,293,251);
+$datax = array("Jan","Feb","Mar","Apr","Maj","Jun","Jul","aug","Sep","Oct");
+
+// Create the graph. These two calls are always required
+// We also specify a 2 min timeout for the cached image
+$graph = new Graph(350,200);
+$graph->SetScale("textlog");
+
+$graph->img->SetMargin(40,110,20,40);
+
+$graph->SetY2Scale("log");
+$graph->SetShadow();
+
+$graph->ygrid->Show(true,true);
+$graph->xgrid->Show(true,false);
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot2=new LinePlot($y2data);
+
+$graph->yaxis->scale->ticks->SupressFirst();
+$graph->y2axis->scale->ticks->SupressFirst();
+// Add the plot to the graph
+$graph->Add($lineplot);
+$graph->AddY2($lineplot2);
+$lineplot2->SetColor("orange");
+$lineplot2->SetWeight(2);
+$graph->y2axis->SetColor("orange");
+
+$graph->title->Set("Examples 9");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+
+$lineplot2->SetColor("orange");
+$lineplot2->SetWeight(2);
+
+$graph->yaxis->SetColor("blue");
+
+$lineplot->SetLegend("Plot 1");
+$lineplot2->SetLegend("Plot 2");
+
+$graph->legend->Pos(0.05,0.5,"right","center");
+
+$graph->xaxis->SetTickLabels($datax);
+$graph->xaxis->SetTextTickInterval(2);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/fieldscatterex1.php b/web/classes/jpgraph/Examples/fieldscatterex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..94b47fb69d0640ae4c5c15af522ea8fcd1164050
--- /dev/null
+++ b/web/classes/jpgraph/Examples/fieldscatterex1.php
@@ -0,0 +1,92 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+$polex = 6;
+$poley = 40;
+
+function FldCallback($x,$y,$a) {
+    GLOBAL $polex, $poley;
+    $maxr = 3000;
+
+    // Size and arrow size is constant
+    $size="";
+    $arrowsize="";
+
+    // Since we have different scales we need the data points
+    // to be of the same magnitude to give it a distance
+    // interpretation.
+    $x *= 10; 
+
+    // Colors gets colder the further out we go from the center
+    $r = ($x-$polex*10)*($x-$polex*10)+($y-$poley)*($y-$poley);
+    $f = $r/$maxr;
+    if( $f > 1 ) $f=1;
+    $red = floor((1-$f)*255);
+    $blue = floor($f*255);
+    $color = array($red,0,$blue);
+    //echo "x=$x, y=$y, blue=$blue, red=$red<br>";
+    return array($color,$size,$arrowsize);
+}
+
+// Create data for a simulated pseudo-magnetic radient field
+$datax = array();
+$datay = array();
+$angle = array();
+for($x=1; $x < 10; ++$x ) {
+    for($y=10; $y<100; $y += 10) {
+	$a = -1;
+	if( $x==$polex && $y==$poley ) continue;
+	if( $x==$polex ) {
+	    if( $y > $poley ) $a=90;
+	    else $a = 270;
+	}
+	if( $y==$poley ) {
+	    if( $x  > $polex ) $a=0;
+	    else  $a=180;	    
+	}
+	if( $a == -1 ) {
+	    $d1 = $y-$poley;
+	    $d2 = ($polex-$x)*20;
+	    if( $y < $poley ) $d2 *= -1;
+	    $h = sqrt($d1*$d1+$d2*$d2);
+	    $t = -$d2/$h;
+	    $ac = acos($t);
+	    if( $y < $poley ) $ac += M_PI;
+	    $a = $ac * 180/M_PI;
+	}
+	$datax[] = $x;
+	$datay[] = $y;
+	$angle[] = $a;
+    }
+}
+
+// Setup the graph
+$graph = new Graph(300,200);
+$graph->SetScale("intlin",0,100,0,10);
+$graph->SetMarginColor('lightblue');
+
+
+// ..and titles
+$graph->title->Set("Field plot");
+
+// Setup the field plot
+$fp = new FieldPlot($datay,$datax,$angle);
+
+// Setup formatting callback
+$fp->SetCallback('FldCallback');
+
+// First size argument is length (in pixels of arrow) 
+// Second size argument is roughly size of arrow. Arrow size is specified as
+// an integer in the range [0,9]
+$fp->arrow->SetSize(20,2);
+$fp->arrow->SetColor('navy');
+
+$graph->Add($fp);
+
+// .. and output
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/filledgridex1.php b/web/classes/jpgraph/Examples/filledgridex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..8e863792abc1bf4c34f700a6621eac52cd7a62cf
--- /dev/null
+++ b/web/classes/jpgraph/Examples/filledgridex1.php
@@ -0,0 +1,50 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay1 = array(20,15,23,15);
+$datay2 = array(12,9,42,8);
+$datay3 = array(5,17,32,24);
+
+// Setup the graph
+$graph = new Graph(300,200);
+$graph->SetMarginColor('white');
+$graph->SetScale("textlin");
+$graph->SetFrame(false);
+$graph->SetMargin(30,50,30,30);
+
+$graph->title->Set('Filled Y-grid');
+
+
+$graph->yaxis->HideZeroLabel();
+$graph->ygrid->SetFill(true,'#EFEFEF@0.5','#BBCCFF@0.5');
+$graph->xgrid->Show();
+
+$graph->xaxis->SetTickLabels($gDateLocale->GetShortMonth());
+
+// Create the first line
+$p1 = new LinePlot($datay1);
+$p1->SetColor("navy");
+$p1->SetLegend('Line 1');
+$graph->Add($p1);
+
+// Create the second line
+$p2 = new LinePlot($datay2);
+$p2->SetColor("red");
+$p2->SetLegend('Line 2');
+$graph->Add($p2);
+
+// Create the third line
+$p3 = new LinePlot($datay3);
+$p3->SetColor("orange");
+$p3->SetLegend('Line 3');
+$graph->Add($p3);
+
+$graph->legend->SetShadow('gray@0.4',5);
+$graph->legend->SetPos(0.1,0.1,'right','top');
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/filledline01.php b/web/classes/jpgraph/Examples/filledline01.php
new file mode 100755
index 0000000000000000000000000000000000000000..4140b299330fa672c611a62c9d804dd625517d64
--- /dev/null
+++ b/web/classes/jpgraph/Examples/filledline01.php
@@ -0,0 +1,24 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay = array(1.23,1.9,1.6,3.1,3.4,2.8,2.1,1.9);
+$graph = new Graph(300,200,'auto');
+$graph->img->SetMargin(40,40,40,40);	
+$graph->SetScale("textlin");
+$graph->SetShadow();
+$graph->title->Set("Example of filled line plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$p1 = new LinePlot($datay);
+$p1->SetFillColor("orange");
+$p1->mark->SetType(MARK_FILLEDCIRCLE);
+$p1->mark->SetFillColor("red");
+$p1->mark->SetWidth(4);
+$graph->Add($p1);
+
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/filledlineex01.1.php b/web/classes/jpgraph/Examples/filledlineex01.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..547d207e29470cc292a1e7cfb100ee2c2c062d87
--- /dev/null
+++ b/web/classes/jpgraph/Examples/filledlineex01.1.php
@@ -0,0 +1,24 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay = array(1.23,1.9,1.6,3.1,3.4,2.8,2.1,1.9);
+$graph = new Graph(300,200);
+$graph->SetScale("textlin");
+
+$graph->img->SetMargin(40,40,40,40);	
+$graph->SetShadow();
+$graph->SetGridDepth(DEPTH_FRONT);
+
+$graph->title->Set("Example of filled line plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$p1 = new LinePlot($datay);
+$p1->SetFillColor("orange");
+$p1->mark->SetType(MARK_FILLEDCIRCLE);
+$p1->mark->SetFillColor("red");
+$p1->mark->SetWidth(4);
+$graph->Add($p1);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/filledlineex01.php b/web/classes/jpgraph/Examples/filledlineex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..6ea2c88dd8955b4cc58438ef8cbfa36212425d53
--- /dev/null
+++ b/web/classes/jpgraph/Examples/filledlineex01.php
@@ -0,0 +1,23 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay = array(1.23, 1.9, 1.6, 3.1, 3.4, 2.8, 2.1, 1.9);
+$graph = new Graph(300,200);
+$graph->SetScale('textlin');
+
+$graph->img->SetMargin(40,40,40,40);
+$graph->SetShadow();
+
+$graph->title->Set("Example of filled line plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$p1 = new LinePlot($datay);
+$p1->SetFillColor("orange");
+$p1->mark->SetType(MARK_FILLEDCIRCLE);
+$p1->mark->SetFillColor("red");
+$p1->mark->SetWidth(4);
+$graph->Add($p1);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/filledlineex02.php b/web/classes/jpgraph/Examples/filledlineex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..1b4db02f51794df987fb256dc7357efc8b94ce93
--- /dev/null
+++ b/web/classes/jpgraph/Examples/filledlineex02.php
@@ -0,0 +1,24 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay = array(1.23,1.9,1.6,3.1,3.4,2.8,2.1,1.9);
+$graph = new Graph(300,200);
+$graph->img->SetMargin(40,40,40,40);	
+$graph->SetScale("textlin");
+$graph->SetShadow();
+$graph->title->Set("Example of filled line plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->subtitle->Set("(Starting from Y=0)");
+
+$graph->yaxis->scale->SetAutoMin(0);
+
+$p1 = new LinePlot($datay);
+$p1->SetFillColor("orange");
+$p1->mark->SetType(MARK_FILLEDCIRCLE);
+$p1->mark->SetFillColor("red");
+$p1->mark->SetWidth(4);
+$graph->Add($p1);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/filledlineex03.php b/web/classes/jpgraph/Examples/filledlineex03.php
new file mode 100755
index 0000000000000000000000000000000000000000..084e655d65ad209ccc4f3e7bef89c44457496f00
--- /dev/null
+++ b/web/classes/jpgraph/Examples/filledlineex03.php
@@ -0,0 +1,23 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay = array(11,30,20,13,10,'x',16,12,'x',15,4,9);
+
+// Setup the graph
+$graph = new Graph(400,250);
+$graph->SetScale('intlin');
+$graph->title->Set('Filled line with NULL values');
+//Make sure data starts from Zero whatever data we have
+$graph->yscale->SetAutoMin(0);
+
+$p1 = new LinePlot($datay);
+$p1->SetFillColor('lightblue');
+$graph->Add($p1);
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/filledstepstyleex1.php b/web/classes/jpgraph/Examples/filledstepstyleex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..75688b5f90cf9b4acd8b60face2143d033652cee
--- /dev/null
+++ b/web/classes/jpgraph/Examples/filledstepstyleex1.php
@@ -0,0 +1,39 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// create the graph
+$graph= new Graph(400,250);
+
+$ydata = array(5,10,15,20,15,10);
+
+$graph->SetScale("textlin");
+$graph->SetShadow(true);
+$graph->SetMarginColor("antiquewhite");
+$graph->img->SetMargin(60,40,40,50);
+$graph->img->setTransparent("white");
+$graph->xaxis->SetFont(FF_FONT1);
+$graph->xaxis->setTextTickInterval(1);
+$graph->xaxis->SetTextLabelInterval(1);
+$graph->legend->SetFillColor("antiquewhite");
+$graph->legend->SetShadow(true);
+$graph->legend->SetLayout(LEGEND_VERT);
+$graph->legend->Pos(0.02,0.01);
+$graph->title->Set("Step Styled Example");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$lineplot = new LinePlot($ydata);
+$lineplot->SetColor("black");
+$lineplot->setFillColor("gray7");
+$lineplot->SetStepStyle();
+$lineplot->SetLegend(" 2002 ");
+
+// add plot to the graph
+$graph->Add($lineplot);
+$graph->ygrid->show(false,false);
+
+// display graph
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/fireplace.jpg b/web/classes/jpgraph/Examples/fireplace.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..8006e3d0033dcac36c19fbd998655d1046340e2b
Binary files /dev/null and b/web/classes/jpgraph/Examples/fireplace.jpg differ
diff --git a/web/classes/jpgraph/Examples/fixscale_radarex1.php b/web/classes/jpgraph/Examples/fixscale_radarex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..d663d90825abb827620d63b9c215e4efed0ee58d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/fixscale_radarex1.php
@@ -0,0 +1,36 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_radar.php');
+
+$graph = new RadarGraph(300,300);
+$graph->SetScale('lin',0,50);
+$graph->yscale->ticks->Set(25,5);
+$graph->SetColor('white');
+$graph->SetShadow();
+
+$graph->SetCenter(0.5,0.55);
+
+$graph->axis->SetFont(FF_FONT1,FS_BOLD);
+$graph->axis->SetWeight(2);
+
+// Uncomment the following lines to also show grid lines.
+$graph->grid->SetLineStyle('dashed');
+$graph->grid->SetColor('navy@0.5');
+$graph->grid->Show();
+
+$graph->ShowMinorTickMarks();
+
+$graph->title->Set('Quality result');
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->SetTitles(array('One','Two','Three','Four','Five','Sex','Seven','Eight','Nine','Ten'));
+
+$plot = new RadarPlot(array(12,35,20,30,33,15,37));
+$plot->SetLegend('Goal');
+$plot->SetColor('red','lightred');
+$plot->SetFillColor('lightblue');
+$plot->SetLineWeight(2);
+
+$graph->Add($plot);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/footerex1.php b/web/classes/jpgraph/Examples/footerex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..a3d113dcd9b4c8591edce332c296935d880b86cf
--- /dev/null
+++ b/web/classes/jpgraph/Examples/footerex1.php
@@ -0,0 +1,62 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+$datay1 = array(4,26,15,44);
+
+// Setup the graph
+$graph = new Graph(300,250);
+$graph->SetMarginColor('white');
+$graph->SetScale("textlin");
+$graph->SetFrame(false);
+$graph->SetMargin(30,5,25,50);
+
+// Setup the tab
+$graph->tabtitle->Set(' Year 2003 ' );
+$graph->tabtitle->SetFont(FF_ARIAL,FS_BOLD,13);
+$graph->tabtitle->SetColor('darkred','#E1E1FF');
+
+// Enable X-grid as well
+$graph->xgrid->Show();
+
+// Use months as X-labels
+$graph->xaxis->SetTickLabels($gDateLocale->GetShortMonth());
+
+$graph->footer->left->Set('L. footer');
+$graph->footer->left->SetFont(FF_ARIAL,FS_NORMAL,12); 
+$graph->footer->left->SetColor('darkred');
+$graph->footer->center->Set('C. footer');
+$graph->footer->center->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->footer->center->SetColor('darkred');
+$graph->footer->right->Set('R. footer');
+$graph->footer->right->SetFont(FF_ARIAL,FS_NORMAL,12); 
+$graph->footer->right->SetColor('darkred');
+
+// Create the plot
+$p1 = new LinePlot($datay1);
+$p1->SetColor("navy");
+
+// Use an image of favourite car as marker
+$p1->mark->SetType(MARK_IMG,'saab_95.jpg',0.5);
+
+// Displayes value on top of marker image
+$p1->value->SetFormat('%d mil');
+$p1->value->Show();
+$p1->value->SetColor('darkred');
+$p1->value->SetFont(FF_ARIAL,FS_BOLD,10);
+// Increase the margin so that the value is printed avove tje
+// img marker
+$p1->value->SetMargin(14);
+
+// Incent the X-scale so the first and last point doesn't
+// fall on the edges
+$p1->SetCenter();
+
+$graph->Add($p1);
+
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/funcex1.php b/web/classes/jpgraph/Examples/funcex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..de12e61683fea0636782e8e9a2df426e3b5f8558
--- /dev/null
+++ b/web/classes/jpgraph/Examples/funcex1.php
@@ -0,0 +1,58 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_utils.inc.php');
+
+$f = new FuncGenerator('cos($x)*$x');
+list($xdata,$ydata) = $f->E(-1.2*M_PI,1.2*M_PI);
+
+$f = new FuncGenerator('$x*$x');
+list($x2data,$y2data) = $f->E(-2,2);
+
+// Setup the basic graph
+$graph = new Graph(450,350);
+$graph->SetScale("linlin");
+$graph->SetShadow();
+$graph->img->SetMargin(50,50,60,40);	
+$graph->SetBox(true,'black',2);	
+$graph->SetMarginColor('white');
+$graph->SetColor('lightyellow');
+
+// ... and titles
+$graph->title->Set('Example of Function plot');
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->subtitle->Set("(With some more advanced axis formatting\nHiding first and last label)");
+$graph->subtitle->SetFont(FF_FONT1,FS_NORMAL);
+$graph->xgrid->Show();
+
+$graph->yaxis->SetPos(0);
+$graph->yaxis->SetWeight(2);
+$graph->yaxis->HideZeroLabel();
+$graph->yaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->SetColor('black','darkblue');
+$graph->yaxis->HideTicks(true,false);
+$graph->yaxis->HideFirstLastLabel();
+
+$graph->xaxis->SetWeight(2);
+$graph->xaxis->HideZeroLabel();
+$graph->xaxis->HideFirstLastLabel();
+$graph->xaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->SetColor('black','darkblue');
+
+$lp1 = new LinePlot($ydata,$xdata);
+$lp1->SetColor('blue');
+$lp1->SetWeight(2);
+
+$lp2 = new LinePlot($y2data,$x2data);
+list($xm,$ym)=$lp2->Max();
+$lp2->SetColor('red');
+$lp2->SetWeight(2);
+
+
+$graph->Add($lp1);
+$graph->Add($lp2);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/funcex2.php b/web/classes/jpgraph/Examples/funcex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..5715f36a6ff7f6d4eee846043e90aa27a653adca
--- /dev/null
+++ b/web/classes/jpgraph/Examples/funcex2.php
@@ -0,0 +1,34 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_utils.inc.php');
+
+$f = new FuncGenerator('cos($i)','$i*$i*$i');
+list($xdata,$ydata) = $f->E(-M_PI,M_PI,25);
+
+$graph = new Graph(380,450);
+$graph->SetScale("linlin");
+$graph->SetShadow();
+$graph->img->SetMargin(50,50,60,40);	
+$graph->SetBox(true,'black',2);	
+$graph->SetMarginColor('white');
+$graph->SetColor('lightyellow');
+$graph->SetAxisStyle(AXSTYLE_SIMPLE);
+
+//$graph->xaxis->SetLabelFormat('%.1f');
+
+$graph->title->Set("Function plot with marker");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->subtitle->Set("(BOXOUT Axis style)");
+$graph->subtitle->SetFont(FF_FONT1,FS_NORMAL);
+
+$lp1 = new LinePlot($ydata,$xdata);
+$lp1->mark->SetType(MARK_FILLEDCIRCLE);
+$lp1->mark->SetFillColor("red");
+$lp1->SetColor("blue");
+
+$graph->Add($lp1);
+$graph->Stroke();
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/funcex3.php b/web/classes/jpgraph/Examples/funcex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..a63456ea94cfaf833291d9ff1d1a9131752a1389
--- /dev/null
+++ b/web/classes/jpgraph/Examples/funcex3.php
@@ -0,0 +1,37 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_utils.inc.php');
+
+$f = new FuncGenerator('cos($i)','$i*$i*$i');
+list($xdata,$ydata) = $f->E(-M_PI,M_PI,25);
+
+$graph = new Graph(350,430);
+$graph->SetScale("linlin");
+$graph->SetShadow();
+$graph->img->SetMargin(50,50,60,40);	
+$graph->SetBox(true,'black',2);	
+$graph->SetMarginColor('white');
+$graph->SetColor('lightyellow');
+$graph->SetAxisStyle(AXSTYLE_BOXIN);
+$graph->xgrid->Show();
+
+
+//$graph->xaxis->SetLabelFormat('%.0f');
+
+$graph->img->SetMargin(50,50,60,40);		
+
+$graph->title->Set("Function plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->subtitle->Set("(BOXIN Axis style)");
+$graph->subtitle->SetFont(FF_FONT1,FS_NORMAL);
+
+$lp1 = new LinePlot($ydata,$xdata);
+$lp1->SetColor("blue");
+$lp1->SetWeight(2);
+
+$graph->Add($lp1);
+$graph->Stroke();
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/funcex4.php b/web/classes/jpgraph/Examples/funcex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..bcd8b4dc8e38a58532a26159832fb40982944645
--- /dev/null
+++ b/web/classes/jpgraph/Examples/funcex4.php
@@ -0,0 +1,63 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_utils.inc.php');
+
+$f = new FuncGenerator('cos($x)*$x');
+list($xdata,$ydata) = $f->E(-1.2*M_PI,1.2*M_PI);
+
+$f = new FuncGenerator('$x*$x');
+list($x2data,$y2data) = $f->E(-2,2);
+
+// Setup the basic graph
+$graph = new Graph(450,350);
+$graph->SetScale("linlin");
+//$graph->SetShadow();
+$graph->img->SetMargin(5,10,60,9);	
+$graph->SetBox(true,'green',2);	
+$graph->SetMarginColor('black');
+$graph->SetColor('black');
+
+// ... and titles
+$graph->title->Set('Example of Function plot');
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->title->SetColor('lightgreen');
+$graph->subtitle->Set("(With some more advanced axis formatting\nHiding first and last label)");
+$graph->subtitle->SetFont(FF_FONT1,FS_NORMAL);
+$graph->subtitle->SetColor('lightgreen');
+
+$graph->xgrid->Show();
+$graph->xgrid->SetColor('darkgreen');
+$graph->ygrid->SetColor('darkgreen');
+
+$graph->yaxis->SetPos(0);
+$graph->yaxis->SetWeight(2);
+$graph->yaxis->HideZeroLabel();
+$graph->yaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->SetColor('green','green');
+$graph->yaxis->HideTicks(true,true);
+$graph->yaxis->HideFirstLastLabel();
+
+$graph->xaxis->SetWeight(2);
+$graph->xaxis->HideZeroLabel();
+$graph->xaxis->HideFirstLastLabel();
+$graph->xaxis->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->SetColor('green','green');
+
+$lp1 = new LinePlot($ydata,$xdata);
+$lp1->SetColor('yellow');
+$lp1->SetWeight(2);
+
+$lp2 = new LinePlot($y2data,$x2data);
+list($xm,$ym)=$lp2->Max();
+$lp2->SetColor('blue');
+$lp2->SetWeight(2);
+
+
+$graph->Add($lp1);
+$graph->Add($lp2);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/fusion_example.php b/web/classes/jpgraph/Examples/fusion_example.php
new file mode 100755
index 0000000000000000000000000000000000000000..4e4ae00feec4013cbb0eab748d7604b74060251e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/fusion_example.php
@@ -0,0 +1,57 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$theme = isset($_GET['theme']) ? $_GET['theme'] : null;
+$data = array (
+  0 => array (0 => 79, 1 => -25, 2 => -7, 3 => 85, 4 => -26, 5 => -32, ),
+  1 => array (0 => 76, 1 => 51, 2 => 86, 3 => 12, 4 => -7, 5 => 94, ),
+  2 => array (0 => 49, 1 => 38, 2 => 7, 3 => -40, 4 => 9, 5 => -7, ),
+  3 => array ( 0 => 69, 1 => 96, 2 => 49, 3 => 7, 4 => 92, 5 => -38, ),
+  4 => array ( 0 => 68, 1 => 16, 2 => 82, 3 => -49, 4 => 50, 5 => 7, ),
+  5 => array ( 0 => -37, 1 => 28, 2 => 32, 3 => 6, 4 => 13, 5 => 57, ),
+  6 => array ( 0 => 24, 1 => -11, 2 => 7, 3 => 10, 4 => 51, 5 => 51, ),
+  7 => array ( 0 => 3, 1 => -1, 2 => -12, 3 => 61, 4 => 10, 5 => 47, ),
+  8 => array ( 0 => -47, 1 => -21, 2 => 43, 3 => 53, 4 => 36, 5 => 34, ),
+);
+
+
+// Create the graph. These two calls are always required
+$graph = new Graph(400,300);    
+
+$graph->SetScale("textlin");
+if ($theme) {
+  $graph->SetTheme(new $theme());
+}
+$theme_class = new FusionTheme;
+$graph->SetTheme($theme_class);
+
+$plot = array();
+// Create the bar plots
+for ($i = 0; $i < 4; $i++) {
+  $plot[$i] = new BarPlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.($i+1));
+}
+//$acc1 = new AccBarPlot(array($plot[0], $plot[1]));
+//$acc1->value->Show();
+$gbplot = new GroupBarPlot(array($plot[2], $plot[1] ));
+
+for ($i = 4; $i < 8; $i++) {
+  $plot[$i] = new LinePlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.$i);
+  $plot[$i]->value->Show();
+}
+
+$graph->Add($gbplot);
+$graph->Add($plot[4]);
+
+$title = "FusionTheme Example";
+$title = mb_convert_encoding($title,'UTF-8');
+$graph->title->Set($title);
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/gantt_samerowex1.php b/web/classes/jpgraph/Examples/gantt_samerowex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..6c59cebde6dbeda2440fa0b99a1c6ca9233c9d9e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/gantt_samerowex1.php
@@ -0,0 +1,63 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("Activities on same row");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR4);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// 0 % vertical label margin
+$graph->SetLabelVMarginFactor(1); // 1=default value
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity1 = new GanttBar(0,"Activity 1","2001-12-21","2001-12-26","");
+
+// Yellow diagonal line pattern on a red background
+$activity1->SetPattern(BAND_RDIAG,"yellow");
+$activity1->SetFillColor("red");
+
+// Set absolute height of activity
+$activity1->SetHeight(16);
+
+// Format the bar for the second activity
+// ($row,$title,$startdate,$enddate)
+$activity2 = new GanttBar(0,"","2001-12-31","2002-01-2","[BO]");
+
+// ADjust font for caption
+$activity2->caption->SetFont(FF_ARIAL,FS_BOLD);
+$activity2->caption->SetColor("darkred");
+
+// Yellow diagonal line pattern on a red background
+$activity2->SetPattern(BAND_RDIAG,"yellow");
+$activity2->SetFillColor("red");
+
+// Set absolute height of activity
+$activity2->SetHeight(16);
+
+// Finally add the bar to the graph
+$graph->Add($activity1);
+$graph->Add($activity2);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/gantt_samerowex2.php b/web/classes/jpgraph/Examples/gantt_samerowex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..b3e2702a00db812eea44f0cd31d02c0462382e86
--- /dev/null
+++ b/web/classes/jpgraph/Examples/gantt_samerowex2.php
@@ -0,0 +1,65 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("Activities on same row");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set('Using break style');
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR4);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// 0 % vertical label margin
+$graph->SetLabelVMarginFactor(1); // 1=default value
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity1 = new GanttBar(0,"Activity 1","2001-12-21","2001-12-26","");
+
+// Yellow diagonal line pattern on a red background
+$activity1->SetPattern(BAND_RDIAG,"yellow");
+$activity1->SetFillColor("red");
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$break1 = new GanttBar(0,'',"2001-12-27","2001-12-30","");
+$break1->SetBreakStyle(true,'dotted',2);
+$break1->SetColor('red');
+$graph->Add($break1);
+
+// Format the bar for the second activity
+// ($row,$title,$startdate,$enddate)
+$activity2 = new GanttBar(0,"","2001-12-31","2002-01-2","[BO]");
+
+// ADjust font for caption
+$activity2->caption->SetFont(FF_ARIAL,FS_BOLD);
+$activity2->caption->SetColor("darkred");
+
+// Yellow diagonal line pattern on a red background
+$activity2->SetPattern(BAND_RDIAG,"yellow");
+$activity2->SetFillColor("red");
+
+// Finally add the bar to the graph
+$graph->Add($activity1);
+$graph->Add($activity2);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/gantt_textex1.php b/web/classes/jpgraph/Examples/gantt_textex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..dae1d56e664a531609b129b980f00b80140992e3
--- /dev/null
+++ b/web/classes/jpgraph/Examples/gantt_textex1.php
@@ -0,0 +1,96 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+require_once ('jpgraph/jpgraph_flags.php');
+
+$graph = new GanttGraph(0,0);
+$graph->SetBox();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("Example with added texts");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Set table title
+$graph->scale->tableTitle->Set("(Rev: 1.22)");
+$graph->scale->tableTitle->SetFont(FF_FONT1,FS_BOLD);
+$graph->scale->SetTableTitleBackground("silver");
+
+// Modify the appearance of the dividing lines
+$graph->scale->divider->SetWeight(3);
+$graph->scale->divider->SetColor("navy");
+$graph->scale->dividerh->SetWeight(3);
+$graph->scale->dividerh->SetColor("navy");
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR2);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// 0 % vertical label margin
+$graph->SetLabelVMarginFactor(1);
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-01-07","[50%]");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Set absolute height
+$activity->SetHeight(10);
+
+// Specify progress to 60%
+$activity->progress->Set(0.6);
+$activity->progress->SetPattern(BAND_HVCROSS,"blue");
+
+// Format the bar for the second activity
+// ($row,$title,$startdate,$enddate)
+$activity2 = new GanttBar(1,"Project","2001-12-21","2001-12-27","[30%]");
+
+// Yellow diagonal line pattern on a red background
+$activity2->SetPattern(BAND_RDIAG,"yellow");
+$activity2->SetFillColor("red");
+
+// Set absolute height
+$activity2->SetHeight(10);
+
+// Specify progress to 30%
+$activity2->progress->Set(0.3);
+$activity2->progress->SetPattern(BAND_HVCROSS,"blue");
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+$graph->Add($activity2);
+
+// Add text to top left corner of graph
+$txt1 = new Text();
+$txt1->SetPos(5,2);
+$txt1->Set("Note:\nEstimate done w148");
+$txt1->SetFont(FF_ARIAL,FS_BOLD,12);
+$txt1->SetColor('darkred');
+$graph->Add($txt1);
+
+// Add text to the top bar
+$txt2 = new Text();
+$txt2->SetScalePos("2002-01-01",1);
+$txt2->SetFont(FF_ARIAL,FS_BOLD,12);
+$txt2->SetAlign('left','center');
+$txt2->Set("Remember this!");
+$txt2->SetBox('yellow');
+$graph->Add($txt2);
+
+
+// Add a vertical line
+$vline = new GanttVLine("2001-12-24","Phase 1");
+$vline->SetDayOffset(0.5);
+//$graph->Add($vline);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttcolumnfontsex01.php b/web/classes/jpgraph/Examples/ganttcolumnfontsex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..a371f875463b05acd36bb75c0da72157f6adfb55
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttcolumnfontsex01.php
@@ -0,0 +1,68 @@
+<?php // content="text/plain; charset=utf-8"
+
+// Gantt column font array example
+
+require_once ('../jpgraph.php');
+require_once ('../jpgraph_gantt.php');
+
+// Setup a basic Gantt graph
+$graph = new GanttGraph();
+$graph->SetMarginColor('gray:1.7');
+$graph->SetColor('white');
+
+// Setup the graph title and title font
+$graph->title->Set("Example of column fonts");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,14);
+
+// Show three headers
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HMONTH| GANTT_HYEAR);
+
+// Set the column headers and font
+$graph->scale->actinfo->SetColTitles( array('Name','Start','End'),array(100));
+$graph->scale->actinfo->SetFont(FF_ARIAL,FS_BOLD,11);
+
+// Some "dummy" data to be dsiplayed
+$data = array(
+    array(0,'Group 1', '2001-11-27','2001-12-05'),
+    array(1,'  Activity 1', '2001-11-27','2001-11-29'),
+    array(2,'  Activity 2', '2001-11-28','2001-12-05'),
+    array(3,'Group 2', '2001-11-29','2001-12-10'),
+    array(4,'  Activity 1', '2001-11-29','2001-12-03'),
+    array(5,'  Activity 2', '2001-12-01','2001-12-10'),
+
+);
+
+// Format and add the Gantt bars to the chart
+$n = count($data);
+for($i=0; $i < $n; ++$i) {
+    if( $i === 0 || $i === 3 ) {
+        // Format the group bars
+        $bar = new GanttBar($data[$i][0],array($data[$i][1],$data[$i][2],$data[$i][3]),$data[$i][2],$data[$i][3],'',0.35);
+
+        // For each group make the name bold but keep the dates as the default font
+        $bar->title->SetColumnFonts(array(array(FF_ARIAL,FS_BOLD,11)));
+
+        // Add group markers
+        $bar->leftMark->SetType( MARK_LEFTTRIANGLE );
+        $bar->leftMark->Show();
+        $bar->rightMark->SetType( MARK_RIGHTTRIANGLE );
+        $bar->rightMark->Show();
+        $bar->SetFillColor('black');
+        $bar->SetPattern(BAND_SOLID,'black');
+    }
+    else {
+        // Format the activity bars
+        $bar = new GanttBar($data[$i][0],array($data[$i][1],$data[$i][2],$data[$i][3]),$data[$i][2],$data[$i][3],'',0.45);
+        $bar->SetPattern(BAND_RDIAG,'black');
+        $bar->SetFillColor('orange');
+    }
+    // Default font
+    $bar->title->SetFont(FF_ARIAL,FS_NORMAL,10);
+	$graph->Add($bar);
+}
+
+// Send back the graph to the client
+$graph->Stroke();
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/ganttconstrainex0.php b/web/classes/jpgraph/Examples/ganttconstrainex0.php
new file mode 100755
index 0000000000000000000000000000000000000000..8f5b72a12b75adab6e6adb423f2002180466fc39
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttconstrainex0.php
@@ -0,0 +1,38 @@
+<?php // content="text/plain; charset=utf-8"
+// Gantt example
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+// 
+// The data for the graphs
+//
+$data = array(
+  array(0,ACTYPE_GROUP,    "Phase 1",        "2001-10-26","2001-11-23",''),
+  array(1,ACTYPE_NORMAL,   "  Label 2",      "2001-10-26","2001-11-16",''),
+  array(2,ACTYPE_NORMAL,   "  Label 3",      "2001-11-20","2001-11-22",''),
+  array(3,ACTYPE_MILESTONE,"  Phase 1 Done", "2001-11-23",'M2') );
+
+// The constrains between the activities
+//$constrains = array(array(1,2,CONSTRAIN_ENDSTART),
+//		    array(2,3,CONSTRAIN_STARTSTART));
+$constrains = array();
+
+$progress = array(array(1,0.4));
+
+// Create the basic graph
+$graph = new GanttGraph();
+$graph->title->Set("Example with grouping and constrains");
+
+// Setup scale
+$graph->ShowHeaders(GANTT_HYEAR | GANTT_HMONTH | GANTT_HDAY | GANTT_HWEEK);
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAYWNBR);
+
+// Add the specified activities
+$graph->CreateSimple($data,$constrains,$progress);
+
+// .. and stroke the graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/ganttconstrainex1.php b/web/classes/jpgraph/Examples/ganttconstrainex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..7e9a3c1f501e9f360cb61dbea06da8c5e6caf92e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttconstrainex1.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+// Gantt example
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+//
+// The data for the graphs
+//
+$data = array(
+  array(0,ACTYPE_GROUP,    "Phase 1",        "2001-10-26","2001-11-23",''),
+  array(1,ACTYPE_NORMAL,   "  Label 2",      "2001-10-26","2001-11-16",''),
+  array(2,ACTYPE_NORMAL,   "  Label 3",      "2001-11-20","2001-11-22",''),
+  array(3,ACTYPE_NORMAL,   "  Label 4",      "2001-11-20","2001-11-22",''),
+  array(4,ACTYPE_MILESTONE,"  Phase 1 Done", "2001-11-23",'M2') );
+
+// The constrains between the activities
+$constrains = array(array(1,2,CONSTRAIN_ENDEND),
+		    array(2,3,CONSTRAIN_STARTEND),
+		    array(3,4,CONSTRAIN_ENDSTART),
+		    );
+
+$progress = array(array(1,0.4));
+
+// Create the basic graph
+$graph = new GanttGraph();
+$graph->title->Set("Example with grouping and constrains");
+
+// Setup scale
+$graph->ShowHeaders(GANTT_HYEAR | GANTT_HMONTH | GANTT_HDAY | GANTT_HWEEK);
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAYWNBR);
+
+// Add the specified activities
+$graph->CreateSimple($data,$constrains,$progress);
+
+// .. and stroke the graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/ganttconstrainex2.php b/web/classes/jpgraph/Examples/ganttconstrainex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..1e6bbbab142bf2e77f426ae911d67926be4a7b27
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttconstrainex2.php
@@ -0,0 +1,39 @@
+<?php // content="text/plain; charset=utf-8"
+// Gantt example
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+
+// 
+// The data for the graphs
+//
+$data = array(
+    array(0,ACTYPE_GROUP,    "Phase 1",        "2001-10-26","2001-11-23",''),
+    array(1,ACTYPE_NORMAL,   "  Label 2",      "2001-11-01","2001-11-20",''),
+    array(2,ACTYPE_NORMAL,   "  Label 3",      "2001-10-26","2001-11-03",''),
+    array(3,ACTYPE_MILESTONE,"  Phase 1 Done", "2001-11-23",'M2') );
+
+// The constrains between the activities
+$constrains = array(array(2,1,CONSTRAIN_ENDSTART),
+		    array(1,3,CONSTRAIN_STARTSTART));
+
+$progress = array(array(1,0.4));
+
+// Create the basic graph
+$graph = new GanttGraph();
+$graph->title->Set("Example with grouping and constrains");
+//$graph->SetFrame(false);
+
+// Setup scale
+$graph->ShowHeaders(GANTT_HYEAR | GANTT_HMONTH | GANTT_HDAY | GANTT_HWEEK);
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAYWNBR);
+
+// Add the specified activities
+$graph->CreateSimple($data,$constrains,$progress);
+
+// .. and stroke the graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/ganttcsimex01.php b/web/classes/jpgraph/Examples/ganttcsimex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..997d34731429881e23530835566975c582c8444d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttcsimex01.php
@@ -0,0 +1,28 @@
+<?php // content="text/plain; charset=utf-8"
+// Gantt example to create CSIM
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$bar1 = new GanttBar(0,"Activity 1","2001-12-21","2002-01-20");
+$bar1->SetCSIMTarget('#','Go back 1');
+$bar1->title->SetCSIMTarget('#','Go back 1 (title)');
+$bar2 = new GanttBar(1,"Activity 2","2002-01-03","2002-01-25");
+$bar2->SetCSIMTarget('#','Go back 2');
+$bar2->title->SetCSIMTarget('#','Go back 2 (title)');
+
+$graph = new GanttGraph(500);
+$graph->title->Set("Example with image map");
+$graph->ShowHeaders(GANTT_HYEAR | GANTT_HMONTH | GANTT_HDAY | GANTT_HWEEK);
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+$graph->scale->week->SetFont(FF_FONT1);
+
+$graph->Add(array($bar1,$bar2));
+
+// And stroke
+$graph->StrokeCSIM();
+
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/ganttcsimex02.php b/web/classes/jpgraph/Examples/ganttcsimex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..b9dd4c66f3920ffe300791b7b74dbbd8efb6d7eb
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttcsimex02.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+// Gantt example to create CSIM using CreateSimple()
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$data = array(
+  array(0,ACTYPE_GROUP,    "Phase 1",        "2001-10-26","2001-11-23",'',
+	'#1','Go home'),
+  array(1,ACTYPE_NORMAL,   "  Label 2",      "2001-10-26","2001-11-16",'ab,cd',
+	'#2','Go home'),
+  array(2,ACTYPE_NORMAL,   "  Label 3",      "2001-11-20","2001-11-22",'ek',
+	'#3','Go home'),
+  array(3,ACTYPE_MILESTONE,"  Phase 1 Done", "2001-11-23",'M2',
+	'#4','Go home') );
+
+// The constrains between the activities
+$constrains = array(array(1,2,CONSTRAIN_ENDSTART),
+		    array(2,3,CONSTRAIN_STARTSTART));
+
+$progress = array(array(1,0.4));
+
+$graph = new GanttGraph(500);
+$graph->title->Set("Example with image map");
+$graph->ShowHeaders(GANTT_HYEAR | GANTT_HMONTH | GANTT_HDAY | GANTT_HWEEK);
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+$graph->scale->week->SetFont(FF_FONT1);
+
+$graph->CreateSimple($data,$constrains,$progress);
+
+// Add the specified activities
+//SetupSimpleGantt($graph,$data,$constrains,$progress);
+
+// And stroke
+$graph->StrokeCSIM();
+
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/ganttex00.php b/web/classes/jpgraph/Examples/ganttex00.php
new file mode 100755
index 0000000000000000000000000000000000000000..618b7f9dc85ac30c6d49abb762db723228a8f35f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex00.php
@@ -0,0 +1,14 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+// A new graph with automatic size
+$graph = new GanttGraph();
+
+//  A new activity on row '0'
+$activity = new GanttBar(0,"Activity 1","2001-12-21","2002-01-19");
+$graph->Add($activity);
+
+// Display the Gantt chart
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex01.php b/web/classes/jpgraph/Examples/ganttex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..b3b9d5359d38b72dcaff9db481dc5e8cf51ff179
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex01.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set('A main title');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set('(Draft version)');
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR2);
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,'Activity 1','2001-12-21','2002-01-18');
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_LDIAG,'yellow');
+$activity->SetFillColor('red');
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex02.php b/web/classes/jpgraph/Examples/ganttex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..2ac42ed7ba09eb9656f1cf0a26608b5fcde391c9
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex02.php
@@ -0,0 +1,42 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph(0,0);
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("Main title");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+// Show day, week and month scale
+//$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+$graph->ShowHeaders(GANTT_HWEEK );
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_WNBR);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR4);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-02-20");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex03.php b/web/classes/jpgraph/Examples/ganttex03.php
new file mode 100755
index 0000000000000000000000000000000000000000..de528a53e29587f71c33990d5eda822bdc1c4f4a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex03.php
@@ -0,0 +1,42 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph(0,0);
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("A nice main title");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(Draft version)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR4);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(7,"Project","2001-12-21","2002-02-20");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex04.php b/web/classes/jpgraph/Examples/ganttex04.php
new file mode 100755
index 0000000000000000000000000000000000000000..c9ea4cb92499e4c9bf5db7bd9fc4d90c2a28e018
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex04.php
@@ -0,0 +1,47 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("A nice main title");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(Draft version)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR4);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-01-20");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+
+// Create a miletone
+$milestone = new MileStone(2,"Milestone",'2002-01-09','MS5');
+$milestone->caption->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->Add($milestone);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex05.php b/web/classes/jpgraph/Examples/ganttex05.php
new file mode 100755
index 0000000000000000000000000000000000000000..6c0ef36c1b70a4dabaff3273d6021259f8d2432e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex05.php
@@ -0,0 +1,48 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("A nice main title");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(Draft version)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR4);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-02-20");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+
+// Create a miletone
+$milestone = new MileStone(2,"Milestone","2002-01-15","2002-01-15");
+$milestone->title->SetColor("black");
+$milestone->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->Add($milestone);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex06.php b/web/classes/jpgraph/Examples/ganttex06.php
new file mode 100755
index 0000000000000000000000000000000000000000..8cf4dbb347e5cabe0d14cab418d343b3b7a883ce
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex06.php
@@ -0,0 +1,52 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("A nice main title");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(Draft version)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR4);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-02-20");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+
+// Create a miletone
+$milestone = new MileStone(2,"Milestone","2002-01-15","2002-01-15");
+$milestone->title->SetColor("black");
+$milestone->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->Add($milestone);
+
+// Add a vertical line
+$vline = new GanttVLine("2001-12-24","Phase 1");
+$graph->Add($vline);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex07.php b/web/classes/jpgraph/Examples/ganttex07.php
new file mode 100755
index 0000000000000000000000000000000000000000..b1eb27aa5491d4908e3a9d1ae7ddefd24bf293ba
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex07.php
@@ -0,0 +1,53 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("A nice main title");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(Draft version)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR4);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-02-20");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+
+// Create a miletone
+$milestone = new MileStone(2,"Milestone","2002-01-15","2002-01-15");
+$milestone->title->SetColor("black");
+$milestone->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->Add($milestone);
+
+// Add a vertical line
+$vline = new GanttVLine("2001-12-24","Phase 1");
+$vline->SetDayOffset(0.5);
+$graph->Add($vline);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex08.php b/web/classes/jpgraph/Examples/ganttex08.php
new file mode 100755
index 0000000000000000000000000000000000000000..62d8947c77da61a275cd65d63be92cd9f9c13cd5
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex08.php
@@ -0,0 +1,63 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("A nice main title");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(Draft version)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR4);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-01-15");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Add a right marker
+$activity->rightMark->Show();
+$activity->rightMark->SetType(MARK_FILLEDCIRCLE);
+$activity->rightMark->SetWidth(13);
+$activity->rightMark->SetColor("red");
+$activity->rightMark->SetFillColor("red");
+$activity->rightMark->title->Set("M5");
+$activity->rightMark->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$activity->rightMark->title->SetColor("white");
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+
+// Create a miletone
+$milestone = new MileStone(2,"Milestone","2002-01-10","2002-01-10");
+$milestone->title->SetColor("black");
+$milestone->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->Add($milestone);
+
+// Add a vertical line
+$vline = new GanttVLine("2001-12-24","Phase 1");
+$vline->SetDayOffset(0.5);
+$graph->Add($vline);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex09.php b/web/classes/jpgraph/Examples/ganttex09.php
new file mode 100755
index 0000000000000000000000000000000000000000..f5fff1a12761fb0324611ea1b7e3884c496b7d30
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex09.php
@@ -0,0 +1,66 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("A nice main title");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(Draft version)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR4);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-02-20");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Add a right marker
+$activity->rightMark->Show();
+$activity->rightMark->SetType(MARK_FILLEDCIRCLE);
+$activity->rightMark->SetWidth(13);
+$activity->rightMark->SetColor("red");
+$activity->rightMark->SetFillColor("red");
+$activity->rightMark->title->Set("M5");
+$activity->rightMark->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$activity->rightMark->title->SetColor("white");
+
+// Set absolute height
+$activity->SetHeight(8);
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+
+// Create a miletone
+$milestone = new MileStone(2,"Milestone","2002-01-15","2002-01-15");
+$milestone->title->SetColor("black");
+$milestone->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->Add($milestone);
+
+// Add a vertical line
+$vline = new GanttVLine("2001-12-24","Phase 1");
+$vline->SetDayOffset(0.5);
+$graph->Add($vline);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex10.php b/web/classes/jpgraph/Examples/ganttex10.php
new file mode 100755
index 0000000000000000000000000000000000000000..459920cfb9d0af7f6768cb1c49f2bda17932531d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex10.php
@@ -0,0 +1,90 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("A nice main title");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(Draft version)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR4);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-02-20");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Add a right marker
+$activity->rightMark->Show();
+$activity->rightMark->SetType(MARK_FILLEDCIRCLE);
+$activity->rightMark->SetWidth(13);
+$activity->rightMark->SetColor("red");
+$activity->rightMark->SetFillColor("red");
+$activity->rightMark->title->Set("M5");
+$activity->rightMark->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$activity->rightMark->title->SetColor("white");
+
+// Set absolute height
+$activity->SetHeight(1);
+
+
+// Format the bar for the second activity
+// ($row,$title,$startdate,$enddate)
+$activity2 = new GanttBar(1,"Project","2001-12-21","2002-02-20");
+
+// Yellow diagonal line pattern on a red background
+$activity2->SetPattern(BAND_RDIAG,"yellow");
+$activity2->SetFillColor("red");
+
+// Add a right marker
+$activity2->rightMark->Show();
+$activity2->rightMark->SetType(MARK_FILLEDCIRCLE);
+$activity2->rightMark->SetWidth(13);
+$activity2->rightMark->SetColor("red");
+$activity2->rightMark->SetFillColor("red");
+$activity2->rightMark->title->Set("M5");
+$activity2->rightMark->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$activity2->rightMark->title->SetColor("white");
+
+// Set absolute height
+$activity2->SetHeight(1);
+
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+$graph->Add($activity2);
+
+// Create a miletone
+$milestone = new MileStone(2,"Milestone","2002-01-15","2002-01-15");
+$milestone->title->SetColor("black");
+$milestone->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->Add($milestone);
+
+// Add a vertical line
+$vline = new GanttVLine("2001-12-24","Phase 1");
+$vline->SetDayOffset(0.5);
+//$graph->Add($vline);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex11.php b/web/classes/jpgraph/Examples/ganttex11.php
new file mode 100755
index 0000000000000000000000000000000000000000..2fec58bb982d2afcd66c20ee0745b4dd5b6a3038
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex11.php
@@ -0,0 +1,89 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("A nice main title");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(Draft version)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR4);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-02-20");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Add a right marker
+$activity->rightMark->Show();
+$activity->rightMark->SetType(MARK_FILLEDCIRCLE);
+$activity->rightMark->SetWidth(13);
+$activity->rightMark->SetColor("red");
+$activity->rightMark->SetFillColor("red");
+$activity->rightMark->title->Set("M5");
+$activity->rightMark->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$activity->rightMark->title->SetColor("white");
+
+// Set absolute height
+$activity->SetHeight(10);
+
+
+// Format the bar for the second activity
+// ($row,$title,$startdate,$enddate)
+$activity2 = new GanttBar(1,"Project","2001-12-21","2002-02-20");
+
+// Yellow diagonal line pattern on a red background
+$activity2->SetPattern(BAND_RDIAG,"yellow");
+$activity2->SetFillColor("red");
+
+// Add a right marker
+$activity2->rightMark->Show();
+$activity2->rightMark->SetType(MARK_FILLEDCIRCLE);
+$activity2->rightMark->SetWidth(13);
+$activity2->rightMark->SetColor("red");
+$activity2->rightMark->SetFillColor("red");
+$activity2->rightMark->title->Set("M5");
+$activity2->rightMark->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$activity2->rightMark->title->SetColor("white");
+
+// Set absolute height
+$activity2->SetHeight(10);
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+$graph->Add($activity2);
+
+// Create a miletone
+$milestone = new MileStone(2,"Milestone","2002-01-15","2002-01-15");
+$milestone->title->SetColor("black");
+$milestone->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->Add($milestone);
+
+// Add a vertical line
+$vline = new GanttVLine("2001-12-24","Phase 1");
+$vline->SetDayOffset(0.5);
+//$graph->Add($vline);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex12.php b/web/classes/jpgraph/Examples/ganttex12.php
new file mode 100755
index 0000000000000000000000000000000000000000..e7adc7a9e44be0108cb8ddfe5494e4cd69c85e00
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex12.php
@@ -0,0 +1,93 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetBox();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("A nice main title");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(Draft version)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR4);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// 0 % vertical label margin
+$graph->SetLabelVMarginFactor(0);
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-02-20");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Add a right marker
+$activity->rightMark->Show();
+$activity->rightMark->SetType(MARK_FILLEDCIRCLE);
+$activity->rightMark->SetWidth(13);
+$activity->rightMark->SetColor("red");
+$activity->rightMark->SetFillColor("red");
+$activity->rightMark->title->Set("M5");
+$activity->rightMark->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$activity->rightMark->title->SetColor("white");
+
+// Set absolute height
+$activity->SetHeight(10);
+
+
+// Format the bar for the second activity
+// ($row,$title,$startdate,$enddate)
+$activity2 = new GanttBar(1,"Project","2001-12-21","2002-02-20");
+
+// Yellow diagonal line pattern on a red background
+$activity2->SetPattern(BAND_RDIAG,"yellow");
+$activity2->SetFillColor("red");
+
+// Add a right marker
+$activity2->rightMark->Show();
+$activity2->rightMark->SetType(MARK_FILLEDCIRCLE);
+$activity2->rightMark->SetWidth(13);
+$activity2->rightMark->SetColor("red");
+$activity2->rightMark->SetFillColor("red");
+$activity2->rightMark->title->Set("M5");
+$activity2->rightMark->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$activity2->rightMark->title->SetColor("white");
+
+// Set absolute height
+$activity2->SetHeight(10);
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+$graph->Add($activity2);
+
+// Create a miletone
+$milestone = new MileStone(2,"Milestone","2002-01-15","2002-01-15");
+$milestone->title->SetColor("black");
+$milestone->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->Add($milestone);
+
+// Add a vertical line
+$vline = new GanttVLine("2001-12-24","Phase 1");
+$vline->SetDayOffset(0.5);
+//$graph->Add($vline);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex13-zoom1.php b/web/classes/jpgraph/Examples/ganttex13-zoom1.php
new file mode 100755
index 0000000000000000000000000000000000000000..9a8457e681dc67cf6b1789579e38d7eafb30410f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex13-zoom1.php
@@ -0,0 +1,67 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("Zooming a graph");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(zoom=0.7)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR4);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// 0 % vertical label margin
+$graph->SetLabelVMarginFactor(1.0); // 1=default value
+
+// Set zoom factor
+$graph->SetZoomFactor(0.7);
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity1 = new GanttBar(0,"Activity 1","2001-12-21","2002-01-07","[ER,TR]");
+
+// Yellow diagonal line pattern on a red background
+$activity1->SetPattern(BAND_RDIAG,"yellow");
+$activity1->SetFillColor("red");
+
+// Set absolute height of activity
+$activity1->SetHeight(16);
+
+// Format the bar for the second activity
+// ($row,$title,$startdate,$enddate)
+$activity2 = new GanttBar(1,"Activity 2","2001-12-21","2002-01-01","[BO,SW,JC]");
+
+// ADjust font for caption
+$activity2->caption->SetFont(FF_ARIAL,FS_BOLD);
+$activity2->caption->SetColor("darkred");
+
+// Yellow diagonal line pattern on a red background
+$activity2->SetPattern(BAND_RDIAG,"yellow");
+$activity2->SetFillColor("red");
+
+// Set absolute height of activity
+$activity2->SetHeight(16);
+
+// Finally add the bar to the graph
+$graph->Add($activity1);
+$graph->Add($activity2);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex13-zoom2.php b/web/classes/jpgraph/Examples/ganttex13-zoom2.php
new file mode 100755
index 0000000000000000000000000000000000000000..882fb7bc78d147098be41e69bde921a3220af7e7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex13-zoom2.php
@@ -0,0 +1,67 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("Zooming a graph");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(zoom=1.5)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR4);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// 0 % vertical label margin
+$graph->SetLabelVMarginFactor(1.0); // 1=default value
+
+// Set zoom factor
+$graph->SetZoomFactor(1.5);
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity1 = new GanttBar(0,"Activity 1","2001-12-21","2002-01-07","[ER,TR]");
+
+// Yellow diagonal line pattern on a red background
+$activity1->SetPattern(BAND_RDIAG,"yellow");
+$activity1->SetFillColor("red");
+
+// Set absolute height of activity
+$activity1->SetHeight(16);
+
+// Format the bar for the second activity
+// ($row,$title,$startdate,$enddate)
+$activity2 = new GanttBar(1,"Activity 2","2001-12-21","2002-01-01","[BO,SW,JC]");
+
+// ADjust font for caption
+$activity2->caption->SetFont(FF_ARIAL,FS_BOLD);
+$activity2->caption->SetColor("darkred");
+
+// Yellow diagonal line pattern on a red background
+$activity2->SetPattern(BAND_RDIAG,"yellow");
+$activity2->SetFillColor("red");
+
+// Set absolute height of activity
+$activity2->SetHeight(16);
+
+// Finally add the bar to the graph
+$graph->Add($activity1);
+$graph->Add($activity2);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex13.php b/web/classes/jpgraph/Examples/ganttex13.php
new file mode 100755
index 0000000000000000000000000000000000000000..865a4db0abd0eae692aa775b46542889e6e1b313
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex13.php
@@ -0,0 +1,64 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("Example of captions");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(ganttex13.php)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Instead of week number show the date for the first day in the week
+// on the week scale
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Make the week scale font smaller than the default
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR4);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// 0 % vertical label margin
+$graph->SetLabelVMarginFactor(1); // 1=default value
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity1 = new GanttBar(0,"Activity 1","2001-12-21","2002-01-07","[ER,TR]");
+
+// Yellow diagonal line pattern on a red background
+$activity1->SetPattern(BAND_RDIAG,"yellow");
+$activity1->SetFillColor("red");
+
+// Set absolute height of activity
+$activity1->SetHeight(16);
+
+// Format the bar for the second activity
+// ($row,$title,$startdate,$enddate)
+$activity2 = new GanttBar(1,"Activity 2","2001-12-21","2002-01-01","[BO,SW,JC]");
+
+// ADjust font for caption
+$activity2->caption->SetFont(FF_ARIAL,FS_BOLD);
+$activity2->caption->SetColor("darkred");
+
+// Yellow diagonal line pattern on a red background
+$activity2->SetPattern(BAND_RDIAG,"yellow");
+$activity2->SetFillColor("red");
+
+// Set absolute height of activity
+$activity2->SetHeight(16);
+
+// Finally add the bar to the graph
+$graph->Add($activity1);
+$graph->Add($activity2);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex14.php b/web/classes/jpgraph/Examples/ganttex14.php
new file mode 100755
index 0000000000000000000000000000000000000000..a53942ba55b9d270335e3a59c5614c15b3274289
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex14.php
@@ -0,0 +1,67 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetBox();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("Example of captions");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(ganttex14.php)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR2);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// 0 % vertical label margin
+$graph->SetLabelVMarginFactor(1);
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-01-07","[50%]");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Set absolute height
+$activity->SetHeight(10);
+
+// Specify progress to 60%
+$activity->progress->Set(0.6);
+
+// Format the bar for the second activity
+// ($row,$title,$startdate,$enddate)
+$activity2 = new GanttBar(1,"Project","2001-12-21","2002-01-02","[30%]");
+
+// Yellow diagonal line pattern on a red background
+$activity2->SetPattern(BAND_RDIAG,"yellow");
+$activity2->SetFillColor("red");
+
+// Set absolute height
+$activity2->SetHeight(10);
+
+// Specify progress to 30%
+$activity2->progress->Set(0.3);
+
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+$graph->Add($activity2);
+
+// Add a vertical line
+$vline = new GanttVLine("2001-12-24","Phase 1");
+$vline->SetDayOffset(0.5);
+//$graph->Add($vline);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex15.php b/web/classes/jpgraph/Examples/ganttex15.php
new file mode 100755
index 0000000000000000000000000000000000000000..ae7598392cd158234a850a275e5c21d08320460c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex15.php
@@ -0,0 +1,68 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetBox();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("Example of captions");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(ganttex15.php)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR2);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// 0 % vertical label margin
+$graph->SetLabelVMarginFactor(1);
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-01-07","[50%]");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Set absolute height
+$activity->SetHeight(10);
+
+// Specify progress to 60%
+$activity->progress->Set(0.6);
+$activity->progress->SetPattern(BAND_HVCROSS,"blue");
+
+// Format the bar for the second activity
+// ($row,$title,$startdate,$enddate)
+$activity2 = new GanttBar(1,"Project","2001-12-21","2002-01-02","[30%]");
+
+// Yellow diagonal line pattern on a red background
+$activity2->SetPattern(BAND_RDIAG,"yellow");
+$activity2->SetFillColor("red");
+
+// Set absolute height
+$activity2->SetHeight(10);
+
+// Specify progress to 30%
+$activity2->progress->Set(0.3);
+$activity2->progress->SetPattern(BAND_HVCROSS,"blue");
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+$graph->Add($activity2);
+
+// Add a vertical line
+$vline = new GanttVLine("2001-12-24","Phase 1");
+$vline->SetDayOffset(0.5);
+//$graph->Add($vline);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex16.php b/web/classes/jpgraph/Examples/ganttex16.php
new file mode 100755
index 0000000000000000000000000000000000000000..bf3e06fae151d991ee292fd2098c59298699d1af
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex16.php
@@ -0,0 +1,73 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetBox();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("Example of captions");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(ganttex16.php)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Set table title
+$graph->scale->tableTitle->Set("(Rev: 1.22)");
+$graph->scale->tableTitle->SetFont(FF_FONT1,FS_BOLD);
+$graph->scale->SetTableTitleBackground("silver");
+$graph->scale->tableTitle->Show();
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR2);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// 0 % vertical label margin
+$graph->SetLabelVMarginFactor(1);
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-01-07","[50%]");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Set absolute height
+$activity->SetHeight(10);
+
+// Specify progress to 60%
+$activity->progress->Set(0.6);
+$activity->progress->SetPattern(BAND_HVCROSS,"blue");
+
+// Format the bar for the second activity
+// ($row,$title,$startdate,$enddate)
+$activity2 = new GanttBar(1,"Project","2001-12-21","2002-01-02","[30%]");
+
+// Yellow diagonal line pattern on a red background
+$activity2->SetPattern(BAND_RDIAG,"yellow");
+$activity2->SetFillColor("red");
+
+// Set absolute height
+$activity2->SetHeight(10);
+
+// Specify progress to 30%
+$activity2->progress->Set(0.3);
+$activity2->progress->SetPattern(BAND_HVCROSS,"blue");
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+$graph->Add($activity2);
+
+// Add a vertical line
+$vline = new GanttVLine("2001-12-24","Phase 1");
+$vline->SetDayOffset(0.5);
+//$graph->Add($vline);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex17-flag.php b/web/classes/jpgraph/Examples/ganttex17-flag.php
new file mode 100755
index 0000000000000000000000000000000000000000..17eaca491fbc4a29953d150d0ac28179cdb2754f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex17-flag.php
@@ -0,0 +1,88 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+require_once ('jpgraph/jpgraph_flags.php');
+
+$graph = new GanttGraph();
+$graph->SetBox();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("Example of captions");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(ganttex17.php)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Set table title
+$graph->scale->tableTitle->Set("(Rev: 1.22)");
+$graph->scale->tableTitle->SetFont(FF_FONT1,FS_BOLD);
+$graph->scale->SetTableTitleBackground("silver");
+
+// Modify the appearance of the dividing lines
+$graph->scale->divider->SetWeight(3);
+$graph->scale->divider->SetColor("navy");
+$graph->scale->dividerh->SetWeight(3);
+$graph->scale->dividerh->SetColor("navy");
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR2);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// 0 % vertical label margin
+$graph->SetLabelVMarginFactor(1);
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-01-07","[50%]");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Set absolute height
+$activity->SetHeight(10);
+
+// Specify progress to 60%
+$activity->progress->Set(0.6);
+$activity->progress->SetPattern(BAND_HVCROSS,"blue");
+
+// Format the bar for the second activity
+// ($row,$title,$startdate,$enddate)
+$activity2 = new GanttBar(1,"Project","2001-12-21","2002-01-02","[30%]");
+
+// Yellow diagonal line pattern on a red background
+$activity2->SetPattern(BAND_RDIAG,"yellow");
+$activity2->SetFillColor("red");
+
+// Set absolute height
+$activity2->SetHeight(10);
+
+// Specify progress to 30%
+$activity2->progress->Set(0.3);
+$activity2->progress->SetPattern(BAND_HVCROSS,"blue");
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+$graph->Add($activity2);
+
+// Add a coutnry flag
+$icon = new IconPlot();
+$icon->SetAnchor('left','top');
+$icon->SetCountryFlag('norway');
+$icon->SetMix(50);
+$icon->SetPos(5,5);
+$graph->Add($icon);
+
+
+// Add a vertical line
+$vline = new GanttVLine("2001-12-24","Phase 1");
+$vline->SetDayOffset(0.5);
+//$graph->Add($vline);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex17.php b/web/classes/jpgraph/Examples/ganttex17.php
new file mode 100755
index 0000000000000000000000000000000000000000..cc2e7e89499e002bac6dd1cccfdf1d21a41555bd
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex17.php
@@ -0,0 +1,78 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph(0,0);
+$graph->SetBox();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("Example of captions");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(ganttex17.php)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Set table title
+$graph->scale->tableTitle->Set("(Rev: 1.22)");
+$graph->scale->tableTitle->SetFont(FF_FONT1,FS_BOLD);
+$graph->scale->SetTableTitleBackground("silver");
+
+// Modify the appearance of the dividing lines
+$graph->scale->divider->SetWeight(3);
+$graph->scale->divider->SetColor("navy");
+$graph->scale->dividerh->SetWeight(3);
+$graph->scale->dividerh->SetColor("navy");
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR2);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// 0 % vertical label margin
+$graph->SetLabelVMarginFactor(1);
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-01-07","[50%]");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Set absolute height
+$activity->SetHeight(10);
+
+// Specify progress to 60%
+$activity->progress->Set(0.6);
+$activity->progress->SetPattern(BAND_HVCROSS,"blue");
+
+// Format the bar for the second activity
+// ($row,$title,$startdate,$enddate)
+$activity2 = new GanttBar(1,"Project","2001-12-21","2002-01-02","[30%]");
+
+// Yellow diagonal line pattern on a red background
+$activity2->SetPattern(BAND_RDIAG,"yellow");
+$activity2->SetFillColor("red");
+
+// Set absolute height
+$activity2->SetHeight(10);
+
+// Specify progress to 30%
+$activity2->progress->Set(0.3);
+$activity2->progress->SetPattern(BAND_HVCROSS,"blue");
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+$graph->Add($activity2);
+
+// Add a vertical line
+$vline = new GanttVLine("2001-12-24","Phase 1");
+$vline->SetDayOffset(0.5);
+//$graph->Add($vline);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex18.php b/web/classes/jpgraph/Examples/ganttex18.php
new file mode 100755
index 0000000000000000000000000000000000000000..4c4b5d91feff3c283df57dfd79acf0b80f787763
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex18.php
@@ -0,0 +1,82 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetBox();
+$graph->SetShadow();
+
+// Add title and subtitle
+$graph->title->Set("Example of captions");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set("(ganttex18.php)");
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Set table title
+$graph->scale->tableTitle->Set("(Rev: 1.22)");
+$graph->scale->tableTitle->SetFont(FF_FONT1,FS_BOLD);
+$graph->scale->SetTableTitleBackground("silver");
+
+// Modify the appearance of the dividing lines
+$graph->scale->divider->SetWeight(3);
+$graph->scale->divider->SetColor("navy");
+
+$graph->scale->dividerh->SetWeight(3);
+$graph->scale->dividerh->SetColor("navy");
+
+$graph->SetBox(true,"navy",3);
+
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR2);
+$graph->scale->month->SetFontColor("white");
+$graph->scale->month->SetBackgroundColor("blue");
+
+// 0 % vertical label margin
+$graph->SetLabelVMarginFactor(1);
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,"Project","2001-12-21","2002-01-07","[50%]");
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,"yellow");
+$activity->SetFillColor("red");
+
+// Set absolute height
+$activity->SetHeight(10);
+
+// Specify progress to 60%
+$activity->progress->Set(0.6);
+$activity->progress->SetPattern(BAND_HVCROSS,"blue");
+
+// Format the bar for the second activity
+// ($row,$title,$startdate,$enddate)
+$activity2 = new GanttBar(1,"Project","2001-12-21","2002-01-02","[30%]");
+
+// Yellow diagonal line pattern on a red background
+$activity2->SetPattern(BAND_RDIAG,"yellow");
+$activity2->SetFillColor("red");
+
+// Set absolute height
+$activity2->SetHeight(10);
+
+// Specify progress to 30%
+$activity2->progress->Set(0.3);
+$activity2->progress->SetPattern(BAND_HVCROSS,"blue");
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+$graph->Add($activity2);
+
+// Add a vertical line
+$vline = new GanttVLine("2001-12-24","Phase 1");
+$vline->SetDayOffset(0.5);
+//$graph->Add($vline);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex19.php b/web/classes/jpgraph/Examples/ganttex19.php
new file mode 100755
index 0000000000000000000000000000000000000000..7528412ead3faf2db9a8921cd92cd2756773529c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex19.php
@@ -0,0 +1,84 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetBox();
+$graph->SetShadow();
+
+// Use default locale
+$graph->scale->SetDateLocale('sv_SE');
+
+// Add title and subtitle
+$graph->title->Set('Example of captions');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->subtitle->Set('(ganttex19.php)');
+
+// Show day, week and month scale
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HWEEK | GANTT_HMONTH);
+
+// Set table title
+$graph->scale->tableTitle->Set('(Rev: 1.22)');
+$graph->scale->tableTitle->SetFont(FF_FONT1,FS_BOLD);
+$graph->scale->SetTableTitleBackground('silver');
+$graph->scale->tableTitle->Show();
+
+$graph->scale->divider->SetStyle('solid');
+$graph->scale->divider->SetWeight(2);
+$graph->scale->divider->SetColor('black');
+
+
+$graph->SetBox(true,'navy',2);
+
+
+// Use the short name of the month together with a 2 digit year
+// on the month scale
+$graph->scale->month->SetStyle(MONTHSTYLE_SHORTNAMEYEAR2);
+$graph->scale->month->SetFontColor('white');
+$graph->scale->month->SetBackgroundColor('blue');
+
+// 0 % vertical label margin
+$graph->SetLabelVMarginFactor(1);
+
+// Format the bar for the first activity
+// ($row,$title,$startdate,$enddate)
+$activity = new GanttBar(0,'Project','2001-12-21','2002-01-07','[50%]');
+
+// Yellow diagonal line pattern on a red background
+$activity->SetPattern(BAND_RDIAG,'yellow');
+$activity->SetFillColor('red');
+
+// Set absolute height
+$activity->SetHeight(10);
+
+// Specify progress to 60%
+$activity->progress->Set(0.6);
+$activity->progress->SetPattern(BAND_HVCROSS,'blue');
+
+// Format the bar for the second activity
+// ($row,$title,$startdate,$enddate)
+$activity2 = new GanttBar(1,'Project','2001-12-21','2002-01-02','[30%]');
+
+// Yellow diagonal line pattern on a red background
+$activity2->SetPattern(BAND_RDIAG,'yellow');
+$activity2->SetFillColor('red');
+
+// Set absolute height
+$activity2->SetHeight(10);
+
+// Specify progress to 30%
+$activity2->progress->Set(0.3);
+$activity2->progress->SetPattern(BAND_HVCROSS,'blue');
+
+// Finally add the bar to the graph
+$graph->Add($activity);
+$graph->Add($activity2);
+
+// Add a vertical line
+$vline = new GanttVLine('2001-12-24','Phase 1');
+$vline->SetDayOffset(0.5);
+//$graph->Add($vline);
+
+// ... and display it
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex30.php b/web/classes/jpgraph/Examples/ganttex30.php
new file mode 100755
index 0000000000000000000000000000000000000000..45cc80b6467c56d2e801b553d40781d44f519693
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex30.php
@@ -0,0 +1,87 @@
+<?php // content="text/plain; charset=utf-8"
+// Gantt example 30
+// $Id: ganttex30.php,v 1.4 2003/05/30 20:12:43 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+// Standard calls to create a new graph
+$graph = new GanttGraph();
+$graph->SetShadow();
+$graph->SetBox();
+
+// Titles for chart
+$graph->title->Set("General conversion plan");
+$graph->subtitle->Set("(Revision: 2001-11-18)");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+// For illustration we enable all headers.
+$graph->ShowHeaders(GANTT_HYEAR | GANTT_HMONTH | GANTT_HDAY | GANTT_HWEEK);
+
+// For the week we choose to show the start date of the week
+// the default is to show week number (according to ISO 8601)
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Change the scale font
+$graph->scale->week->SetFont(FF_FONT0);
+$graph->scale->year->SetFont(FF_ARIAL,FS_BOLD,12);
+
+
+// Setup some data for the gantt bars
+$data = array(
+        array(0,"Group 1", "2001-10-29","2001-11-27",FF_FONT1,FS_BOLD,8),
+        array(1,"  Label 2", "2001-11-8","2001-12-14"),
+        array(2,"  Label 3", "2001-11-01","2001-11-8"),
+        array(4,"Group 2", "2001-11-07","2001-12-19",FF_FONT1,FS_BOLD,8),
+        array(5,"  Label 4", "2001-11-8","2001-12-19"),
+        array(6,"  Label 5", "2001-11-01","2001-11-8")
+        );
+
+for($i=0; $i<count($data); ++$i) {
+        $bar = new GanttBar($data[$i][0],$data[$i][1],$data[$i][2],$data[$i][3],"[50%]",0.5);
+        if( count($data[$i])>4 )
+                $bar->title->SetFont($data[$i][4],$data[$i][5],$data[$i][6]);
+
+        // If you like each bar can have a shadow
+        // $bar->SetShadow(true,"darkgray");
+
+        // For illustration lets make each bar be red with yellow diagonal stripes
+        $bar->SetPattern(BAND_RDIAG,"yellow");
+        $bar->SetFillColor("red");
+
+        // To indicate progress each bar can have a smaller bar within
+        // For illustrative purpose just set the progress to 50% for each bar
+        $bar->progress->Set(0.5);
+
+        // Each bar may also have optional left and right plot marks
+        // As illustration lets put a filled circle with a number at the end
+        // of each bar
+        $bar->rightMark->SetType(MARK_FILLEDCIRCLE);
+        $bar->rightMark->SetFillColor("red");
+        $bar->rightMark->SetColor("red");
+        $bar->rightMark->SetWidth(10);
+
+        // Title for the mark
+        $bar->rightMark->title->Set("".$i+1);
+        $bar->rightMark->title->SetColor("white");
+        $bar->rightMark->title->SetFont(FF_ARIAL,FS_BOLD,10);
+        $bar->rightMark->Show();
+
+        // ... and add the bar to the gantt chart
+        $graph->Add($bar);
+}
+
+// Create a milestone mark
+$ms = new MileStone(7,"M5","2001-12-10","10/12");
+$ms->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->Add($ms);
+
+// Create a vertical line to emphasize the milestone
+$vl = new GanttVLine("2001-12-10 13:00","Phase 1","darkred");
+$vl->SetDayOffset(0.5); // Center the line in the day
+$graph->Add($vl);
+
+// Output the graph
+$graph->Stroke();
+
+// EOF
+?>
diff --git a/web/classes/jpgraph/Examples/ganttex_slice.php b/web/classes/jpgraph/Examples/ganttex_slice.php
new file mode 100755
index 0000000000000000000000000000000000000000..5ec95bc96d64048052b52a98f52d42e27ef6d620
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttex_slice.php
@@ -0,0 +1,78 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: ganttex_slice.php,v 1.2 2002/07/11 23:27:28 aditus Exp $
+// Gantt example with sunday week start and only shows a partial graph
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+// Setup Gantt graph
+$graph = new GanttGraph(0,0,'auto');
+$graph->SetShadow();
+$graph->SetBox();
+
+// Only show part of the Gantt
+$graph->SetDateRange('2001-11-22','2002-1-24');
+
+// Weeks start on Sunday
+$graph->scale->SetWeekStart(0);
+
+$graph->title->Set("General conversion plan");
+$graph->subtitle->Set("(Slice between 2001-11-22 to 2002-01-24)");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,20);
+
+$graph->ShowHeaders(GANTT_HYEAR | GANTT_HMONTH | GANTT_HDAY | GANTT_HWEEK);
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+$graph->scale->week->SetFont(FF_FONT1);
+
+
+$data = array(
+	array(0,"Group 1\tJohan", "2002-1-23","2002-01-28",FF_FONT1,FS_BOLD,8),
+	array(1,"  Label 2", "2001-10-26","2001-11-16"),
+	array(2,"  Label 3", "2001-11-30","2001-12-01"),
+	array(4,"Group 2", "2001-11-30","2001-12-22",FF_FONT1,FS_BOLD,8),
+	array(5,"  Label 4", "2001-11-30","2001-12-1"),
+	array(6,"  Label 5", "2001-12-6","2001-12-8"),
+	array(8,"    Label 8", "2001-11-30","2002-01-02")			
+	);
+
+
+// make up some fictionary activity bars
+for($i=0; $i<count($data); ++$i) {
+	$bar = new GanttBar($data[$i][0],$data[$i][1],$data[$i][2],$data[$i][3],"[5%]",10);
+	if( count($data[$i])>4 )
+		$bar->title->SetFont($data[$i][4],$data[$i][5],$data[$i][6]);
+		
+	$bar->rightMark->Show();
+	$bar->rightMark->SetType(MARK_FILLEDCIRCLE);
+	$bar->rightMark->SetWidth(8);
+	$bar->rightMark->SetColor("red");
+	$bar->rightMark->SetFillColor("red");
+	$bar->rightMark->title->Set($i+1);
+	$bar->rightMark->title->SetFont(FF_ARIAL,FS_BOLD,12);
+	$bar->rightMark->title->SetColor("white");
+
+	$bar->SetPattern(BAND_RDIAG,"yellow");
+	$bar->SetFillColor("red");
+	$bar->progress->Set($i/10);
+	$bar->progress->SetPattern(GANTT_SOLID,"darkgreen");
+	
+	$graph->Add($bar);
+}
+
+
+// The line will NOT be shown since it is outside the specified slice
+$vline = new GanttVLine("2002-02-28");
+$vline->title->Set("2002-02-28");
+$vline->title->SetFont(FF_FONT1,FS_BOLD,10);
+$graph->Add($vline);
+
+// The milestone will NOT be shown since it is outside the specified slice
+$ms = new MileStone(7,"M5","2002-01-28","28/1");
+$ms->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->Add($ms);
+
+$graph->Stroke();
+
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/gantthgridex1.php b/web/classes/jpgraph/Examples/gantthgridex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..70a94813645344823ac293d7a854c17019ea0963
--- /dev/null
+++ b/web/classes/jpgraph/Examples/gantthgridex1.php
@@ -0,0 +1,63 @@
+<?php // content="text/plain; charset=utf-8"
+// Gantt horizontal grid example
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+
+// Some dummy data for some activities
+$data = array(
+	array(0,"Group 1  Johan", "2001-10-23","2001-11-06",FF_FONT1,FS_BOLD,8),
+	array(1,"  Label 2", "2001-10-26","2001-11-04"),
+	array(3,"Group 2", "2001-11-20","2001-11-28",FF_FONT1,FS_BOLD,8),
+	array(4,"  Label 1", "2001-11-20","2001-12-1"));
+
+// New Gantt Graph
+$graph = new GanttGraph(500);
+
+// Setup a title
+$graph->title->Set("Grid example");
+$graph->subtitle->Set("(Horizontal grid)");
+$graph->title->SetFont(FF_VERDANA,FS_NORMAL,14);
+
+// Specify what headers to show
+$graph->ShowHeaders(GANTT_HMONTH|GANTT_HDAY );
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+$graph->scale->week->SetFont(FF_FONT0);
+
+// Setup a horizontal grid
+$graph->hgrid->Show();
+$graph->hgrid->SetRowFillColor('darkblue@0.9');
+
+
+for($i=0; $i<count($data); ++$i) {
+    $bar = new GanttBar($data[$i][0],$data[$i][1],$data[$i][2],$data[$i][3],"[5%]",10);
+    if( count($data[$i]) > 4 )
+	$bar->title->SetFont($data[$i][4],$data[$i][5],$data[$i][6]);
+    $bar->SetPattern(BAND_RDIAG,"yellow");
+    $bar->SetFillColor("red");
+    $graph->Add($bar);
+}
+
+// Setup a vertical marker line 
+$vline = new GanttVLine("2001-11-01");
+$vline->SetDayOffset(0.5);
+$vline->title->Set("2001-11-01");
+$vline->title->SetFont(FF_FONT1,FS_BOLD,10);
+$graph->Add($vline);
+
+// Setup a milestone
+$ms = new MileStone(6,"M5","2001-11-28","28/12");
+$ms->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->Add($ms);
+
+// And to show that you can also add an icon we add "Tux"
+$icon = new IconPlot('penguin.png',0.05,0.95,1,15);
+$icon->SetAnchor('left','bottom');
+$graph->Add($icon);
+
+// .. and finally send it back to the browser
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/gantthourex1.php b/web/classes/jpgraph/Examples/gantthourex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..bfe55324e67fb9cd7ade673acbf5521a21bb7c09
--- /dev/null
+++ b/web/classes/jpgraph/Examples/gantthourex1.php
@@ -0,0 +1,51 @@
+<?php // content="text/plain; charset=utf-8"
+// Gantt hour example
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+$graph->SetMarginColor('blue:1.7');
+$graph->SetColor('white');
+
+$graph->SetBackgroundGradient('navy','white',GRAD_HOR,BGRAD_MARGIN);
+$graph->scale->hour->SetBackgroundColor('lightyellow:1.5');
+$graph->scale->hour->SetFont(FF_FONT1);
+$graph->scale->day->SetBackgroundColor('lightyellow:1.5');
+$graph->scale->day->SetFont(FF_FONT1,FS_BOLD);
+
+$graph->title->Set("Example of hours in scale");
+$graph->title->SetColor('white');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,14);
+
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HHOUR);
+
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+$graph->scale->week->SetFont(FF_FONT1);
+$graph->scale->hour->SetIntervall(4);
+
+$graph->scale->hour->SetStyle(HOURSTYLE_HM24);
+$graph->scale->day->SetStyle(DAYSTYLE_SHORTDAYDATE3);
+
+$data = array(
+    array(0,"  Label 1", "2001-01-26 04:00","2001-01-26 14:00"),
+    array(1,"  Label 2", "2001-01-26 10:00","2001-01-26 18:00"),
+    array(2,"  Label 3", "2001-01-26","2001-01-27 10:00")
+);
+
+
+for($i=0; $i<count($data); ++$i) {
+	$bar = new GanttBar($data[$i][0],$data[$i][1],$data[$i][2],$data[$i][3],"[5%]",10);
+	if( count($data[$i])>4 )
+		$bar->title->SetFont($data[$i][4],$data[$i][5],$data[$i][6]);
+	$bar->SetPattern(BAND_RDIAG,"yellow");
+	$bar->SetFillColor("red");
+	$graph->Add($bar);
+}
+
+$graph->Stroke();
+
+
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/gantthourminex1.php b/web/classes/jpgraph/Examples/gantthourminex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..8a76bf12029ef702249b65b7dd74d15754c69c9c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/gantthourminex1.php
@@ -0,0 +1,93 @@
+<?php // content="text/plain; charset=utf-8"
+// Gantt hour + minute example
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+// Some sample Gantt data
+$data = array(
+    array(0,array("Group 1","345 days","2004-03-01","2004-05-05"), "2001-11-27 10:00","2001-11-27 14:00",FF_FONT2,FS_NORMAL,0),
+    array(1,array("  Label one",' 122,5 days',' 2004-03-01',' 2003-05-05','MJ'), "2001-11-27 16:00","2001-11-27 18:00"),
+    array(2,"  Label two", "2001-11-27","2001-11-27 10:00"),
+    array(3,"  Label three", "2001-11-27","2001-11-27 08:00")
+);
+
+
+// Basic graph parameters
+$graph = new GanttGraph();
+$graph->SetMarginColor('darkgreen@0.8');
+$graph->SetColor('white');
+
+// We want to display day, hour and minute scales
+$graph->ShowHeaders(GANTT_HDAY | GANTT_HHOUR | GANTT_HMIN);
+
+// We want to have the following titles in our columns
+// describing each activity
+$graph->scale->actinfo->SetColTitles(
+    array('Act','Duration','Start','Finish','Resp'));//,array(100,70,70,70));
+
+// Uncomment the following line if you don't want the 3D look
+// in the columns headers
+//$graph->scale->actinfo->SetStyle(ACTINFO_2D);
+
+$graph->scale->actinfo->SetFont(FF_ARIAL,FS_NORMAL,10);
+
+//These are the default values for use in the columns
+//$graph->scale->actinfo->SetFontColor('black');
+//$graph->scale->actinfo->SetBackgroundColor('lightgray');
+//$graph->scale->actinfo->vgrid->SetStyle('solid');
+
+$graph->scale->actinfo->vgrid->SetColor('gray');
+$graph->scale->actinfo->SetColor('darkgray');
+
+// Setup day format
+$graph->scale->day->SetBackgroundColor('lightyellow:1.5');
+$graph->scale->day->SetFont(FF_ARIAL);
+$graph->scale->day->SetStyle(DAYSTYLE_SHORTDAYDATE1);
+
+// Setup hour format
+$graph->scale->hour->SetIntervall(1);
+$graph->scale->hour->SetBackgroundColor('lightyellow:1.5');
+$graph->scale->hour->SetFont(FF_FONT0);
+$graph->scale->hour->SetStyle(HOURSTYLE_H24);
+$graph->scale->hour->grid->SetColor('gray:0.8');
+
+// Setup minute format
+$graph->scale->minute->SetIntervall(30);
+$graph->scale->minute->SetBackgroundColor('lightyellow:1.5');
+$graph->scale->minute->SetFont(FF_FONT0);
+$graph->scale->minute->SetStyle(MINUTESTYLE_MM);
+$graph->scale->minute->grid->SetColor('lightgray');
+
+$graph->scale->tableTitle->Set('Phase 1');
+$graph->scale->tableTitle->SetFont(FF_ARIAL,FS_NORMAL,12);
+$graph->scale->SetTableTitleBackground('darkgreen@0.6');
+$graph->scale->tableTitle->Show(true);
+
+$graph->title->Set("Example of hours & mins scale");
+$graph->title->SetColor('darkgray');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,14);
+
+
+for($i=0; $i<count($data); ++$i) {
+    $bar = new GanttBar($data[$i][0],$data[$i][1],$data[$i][2],$data[$i][3]);
+    if( count($data[$i])>4 )
+        $bar->title->SetFont($data[$i][4],$data[$i][5],$data[$i][6]);
+    $bar->SetPattern(BAND_RDIAG,"yellow");
+    $bar->SetFillColor("gray");
+    $graph->Add($bar);
+}
+
+
+//$vline = new GanttVLine("2001-11-27");//d=1006858800,
+$vline = new GanttVLine("2001-11-27 9:00");//d=1006858800,
+$vline->SetWeight(5);
+$vline->SetDayOffset(0);
+$vline->title->Set("27/11 9:00");
+$vline->title->SetFont(FF_FONT1,FS_BOLD,10);
+$graph->Add($vline);
+
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/gantticonex1.php b/web/classes/jpgraph/Examples/gantticonex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..b5a31976fe64287fb79d2004d0c5c78867ae4d7e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/gantticonex1.php
@@ -0,0 +1,77 @@
+<?php // content="text/plain; charset=utf-8"
+// Gantt example
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+// Basic Gantt graph
+$graph = new GanttGraph();
+$graph->title->Set("Gantt chart with title columns and icons");
+$graph->title->SetFont(FF_ARIAL, FS_BOLD,12);
+$graph->title->SetMargin(10);
+
+// Explicitely set the date range
+// (Autoscaling will of course also work)
+$graph->SetDateRange('2001-10-06','2002-4-10');
+
+// 1.5 line spacing to make more room
+$graph->SetVMarginFactor(1.5);
+
+// Setup some nonstandard colors
+$graph->SetMarginColor('darkgreen@0.95');
+$graph->SetBox(true,'yellow:0.6',2);
+$graph->SetFrame(true,'darkgreen',4);
+$graph->scale->divider->SetColor('yellow:0.6');
+$graph->scale->dividerh->SetColor('yellow:0.6');
+
+// Display month and year scale with the gridlines
+$graph->ShowHeaders(GANTT_HMONTH | GANTT_HYEAR);
+$graph->scale->month->grid->SetColor('gray');
+$graph->scale->month->grid->Show(true);
+$graph->scale->year->grid->SetColor('gray');
+$graph->scale->year->grid->Show(true);
+
+// For the titles we also add a minimum width of 100 pixels for the Task name column
+$graph->scale->actinfo->SetColTitles(
+    array('Note','Task','Duration','Start','Finish'),array(30,100));
+$graph->scale->actinfo->SetBackgroundColor('green:0.5@0.5');
+$graph->scale->actinfo->SetFont(FF_ARIAL,FS_NORMAL,10);
+$graph->scale->actinfo->vgrid->SetStyle('solid');
+$graph->scale->actinfo->vgrid->SetColor('gray');
+
+// Uncomment this to keep the columns but show no headers
+//$graph->scale->actinfo->Show(false);
+
+// Setup the icons we want to use
+$erricon = new IconImage(GICON_FOLDER,0.6);
+$startconicon = new IconImage(GICON_FOLDEROPEN,0.6);
+$endconicon = new IconImage(GICON_TEXTIMPORTANT,0.5);
+
+// Store the icons in the first column and use plain text in the others
+$data = array(
+	array(0,array($erricon,"Pre-study","102 days","23 Nov '01","1 Mar '02")
+	      , "2001-11-23","2002-03-1",FF_ARIAL,FS_NORMAL,8),
+	array(1,array($startconicon,"Prototype","21 days","26 Oct '01","16 Nov '01"),
+	      "2001-10-26","2001-11-16",FF_ARIAL,FS_NORMAL,8),
+	array(2,array($endconicon,"Report","12 days","1 Mar '02","13 Mar '02"),
+	      "2002-03-01","2002-03-13",FF_ARIAL,FS_NORMAL,8)
+);
+
+// Create the bars and add them to the gantt chart
+for($i=0; $i<count($data); ++$i) {
+	$bar = new GanttBar($data[$i][0],$data[$i][1],$data[$i][2],$data[$i][3],"[50%]",10);
+	if( count($data[$i])>4 )
+		$bar->title->SetFont($data[$i][4],$data[$i][5],$data[$i][6]);
+	$bar->SetPattern(BAND_RDIAG,"yellow");
+	$bar->SetFillColor("gray");
+	$bar->progress->Set(0.5);
+	$bar->progress->SetPattern(GANTT_SOLID,"darkgreen");
+	$bar->title->SetCSIMTarget(array('#1'.$i,'#2'.$i,'#3'.$i,'#4'.$i,'#5'.$i),array('11'.$i,'22'.$i,'33'.$i));
+	$graph->Add($bar);
+}
+
+// Output the chart
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/ganttmonthyearex1.php b/web/classes/jpgraph/Examples/ganttmonthyearex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..6bc7809c8d522c2ab93ec2a838db25c841e23f02
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttmonthyearex1.php
@@ -0,0 +1,50 @@
+<?php // content="text/plain; charset=utf-8"
+// Gantt example
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+
+$graph->title->Set("Only month & year scale");
+
+// Setup some "very" nonstandard colors
+$graph->SetMarginColor('lightgreen@0.8');
+$graph->SetBox(true,'yellow:0.6',2);
+$graph->SetFrame(true,'darkgreen',4);
+$graph->scale->divider->SetColor('yellow:0.6');
+$graph->scale->dividerh->SetColor('yellow:0.6');
+
+// Explicitely set the date range 
+// (Autoscaling will of course also work)
+$graph->SetDateRange('2001-10-06','2002-4-01');
+
+// Display month and year scale with the gridlines
+$graph->ShowHeaders(GANTT_HMONTH | GANTT_HYEAR);
+$graph->scale->month->grid->SetColor('gray');
+$graph->scale->month->grid->Show(true);
+$graph->scale->year->grid->SetColor('gray');
+$graph->scale->year->grid->Show(true);
+
+// Data for our example activities
+$data = array(
+	array(0,"Group 1  Johan", "2001-11-23","2002-03-1",FF_FONT1,FS_BOLD,8),
+	array(1,"  Label 2", "2001-10-26","2001-11-16"));
+	
+// Create the bars and add them to the gantt chart
+for($i=0; $i<count($data); ++$i) {
+	$bar = new GanttBar($data[$i][0],$data[$i][1],$data[$i][2],$data[$i][3],"[50%]",10);
+	if( count($data[$i])>4 )
+		$bar->title->SetFont($data[$i][4],$data[$i][5],$data[$i][6]);
+	$bar->SetPattern(BAND_RDIAG,"yellow");
+	$bar->SetFillColor("red");
+	$bar->progress->Set(0.5);
+	$bar->progress->SetPattern(GANTT_SOLID,"darkgreen");
+	$graph->Add($bar);
+}
+
+// Output the chart
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/ganttmonthyearex2.php b/web/classes/jpgraph/Examples/ganttmonthyearex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..4ed509255c5b9d91c89f0d5d9cec125ce69d840d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttmonthyearex2.php
@@ -0,0 +1,66 @@
+<?php // content="text/plain; charset=utf-8"
+// Gantt example
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+
+$graph->title->Set("Only month & year scale");
+
+// Setup some "very" nonstandard colors
+$graph->SetMarginColor('lightgreen@0.8');
+$graph->SetBox(true,'yellow:0.6',2);
+$graph->SetFrame(true,'darkgreen',4);
+$graph->scale->divider->SetColor('yellow:0.6');
+$graph->scale->dividerh->SetColor('yellow:0.6');
+
+// Explicitely set the date range 
+// (Autoscaling will of course also work)
+$graph->SetDateRange('2001-10-06','2002-4-10');
+
+// Display month and year scale with the gridlines
+$graph->ShowHeaders(GANTT_HMONTH | GANTT_HYEAR);
+$graph->scale->month->grid->SetColor('gray');
+$graph->scale->month->grid->Show(true);
+$graph->scale->year->grid->SetColor('gray');
+$graph->scale->year->grid->Show(true);
+
+
+// Setup activity info
+
+// For the titles we also add a minimum width of 100 pixels for the Task name column
+$graph->scale->actinfo->SetColTitles(
+    array('Name','Duration','Start','Finish'),array(100));
+$graph->scale->actinfo->SetBackgroundColor('green:0.5@0.5');
+$graph->scale->actinfo->SetFont(FF_ARIAL,FS_NORMAL,10);
+$graph->scale->actinfo->vgrid->SetStyle('solid');
+$graph->scale->actinfo->vgrid->SetColor('gray');
+
+// Data for our example activities
+$data = array(
+	array(0,array("Pre-study","102 days","23 Nov '01","1 Mar '02")
+	      , "2001-11-23","2002-03-1",FF_ARIAL,FS_NORMAL,8),
+	array(1,array("Prototype","21 days","26 Oct '01","16 Nov '01"),
+	      "2001-10-26","2001-11-16",FF_ARIAL,FS_NORMAL,8),
+	array(2,array("Report","12 days","1 Mar '02","13 Mar '02"),
+	      "2002-03-01","2002-03-13",FF_ARIAL,FS_NORMAL,8)
+);
+	
+// Create the bars and add them to the gantt chart
+for($i=0; $i<count($data); ++$i) {
+	$bar = new GanttBar($data[$i][0],$data[$i][1],$data[$i][2],$data[$i][3],"[50%]",10);
+	if( count($data[$i])>4 )
+		$bar->title->SetFont($data[$i][4],$data[$i][5],$data[$i][6]);
+	$bar->SetPattern(BAND_RDIAG,"yellow");
+	$bar->SetFillColor("gray");
+	$bar->progress->Set(0.5);
+	$bar->progress->SetPattern(GANTT_SOLID,"darkgreen");
+	$graph->Add($bar);
+}
+
+// Output the chart
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/ganttmonthyearex3.php b/web/classes/jpgraph/Examples/ganttmonthyearex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..fa0c3f67bb7209c0c6584bf0f8092fbbf1f90be4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttmonthyearex3.php
@@ -0,0 +1,66 @@
+<?php // content="text/plain; charset=utf-8"
+// Gantt example
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+
+$graph->title->Set("Only month & year scale");
+
+// Setup some "very" nonstandard colors
+$graph->SetMarginColor('lightgreen@0.8');
+$graph->SetBox(true,'yellow:0.6',2);
+$graph->SetFrame(true,'darkgreen',4);
+$graph->scale->divider->SetColor('yellow:0.6');
+$graph->scale->dividerh->SetColor('yellow:0.6');
+
+// Explicitely set the date range 
+// (Autoscaling will of course also work)
+$graph->SetDateRange('2001-10-06','2002-4-10');
+
+// Display month and year scale with the gridlines
+$graph->ShowHeaders(GANTT_HMONTH | GANTT_HYEAR);
+$graph->scale->month->grid->SetColor('gray');
+$graph->scale->month->grid->Show(true);
+$graph->scale->year->grid->SetColor('gray');
+$graph->scale->year->grid->Show(true);
+
+
+// Setup activity info
+
+// For the titles we also add a minimum width of 100 pixels for the Task name column
+$graph->scale->actinfo->SetColTitles(
+    array('Type','Name','Duration','Start','Finish'),array(40,100));
+$graph->scale->actinfo->SetBackgroundColor('green:0.5@0.5');
+$graph->scale->actinfo->SetFont(FF_ARIAL,FS_NORMAL,10);
+$graph->scale->actinfo->vgrid->SetStyle('solid');
+$graph->scale->actinfo->vgrid->SetColor('gray');
+
+// Data for our example activities
+$data = array(
+	array(0,array("","Pre-study","102 days","23 Nov '01","1 Mar '02")
+	      , "2001-11-23","2002-03-1",FF_ARIAL,FS_NORMAL,8),
+	array(1,array("","Prototype","21 days","26 Oct '01","16 Nov '01"),
+	      "2001-10-26","2001-11-16",FF_ARIAL,FS_NORMAL,8),
+	array(2,array("","Report","12 days","1 Mar '02","13 Mar '02"),
+	      "2002-03-01","2002-03-13",FF_ARIAL,FS_NORMAL,8)
+);
+	
+// Create the bars and add them to the gantt chart
+for($i=0; $i<count($data); ++$i) {
+	$bar = new GanttBar($data[$i][0],$data[$i][1],$data[$i][2],$data[$i][3],"[50%]",10);
+	if( count($data[$i])>4 )
+		$bar->title->SetFont($data[$i][4],$data[$i][5],$data[$i][6]);
+	$bar->SetPattern(BAND_RDIAG,"yellow");
+	$bar->SetFillColor("gray");
+	$bar->progress->Set(0.5);
+	$bar->progress->SetPattern(GANTT_SOLID,"darkgreen");
+	$graph->Add($bar);
+}
+
+// Output the chart
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/ganttmonthyearex4.php b/web/classes/jpgraph/Examples/ganttmonthyearex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..defa2e73f97330f64034064176044d62a98becb6
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttmonthyearex4.php
@@ -0,0 +1,71 @@
+<?php // content="text/plain; charset=utf-8"
+// Gantt example
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+$graph = new GanttGraph();
+
+$graph->title->Set("Adding a spaning title");
+
+// Setup some "very" nonstandard colors
+$graph->SetMarginColor('lightgreen@0.8');
+$graph->SetBox(true,'yellow:0.6',2);
+$graph->SetFrame(true,'darkgreen',4);
+$graph->scale->divider->SetColor('yellow:0.6');
+$graph->scale->dividerh->SetColor('yellow:0.6');
+
+// Explicitely set the date range
+// (Autoscaling will of course also work)
+$graph->SetDateRange('2001-11-06','2002-1-10');
+
+// Display month and year scale with the gridlines
+$graph->ShowHeaders(GANTT_HMONTH | GANTT_HYEAR | GANTT_HWEEK );
+$graph->scale->month->grid->SetColor('gray');
+$graph->scale->month->grid->Show(true);
+$graph->scale->year->grid->SetColor('gray');
+$graph->scale->year->grid->Show(true);
+
+
+//Setup spanning title
+$graph->scale->tableTitle->Set( 'Phase 1' );
+$graph->scale->tableTitle->SetFont( FF_ARIAL , FS_NORMAL , 16 );
+$graph->scale->SetTableTitleBackground( 'darkgreen@0.6' );
+$graph->scale->tableTitle->Show( true );
+
+// Setup activity info
+
+// For the titles we also add a minimum width of 100 pixels for the Task name column
+$graph->scale->actinfo->SetColTitles(array('Name','Duration','Start','Finish'),array(100));
+$graph->scale->actinfo->SetBackgroundColor('green:0.5@0.5');
+$graph->scale->actinfo->SetFont(FF_ARIAL,FS_NORMAL,10);
+$graph->scale->actinfo->vgrid->SetStyle('solid');
+$graph->scale->actinfo->vgrid->SetColor('gray');
+
+// Data for our example activities
+$data = array(
+	array(0,array("Pre-study","102 days","23 Nov '01","1 Mar '02")
+	      , "2001-11-23","2002-03-1",FF_ARIAL,FS_NORMAL,8),
+	array(1,array("Prototype","21 days","26 Oct '01","16 Nov '01"),
+	      "2001-10-26","2001-11-16",FF_ARIAL,FS_NORMAL,8),
+	array(2,array("Report","12 days","1 Mar '02","13 Mar '02"),
+	      "2002-03-01","2002-03-13",FF_ARIAL,FS_NORMAL,8)
+);
+
+// Create the bars and add them to the gantt chart
+for($i=0; $i<count($data); ++$i) {
+	$bar = new GanttBar($data[$i][0],$data[$i][1],$data[$i][2],$data[$i][3],"[50%]",10);
+	if( count($data[$i])>4 )
+		$bar->title->SetFont($data[$i][4],$data[$i][5],$data[$i][6]);
+	$bar->SetPattern(BAND_RDIAG,"yellow");
+	$bar->SetFillColor("gray");
+	$bar->progress->Set(0.5);
+	$bar->progress->SetPattern(GANTT_SOLID,"darkgreen");
+	$graph->Add($bar);
+}
+
+// Output the chart
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/ganttsimpleex1.php b/web/classes/jpgraph/Examples/ganttsimpleex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..63e4efb6c65d80638b36c598c976e5d0af6f1dc5
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ganttsimpleex1.php
@@ -0,0 +1,31 @@
+<?php // content="text/plain; charset=utf-8"
+// Gantt example
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_gantt.php');
+
+// 
+// The data for the graphs
+//
+$data = array(
+  array(0,ACTYPE_GROUP,    "Phase 1",        "2001-10-26","2001-11-23",''),
+  array(1,ACTYPE_NORMAL,   "  Label 2",      "2001-10-26","2001-11-13",'[KJ]'),
+  array(2,ACTYPE_NORMAL,   "  Label 3",      "2001-11-20","2001-11-22",'[EP]'),
+  array(3,ACTYPE_MILESTONE,"  Phase 1 Done", "2001-11-23",'M2') );
+
+// Create the basic graph
+$graph = new GanttGraph();
+$graph->title->Set("Gantt Graph using CreateSimple()");
+
+// Setup scale
+$graph->ShowHeaders(GANTT_HYEAR | GANTT_HMONTH | GANTT_HDAY | GANTT_HWEEK);
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAY);
+
+// Add the specified activities
+$graph->CreateSimple($data);
+
+// .. and stroke the graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/grace_ex0.php b/web/classes/jpgraph/Examples/grace_ex0.php
new file mode 100755
index 0000000000000000000000000000000000000000..5358ae51d43845175a4bf6d805e68c3800e467c4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/grace_ex0.php
@@ -0,0 +1,58 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+$datay=array(7,19,11,4,20);
+
+// Create the graph and setup the basic parameters 
+$graph = new Graph(300,200,'auto');	
+$graph->img->SetMargin(40,30,40,50);
+$graph->SetScale("textint");
+$graph->SetFrame(true,'blue',1); 
+$graph->SetColor('lightblue');
+$graph->SetMarginColor('lightblue');
+
+// Setup X-axis labels
+$a = $gDateLocale->GetShortMonth();
+$graph->xaxis->SetTickLabels($a);
+$graph->xaxis->SetFont(FF_FONT1);
+$graph->xaxis->SetColor('darkblue','black');
+
+// Setup "hidden" y-axis by given it the same color
+// as the background (this could also be done by setting the weight
+// to zero)
+$graph->yaxis->SetColor('lightblue','darkblue');
+$graph->ygrid->SetColor('white');
+
+// Setup graph title ands fonts
+$graph->title->Set('Using grace = 0');
+$graph->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->xaxis->SetTitle('Year 2002','center');
+$graph->xaxis->SetTitleMargin(10);
+$graph->xaxis->title->SetFont(FF_FONT2,FS_BOLD);
+
+// Add some grace to the top so that the scale doesn't
+// end exactly at the max value. 
+$graph->yaxis->scale->SetGrace(0);
+
+                              
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor('darkblue');
+$bplot->SetColor('darkblue');
+$bplot->SetWidth(0.5);
+$bplot->SetShadow('darkgray');
+
+// Setup the values that are displayed on top of each bar
+// Must use TTF fonts if we want text at an arbitrary angle
+$bplot->value->Show();
+$bplot->value->SetFont(FF_ARIAL,FS_NORMAL,8);
+$bplot->value->SetFormat('$%d');
+$bplot->value->SetColor('darkred');
+$bplot->value->SetAngle(45);
+$graph->Add($bplot);
+
+// Finally stroke the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/grace_ex1.php b/web/classes/jpgraph/Examples/grace_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..7544b44518a245a45cc8c1dd41ee6291b1d107da
--- /dev/null
+++ b/web/classes/jpgraph/Examples/grace_ex1.php
@@ -0,0 +1,58 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+$datay=array(7,19,11,4,20);
+
+// Create the graph and setup the basic parameters 
+$graph = new Graph(300,200,'auto');	
+$graph->img->SetMargin(40,30,40,50);
+$graph->SetScale("textint");
+$graph->SetFrame(true,'blue',1); 
+$graph->SetColor('lightblue');
+$graph->SetMarginColor('lightblue');
+
+// Setup X-axis labels
+$a = $gDateLocale->GetShortMonth();
+$graph->xaxis->SetTickLabels($a);
+$graph->xaxis->SetFont(FF_FONT1);
+$graph->xaxis->SetColor('darkblue','black');
+
+// Setup "hidden" y-axis by given it the same color
+// as the background (this could also be done by setting the weight
+// to zero)
+$graph->yaxis->SetColor('lightblue','darkblue');
+$graph->ygrid->SetColor('white');
+
+// Setup graph title ands fonts
+$graph->title->Set('Using grace = 10%');
+$graph->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->xaxis->SetTitle('Year 2002','center');
+$graph->xaxis->SetTitleMargin(10);
+$graph->xaxis->title->SetFont(FF_FONT2,FS_BOLD);
+
+// Add some grace to the top so that the scale doesn't
+// end exactly at the max value. 
+$graph->yaxis->scale->SetGrace(10);
+
+                              
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor('darkblue');
+$bplot->SetColor('darkblue');
+$bplot->SetWidth(0.5);
+$bplot->SetShadow('darkgray');
+
+// Setup the values that are displayed on top of each bar
+// Must use TTF fonts if we want text at an arbitrary angle
+$bplot->value->Show();
+$bplot->value->SetFont(FF_ARIAL,FS_NORMAL,8);
+$bplot->value->SetFormat('$%d');
+$bplot->value->SetColor('darkred');
+$bplot->value->SetAngle(45);
+$graph->Add($bplot);
+
+// Finally stroke the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/grace_ex2.php b/web/classes/jpgraph/Examples/grace_ex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..eff8b8dad6e4fefc85365879d36bb5d816285b66
--- /dev/null
+++ b/web/classes/jpgraph/Examples/grace_ex2.php
@@ -0,0 +1,58 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+$datay=array(7,19,11,4,20);
+
+// Create the graph and setup the basic parameters 
+$graph = new Graph(300,200,'auto');	
+$graph->img->SetMargin(40,30,40,50);
+$graph->SetScale("textint");
+$graph->SetFrame(true,'blue',1); 
+$graph->SetColor('lightblue');
+$graph->SetMarginColor('lightblue');
+
+// Setup X-axis labels
+$a = $gDateLocale->GetShortMonth();
+$graph->xaxis->SetTickLabels($a);
+$graph->xaxis->SetFont(FF_FONT1);
+$graph->xaxis->SetColor('darkblue','black');
+
+// Setup "hidden" y-axis by given it the same color
+// as the background (this could also be done by setting the weight
+// to zero)
+$graph->yaxis->SetColor('lightblue','darkblue');
+$graph->ygrid->SetColor('white');
+
+// Setup graph title ands fonts
+$graph->title->Set('Using grace = 50%');
+$graph->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->xaxis->SetTitle('Year 2002','center');
+$graph->xaxis->SetTitleMargin(10);
+$graph->xaxis->title->SetFont(FF_FONT2,FS_BOLD);
+
+// Add some grace to the top so that the scale doesn't
+// end exactly at the max value. 
+$graph->yaxis->scale->SetGrace(50);
+
+                              
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor('darkblue');
+$bplot->SetColor('darkblue');
+$bplot->SetWidth(0.5);
+$bplot->SetShadow('darkgray');
+
+// Setup the values that are displayed on top of each bar
+// Must use TTF fonts if we want text at an arbitrary angle
+$bplot->value->Show();
+$bplot->value->SetFont(FF_ARIAL,FS_NORMAL,8);
+$bplot->value->SetFormat('$%d');
+$bplot->value->SetColor('darkred');
+$bplot->value->SetAngle(45);
+$graph->Add($bplot);
+
+// Finally stroke the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/grace_ex3.php b/web/classes/jpgraph/Examples/grace_ex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..40f7daf61a3be064d2fc1cbfd7a49919ee08e5eb
--- /dev/null
+++ b/web/classes/jpgraph/Examples/grace_ex3.php
@@ -0,0 +1,58 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+$datay=array(7,19,11,4,20);
+
+// Create the graph and setup the basic parameters 
+$graph = new Graph(300,200,'auto');	
+$graph->img->SetMargin(40,30,40,50);
+$graph->SetScale("textint");
+$graph->SetFrame(true,'blue',1); 
+$graph->SetColor('lightblue');
+$graph->SetMarginColor('lightblue');
+
+// Setup X-axis labels
+$a = $gDateLocale->GetShortMonth();
+$graph->xaxis->SetTickLabels($a);
+$graph->xaxis->SetFont(FF_FONT1);
+$graph->xaxis->SetColor('darkblue','black');
+
+// Setup "hidden" y-axis by given it the same color
+// as the background (this could also be done by setting the weight
+// to zero)
+$graph->yaxis->SetColor('lightblue','darkblue');
+$graph->ygrid->SetColor('white');
+
+// Setup graph title ands fonts
+$graph->title->Set('Using grace = 100%');
+$graph->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->xaxis->SetTitle('Year 2002','center');
+$graph->xaxis->SetTitleMargin(10);
+$graph->xaxis->title->SetFont(FF_FONT2,FS_BOLD);
+
+// Add some grace to the top so that the scale doesn't
+// end exactly at the max value. 
+$graph->yaxis->scale->SetGrace(100);
+
+                              
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor('darkblue');
+$bplot->SetColor('darkblue');
+$bplot->SetWidth(0.5);
+$bplot->SetShadow('darkgray');
+
+// Setup the values that are displayed on top of each bar
+// Must use TTF fonts if we want text at an arbitrary angle
+$bplot->value->Show();
+$bplot->value->SetFont(FF_ARIAL,FS_NORMAL,8);
+$bplot->value->SetFormat('$%d');
+$bplot->value->SetColor('darkred');
+$bplot->value->SetAngle(45);
+$graph->Add($bplot);
+
+// Finally stroke the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/gradbkgex1.php b/web/classes/jpgraph/Examples/gradbkgex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..0509e41ead2201a8d0758c57d67c25028abca7f9
--- /dev/null
+++ b/web/classes/jpgraph/Examples/gradbkgex1.php
@@ -0,0 +1,66 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay1 = array(4,26,12,18,8,22);
+$datay2 = array(12,9,42,8,20,19);
+
+// Setup the graph
+$graph = new Graph(300,200);
+$graph->SetMarginColor('white');
+$graph->SetScale("textlin",0,50);
+$graph->SetMargin(30,50,30,30);
+
+// We must have the frame enabled to get the gradient
+// However, we don't want the frame line so we set it to
+// white color which makes it invisible.
+$graph->SetFrame(true,'white');
+
+// Setup a background gradient image
+$graph->SetBackgroundGradient('blue','navy:0.5',GRAD_HOR,BGRAD_PLOT);
+
+// Setup the tab title
+$graph->tabtitle->Set(' 3rd Division ' );
+$graph->tabtitle->SetFont(FF_ARIAL,FS_BOLD,13);
+
+// Setup x,Y grid
+$graph->xgrid->Show();
+$graph->xgrid->SetColor('gray@0.5');
+$graph->xaxis->SetTickLabels($gDateLocale->GetShortMonth());
+$graph->ygrid->SetColor('gray@0.5');
+
+// Setup color for axis and labels on axis
+$graph->xaxis->SetColor('orange','black');
+$graph->yaxis->SetColor('orange','black');
+
+// Ticks on the outsid
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+
+// Setup the legend box colors and font
+$graph->legend->SetColor('white','navy');
+$graph->legend->SetFillColor('navy@0.25');
+$graph->legend->SetFont(FF_ARIAL,FS_BOLD,8);
+$graph->legend->SetShadow('darkgray@0.4',3);
+$graph->legend->SetPos(0.05,0.05,'right','top');
+
+// Create the first line
+$p1 = new LinePlot($datay1);
+$p1->SetColor("red");
+$p1->SetWeight(2);
+$p1->SetLegend('2002');
+$graph->Add($p1);
+
+// Create the second line
+$p2 = new LinePlot($datay2);
+$p2->SetColor("lightyellow");
+$p2->SetLegend('2001');
+$p2->SetWeight(2);
+$graph->Add($p2);
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/gradlinefillex1.php b/web/classes/jpgraph/Examples/gradlinefillex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..06520e2e0ec63682ed2e3d837792230bccc905f7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/gradlinefillex1.php
@@ -0,0 +1,29 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay = array(20,15,33,5,17,35,22);
+
+// Setup the graph
+$graph = new Graph(400,200);
+$graph->SetMargin(40,40,20,30);	
+$graph->SetScale("intlin");
+$graph->SetMarginColor('darkgreen@0.8');
+
+$graph->title->Set('Gradient filled line plot');
+$graph->yscale->SetAutoMin(0);
+
+// Create the line
+$p1 = new LinePlot($datay);
+$p1->SetColor("blue");
+$p1->SetWeight(0);
+$p1->SetFillGradient('red','yellow');
+
+$graph->Add($p1);
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/gradlinefillex2.php b/web/classes/jpgraph/Examples/gradlinefillex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..97887445b855603b52d32e043ef9ab36237a1069
--- /dev/null
+++ b/web/classes/jpgraph/Examples/gradlinefillex2.php
@@ -0,0 +1,30 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay = array(20,10,35,5,17,35,22);
+
+// Setup the graph
+$graph = new Graph(400,200);
+$graph->SetMargin(40,40,20,30);	
+$graph->SetScale("intlin");
+$graph->SetBox();
+$graph->SetMarginColor('darkgreen@0.8');
+
+// Setup a background gradient image
+$graph->SetBackgroundGradient('darkred','yellow',GRAD_HOR,BGRAD_PLOT);
+
+$graph->title->Set('Gradient filled line plot ex2');
+$graph->yscale->SetAutoMin(0);
+
+// Create the line
+$p1 = new LinePlot($datay);
+$p1->SetFillGradient('white','darkgreen');
+$graph->Add($p1);
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/gradlinefillex3.php b/web/classes/jpgraph/Examples/gradlinefillex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..17b6e5150c9aac28207e9ae3d13e0693ba054434
--- /dev/null
+++ b/web/classes/jpgraph/Examples/gradlinefillex3.php
@@ -0,0 +1,30 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay = array(20,10,35,5,17,35,22);
+
+// Setup the graph
+$graph = new Graph(400,200);
+$graph->SetMargin(40,40,20,30);	
+$graph->SetScale("intlin");
+$graph->SetBox();
+$graph->SetMarginColor('darkgreen@0.8');
+
+// Setup a background gradient image
+$graph->SetBackgroundGradient('darkred','yellow',GRAD_HOR,BGRAD_PLOT);
+
+$graph->title->Set('Gradient filled line plot ex3');
+$graph->yscale->SetAutoMin(0);
+
+// Create the line
+$p1 = new LinePlot($datay);
+$p1->SetFillGradient('white','darkgreen',4);
+$graph->Add($p1);
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/gradlinefillex4.php b/web/classes/jpgraph/Examples/gradlinefillex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..f921560e729d58a39d367b1dac9e6d205b9b6b7b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/gradlinefillex4.php
@@ -0,0 +1,31 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay = array(20,10,35,5,17,35,22);
+
+// Setup the graph
+$graph = new Graph(400,200);
+$graph->SetMargin(40,40,20,30);	
+$graph->SetScale("intlin");
+$graph->SetBox();
+$graph->SetMarginColor('darkgreen@0.8');
+
+// Setup a background gradient image
+$graph->SetBackgroundGradient('darkred','yellow',GRAD_HOR,BGRAD_PLOT);
+
+$graph->title->Set('Gradient filled line plot ex2');
+$graph->yscale->SetAutoMin(0);
+
+// Create the line
+$p1 = new LinePlot($datay);
+$p1->SetFillGradient('white','darkgreen');
+$p1->SetStepStyle();
+$graph->Add($p1);
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/green_example.php b/web/classes/jpgraph/Examples/green_example.php
new file mode 100755
index 0000000000000000000000000000000000000000..4c939d2dceaf036b1788ce82250bc0e707271f35
--- /dev/null
+++ b/web/classes/jpgraph/Examples/green_example.php
@@ -0,0 +1,58 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$theme = isset($_GET['theme']) ? $_GET['theme'] : null;
+
+$data = array (
+  0 => array (0 => 79, 1 => -25, 2 => -7, 3 => 85, 4 => -26, 5 => -32, ),
+  1 => array (0 => 76, 1 => 51, 2 => 86, 3 => 12, 4 => -7, 5 => 94, ),
+  2 => array (0 => 49, 1 => 38, 2 => 7, 3 => -40, 4 => 9, 5 => -7, ),
+  3 => array ( 0 => 69, 1 => 96, 2 => 49, 3 => 7, 4 => 92, 5 => -38, ),
+  4 => array ( 0 => 68, 1 => 16, 2 => 82, 3 => -49, 4 => 50, 5 => 7, ),
+  5 => array ( 0 => -37, 1 => 28, 2 => 32, 3 => 6, 4 => 13, 5 => 57, ),
+  6 => array ( 0 => 24, 1 => -11, 2 => 7, 3 => 10, 4 => 51, 5 => 51, ),
+  7 => array ( 0 => 3, 1 => -1, 2 => -12, 3 => 61, 4 => 10, 5 => 47, ),
+  8 => array ( 0 => -47, 1 => -21, 2 => 43, 3 => 53, 4 => 36, 5 => 34, ),
+);
+
+
+// Create the graph. These two calls are always required
+$graph = new Graph(400,300);    
+
+$graph->SetScale("textlin");
+if ($theme) {
+  $graph->SetTheme(new $theme());
+}
+$theme_class = new GreenTheme;
+$graph->SetTheme($theme_class);
+
+$plot = array();
+// Create the bar plots
+for ($i = 0; $i < 4; $i++) {
+  $plot[$i] = new BarPlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.($i+1));
+}
+//$acc1 = new AccBarPlot(array($plot[0], $plot[1]));
+//$acc1->value->Show();
+$gbplot = new GroupBarPlot(array($plot[2], $plot[1] ));
+
+for ($i = 4; $i < 8; $i++) {
+  $plot[$i] = new LinePlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.$i);
+  $plot[$i]->value->Show();
+}
+
+$graph->Add($gbplot);
+$graph->Add($plot[4]);
+
+$title = "GreenTheme Example";
+$title = mb_convert_encoding($title,'UTF-8');
+$graph->title->Set($title);
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/groupbarex1.php b/web/classes/jpgraph/Examples/groupbarex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..40f28ee38839ac3c1fec748769dfc1d926dd0739
--- /dev/null
+++ b/web/classes/jpgraph/Examples/groupbarex1.php
@@ -0,0 +1,44 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: groupbarex1.php,v 1.2 2002/07/11 23:27:28 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay1=array(35,160,0,0,0,0);
+$datay2=array(35,190,190,190,190,190);
+$datay3=array(20,70,70,140,230,260);
+
+$graph = new Graph(450,200,'auto');	
+$graph->SetScale("textlin");
+$graph->SetShadow();
+$graph->img->SetMargin(40,30,40,40);
+$graph->xaxis->SetTickLabels($gDateLocale->GetShortMonth());
+
+$graph->xaxis->title->Set('Year 2002');
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$graph->title->Set('Group bar plot');
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$bplot1 = new BarPlot($datay1);
+$bplot2 = new BarPlot($datay2);
+$bplot3 = new BarPlot($datay3);
+
+$bplot1->SetFillColor("orange");
+$bplot2->SetFillColor("brown");
+$bplot3->SetFillColor("darkgreen");
+
+$bplot1->SetShadow();
+$bplot2->SetShadow();
+$bplot3->SetShadow();
+
+$bplot1->SetShadow();
+$bplot2->SetShadow();
+$bplot3->SetShadow();
+
+$gbarplot = new GroupBarPlot(array($bplot1,$bplot2,$bplot3));
+$gbarplot->SetWidth(0.6);
+$graph->Add($gbarplot);
+
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/heat1.jpg b/web/classes/jpgraph/Examples/heat1.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..07f04d762c7adeb9d70b95997129818904a80b18
Binary files /dev/null and b/web/classes/jpgraph/Examples/heat1.jpg differ
diff --git a/web/classes/jpgraph/Examples/horizbarex1.php b/web/classes/jpgraph/Examples/horizbarex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..bc5055fc862a11521a4dc9eece918c86f20c38dc
--- /dev/null
+++ b/web/classes/jpgraph/Examples/horizbarex1.php
@@ -0,0 +1,63 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(2,3,5,8,12,6,3);
+$datax=array('Jan','Feb','Mar','Apr','May','Jun','Jul');
+
+// Size of graph
+$width=400;
+$height=500;
+
+// Set the basic parameters of the graph
+$graph = new Graph($width,$height,'auto');
+$graph->SetScale('textlin');
+
+// Rotate graph 90 degrees and set margin
+$graph->Set90AndMargin(50,20,50,30);
+
+// Nice shadow
+$graph->SetShadow();
+
+// Setup title
+$graph->title->Set('Horizontal bar graph ex 1');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,14);
+
+// Setup X-axis
+$graph->xaxis->SetTickLabels($datax);
+$graph->xaxis->SetFont(FF_VERDANA,FS_NORMAL,12);
+
+// Some extra margin looks nicer
+$graph->xaxis->SetLabelMargin(10);
+
+// Label align for X-axis
+$graph->xaxis->SetLabelAlign('right','center');
+
+// Add some grace to y-axis so the bars doesn't go
+// all the way to the end of the plot area
+$graph->yaxis->scale->SetGrace(20);
+
+// We don't want to display Y-axis
+$graph->yaxis->Hide();
+
+// Now create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor('orange');
+$bplot->SetShadow();
+
+//You can change the width of the bars if you like
+//$bplot->SetWidth(0.5);
+
+// We want to display the value of each bar at the top
+$bplot->value->Show();
+$bplot->value->SetFont(FF_ARIAL,FS_BOLD,12);
+$bplot->value->SetAlign('left','center');
+$bplot->value->SetColor('black','darkred');
+$bplot->value->SetFormat('%.1f mkr');
+
+// Add the bar to the graph
+$graph->Add($bplot);
+
+// .. and stroke the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/horizbarex2.php b/web/classes/jpgraph/Examples/horizbarex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..d50bb7d4781182e01c1d3a625c7b356360380934
--- /dev/null
+++ b/web/classes/jpgraph/Examples/horizbarex2.php
@@ -0,0 +1,70 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(2,3,5,8,12,6,3);
+$datax=array("Jan","Feb","Mar","Apr","May","Jun","Jul");
+
+$width=400; 
+$height=500;
+
+// Set the basic parameters of the graph 
+$graph = new Graph($width,$height,'auto');
+$graph->SetScale("textlin");
+
+$top = 80;
+$bottom = 30;
+$left = 50;
+$right = 30;
+$graph->Set90AndMargin($left,$right,$top,$bottom);
+
+// Nice shadow
+$graph->SetShadow();
+
+// Setup title
+$graph->title->Set("Horizontal bar graph ex 2");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,14);
+$graph->subtitle->Set("(Axis at top)");
+
+// Setup X-axis
+$graph->xaxis->SetTickLabels($datax);
+$graph->xaxis->SetFont(FF_VERDANA,FS_NORMAL,12);
+
+// Some extra margin looks nicer
+$graph->xaxis->SetLabelMargin(5);
+
+// Label align for X-axis
+$graph->xaxis->SetLabelAlign('right','center');
+
+// Add some grace to y-axis so the bars doesn't go
+// all the way to the end of the plot area
+$graph->yaxis->scale->SetGrace(20);
+$graph->yaxis->SetLabelAlign('center','bottom');
+$graph->yaxis->SetLabelAngle(45);
+$graph->yaxis->SetLabelFormat('%d');
+$graph->yaxis->SetFont(FF_VERDANA,FS_NORMAL,12);
+
+// We don't want to display Y-axis
+//$graph->yaxis->Hide();
+
+// Now create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("orange");
+$bplot->SetShadow();
+
+//You can change the width of the bars if you like
+//$bplot->SetWidth(0.5);
+
+// We want to display the value of each bar at the top
+$bplot->value->Show();
+$bplot->value->SetFont(FF_ARIAL,FS_BOLD,12);
+$bplot->value->SetAlign('left','center');
+$bplot->value->SetColor("black","darkred");
+$bplot->value->SetFormat('%.1f mkr');
+
+// Add the bar to the graph
+$graph->Add($bplot);
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/horizbarex3.php b/web/classes/jpgraph/Examples/horizbarex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..c0d5a49ff84efcf9a0714d0925174a91575dc45d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/horizbarex3.php
@@ -0,0 +1,99 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(2,3,-5,8,12,6,3);
+$datax=array("Jan","Feb","Mar","Apr","May","Jun","Jul");
+
+// Size of graph
+$width=400; 
+$height=500;
+
+// Set the basic parameters of the graph 
+$graph = new Graph($width,$height,'auto');
+$graph->SetScale("textlin");
+
+$top = 50;
+$bottom = 80;
+$left = 50;
+$right = 20;
+$graph->Set90AndMargin($left,$right,$top,$bottom);
+
+$graph->xaxis->SetPos('min');
+
+// Nice shadow
+$graph->SetShadow();
+
+// Setup title
+$graph->title->Set("Horizontal bar graph ex 3");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,14);
+$graph->subtitle->Set("(Axis at bottom)");
+
+// Setup X-axis
+$graph->xaxis->SetTickLabels($datax);
+$graph->xaxis->SetFont(FF_FONT2,FS_BOLD,12);
+
+// Some extra margin looks nicer
+$graph->xaxis->SetLabelMargin(5);
+
+// Label align for X-axis
+$graph->xaxis->SetLabelAlign('right','center');
+
+// Add some grace to y-axis so the bars doesn't go
+// all the way to the end of the plot area
+$graph->yaxis->scale->SetGrace(20);
+
+// Setup the Y-axis to be displayed in the bottom of the 
+// graph. We also finetune the exact layout of the title,
+// ticks and labels to make them look nice.
+$graph->yaxis->SetPos('max');
+
+// First make the labels look right
+$graph->yaxis->SetLabelAlign('center','top');
+$graph->yaxis->SetLabelFormat('%d');
+$graph->yaxis->SetLabelSide(SIDE_RIGHT);
+
+// The fix the tick marks
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+
+// Finally setup the title
+$graph->yaxis->SetTitleSide(SIDE_RIGHT);
+$graph->yaxis->SetTitleMargin(35);
+
+// To align the title to the right use :
+$graph->yaxis->SetTitle('Turnaround 2002','high');
+$graph->yaxis->title->Align('right');
+
+// To center the title use :
+//$graph->yaxis->SetTitle('Turnaround 2002','center');
+//$graph->yaxis->title->Align('center');
+
+$graph->yaxis->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->yaxis->title->SetAngle(0);
+
+$graph->yaxis->SetFont(FF_FONT2,FS_NORMAL);
+// If you want the labels at an angle other than 0 or 90
+// you need to use TTF fonts
+//$graph->yaxis->SetLabelAngle(0);
+
+// Now create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("orange");
+$bplot->SetShadow();
+
+//You can change the width of the bars if you like
+//$bplot->SetWidth(0.5);
+
+// We want to display the value of each bar at the top
+$bplot->value->Show();
+$bplot->value->SetFont(FF_ARIAL,FS_BOLD,12);
+$bplot->value->SetAlign('left','center');
+$bplot->value->SetColor("black","darkred");
+$bplot->value->SetFormat('%.1f mkr');
+
+// Add the bar to the graph
+$graph->Add($bplot);
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/horizbarex4.php b/web/classes/jpgraph/Examples/horizbarex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..5f51be489d84a47f7cbcedf8ed50c5ff9feefd9b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/horizbarex4.php
@@ -0,0 +1,48 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: horizbarex4.php,v 1.4 2002/11/17 23:59:27 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(1992,1993,1995,1996,1997,1998,2001);
+
+// Size of graph
+$width=400;
+$height=500;
+
+// Set the basic parameters of the graph
+$graph = new Graph($width,$height);
+$graph->SetScale('textlin');
+
+$top = 60;
+$bottom = 30;
+$left = 80;
+$right = 30;
+$graph->Set90AndMargin($left,$right,$top,$bottom);
+
+// Nice shadow
+$graph->SetShadow();
+
+// Setup labels
+$lbl = array("Andrew\nTait","Thomas\nAnderssen","Kevin\nSpacey","Nick\nDavidsson",
+"David\nLindquist","Jason\nTait","Lorin\nPersson");
+$graph->xaxis->SetTickLabels($lbl);
+
+// Label align for X-axis
+$graph->xaxis->SetLabelAlign('right','center','right');
+
+// Label align for Y-axis
+$graph->yaxis->SetLabelAlign('center','bottom');
+
+// Titles
+$graph->title->Set('Number of incidents');
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor('orange');
+$bplot->SetWidth(0.5);
+$bplot->SetYMin(1990);
+
+$graph->Add($bplot);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/horizbarex6.php b/web/classes/jpgraph/Examples/horizbarex6.php
new file mode 100755
index 0000000000000000000000000000000000000000..8ab4cbc69b20e668586eb7b879b221c1a4302d27
--- /dev/null
+++ b/web/classes/jpgraph/Examples/horizbarex6.php
@@ -0,0 +1,83 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(2,3,5,8,12,6,3);
+$datax=array("320x240","640x480","600x800","1024x768","1280x1024(16)","1280x1024(32)",
+	     "1600x1200(32)");
+
+// Size of graph
+$width=300; 
+$height=400;
+
+// Set the basic parameters of the graph 
+$graph = new Graph($width,$height,'auto');
+$graph->SetScale("textlin");
+
+// No frame around the image
+$graph->SetFrame(false);
+
+// Rotate graph 90 degrees and set margin
+$graph->Set90AndMargin(100,20,50,30);
+
+// Set white margin color
+$graph->SetMarginColor('white');
+
+// Use a box around the plot area
+$graph->SetBox();
+
+// Use a gradient to fill the plot area
+$graph->SetBackgroundGradient('white','lightblue',GRAD_HOR,BGRAD_PLOT);
+
+// Setup title
+$graph->title->Set("Graphic card performance");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,11);
+$graph->subtitle->Set("(Non optimized)");
+
+// Setup X-axis
+$graph->xaxis->SetTickLabels($datax);
+$graph->xaxis->SetFont(FF_VERDANA,FS_NORMAL,8);
+
+// Some extra margin looks nicer
+$graph->xaxis->SetLabelMargin(10);
+
+// Label align for X-axis
+$graph->xaxis->SetLabelAlign('right','center');
+
+// Add some grace to y-axis so the bars doesn't go
+// all the way to the end of the plot area
+$graph->yaxis->scale->SetGrace(20);
+
+// We don't want to display Y-axis
+$graph->yaxis->Hide();
+
+// Now create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetShadow();
+
+//You can change the width of the bars if you like
+//$bplot->SetWidth(0.5);
+
+// Set gradient fill for bars
+$bplot->SetFillGradient('darkred','yellow',GRAD_HOR);
+
+// We want to display the value of each bar at the top
+$bplot->value->Show();
+$bplot->value->SetFont(FF_ARIAL,FS_BOLD,10);
+//$bplot->value->SetAlign('left','center');
+$bplot->value->SetColor("white");
+$bplot->value->SetFormat('%.1f');
+$bplot->SetValuePos('max');
+
+// Add the bar to the graph
+$graph->Add($bplot);
+
+// Add some explanation text
+$txt = new Text('Note: Higher value is better.');
+$txt->SetPos(190,399,'center','bottom');
+$txt->SetFont(FF_ARIAL,FS_NORMAL,8);
+$graph->Add($txt);
+
+// .. and stroke the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/icon.jpg b/web/classes/jpgraph/Examples/icon.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..dc3b30299f4e3588e561ddd84d99d415b620e8ed
Binary files /dev/null and b/web/classes/jpgraph/Examples/icon.jpg differ
diff --git a/web/classes/jpgraph/Examples/imgmarkercsimex1.php b/web/classes/jpgraph/Examples/imgmarkercsimex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..2c91a0dde2b3ffb814761a30ad28ca5779978068
--- /dev/null
+++ b/web/classes/jpgraph/Examples/imgmarkercsimex1.php
@@ -0,0 +1,55 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+$datay1 = array(4,26,15,44);
+
+// Setup the graph
+$graph = new Graph(300,200);
+$graph->SetMarginColor('white');
+$graph->SetScale("textlin");
+$graph->SetFrame(false);
+$graph->SetMargin(30,5,25,20);
+
+// Setup the tab
+$graph->tabtitle->Set(' Year 2003 ' );
+$graph->tabtitle->SetFont(FF_ARIAL,FS_BOLD,13);
+$graph->tabtitle->SetColor('darkred','#E1E1FF');
+
+// Enable X-grid as well
+$graph->xgrid->Show();
+
+// Use months as X-labels
+$graph->xaxis->SetTickLabels($gDateLocale->GetShortMonth());
+
+// Create the plot
+$p1 = new LinePlot($datay1);
+$p1->SetColor("navy");
+
+$p1->SetCSIMTargets(array('#1','#2','#3','#4','#5'));
+
+// Use an image of favourite car as 
+$p1->mark->SetType(MARK_IMG,'saab_95.jpg',0.5);
+//$p1->mark->SetType(MARK_SQUARE);
+
+// Displayes value on top of marker image
+$p1->value->SetFormat('%d mil');
+$p1->value->Show();
+$p1->value->SetColor('darkred');
+$p1->value->SetFont(FF_ARIAL,FS_BOLD,10);
+// Increase the margin so that the value is printed avove tje
+// img marker
+$p1->value->SetMargin(14);
+
+// Incent the X-scale so the first and last point doesn't
+// fall on the edges
+$p1->SetCenter();
+
+$graph->Add($p1);
+
+$graph->StrokeCSIM();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/imgmarkerex1.php b/web/classes/jpgraph/Examples/imgmarkerex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..9f5e8ce6d2448c79413440f2364beac725353f82
--- /dev/null
+++ b/web/classes/jpgraph/Examples/imgmarkerex1.php
@@ -0,0 +1,52 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+$datay1 = array(4,26,15,44);
+
+// Setup the graph
+$graph = new Graph(300,200);
+$graph->SetMarginColor('white');
+$graph->SetScale("textlin");
+$graph->SetFrame(false);
+$graph->SetMargin(30,5,25,20);
+
+// Setup the tab
+$graph->tabtitle->Set(' Year 2003 ' );
+$graph->tabtitle->SetFont(FF_ARIAL,FS_BOLD,13);
+$graph->tabtitle->SetColor('darkred','#E1E1FF');
+
+// Enable X-grid as well
+$graph->xgrid->Show();
+
+// Use months as X-labels
+$graph->xaxis->SetTickLabels($gDateLocale->GetShortMonth());
+
+// Create the plot
+$p1 = new LinePlot($datay1);
+$p1->SetColor("navy");
+
+// Use an image of favourite car as marker
+$p1->mark->SetType(MARK_IMG,'saab_95.jpg',0.5);
+
+// Displayes value on top of marker image
+$p1->value->SetFormat('%d mil');
+$p1->value->Show();
+$p1->value->SetColor('darkred');
+$p1->value->SetFont(FF_ARIAL,FS_BOLD,10);
+// Increase the margin so that the value is printed avove tje
+// img marker
+$p1->value->SetMargin(14);
+
+// Incent the X-scale so the first and last point doesn't
+// fall on the edges
+$p1->SetCenter();
+
+$graph->Add($p1);
+
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/impulsex1.php b/web/classes/jpgraph/Examples/impulsex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..ff8938330758619b42236e301602b2e9464cafca
--- /dev/null
+++ b/web/classes/jpgraph/Examples/impulsex1.php
@@ -0,0 +1,23 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+$datay = array(20,22,12,13,17,20,16,19,30,31,40,43);
+
+$graph = new Graph(300,200);
+$graph->SetScale("textlin");
+
+$graph->SetShadow();
+$graph->img->SetMargin(40,40,40,40);		
+
+$graph->title->Set("Simple mpuls plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$sp1 = new ScatterPlot($datay);
+$sp1->mark->SetType(MARK_SQUARE);
+$sp1->SetImpuls();
+
+$graph->Add($sp1);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/impulsex2.php b/web/classes/jpgraph/Examples/impulsex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..8ea45973d2b871686ae06c26ce4c74943779f99e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/impulsex2.php
@@ -0,0 +1,29 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+$datay = array(20,22,12,13,17,20,16,19,30,31,40,43);
+
+$graph = new Graph(300,200);
+$graph->SetScale("textlin");
+
+$graph->SetShadow();
+$graph->img->SetMargin(40,40,40,40);		
+
+$graph->title->Set("Impuls plot, variant 2");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->Set("Impuls respons");
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$sp1 = new ScatterPlot($datay);//,$datax);
+$sp1->mark->SetType(MARK_FILLEDCIRCLE);
+$sp1->mark->SetFillColor("red");
+$sp1->mark->SetWidth(4);
+$sp1->SetImpuls();
+$sp1->SetColor("blue");
+$sp1->SetWeight(3);
+
+$graph->Add($sp1);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/impulsex3.php b/web/classes/jpgraph/Examples/impulsex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..f7b5182ee97a1f8bfe532ad390149e121d3c91c8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/impulsex3.php
@@ -0,0 +1,53 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+$numpoints=50;
+$k=0.05;
+
+// Create some data points
+for($i=0; $i<$numpoints; ++$i) {
+	$datay[$i]=exp(-$k*$i)*cos(2*M_PI/10*$i);
+}
+
+// A format callbakc function
+function mycallback($l) {
+	return sprintf("%02.2f",$l);
+}
+
+// Setup the basic parameters for the graph
+$graph = new Graph(400,200);
+$graph->SetScale("intlin");
+$graph->SetShadow();
+$graph->SetBox();
+
+$graph->title->Set("Impuls Example 3");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Set format callback for labels
+$graph->yaxis->SetLabelFormatCallback("mycallback");
+
+// Set X-axis at the minimum value of Y-axis (default will be at 0)
+$graph->xaxis->SetPos("min");	// "min" will position the x-axis at the minimum value of the Y-axis
+
+// Extend the margin for the labels on the Y-axis and reverse the direction
+// of the ticks on the Y-axis
+$graph->yaxis->SetLabelMargin(12);
+$graph->xaxis->SetLabelMargin(6);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+
+// Create a new impuls type scatter plot
+$sp1 = new ScatterPlot($datay);
+$sp1->mark->SetType(MARK_SQUARE);
+$sp1->mark->SetFillColor("red");
+$sp1->SetImpuls();
+$sp1->SetColor("blue");
+$sp1->SetWeight(1);
+$sp1->mark->SetWidth(3);
+
+$graph->Add($sp1);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/impulsex4.php b/web/classes/jpgraph/Examples/impulsex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..ac497adec225af5d8bae7d210b27546bce703c86
--- /dev/null
+++ b/web/classes/jpgraph/Examples/impulsex4.php
@@ -0,0 +1,76 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_plotline.php');
+
+$numpoints=50;
+$k=0.05;
+
+// Create some data points
+for($i=-$numpoints+1; $i<0; ++$i) {
+	$datay[$i+$numpoints-1]=exp($k*$i)*cos(2*M_PI/10*$i)*14;
+	$datayenv[$i+$numpoints-1]=exp($k*$i)*14;
+	$datax[$i+$numpoints-1]=$i;
+}
+
+for($i=0; $i<$numpoints; ++$i) {
+	$datay[$i+$numpoints-1]=exp(-$k*$i)*cos(2*M_PI/10*$i)*14;
+	$datayenv[$i+$numpoints-1]=exp(-$k*$i)*14;
+	$datax[$i+$numpoints-1]=$i;
+}
+
+// Setup the basic parameters for the graph
+$graph = new Graph(500,250);
+$graph->SetScale("intlin");
+
+$graph->SetShadow();
+$graph->SetBox();
+$graph->title->Set("Impuls Example 4");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Set some other color then the boring default
+$graph->SetColor("lightyellow");
+$graph->SetMarginColor("khaki");
+
+// Set legend box specification
+$graph->legend->SetFillColor("white");
+$graph->legend->SetLineWeight(2);
+
+// Set X-axis at the minimum value of Y-axis (default will be at 0)
+$graph->xaxis->SetPos("min");	// "min" will position the x-axis at the minimum value of the Y-axis
+
+// Extend the margin for the labels on the Y-axis and reverse the direction
+// of the ticks on the Y-axis
+$graph->yaxis->SetLabelMargin(12);
+$graph->xaxis->SetLabelMargin(6);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+
+// Add mark graph with static lines
+$line = new PlotLine(HORIZONTAL,0,"black",2);
+$graph->AddLine($line);
+
+// Create a new impuls type scatter plot
+$sp1 = new ScatterPlot($datay,$datax);
+$sp1->mark->SetType(MARK_SQUARE);
+$sp1->mark->SetFillColor("red");
+$sp1->mark->SetWidth(3);
+
+$sp1->SetImpuls();
+$sp1->SetColor("blue");
+$sp1->SetWeight(1);
+$sp1->SetLegend("Non-causal signal");
+
+$graph->Add($sp1);
+
+// Create the envelope plot
+$ep1 = new LinePlot($datayenv,$datax);
+$ep1->SetStyle("dotted");
+$ep1->SetLegend("Positive envelope");
+
+$graph->Add($ep1);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/index.html b/web/classes/jpgraph/Examples/index.html
new file mode 100755
index 0000000000000000000000000000000000000000..6731a8505f96806006745fdd9f6086fadd6a5669
--- /dev/null
+++ b/web/classes/jpgraph/Examples/index.html
@@ -0,0 +1,36 @@
+<h2>Examples of odometers</h2>
+
+<table>
+<tr>
+<td><img src="odoex00.php"></td>
+<td><img src="odoex01.php"></td>
+</tr>
+<tr>
+<td><img src="odoex02.php"></td>
+<td><img src="odoex03.php"></td>
+</tr>
+<tr>
+<td><img src="odoex04.php"></td>
+<td><img src="odoex05.php"></td>
+</tr>
+<tr>
+<td><img src="odoex06.php"></td>
+<td><img src="odoex07.php"></td>
+</tr>
+<tr>
+<td><img src="odoex08.php"></td>
+<td><img src="odoex09.php"></td>
+</tr>
+<tr>
+<td><img src="odoex010.php"></td>
+<td><img src="odoex011.php"></td>
+</tr>
+<tr>
+<td><img src="odoex012.php"></td>
+</tr>
+</table>
+
+
+
+
+
diff --git a/web/classes/jpgraph/Examples/interpolation-growth-log.php b/web/classes/jpgraph/Examples/interpolation-growth-log.php
new file mode 100755
index 0000000000000000000000000000000000000000..c9ecd00798bf46939ebb23b80a4fab88cdba4e4a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/interpolation-growth-log.php
@@ -0,0 +1,42 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_log.php');
+
+// Matrix size rxr
+$r = 10;
+
+// Max Interpolation factor
+$f = 5;
+
+for( $i=1; $i <= $f; ++$i ) {
+	$xdata[] = $i;
+	$ydata[] =  pow( $r*pow(2,($i-1)) - ( pow(2,$i) - 1 ),2);
+}
+
+$graph = new Graph(400,240);
+$graph->SetScale('intlog');
+$graph->SetMargin(50,50,20,30);
+$graph->SetFrame(false);
+$graph->SetBox(true,'black',2);
+$graph->SetMarginColor('white');
+$graph->SetColor('lightyellow@0.7');
+
+$graph->title->Set('Interpolation growth for size 10x10');
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$graph->xaxis->SetTitle('Interpolation factor','center');
+$graph->xaxis->SetTitleMargin(10);
+
+$graph->SetAxisStyle(AXSTYLE_YBOXIN);
+$graph->xgrid->Show();
+
+$lp1 = new LinePlot($ydata,$xdata);
+$lp1->SetColor('darkred');
+$lp1->SetWeight(3);
+$graph->Add($lp1);
+
+$graph->Stroke();
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/interpolation-growth.php b/web/classes/jpgraph/Examples/interpolation-growth.php
new file mode 100755
index 0000000000000000000000000000000000000000..e1fec180a2dd49f6e8c0a1165d39cb3632b96162
--- /dev/null
+++ b/web/classes/jpgraph/Examples/interpolation-growth.php
@@ -0,0 +1,42 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_log.php');
+
+// Matrix size rxr
+$r = 10;
+
+// Max Interpolation factor
+$f = 5;
+
+for( $i=1; $i <= $f; ++$i ) {
+	$xdata[] = $i;
+	$ydata[] =  pow( $r*pow(2,($i-1)) - ( pow(2,$i) - 1 ),2);
+}
+
+$graph = new Graph(400,240);
+$graph->SetScale('intint');
+$graph->SetMargin(50,50,20,30);
+$graph->SetFrame(false);
+$graph->SetBox(true,'black',2);
+$graph->SetMarginColor('white');
+$graph->SetColor('lightyellow@0.7');
+
+$graph->title->Set('Interpolation growth for size 10x10');
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$graph->xaxis->SetTitle('Interpolation factor','center');
+$graph->xaxis->SetTitleMargin(10);
+
+$graph->SetAxisStyle(AXSTYLE_YBOXIN);
+$graph->xgrid->Show();
+
+$lp1 = new LinePlot($ydata,$xdata);
+$lp1->SetColor('darkred');
+$lp1->SetWeight(3);
+$graph->Add($lp1);
+
+$graph->Stroke();
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/inyaxisex1.php b/web/classes/jpgraph/Examples/inyaxisex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..d6e3d4166a8b94f42f22b1e616dde23fa279d45f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/inyaxisex1.php
@@ -0,0 +1,51 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Callback to negate the argument
+function _cb_negate($aVal) {
+    return round(-$aVal);
+}
+
+// A fake depth curve
+$ydata = array(0,1,4,5,8,9,10,14,16,16,16,18,20,20,20,22,22.5,22,19,19,15,15,15,15,10,10,10,6,5,5,5,4,4,2,1,0);
+
+// Negate all data
+$n = count($ydata);
+for($i=0; $i<$n; ++$i) {
+    $ydata[$i] = round(-$ydata[$i]);
+}
+
+// Basic graph setup
+$graph = new Graph(400,300);
+$graph->SetScale("linlin");
+$graph->img->SetMargin(50,50,60,40);	
+$graph->SetMarginColor('darkblue');
+$graph->SetColor('darkblue');
+$graph->SetAxisStyle(AXSTYLE_BOXOUT);
+
+$graph->title->Set("Depth curve. Dive #2");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->title->SetColor("white");
+
+$graph->subtitle->Set("(Negated Y-axis)");
+$graph->subtitle->SetFont(FF_FONT1,FS_NORMAL);
+$graph->subtitle->SetColor("white");
+
+// Setup axis
+$graph->yaxis->SetLabelFormatCallback("_cb_negate");
+$graph->xaxis->SetColor("lightblue","white");
+$graph->yaxis->SetColor("lightblue","white");
+$graph->ygrid->SetColor("blue");
+
+
+$lp1 = new LinePlot($ydata);
+$lp1->SetColor("yellow");
+$lp1->SetWeight(2);
+
+
+$graph->Add($lp1);
+$graph->Stroke();
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/inyaxisex2.php b/web/classes/jpgraph/Examples/inyaxisex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..5e19d4aae38a90c1c633a41d166b6fef4a1611df
--- /dev/null
+++ b/web/classes/jpgraph/Examples/inyaxisex2.php
@@ -0,0 +1,53 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Callback to negate the argument
+function _cb_negate($aVal) {
+    return round(-$aVal);
+}
+
+// A fake depth curve
+$ydata = array(0,1,4,5,8,9,10,14,16,16,16,18,20,20,20,22,22.5,22,19,19,15,15,15,15,10,10,10,6,5,5,5,4,4,2,1,0);
+
+// Negate all data
+$n = count($ydata);
+for($i=0; $i<$n; ++$i) {
+    $ydata[$i] = round(-$ydata[$i]);
+}
+
+// Basic graph setup
+$graph = new Graph(400,300);
+$graph->SetScale("linlin");
+$graph->img->SetMargin(50,50,60,40);	
+$graph->SetMarginColor('darkblue');
+$graph->SetColor('darkblue');
+$graph->SetAxisStyle(AXSTYLE_BOXOUT);
+$graph->SetBackgroundImage("blueblack400x300grad.png",1);
+//$graph->SetBackgroundImage("lightbluedarkblue400x300grad.png",1);
+
+$graph->title->Set("Depth curve. Dive #2");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->title->SetColor("white");
+
+$graph->subtitle->Set("(Negated Y-axis)");
+$graph->subtitle->SetFont(FF_FONT1,FS_NORMAL);
+$graph->subtitle->SetColor("white");
+
+// Setup axis
+$graph->yaxis->SetLabelFormatCallback("_cb_negate");
+$graph->xaxis->SetColor("lightblue","white");
+$graph->yaxis->SetColor("lightblue","white");
+$graph->ygrid->SetColor("blue");
+
+
+$lp1 = new LinePlot($ydata);
+$lp1->SetColor("yellow");
+$lp1->SetWeight(2);
+
+
+$graph->Add($lp1);
+$graph->Stroke();
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/inyaxisex3.php b/web/classes/jpgraph/Examples/inyaxisex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..e09567efa3852b0b00c625336441b6d20219f83a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/inyaxisex3.php
@@ -0,0 +1,69 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Callback to negate the argument
+function _cb_negate($aVal) {
+    return round(-$aVal);
+}
+
+// A fake depth curve
+$ydata = array(0,1,4,5,8,9,10,14,16,16,16,18,20,20,20,22,22.5,22,19,19,15,15,15,15,10,10,10,6,5,5,5,4,4,2,1,0);
+
+$n = count($ydata);
+$y2data = array();
+for( $i=0; $i< $n; ++$i ) {
+    $y2data[] = $ydata[$i]+10;
+}
+
+// Negate all data
+$n = count($ydata);
+for($i=0; $i<$n; ++$i) {
+    $ydata[$i] = round(-$ydata[$i]);
+    $y2data[$i] = round(-$y2data[$i]);
+}
+
+// Basic graph setup
+$graph = new Graph(400,300);
+$graph->SetScale("linlin");
+$graph->SetY2Scale("lin");
+$graph->SetMargin(50,50,60,40);	
+$graph->SetMarginColor('darkblue');
+$graph->SetColor('darkblue');
+
+// Setup titles
+$graph->title->Set("Inverting both Y-axis");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->title->SetColor("white");
+
+$graph->subtitle->Set("(Negated Y & Y2 axis)");
+$graph->subtitle->SetFont(FF_FONT1,FS_NORMAL);
+$graph->subtitle->SetColor("white");
+
+// Setup axis
+$graph->yaxis->SetLabelFormatCallback("_cb_negate");
+$graph->xaxis->SetColor("lightblue","white");
+$graph->yaxis->SetColor("lightblue","white");
+$graph->ygrid->SetColor("blue");
+
+// Setup Y2 axis
+$graph->y2axis->SetLabelFormatCallback("_cb_negate");
+$graph->y2axis->SetColor("darkred","white");
+$graph->y2scale->SetAutoMax(0); // To make sure it starts with 0
+
+// Setup plot 1
+$lp1 = new LinePlot($ydata);
+$lp1->SetColor("yellow");
+$lp1->SetWeight(2);
+$graph->Add($lp1);
+
+// Setup plot 2
+$lp2 = new LinePlot($y2data);
+$lp2->SetColor("darkred");
+$lp2->SetWeight(2);
+$graph->AddY2($lp2);
+
+$graph->Stroke();
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/ironrod.jpg b/web/classes/jpgraph/Examples/ironrod.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..0b9e8d4031014f935102f064be34a8fd8141383f
Binary files /dev/null and b/web/classes/jpgraph/Examples/ironrod.jpg differ
diff --git a/web/classes/jpgraph/Examples/jpglogo.jpg b/web/classes/jpgraph/Examples/jpglogo.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..a7f71211a38d79b58c3bbfff2377e5fbc6ab95c3
Binary files /dev/null and b/web/classes/jpgraph/Examples/jpglogo.jpg differ
diff --git a/web/classes/jpgraph/Examples/ledex1.php b/web/classes/jpgraph/Examples/ledex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..8d61f937ceb3d09e095c2a2596484e532e466e92
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex1.php
@@ -0,0 +1,12 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels
+$led = new DigitalLED74();
+$led->StrokeNumber('0123456789. ABCDEFGHIJKL',LEDC_GREEN); 
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex10.php b/web/classes/jpgraph/Examples/ledex10.php
new file mode 100755
index 0000000000000000000000000000000000000000..3aa375f9aac2f3fcb3dabc9f6ed80b6c91442ffe
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex10.php
@@ -0,0 +1,12 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels
+$led = new DigitalLED74();
+$led->StrokeNumber('0123456789. ABCDEFGHIJKL',LEDC_KHAKI);
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex11.php b/web/classes/jpgraph/Examples/ledex11.php
new file mode 100755
index 0000000000000000000000000000000000000000..857faa0746ee2f6ddb619437d0afe09030bbec78
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex11.php
@@ -0,0 +1,12 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels
+$led = new DigitalLED74();
+$led->StrokeNumber('0123456789. ABCDEFGHIJKL',LEDC_OLIVE);
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex12.php b/web/classes/jpgraph/Examples/ledex12.php
new file mode 100755
index 0000000000000000000000000000000000000000..7756ea130af22bfd1d0c46ecae1e4b932abd665d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex12.php
@@ -0,0 +1,12 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels
+$led = new DigitalLED74();
+$led->StrokeNumber('0123456789. ABCDEFGHIJKL',LEDC_LIMEGREEN);
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex13.php b/web/classes/jpgraph/Examples/ledex13.php
new file mode 100755
index 0000000000000000000000000000000000000000..add394d3f106c81cf164c30611194c87c4f5aa18
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex13.php
@@ -0,0 +1,12 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels
+$led = new DigitalLED74();
+$led->StrokeNumber('0123456789. ABCDEFGHIJKL',LEDC_FORESTGREEN);
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex14.php b/web/classes/jpgraph/Examples/ledex14.php
new file mode 100755
index 0000000000000000000000000000000000000000..7a50599938e61a9eb99fb0e777837bf2134fbd92
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex14.php
@@ -0,0 +1,12 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels
+$led = new DigitalLED74();
+$led->StrokeNumber('0123456789. ABCDEFGHIJKL',LEDC_TEAL);
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex15.php b/web/classes/jpgraph/Examples/ledex15.php
new file mode 100755
index 0000000000000000000000000000000000000000..6a5bb1f6f091440a310908a5c4761be914d75630
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex15.php
@@ -0,0 +1,12 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels
+$led = new DigitalLED74();
+$led->StrokeNumber('0123456789. ABCDEFGHIJKL',LEDC_STEELBLUE);
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex16.php b/web/classes/jpgraph/Examples/ledex16.php
new file mode 100755
index 0000000000000000000000000000000000000000..08ab73129bffeac0210f76dfed47ab759c18d6d4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex16.php
@@ -0,0 +1,12 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels
+$led = new DigitalLED74();
+$led->StrokeNumber('0123456789. ABCDEFGHIJKL',LEDC_NAVY);
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex17.php b/web/classes/jpgraph/Examples/ledex17.php
new file mode 100755
index 0000000000000000000000000000000000000000..34f18cd1ba6f81d5346e29c682a60f71a0a7bc22
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex17.php
@@ -0,0 +1,12 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels
+$led = new DigitalLED74();
+$led->StrokeNumber('0123456789. ABCDEFGHIJKL',LEDC_INVERTGRAY);
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex2.php b/web/classes/jpgraph/Examples/ledex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..bd196d389b8644facb600359c06699f8d361e4f0
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex2.php
@@ -0,0 +1,12 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels
+$led = new DigitalLED74();
+$led->StrokeNumber('0123456789. ABCDEFGHIJKL',LEDC_RED); 
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex3.php b/web/classes/jpgraph/Examples/ledex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..0d81b3d521d41f5cd643d9819b284047bf7f9429
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex3.php
@@ -0,0 +1,12 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels
+$led = new DigitalLED74();
+$led->StrokeNumber('0123456789. ABCDEFGHIJKL',LEDC_YELLOW); 
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex4.1.php b/web/classes/jpgraph/Examples/ledex4.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..81a9d1ff38b637b55b46f3cf0fd7891ed274497e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex4.1.php
@@ -0,0 +1,13 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels. Change to 5 and slghtly smaller margin
+$led = new DigitalLED74(6);
+$led->SetSupersampling(2);
+$led->StrokeNumber('123.',LEDC_RED);
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex4.2.php b/web/classes/jpgraph/Examples/ledex4.2.php
new file mode 100755
index 0000000000000000000000000000000000000000..0a25bc029c2ce4f2b0e94390f5573bf412dd08fc
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex4.2.php
@@ -0,0 +1,13 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels. Change to 5 and slghtly smaller margin
+$led = new DigitalLED74(6);
+$led->SetSupersampling(4);
+$led->StrokeNumber('123.',LEDC_RED);
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex4.php b/web/classes/jpgraph/Examples/ledex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..d8782e25691ee46841bd30478138ec3d244a0203
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex4.php
@@ -0,0 +1,13 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels. Change to 5 and slghtly smaller margin
+$led = new DigitalLED74(6);
+$led->SetSupersampling(1);
+$led->StrokeNumber('123.',LEDC_RED);
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex5.php b/web/classes/jpgraph/Examples/ledex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..5526063c5a5780f477a5f467c8d0fd09dcf2d2c9
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex5.php
@@ -0,0 +1,12 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels
+$led = new DigitalLED74();
+$led->StrokeNumber('0123456789. ABCDEFGHIJKL',LEDC_BLUE);
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex6.php b/web/classes/jpgraph/Examples/ledex6.php
new file mode 100755
index 0000000000000000000000000000000000000000..eb8c03bad5ed97f651657f152ddc9af2b0f9423d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex6.php
@@ -0,0 +1,12 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels
+$led = new DigitalLED74();
+$led->StrokeNumber('0123456789. ABCDEFGHIJKL',LEDC_GRAY);
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex7.php b/web/classes/jpgraph/Examples/ledex7.php
new file mode 100755
index 0000000000000000000000000000000000000000..da6c656b8b82a5ecaebc9ee4f46d9d1746181e98
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex7.php
@@ -0,0 +1,12 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels
+$led = new DigitalLED74();
+$led->StrokeNumber('0123456789. ABCDEFGHIJKL',LEDC_CHOCOLATE);
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex8.php b/web/classes/jpgraph/Examples/ledex8.php
new file mode 100755
index 0000000000000000000000000000000000000000..2075e261255c95586628452d799fb65b8e7be4c9
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex8.php
@@ -0,0 +1,12 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels
+$led = new DigitalLED74();
+$led->StrokeNumber('0123456789. ABCDEFGHIJKL',LEDC_PERU);
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex9.php b/web/classes/jpgraph/Examples/ledex9.php
new file mode 100755
index 0000000000000000000000000000000000000000..82837d1d7676761a8d80d6d2fe0ac28d3fb83cd2
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex9.php
@@ -0,0 +1,12 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels
+$led = new DigitalLED74();
+$led->StrokeNumber('0123456789. ABCDEFGHIJKL',LEDC_GOLDENROD);
+
+
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex_cyrillic.php b/web/classes/jpgraph/Examples/ledex_cyrillic.php
new file mode 100755
index 0000000000000000000000000000000000000000..b85f9d31cbebf6fa2bc607b3ebbd34f5475f9c60
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex_cyrillic.php
@@ -0,0 +1,27 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels. Change to 5 and slghtly smaller margin
+$led = new DigitalLED74(3);
+$led->SetSupersampling(2);
+$text =     'А'.
+            'Б'.
+            'В'.
+            'Г'.
+            'Д'.
+            'Е'.
+            'Ё'.
+            'З'.
+            'И'.
+            'Й'.
+            'К'.
+            'Л'.
+            'М'.
+            'Н'.
+            'О'.
+			'П';
+$led->StrokeNumber($text, LEDC_RED);
+
+?>
diff --git a/web/classes/jpgraph/Examples/ledex_cyrillic2.php b/web/classes/jpgraph/Examples/ledex_cyrillic2.php
new file mode 100755
index 0000000000000000000000000000000000000000..fb0071440adf3e6bc4e75855722f40814f5198ab
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ledex_cyrillic2.php
@@ -0,0 +1,27 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_led.php');
+
+// By default each "LED" circle has a radius of 3 pixels. Change to 5 and slghtly smaller margin
+$led = new DigitalLED74(3);
+$led->SetSupersampling(2);
+$text =     'Р'.
+            'С'.
+            'Т'.
+            'У'.
+            'Ф'.
+            'Х'.
+            'Ц'.
+            'Ч'.
+            'Ш'.
+            'Щ'.
+            'Ъ'.
+            'Ы'.
+            'Ь'.
+            'Э'.
+            'Ю'.
+            'Я';
+$led->StrokeNumber($text, LEDC_RED);
+
+?>
diff --git a/web/classes/jpgraph/Examples/lightbluedarkblue400x300grad.png b/web/classes/jpgraph/Examples/lightbluedarkblue400x300grad.png
new file mode 100755
index 0000000000000000000000000000000000000000..86092ecfd852b479f7e21ed69415fd8b554bf2ff
Binary files /dev/null and b/web/classes/jpgraph/Examples/lightbluedarkblue400x300grad.png differ
diff --git a/web/classes/jpgraph/Examples/linebarcentex1.php b/web/classes/jpgraph/Examples/linebarcentex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..1b5e188858a035db5f9248a08b9b2a3c12b6c9d4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/linebarcentex1.php
@@ -0,0 +1,49 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$l1datay = array(11,9,2,4,3,13,17);
+$l2datay = array(23,12,5,19,17,10,15);
+
+$datax=$gDateLocale->GetShortMonth();
+
+// Create the graph. 
+$graph = new Graph(400,200);	
+$graph->SetScale("textlin");
+$graph->SetMargin(40,130,20,40);
+$graph->SetShadow();
+$graph->xaxis->SetTickLabels($datax);
+
+// Create the linear error plot
+$l1plot=new LinePlot($l1datay);
+$l1plot->SetColor("red");
+$l1plot->SetWeight(2);
+$l1plot->SetLegend("Prediction");
+
+//Center the line plot in the center of the bars
+$l1plot->SetBarCenter();
+
+
+// Create the bar plot
+$bplot = new BarPlot($l2datay);
+$bplot->SetFillColor("orange");
+$bplot->SetLegend("Result");
+
+// Add the plots to t'he graph
+$graph->Add($bplot);
+$graph->Add($l1plot);
+
+
+$graph->title->Set("Adding a line plot to a bar graph v1");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/linebarex1.php b/web/classes/jpgraph/Examples/linebarex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..2f4414d8250836a5e0edd611f6ef341f5c43138c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/linebarex1.php
@@ -0,0 +1,75 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$month=array(
+"Jan","Feb","Mar","Apr","Maj","Jun","Jul","Aug","Sep","Okt","Nov","Dec");
+
+// Create datapoints where every point
+$steps=100;
+for($i=0; $i<$steps; ++$i) {
+	$datay[$i]=log(pow($i,$i/10)+1)*sin($i/15)+35;
+	$databarx[]=sprintf("198%d %s",floor($i/12),$month[$i%12]);
+	
+	// Simulate an accumulated value for every 5:th data point
+	if( $i % 6 == 0 ) {
+		$databary[]=abs(25*sin($i)+5);
+	}
+	else {
+		$databary[]=0;
+	}
+	
+}
+
+
+// New graph with a background image and drop shadow
+$graph = new Graph(450,300);
+$graph->SetBackgroundImage("tiger_bkg.png",BGIMG_FILLFRAME);
+$graph->SetShadow();
+
+// Use an integer X-scale
+$graph->SetScale("textlin");
+
+// Set title and subtitle
+$graph->title->Set("Combined bar and line plot");
+$graph->subtitle->Set("100 data points, X-Scale: 'text'");
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Make the margin around the plot a little bit bigger
+// then default
+$graph->img->SetMargin(40,140,40,80);	
+
+// Slightly adjust the legend from it's default position in the
+// top right corner to middle right side
+$graph->legend->Pos(0.05,0.5,"right","center");
+
+// Display every 10:th datalabel
+$graph->xaxis->SetTextTickInterval(6);
+$graph->xaxis->SetTextLabelInterval(2);
+$graph->xaxis->SetTickLabels($databarx);
+$graph->xaxis->SetLabelAngle(90);
+
+// Create a red line plot
+$p1 = new LinePlot($datay);
+$p1->SetColor("red");
+$p1->SetLegend("Pressure");
+
+// Create the bar plot
+$b1 = new BarPlot($databary);
+$b1->SetLegend("Temperature");
+$b1->SetAbsWidth(6);
+$b1->SetShadow();
+
+// The order the plots are added determines who's ontop
+$graph->Add($p1);
+$graph->Add($b1);
+
+// Finally output the  image
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/linebarex2.php b/web/classes/jpgraph/Examples/linebarex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..efae8e2d02cc100f450f2446d69906df8ea95d19
--- /dev/null
+++ b/web/classes/jpgraph/Examples/linebarex2.php
@@ -0,0 +1,59 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+
+$steps=100;
+for($i=0; $i<$steps; ++$i) {
+	$datay[$i]=log(pow($i,$i/10)+1)*sin($i/15)+35;
+	$datax[]=$i;
+	if( $i % 10 == 0 ) {
+		$databarx[]=$i;
+		$databary[]=$datay[$i]/2;
+	}
+}
+
+// New graph with a background image and drop shadow
+$graph = new Graph(450,300);
+$graph->SetBackgroundImage("tiger_bkg.png",BGIMG_FILLFRAME);
+$graph->SetShadow();
+
+// Use an integer X-scale
+$graph->SetScale("intlin");
+
+// Set title and subtitle
+$graph->title->Set("Combined bar and line plot");
+$graph->subtitle->Set("(\"left\" aligned bars)");
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Make the margin around the plot a little bit bigger
+// then default
+$graph->img->SetMargin(40,120,40,40);	
+
+// Slightly adjust the legend from it's default position in the
+// top right corner to middle right side
+$graph->legend->Pos(0.05,0.5,"right","center");
+
+// Create a red line plot
+$p1 = new LinePlot($datay,$datax);
+$p1->SetColor("red");
+$p1->SetLegend("Status one");
+$graph->Add($p1);
+
+// Create the bar plot
+$b1 = new BarPlot($databary,$databarx);
+$b1->SetLegend("Status two");
+$b1->SetAlign("left");
+$b1->SetShadow();
+$graph->Add($b1);
+
+// Finally output the  image
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/linebarex3.php b/web/classes/jpgraph/Examples/linebarex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..faff220d767e33f7478ef45dc073d235d31e6dfd
--- /dev/null
+++ b/web/classes/jpgraph/Examples/linebarex3.php
@@ -0,0 +1,52 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+
+$steps=100;for($i=0; $i<$steps; ++$i) {	
+    $datay[$i]=log(pow($i,$i/10)+1)*sin($i/15)+35;	
+    $datax[]=$i;	
+    if( $i % 10 == 0 ) {		
+	$databarx[]=$i;		
+	$databary[]=$datay[$i]/2;	
+    }
+}
+
+// New graph with a background image and drop shadow
+$graph = new Graph(450,300);
+$graph->img->SetMargin(40,180,40,40);	
+$graph->SetBackgroundImage("tiger_bkg.png",BGIMG_FILLFRAME);
+
+//$graph->img->SetAntiAliasing();
+
+$graph->SetScale("intlin");
+$graph->SetShadow();
+$graph->title->Set("Combined bar and line plot");
+$graph->subtitle->Set("(\"center\" aligned bars)");
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Slightly adjust the legend from it's default position in the
+// top right corner. 
+$graph->legend->Pos(0.05,0.5,"right","center");
+
+// Create the first line
+
+$p1 = new LinePlot($datay,$datax);
+$p1->SetWeight(1);
+$p1->SetColor("red");
+$p1->SetLegend("Triumph Tiger -98");
+$graph->Add($p1);
+
+$b1 = new BarPlot($databary,$databarx);
+$b1->SetAbsWidth(10);
+$b1->SetAlign("center");
+$b1->SetShadow();
+$graph->Add($b1);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/linegraceex.php b/web/classes/jpgraph/Examples/linegraceex.php
new file mode 100755
index 0000000000000000000000000000000000000000..e64cdc4f914a88f49b4b270d6a4160a113007f59
--- /dev/null
+++ b/web/classes/jpgraph/Examples/linegraceex.php
@@ -0,0 +1,31 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay = array(0.2980,0.3039,0.3020,0.3027,0.3015);
+
+$graph = new Graph(300,200);
+$graph->img->SetMargin(40,40,40,40);	
+
+$graph->img->SetAntiAliasing();
+$graph->SetScale("textlin");
+$graph->SetShadow();
+$graph->title->Set("Example of 10% top/bottom grace");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Add 10% grace to top and bottom of plot
+$graph->yscale->SetGrace(10,10);
+
+$p1 = new LinePlot($datay);
+$p1->mark->SetType(MARK_FILLEDCIRCLE);
+$p1->mark->SetFillColor("red");
+$p1->mark->SetWidth(4);
+$p1->SetColor("blue");
+$p1->SetCenter();
+$graph->Add($p1);
+
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/lineiconex1.php b/web/classes/jpgraph/Examples/lineiconex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..53f2b00fc15e86d17d78e4f6525d87695cc58239
--- /dev/null
+++ b/web/classes/jpgraph/Examples/lineiconex1.php
@@ -0,0 +1,49 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_iconplot.php');
+
+
+//$datay = array(20,15,23,15,17,35,22);
+$datay = array(30,25,33,25,27,45,32);
+$datay2 = array(3,25,10,15,50,5,18);
+$datay3 = array(10,5,10,15,5,2,1);
+
+// Setup the graph
+$graph = new Graph(400,250);
+$graph->SetMargin(40,40,20,30);	
+$graph->SetScale("textlin");
+
+$graph->title->Set('Adding an icon ("tux") in the background');
+$graph->title->SetFont(FF_ARIAL,FS_NORMAL,12);
+
+//$graph->SetBackgroundGradient('red','blue');
+
+$graph->xaxis->SetPos('min');
+
+$p1 = new LinePlot($datay);
+$p1->SetColor("blue");
+$p1->SetFillGradient('yellow@0.4','red@0.4');
+
+$p2 = new LinePlot($datay2);
+$p2->SetColor("black");
+$p2->SetFillGradient('green@0.4','white');
+
+$p3 = new LinePlot($datay3);
+$p3->SetColor("blue");
+$p3->SetFillGradient('navy@0.4','white@0.4');
+
+$graph->Add($p1);
+$graph->Add($p2);
+$graph->Add($p3);
+
+$icon = new IconPlot('penguin.png',0.2,0.3,1,30);
+$icon->SetAnchor('center','center');
+$graph->Add($icon);
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/lineiconex2.php b/web/classes/jpgraph/Examples/lineiconex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..d16ab8b75935f2731ec7b65fbf4cc2a38a41a138
--- /dev/null
+++ b/web/classes/jpgraph/Examples/lineiconex2.php
@@ -0,0 +1,32 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_flags.php');
+require_once ('jpgraph/jpgraph_iconplot.php');
+
+$datay = array(30,25,33,25,27,45,32);
+
+// Setup the graph
+$graph = new Graph(400,250);
+$graph->SetMargin(40,40,20,30);	
+$graph->SetScale("textlin");
+
+$graph->title->Set('Adding a country flag as a an icon');
+
+$p1 = new LinePlot($datay);
+$p1->SetColor("blue");
+$p1->SetFillGradient('yellow@0.4','red@0.4');
+
+$graph->Add($p1);
+
+$icon = new IconPlot();
+$icon->SetCountryFlag('iceland',50,30,1.5,40,3);
+$icon->SetAnchor('left','top');
+$graph->Add($icon);
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/lineimagefillex1.php b/web/classes/jpgraph/Examples/lineimagefillex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..d2fb60aede8b74c21071d13aa8d64752a3c999a6
--- /dev/null
+++ b/web/classes/jpgraph/Examples/lineimagefillex1.php
@@ -0,0 +1,41 @@
+<?php
+require_once ('../jpgraph.php');
+require_once ('../jpgraph_line.php');
+
+$datay = array(0,3,5,12,15,18,22,36,37,41);
+
+// Setup the graph
+$graph = new Graph(320,200);
+$graph->title->Set('Education growth');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph->SetScale('intlin');
+$graph->SetMarginColor('white');
+$graph->SetBox();
+//$graph->img->SetAntialiasing();
+
+$graph->SetGridDepth(DEPTH_FRONT);
+$graph->ygrid->SetColor('gray@0.7');
+$graph->SetBackgroundImage('classroom.jpg',BGIMG_FILLPLOT);
+
+// Masking graph
+$p1 = new LinePlot($datay);
+$p1->SetFillColor('white');
+$p1->SetFillFromYMax();
+$p1->SetWeight(0);
+$graph->Add($p1);
+
+// Line plot
+$p2 = new LinePlot($datay);
+$p2->SetColor('black@0.4');
+$p2->SetWeight(3);
+$p2->mark->SetType(MARK_SQUARE);
+$p2->mark->SetColor('orange@0.5');
+$p2->mark->SetFillColor('orange@0.3');
+$graph->Add($p2);
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/linlogex1.php b/web/classes/jpgraph/Examples/linlogex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..4c2be9dee1782fdc45bf150392d4a45f8f72e007
--- /dev/null
+++ b/web/classes/jpgraph/Examples/linlogex1.php
@@ -0,0 +1,64 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_log.php');
+require_once ('jpgraph/jpgraph_error.php');
+
+$xdata = array( 2.0,  2.5,  3.0,  4.0,  5.0,  6.0,  8.0, 10.0,
+               12.0, 15.0, 20.0, 25.0, 30.0, 40.0, 50.0, 60.0,
+               75.0, 100., 125., 150., 175., 200., 250., 300.,
+               400., 500., 600., 800., 950.,
+              1200., 1500., 2000., 2500.);
+$ydata = array(270.,  280., // 2 m
+               330.,  340., // 2.5
+               410.,  420., // 3
+               550.,  560., // 4
+               670.,  680., // 5
+               770.,  780., // 6
+               930.,  940., // 8
+              1010., 1020., // 10
+              1040., 1050., // 12
+               980.,  990., // 15
+               860.,  870., // 20
+               720.,  730., // 25
+               590.,  600., // 30
+               370.,  380., // 40
+               330.,  340., // 50
+               320.,  330., // 60
+               320.,  330., // 75
+               300.,  310., // 100
+               305.,  315., // 125
+               310.,  320., // 150
+               315.,  325., // 175
+               300.,  310., // 200
+               270.,  280., // 250
+               240.,  250., // 300
+               200.,  210., // 400
+               150.,  160., // 500
+               120.,  130., // 600
+                50.,   60., // 800
+                30.,   40., // 950
+                15.,   20., // 1200
+                 8.,   10., // 1500
+                 7.,    9., // 2000
+                 8.,   10.  // 2500 m
+               );
+
+$graph = new Graph(500,300);
+$graph->SetScale("linlog");
+$graph->img->SetMargin(40,20,20,40);
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->Set("ab/2");
+$graph->yaxis->title->Set("rho_s");
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->ygrid->Show(true,true);
+$graph->xgrid->Show(true,true);
+
+$errorplot=new ErrorPlot($ydata, $xdata);
+
+$graph->Add($errorplot);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/listallflags.php b/web/classes/jpgraph/Examples/listallflags.php
new file mode 100755
index 0000000000000000000000000000000000000000..0f7a7966a00e2d93e5892ece18244e9aa3fcc857
--- /dev/null
+++ b/web/classes/jpgraph/Examples/listallflags.php
@@ -0,0 +1,29 @@
+<?php // content="text/plain; charset=utf-8"
+// List all current supported flags.
+// $Id: listallflags.php,v 1.1.2.1 2003/06/29 15:28:12 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_flags.php');
+
+// Flag size to use in table 
+$s = FLAGSIZE2 ;
+$w = 60;
+$flags = new FlagImages($s) ;
+
+// Create a nice table wil all flags and their full name (and index)
+echo "<table width=100%><tr>\n";
+$cols=0;
+while( list($key,$val) = each($flags->iCountryNameMap) ) {
+
+    echo '<td width=20%><a href="javascript:window.open(\'listallflags_helper.php?size=4&idx='.$val.'\',\'_new\',\'width=500,height=350\');void(0)"><img src="listallflags_helper.php?size='.$s.'&idx='.$val.'"></a><br>';
+    echo "<small>$key</small><br><small><font color=blue><i>idx=$val</i></font></small></td>\n";
+    
+    if( ++$cols == 5 ) {
+	echo "</tr>\n<tr>";
+	$cols=0;
+    }
+}
+
+echo "</tr></table>";
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/listallflags_helper.php b/web/classes/jpgraph/Examples/listallflags_helper.php
new file mode 100755
index 0000000000000000000000000000000000000000..52ad9f9b1b57787278bdb48b6f3bd5cac4fd1496
--- /dev/null
+++ b/web/classes/jpgraph/Examples/listallflags_helper.php
@@ -0,0 +1,25 @@
+<?php // content="text/plain; charset=utf-8"
+require_once 'jpgraph/jpgraph.php';
+require_once 'jpgraph/jpgraph_flags.php';
+
+if( empty($_GET['size']) ) {
+    $size = FLAGSIZE2;
+}
+else {
+    $size = $_GET['size'];
+}
+
+if( empty($_GET['idx']) ) {
+    $idx = 'ecua';
+}
+else {
+    $idx = $_GET['idx'];
+}
+
+
+$flags = new FlagImages($size) ;
+$img = $flags->GetImgByIdx($idx);
+header ("Content-type: image/png");
+ImagePng ($img);
+
+?>
diff --git a/web/classes/jpgraph/Examples/listfontsex1.php b/web/classes/jpgraph/Examples/listfontsex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..15ee50d141963578755cf677eb8ef7258952612e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/listfontsex1.php
@@ -0,0 +1,154 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_canvtools.php');
+
+$width = 700;
+$height = 800;
+$g = new CanvasGraph($width,$height);
+$scale = new CanvasScale($g);
+$scale->Set(0,27,0,85);
+$g->SetMargin(5,6,5,6);
+$g->SetColor('white');
+$g->SetMarginColor("teal");
+$g->InitFrame();
+
+
+$t = new CanvasRectangleText();
+$t->SetFont(FF_ARIAL,FS_NORMAL,16);
+$t->SetFillColor('lemonchiffon2');
+$t->SetFontColor('black');
+$t->Set("\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nTTF Fonts (11pt)",0.5,19.5,26,64.5);
+$t->Stroke($g->img,$scale);
+
+$t->SetFillColor('lemonchiffon3');
+$t->Set("\n\n\n\nBitmap Fonts",0.5,5,26,13.5);
+$t->Stroke($g->img,$scale);
+
+
+$t = new CanvasRectangleText();
+$t->SetFillColor('');
+$t->SetFontColor('black');
+$t->SetColor('');
+$t->SetShadow('');
+
+$t->SetFont(FF_ARIAL,FS_BOLD,18);
+$t->Set('Normal',1,1,8);
+$t->Stroke($g->img,$scale);
+
+$t->Set('Italic style',9,1,8);
+$t->Stroke($g->img,$scale);
+
+$t->Set('Bold style',17.5,1,8);
+$t->Stroke($g->img,$scale);
+
+
+$t->SetFillColor('yellow');
+$t->SetFontColor('black');
+$t->SetColor('black');
+$t->SetShadow('gray');
+
+$r=6;$c=1;$w=7.5;$h=3.5;
+
+$fonts=array(
+    array("Font 0",FF_FONT0,FS_NORMAL),
+    array("",FF_FONT0,FS_ITALIC),
+    array("",FF_FONT0,FS_BOLD),
+
+    array("Font 1",FF_FONT1,FS_NORMAL),
+    array("",FF_FONT1,FS_ITALIC),
+    array("Font 1 bold",FF_FONT1,FS_BOLD),
+
+    array("Font 2",FF_FONT2,FS_NORMAL),
+    array("",FF_FONT2,FS_ITALIC),
+    array("Font 2 bold",FF_FONT2,FS_BOLD),
+
+    array("Arial",FF_ARIAL,FS_NORMAL),
+    array("Arial italic",FF_ARIAL,FS_ITALIC),
+    array("Arial bold",FF_ARIAL,FS_BOLD),
+
+    array("Verdana",FF_VERDANA,FS_NORMAL),
+    array("Verdana italic",FF_VERDANA,FS_ITALIC),
+    array("Verdana bold",FF_VERDANA,FS_BOLD),
+
+
+    array("Trebuche",FF_TREBUCHE,FS_NORMAL),
+    array("Trebuche italic",FF_TREBUCHE,FS_ITALIC),
+    array("Trebuche bold",FF_TREBUCHE,FS_BOLD),
+
+    array("Georgia",FF_GEORGIA,FS_NORMAL),
+    array("Georgia italic",FF_GEORGIA,FS_ITALIC),
+    array("Georgia bold",FF_GEORGIA,FS_BOLD),
+
+    array("Comic",FF_COMIC,FS_NORMAL),
+    array("",FF_COMIC,FS_ITALIC),
+    array("Comic bold",FF_COMIC,FS_BOLD),
+
+    array("Courier",FF_COURIER,FS_NORMAL),
+    array("Courier italic",FF_COURIER,FS_ITALIC),
+    array("Courier bold",FF_COURIER,FS_BOLD),
+
+    array("Times normal",FF_TIMES,FS_NORMAL),
+    array("Times italic",FF_TIMES,FS_ITALIC),
+    array("Times bold",FF_TIMES,FS_BOLD),
+
+    array("Vera normal",FF_VERA,FS_NORMAL),
+    array("Vera italic",FF_VERA,FS_ITALIC),
+    array("Vera bold",FF_VERA,FS_BOLD),    
+    
+    array("Vera mono normal",FF_VERAMONO,FS_NORMAL),
+    array("Vera mono italic",FF_VERAMONO,FS_ITALIC),
+    array("Vera mono bold",FF_VERAMONO,FS_BOLD),    
+
+    array("Vera serif normal",FF_VERASERIF,FS_NORMAL),
+    array("",FF_VERASERIF,FS_ITALIC),
+    array("Vera serif bold",FF_VERASERIF,FS_BOLD),    
+            
+    array("DejaVu sans serif",FF_DV_SANSSERIF,FS_NORMAL),
+    array("DejaVu sans serif",FF_DV_SANSSERIF,FS_ITALIC),
+    array("DejaVu sans serif",FF_DV_SANSSERIF,FS_BOLD),
+
+    array("DejaVu serif",FF_DV_SERIF,FS_NORMAL),
+    array("DejaVu serif",FF_DV_SERIF,FS_ITALIC),
+    array("DejaVu serif",FF_DV_SERIF,FS_BOLD),
+
+    array("DejaVuMono sans serif",FF_DV_SANSSERIFMONO,FS_NORMAL),
+    array("DejaVuMono sans serif",FF_DV_SANSSERIFMONO,FS_ITALIC),
+    array("DejaVuMono sans serif",FF_DV_SANSSERIFMONO,FS_BOLD),
+
+    array("DejaVuCond serif",FF_DV_SERIFCOND,FS_NORMAL),
+    array("DejaVuCond serif",FF_DV_SERIFCOND,FS_ITALIC),
+    array("DejaVuCond serif",FF_DV_SERIFCOND,FS_BOLD),
+
+    array("DejaVuCond sans serif",FF_DV_SANSSERIFCOND,FS_NORMAL),
+    array("DejaVuCond sans serif",FF_DV_SANSSERIFCOND,FS_ITALIC),
+    array("DejaVuCond sans serif",FF_DV_SANSSERIFCOND,FS_BOLD),
+    
+    );
+
+
+$n=count($fonts);
+
+for( $i=0; $i < $n; ++$i ) {
+    
+    if( $i==9 ) $r += 3;
+
+    if( $fonts[$i][0] ) {
+    $t->SetTxt($fonts[$i][0]);
+    $t->SetPos($c,$r,$w,$h);
+    $t->SetFont($fonts[$i][1],$fonts[$i][2],11);
+    $t->Stroke($g->img,$scale);
+    }
+
+    $c += $w+1;
+    if( $c > 30-$w-2 ) {
+    $c = 1;
+    $r += 4;
+    }
+
+}
+
+$g->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/logbarex1.php b/web/classes/jpgraph/Examples/logbarex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..a3a8a901e56792fc35122a4f702752b9072685a2
--- /dev/null
+++ b/web/classes/jpgraph/Examples/logbarex1.php
@@ -0,0 +1,48 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: logbarex1.php,v 1.4 2003/05/30 20:12:43 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_log.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(4,13,30,28,12,45,30,12,55,3,0.5);
+$datax=array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov");
+
+// Create the graph. 
+$graph = new Graph(400,220,'auto');	
+//$graph->img->SetMargin(50,30,50,50);
+$graph->SetScale("textlog");
+//$graph->SetShadow();
+
+// Setup titles for graph and axis
+$graph->title->Set("Bar with logarithmic Y-scale");
+$graph->title->SetFont(FF_VERDANA,FS_NORMAL,18);
+
+$graph->xaxis->SetTitle("2002");
+$graph->xaxis->title->SetFont(FF_ARIAL,FS_NORMAL,16);
+
+$graph->yaxis->title->SetFont(FF_ARIAL,FS_NORMAL,16);
+$graph->yaxis->SetTitle("Y-title",'center');
+$graph->yaxis->SetTitleMargin(30);
+
+// Setup month on X-scale
+//$graph->xaxis->SetTickLabels($datax);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("orange");
+
+//You can also set a manual base of the bars
+//$bplot->SetYBase(0.001);
+
+/*
+$bplot->SetShadow();
+$bplot->value->Show();
+$bplot->value->SetFont(FF_ARIAL,FS_BOLD);
+$bplot->value->SetAngle(45);
+$bplot->value->SetColor("black","darkred");
+*/
+
+$graph->Add($bplot);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/loglogex1.php b/web/classes/jpgraph/Examples/loglogex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..31a4a52ccf0d6717ef9e2a0396c21ba4bc204d6f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/loglogex1.php
@@ -0,0 +1,59 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_log.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+
+$ab2  = array( 1.5,  2.0,  2.5,  3.0,  4.0,  5.0,  6.0,  8.0, 10.0,
+              12.0, 15.0, 20.0, 25.0, 30.0, 40.0, 50.0, 60.0 ,75.0,
+              100., 125., 150.);
+$mn2  = array( 0.5,  0.5,  0.5,  0.5,  0.8,  0.8,  0.8,  0.8,  1.0,
+               1.0,  1.0,  1.0,  1.0,  2.0,  2.0,  2.0,  2.0,  2.0,
+               5.0,  5.0,  5.0);
+$rhos = array(30.0, 31.0, 32.0, 34.0, 35.5, 37.5, 38.0, 39.5, 41.5,
+              43.0, 41.0, 42.0, 42.5, 45.0, 49.0, 53.5, 58.0, 66.5,
+              75.0, 81.0, 89.0);
+
+// Create the graph.
+$graph = new Graph(500,300);     
+$graph->SetScale("loglog");              
+$graph->SetY2Scale("lin");               
+$graph->y2axis->SetColor("blue","blue"); 
+
+$graph->img->SetMargin(50,70,40,50);     
+$graph->title->Set("Geoelektrik");       
+$graph->xaxis->title->Set("Auslage ab/2 [m]");  
+$graph->yaxis->title->Set("rho_s [Ohm m]");     
+$graph->y2axis->title->Set("mn/2 [m]");         
+$graph->y2axis->title->SetColor("blue");
+$graph->y2axis->SetTitleMargin(35);
+$graph->title->SetFont(FF_FONT1,FS_BOLD);       
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD); 
+$graph->xgrid->Show(true,true);                  
+$graph->ygrid->Show(true,true);                  
+
+// Create the linear plot
+
+$lineplot=new LinePlot($rhos,$ab2);       
+$lineplot->SetWeight(1);
+$lineplot->mark->SetType(MARK_FILLEDCIRCLE);
+$lineplot->mark->SetWidth(2);
+
+// Create scatter plot 
+
+$scplot=new ScatterPlot($mn2,$ab2);
+$scplot->mark->SetType(MARK_FILLEDCIRCLE);
+$scplot->mark->SetColor("blue");
+$scplot->mark->SetWidth(2);
+
+// Add plots to the graph
+
+$graph->AddY2($scplot);
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/manscaleex1.php b/web/classes/jpgraph/Examples/manscaleex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..9a7962aaf670bc2e5caf0bd356593b686004a5c3
--- /dev/null
+++ b/web/classes/jpgraph/Examples/manscaleex1.php
@@ -0,0 +1,22 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,17,22,19,5,15);
+
+$graph = new Graph(220,170);
+$graph->SetScale("textlin",3,35);
+$graph->yscale->ticks->Set(8,2);
+
+$graph->title->Set('Manual scale, manual ticks');
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$line = new LinePlot($ydata);
+$graph->Add($line);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/manscaleex2.php b/web/classes/jpgraph/Examples/manscaleex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..d192ed8ffd13df704ccafd55b350a3da1af66f72
--- /dev/null
+++ b/web/classes/jpgraph/Examples/manscaleex2.php
@@ -0,0 +1,21 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,17,22,19,5,15);
+
+$graph = new Graph(220,170);
+$graph->SetScale("textlin",3,35);
+
+$graph->title->Set('Manual scale, exact limits');
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$line = new LinePlot($ydata);
+$graph->Add($line);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/manscaleex3.php b/web/classes/jpgraph/Examples/manscaleex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..2fdcfa283af9028d516620ae1712808a71af24e4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/manscaleex3.php
@@ -0,0 +1,23 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,17,22,19,5,15);
+
+$graph = new Graph(250,170);
+$graph->SetScale("textlin",3,35);
+$graph->SetTickDensity(TICKD_DENSE);
+$graph->yscale->SetAutoTicks();
+
+$graph->title->Set('Manual scale, auto ticks');
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$line = new LinePlot($ydata);
+$graph->Add($line);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/manscaleex4.php b/web/classes/jpgraph/Examples/manscaleex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..4653ede6464dad5ffa121c0cf734e101886647fd
--- /dev/null
+++ b/web/classes/jpgraph/Examples/manscaleex4.php
@@ -0,0 +1,22 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,17,22,19,5,15);
+
+$graph = new Graph(220,200);
+$graph->SetScale("textlin",3,35);
+$graph->yscale->SetAutoTicks();
+
+$graph->title->Set('Manual scale, allow adjustment');
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$line = new LinePlot($ydata);
+$graph->Add($line);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/manual_textscale_ex1.php b/web/classes/jpgraph/Examples/manual_textscale_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..a911c337f6e0ae0a54a6112afad7d77219ef82d5
--- /dev/null
+++ b/web/classes/jpgraph/Examples/manual_textscale_ex1.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+$databary=array(12,7,16,6,7,14,9,3);
+$months=$gDateLocale->GetShortMonth();
+
+// New graph with a drop shadow
+$graph = new Graph(300,200,'auto');
+$graph->SetShadow();
+
+// Use a "text" X-scale
+$graph->SetScale("textlin");
+
+// Specify X-labels
+$graph->xaxis->SetTickLabels($months);
+
+// Set title and subtitle
+$graph->title->Set("Textscale with specified labels");
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Create the bar plot
+$b1 = new BarPlot($databary);
+$b1->SetLegend("Temperature");
+
+//$b1->SetAbsWidth(6);
+//$b1->SetShadow();
+
+// The order the plots are added determines who's ontop
+$graph->Add($b1);
+
+// Finally output the  image
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/manual_textscale_ex2.php b/web/classes/jpgraph/Examples/manual_textscale_ex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..968d9dd22121fe3d0ebd3926a7c876a1629d291b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/manual_textscale_ex2.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+for($i=0; $i < 12; ++$i) {
+    $databary[$i] = rand(1,20);
+}
+$months=$gDateLocale->GetShortMonth();
+
+// New graph with a drop shadow
+$graph = new Graph(300,200);
+$graph->SetShadow();
+
+// Use a "text" X-scale
+$graph->SetScale('textlin');
+
+// Specify X-labels
+$graph->xaxis->SetTickLabels($months);
+$graph->xaxis->SetTextTickInterval(2,0);
+
+// Set title and subtitle
+$graph->title->Set('Textscale with tickinterval=2');
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Create the bar plot
+$b1 = new BarPlot($databary);
+$b1->SetLegend('Temperature');
+
+// The order the plots are added determines who's ontop
+$graph->Add($b1);
+
+// Finally output the  image
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/manual_textscale_ex3.php b/web/classes/jpgraph/Examples/manual_textscale_ex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..18d718cf82467bdb67701aa9ff58a01231a32ea9
--- /dev/null
+++ b/web/classes/jpgraph/Examples/manual_textscale_ex3.php
@@ -0,0 +1,40 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+// Some data
+for($i=0; $i < 12; ++$i) {
+    $databary[$i] = rand(1,20);
+}
+$months=$gDateLocale->GetShortMonth();
+
+// New graph with a drop shadow
+$graph = new Graph(300,200);
+$graph->SetShadow();
+
+// Use a "text" X-scale
+$graph->SetScale('textlin');
+
+// Specify X-labels
+$graph->xaxis->SetTickLabels($months);
+$graph->xaxis->SetTextLabelInterval(2);
+
+// Set title and subtitle
+$graph->title->Set('Textscale with tickinterval=2');
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Create the bar plot
+$b1 = new BarPlot($databary);
+$b1->SetLegend('Temperature');
+
+// The order the plots are added determines who's ontop
+$graph->Add($b1);
+
+// Finally output the  image
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/manual_textscale_ex4.php b/web/classes/jpgraph/Examples/manual_textscale_ex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..99146faf77cf941445a98b070dcd91ff199005d9
--- /dev/null
+++ b/web/classes/jpgraph/Examples/manual_textscale_ex4.php
@@ -0,0 +1,51 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+define('DATAPERMONTH',40);
+
+// Some data
+$m=$gDateLocale->GetShortMonth();
+$k=0;
+for($i=0; $i < 480; ++$i) {
+    $datay[$i] = rand(1,40);
+    if( $i % DATAPERMONTH === 0 )
+        $months[$i] = $m[(int)($i/DATAPERMONTH)];
+    else
+        $months[$i] = 'xx';
+}
+
+
+// New graph with a drop shadow
+$graph = new Graph(400,200);
+//$graph->SetShadow();
+
+// Use a "text" X-scale
+$graph->SetScale('textlin');
+
+// Specify X-labels
+$graph->xaxis->SetTickLabels($months);
+$graph->xaxis->SetTextTickInterval(DATAPERMONTH,0);
+$graph->xaxis->SetTextLabelInterval(2);
+
+// Set title and subtitle
+$graph->title->Set('Textscale with tickinterval=2');
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$graph->SetBox(true,'red');
+
+// Create the bar plot
+$lp1 = new LinePlot($datay);
+$lp1->SetLegend('Temperature');
+
+// The order the plots are added determines who's ontop
+$graph->Add($lp1);
+
+// Finally output the  image
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/manualtickex1.php b/web/classes/jpgraph/Examples/manualtickex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..47d0b8d2c9f26917a2e5290c3f129b83af8b527e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/manualtickex1.php
@@ -0,0 +1,73 @@
+<?php // content="text/plain; charset=utf-8"
+//
+// Basic example on how to use custom tickmark feature to have a label
+// at the start of each month.
+//
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_utils.inc.php');
+
+// 
+// Create some random data for the plot. We use the current time for the
+// first X-position
+//
+$datay = array();
+$datax = array();
+$ts = time();
+$n=15; // Number of data points
+for($i=0; $i < $n; ++$i ) {
+    $datax[$i] = $ts+$i*700000; 
+    $datay[$i] = rand(5,60);
+}
+
+// Now get labels at the start of each month
+$dateUtils = new DateScaleUtils();
+list($tickPositions,$minTickPositions) = $dateUtils->GetTicks($datax);
+
+// We add some grace to the end of the X-axis scale so that the first and last
+// data point isn't exactly at the very end or beginning of the scale
+$grace = 400000;
+$xmin = $datax[0]-$grace;
+$xmax = $datax[$n-1]+$grace;
+
+//
+// The code to setup a very basic graph
+//
+$graph = new Graph(400,200);
+
+//
+// We use an integer scale on the X-axis since the positions on the X axis
+// are assumed to be UNI timestamps
+$graph->SetScale('intlin',0,0,$xmin,$xmax);
+$graph->title->Set('Basic example with manual ticks');
+$graph->title->SetFont(FF_ARIAL,FS_NORMAL,12);
+
+//
+// Make sure that the X-axis is always at the bottom of the scale
+// (By default the X-axis is alwys positioned at Y=0 so if the scale
+// doesn't happen to include 0 the axis will not be shown)
+$graph->xaxis->SetPos('min');
+
+// Now set the tic positions
+$graph->xaxis->SetTickPositions($tickPositions,$minTickPositions);
+
+// The labels should be formatted at dates with "Year-month"
+$graph->xaxis->SetLabelFormatString('My',true);
+
+// Use Ariel font
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+
+// Add a X-grid
+$graph->xgrid->Show();
+
+// Create the plot line
+$p1 = new LinePlot($datay,$datax);
+$p1->SetColor('teal');
+$graph->Add($p1);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/manualtickex1a.php b/web/classes/jpgraph/Examples/manualtickex1a.php
new file mode 100755
index 0000000000000000000000000000000000000000..47d0b8d2c9f26917a2e5290c3f129b83af8b527e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/manualtickex1a.php
@@ -0,0 +1,73 @@
+<?php // content="text/plain; charset=utf-8"
+//
+// Basic example on how to use custom tickmark feature to have a label
+// at the start of each month.
+//
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_utils.inc.php');
+
+// 
+// Create some random data for the plot. We use the current time for the
+// first X-position
+//
+$datay = array();
+$datax = array();
+$ts = time();
+$n=15; // Number of data points
+for($i=0; $i < $n; ++$i ) {
+    $datax[$i] = $ts+$i*700000; 
+    $datay[$i] = rand(5,60);
+}
+
+// Now get labels at the start of each month
+$dateUtils = new DateScaleUtils();
+list($tickPositions,$minTickPositions) = $dateUtils->GetTicks($datax);
+
+// We add some grace to the end of the X-axis scale so that the first and last
+// data point isn't exactly at the very end or beginning of the scale
+$grace = 400000;
+$xmin = $datax[0]-$grace;
+$xmax = $datax[$n-1]+$grace;
+
+//
+// The code to setup a very basic graph
+//
+$graph = new Graph(400,200);
+
+//
+// We use an integer scale on the X-axis since the positions on the X axis
+// are assumed to be UNI timestamps
+$graph->SetScale('intlin',0,0,$xmin,$xmax);
+$graph->title->Set('Basic example with manual ticks');
+$graph->title->SetFont(FF_ARIAL,FS_NORMAL,12);
+
+//
+// Make sure that the X-axis is always at the bottom of the scale
+// (By default the X-axis is alwys positioned at Y=0 so if the scale
+// doesn't happen to include 0 the axis will not be shown)
+$graph->xaxis->SetPos('min');
+
+// Now set the tic positions
+$graph->xaxis->SetTickPositions($tickPositions,$minTickPositions);
+
+// The labels should be formatted at dates with "Year-month"
+$graph->xaxis->SetLabelFormatString('My',true);
+
+// Use Ariel font
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,9);
+
+// Add a X-grid
+$graph->xgrid->Show();
+
+// Create the plot line
+$p1 = new LinePlot($datay,$datax);
+$p1->SetColor('teal');
+$graph->Add($p1);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/manualtickex2.php b/web/classes/jpgraph/Examples/manualtickex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..abd7e10150df6e9443170aadde659b2619eb6104
--- /dev/null
+++ b/web/classes/jpgraph/Examples/manualtickex2.php
@@ -0,0 +1,72 @@
+<?php // content="text/plain; charset=utf-8"
+//
+// Basic example on how to use custom tickmark feature to have a label
+// at the start of each month.
+//
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_utils.inc.php');
+
+// 
+// Create some random data for the plot. We use the current time for the
+// first X-position
+//
+$f = new FuncGenerator('cos($x)+1.5*cos(2*$x)');
+list($datax,$datay) = $f->E(0,10);
+
+// Now get labels at 1/2 PI intervall
+$tickPositions = array();
+$tickLabels = array();
+$tickPositions[0] = 0;
+$tickLabels[0] = '0';
+for($i=1; $i/2*M_PI < 11 ; ++$i ) {
+    $tickPositions[$i] = $i/2*M_PI;
+    if( $i % 2 )
+	$tickLabels[$i] = $i.'/2'.SymChar::Get('pi');
+    else
+	$tickLabels[$i] = ($i/2).SymChar::Get('pi');
+}
+
+$n = count($datax);
+$xmin = $datax[0];
+$xmax = $datax[$n-1];
+
+//
+// The code to setup a very basic graph
+//
+$graph = new Graph(400,200);
+
+//
+// We use an integer scale on the X-axis since the positions on the X axis
+// are assumed to be UNI timestamps
+$graph->SetScale('linlin',0,0,$xmin,$xmax);
+$graph->title->Set('Example with manual tick labels');
+$graph->title->SetFont(FF_ARIAL,FS_NORMAL,12);
+
+//
+// Make sure that the X-axis is always at the bottom of the scale
+// (By default the X-axis is alwys positioned at Y=0 so if the scale
+// doesn't happen to include 0 the axis will not be shown)
+$graph->xaxis->SetPos('min');
+
+// Now set the tic positions
+$graph->xaxis->SetMajTickPositions($tickPositions,$tickLabels);
+
+// Use Times font
+$graph->xaxis->SetFont(FF_TIMES,FS_NORMAL,10);
+$graph->yaxis->SetFont(FF_TIMES,FS_NORMAL,10);
+
+// Add a X-grid
+$graph->xgrid->Show();
+
+// Create the plot line
+$p1 = new LinePlot($datay,$datax);
+$p1->SetColor('teal');
+$graph->Add($p1);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/manualtickex3.php b/web/classes/jpgraph/Examples/manualtickex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..0bd03ceadc301c2dd6cf5052fdbe7659a4eb40e8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/manualtickex3.php
@@ -0,0 +1,91 @@
+<?php // content="text/plain; charset=utf-8"
+//
+// Basic example on how to use custom tickmark feature to have a label
+// at the start of each month.
+//
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_utils.inc.php');
+
+// 
+// Create some random data for the plot. We use the current time for the
+// first X-position
+//
+$f = new FuncGenerator('cos($x)+1.5*cos(2*$x)');
+list($datax,$datay) = $f->E(0,10);
+
+// Now get labels at 1/2 PI intervall
+$tickPositions = array();
+$tickLabels = array();
+$tickPositions[0] = 0;
+$tickLabels[0] = '0';
+for($i=1; $i/2*M_PI < 11 ; ++$i ) {
+    $tickPositions[$i] = $i/2*M_PI;
+    if( $i % 2 )
+	$tickLabels[$i] = $i.'/2'.SymChar::Get('pi');
+    else
+	$tickLabels[$i] = ($i/2).SymChar::Get('pi');
+}
+
+$n = count($datax);
+$xmin = $datax[0];
+$xmax = $datax[$n-1];
+
+//
+// The code to setup a very basic graph
+//
+$graph = new Graph(400,200);
+
+// We use an integer scale on the X-axis since the positions on the X axis
+// are assumed to be UNI timestamps
+$graph->SetScale('linlin',0,0,$xmin,$xmax);
+$graph->title->Set('Example with manual tick labels');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->title->SetColor('white');
+
+// Setup a abackground gradient
+$graph->SetBackgroundGradient('darkred:0.7', 'black', 2, BGRAD_MARGIN);
+$graph->SetPlotGradient('black','darkred:0.8', 2);
+
+// Make sure that the X-axis is always at the bottom of the scale
+// (By default the X-axis is alwys positioned at Y=0 so if the scale
+// doesn't happen to include 0 the axis will not be shown)
+$graph->xaxis->SetPos('min');
+
+// Now set the tic positions
+$graph->xaxis->SetMajTickPositions($tickPositions,$tickLabels);
+
+// Use Times font
+$graph->xaxis->SetFont(FF_TIMES,FS_NORMAL,11);
+$graph->yaxis->SetFont(FF_TIMES,FS_NORMAL,9);
+
+// Set colors for axis
+$graph->xaxis->SetColor('lightgray');
+$graph->yaxis->SetColor('lightgray');
+
+// Add a X-grid
+$graph->xgrid->Show();
+
+// Show ticks outwards
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+$graph->xaxis->SetLabelMargin(8);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+
+// Setup a filled y-grid
+//$graph->ygrid->SetFill(true,'darkgray:1.55@0.7','darkgray:1.6@0.7');
+$graph->ygrid->SetStyle('dotted');
+$graph->xgrid->SetStyle('dashed');
+
+// Create the plot line
+$p1 = new LinePlot($datay,$datax);
+$p1->SetWeight(2);
+$p1->SetColor('orange:0.9');
+$p1->SetFillColor('white@0.7');
+$graph->Add($p1);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/manualtickex4.php b/web/classes/jpgraph/Examples/manualtickex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..f4a80e675001387e99305ebb984c44863917a65f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/manualtickex4.php
@@ -0,0 +1,92 @@
+<?php // content="text/plain; charset=utf-8"
+//
+// Basic example on how to use custom tickmark feature to have a label
+// at the start of each month.
+//
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_utils.inc.php');
+
+// 
+// Create some random data for the plot. We use the current time for the
+// first X-position
+//
+$f = new FuncGenerator('cos($x)+1.5*cos(2*$x)');
+list($datax,$datay) = $f->E(0,10);
+
+// Now get labels at 1/2 PI intervall
+$tickPositions = array();
+$tickLabels = array();
+$tickPositions[0] = 0;
+$tickLabels[0] = '0';
+for($i=1; $i/2*M_PI < 11 ; ++$i ) {
+    $tickPositions[$i] = $i/2*M_PI;
+    if( $i % 2 )
+	$tickLabels[$i] = $i.'/2'.SymChar::Get('pi');
+    else
+	$tickLabels[$i] = ($i/2).SymChar::Get('pi');
+}
+
+$n = count($datax);
+$xmin = $datax[0];
+$xmax = $datax[$n-1];
+
+//
+// The code to setup a very basic graph
+//
+$graph = new Graph(400,200);
+
+// We use an integer scale on the X-axis since the positions on the X axis
+// are assumed to be UNI timestamps
+$graph->SetScale('linlin',0,0,$xmin,$xmax);
+$graph->title->Set('Example with manual tick labels');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->title->SetColor('white');
+
+// Setup a abackground gradient
+$graph->SetBackgroundGradient('darkred:0.7', 'black', 2, BGRAD_MARGIN);
+$graph->SetPlotGradient('black','darkred:0.8', 2);
+
+// Make sure that the X-axis is always at the bottom of the scale
+// (By default the X-axis is alwys positioned at Y=0 so if the scale
+// doesn't happen to include 0 the axis will not be shown)
+$graph->xaxis->SetPos('min');
+
+// Now set the tic positions
+$graph->xaxis->SetMajTickPositions($tickPositions,$tickLabels);
+
+// Use Times font
+$graph->xaxis->SetFont(FF_TIMES,FS_NORMAL,11);
+$graph->yaxis->SetFont(FF_TIMES,FS_NORMAL,9);
+
+// Set colors for axis
+$graph->xaxis->SetColor('lightgray');
+$graph->yaxis->SetColor('lightgray');
+
+// Add a X-grid
+$graph->xgrid->Show();
+
+// Show ticks outwards
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+$graph->xaxis->SetLabelMargin(8);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+
+// Setup a filled y-grid
+//$graph->ygrid->SetFill(true,'darkgray:1.55@0.7','darkgray:1.6@0.7');
+$graph->ygrid->SetStyle('dotted');
+$graph->xgrid->SetStyle('dashed');
+
+// Create the plot line
+$p1 = new LinePlot($datay,$datax);
+$p1->SetWeight(2);
+$p1->SetColor('orange:0.9');
+$p1->SetFillColor('white@0.7');
+$p1->SetFillFromYMin();
+$graph->Add($p1);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/markflagex1.php b/web/classes/jpgraph/Examples/markflagex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..576134e266e974457a6a01ebdc0e10197cccf9da
--- /dev/null
+++ b/web/classes/jpgraph/Examples/markflagex1.php
@@ -0,0 +1,74 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+$datay = array(
+    array(4,26,15,44),
+    array(20,51,32,20));
+
+// Setup the graph
+$graph = new Graph(300,200);
+$graph->SetMarginColor('white');
+$graph->SetScale("textlin");
+$graph->SetFrame(false);
+$graph->SetMargin(30,5,25,20);
+
+// Enable X-grid as well
+$graph->xgrid->Show();
+
+// Use months as X-labels
+$graph->xaxis->SetTickLabels($gDateLocale->GetShortMonth());
+
+//------------------------
+// Create the plots
+//------------------------
+$p1 = new LinePlot($datay[0]);
+$p1->SetColor("navy");
+
+// Use a flag
+$p1->mark->SetType(MARK_FLAG1,197);
+
+// Displayes value on top of marker image
+$p1->value->SetFormat('%d mil');
+$p1->value->Show();
+$p1->value->SetColor('darkred');
+$p1->value->SetFont(FF_ARIAL,FS_BOLD,10);
+// Increase the margin so that the value is printed avove tje
+// img marker
+$p1->value->SetMargin(14);
+
+// Incent the X-scale so the first and last point doesn't
+// fall on the edges
+$p1->SetCenter();
+
+$graph->Add($p1);
+
+//------------
+// 2:nd plot
+//------------
+$p2 = new LinePlot($datay[1]);
+$p2->SetColor("navy");
+
+// Use a flag
+$p2->mark->SetType(MARK_FLAG1,'united states');
+
+// Displayes value on top of marker image
+$p2->value->SetFormat('%d mil');
+$p2->value->Show();
+$p2->value->SetColor('darkred');
+$p2->value->SetFont(FF_ARIAL,FS_BOLD,10);
+// Increase the margin so that the value is printed avove tje
+// img marker
+$p2->value->SetMargin(14);
+
+// Incent the X-scale so the first and last point doesn't
+// fall on the edges
+$p2->SetCenter();
+$graph->Add($p2);
+
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/matrix_csimex01.php b/web/classes/jpgraph/Examples/matrix_csimex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..76bb0a1e734fcc4eb8cf2ff767cc27aeb220d736
--- /dev/null
+++ b/web/classes/jpgraph/Examples/matrix_csimex01.php
@@ -0,0 +1,76 @@
+<?php // content="text/plain; charset=utf-8"
+require_once('jpgraph/jpgraph.php');
+require_once('jpgraph/jpgraph_matrix.php');
+
+
+$data = array(
+	array(0,null,2,3,4,5,6,7,8,9,10,8,6,4,2),
+	array(10,9,8,7,6,5,4,3,2,1,0,8,5,9,2),
+	array(0,1,2,3,4,5,6,7,8,9,10,2,4,5,7),
+	array(10,9,8,17,6,5,4,3,2,1,0,8,6,4,2),
+	array(0,1,2,3,4,4,9,7,8,9,10,3,2,7,2),
+	array(8,1,2,3,4,8,3,7,8,9,10,5,3,9,1),
+	array(10,3,5,7,6,5,4,3,12,1,0,6,5,10,2),
+	array(10,9,8,7,6,5,4,3,2,1,NULL,8,6,4,2),
+);
+
+$nx = count($data[0]);
+$ny = count($data);
+
+for( $i=0; $i < $ny; ++$i ) {
+    for( $j=0; $j < $nx; ++$j ) {
+        $csimtargets[$i][$j] = '#'.sprintf('%02sd',$i)."-".sprintf('%02sd',$j);
+    }
+}
+
+
+for($i=0; $i < $nx; ++$i ) {
+    $collabels[$i] = sprintf('column label: %02d',$i);
+    $collabeltargets[$i] = '#'.sprintf('collabel: %02d',$i);
+
+}
+for($i=0; $i < $ny; ++$i ) {
+    $rowlabels[$i] = sprintf('row label: %02d',$i);
+    $rowlabeltargets[$i] = '#'.sprintf('rowlabel: %02d',$i);
+}
+
+// Setup a nasic matrix graph
+$graph = new MatrixGraph(400,350);
+
+$graph->SetBackgroundGradient('lightsteelblue:0.8','lightsteelblue:0.3');
+$graph->title->Set('CSIM with matrix');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,16);
+$graph->title->SetColor('white');
+
+// Create one matrix plot
+$mp = new MatrixPlot($data,1);
+$mp->SetModuleSize(13,15);
+$mp->SetCenterPos(0.35,0.6);
+$mp->colormap->SetNullColor('gray');
+
+// Setup column lablels
+$mp->collabel->Set($collabels);
+$mp->collabel->SetSide('top');
+$mp->collabel->SetFont(FF_ARIAL,FS_NORMAL,8);
+$mp->collabel->SetFontColor('lightgray');
+
+// Setup row lablels
+$mp->rowlabel->Set($rowlabels);
+$mp->rowlabel->SetSide('right');
+$mp->rowlabel->SetFont(FF_ARIAL,FS_NORMAL,8);
+$mp->rowlabel->SetFontColor('lightgray');
+
+$mp->rowlabel->SetCSIMTargets($rowlabeltargets);
+$mp->collabel->SetCSIMTargets($collabeltargets);
+
+// Move the legend more to the right
+$mp->legend->SetMargin(90);
+$mp->legend->SetColor('white');
+$mp->legend->SetFont(FF_VERDANA,FS_BOLD,10);
+
+$mp->SetCSIMTargets($csimtargets);
+
+$graph->Add($mp);
+$graph->StrokeCSIM();
+
+?>
diff --git a/web/classes/jpgraph/Examples/matrix_edgeex01.php b/web/classes/jpgraph/Examples/matrix_edgeex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..e66fd77a3691bad8d20072c907e4caafc31a0162
--- /dev/null
+++ b/web/classes/jpgraph/Examples/matrix_edgeex01.php
@@ -0,0 +1,53 @@
+<?php // content="text/plain; charset=utf-8"
+require_once('jpgraph/jpgraph.php');
+require_once('jpgraph/jpgraph_matrix.php');
+
+$data = array(
+	array(0,null,2,3,4,5,6,7,8,9,10,8,6,4,2),
+	array(10,9,8,7,6,5,4,3,2,1,0,8,5,9,2),
+	array(0,1,2,3,4,5,6,7,8,9,10,2,4,5,7),
+	array(10,9,8,17,6,5,4,3,2,1,0,8,6,4,2),
+	array(0,1,2,3,4,4,9,7,8,9,10,3,2,7,2),
+	array(8,1,2,3,4,8,3,7,8,9,10,5,3,9,1),
+	array(10,3,5,7,6,5,4,3,12,1,0,6,5,10,2),
+	array(10,9,8,7,6,5,4,3,2,1,NULL,8,6,4,2),
+);
+
+for($i=0; $i < count($data[0]); ++$i ) {
+    $xlabels[$i] = sprintf('xlabel: %02d',$i);
+}
+for($i=0; $i < count($data); ++$i ) {
+    $ylabels[$i] = sprintf('ylabel: %02d',$i);
+}
+
+// Setup a nasic matrix graph
+$graph = new MatrixGraph(400,250);
+$graph->SetMarginColor('white');
+$graph->title->Set('Adding labels on the edges');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+// Create one matrix plot
+$mp = new MatrixPlot($data,1);
+$mp->SetModuleSize(13,15);
+$mp->SetCenterPos(0.35,0.45);
+$mp->colormap->SetNullColor('gray');
+
+// Setup column lablels
+$mp->collabel->Set($xlabels);
+$mp->collabel->SetSide('bottom');
+$mp->collabel->SetFont(FF_ARIAL,FS_NORMAL,8);
+$mp->collabel->SetFontColor('darkgray');
+
+// Setup row lablels
+$mp->rowlabel->Set($ylabels);
+$mp->rowlabel->SetSide('right');
+$mp->rowlabel->SetFont(FF_ARIAL,FS_NORMAL,8);
+$mp->rowlabel->SetFontColor('darkgray');
+
+// Move the legend more to the right
+$mp->legend->SetMargin(90);
+
+$graph->Add($mp);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/matrix_edgeex02.php b/web/classes/jpgraph/Examples/matrix_edgeex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..c07ba6a174236392d86bc8915cbe9f9c5f4c769c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/matrix_edgeex02.php
@@ -0,0 +1,51 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_matrix.php');
+require_once ('jpgraph/jpgraph_iconplot.php');
+
+$data = array(
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,17,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,4,9,7,8,9,10),
+	array(8,1,2,3,4,8,3,7,8,9,10),
+	array(10,3,5,7,6,5,4,3,12,1,0),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+);
+
+$nrow = count($data); $ncol = count($data[0]);
+
+$width=350; $height=300;
+$graph = new MatrixGraph($width,$height);
+$graph->title->Set('Add ine row/col labels');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+$mp = new MatrixPlot($data,1);
+$mp->SetSize(0.55);
+$mp->SetCenterPos(0.45, 0.45);
+
+$rowtitles = array();
+for( $i=0; $i < $nrow; ++$i ) {
+    $rowtitles[$i] = sprintf('Row: %02d',$i);
+}
+$coltitles = array();
+for( $i=0; $i < $ncol; ++$i ) {
+    $coltitles[$i] = sprintf('Col: %02d',$i);
+}
+
+$mp->rowlabel->Set($rowtitles);
+$mp->rowlabel->SetFont(FF_ARIAL,FS_NORMAL,10);
+$mp->rowlabel->SetFontColor('blue');
+$mp->rowlabel->SetSide('left');
+
+$mp->collabel->Set($coltitles);
+$mp->collabel->SetFont(FF_ARIAL,FS_NORMAL,10);
+$mp->collabel->SetFontColor('darkred');
+$mp->collabel->SetAngle(70); // 90 is default for col titles
+$mp->collabel->SetSide('bottom');
+
+$graph->Add($mp);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/matrix_ex0.php b/web/classes/jpgraph/Examples/matrix_ex0.php
new file mode 100755
index 0000000000000000000000000000000000000000..43777cf8985f9c75422eaa72355fa16003bf1700
--- /dev/null
+++ b/web/classes/jpgraph/Examples/matrix_ex0.php
@@ -0,0 +1,28 @@
+<?php
+require_once('jpgraph/jpgraph.php');
+require_once('jpgraph/jpgraph_matrix.php');
+
+// Some (random) matrix
+$data = array(
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,17,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,4,9,7,8,9,10),
+	array(8,1,2,3,4,8,3,7,8,9,10),
+	array(10,3,5,7,6,5,4,3,12,1,0),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+);
+
+// Setup a bsic matrix graph and title
+$graph = new MatrixGraph(400,300);
+$graph->title->Set('Basic matrix example');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+// Create a ,atrix plot using all default values
+$mp = new MatrixPlot($data);
+$graph->Add($mp);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/matrix_ex01.php b/web/classes/jpgraph/Examples/matrix_ex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..d0387dd1bc96afbb0e80c137392ce329f7defcc8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/matrix_ex01.php
@@ -0,0 +1,38 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_matrix.php');
+
+$data = array(
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,17,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,4,9,7,8,9,10),
+	array(8,1,2,3,4,8,3,7,8,9,10),
+	array(10,3,5,7,6,5,4,3,12,1,0),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+);
+
+// Do the meshinterpolation once for the data
+doMeshInterpolate($data,3);
+
+$graph = new MatrixGraph(550,500);
+$graph->title->Set('Possible legend positions');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+$mp = array();
+$n = 4;
+$pos = array(0.3,0.33, 0.8,0.68, 
+			 0.3,0.68, 0.8,0.33);
+for($i=0; $i < $n; ++$i){
+    $mp[$i] = new MatrixPlot($data);
+    $mp[$i]->colormap->SetMap($i);
+	$mp[$i]->SetModuleSize(4,5);
+	$mp[$i]->SetLegendLayout($i);
+	$mp[$i]->SetCenterPos($pos[$i*2],$pos[$i*2+1]);
+}
+
+$graph->Add($mp);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/matrix_ex02.php b/web/classes/jpgraph/Examples/matrix_ex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..f81e59cd54078bc80c7103b49a4197fac74ea0af
--- /dev/null
+++ b/web/classes/jpgraph/Examples/matrix_ex02.php
@@ -0,0 +1,32 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_matrix.php');
+
+$data = array(
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,17,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,4,9,7,8,9,10),
+	array(8,1,2,3,4,8,3,7,8,9,10),
+	array(10,3,5,7,6,5,4,3,12,1,0),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+);
+
+// Do the meshinterpolation once for the data
+doMeshInterpolate($data,3);
+$r=count($data);$c=count($data[0]);
+
+$graph = new MatrixGraph(250,220);
+$graph->title->Set('Meshinterpolation=3');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+$mp = new MatrixPlot($data,1);
+$mp->colormap->SetMap(0);
+$mp->SetSize(200,160);
+$mp->SetCenterPos(0.5,0.55);
+$mp->legend->Show(false);
+$graph->Add($mp);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/matrix_ex03.php b/web/classes/jpgraph/Examples/matrix_ex03.php
new file mode 100755
index 0000000000000000000000000000000000000000..a943acd0fb9353345fdae2aa5b521e0a3721587d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/matrix_ex03.php
@@ -0,0 +1,36 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_matrix.php');
+require_once ('jpgraph/jpgraph_iconplot.php');
+
+$data = array(
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,17,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,4,9,7,8,9,10),
+	array(8,1,2,3,4,8,3,7,8,9,10),
+	array(10,3,5,7,6,5,4,3,12,1,0),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+);
+
+// Do the meshinterpolation once for the data
+doMeshInterpolate($data,3);
+$r=count($data);$c=count($data[0]);
+
+$width=400; $height=400;
+$graph = new MatrixGraph($width,$height);
+$graph->title->Set('Adding an icon to the background');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+$mp = new MatrixPlot($data,1);
+$mp->SetSize(0.6);
+
+$icon = new IconPlot('icon.jpg',$width-1,$height-1,0.8,50);
+$icon->SetAnchor('right','bottom');
+$graph->Add($icon);
+
+$graph->Add($mp);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/matrix_ex04.1.php b/web/classes/jpgraph/Examples/matrix_ex04.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..419a437a3e952cf1c25eb3e241907cb66a1d0575
--- /dev/null
+++ b/web/classes/jpgraph/Examples/matrix_ex04.1.php
@@ -0,0 +1,40 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_matrix.php');
+require_once ('jpgraph/jpgraph_iconplot.php');
+
+$data = array(
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,17,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,4,9,7,8,9,10),
+	array(8,1,2,3,4,8,3,7,8,9,10),
+	array(10,3,5,7,6,5,4,3,12,1,0),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+);
+
+// Do the meshinterpolation once for the data
+doMeshInterpolate($data,4);
+$r=count($data);$c=count($data[0]);
+
+$width=300; $height=300;
+$graph = new MatrixGraph($width,$height);
+$graph->title->Set('Adding a background image');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph->subtitle->Set('Alphablending = 0.2');
+
+// Add a stretched background image
+$graph->SetBackgroundImage('ironrod.jpg',BGIMG_FILLFRAME);
+$graph->SetBackgroundImageMix(50);
+
+$mp = new MatrixPlot($data,1);
+$mp->SetSize(0.65);
+$mp->SetCenterPos(0.5,0.5);
+$mp->SetLegendLayout(1);
+$mp->SetAlpha(0.2);
+
+$graph->Add($mp);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/matrix_ex04.2.php b/web/classes/jpgraph/Examples/matrix_ex04.2.php
new file mode 100755
index 0000000000000000000000000000000000000000..6650444cf4c50d94a01ed7b4cbd0ca4ce20264db
--- /dev/null
+++ b/web/classes/jpgraph/Examples/matrix_ex04.2.php
@@ -0,0 +1,40 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_matrix.php');
+require_once ('jpgraph/jpgraph_iconplot.php');
+
+$data = array(
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,17,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,4,9,7,8,9,10),
+	array(8,1,2,3,4,8,3,7,8,9,10),
+	array(10,3,5,7,6,5,4,3,12,1,0),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+);
+
+// Do the meshinterpolation once for the data
+doMeshInterpolate($data,4);
+$r=count($data);$c=count($data[0]);
+
+$width=300; $height=300;
+$graph = new MatrixGraph($width,$height);
+$graph->title->Set('Adding a background image');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph->subtitle->Set('Alphablending = 0.7');
+
+// Add a stretched background image
+$graph->SetBackgroundImage('ironrod.jpg',BGIMG_FILLFRAME);
+$graph->SetBackgroundImageMix(50);
+
+$mp = new MatrixPlot($data,1);
+$mp->SetSize(0.65);
+$mp->SetCenterPos(0.5,0.5);
+$mp->SetLegendLayout(1);
+$mp->SetAlpha(0.7);
+
+$graph->Add($mp);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/matrix_ex04.php b/web/classes/jpgraph/Examples/matrix_ex04.php
new file mode 100755
index 0000000000000000000000000000000000000000..2917f15c188b5223df1d5ea40e568d2ce4c1ec6b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/matrix_ex04.php
@@ -0,0 +1,38 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_matrix.php');
+require_once ('jpgraph/jpgraph_iconplot.php');
+
+$data = array(
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,17,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,4,9,7,8,9,10),
+	array(8,1,2,3,4,8,3,7,8,9,10),
+	array(10,3,5,7,6,5,4,3,12,1,0),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+);
+
+// Do the meshinterpolation once for the data
+doMeshInterpolate($data,4);
+$r=count($data);$c=count($data[0]);
+
+$width=400; $height=400;
+$graph = new MatrixGraph($width,$height);
+$graph->title->Set('Adding a background image');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+// Add a stretched background image
+$graph->SetBackgroundImage('ironrod.jpg',BGIMG_FILLFRAME);
+$graph->SetBackgroundImageMix(50);
+
+$mp = new MatrixPlot($data,1);
+$mp->SetSize(0.6);
+$mp->SetCenterPos(0.5,0.5);
+$mp->SetLegendLayout(1);
+
+$graph->Add($mp);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/matrix_ex05.php b/web/classes/jpgraph/Examples/matrix_ex05.php
new file mode 100755
index 0000000000000000000000000000000000000000..d3f989eac31583c1773784e04bdd7c52ddb2a315
--- /dev/null
+++ b/web/classes/jpgraph/Examples/matrix_ex05.php
@@ -0,0 +1,31 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_matrix.php');
+
+$data = array(
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,5,6,7,8,9,10),
+	array(10,9,8,17,6,5,4,3,2,1,0),
+	array(0,1,2,3,4,4,9,7,8,9,10),
+	array(8,1,2,3,4,8,3,7,8,9,10),
+	array(10,3,5,7,6,5,4,3,12,1,0),
+	array(10,9,8,7,6,5,4,3,2,1,0),
+);
+
+$width=400; $height=350;
+$graph = new MatrixGraph($width,$height);
+$graph->title->Set('Using a circular module type');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+$mp = new MatrixPlot($data,2);
+$mp->SetSize(0.85);
+$mp->SetModuleType(1);
+$mp->SetBackgroundColor('teal:1.8');
+$mp->SetCenterPos(0.5,0.45);
+$mp->SetLegendLayout(1);
+
+$graph->Add($mp);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/matrix_ex06.php b/web/classes/jpgraph/Examples/matrix_ex06.php
new file mode 100755
index 0000000000000000000000000000000000000000..7c3d472748e188d3b5d2ce22aa517c6c9fafec85
--- /dev/null
+++ b/web/classes/jpgraph/Examples/matrix_ex06.php
@@ -0,0 +1,75 @@
+<?php // content="text/plain; charset=utf-8"
+require_once('jpgraph/jpgraph.php');
+require_once('jpgraph/jpgraph_matrix.php');
+require_once('jpgraph/jpgraph_plotline.php');
+
+
+$data = array(
+        array(0,null,2,3,4,5,6,7,8,9,10,8,6,4,2),
+        array(10,9,8,7,6,5,4,3,2,1,0,8,5,9,2),
+        array(0,1,2,3,4,5,6,7,8,9,10,2,4,5,7),
+        array(10,9,8,17,6,5,4,3,2,1,0,8,6,4,2),
+        array(0,1,2,3,4,4,9,7,8,9,10,3,2,7,2),
+        array(8,1,2,3,4,8,3,7,8,9,10,5,3,9,1),
+        array(10,3,5,7,6,5,4,3,12,1,0,6,5,10,2),
+        array(10,9,8,7,6,5,4,3,2,1,NULL,8,6,4,2),
+);
+
+$nx = count($data[0]);
+$ny = count($data);
+
+
+
+for($i=0; $i < $nx; ++$i ) {
+    $collabels[$i] = sprintf('column label: %02d',$i);
+
+}
+for($i=0; $i < $ny; ++$i ) {
+    $rowlabels[$i] = sprintf('row label: %02d',$i);
+ }
+
+// Setup a nasic matrix graph
+$graph = new MatrixGraph(400,350);
+
+$graph->SetBackgroundGradient('lightsteelblue:0.8','lightsteelblue:0.3');
+$graph->title->Set('Matrix with lines');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,18);
+$graph->title->SetColor('white');
+
+// Create two lines to add as markers
+$l1 = new PlotLine(VERTICAL, 5, 'lightgray:1.5', 4);
+$l2 = new PlotLine(HORIZONTAL, 3, 'lightgray:1.5', 4);
+
+// Create one matrix plot
+$mp = new MatrixPlot($data,1);
+$mp->SetModuleSize(13,15);
+$mp->SetCenterPos(0.35,0.6);
+$mp->colormap->SetNullColor('gray');
+
+// Add lines
+$mp->AddLine($l1);
+$mp->AddLine($l2);
+// this could also be done as
+// $mp->AddLine(array($l1,$l2));
+
+// Setup column lablels
+$mp->collabel->Set($collabels);
+$mp->collabel->SetSide('top');
+$mp->collabel->SetFont(FF_ARIAL,FS_NORMAL,8);
+$mp->collabel->SetFontColor('lightgray');
+
+// Setup row lablels
+$mp->rowlabel->Set($rowlabels);
+$mp->rowlabel->SetSide('right');
+$mp->rowlabel->SetFont(FF_ARIAL,FS_NORMAL,8);
+$mp->rowlabel->SetFontColor('lightgray');
+
+// Move the legend more to the right
+$mp->legend->SetMargin(90);
+$mp->legend->SetColor('white');
+$mp->legend->SetFont(FF_VERDANA,FS_BOLD,10);
+
+$graph->Add($mp);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/matrix_introex.php b/web/classes/jpgraph/Examples/matrix_introex.php
new file mode 100755
index 0000000000000000000000000000000000000000..fcecc40cb02cffa56cb9fa9ddc0805b8e969b838
--- /dev/null
+++ b/web/classes/jpgraph/Examples/matrix_introex.php
@@ -0,0 +1,89 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_matrix.php');
+require_once ('jpgraph/jpgraph_iconplot.php');
+
+$data = array(
+    array(0,1,2,3,4,5,6,7,8,9,10),
+    array(10,9,8,7,6,5,4,3,2,1,0),
+    array(0,1,2,3,4,5,6,7,8,9,10),
+    array(10,9,8,17,6,5,4,3,2,1,0),
+    array(0,1,2,3,4,4,9,7,8,9,10),
+    array(8,1,2,3,4,8,3,7,8,9,10),
+    array(10,3,5,7,6,5,4,3,12,1,0),
+    array(10,9,8,7,6,5,4,3,2,1,0),
+);
+// Interpolate the data a factor of 4 to get some mroe 
+// data points
+doMeshInterpolate($data,4);
+
+// Setup a timer
+$timer = new JpgTimer();
+$timer->Push();
+
+//--------------------------------------------------------------
+// Setup a basic matrix graph
+//--------------------------------------------------------------
+$width = 740; $height = 500;
+$graph = new MatrixGraph($width,$height);
+$graph->SetMargin(1,2,70,1);
+$graph->SetColor('white');
+$graph->SetMarginColor('#fafafa');
+$graph->title->Set('Intro matrix graph');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+// Setup the background image
+$graph->SetBackgroundImage('fireplace.jpg',BGIMG_FILLPLOT);
+$graph->SetBackgroundImageMix(50);
+
+// Setup the timer in the right footer
+$graph->footer->SetTimer($timer);
+$graph->footer->right->SetColor('white');
+
+//--------------------------------------------------------------
+// Create the 2 matrix plots
+//--------------------------------------------------------------
+$mp = array(); $n = 2;
+for($i=0; $i < $n; ++$i){
+    $mp[$i] = new MatrixPlot($data);
+    $mp[$i]->colormap->SetMap($i);
+    $mp[$i]->SetSize(300,250);    
+    $mp[$i]->SetLegendLayout(1);
+    $mp[$i]->SetAlpha(0.2);
+    
+    // Make the legend slightly longer than default
+    $mp[$i]->legend->SetSize(20,280);
+}
+$mp[1]->colormap->SetMap(3);
+
+$hor1 = new LayoutHor(array($mp[0],$mp[1]));
+$hor1->SetCenterPos(0.5,0.5);
+
+$graph->Add($hor1);
+
+//--------------------------------------------------------------
+// Add texts to the graph
+//--------------------------------------------------------------
+$txts = array( 
+    array('Temperature gradient',$width/2,80),
+    array('Heat color map',200,110),
+    array('High contrast map',560,110));
+
+$n=count($txts);
+$t=array();
+for($i=0; $i < $n; ++$i){
+    $t[$i] = new Text($txts[$i][0],$txts[$i][1],$txts[$i][2]);
+    $t[$i]->SetFont(FF_ARIAL,FS_BOLD,14);
+    $t[$i]->SetColor('white');
+    $t[$i]->SetAlign('center','top');
+}
+$graph->Add($t);
+
+//--------------------------------------------------------------
+// Add Jpgraph logo to top left corner
+//--------------------------------------------------------------
+$icon = new IconPlot('jpglogo.jpg',2,2,0.9,50);
+$graph->Add($icon);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/matrix_layout_ex1.php b/web/classes/jpgraph/Examples/matrix_layout_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..1fefb1a81515ff5435a071902954065695116233
--- /dev/null
+++ b/web/classes/jpgraph/Examples/matrix_layout_ex1.php
@@ -0,0 +1,44 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_matrix.php');
+
+$data = array(
+array(0,1,2,3,4,5,6,7,8,9,10),
+array(10,9,8,7,6,5,4,3,2,1,0),
+array(0,1,2,3,4,5,6,7,8,9,10),
+array(10,9,8,17,6,5,4,3,2,1,0),
+array(0,1,2,3,4,4,9,7,8,9,10),
+array(8,1,2,3,4,8,3,7,8,9,10),
+array(10,3,5,7,6,5,4,3,12,1,0),
+array(10,9,8,7,6,5,4,3,2,1,0),
+);
+
+doMeshInterpolate($data,4);
+
+$graph = new MatrixGraph(850,580);
+$graph->title->Set('Matrix layout example');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+$mp = array();
+$n = 5;
+for($i=0; $i < $n; ++$i){
+    $mp[$i] = new MatrixPlot($data);
+    $mp[$i]->colormap->SetMap($i);
+    if( $i < 2 )
+        $mp[$i]->SetSize(0.35);
+    else
+        $mp[$i]->SetSize(0.21);    
+    // We need to make the legend a bit smaller since by 
+    // defalt has a  ~45% height 
+    $mp[$i]->legend->SetModuleSize(15,2);
+}
+
+$hor1 = new LayoutHor(array($mp[0],$mp[1]));
+$hor2 = new LayoutHor(array($mp[2],$mp[3],$mp[4]));
+$vert = new LayoutVert(array($hor1,$hor2));
+$vert->SetCenterPos(0.45,0.5);
+
+$graph->Add($vert);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/matrixex00.php b/web/classes/jpgraph/Examples/matrixex00.php
new file mode 100755
index 0000000000000000000000000000000000000000..2ba5114ac3c8aad79fb966bc33b710118983ebe7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/matrixex00.php
@@ -0,0 +1,59 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_matrix.php');
+
+$data = array(
+array(0,1,2,3,4,5,6,7,8,9,10),
+array(10,9,8,7,6,5,4,3,2,1,0),
+array(0,1,2,3,4,5,6,7,8,9,10),
+array(10,9,8,17,6,5,4,3,2,1,0),
+array(0,1,2,3,4,4,9,7,8,9,10),
+array(8,1,2,3,4,8,3,7,8,9,10),
+array(10,3,5,7,6,5,4,3,12,1,0),
+array(10,9,8,7,6,5,4,3,2,1,0),
+);
+
+doMeshInterpolate($data,4);
+
+$graph = new MatrixGraph(850,580);
+$graph->title->Set('Matrix example 00');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+//$graph->SetColor('darkgreen@0.8');
+
+$mp = array();
+$n = 5;
+for($i=0; $i < $n; ++$i){
+    $mp[$i] = new MatrixPlot($data);
+    $mp[$i]->colormap->SetMap($i);
+    if( $i < 2 )
+        $mp[$i]->SetSize(0.35);
+    else
+        $mp[$i]->SetSize(0.21);    
+}
+
+$hor1 = new LayoutHor(array($mp[0],$mp[1]));
+$hor2 = new LayoutHor(array($mp[2],$mp[3],$mp[4]));
+$vert = new LayoutVert(array($hor1,$hor2));
+$vert->SetCenterPos(0.45,0.5);
+
+//$mp = new MatrixPlot($data);
+//$mp->colormap->SetMap(2);
+//$mp->SetCenterPos(0.5, 0.45);
+//$mp->SetLegendLayout(0);
+//$mp->SetSize(0.6);
+//$mp->legend->Show(false);
+//$mp->SetModuleSize(5,5);
+
+//$mp->legend->SetModuleSize(20,4);
+//$mp->legend->SetSize(20,0.5);
+
+//$t = new Text('A text string',10,10);
+//$graph->Add($t);
+
+//$graph->Add($mp);
+
+$graph->Add($vert);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/mkgrad.php b/web/classes/jpgraph/Examples/mkgrad.php
new file mode 100755
index 0000000000000000000000000000000000000000..3f36b44a97f549fb5cf667078f2c2e03dc984075
--- /dev/null
+++ b/web/classes/jpgraph/Examples/mkgrad.php
@@ -0,0 +1,171 @@
+<?php // content="text/plain; charset=utf-8"
+//=======================================================================
+// File:	    MKGRAD.PHP
+// Description:	Simple tool to create a gradient background
+// Ver: 	    $Id$
+//=======================================================================
+
+// Basic library classes
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+  
+
+// Must have a global comparison method for usort()
+function _cmp($a,$b) {
+    return strcmp($a,$b);
+}
+
+// Generate the input form
+class Form {
+    var $iColors;
+    var $iGradstyles;
+    function Form() {
+
+	$rgb = new RGB();
+	$this->iColors = array_keys($rgb->rgb_table);
+	usort($this->iColors,'_cmp');
+
+	$this->iGradstyles = array(
+	    "Vertical",2,
+	    "Horizontal",1,
+	    "Vertical from middle",3,
+	    "Horizontal from middle",4,
+	    "Horizontal wider middle",6,
+	    "Vertical wider middle",7,
+	    "Rectangle",5 );
+    }
+
+    function Run() {
+
+	echo '<h3>Generate gradient background</h3>';
+	echo '<form METHOD=POST action=""><table style="border:blue solid 1;">';
+	echo '<tr><td>Width:<br>'.$this->GenHTMLInput('w',8,4,300).'</td>';
+	echo "\n";
+	echo '<td>Height:<br>'.$this->GenHTMLInput('h',8,4,300).'</td></tr>';
+	echo "\n";
+	echo '<tr><td>From Color:<br>';
+	echo $this->GenHTMLSelect('fc',$this->iColors);
+	echo '</td><td>To Color:<br>';
+	echo $this->GenHTMLSelect('tc',$this->iColors);
+	echo '</td></tr>';
+	echo '<tr><td colspan=2>Gradient style:<br>';
+	echo $this->GenHTMLSelectCode('s',$this->iGradstyles);
+	echo '</td></tr>';
+	echo '<tr><td colspan=2>Filename: (empty to stream)<br>';
+	echo $this->GenHTMLInput('fn',55,100);
+	echo '</td></tr>';
+	echo '<tr><td colspan=2 align=right>'.$this->GenHTMLSubmit('submit').'</td></tr>';
+	echo '</table>';
+	echo '</form>';
+
+    }
+
+    function GenHTMLSubmit($name) {
+	return '<INPUT TYPE=submit name="ok"  value=" Ok " >';
+    }
+
+
+    function GenHTMLInput($name,$len,$maxlen=100,$val='') {
+	return '<INPUT TYPE=TEXT NAME='.$name.' VALUE="'.$val.'" SIZE='.$len.' MAXLENGTH='.$maxlen.'>';
+    }
+
+    function GenHTMLSelect($name,$option,$selected="",$size=0) {
+	$txt="<select name=$name";
+	if( $size > 0 )
+	    $txt .= " size=$size >";
+	else 
+	    $txt .= ">";
+	for($i=0; $i<count($option); $i++) {
+	    if( $selected==$option[$i] )
+		$txt=$txt."<option selected value=\"$option[$i]\">$option[$i]</option>\n";		
+	    else
+		$txt=$txt."<option value=\"".$option[$i]."\">$option[$i]</option>\n";
+	}
+	return $txt."</select>\n";
+    }
+    
+    function GenHTMLSelectCode($name,$option,$selected="",$size=0) {
+	$txt="<select name=$name";
+	if( $size > 0 )
+	    $txt .= " size=$size >";
+	else 
+	    $txt .= ">";
+	for($i=0; $i<count($option); $i += 2) {
+	    if( $selected==$option[($i+1)] )
+		$txt=$txt."<option selected value=".$option[($i+1)].">$option[$i]</option>\n";		
+	    else
+		$txt=$txt."<option value=\"".$option[($i+1)]."\">$option[$i]</option>\n";
+	}
+	return $txt."</select>\n";
+    }
+
+}
+
+// Basic application driver
+
+class Driver {
+    var $iGraph, $iGrad;
+    var $iWidth,$iHeight;
+    var $iFromColor, $iToColor;
+    var $iStyle;
+    var $iForm;
+
+    function Driver() {
+	$this->iForm = new Form();
+    }
+
+    function GenGradImage() {
+	
+	$aWidth	 = (int)@$_POST['w'];
+	$aHeight = (int)@$_POST['h'];
+	$aFrom   = @$_POST['fc'];
+	$aTo     = @$_POST['tc'];
+	$aStyle  = @$_POST['s'];
+	$aFileName  = @$_POST['fn'];
+
+	$this->iWidth     = $aWidth;
+	$this->iHeight    = $aHeight;
+	$this->iFromColor = $aFrom;
+	$this->iToColor   = $aTo;
+	$this->iStyle     = $aStyle;
+
+	$this->graph = new CanvasGraph($aWidth,$aHeight);
+	$this->grad  = new Gradient($this->graph->img);
+	$this->grad->FilledRectangle(0,0,
+				     $this->iWidth,$this->iHeight,
+				     $this->iFromColor,
+				     $this->iToColor,
+				     $this->iStyle);
+
+	if( $aFileName != "" ) {
+	    $this->graph->Stroke($aFileName);
+	    echo "Image file '$aFileName' created.";
+	}
+	else
+	    $this->graph->Stroke();
+    }
+
+
+    function Run() {
+	
+	global $HTTP_POST_VARS;
+
+	// Two modes:
+	// 1) If the script is called with no posted arguments
+	// we show the input form.
+	// 2) If we have posted arguments we naivly assume that
+	// we are called to do the image.
+
+	if( @$_POST['ok']===' Ok ' ) { 
+	    $this->GenGradImage();
+	}
+	else
+	    $this->iForm->Run();
+    }
+}
+
+$driver = new Driver();				
+$driver->Run();
+
+?>
diff --git a/web/classes/jpgraph/Examples/multconstganttex01.php b/web/classes/jpgraph/Examples/multconstganttex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..fce986e25b5e71d2e8fd0ad75a366019e45fe92c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/multconstganttex01.php
@@ -0,0 +1,30 @@
+<?php // content="text/plain; charset=utf-8" 
+// Gantt example 
+require_once ('jpgraph/jpgraph.php'); 
+require_once ('jpgraph/jpgraph_gantt.php'); 
+
+// Create the basic graph 
+$graph = new GanttGraph(); 
+$graph->title->Set("Example with multiple constrains"); 
+
+$bar1 = new GanttBar(0, "Label 1", "2003-06-08", "2003-06-12"); 
+$bar2 = new GanttBar(1, "Label 2", "2003-06-16", "2003-06-19"); 
+$bar3 = new GanttBar(2, "Label 3", "2003-06-15", "2003-06-21"); 
+
+//create constraints 
+$bar1->SetConstrain(1, CONSTRAIN_ENDSTART); 
+$bar1->SetConstrain(2, CONSTRAIN_ENDSTART); 
+
+// Setup scale 
+$graph->ShowHeaders(/*GANTT_HYEAR | GANTT_HMONTH |*/ GANTT_HDAY | GANTT_HWEEK); 
+$graph->scale->week->SetStyle(WEEKSTYLE_FIRSTDAYWNBR); 
+
+// Add the specified activities 
+$graph->Add($bar1); 
+$graph->Add($bar2); 
+$graph->Add($bar3); 
+
+// .. and stroke the graph 
+$graph->Stroke(); 
+
+?>
diff --git a/web/classes/jpgraph/Examples/mulyaxiscsimex1.php b/web/classes/jpgraph/Examples/mulyaxiscsimex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..516aea347b9a5083399499070c7821ad8e113f4d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/mulyaxiscsimex1.php
@@ -0,0 +1,75 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+
+// Setup some dummy targets for the CSIM
+$n = 5;
+for($i=0; $i < $n; ++$i ) {
+    $targ1[$i] = "#$i";
+    $targ2[$i] = "#$i";
+    $targ3[$i] = "#$i";
+    $alts1[$i] = "val=%d";
+    $alts2[$i] = "val=%d";
+    $alts3[$i] = "val=%d";
+}
+
+// Some data for the points
+$datay1 = array(3,10,4,1,6);
+$datay2 = array(25,22,18,24,20);
+$datay3 = array(89,70,92,77,96);
+
+// Create a basic graph with some suitable margins
+$graph = new Graph(500,250);
+$graph->SetMargin(60,180,50,40);
+$graph->SetMarginColor('white');
+$graph->title->Set("Multi Y-axes with Image Map");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Setup the scales for all axes
+$graph->SetScale("intlin");
+$graph->SetYScale(0,'int');
+$graph->SetYScale(1,'int');
+
+// Standard Y-axis plot
+$lp1 = new LinePlot($datay1);
+$lp1->SetLegend('2001');
+$lp1->mark->SetType(MARK_DIAMOND);
+$lp1->mark->SetWidth(15);
+$lp1->mark->SetFillColor('orange');
+$lp1->SetCSIMTargets($targ1,$alts1);
+$graph->yaxis->title->Set('Basic Rate');
+$graph->yaxis->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->yaxis->title->SetColor('black');
+$graph->Add($lp1);
+
+// First multi Y-axis plot
+$lp2 = new LinePlot($datay2);
+$lp2->SetLegend('2002');
+$lp2->mark->SetType(MARK_DIAMOND);
+$lp2->mark->SetWidth(15);
+$lp2->mark->SetFillColor('darkred');
+$lp2->SetCSIMTargets($targ2,$alts2);
+$graph->ynaxis[0]->SetColor('darkred');
+$graph->ynaxis[0]->title->Set('Rate A');
+$graph->ynaxis[0]->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->ynaxis[0]->title->SetColor('darkred');
+$graph->AddY(0,$lp2);
+
+// Second multi Y-axis plot
+$lp3 = new LinePlot($datay3);
+$lp3->SetLegend('2003');
+$lp3->mark->SetType(MARK_DIAMOND);
+$lp3->mark->SetWidth(15);
+$lp3->mark->SetFillColor('darkgreen');
+$lp3->SetCSIMTargets($targ3,$alts3);
+$graph->ynaxis[1]->SetColor('darkgreen');
+$graph->ynaxis[1]->title->Set('Rate B');
+$graph->ynaxis[1]->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->ynaxis[1]->title->SetColor('darkgreen');
+$graph->AddY(1,$lp3);
+
+// Send back the HTML page which will call this script again
+// to retrieve the image.
+$graph->StrokeCSIM();
+?>
diff --git a/web/classes/jpgraph/Examples/mulyaxisex1.php b/web/classes/jpgraph/Examples/mulyaxisex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..57304ebabd7a1e4f948ff0c1c594f5a48eb1f89a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/mulyaxisex1.php
@@ -0,0 +1,48 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$n = 8;
+for($i=0; $i < $n; ++$i ) {
+    $datay[$i] = rand(1,10);
+    $datay2[$i] = rand(10,55);
+    $datay3[$i] = rand(200,600);
+    $datay4[$i] = rand(500,800);
+}
+
+// Setup the graph
+$graph = new Graph(450,250);
+$graph->SetMargin(40,150,40,30);
+$graph->SetMarginColor('white');
+
+$graph->SetScale('intlin');
+$graph->title->Set('Using multiple Y-axis');
+$graph->title->SetFont(FF_ARIAL,FS_NORMAL,14);
+
+$graph->SetYScale(0,'lin');
+$graph->SetYScale(1,'lin');
+$graph->SetYScale(2,'lin');
+
+$p1 = new LinePlot($datay);
+$graph->Add($p1);
+
+$p2 = new LinePlot($datay2);
+$p2->SetColor('teal');
+$graph->AddY(0,$p2);
+$graph->ynaxis[0]->SetColor('teal');
+
+$p3 = new LinePlot($datay3);
+$p3->SetColor('red');
+$graph->AddY(1,$p3);
+$graph->ynaxis[1]->SetColor('red');
+
+$p4 = new LinePlot($datay4);
+$p4->SetColor('blue');
+$graph->AddY(2,$p4);
+$graph->ynaxis[2]->SetColor('blue');
+
+// Output line
+$graph->Stroke();
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/negbarvalueex01.php b/web/classes/jpgraph/Examples/negbarvalueex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..f825a59c014a825b32771900518790454e14591b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/negbarvalueex01.php
@@ -0,0 +1,39 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,0,-19,-7,17,-6);
+
+// Create the graph. 
+$graph = new Graph(400,300);	
+$graph->img->SetMargin(60,30,40,40);
+$graph->SetScale("textlin");
+$graph->SetShadow();
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("orange");
+
+// DIsplay value at top of each bar
+$bplot->value->Show();
+$bplot->SetShadow();
+
+$graph->Add($bplot);
+
+// Position the scale at the min of the other axis
+$graph->xaxis->SetPos("min");
+
+// Add 10% more space at top and bottom of graph
+$graph->yscale->SetGrace(10,10);
+
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->title->SetFont(FF_VERDANA,FS_NORMAL,12);
+$graph->title->Set("Example of bar plot with absolute labels");
+
+$graph->yaxis->title->SetFont(FF_ARIAL,FS_NORMAL,16);
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/new1.gif b/web/classes/jpgraph/Examples/new1.gif
new file mode 100755
index 0000000000000000000000000000000000000000..7c8a29626fae142ab9ab6219b13372759630e9c2
Binary files /dev/null and b/web/classes/jpgraph/Examples/new1.gif differ
diff --git a/web/classes/jpgraph/Examples/new2.gif b/web/classes/jpgraph/Examples/new2.gif
new file mode 100755
index 0000000000000000000000000000000000000000..b9620d74047f5d4b82751fb92705025e4e6a2d19
Binary files /dev/null and b/web/classes/jpgraph/Examples/new2.gif differ
diff --git a/web/classes/jpgraph/Examples/new_bar1.php b/web/classes/jpgraph/Examples/new_bar1.php
new file mode 100755
index 0000000000000000000000000000000000000000..589b4c38f4ab95d3d2fa19fd65de55916c24893c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/new_bar1.php
@@ -0,0 +1,49 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$data1y=array(47,80,40,116);
+$data2y=array(61,30,82,105);
+$data3y=array(115,50,70,93);
+
+
+// Create the graph. These two calls are always required
+$graph = new Graph(350,200,'auto');
+$graph->SetScale("textlin");
+
+$theme_class=new UniversalTheme;
+$graph->SetTheme($theme_class);
+
+$graph->yaxis->SetTickPositions(array(0,30,60,90,120,150), array(15,45,75,105,135));
+$graph->SetBox(false);
+
+$graph->ygrid->SetFill(false);
+$graph->xaxis->SetTickLabels(array('A','B','C','D'));
+$graph->yaxis->HideLine(false);
+$graph->yaxis->HideTicks(false,false);
+
+// Create the bar plots
+$b1plot = new BarPlot($data1y);
+$b2plot = new BarPlot($data2y);
+$b3plot = new BarPlot($data3y);
+
+// Create the grouped bar plot
+$gbplot = new GroupBarPlot(array($b1plot,$b2plot,$b3plot));
+// ...and add it to the graPH
+$graph->Add($gbplot);
+
+
+$b1plot->SetColor("white");
+$b1plot->SetFillColor("#cc1111");
+
+$b2plot->SetColor("white");
+$b2plot->SetFillColor("#11cccc");
+
+$b3plot->SetColor("white");
+$b3plot->SetFillColor("#1111cc");
+
+$graph->title->Set("Bar Plots");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/new_bar3.php b/web/classes/jpgraph/Examples/new_bar3.php
new file mode 100755
index 0000000000000000000000000000000000000000..2d8b9e657271fbfcc44240747caa3a593fe4cb7b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/new_bar3.php
@@ -0,0 +1,39 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(62,105,85,50);
+
+
+// Create the graph. These two calls are always required
+$graph = new Graph(350,220,'auto');
+$graph->SetScale("textlin");
+
+//$theme_class="DefaultTheme";
+//$graph->SetTheme(new $theme_class());
+
+// set major and minor tick positions manually
+$graph->yaxis->SetTickPositions(array(0,30,60,90,120,150), array(15,45,75,105,135));
+$graph->SetBox(false);
+
+//$graph->ygrid->SetColor('gray');
+$graph->ygrid->SetFill(false);
+$graph->xaxis->SetTickLabels(array('A','B','C','D'));
+$graph->yaxis->HideLine(false);
+$graph->yaxis->HideTicks(false,false);
+
+// Create the bar plots
+$b1plot = new BarPlot($datay);
+
+// ...and add it to the graPH
+$graph->Add($b1plot);
+
+
+$b1plot->SetColor("white");
+$b1plot->SetFillGradient("#4B0082","white",GRAD_LEFT_REFLECTION);
+$b1plot->SetWidth(45);
+$graph->title->Set("Bar Gradient(Left reflection)");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/new_bar4.php b/web/classes/jpgraph/Examples/new_bar4.php
new file mode 100755
index 0000000000000000000000000000000000000000..8415c09f06f6f474e83109094c43c2b61d58f101
--- /dev/null
+++ b/web/classes/jpgraph/Examples/new_bar4.php
@@ -0,0 +1,43 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(17,22,33,48,24,20);
+
+
+// Create the graph. These two calls are always required
+$graph = new Graph(220,300,'auto');
+$graph->SetScale("textlin");
+
+$theme_class=new UniversalTheme;
+$graph->SetTheme($theme_class);
+
+$graph->Set90AndMargin(50,40,40,40);
+$graph->img->SetAngle(90); 
+
+// set major and minor tick positions manually
+$graph->SetBox(false);
+
+//$graph->ygrid->SetColor('gray');
+$graph->ygrid->Show(false);
+$graph->ygrid->SetFill(false);
+$graph->xaxis->SetTickLabels(array('A','B','C','D','E','F'));
+$graph->yaxis->HideLine(false);
+$graph->yaxis->HideTicks(false,false);
+
+// For background to be gradient, setfill is needed first.
+$graph->SetBackgroundGradient('#00CED1', '#FFFFFF', GRAD_HOR, BGRAD_PLOT);
+
+// Create the bar plots
+$b1plot = new BarPlot($datay);
+
+// ...and add it to the graPH
+$graph->Add($b1plot);
+
+$b1plot->SetWeight(0);
+$b1plot->SetFillGradient("#808000","#90EE90",GRAD_HOR);
+$b1plot->SetWidth(17);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/new_bar6.php b/web/classes/jpgraph/Examples/new_bar6.php
new file mode 100755
index 0000000000000000000000000000000000000000..a439ec7653485b72b82833daa6b1a040c8a03396
--- /dev/null
+++ b/web/classes/jpgraph/Examples/new_bar6.php
@@ -0,0 +1,103 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+//bar1
+$data1y=array(115,130,135,130,110,130,130,150,130,130,150,120);
+//bar2
+$data2y=array(180,200,220,190,170,195,190,210,200,205,195,150);
+//bar3
+$data3y=array(220,230,210,175,185,195,200,230,200,195,180,130);
+$data4y=array(40,45,70,80,50,75,70,70,80,75,80,50);
+$data5y=array(20,20,25,22,30,25,35,30,27,25,25,45);
+//line1
+$data6y=array(50,58,60,58,53,58,57,60,58,58,57,50);
+foreach ($data6y as &$y) { $y -=10; }
+
+// Create the graph. These two calls are always required
+$graph = new Graph(750,320,'auto');
+$graph->SetScale("textlin");
+$graph->SetY2Scale("lin",0,90);
+$graph->SetY2OrderBack(false);
+
+$graph->SetMargin(35,50,20,5);
+
+$theme_class = new UniversalTheme;
+$graph->SetTheme($theme_class);
+
+$graph->yaxis->SetTickPositions(array(0,50,100,150,200,250,300,350), array(25,75,125,175,275,325));
+$graph->y2axis->SetTickPositions(array(30,40,50,60,70,80,90));
+
+$months = $gDateLocale->GetShortMonth();
+$months = array_merge(array_slice($months,3,9), array_slice($months,0,3));
+$graph->SetBox(false);
+
+$graph->ygrid->SetFill(false);
+$graph->xaxis->SetTickLabels(array('A','B','C','D'));
+$graph->yaxis->HideLine(false);
+$graph->yaxis->HideTicks(false,false);
+// Setup month as labels on the X-axis
+$graph->xaxis->SetTickLabels($months);
+
+// Create the bar plots
+$b1plot = new BarPlot($data1y);
+$b2plot = new BarPlot($data2y);
+
+$b3plot = new BarPlot($data3y);
+$b4plot = new BarPlot($data4y);
+$b5plot = new BarPlot($data5y);
+
+$lplot = new LinePlot($data6y);
+
+// Create the grouped bar plot
+$gbbplot = new AccBarPlot(array($b3plot,$b4plot,$b5plot));
+$gbplot = new GroupBarPlot(array($b1plot,$b2plot,$gbbplot));
+
+// ...and add it to the graPH
+$graph->Add($gbplot);
+$graph->AddY2($lplot);
+
+$b1plot->SetColor("#0000CD");
+$b1plot->SetFillColor("#0000CD");
+$b1plot->SetLegend("Cliants");
+
+$b2plot->SetColor("#B0C4DE");
+$b2plot->SetFillColor("#B0C4DE");
+$b2plot->SetLegend("Machines");
+
+$b3plot->SetColor("#8B008B");
+$b3plot->SetFillColor("#8B008B");
+$b3plot->SetLegend("First Track");
+
+$b4plot->SetColor("#DA70D6");
+$b4plot->SetFillColor("#DA70D6");
+$b4plot->SetLegend("All");
+
+$b5plot->SetColor("#9370DB");
+$b5plot->SetFillColor("#9370DB");
+$b5plot->SetLegend("Single Only");
+
+$lplot->SetBarCenter();
+$lplot->SetColor("yellow");
+$lplot->SetLegend("Houses");
+$lplot->mark->SetType(MARK_X,'',1.0);
+$lplot->mark->SetWeight(2);
+$lplot->mark->SetWidth(8);
+$lplot->mark->setColor("yellow");
+$lplot->mark->setFillColor("yellow");
+
+$graph->legend->SetFrameWeight(1);
+$graph->legend->SetColumns(6);
+$graph->legend->SetColor('#4E4E4E','#00A78A');
+
+$band = new PlotBand(VERTICAL,BAND_RDIAG,11,"max",'khaki4');
+$band->ShowFrame(true);
+$band->SetOrder(DEPTH_BACK);
+$graph->Add($band);
+
+$graph->title->Set("Combineed Line and Bar plots");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/new_line1.php b/web/classes/jpgraph/Examples/new_line1.php
new file mode 100755
index 0000000000000000000000000000000000000000..7a8ae6603f0fd44af5e24d9b4fd27063908f527e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/new_line1.php
@@ -0,0 +1,57 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay1 = array(20,15,23,15);
+$datay2 = array(12,9,42,8);
+$datay3 = array(5,17,32,24);
+
+// Setup the graph
+$graph = new Graph(300,250);
+$graph->SetScale("textlin");
+
+$theme_class=new UniversalTheme;
+
+$graph->SetTheme($theme_class);
+$graph->img->SetAntiAliasing(false);
+$graph->title->Set('Filled Y-grid');
+$graph->SetBox(false);
+
+$graph->img->SetAntiAliasing();
+
+$graph->yaxis->HideZeroLabel();
+$graph->yaxis->HideLine(false);
+$graph->yaxis->HideTicks(false,false);
+
+$graph->xgrid->Show();
+$graph->xgrid->SetLineStyle("solid");
+$graph->xaxis->SetTickLabels(array('A','B','C','D'));
+$graph->xgrid->SetColor('#E3E3E3');
+/* $graph->SetBackgroundImage("tiger_bkg.png",BGIMG_FILLPLOT); */
+
+// Create the first line
+$p1 = new LinePlot($datay1);
+$graph->Add($p1);
+$p1->SetColor("#6495ED");
+$p1->SetLegend('Line 1');
+
+// Create the second line
+$p2 = new LinePlot($datay2);
+$graph->Add($p2);
+$p2->SetColor("#B22222");
+$p2->SetLegend('Line 2');
+
+// Create the third line
+$p3 = new LinePlot($datay3);
+$graph->Add($p3);
+$p3->SetColor("#FF1493");
+$p3->SetLegend('Line 3');
+
+$graph->legend->SetFrameWeight(1);
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/new_line2.php b/web/classes/jpgraph/Examples/new_line2.php
new file mode 100755
index 0000000000000000000000000000000000000000..8ccd2710a5f1de10c6857302fe88df5a6c2ac808
--- /dev/null
+++ b/web/classes/jpgraph/Examples/new_line2.php
@@ -0,0 +1,57 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay1 = array(20,7,16,46);
+$datay2 = array(6,20,10,22);
+
+// Setup the graph
+$graph = new Graph(350,230);
+$graph->SetScale("textlin");
+
+$theme_class= new UniversalTheme;
+$graph->SetTheme($theme_class);
+
+$graph->title->Set('Background Image');
+$graph->SetBox(false);
+
+$graph->yaxis->HideZeroLabel();
+$graph->yaxis->HideLine(false);
+$graph->yaxis->HideTicks(false,false);
+
+$graph->xaxis->SetTickLabels(array('A','B','C','D'));
+$graph->ygrid->SetFill(false);
+$graph->SetBackgroundImage("tiger_bkg.png",BGIMG_FILLFRAME);
+
+$p1 = new LinePlot($datay1);
+$graph->Add($p1);
+
+$p2 = new LinePlot($datay2);
+$graph->Add($p2);
+
+$p1->SetColor("#55bbdd");
+$p1->SetLegend('Line 1');
+$p1->mark->SetType(MARK_FILLEDCIRCLE,'',1.0);
+$p1->mark->SetColor('#55bbdd');
+$p1->mark->SetFillColor('#55bbdd');
+$p1->SetCenter();
+
+$p2->SetColor("#aaaaaa");
+$p2->SetLegend('Line 2');
+$p2->mark->SetType(MARK_UTRIANGLE,'',1.0);
+$p2->mark->SetColor('#aaaaaa');
+$p2->mark->SetFillColor('#aaaaaa');
+$p2->value->SetMargin(14);
+$p2->SetCenter();
+
+$graph->legend->SetFrameWeight(1);
+$graph->legend->SetColor('#4E4E4E','#00A78A');
+$graph->legend->SetMarkAbsSize(8);
+
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/new_line3.php b/web/classes/jpgraph/Examples/new_line3.php
new file mode 100755
index 0000000000000000000000000000000000000000..cc0ab3e5999bf80dd57ec108a5c9c61e1c6874d3
--- /dev/null
+++ b/web/classes/jpgraph/Examples/new_line3.php
@@ -0,0 +1,46 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+$datay1 = array(15,21,24,10,37,29,47);
+$datay2 = array(8,6,11,26,10,4,2);
+
+// Setup the graph
+$graph = new Graph(300,250);
+
+$graph->SetScale("textlin",0,50);
+
+//$theme_class=new DefaultTheme;
+//$graph->SetTheme($theme_class);
+
+$graph->title->Set("Filled Area");
+
+$graph->SetBox(false);
+$graph->yaxis->HideLine(false);
+$graph->yaxis->HideTicks(false,false);
+$graph->yaxis->HideZeroLabel();
+
+$graph->xaxis->SetTickLabels(array('A','B','C','D','E','F','G'));
+
+// Create the plot
+$p1 = new LinePlot($datay1);
+$graph->Add($p1);
+
+$p2 = new LinePlot($datay2);
+$graph->Add($p2);
+
+// Use an image of favourite car as marker
+$p1->mark->SetType(MARK_IMG,'rose.gif',1.0);
+$p1->SetLegend('rose');
+$p1->SetColor('#CD5C5C');
+
+$p2->mark->SetType(MARK_IMG,'sunflower.gif',1.0);
+$p2->SetLegend('sunflower');
+$p2->SetColor('#CD5C5C');
+
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/new_line4.php b/web/classes/jpgraph/Examples/new_line4.php
new file mode 100755
index 0000000000000000000000000000000000000000..f50921ea7ff780996f0af2cf5265d27aca4d6e60
--- /dev/null
+++ b/web/classes/jpgraph/Examples/new_line4.php
@@ -0,0 +1,49 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+$datay1 = array(33,20,24,5,38,24,22);
+$datay2 = array(9,7,10,25,10,8,4);
+
+// Setup the graph
+$graph = new Graph(300,250);
+
+$graph->SetScale("textlin",0,50);
+
+$theme_class= new UniversalTheme;
+$graph->SetTheme($theme_class);
+
+$graph->title->Set("Line Plots with Markers");
+
+$graph->SetBox(false);
+$graph->ygrid->SetFill(false);
+$graph->yaxis->HideLine(false);
+$graph->yaxis->HideTicks(false,false);
+$graph->yaxis->HideZeroLabel();
+
+$graph->xaxis->SetTickLabels(array('A','B','C','D','E','F','G'));
+// Create the plot
+$p1 = new LinePlot($datay1);
+$graph->Add($p1);
+
+$p2 = new LinePlot($datay2);
+$graph->Add($p2);
+
+// Use an image of favourite car as marker
+$p1->mark->SetType(MARK_IMG,'new1.gif',0.8);
+$p1->SetColor('#aadddd');
+$p1->value->SetFormat('%d');
+$p1->value->Show();
+$p1->value->SetColor('#55bbdd');
+
+$p2->mark->SetType(MARK_IMG,'new2.gif',0.8);
+$p2->SetColor('#ddaa99');
+$p2->value->SetFormat('%d');
+$p2->value->Show();
+$p2->value->SetColor('#55bbdd');
+
+
+$graph->Stroke();
+
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/new_line5.php b/web/classes/jpgraph/Examples/new_line5.php
new file mode 100755
index 0000000000000000000000000000000000000000..7a234a8c226d56dd198ee22823d55a7764d1243c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/new_line5.php
@@ -0,0 +1,44 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay = array(0,25,12,47,27,27,0);
+
+// Setup the graph
+$graph = new Graph(350,250);
+$graph->SetScale("intlin",0,$aYMax=50);
+
+$theme_class= new UniversalTheme;
+$graph->SetTheme($theme_class);
+
+$graph->SetMargin(40,40,50,40);
+
+$graph->title->Set('Inverted Y-axis');
+$graph->SetBox(false);
+$graph->yaxis->HideLine(false);
+$graph->yaxis->HideTicks(false,false);
+
+// For background to be gradient, setfill is needed first.
+$graph->ygrid->SetFill(true,'#FFFFFF@0.5','#FFFFFF@0.5');
+$graph->SetBackgroundGradient('#FFFFFF', '#00FF7F', GRAD_HOR, BGRAD_PLOT);
+
+$graph->xaxis->SetTickLabels(array('G','F','E','D','C','B','A'));
+$graph->xaxis->SetLabelMargin(20);
+$graph->yaxis->SetLabelMargin(20);
+
+$graph->SetAxisStyle(AXSTYLE_BOXOUT);
+$graph->img->SetAngle(180); 
+
+// Create the line
+$p1 = new LinePlot($datay);
+$graph->Add($p1);
+
+$p1->SetFillGradient('#FFFFFF','#F0F8FF');
+$p1->SetColor('#aadddd');
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/new_pie1.php b/web/classes/jpgraph/Examples/new_pie1.php
new file mode 100755
index 0000000000000000000000000000000000000000..3c395e885789898d897d319ab0f2815dba6dc52e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/new_pie1.php
@@ -0,0 +1,28 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+// Some data
+$data = array(40,21,17,14,23);
+
+// Create the Pie Graph. 
+$graph = new PieGraph(350,250);
+
+$theme_class="DefaultTheme";
+//$graph->SetTheme(new $theme_class());
+
+// Set A title for the plot
+$graph->title->Set("A Simple Pie Plot");
+$graph->SetBox(true);
+
+// Create
+$p1 = new PiePlot($data);
+$graph->Add($p1);
+
+$p1->ShowBorder();
+$p1->SetColor('black');
+$p1->SetSliceColors(array('#1E90FF','#2E8B57','#ADFF2F','#DC143C','#BA55D3'));
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/new_pie2.php b/web/classes/jpgraph/Examples/new_pie2.php
new file mode 100755
index 0000000000000000000000000000000000000000..6e94cbff116be12745c069da4be75ce3b961bd96
--- /dev/null
+++ b/web/classes/jpgraph/Examples/new_pie2.php
@@ -0,0 +1,55 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+// Some data
+$data = array(40,21,17,14,23);
+
+// Create the Pie Graph.
+$graph = new PieGraph(500,300);
+$graph->SetShadow();
+
+$theme_class= new UniversalTheme;
+//$graph->SetTheme($theme_class);
+
+// Set A title for the plot
+$graph->title->Set("Multiple - Pie plot");
+
+// Create plots
+$size=0.13;
+$p1 = new PiePlot($data);
+$graph->Add($p1);
+
+$p1->SetSize($size);
+$p1->SetCenter(0.25,0.32);
+$p1->SetSliceColors(array('#1E90FF','#2E8B57','#ADFF2F','#DC143C','#BA55D3'));
+$p1->title->Set("2005");
+
+$p2 = new PiePlot($data);
+$graph->Add($p2);
+
+$p2->SetSize($size);
+$p2->SetCenter(0.65,0.32);
+$p2->SetSliceColors(array('#1E90FF','#2E8B57','#ADFF2F','#DC143C','#BA55D3'));
+$p2->title->Set("2006");
+
+$p3 = new PiePlot($data);
+$graph->Add($p3);
+
+$p3->SetSize($size);
+$p3->SetCenter(0.25,0.75);
+$p3->SetSliceColors(array('#6495ED','#2E8B57','#ADFF2F','#DC143C','#BA55D3'));
+$p3->title->Set("2007");
+
+$p4 = new PiePlot($data);
+$graph->Add($p4);
+
+$p4->SetSize($size);
+$p4->SetCenter(0.65,0.75);
+$p4->SetSliceColors(array('#6495ED','#2E8B57','#ADFF2F','#DC143C','#BA55D3'));
+$p4->title->Set("2008");
+
+
+$graph->Stroke();
+
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/new_pie3.php b/web/classes/jpgraph/Examples/new_pie3.php
new file mode 100755
index 0000000000000000000000000000000000000000..81bc0f2a0a8e032d45c2020d0137f3326c2d4f17
--- /dev/null
+++ b/web/classes/jpgraph/Examples/new_pie3.php
@@ -0,0 +1,28 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+require_once ('jpgraph/jpgraph_pie3d.php');
+
+// Some data
+$data = array(40,60,21,33);
+
+// Create the Pie Graph. 
+$graph = new PieGraph(350,250);
+
+$theme_class= new UniversalTheme;
+$graph->SetTheme($theme_class);
+
+// Set A title for the plot
+$graph->title->Set("A Simple 3D Pie Plot");
+
+// Create
+$p1 = new PiePlot3D($data);
+$graph->Add($p1);
+
+$p1->ShowBorder();
+$p1->SetColor('black');
+$p1->SetSliceColors(array('#1E90FF','#2E8B57','#ADFF2F','#BA55D3'));
+$p1->ExplodeSlice(1);
+$graph->Stroke();
+
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/new_pie4.php b/web/classes/jpgraph/Examples/new_pie4.php
new file mode 100755
index 0000000000000000000000000000000000000000..5353800806ca1c88f106e81543be4b31b6d04fab
--- /dev/null
+++ b/web/classes/jpgraph/Examples/new_pie4.php
@@ -0,0 +1,65 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+require_once ('jpgraph/jpgraph_pie3d.php');
+
+// Some data
+$data = array(40,60,21,33);
+
+$piepos = array(0.2,0.35,0.5,0.25,0.3,0.7,0.85,0.7);
+$titles = array('USA','Sweden','South America','Australia');
+
+$n = count($piepos)/2;
+ 
+// A new graph
+$graph = new PieGraph(450,300,'auto');
+
+$theme_class="PastelTheme";
+$graph->SetTheme(new $theme_class());
+
+// Setup background
+$graph->SetBackgroundImage('worldmap1.jpg',BGIMG_FILLFRAME);
+
+// Setup title
+$graph->title->Set("Pie plots with background image");
+$graph->title->SetColor('white');
+$graph->SetTitleBackground('#4169E1',TITLEBKG_STYLE2,TITLEBKG_FRAME_FULL,'#4169E1',10,10,true);
+
+$p = array();
+// Create the plots
+for( $i=0; $i < $n; ++$i ) {
+    $p[] = new PiePlot3D($data);
+}
+for( $i=0; $i < $n; ++$i ) {
+    $graph->Add($p[$i]);
+}
+
+// Position the four pies and change color
+for( $i=0; $i < $n; ++$i ) {
+    $p[$i]->SetCenter($piepos[2*$i],$piepos[2*$i+1]);
+    $p[$i]->SetSliceColors(array('#1E90FF','#2E8B57','#ADFF2F','#DC143C','#BA55D3'));
+}
+
+// Set the titles
+for( $i=0; $i < $n; ++$i ) {
+    $p[$i]->title->Set($titles[$i]);
+    $p[$i]->title->SetFont(FF_ARIAL,FS_NORMAL,8);
+} 
+
+for( $i=0; $i < $n; ++$i ) {
+  $p[$i]->value->Show(false);
+}
+
+// Size of pie in fraction of the width of the graph
+for( $i=0; $i < $n; ++$i ) {
+    $p[$i]->SetSize(0.13);
+}
+
+for( $i=0; $i < $n; ++$i ) {
+    $p[$i]->SetEdge(false);
+    $p[$i]->ExplodeSlice(1,7);
+}
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/new_step1.php b/web/classes/jpgraph/Examples/new_step1.php
new file mode 100755
index 0000000000000000000000000000000000000000..7bd0ce50a9a83a6cd346d83340322a6e1d227bdd
--- /dev/null
+++ b/web/classes/jpgraph/Examples/new_step1.php
@@ -0,0 +1,36 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay = array(20,10,35,5,17,35,22);
+
+// Setup the graph
+$graph = new Graph(400,250);
+$graph->SetScale("intlin",0,$aYMax=50);
+$theme_class=new UniversalTheme;
+$graph->SetTheme($theme_class);
+
+$graph->SetBox(false);
+
+$graph->title->Set('Step Line');
+$graph->ygrid->Show(true);
+$graph->xgrid->Show(false);
+$graph->yaxis->HideZeroLabel();
+$graph->ygrid->SetFill(true,'#FFFFFF@0.5','#FFFFFF@0.5');
+$graph->SetBackgroundGradient('blue', '#55eeff', GRAD_HOR, BGRAD_PLOT);
+$graph->xaxis->SetTickLabels(array('A','B','C','D','E','F','G'));
+
+// Create the line
+$p1 = new LinePlot($datay);
+$graph->Add($p1);
+
+$p1->SetFillGradient('yellow','red');
+$p1->SetStepStyle();
+$p1->SetColor('#808000');
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/nullvalueex01.php b/web/classes/jpgraph/Examples/nullvalueex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..33088117d860056232bbefd0a4be0608d07d7817
--- /dev/null
+++ b/web/classes/jpgraph/Examples/nullvalueex01.php
@@ -0,0 +1,56 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some data
+$datax = array("2001-04-01","2001-04-02","2001-04-03","2001-04-04","2001-04-05","2001-04-06");
+$datay = array(28,13,24,"",90,11);
+$data2y = array(11,41,"-",33,"-",63);
+
+// Setup graph
+$graph = new Graph(400,250);
+$graph->img->SetMargin(40,150,40,80);	
+$graph->SetScale("textlin");
+$graph->SetShadow();
+
+//Setup title
+$graph->title->Set("Line plot with null values");
+
+// Use built in font
+$graph->title->SetFont(FF_ARIAL,FS_NORMAL,14);
+
+// Slightly adjust the legend from it's default position
+$graph->legend->Pos(0.03,0.5,"right","center");
+$graph->legend->SetFont(FF_FONT1,FS_BOLD);
+
+// Setup X-scale
+$graph->xaxis->SetTickLabels($datax);
+$graph->xaxis->SetFont(FF_ARIAL,FS_NORMAL,8);
+$graph->xaxis->SetLabelAngle(45);
+
+// Create the first line
+$p1 = new LinePlot($datay);
+$p1->mark->SetType(MARK_FILLEDCIRCLE);
+$p1->mark->SetFillColor("red");
+$p1->mark->SetWidth(4);
+$p1->SetColor("blue");
+$p1->SetCenter();
+$p1->SetLegend("Undefined\nvariant 1");
+$graph->Add($p1);
+
+// ... and the second
+$p2 = new LinePlot($data2y);
+$p2->mark->SetType(MARK_STAR);
+$p2->mark->SetFillColor("red");
+$p2->mark->SetWidth(4);
+$p2->SetColor("red");
+$p2->SetCenter();
+$p2->SetLegend("Undefined\nvariant 2");
+$graph->Add($p2);
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/ocean_example.php b/web/classes/jpgraph/Examples/ocean_example.php
new file mode 100755
index 0000000000000000000000000000000000000000..8a09d59cebc7f920ad6236cfd2611e7c5ca16ae3
--- /dev/null
+++ b/web/classes/jpgraph/Examples/ocean_example.php
@@ -0,0 +1,58 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$theme = isset($_GET['theme']) ? $_GET['theme'] : null;
+
+$data = array (
+  0 => array (0 => 79, 1 => -25, 2 => -7, 3 => 85, 4 => -26, 5 => -32, ),
+  1 => array (0 => 76, 1 => 51, 2 => 86, 3 => 12, 4 => -7, 5 => 94, ),
+  2 => array (0 => 49, 1 => 38, 2 => 7, 3 => -40, 4 => 9, 5 => -7, ),
+  3 => array ( 0 => 69, 1 => 96, 2 => 49, 3 => 7, 4 => 92, 5 => -38, ),
+  4 => array ( 0 => 68, 1 => 16, 2 => 82, 3 => -49, 4 => 50, 5 => 7, ),
+  5 => array ( 0 => -37, 1 => 28, 2 => 32, 3 => 6, 4 => 13, 5 => 57, ),
+  6 => array ( 0 => 24, 1 => -11, 2 => 7, 3 => 10, 4 => 51, 5 => 51, ),
+  7 => array ( 0 => 3, 1 => -1, 2 => -12, 3 => 61, 4 => 10, 5 => 47, ),
+  8 => array ( 0 => -47, 1 => -21, 2 => 43, 3 => 53, 4 => 36, 5 => 34, ),
+);
+
+
+// Create the graph. These two calls are always required
+$graph = new Graph(400,300);    
+
+$graph->SetScale("textlin");
+if ($theme) {
+  $graph->SetTheme(new $theme());
+}
+$theme_class = new OceanTheme;
+$graph->SetTheme($theme_class);
+
+$plot = array();
+// Create the bar plots
+for ($i = 0; $i < 4; $i++) {
+  $plot[$i] = new BarPlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.($i+1));
+}
+//$acc1 = new AccBarPlot(array($plot[0], $plot[1]));
+//$acc1->value->Show();
+$gbplot = new GroupBarPlot(array($plot[2], $plot[1] ));
+
+for ($i = 4; $i < 8; $i++) {
+  $plot[$i] = new LinePlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.$i);
+  $plot[$i]->value->Show();
+}
+
+$graph->Add($gbplot);
+$graph->Add($plot[4]);
+
+$title = "OceanTheme Example";
+$title = mb_convert_encoding($title,'UTF-8');
+$graph->title->Set($title);
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/odoex00.php b/web/classes/jpgraph/Examples/odoex00.php
new file mode 100755
index 0000000000000000000000000000000000000000..e8cef55235e3045bf2c49486e7dee3c57a675bea
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odoex00.php
@@ -0,0 +1,47 @@
+<?php
+//=============================================================================
+// File:	ODOEX00.PHP
+// Description: Example 0 for odometer graphs
+// Created:	2002-02-22
+// Version:	$Id$
+// 
+// Comment:
+// Example file for odometer graph. This examples demonstrates the simplest
+// possible graph using all default values for colors, sizes etc.
+//
+// Copyright (C) 2002 Johan Persson. All rights reserved.
+//=============================================================================
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+//---------------------------------------------------------------------
+// Create a new odometer graph (width=250, height=200 pixels)
+//---------------------------------------------------------------------
+$graph = new OdoGraph(250,130);
+$graph->SetColor('white');
+$graph->SetMarginColor('white');
+$graph->SetFrame(false);
+
+//---------------------------------------------------------------------
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+//---------------------------------------------------------------------
+$odo = new Odometer(); 
+
+//---------------------------------------------------------------------
+// Set display value for the odometer
+//---------------------------------------------------------------------
+$odo->needle->Set(40);
+
+//---------------------------------------------------------------------
+// Add the odometer to the graph
+//---------------------------------------------------------------------
+$graph->Add($odo);
+
+//---------------------------------------------------------------------
+// ... and finally stroke and stream the image back to the browser
+//---------------------------------------------------------------------
+$graph->Stroke();
+
+// EOF
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odoex01.php b/web/classes/jpgraph/Examples/odoex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..3d29aa02b213a0fea43bfe11b860e61ba58dc7bc
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odoex01.php
@@ -0,0 +1,69 @@
+<?php
+//=============================================================================
+// File:	ODOEX01.PHP
+// Description: Example 1 for odometer graphs
+// Created:	2002-02-22
+// Version:	$Id$
+// 
+// Comment:
+// Example file for odometer graph. This examples extends odoex00
+// by adding titles, captions and indicator band to the fascia.
+//
+// Copyright (C) 2002 Johan Persson. All rights reserved.
+//=============================================================================
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+//---------------------------------------------------------------------
+// Create a new odometer graph (width=250, height=200 pixels)
+//---------------------------------------------------------------------
+$graph = new OdoGraph(250,200);
+
+//---------------------------------------------------------------------
+// Specify title and subtitle using default fonts
+// * Note each title may be multilines by using a '\n' as a line
+// divider.
+//---------------------------------------------------------------------
+$graph->title->Set("Odometer title");
+$graph->title->SetColor("white");
+$graph->subtitle->Set("2002-02-13");
+$graph->subtitle->SetColor("white");
+
+//---------------------------------------------------------------------
+// Specify caption.
+// * (This is the text at the bottom of the graph.) The margins will
+// automatically adjust to fit the height of the text. A caption
+// may have multiple lines by including a '\n' character in the 
+// string.
+//---------------------------------------------------------------------
+$graph->caption->Set("First caption row\n... second row");
+$graph->caption->SetColor("white");
+
+//---------------------------------------------------------------------
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+//---------------------------------------------------------------------
+$odo = new Odometer(); 
+
+//---------------------------------------------------------------------
+// Set color indication between values 80 and 100 as red
+//---------------------------------------------------------------------
+$odo->AddIndication(80,100,"red");
+
+//---------------------------------------------------------------------
+// Set display value for the odometer
+//---------------------------------------------------------------------
+$odo->needle->Set(30);
+
+//---------------------------------------------------------------------
+// Add the odometer to the graph
+//---------------------------------------------------------------------
+$graph->Add($odo);
+
+//---------------------------------------------------------------------
+// ... and finally stroke and stream the image back to the browser
+//---------------------------------------------------------------------
+$graph->Stroke();
+
+// EOF
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odoex010.php b/web/classes/jpgraph/Examples/odoex010.php
new file mode 100755
index 0000000000000000000000000000000000000000..3c70ad2f6faeeabe9dd9473a950a7b0775889ab3
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odoex010.php
@@ -0,0 +1,75 @@
+<?php
+//=============================================================================
+// File:	ODOEX010.PHP
+// Description: Example 0 for odometer graphs
+// Created:	2002-02-22
+// Version:	$Id$
+// 
+// Comment:
+// Example file for odometer graph. Extends odoex09.php to show how multiple
+// odometers can have different properties
+//
+// Copyright (C) 2002 Johan Persson. All rights reserved.
+//=============================================================================
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+//---------------------------------------------------------------------
+// Create a new odometer graph (width=250, height=200 pixels)
+//---------------------------------------------------------------------
+$graph = new OdoGraph(200,300);
+
+//---------------------------------------------------------------------
+// We will display three odometers stacked vertically
+// The first thing to do is to create them
+//---------------------------------------------------------------------
+$odo1 = new Odometer(); 
+$odo2 = new Odometer(); 
+$odo3 = new Odometer(); 
+
+//---------------------------------------------------------------------
+// Set Indicator bands for the odometers
+//---------------------------------------------------------------------
+$odo1->AddIndication(80,100,"red");
+$odo2->AddIndication(20,30,"green");
+$odo2->AddIndication(65,100,"red");
+$odo3->AddIndication(60,90,"yellow");
+$odo3->AddIndication(90,100,"red");
+
+//---------------------------------------------------------------------
+// Set display values for the odometers
+//---------------------------------------------------------------------
+$odo1->needle->Set(17);
+$odo2->needle->Set(47);
+$odo3->needle->Set(86);
+
+$odo1->needle->SetFillColor("blue");
+$odo2->needle->SetFillColor("yellow:0.7");
+$odo3->needle->SetFillColor("black");
+$odo3->needle->SetColor("black");
+
+
+//---------------------------------------------------------------------
+// Set scale label properties
+//---------------------------------------------------------------------
+$odo1->scale->label->SetColor("navy");
+$odo2->scale->label->SetColor("blue");
+$odo3->scale->label->SetColor("darkred");
+
+$odo1->scale->label->SetFont(FF_FONT1);
+$odo2->scale->label->SetFont(FF_FONT2,FS_BOLD);
+$odo3->scale->label->SetFont(FF_ARIAL,FS_BOLD,11);
+
+//---------------------------------------------------------------------
+// Add the odometers to the graph using a vertical layout
+//---------------------------------------------------------------------
+$l1 = new LayoutVert( array($odo1,$odo2,$odo3) ) ;
+$graph->Add( $l1 );
+
+//---------------------------------------------------------------------
+// ... and finally stroke and stream the image back to the browser
+//---------------------------------------------------------------------
+$graph->Stroke();
+
+// EOF
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odoex011.php b/web/classes/jpgraph/Examples/odoex011.php
new file mode 100755
index 0000000000000000000000000000000000000000..cc74f4f70260782b84525d55b801ade9e4a25b03
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odoex011.php
@@ -0,0 +1,108 @@
+<?php
+//=============================================================================
+// File:	ODOEX011.PHP
+// Description: Example 0 for odometer graphs
+// Created:	2002-02-22
+// Version:	$Id$
+// 
+// Comment:
+// Example file for odometer graph. Extends odoex10.php with graph titles
+// and captions and also adds individual captions for each odometer.
+
+//
+// Copyright (C) 2002 Johan Persson. All rights reserved.
+//=============================================================================
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+//---------------------------------------------------------------------
+// Create a new odometer graph (width=200, height=400 pixels)
+//---------------------------------------------------------------------
+$graph = new OdoGraph(200,370);
+$graph->SetShadow();
+
+//---------------------------------------------------------------------
+// Specify title and subtitle using default fonts
+// * Note each title may be multilines by using a '\n' as a line
+// divider.
+//---------------------------------------------------------------------
+$graph->title->Set("Result from 2002");
+$graph->title->SetColor("white");
+$graph->subtitle->Set("O1 - W-Site");
+$graph->subtitle->SetColor("white");
+
+//---------------------------------------------------------------------
+// Specify caption.
+// * (This is the text at the bottom of the graph.) The margins will
+// automatically adjust to fit the height of the text. A caption
+// may have multiple lines by including a '\n' character in the 
+// string.
+//---------------------------------------------------------------------
+$graph->caption->Set("Fig1. Values within 85%\nconfidence intervall");
+$graph->caption->SetColor("white");
+
+//---------------------------------------------------------------------
+// We will display three odometers stacked vertically
+// The first thing to do is to create them
+//---------------------------------------------------------------------
+$odo1 = new Odometer(); 
+$odo2 = new Odometer(); 
+$odo3 = new Odometer(); 
+
+
+//---------------------------------------------------------------------
+// Set caption for each odometer
+//---------------------------------------------------------------------
+$odo1->caption->Set("April");
+$odo1->caption->SetFont(FF_FONT2,FS_BOLD);
+$odo2->caption->Set("May");
+$odo2->caption->SetFont(FF_FONT2,FS_BOLD);
+$odo3->caption->Set("June");
+$odo3->caption->SetFont(FF_FONT2,FS_BOLD);
+
+//---------------------------------------------------------------------
+// Set Indicator bands for the odometers
+//---------------------------------------------------------------------
+$odo1->AddIndication(80,100,"red");
+$odo2->AddIndication(20,30,"green");
+$odo2->AddIndication(65,100,"red");
+$odo3->AddIndication(60,90,"yellow");
+$odo3->AddIndication(90,100,"red");
+
+//---------------------------------------------------------------------
+// Set display values for the odometers
+//---------------------------------------------------------------------
+$odo1->needle->Set(17);
+$odo2->needle->Set(47);
+$odo3->needle->Set(86);
+
+$odo1->needle->SetFillColor("blue");
+$odo2->needle->SetFillColor("yellow:0.7");
+$odo3->needle->SetFillColor("black");
+$odo3->needle->SetColor("black");
+
+
+//---------------------------------------------------------------------
+// Set scale label properties
+//---------------------------------------------------------------------
+$odo1->scale->label->SetColor("navy");
+$odo2->scale->label->SetColor("blue");
+$odo3->scale->label->SetColor("darkred");
+
+$odo1->scale->label->SetFont(FF_FONT1);
+$odo2->scale->label->SetFont(FF_FONT2,FS_BOLD);
+$odo3->scale->label->SetFont(FF_ARIAL,FS_BOLD,10);
+
+//---------------------------------------------------------------------
+// Add the odometers to the graph using a vertical layout
+//---------------------------------------------------------------------
+$l1 = new LayoutVert( array($odo1,$odo2,$odo3) ) ;
+$graph->Add( $l1 );
+
+//---------------------------------------------------------------------
+// ... and finally stroke and stream the image back to the browser
+//---------------------------------------------------------------------
+$graph->Stroke();
+
+// EOF
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odoex012.php b/web/classes/jpgraph/Examples/odoex012.php
new file mode 100755
index 0000000000000000000000000000000000000000..b54f773dfd11aebed7174092bc9349a7c6558d9a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odoex012.php
@@ -0,0 +1,119 @@
+<?php
+//=============================================================================
+// File:	ODOEX012.PHP
+// Description: Example 0 for odometer graphs
+// Created:	2002-02-22
+// Version:	$Id$
+// 
+// Comment:
+// Example file for odometer graph. Extends odoex11.php to add two more
+// odometers to the image and showing more layout possibilities 
+//
+// Copyright (C) 2002 Johan Persson. All rights reserved.
+//=============================================================================
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+//---------------------------------------------------------------------
+// Create a new odometer graph (width=400, height=400 pixels)
+//---------------------------------------------------------------------
+$graph = new OdoGraph(400,370);
+$graph->SetShadow();
+
+//---------------------------------------------------------------------
+// Specify title and subtitle using default fonts
+// * Note each title may be multilines by using a '\n' as a line
+// divider.
+//---------------------------------------------------------------------
+$graph->title->Set("Result from 2002");
+$graph->title->SetColor("white");
+$graph->subtitle->Set("O1 - W-Site");
+$graph->subtitle->SetColor("white");
+
+//---------------------------------------------------------------------
+// Specify caption.
+// * (This is the text at the bottom of the graph.) The margins will
+// automatically adjust to fit the height of the text. A caption
+// may have multiple lines by including a '\n' character in the 
+// string.
+//---------------------------------------------------------------------
+$graph->caption->Set("Fig1. Values within 85%\nconfidence intervall");
+$graph->caption->SetColor("white");
+
+//---------------------------------------------------------------------
+// We will display two columns where the first column has
+// three odometers (same as in example 11) and the second column
+// has two odoemters
+// The first thing to do is to create them
+//---------------------------------------------------------------------
+$odo1 = new Odometer(); 
+$odo2 = new Odometer(); 
+$odo3 = new Odometer(); 
+$odo4 = new Odometer(); 
+$odo5 = new Odometer(); 
+
+
+//---------------------------------------------------------------------
+// Set caption for each odometer
+//---------------------------------------------------------------------
+$odo1->caption->Set("April");
+$odo1->caption->SetFont(FF_ARIAL,FS_BOLD);
+$odo2->caption->Set("May");
+$odo2->caption->SetFont(FF_FONT2,FS_BOLD);
+$odo3->caption->Set("June");
+$odo3->caption->SetFont(FF_FONT2,FS_BOLD);
+$odo4->caption->Set("Daily low average");
+$odo4->caption->SetFont(FF_FONT1,FS_BOLD);
+$odo5->caption->Set("Daily high average");
+$odo5->caption->SetFont(FF_FONT1,FS_BOLD);
+
+//---------------------------------------------------------------------
+// Set Indicator bands for the odometers
+//---------------------------------------------------------------------
+$odo1->AddIndication(80,100,"red");
+$odo2->AddIndication(20,30,"green");
+$odo2->AddIndication(65,100,"red");
+$odo3->AddIndication(60,90,"yellow");
+$odo3->AddIndication(90,100,"red");
+
+//---------------------------------------------------------------------
+// Set display values for the odometers
+//---------------------------------------------------------------------
+$odo1->needle->Set(17);
+$odo2->needle->Set(47);
+$odo3->needle->Set(86);
+$odo4->needle->Set(22);
+$odo5->needle->Set(77);
+
+$odo1->needle->SetFillColor("blue");
+$odo2->needle->SetFillColor("yellow:0.7");
+$odo3->needle->SetFillColor("black");
+$odo3->needle->SetColor("black");
+
+
+//---------------------------------------------------------------------
+// Set scale label properties
+//---------------------------------------------------------------------
+$odo1->scale->label->SetColor("navy");
+$odo2->scale->label->SetColor("blue");
+$odo3->scale->label->SetColor("darkred");
+
+$odo1->scale->label->SetFont(FF_FONT1);
+$odo2->scale->label->SetFont(FF_FONT2,FS_BOLD);
+$odo3->scale->label->SetFont(FF_ARIAL,FS_BOLD,10);
+
+//---------------------------------------------------------------------
+// Add the odometers to the graph using a vertical layout
+//---------------------------------------------------------------------
+$l1 = new LayoutVert( array($odo1,$odo2,$odo3) ) ;
+$l2 = new LayoutVert( array($odo4,$odo5) ) ;
+$l3 = new LayoutHor( array($l1,$l2) );
+$graph->Add( $l3 );
+
+//---------------------------------------------------------------------
+// ... and finally stroke and stream the image back to the browser
+//---------------------------------------------------------------------
+$graph->Stroke();
+
+// EOF
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odoex02.php b/web/classes/jpgraph/Examples/odoex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..47ccc6bae9ed32a982045a37213c610c4732ab89
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odoex02.php
@@ -0,0 +1,71 @@
+<?php
+//=============================================================================
+// File:	ODOEX02.PHP
+// Description: Example 1 for odometer graphs
+// Created:	2002-02-22
+// Version:	$Id$
+// 
+// Comment:
+// Example file for odometer graph. This examples extends odoex01
+// by adding several indicator bands to the fascia.
+//
+// Copyright (C) 2002 Johan Persson. All rights reserved.
+//=============================================================================
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+//---------------------------------------------------------------------
+// Create a new odometer graph (width=250, height=200 pixels)
+//---------------------------------------------------------------------
+$graph = new OdoGraph(300,200);
+
+//---------------------------------------------------------------------
+// Specify title and subtitle using default fonts
+// * Note each title may be multilines by using a '\n' as a line
+// divider.
+//---------------------------------------------------------------------
+$graph->title->Set("Odometer title");
+$graph->title->SetColor("white");
+$graph->subtitle->Set("2002-02-13");
+$graph->subtitle->SetColor("white");
+
+//---------------------------------------------------------------------
+// Specify caption.
+// * (This is the text at the bottom of the graph.) The margins will
+// automatically adjust to fit the height of the text. A caption
+// may have multiple lines by including a '\n' character in the 
+// string.
+//---------------------------------------------------------------------
+$graph->caption->Set("First caption row\n... second row");
+$graph->caption->SetColor("white");
+
+//---------------------------------------------------------------------
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+//---------------------------------------------------------------------
+$odo = new Odometer(); 
+
+//---------------------------------------------------------------------
+// Set color indication 
+//---------------------------------------------------------------------
+$odo->AddIndication(0,50,"green");
+$odo->AddIndication(50,80,"yellow");
+$odo->AddIndication(80,100,"red");
+
+//---------------------------------------------------------------------
+// Set display value for the odometer
+//---------------------------------------------------------------------
+$odo->needle->Set(30);
+
+//---------------------------------------------------------------------
+// Add the odometer to the graph
+//---------------------------------------------------------------------
+$graph->Add($odo);
+
+//---------------------------------------------------------------------
+// ... and finally stroke and stream the image back to the browser
+//---------------------------------------------------------------------
+$graph->Stroke();
+
+// EOF
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odoex03.php b/web/classes/jpgraph/Examples/odoex03.php
new file mode 100755
index 0000000000000000000000000000000000000000..91ca401c80e5f110c3d41270d2e2d1cf1fefc739
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odoex03.php
@@ -0,0 +1,83 @@
+<?php
+//=============================================================================
+// File:	ODOEX03.PHP
+// Description: Example 1 for odometer graphs
+// Created:	2002-02-22
+// Version:	$Id$
+// 
+// Comment:
+// Example file for odometer graph. This examples extends odoex02
+// by changing scale tick interval and scale fonts.
+//
+// Copyright (C) 2002 Johan Persson. All rights reserved.
+//=============================================================================
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+//---------------------------------------------------------------------
+// Create a new odometer graph (width=250, height=200 pixels)
+//---------------------------------------------------------------------
+$graph = new OdoGraph(250,200);
+$graph->SetShadow();
+
+//---------------------------------------------------------------------
+// Specify title and subtitle using default fonts
+// * Note each title may be multilines by using a '\n' as a line
+// divider.
+//---------------------------------------------------------------------
+$graph->title->Set("Odometer title");
+$graph->title->SetColor("white");
+$graph->subtitle->Set("2002-02-13");
+$graph->subtitle->SetColor("white");
+
+//---------------------------------------------------------------------
+// Specify caption.
+// * (This is the text at the bottom of the graph.) The margins will
+// automatically adjust to fit the height of the text. A caption
+// may have multiple lines by including a '\n' character in the 
+// string.
+//---------------------------------------------------------------------
+$graph->caption->Set("First caption row\n... second row");
+$graph->caption->SetColor("white");
+
+//---------------------------------------------------------------------
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+//---------------------------------------------------------------------
+$odo = new Odometer(); 
+
+//---------------------------------------------------------------------
+// Set color indication 
+//---------------------------------------------------------------------
+$odo->AddIndication(0,50,"green");
+$odo->AddIndication(50,80,"yellow");
+$odo->AddIndication(80,100,"red");
+
+//---------------------------------------------------------------------
+// Adjust scale ticks to be shown at 10 steps interval and scale
+// labels at every second tick
+//---------------------------------------------------------------------
+$odo->scale->SetTicks(10,2);
+
+//---------------------------------------------------------------------
+// Use a bold font for tick labels
+//---------------------------------------------------------------------
+$odo->scale->label->SetFont(FF_FONT1, FS_BOLD);
+
+//---------------------------------------------------------------------
+// Set display value for the odometer
+//---------------------------------------------------------------------
+$odo->needle->Set(30);
+
+//---------------------------------------------------------------------
+// Add the odometer to the graph
+//---------------------------------------------------------------------
+$graph->Add($odo);
+
+//---------------------------------------------------------------------
+// ... and finally stroke and stream the image back to the browser
+//---------------------------------------------------------------------
+$graph->Stroke();
+
+// EOF
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odoex04.php b/web/classes/jpgraph/Examples/odoex04.php
new file mode 100755
index 0000000000000000000000000000000000000000..9955b7db38b3c9d4cbaf302421f1797ff71e9eee
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odoex04.php
@@ -0,0 +1,96 @@
+<?php
+//=============================================================================
+// File:	ODOEX04.PHP
+// Description: Example 1 for odometer graphs
+// Created:	2002-02-22
+// Version:	$Id$
+// 
+// Comment:
+// Example file for odometer graph. This examples extends odoex03
+// by 1) changing the indicator needle style and color 2) Introducing
+// a half circle in the middle that is not affetced by the indicator bands.
+//
+// Copyright (C) 2002 Johan Persson. All rights reserved.
+//=============================================================================
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+//---------------------------------------------------------------------
+// Create a new odometer graph (width=250, height=200 pixels)
+//---------------------------------------------------------------------
+$graph = new OdoGraph(250,200);
+
+//---------------------------------------------------------------------
+// Specify title and subtitle using default fonts
+// * Note each title may be multilines by using a '\n' as a line
+// divider.
+//---------------------------------------------------------------------
+$graph->title->Set("Odometer title");
+$graph->title->SetColor("white");
+$graph->subtitle->Set("2002-02-13");
+$graph->subtitle->SetColor("white");
+
+//---------------------------------------------------------------------
+// Specify caption.
+// * (This is the text at the bottom of the graph.) The margins will
+// automatically adjust to fit the height of the text. A caption
+// may have multiple lines by including a '\n' character in the 
+// string.
+//---------------------------------------------------------------------
+$graph->caption->Set("First caption row\n... second row");
+$graph->caption->SetColor("white");
+
+//---------------------------------------------------------------------
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+//---------------------------------------------------------------------
+$odo = new Odometer(); 
+
+//---------------------------------------------------------------------
+// Set color indication 
+//---------------------------------------------------------------------
+$odo->AddIndication(0,50,"green");
+$odo->AddIndication(50,80,"yellow");
+$odo->AddIndication(80,100,"red");
+
+//---------------------------------------------------------------------
+// Set the center area that will not be affected by the color bands
+//---------------------------------------------------------------------
+$odo->SetCenterAreaWidth(0.4);  // Fraction of radius
+
+//---------------------------------------------------------------------
+// Adjust scale ticks to be shown at 10 steps interval and scale
+// labels at every second tick
+//---------------------------------------------------------------------
+$odo->scale->SetTicks(10,2);
+
+//---------------------------------------------------------------------
+// Use a bold font for tick labels
+//---------------------------------------------------------------------
+$odo->scale->label->SetFont(FF_FONT1, FS_BOLD);
+
+//---------------------------------------------------------------------
+// Set display value for the odometer
+//---------------------------------------------------------------------
+$odo->needle->Set(30);
+
+//---------------------------------------------------------------------
+// Set a new style for the needle
+//---------------------------------------------------------------------
+$odo->needle->SetStyle(NEEDLE_STYLE_MEDIUM_TRIANGLE);
+$odo->needle->SetLength(0.7);  // Length as 70% of the radius
+$odo->needle->SetFillColor("orange");
+
+
+//---------------------------------------------------------------------
+// Add the odometer to the graph
+//---------------------------------------------------------------------
+$graph->Add($odo);
+
+//---------------------------------------------------------------------
+// ... and finally stroke and stream the image back to the browser
+//---------------------------------------------------------------------
+$graph->Stroke();
+
+// EOF
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odoex05.php b/web/classes/jpgraph/Examples/odoex05.php
new file mode 100755
index 0000000000000000000000000000000000000000..379a06e9a25cf91cb721b3a215ee486810bff1d3
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odoex05.php
@@ -0,0 +1,123 @@
+<?php
+//=============================================================================
+// File:	ODOEX05.PHP
+// Description: Example 1 for odometer graphs
+// Created:	2002-02-22
+// Version:	$Id$
+// 
+// Comment:
+// Example file for odometer graph. This examples extends odoex04
+// by 1) changing color of odometer canvas 2) Adding a second indicator
+// needle 3) making the tick marks thicker 4) and finally adding a short
+// scale text in the middle of the odometer.
+//
+// Copyright (C) 2002 Johan Persson. All rights reserved.
+//=============================================================================
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+//---------------------------------------------------------------------
+// Create a new odometer graph (width=250, height=200 pixels)
+//---------------------------------------------------------------------
+$graph = new OdoGraph(250,200);
+
+//---------------------------------------------------------------------
+// Change the color of the odometer plotcanvas. NOT the odometer
+// fill color itself.
+//---------------------------------------------------------------------
+$graph->SetColor("lightyellow");
+
+//---------------------------------------------------------------------
+// Specify title and subtitle using default fonts
+// * Note each title may be multilines by using a '\n' as a line
+// divider.
+//---------------------------------------------------------------------
+$graph->title->Set("Odometer title");
+$graph->title->SetColor("white");
+$graph->subtitle->Set("2002-02-13");
+$graph->subtitle->SetColor("white");
+
+//---------------------------------------------------------------------
+// Specify caption.
+// * (This is the text at the bottom of the graph.) The margins will
+// automatically adjust to fit the height of the text. A caption
+// may have multiple lines by including a '\n' character in the 
+// string.
+//---------------------------------------------------------------------
+$graph->caption->Set("First caption row\n... second row");
+$graph->caption->SetColor("white");
+
+//---------------------------------------------------------------------
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+//---------------------------------------------------------------------
+$odo = new Odometer(); 
+
+//---------------------------------------------------------------------
+// Set color indication 
+//---------------------------------------------------------------------
+$odo->AddIndication(0,50,"green");
+$odo->AddIndication(50,80,"yellow");
+$odo->AddIndication(80,100,"red");
+
+//---------------------------------------------------------------------
+// Set the center area that will not be affected by the color bands
+//---------------------------------------------------------------------
+$odo->SetCenterAreaWidth(0.4);  // Fraction of radius
+
+//---------------------------------------------------------------------
+// Adjust scale ticks to be shown at 10 steps interval and scale
+// labels at every second tick
+//---------------------------------------------------------------------
+$odo->scale->SetTicks(10,2);
+
+//---------------------------------------------------------------------
+// Make the tick marks 2 pixel wide
+//---------------------------------------------------------------------
+$odo->scale->SetTickWeight(2);
+
+//---------------------------------------------------------------------
+// Use a bold font for tick labels
+//---------------------------------------------------------------------
+$odo->scale->label->SetFont(FF_FONT1, FS_BOLD);
+
+//---------------------------------------------------------------------
+// Set display value for the odometer
+//---------------------------------------------------------------------
+$odo->needle->Set(78);
+
+//---------------------------------------------------------------------
+// Specify scale caption. Note that depending on the position of the
+// indicator needle this label might be partially hidden. 
+//---------------------------------------------------------------------
+$odo->label->Set("% Passed");
+
+//---------------------------------------------------------------------
+// Set a new style for the needle
+//---------------------------------------------------------------------
+$odo->needle->SetStyle(NEEDLE_STYLE_MEDIUM_TRIANGLE);
+$odo->needle->SetLength(0.7);  // Length as 70% of the radius
+$odo->needle->SetFillColor("orange");
+
+//---------------------------------------------------------------------
+// Setup the second indicator needle
+//---------------------------------------------------------------------
+$odo->needle2->Set(24);
+$odo->needle2->SetStyle(NEEDLE_STYLE_SMALL_TRIANGLE);
+$odo->needle2->SetLength(0.55);  // Length as 70% of the radius
+$odo->needle2->SetFillColor("lightgray");
+$odo->needle2->Show();  
+
+
+//---------------------------------------------------------------------
+// Add the odometer to the graph
+//---------------------------------------------------------------------
+$graph->Add($odo);
+
+//---------------------------------------------------------------------
+// ... and finally stroke and stream the image back to the browser
+//---------------------------------------------------------------------
+$graph->Stroke();
+
+// EOF
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odoex06.php b/web/classes/jpgraph/Examples/odoex06.php
new file mode 100755
index 0000000000000000000000000000000000000000..305a5eea18d8b59e4cf9bc4e75a3e9f30c3949f4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odoex06.php
@@ -0,0 +1,122 @@
+<?php
+//=============================================================================
+// File:	ODOEX06.PHP
+// Description: Example 1 for odometer graphs
+// Created:	2002-02-22
+// Version:	$Id$
+// 
+// Comment:
+// Example file for odometer graph. This examples extends odoex05
+// by changing the type of odometer to a full circle. This is as simple
+// as changing (less than) one line of code.
+//
+// Copyright (C) 2002 Johan Persson. All rights reserved.
+//=============================================================================
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+//---------------------------------------------------------------------
+// Create a new odometer graph (width=250, height=200 pixels)
+//---------------------------------------------------------------------
+$graph = new OdoGraph(250,250);
+
+//---------------------------------------------------------------------
+// Change the color of the odometer plotcanvas. NOT the odometer
+// fill color itself.
+//---------------------------------------------------------------------
+$graph->SetColor("lightyellow");
+
+//---------------------------------------------------------------------
+// Specify title and subtitle using default fonts
+// * Note each title may be multilines by using a '\n' as a line
+// divider.
+//---------------------------------------------------------------------
+$graph->title->Set("Odometer title");
+$graph->title->SetColor("white");
+$graph->subtitle->Set("2002-02-13");
+$graph->subtitle->SetColor("white");
+
+//---------------------------------------------------------------------
+// Specify caption.
+// * (This is the text at the bottom of the graph.) The margins will
+// automatically adjust to fit the height of the text. A caption
+// may have multiple lines by including a '\n' character in the 
+// string.
+//---------------------------------------------------------------------
+$graph->caption->Set("First caption row\n... second row");
+$graph->caption->SetColor("white");
+
+//---------------------------------------------------------------------
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+//---------------------------------------------------------------------
+$odo = new Odometer(ODO_FULL); 
+
+//---------------------------------------------------------------------
+// Set color indication 
+//---------------------------------------------------------------------
+$odo->AddIndication(0,50,"green");
+$odo->AddIndication(50,80,"yellow");
+$odo->AddIndication(80,100,"red");
+
+//---------------------------------------------------------------------
+// Set the center area that will not be affected by the color bands
+//---------------------------------------------------------------------
+$odo->SetCenterAreaWidth(0.4);  // Fraction of radius
+
+//---------------------------------------------------------------------
+// Adjust scale ticks to be shown at 10 steps interval and scale
+// labels at every second tick
+//---------------------------------------------------------------------
+$odo->scale->SetTicks(10,2);
+
+//---------------------------------------------------------------------
+// Make the tick marks 2 pixel wide
+//---------------------------------------------------------------------
+$odo->scale->SetTickWeight(2);
+
+//---------------------------------------------------------------------
+// Use a bold font for tick labels
+//---------------------------------------------------------------------
+$odo->scale->label->SetFont(FF_FONT1, FS_BOLD);
+
+//---------------------------------------------------------------------
+// Set display value for the odometer
+//---------------------------------------------------------------------
+$odo->needle->Set(78);
+
+//---------------------------------------------------------------------
+// Specify scale caption. Note that depending on the position of the
+// indicator needle this label might be partially hidden. 
+//---------------------------------------------------------------------
+$odo->label->Set("% Passed");
+
+//---------------------------------------------------------------------
+// Set a new style for the needle
+//---------------------------------------------------------------------
+$odo->needle->SetStyle(NEEDLE_STYLE_MEDIUM_TRIANGLE);
+$odo->needle->SetLength(0.7);  // Length as 70% of the radius
+$odo->needle->SetFillColor("orange");
+
+//---------------------------------------------------------------------
+// Setup the second indicator needle
+//---------------------------------------------------------------------
+$odo->needle2->Set(24);
+$odo->needle2->SetStyle(NEEDLE_STYLE_SMALL_TRIANGLE);
+$odo->needle2->SetLength(0.55);  // Length as 70% of the radius
+$odo->needle2->SetFillColor("lightgray");
+$odo->needle2->Show();  
+
+
+//---------------------------------------------------------------------
+// Add the odometer to the graph
+//---------------------------------------------------------------------
+$graph->Add($odo);
+
+//---------------------------------------------------------------------
+// ... and finally stroke and stream the image back to the browser
+//---------------------------------------------------------------------
+$graph->Stroke();
+
+// EOF
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odoex07.php b/web/classes/jpgraph/Examples/odoex07.php
new file mode 100755
index 0000000000000000000000000000000000000000..eb86ba3ccaf15d9861cc6b115daed4f50630eef9
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odoex07.php
@@ -0,0 +1,126 @@
+<?php
+//=============================================================================
+// File:	ODOEX07.PHP
+// Description: Example 1 for odometer graphs
+// Created:	2002-02-22
+// Version:	$Id$
+// 
+// Comment:
+// Example file for odometer graph. This examples extends odoex06
+// by changing the start and end angles for the scale.
+//
+// Copyright (C) 2002 Johan Persson. All rights reserved.
+//=============================================================================
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+//---------------------------------------------------------------------
+// Create a new odometer graph (width=250, height=200 pixels)
+//---------------------------------------------------------------------
+$graph = new OdoGraph(250,250);
+
+//---------------------------------------------------------------------
+// Change the color of the odometer plotcanvas. NOT the odometer
+// fill color itself.
+//---------------------------------------------------------------------
+$graph->SetColor("lightyellow");
+
+//---------------------------------------------------------------------
+// Specify title and subtitle using default fonts
+// * Note each title may be multilines by using a '\n' as a line
+// divider.
+//---------------------------------------------------------------------
+$graph->title->Set("Odometer title");
+$graph->title->SetColor("white");
+$graph->subtitle->Set("2002-02-13");
+$graph->subtitle->SetColor("white");
+
+//---------------------------------------------------------------------
+// Specify caption.
+// * (This is the text at the bottom of the graph.) The margins will
+// automatically adjust to fit the height of the text. A caption
+// may have multiple lines by including a '\n' character in the 
+// string.
+//---------------------------------------------------------------------
+$graph->caption->Set("First caption row\n... second row");
+$graph->caption->SetColor("white");
+
+//---------------------------------------------------------------------
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+//---------------------------------------------------------------------
+$odo = new Odometer(ODO_FULL); 
+
+//---------------------------------------------------------------------
+// Set color indication 
+//---------------------------------------------------------------------
+$odo->AddIndication(0,50,"green");
+$odo->AddIndication(50,80,"yellow");
+$odo->AddIndication(80,100,"red");
+
+//---------------------------------------------------------------------
+// Set the center area that will not be affected by the color bands
+//---------------------------------------------------------------------
+$odo->SetCenterAreaWidth(0.4);  // Fraction of radius
+
+//---------------------------------------------------------------------
+// Adjust scale ticks to be shown at 10 steps interval and scale
+// labels at every second tick
+//---------------------------------------------------------------------
+$odo->scale->SetTicks(10,2);
+
+//---------------------------------------------------------------------
+// Make the tick marks 2 pixel wide
+//---------------------------------------------------------------------
+$odo->scale->SetTickWeight(2);
+
+//---------------------------------------------------------------------
+// Use a bold font for tick labels
+//---------------------------------------------------------------------
+$odo->scale->label->SetFont(FF_FONT1, FS_BOLD);
+
+//---------------------------------------------------------------------
+// Change the start and end angle for the scale
+//---------------------------------------------------------------------
+$odo->scale->SetAngle(20,340);
+
+//---------------------------------------------------------------------
+// Set display value for the odometer
+//---------------------------------------------------------------------
+$odo->needle->Set(64);
+
+//---------------------------------------------------------------------
+// Specify scale caption. Note that depending on the position of the
+// indicator needle this label might be partially hidden. 
+//---------------------------------------------------------------------
+$odo->label->Set("% Passed");
+
+//---------------------------------------------------------------------
+// Set a new style for the needle
+//---------------------------------------------------------------------
+$odo->needle->SetStyle(NEEDLE_STYLE_MEDIUM_TRIANGLE);
+$odo->needle->SetLength(0.7);  // Length as 70% of the radius
+$odo->needle->SetFillColor("orange");
+
+//---------------------------------------------------------------------
+// Setup the second indicator needle
+//---------------------------------------------------------------------
+$odo->needle2->Set(15);
+$odo->needle2->SetStyle(NEEDLE_STYLE_SMALL_TRIANGLE);
+$odo->needle2->SetLength(0.55);  // Length as 70% of the radius
+$odo->needle2->SetFillColor("lightgray");
+$odo->needle2->Show();  
+
+
+//---------------------------------------------------------------------
+// Add the odometer to the graph
+//---------------------------------------------------------------------
+$graph->Add($odo);
+
+//---------------------------------------------------------------------
+// ... and finally stroke and stream the image back to the browser
+//---------------------------------------------------------------------
+$graph->Stroke();
+
+// EOF
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odoex08.php b/web/classes/jpgraph/Examples/odoex08.php
new file mode 100755
index 0000000000000000000000000000000000000000..39f12e7a909a3458839f28815cca790c954dddc5
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odoex08.php
@@ -0,0 +1,150 @@
+<?php
+//=============================================================================
+// File:	ODOEX08.PHP
+// Description: Example 1 for odometer graphs
+// Created:	2002-02-22
+// Version:	$Id$
+// 
+// Comment:
+// Example file for odometer graph. This examples extends odoex07
+// by showing how 1) a drop shadow may be added to the frame
+// 2) Change the margin color 3) Change the fill color of the odometer
+// 4) adding a drop shadow to the indicator needles
+//
+// Copyright (C) 2002 Johan Persson. All rights reserved.
+//=============================================================================
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+//---------------------------------------------------------------------
+// Create a new odometer graph (width=250, height=200 pixels)
+//---------------------------------------------------------------------
+$graph = new OdoGraph(250,250);
+
+//---------------------------------------------------------------------
+// Add a drop shadow to the fram
+//---------------------------------------------------------------------
+$graph->SetShadow();
+
+//---------------------------------------------------------------------
+// Change the color of the odometer plotcanvas. NOT the odometer
+// fill color itself.
+//---------------------------------------------------------------------
+$graph->SetColor("lightyellow");
+
+//---------------------------------------------------------------------
+// Change the color of the margin in the graph
+//---------------------------------------------------------------------
+$graph->SetMarginColor("khaki:0.6");
+
+//---------------------------------------------------------------------
+// Specify title and subtitle using default fonts
+// * Note each title may be multilines by using a '\n' as a line
+// divider.
+//---------------------------------------------------------------------
+$graph->title->Set("Odometer title");
+$graph->title->SetColor("white");
+$graph->subtitle->Set("2002-02-13");
+$graph->subtitle->SetColor("white");
+
+//---------------------------------------------------------------------
+// Specify caption.
+// * (This is the text at the bottom of the graph.) The margins will
+// automatically adjust to fit the height of the text. A caption
+// may have multiple lines by including a '\n' character in the 
+// string.
+//---------------------------------------------------------------------
+$graph->caption->Set("First caption row\n... second row");
+$graph->caption->SetColor("white");
+
+//---------------------------------------------------------------------
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+//---------------------------------------------------------------------
+$odo = new Odometer(ODO_FULL); 
+
+//---------------------------------------------------------------------
+// Set fill color for odometer
+//---------------------------------------------------------------------
+$odo->SetColor("lightblue");
+
+//---------------------------------------------------------------------
+// Set color indication 
+//---------------------------------------------------------------------
+$odo->AddIndication(0,50,"green");
+$odo->AddIndication(50,80,"yellow");
+$odo->AddIndication(80,100,"red");
+
+//---------------------------------------------------------------------
+// Set the center area that will not be affected by the color bands
+//---------------------------------------------------------------------
+$odo->SetCenterAreaWidth(0.4);  // Fraction of radius
+
+//---------------------------------------------------------------------
+// Adjust scale ticks to be shown at 10 steps interval and scale
+// labels at every second tick
+//---------------------------------------------------------------------
+$odo->scale->SetTicks(10,2);
+
+//---------------------------------------------------------------------
+// Make the tick marks 2 pixel wide
+//---------------------------------------------------------------------
+$odo->scale->SetTickWeight(2);
+
+//---------------------------------------------------------------------
+// Use a bold font for tick labels
+//---------------------------------------------------------------------
+$odo->scale->label->SetFont(FF_FONT1, FS_BOLD);
+
+//---------------------------------------------------------------------
+// Change the start and end angle for the scale
+//---------------------------------------------------------------------
+$odo->scale->SetAngle(20,340);
+
+//---------------------------------------------------------------------
+// Set display value for the odometer
+//---------------------------------------------------------------------
+$odo->needle->Set(64);
+
+//---------------------------------------------------------------------
+// Specify scale caption. Note that depending on the position of the
+// indicator needle this label might be partially hidden. 
+//---------------------------------------------------------------------
+$odo->label->Set("% Passed");
+
+//---------------------------------------------------------------------
+// Set a new style for the needle
+//---------------------------------------------------------------------
+$odo->needle->SetStyle(NEEDLE_STYLE_MEDIUM_TRIANGLE);
+$odo->needle->SetLength(0.7);  // Length as 70% of the radius
+$odo->needle->SetFillColor("orange");
+
+//---------------------------------------------------------------------
+// Setup the second indicator needle
+//---------------------------------------------------------------------
+$odo->needle2->Set(15);
+$odo->needle2->SetStyle(NEEDLE_STYLE_SMALL_TRIANGLE);
+$odo->needle2->SetLength(0.55);  // Length as 70% of the radius
+$odo->needle2->SetFillColor("lightgray");
+
+// Only the first needle is shown by default 
+$odo->needle2->Show();  
+
+//---------------------------------------------------------------------
+// Add a drop shadow to the indicator needles
+//---------------------------------------------------------------------
+$odo->needle->SetShadow();  
+$odo->needle2->SetShadow();  
+
+//---------------------------------------------------------------------
+// Add the odometer to the graph
+//---------------------------------------------------------------------
+$graph->Add($odo);
+
+//---------------------------------------------------------------------
+// ... and finally stroke and stream the image back to the browser
+//---------------------------------------------------------------------
+$graph->Stroke();
+
+// EOF
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odoex09.php b/web/classes/jpgraph/Examples/odoex09.php
new file mode 100755
index 0000000000000000000000000000000000000000..9fc9affeab6b9eaf6caf7ebb214fc4805062f8e1
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odoex09.php
@@ -0,0 +1,49 @@
+<?php
+//=============================================================================
+// File:	ODOEX09.PHP
+// Description: Example 0 for odometer graphs
+// Created:	2002-02-22
+// Version:	$Id$
+// 
+// Comment:
+// Example file for odometer graph. Extends odoex00.php to show how multiple
+// odometers may be combined in the same graph.
+//
+// Copyright (C) 2002 Johan Persson. All rights reserved.
+//=============================================================================
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+//---------------------------------------------------------------------
+// Create a new odometer graph (width=250, height=200 pixels)
+//---------------------------------------------------------------------
+$graph = new OdoGraph(200,300);
+
+//---------------------------------------------------------------------
+// We will display three odometers stacked vertically
+// The first thing to do is to create them
+//---------------------------------------------------------------------
+$odo1 = new Odometer(); 
+$odo2 = new Odometer(); 
+$odo3 = new Odometer(); 
+
+//---------------------------------------------------------------------
+// Set display value for the odometers
+//---------------------------------------------------------------------
+$odo1->needle->Set(17);
+$odo2->needle->Set(47);
+$odo3->needle->Set(86);
+
+//---------------------------------------------------------------------
+// Add the odometers to the graph using a vertical layout
+//---------------------------------------------------------------------
+$l1 = new LayoutVert( array($odo1,$odo2,$odo3) ) ;
+$graph->Add( $l1 );
+
+//---------------------------------------------------------------------
+// ... and finally stroke and stream the image back to the browser
+//---------------------------------------------------------------------
+$graph->Stroke();
+
+// EOF
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odotutex00.php b/web/classes/jpgraph/Examples/odotutex00.php
new file mode 100755
index 0000000000000000000000000000000000000000..4344292dec48bd2839bbfbeec046f016db65e3a6
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex00.php
@@ -0,0 +1,21 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(250,140);
+
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+$odo = new Odometer();
+
+// Set display value for the odometer
+$odo->needle->Set(30);
+
+// Add the odometer to the graph
+$graph->Add($odo);
+
+// ... and finally stroke and stream the image back to the client
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/odotutex01.php b/web/classes/jpgraph/Examples/odotutex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..ec970cd424721413e28fff02a309ec2e9df2ab51
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex01.php
@@ -0,0 +1,21 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(250,140);
+
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+$odo = new Odometer(ODO_FULL);
+
+// Set display value for the odometer
+$odo->needle->Set(30);
+
+// Add the odometer to the graph
+$graph->Add($odo);
+
+// ... and finally stroke and stream the image back to the client
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/odotutex02.php b/web/classes/jpgraph/Examples/odotutex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..a007c1b18f5548e3c86e823dda8e3c79bfb40b90
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex02.php
@@ -0,0 +1,30 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(250,180);
+
+// Setup titles
+$graph->title->Set("Result for 2002");
+$graph->title->SetColor("white");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph->subtitle->Set("New York Office");
+$graph->subtitle->SetColor("white");
+$graph->caption->Set("Figure 1. Branch results.");
+$graph->caption->SetColor("white");
+
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+$odo = new Odometer();
+
+// Set display value for the odometer
+$odo->needle->Set(30);
+
+// Add the odometer to the graph
+$graph->Add($odo);
+
+// ... and finally stroke and stream the image back to the client
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/odotutex03.php b/web/classes/jpgraph/Examples/odotutex03.php
new file mode 100755
index 0000000000000000000000000000000000000000..3c0e907c690539c8b9124e4a02636bd707377290
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex03.php
@@ -0,0 +1,30 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(250,200);
+
+// Setup titles
+$graph->title->Set("Result for 2002");
+$graph->title->SetColor("white");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph->subtitle->Set("New York Office");
+$graph->subtitle->SetColor("white");
+$graph->caption->Set("Figure 1.This is a very, very\nlong text with multiples lines\nthat are added as a caption.");
+$graph->caption->SetColor("white");
+
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+$odo = new Odometer();
+
+// Set display value for the odometer
+$odo->needle->Set(30);
+
+// Add the odometer to the graph
+$graph->Add($odo);
+
+// ... and finally stroke and stream the image back to the client
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/odotutex04.php b/web/classes/jpgraph/Examples/odotutex04.php
new file mode 100755
index 0000000000000000000000000000000000000000..60c57fc70e454e9fdd3648b7b227694879699267
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex04.php
@@ -0,0 +1,40 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(250,200);
+
+// Setup titles
+$graph->title->Set("Result for 2002");
+$graph->title->SetColor("white");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph->subtitle->Set("New York Office");
+$graph->subtitle->SetColor("white");
+$graph->caption->Set("Figure 1.This is a very, very\nlong text with multiples lines\nthat are added as a caption.");
+$graph->caption->SetColor("white");
+
+// Setup colors
+// Make the border 40% darker than normal "khaki"
+$graph->SetMarginColor("khaki:0.6");
+$graph->SetColor("khaki");
+
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+$odo = new Odometer();
+
+// Setup colors for odometyer plot
+$odo->SetColor('white');
+$odo->scale->label->SetColor("darkred");
+$odo->needle->SetFillColor("yellow");
+
+// Set display value for the odometer
+$odo->needle->Set(30);
+
+// Add the odometer to the graph
+$graph->Add($odo);
+
+// ... and finally stroke and stream the image back to the client
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/odotutex06.php b/web/classes/jpgraph/Examples/odotutex06.php
new file mode 100755
index 0000000000000000000000000000000000000000..4161e5fa448b01dde669170c951d535f1b9374e1
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex06.php
@@ -0,0 +1,43 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(570,220);
+
+$nstyle = array(
+	NEEDLE_STYLE_SIMPLE, NEEDLE_STYLE_STRAIGHT, NEEDLE_STYLE_ENDARROW,
+	NEEDLE_STYLE_SMALL_TRIANGLE,NEEDLE_STYLE_MEDIUM_TRIANGLE,
+	NEEDLE_STYLE_LARGE_TRIANGLE
+);
+
+$captions = array(
+	"NEEDLE_STYLE_SIMPLE","NEEDLE_STYLE_STRAIGHT","NEEDLE_STYLE_ENDARROW",
+	"NEEDLE_STYLE_SMALL_TRIANGLE","NEEDLE_STYLE_MEDIUM_TRIANGLE",
+	"NEEDLE_STYLE_LARGE_TRIANGLE"
+);
+
+$odo = array();
+
+for( $i=0; $i < 6; ++$i ) {
+	$odo[$i] = new Odometer();
+	$odo[$i]->SetColor("lightyellow");
+	$odo[$i]->needle->Set(80);
+	$odo[$i]->needle->SetStyle($nstyle[$i]);
+	$odo[$i]->caption->Set($captions[$i]);
+	$odo[$i]->caption->SetFont(FF_FONT1);
+	$odo[$i]->caption->SetMargin(3);
+}
+
+// Use the automatic layout engine to positon the plots on the graph
+$row1 = new LayoutHor( array($odo[0],$odo[1],$odo[2]) );
+$row2 = new LayoutHor( array($odo[3],$odo[4],$odo[5]) );
+$col1 = new LayoutVert( array($row1,$row2) );
+
+// Add the odometer to the graph
+$graph->Add($col1);
+
+// ... and finally stroke and stream the image back to the browser
+$graph->Stroke();
+
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odotutex07.php b/web/classes/jpgraph/Examples/odotutex07.php
new file mode 100755
index 0000000000000000000000000000000000000000..a1ba22bbb3a7fd0cdcefddbeab10355c8ff65fda
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex07.php
@@ -0,0 +1,37 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(570,250);
+
+$odo = array();
+$astyles = array(
+	NEEDLE_ARROW_SS,NEEDLE_ARROW_SM,NEEDLE_ARROW_SL,
+	NEEDLE_ARROW_MS,NEEDLE_ARROW_MM, NEEDLE_ARROW_ML,
+	NEEDLE_ARROW_LS, NEEDLE_ARROW_LM, NEEDLE_ARROW_LL
+	);
+$acaptions = array(
+	'SS','SM','SL','MS','MM','ML','LS','LM','LL'
+);
+
+for($i = 0; $i < 9; ++$i ) {
+	$odo[$i] = 	new Odometer();
+	$odo[$i]->SetColor("lightyellow");
+	$odo[$i]->needle->Set(75);
+	$odo[$i]->needle->SetStyle(NEEDLE_STYLE_ENDARROW, $astyles[$i]);
+	$odo[$i]->caption->SetFont(FF_FONT1,FS_BOLD);
+	$odo[$i]->caption->Set('Arrow: '.$acaptions[$i]);
+}
+
+$row1 = new LayoutHor( array($odo[0],$odo[1],$odo[2]) );
+$row2 = new LayoutHor( array($odo[3],$odo[4],$odo[5]) );
+$row3 = new LayoutHor( array($odo[6],$odo[7],$odo[8]) );
+$col1 = new LayoutVert( array($row1,$row2,$row3) );
+
+// Add the odometer to the graph
+$graph->Add($col1);
+
+// ... and finally stroke and stream the image back to the browser
+$graph->Stroke();
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odotutex08.1.php b/web/classes/jpgraph/Examples/odotutex08.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..676ac4c8b8302e3291f3ea7b904d5f4b1c2455d9
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex08.1.php
@@ -0,0 +1,41 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(250,140);
+
+// Setup a title
+$graph->title->Set('An example with thick border');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,11);
+
+// Add drop shadow for graph
+$graph->SetShadow();
+
+// Set some nonstandard colors
+$color = array(205,220,205);
+$graph->SetMarginColor($color);
+$graph->SetColor($color);
+
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+$odo = new Odometer();
+$odo->SetColor('white');
+$odo->SetBorder('darkgreen:0.8',5);
+
+$odo->scale->label->SetFont(FF_ARIAL,FS_BOLD,10);
+$odo->scale->label->SetColor('brown:0.6');
+
+// Set display value for the odometer
+$odo->needle->Set(70);
+
+// Add drop shadow for needle
+$odo->needle->SetShadow();
+
+// Add the odometer to the graph
+$graph->Add($odo);
+
+// ... and finally stroke and stream the image back to the browser
+$graph->Stroke();
+
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odotutex08.php b/web/classes/jpgraph/Examples/odotutex08.php
new file mode 100755
index 0000000000000000000000000000000000000000..8132e732f382c60fe22c4d4ad5c554b212162713
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex08.php
@@ -0,0 +1,36 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(250,140);
+
+// Setup a title
+$graph->title->Set('An example with drop shadows');
+
+// Add drop shadow for graph
+$graph->SetShadow();
+
+// Set some nonstandard colors
+$color = array(205,220,205);
+$graph->SetMarginColor($color);
+$graph->SetColor($color);
+
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+$odo = new Odometer();
+$odo->SetColor('white');
+
+// Set display value for the odometer
+$odo->needle->Set(70);
+
+// Add drop shadow for needle
+$odo->needle->SetShadow();
+
+// Add the odometer to the graph
+$graph->Add($odo);
+
+// ... and finally stroke and stream the image back to the browser
+$graph->Stroke();
+
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odotutex09.php b/web/classes/jpgraph/Examples/odotutex09.php
new file mode 100755
index 0000000000000000000000000000000000000000..82a2c4b3e7f711c200b8d5298e9bc01316cd74ef
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex09.php
@@ -0,0 +1,38 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(600,300);
+
+$odo = array();
+$astyles = array(
+	NEEDLE_ARROW_SS,NEEDLE_ARROW_SM,NEEDLE_ARROW_SL,
+	NEEDLE_ARROW_MS,NEEDLE_ARROW_MM, NEEDLE_ARROW_ML,
+	NEEDLE_ARROW_LS, NEEDLE_ARROW_LM, NEEDLE_ARROW_LL
+	);
+$acaptions = array(
+	'SS','SM','SL','MS','MM','ML','LS','LM','LL'
+);
+
+for($i = 0; $i < 9; ++$i ) {
+	$odo[$i] = 	new Odometer();
+	$odo[$i]->SetColor("lightyellow");
+	$odo[$i]->needle->Set(75);
+	$odo[$i]->needle->SetStyle(NEEDLE_STYLE_ENDARROW, $astyles[$i]);
+	$odo[$i]->caption->SetFont(FF_FONT1);
+	$odo[$i]->caption->Set($acaptions[$i]);
+	$odo[$i]->SetMargin(15);
+}
+
+$row1 = new LayoutHor( array($odo[0],$odo[1],$odo[2]) );
+$row2 = new LayoutHor( array($odo[3],$odo[4],$odo[5]) );
+$row3 = new LayoutHor( array($odo[6],$odo[7],$odo[8]) );
+$col1 = new LayoutVert( array($row1,$row2,$row3) );
+
+// Add the odometer to the graph
+$graph->Add($col1);
+
+// ... and finally stroke and stream the image back to the browser
+$graph->Stroke();
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odotutex10.php b/web/classes/jpgraph/Examples/odotutex10.php
new file mode 100755
index 0000000000000000000000000000000000000000..f44fc5e0d0cb6bf90c6005322fc138410daedbf1
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex10.php
@@ -0,0 +1,43 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(250,150);
+
+$graph->title->Set('Example with scale indicators');
+
+// Add drop shadow for graph
+$graph->SetShadow();
+
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+$odo = new Odometer(ODO_HALF);
+
+// Add color indications
+$odo->AddIndication(0,20,"green:0.7");
+$odo->AddIndication(20,30,"green:0.9");
+$odo->AddIndication(30,60,"yellow");
+$odo->AddIndication(60,80,"orange");
+$odo->AddIndication(80,100,"red");
+
+// Set display value for the odometer
+$odo->needle->Set(90);
+
+//---------------------------------------------------------------------
+// Add drop shadow for needle
+//---------------------------------------------------------------------
+$odo->needle->SetShadow();
+
+//---------------------------------------------------------------------
+// Add the odometer to the graph
+//---------------------------------------------------------------------
+$graph->Add($odo);
+
+//---------------------------------------------------------------------
+// ... and finally stroke and stream the image back to the browser
+//---------------------------------------------------------------------
+$graph->Stroke();
+
+// EOF
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odotutex11.php b/web/classes/jpgraph/Examples/odotutex11.php
new file mode 100755
index 0000000000000000000000000000000000000000..f1290f7daa1426caeac1a518da866355c1276a32
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex11.php
@@ -0,0 +1,40 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(250,150);
+
+$graph->title->Set('Example with scale indicators');
+
+// Add drop shadow for graph
+$graph->SetShadow();
+
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+$odo = new Odometer(ODO_HALF);
+
+// Add color indications
+$odo->AddIndication(0,20,"green:0.7");
+$odo->AddIndication(20,30,"green:0.9");
+$odo->AddIndication(30,60,"yellow");
+$odo->AddIndication(60,80,"orange");
+$odo->AddIndication(80,100,"red");
+
+// Set display value for the odometer
+$odo->needle->Set(90);
+
+// Set the size of the non-colored base area to 40% of the radius
+$odo->SetCenterAreaWidth(0.45);
+
+// Add drop shadow for needle
+$odo->needle->SetShadow();
+
+// Add the odometer to the graph
+$graph->Add($odo);
+
+// ... and finally stroke and stream the image back to the browser
+$graph->Stroke();
+
+// EOF
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odotutex12.php b/web/classes/jpgraph/Examples/odotutex12.php
new file mode 100755
index 0000000000000000000000000000000000000000..5d030a8e3682356e54514c47824eb74d65058b67
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex12.php
@@ -0,0 +1,47 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(250,150);
+
+$graph->title->Set('Example with scale indicators');
+
+// Add drop shadow for graph
+$graph->SetShadow();
+
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+$odo = new Odometer(ODO_HALF);
+
+// Add color indications
+$odo->AddIndication(0,20,"green:0.7");
+$odo->AddIndication(20,30,"green:0.9");
+$odo->AddIndication(30,60,"yellow");
+$odo->AddIndication(60,80,"orange");
+$odo->AddIndication(80,100,"red");
+
+// Set display value for the odometer
+$odo->needle->Set(90);
+
+// Set the size of the non-colored base area to 40% of the radius
+$odo->SetCenterAreaWidth(0.45);
+
+// Add drop shadow for needle
+$odo->needle->SetShadow();
+
+// Setup the second needle
+$odo->needle2->Set(44);
+$odo->needle2->Show();
+$odo->needle2->SetLength(0.4);
+$odo->needle2->SetFillColor("navy");
+$odo->needle2->SetShadow();
+
+// Add the odometer to the graph
+$graph->Add($odo);
+
+// ... and finally stroke and stream the image back to the browser
+$graph->Stroke();
+
+// EOF
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odotutex13.php b/web/classes/jpgraph/Examples/odotutex13.php
new file mode 100755
index 0000000000000000000000000000000000000000..5c49a1179f0708069a264b3fae315448f96f3cc7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex13.php
@@ -0,0 +1,41 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(250,150);
+
+$graph->title->Set('Example with scale indicators');
+
+// Add drop shadow for graph
+$graph->SetShadow();
+
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+$odo = new Odometer(ODO_HALF);
+
+// Add color indications
+$odo->AddIndication(0,20,"green:0.7");
+$odo->AddIndication(20,30,"green:0.9");
+$odo->AddIndication(30,60,"yellow");
+$odo->AddIndication(60,80,"orange");
+$odo->AddIndication(80,100,"red");
+
+$odo->SetCenterAreaWidth(0.45);
+
+// Set display value for the odometer
+$odo->needle->Set(90);
+
+// Add scale labels
+$odo->label->Set("mBar");
+$odo->label->SetFont(FF_FONT2,FS_BOLD);
+
+// Add drop shadow for needle
+$odo->needle->SetShadow();
+
+// Add the odometer to the graph
+$graph->Add($odo);
+
+// ... and finally stroke and stream the image back to the browser
+$graph->Stroke();
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odotutex14.php b/web/classes/jpgraph/Examples/odotutex14.php
new file mode 100755
index 0000000000000000000000000000000000000000..19e8f71b8b3bc1ed0fdb3bc75d52fc3111fcc97f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex14.php
@@ -0,0 +1,35 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(250,160);
+$graph->title->Set('Custom scale');
+$graph->title->SetColor('white');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD);
+
+// Add drop shadow for graph
+$graph->SetShadow();
+
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+$odo = new Odometer();
+$odo->SetColor('lightyellow');
+
+// Setup the scale
+$odo->scale->Set(100,600);
+$odo->scale->SetTicks(50,2);
+
+// Set display value for the odometer
+$odo->needle->Set(280);
+
+// Add drop shadow for needle
+$odo->needle->SetShadow();
+
+// Add the odometer to the graph
+$graph->Add($odo);
+
+// ... and finally stroke and stream the image back to the browser
+$graph->Stroke();
+
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odotutex15.php b/web/classes/jpgraph/Examples/odotutex15.php
new file mode 100755
index 0000000000000000000000000000000000000000..fece535e90c50336ee3899332f4c7f729f6d280e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex15.php
@@ -0,0 +1,46 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(250,170);
+
+// Setup graph titles
+$graph->title->Set('Custom formatting');
+$graph->title->SetColor('white');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD);
+
+// Add drop shadow for graph
+$graph->SetShadow();
+
+// Now we need to create an odometer to add to the graph.
+$odo = new Odometer();
+$odo->SetColor("lightgray:1.9");
+
+// Setup the scale
+$odo->scale->Set(100,600);
+$odo->scale->SetTicks(50,2);
+$odo->scale->SetTickColor('brown');
+$odo->scale->SetTickLength(0.05);
+$odo->scale->SetTickWeight(2);
+
+$odo->scale->SetLabelPos(0.75);
+$odo->scale->label->SetFont(FF_FONT1, FS_BOLD);
+$odo->scale->label->SetColor('brown');
+$odo->scale->label->SetFont(FF_ARIAL,FS_NORMAL,10);
+
+// Setup a label with a degree mark
+$odo->scale->SetLabelFormat('%dC'.SymChar::Get('degree'));
+
+// Set display value for the odometer
+$odo->needle->Set(280);
+
+// Add drop shadow for needle
+$odo->needle->SetShadow();
+
+// Add the odometer to the graph
+$graph->Add($odo);
+
+// ... and finally stroke and stream the image back to the browser
+$graph->Stroke();
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odotutex16.1.php b/web/classes/jpgraph/Examples/odotutex16.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..c370618feb4bbd3554a3be3b182b8696ff2a2d86
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex16.1.php
@@ -0,0 +1,42 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(350,100);
+
+// Add drop shadow for graph
+$graph->SetShadow();
+
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+$odo1 = new Odometer();
+$odo2 = new Odometer();
+$odo1->SetColor("lightgray:1.9");
+$odo2->SetColor("lightgray:1.9");
+
+// Adjust start and end angle for the scale
+$odo2->scale->SetAngle(110,250);
+
+$odo1->scale->label->SetFont(FF_ARIAL,FS_BOLD,10);
+$odo2->scale->label->SetFont(FF_ARIAL,FS_BOLD,10);
+$odo2->AddIndication(-15,0,'lightgray');
+$odo2->AddIndication(100,115,'lightgray');
+
+// Set display value for the odometer
+$odo1->needle->Set(70);
+$odo2->needle->Set(70);
+
+// Add drop shadow for needle
+$odo1->needle->SetShadow();
+$odo2->needle->SetShadow();
+
+// Specify the layout for the two odometers
+$row = new LayoutHor( array($odo1,$odo2) );
+
+// Add the odometer to the graph
+$graph->Add($row);
+
+// ... and finally stroke and stream the image back to the browser
+$graph->Stroke();
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odotutex16.php b/web/classes/jpgraph/Examples/odotutex16.php
new file mode 100755
index 0000000000000000000000000000000000000000..16619f3c12df91264963abf4affa7fdec0047980
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex16.php
@@ -0,0 +1,40 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph (width=250, height=200 pixels)
+$graph = new OdoGraph(350,100);
+
+// Add drop shadow for graph
+$graph->SetShadow();
+
+// Now we need to create an odometer to add to the graph.
+// By default the scale will be 0 to 100
+$odo1 = new Odometer();
+$odo2 = new Odometer();
+$odo1->SetColor("lightgray:1.9");
+$odo2->SetColor("lightgray:1.9");
+
+// Adjust start and end angle for the scale
+$odo2->scale->SetAngle(110,250);
+
+$odo1->scale->label->SetFont(FF_ARIAL,FS_BOLD,10);
+$odo2->scale->label->SetFont(FF_ARIAL,FS_BOLD,10);
+
+// Set display value for the odometer
+$odo1->needle->Set(70);
+$odo2->needle->Set(70);
+
+// Add drop shadow for needle
+$odo1->needle->SetShadow();
+$odo2->needle->SetShadow();
+
+// Specify the layout for the two odometers
+$row = new LayoutHor( array($odo1,$odo2) );
+
+// Add the odometer to the graph
+$graph->Add($row);
+
+// ... and finally stroke and stream the image back to the browser
+$graph->Stroke();
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odotutex17.php b/web/classes/jpgraph/Examples/odotutex17.php
new file mode 100755
index 0000000000000000000000000000000000000000..6a9abf8dc39638b9eb8a8a2f78bb3daa5d4eb4ff
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex17.php
@@ -0,0 +1,46 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph
+$graph = new OdoGraph(300,320);
+
+// Setup graph titles
+$graph->title->Set('Manual positioning');
+$graph->title->SetColor('white');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+// Add drop shadow for graph
+$graph->SetShadow();
+
+// Now we need to create an odometer to add to the graph.
+$odo1 = new Odometer();
+$odo2 = new Odometer();
+$odo1->SetColor('lightgray:1.9');
+$odo2->SetColor('lightgray:1.9');
+
+// Set display value for the odometer
+$odo1->needle->Set(37);
+$odo2->needle->Set(73);
+
+// Add drop shadow for needle
+$odo1->needle->SetShadow();
+$odo2->needle->SetShadow();
+
+// Specify the position for the two odometers
+$odo1->SetPos(180,110);
+$odo1->SetSize(100);
+$odo2->SetPos(110,250);
+$odo2->SetSize(100);
+
+// Set captions for the odometers
+$odo1->caption->Set("(x,y) = (180,120)\nradius=100");
+$odo2->caption->Set("(x,y) = (110,270)\nradius=100");
+
+// Add the odometer to the graph
+$graph->Add($odo1);
+$graph->Add($odo2);
+
+// ... and finally stroke and stream the image back to the browser
+$graph->Stroke();
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odotutex18.php b/web/classes/jpgraph/Examples/odotutex18.php
new file mode 100755
index 0000000000000000000000000000000000000000..44bd4913a7be2ffb31666bf7e0c5ae6740585b45
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex18.php
@@ -0,0 +1,37 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+
+// Create a new odometer graph
+$graph = new OdoGraph(500,180);
+
+$odo = array();
+
+// Now we need to create an odometer to add to the graph.
+for( $i=0; $i < 5; ++$i ) {
+	$odo[$i] = new Odometer();
+	$odo[$i]->SetColor('lightgray:1.9');
+	$odo[$i]->needle->Set(10+$i*17);
+	$odo[$i]->needle->SetShadow();
+	if( $i < 2 )
+		$fsize = 10;
+	else
+		$fsize = 8;
+	$odo[$i]->scale->label->SetFont(FF_ARIAL,FS_NORMAL,$fsize);
+	$odo[$i]->AddIndication(92,100,'red');
+	$odo[$i]->AddIndication(80,92,'orange');
+	$odo[$i]->AddIndication(60,80,'yellow');
+}
+
+// Create the layout
+$row1 = new LayoutHor( array($odo[0],$odo[1]) );
+$row2 = new LayoutHor( array($odo[2],$odo[3],$odo[4]) );
+$col1 = new LayoutVert( array($row1,$row2) );
+
+// Add the odometer to the graph
+$graph->Add($col1);
+
+// ... and finally stroke and stream the image back to the browser
+$graph->Stroke();
+
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/odotutex19.php b/web/classes/jpgraph/Examples/odotutex19.php
new file mode 100755
index 0000000000000000000000000000000000000000..02324b0677719d3039fe1009349f54fe4ef631c1
--- /dev/null
+++ b/web/classes/jpgraph/Examples/odotutex19.php
@@ -0,0 +1,49 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_odo.php');
+require_once ('jpgraph/jpgraph_iconplot.php');
+
+// Create a new odometer graph
+$graph = new OdoGraph(500,180);
+
+$odo = array();
+
+// Now we need to create an odometer to add to the graph.
+for( $i=0; $i < 5; ++$i ) {
+	$odo[$i] = new Odometer();
+	$odo[$i]->SetColor('lightgray:1.9');
+	$odo[$i]->needle->Set(10+$i*17);
+	$odo[$i]->needle->SetShadow();
+	if( $i < 2 )
+		$fsize = 10;
+	else
+		$fsize = 8;
+	$odo[$i]->scale->label->SetFont(FF_ARIAL,FS_NORMAL,$fsize);
+	$odo[$i]->AddIndication(92,100,'red');
+	$odo[$i]->AddIndication(80,92,'orange');
+	$odo[$i]->AddIndication(60,80,'yellow');
+}
+
+// Create the layout
+$row1 = new LayoutHor( array($odo[0],$odo[1]) );
+$row2 = new LayoutHor( array($odo[2],$odo[3],$odo[4]) );
+$col1 = new LayoutVert( array($row1,$row2) );
+
+// Add the odometer to the graph
+$graph->Add($col1);
+
+// Add an icon and text
+$icon = new IconPlot('jpglogo.jpg',250,10,0.85,30);
+$icon->SetAnchor('center','top');
+$graph->Add($icon);
+
+$t = new Text('JpGraph',250,70);
+$t->SetAlign('center','top');
+#$t->SetFont(FF_VERA,FS_BOLD,11);
+$t->SetColor('darkgray');
+$graph->Add($t);
+
+// ... and finally stroke and stream the image back to the browser
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/orange_example.php b/web/classes/jpgraph/Examples/orange_example.php
new file mode 100755
index 0000000000000000000000000000000000000000..adab98dc75be407087efeb99f8f5d66c6c98fe4f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/orange_example.php
@@ -0,0 +1,58 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$theme = isset($_GET['theme']) ? $_GET['theme'] : null;
+
+$data = array (
+  0 => array (0 => 79, 1 => -25, 2 => -7, 3 => 85, 4 => -26, 5 => -32, ),
+  1 => array (0 => 76, 1 => 51, 2 => 86, 3 => 12, 4 => -7, 5 => 94, ),
+  2 => array (0 => 49, 1 => 38, 2 => 7, 3 => -40, 4 => 9, 5 => -7, ),
+  3 => array ( 0 => 69, 1 => 96, 2 => 49, 3 => 7, 4 => 92, 5 => -38, ),
+  4 => array ( 0 => 68, 1 => 16, 2 => 82, 3 => -49, 4 => 50, 5 => 7, ),
+  5 => array ( 0 => -37, 1 => 28, 2 => 32, 3 => 6, 4 => 13, 5 => 57, ),
+  6 => array ( 0 => 24, 1 => -11, 2 => 7, 3 => 10, 4 => 51, 5 => 51, ),
+  7 => array ( 0 => 3, 1 => -1, 2 => -12, 3 => 61, 4 => 10, 5 => 47, ),
+  8 => array ( 0 => -47, 1 => -21, 2 => 43, 3 => 53, 4 => 36, 5 => 34, ),
+);
+
+
+// Create the graph. These two calls are always required
+$graph = new Graph(400,300);    
+
+$graph->SetScale("textlin");
+if ($theme) {
+  $graph->SetTheme(new $theme());
+}
+$theme_class = new OrangeTheme;
+$graph->SetTheme($theme_class);
+
+$plot = array();
+// Create the bar plots
+for ($i = 0; $i < 4; $i++) {
+  $plot[$i] = new BarPlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.($i+1));
+}
+//$acc1 = new AccBarPlot(array($plot[0], $plot[1]));
+//$acc1->value->Show();
+$gbplot = new GroupBarPlot(array($plot[2], $plot[1] ));
+
+for ($i = 4; $i < 8; $i++) {
+  $plot[$i] = new LinePlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.$i);
+  $plot[$i]->value->Show();
+}
+
+$graph->Add($gbplot);
+$graph->Add($plot[4]);
+
+$title = "OrangeTheme Example";
+$title = mb_convert_encoding($title,'UTF-8');
+$graph->title->Set($title);
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/partiallyfilledlineex1.php b/web/classes/jpgraph/Examples/partiallyfilledlineex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..7ad37eca96e7907fcd894cd865d45e15ba0b5381
--- /dev/null
+++ b/web/classes/jpgraph/Examples/partiallyfilledlineex1.php
@@ -0,0 +1,44 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some data
+$ydata = array(5,10,15,20,15,10,8,7,4,10,5);
+
+// Create the graph
+$graph= new Graph(400,300);
+$graph->SetScale("textlin");
+$graph->SetShadow(true);
+$graph->SetMarginColor("lightblue");
+
+// Setup format for legend
+$graph->legend->SetFillColor("antiquewhite");
+$graph->legend->SetShadow(true);
+
+// Setup title
+$graph->title->Set("Filled Area Example");
+$graph->title->SetFont(FF_FONT2,FS_BOLD);
+
+// Setup semi-filled line plot
+$lineplot = new LinePlot($ydata);
+$lineplot->SetLegend("Semi-filled\nLineplot");
+
+// Set line color
+$lineplot->SetColor("black");
+
+// Setup the two areas to be filled
+$lineplot->AddArea(2,5,LP_AREA_FILLED,"red");
+$lineplot->AddArea(6,8,LP_AREA_FILLED,"green");
+
+// Display the marks on the lines
+$lineplot->mark->SetType(MARK_DIAMOND);
+$lineplot->mark->SetSize(8);
+$lineplot->mark->Show();
+
+// add plot to the graph
+$graph->Add($lineplot);
+
+// display graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/pastel_example.php b/web/classes/jpgraph/Examples/pastel_example.php
new file mode 100755
index 0000000000000000000000000000000000000000..82aeeb4c9505356a2338721f6c238f53124a32e9
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pastel_example.php
@@ -0,0 +1,57 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$theme = isset($_GET['theme']) ? $_GET['theme'] : null;
+$data = array (
+  0 => array (0 => 79, 1 => -25, 2 => -7, 3 => 85, 4 => -26, 5 => -32, ),
+  1 => array (0 => 76, 1 => 51, 2 => 86, 3 => 12, 4 => -7, 5 => 94, ),
+  2 => array (0 => 49, 1 => 38, 2 => 7, 3 => -40, 4 => 9, 5 => -7, ),
+  3 => array ( 0 => 69, 1 => 96, 2 => 49, 3 => 7, 4 => 92, 5 => -38, ),
+  4 => array ( 0 => 68, 1 => 16, 2 => 82, 3 => -49, 4 => 50, 5 => 7, ),
+  5 => array ( 0 => -37, 1 => 28, 2 => 32, 3 => 6, 4 => 13, 5 => 57, ),
+  6 => array ( 0 => 24, 1 => -11, 2 => 7, 3 => 10, 4 => 51, 5 => 51, ),
+  7 => array ( 0 => 3, 1 => -1, 2 => -12, 3 => 61, 4 => 10, 5 => 47, ),
+  8 => array ( 0 => -47, 1 => -21, 2 => 43, 3 => 53, 4 => 36, 5 => 34, ),
+);
+
+
+// Create the graph. These two calls are always required
+$graph = new Graph(400,300);    
+
+$graph->SetScale("textlin");
+if ($theme) {
+  $graph->SetTheme(new $theme());
+}
+$theme_class = new PastelTheme;
+$graph->SetTheme($theme_class);
+
+$plot = array();
+// Create the bar plots
+for ($i = 0; $i < 4; $i++) {
+  $plot[$i] = new BarPlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.($i+1));
+}
+//$acc1 = new AccBarPlot(array($plot[0], $plot[1]));
+//$acc1->value->Show();
+$gbplot = new GroupBarPlot(array($plot[2], $plot[1] ));
+
+for ($i = 4; $i < 8; $i++) {
+  $plot[$i] = new LinePlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.$i);
+  $plot[$i]->value->Show();
+}
+
+$graph->Add($gbplot);
+$graph->Add($plot[4]);
+
+$title = "PastelTheme Example";
+$title = mb_convert_encoding($title,'UTF-8');
+$graph->title->Set($title);
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/pdf417_ex0.php b/web/classes/jpgraph/Examples/pdf417_ex0.php
new file mode 100755
index 0000000000000000000000000000000000000000..fb197f5b10191c42454870c3b5b45541d97351d8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pdf417_ex0.php
@@ -0,0 +1,8 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/pdf417/jpgraph_pdf417.php');
+
+$data = 'PDF-417';
+// Create a new encoder and backend to generate PNG images
+$backend = PDF417BackendFactory::Create(BACKEND_IMAGE,new PDF417Barcode());
+$backend->Stroke($data);
+?>
diff --git a/web/classes/jpgraph/Examples/pdf417_ex1.php b/web/classes/jpgraph/Examples/pdf417_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..84dd2726b186ed0dca5f2042764bdb91a4882f6d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pdf417_ex1.php
@@ -0,0 +1,13 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/pdf417/jpgraph_pdf417.php');
+
+$data = 'PDF-417';
+try {
+	// Create a new encoder and backend to generate PNG images
+	$backend = PDF417BackendFactory::Create(BACKEND_IMAGE,new PDF417Barcode());
+	$backend->Stroke($data);
+}
+catch(JpGraphException $e) {
+	echo 'PDF417 Error: '.$e->GetMessage();
+}
+?>
diff --git a/web/classes/jpgraph/Examples/pdf417_ex1b.php b/web/classes/jpgraph/Examples/pdf417_ex1b.php
new file mode 100755
index 0000000000000000000000000000000000000000..fad0a9e0a4bfa4b93f72627aa857e7a403a676cc
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pdf417_ex1b.php
@@ -0,0 +1,20 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/pdf417/jpgraph_pdf417.php');
+
+$data = 'PDF-417';
+
+// Setup some symbolic names for barcode specification
+
+$columns = 8;   // Use 8 data (payload) columns
+$errlevel = 2;  // Use error level 2 (minimum recommended)
+
+// Create a new encoder and backend to generate PNG images
+try {
+	$encoder = new PDF417Barcode($columns,$errlevel);
+	$backend = PDF417BackendFactory::Create(BACKEND_IMAGE,$encoder);
+	$backend->Stroke($data);
+}
+catch(JpGraphException $e) {
+	echo 'PDF417 Error: '.$e->GetMessage();
+}
+?>
diff --git a/web/classes/jpgraph/Examples/pdf417_ex1c.php b/web/classes/jpgraph/Examples/pdf417_ex1c.php
new file mode 100755
index 0000000000000000000000000000000000000000..96a748703ac6754b07bfc842730ee9750185fd88
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pdf417_ex1c.php
@@ -0,0 +1,23 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/pdf417/jpgraph_pdf417.php');
+
+$data = 'PDF-417';
+
+// Setup some symbolic names for barcode specification
+
+$columns = 8;   // Use 8 data (payload) columns
+$errlevel = 2;  // Use error level 2 (minimum recommended)
+$modwidth = 2;  // Setup module width (in pixels)
+
+// Create a new encoder and backend to generate PNG images
+try {
+	$encoder = new PDF417Barcode($columns,$errlevel);
+	$backend = PDF417BackendFactory::Create(BACKEND_IMAGE,$encoder);
+	$backend->ShowText(true);
+	$backend->SetModuleWidth($modwidth);
+	$backend->Stroke($data);
+}
+catch(JpGraphException $e) {
+	echo 'PDF417 Error: '.$e->GetMessage();
+}
+?>
diff --git a/web/classes/jpgraph/Examples/pdf417_ex2.php b/web/classes/jpgraph/Examples/pdf417_ex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..685b0c292bdc82847159611a92a2b36bff7dd630
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pdf417_ex2.php
@@ -0,0 +1,24 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/pdf417/jpgraph_pdf417.php');
+
+$data = 'PDF-417';
+
+// Setup some symbolic names for barcode specification
+
+$columns = 8;   // Use 8 data (payload) columns
+$errlevel = 2;  // Use error level 2 (minimum recommended)
+$modwidth = 2;  // Setup module width (in pixels)
+$height = 3;    // Height factor
+
+// Create a new encoder and backend to generate PNG images
+try {
+	$encoder = new PDF417Barcode($columns,$errlevel);
+	$backend = PDF417BackendFactory::Create(BACKEND_IMAGE,$encoder);
+	$backend->SetModuleWidth($modwidth);
+	$backend->SetHeight($height);
+	$backend->Stroke($data);
+}
+catch(JpGraphException $e) {
+	echo 'PDF417 Error: '.$e->GetMessage();
+}
+?>
diff --git a/web/classes/jpgraph/Examples/pdf417_ex3.php b/web/classes/jpgraph/Examples/pdf417_ex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..ec2c7b6fefdf7b949eefeee5cad44d537668b1fc
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pdf417_ex3.php
@@ -0,0 +1,26 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/pdf417/jpgraph_pdf417.php');
+
+$data = 'PDF-417';
+
+// Setup some symbolic names for barcode specification
+
+$columns = 8;   // Use 8 data (payload) columns
+$errlevel = 4;  // Use error level 4
+$modwidth = 2;  // Setup module width (in pixels)
+$height = 2;    // Height factor (=2)
+$showtext = false;  // Show human readable string
+
+// Create a new encoder and backend to generate PNG images
+try {
+	$encoder = new PDF417Barcode($columns,$errlevel);
+	$backend = PDF417BackendFactory::Create(BACKEND_IMAGE,$encoder);
+    $backend->SetModuleWidth($modwidth);
+    $backend->SetHeight($height);
+    $backend->NoText(!$showtext);
+    $backend->Stroke($data);
+}
+catch(JpGraphException $e) {
+	echo 'PDF417 Error: '.$e->GetMessage();
+}
+?>
diff --git a/web/classes/jpgraph/Examples/pdf417_ex4.php b/web/classes/jpgraph/Examples/pdf417_ex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..5fb8e6e7fcd9998daa2e7476438a14c329166db5
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pdf417_ex4.php
@@ -0,0 +1,28 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/pdf417/jpgraph_pdf417.php');
+
+$data = 'PDF-417';
+
+// Setup some symbolic names for barcode specification
+
+$columns = 8;   // Use 8 data (payload) columns
+$errlevel = 4;  // Use error level 4
+$modwidth = 2;  // Setup module width (in pixels)
+$height = 2;    // Height factor (=2)
+$showtext = true;  // Show human readable string
+
+try {
+	// Create a new encoder and backend to generate PNG images
+	$encoder = new PDF417Barcode($columns,$errlevel);
+	$backend = PDF417BackendFactory::Create(BACKEND_IMAGE,$encoder);
+
+	$backend->SetModuleWidth($modwidth);
+    $backend->SetHeight($height);
+    $backend->NoText(!$showtext);
+    $backend->SetColor('black','yellow');
+    $backend->Stroke($data);
+}
+catch(JpGraphException $e) {
+	echo 'PDF417 Error: '.$e->GetMessage();
+}
+?>
diff --git a/web/classes/jpgraph/Examples/pdf417_ex5.php b/web/classes/jpgraph/Examples/pdf417_ex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..fc525bfe77f07100ce735112515e98152c58309a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pdf417_ex5.php
@@ -0,0 +1,29 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/pdf417/jpgraph_pdf417.php');
+
+$data = 'PDF-417';
+
+// Setup some symbolic names for barcode specification
+
+$columns = 8;   // Use 8 data (payload) columns
+$errlevel = 4;  // Use error level 4
+$modwidth = 0.8;// Setup module width (in PS points)
+$height = 3;    // Height factor (=2)
+$showtext = true;  // Show human readable string
+
+try {
+	// Create a new encoder and backend to generate PNG images
+	$encoder = new PDF417Barcode($columns,$errlevel);
+	$backend = PDF417BackendFactory::Create(BACKEND_PS,$encoder);
+
+	$backend->SetModuleWidth($modwidth);
+    $backend->SetHeight($height);
+    $backend->NoText(!$showtext);
+    $backend->SetColor('black','yellow');
+    $output = $backend->Stroke($data);
+    echo nl2br(htmlspecialchars($output));
+}
+catch(JpGraphException $e) {
+	echo 'PDF417 Error: '.$e->GetMessage();
+}
+?>
diff --git a/web/classes/jpgraph/Examples/pdf417_ex6.php b/web/classes/jpgraph/Examples/pdf417_ex6.php
new file mode 100755
index 0000000000000000000000000000000000000000..9b2e14d6a1c3a251a68a98cba204336b58cbcab7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pdf417_ex6.php
@@ -0,0 +1,35 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/pdf417/jpgraph_pdf417.php');
+
+$data1 = '12345';
+$data2 = 'Abcdef';
+$data3 = '6789';
+
+// Manually specify several encodation schema
+$data = array(
+    array(USE_NC,$data1),
+    array(USE_TC,$data2),
+    array(USE_NC,$data3));
+
+//$data = "12345Abcdef6789";
+
+// Setup some symbolic names for barcode specification
+
+$columns = 8;   // Use 8 data (payload) columns
+$modwidth = 2;  // Use 2 pixel module width
+$errlevel = 2;  // Use error level 2
+$showtext = true;  // Show human readable string
+
+try {
+	// Create a new encoder and backend to generate PNG images
+	$encoder = new PDF417Barcode($columns,$errlevel);
+	$backend = PDF417BackendFactory::Create(BACKEND_IMAGE,$encoder);
+
+	$backend->SetModuleWidth($modwidth);
+    $backend->NoText(!$showtext);
+    $backend->Stroke($data);
+}
+catch(JpGraphException $e) {
+	echo 'PDF417 Error: '.$e->GetMessage();
+}
+?>
diff --git a/web/classes/jpgraph/Examples/penguin.png b/web/classes/jpgraph/Examples/penguin.png
new file mode 100755
index 0000000000000000000000000000000000000000..2ae426ae3c5d4804b12b6a468d6fe9c7aa960a28
Binary files /dev/null and b/web/classes/jpgraph/Examples/penguin.png differ
diff --git a/web/classes/jpgraph/Examples/pie3d_csimex1.php b/web/classes/jpgraph/Examples/pie3d_csimex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..564c51f60914ad7721500774c4037bbb72f08aa7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pie3d_csimex1.php
@@ -0,0 +1,43 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+require_once ('jpgraph/jpgraph_pie3d.php');
+
+//$gJpgBrandTiming=true;
+
+// Some data
+$data = array(40,21,17,27,23);
+
+// Create the Pie Graph. 
+$graph = new PieGraph(400,200,'auto');
+$graph->SetShadow();
+
+// Set A title for the plot
+$graph->title->Set("3D Pie Client side image map");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Create
+$p1 = new PiePlot3D($data);
+$p1->SetLegends(array("Jan (%d)","Feb","Mar","Apr","May","Jun","Jul"));
+$targ=array("pie3d_csimex1.php?v=1","pie3d_csimex1.php?v=2","pie3d_csimex1.php?v=3",
+			"pie3d_csimex1.php?v=4","pie3d_csimex1.php?v=5","pie3d_csimex1.php?v=6");
+$alts=array("val=%d","val=%d","val=%d","val=%d","val=%d","val=%d");
+$p1->SetCSIMTargets($targ,$alts);
+
+// Use absolute labels
+$p1->SetLabelType(1);
+$p1->value->SetFormat("%d kr");
+
+// Move the pie slightly to the left
+$p1->SetCenter(0.4,0.5);
+
+$graph->Add($p1);
+
+
+// Send back the HTML page which will call this script again
+// to retrieve the image.
+$graph->StrokeCSIM();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pie3dex1.php b/web/classes/jpgraph/Examples/pie3dex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..10e2100f4f2b74dd8d921addd2f9761905be11e3
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pie3dex1.php
@@ -0,0 +1,32 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+require_once ('jpgraph/jpgraph_pie3d.php');
+
+// Some data
+$data = array(20,27,45,75,90);
+
+// Create the Pie Graph.
+$graph = new PieGraph(350,200);
+$graph->SetShadow();
+
+// Set A title for the plot
+$graph->title->Set("Example 1 3D Pie plot");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,18); 
+$graph->title->SetColor("darkblue");
+$graph->legend->Pos(0.1,0.2);
+
+// Create pie plot
+$p1 = new PiePlot3d($data);
+$p1->SetTheme("sand");
+$p1->SetCenter(0.4);
+$p1->SetAngle(30);
+$p1->value->SetFont(FF_ARIAL,FS_NORMAL,12);
+$p1->SetLegends(array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct"));
+
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pie3dex2.php b/web/classes/jpgraph/Examples/pie3dex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..bd2a099b14809516d73854e7f02ae6171144f13c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pie3dex2.php
@@ -0,0 +1,45 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+require_once ('jpgraph/jpgraph_pie3d.php');
+
+// Some data
+$data = array(20,27,45,75,90);
+
+// Create the Pie Graph.
+$graph = new PieGraph(350,200);
+$graph->SetShadow();
+
+
+// Set A title for the plot
+$graph->title->Set("Example 2 3D Pie plot");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,18); 
+$graph->title->SetColor("darkblue");
+$graph->legend->Pos(0.1,0.2);
+
+// Create 3D pie plot
+$p1 = new PiePlot3d($data);
+$p1->SetTheme("sand");
+$p1->SetCenter(0.4);
+$p1->SetSize(0.4);
+$p1->SetHeight(5);
+
+// Adjust projection angle
+$p1->SetAngle(45);
+
+// You can explode several slices by specifying the explode
+// distance for some slices in an array
+$p1->Explode(array(0,40,0,30));
+
+// As a shortcut you can easily explode one numbered slice with
+// $p1->ExplodeSlice(3);
+
+$p1->value->SetFont(FF_ARIAL,FS_NORMAL,10);
+$p1->SetLegends(array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct"));
+
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pie3dex3.php b/web/classes/jpgraph/Examples/pie3dex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..b45a2f227098ee8dfc45853e422f20512f129ad0
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pie3dex3.php
@@ -0,0 +1,42 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+require_once ('jpgraph/jpgraph_pie3d.php');
+
+// Some data
+$data = array(20,27,45,75,90);
+
+// Create the Pie Graph.
+$graph = new PieGraph(350,200);
+$graph->SetShadow();
+
+// Set A title for the plot
+$graph->title->Set("Example 3 3D Pie plot");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,18); 
+$graph->title->SetColor("darkblue");
+$graph->legend->Pos(0.1,0.2);
+
+// Create 3D pie plot
+$p1 = new PiePlot3d($data);
+$p1->SetTheme("sand");
+$p1->SetCenter(0.4);
+$p1->SetSize(80);
+
+// Adjust projection angle
+$p1->SetAngle(45);
+
+// As a shortcut you can easily explode one numbered slice with
+$p1->ExplodeSlice(3);
+
+// Setup the slice values
+$p1->value->SetFont(FF_ARIAL,FS_BOLD,11);
+$p1->value->SetColor("navy");
+
+$p1->SetLegends(array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct"));
+
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pie3dex4.php b/web/classes/jpgraph/Examples/pie3dex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..0ce86e4eae9421a612aaf6c33d8349f2d9939fd0
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pie3dex4.php
@@ -0,0 +1,46 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+require_once ('jpgraph/jpgraph_pie3d.php');
+
+// Some data
+$data = array(20,27,45,75,90);
+
+// Create the Pie Graph.
+$graph = new PieGraph(350,200);
+$graph->SetShadow();
+
+// Set A title for the plot
+$graph->title->Set("Example 4 3D Pie plot");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,18); 
+$graph->title->SetColor("darkblue");
+$graph->legend->Pos(0.1,0.2);
+
+// Create 3D pie plot
+$p1 = new PiePlot3d($data);
+$p1->SetTheme("sand");
+$p1->SetCenter(0.4);
+$p1->SetSize(80);
+
+// Adjust projection angle
+$p1->SetAngle(45);
+
+// Adjsut angle for first slice
+$p1->SetStartAngle(45);
+
+// As a shortcut you can easily explode one numbered slice with
+$p1->ExplodeSlice(3);
+
+// Setup slice values
+$p1->value->SetFont(FF_ARIAL,FS_BOLD,11);
+$p1->value->SetColor("navy");
+
+
+$p1->SetLegends(array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct"));
+
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pie3dex5.php b/web/classes/jpgraph/Examples/pie3dex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..6efe470f183a6b7d4d05607f84e0fe78222849f5
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pie3dex5.php
@@ -0,0 +1,46 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+require_once ('jpgraph/jpgraph_pie3d.php');
+
+// Some data
+$data = array(20,27,45,75,90);
+
+// Create the Pie Graph.
+$graph = new PieGraph(350,200);
+$graph->SetShadow();
+
+// Set A title for the plot
+$graph->title->Set("Example 5 3D Pie plot");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,18); 
+$graph->title->SetColor("darkblue");
+$graph->legend->Pos(0.1,0.2);
+
+// Create 3D pie plot
+$p1 = new PiePlot3d($data);
+$p1->SetTheme("sand");
+$p1->SetCenter(0.4);
+$p1->SetSize(80);
+
+// Adjust projection angle
+$p1->SetAngle(45);
+
+// Adjsut angle for first slice
+$p1->SetStartAngle(45);
+
+// Display the slice values
+$p1->value->SetFont(FF_ARIAL,FS_BOLD,11);
+$p1->value->SetColor("navy");
+
+// Add colored edges to the 3D pie
+// NOTE: You can't have exploded slices with edges!
+$p1->SetEdge("navy");
+
+$p1->SetLegends(array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct"));
+
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pie_csimex1.php b/web/classes/jpgraph/Examples/pie_csimex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..50c3f700fecab397cf99df124cafddbe09b813b7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pie_csimex1.php
@@ -0,0 +1,35 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+// Some data
+$data = array(40,21,17,14,23);
+
+// Create the Pie Graph. 
+$graph = new PieGraph(300,200,'auto');
+$graph->SetShadow();
+
+// Set A title for the plot
+$graph->title->Set("Client side image map");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Create
+$p1 = new PiePlot($data);
+$p1->SetCenter(0.4,0.5);
+
+$p1->SetLegends(array("Jan","Feb","Mar","Apr","May","Jun","Jul"));
+$targ=array("pie_csimex1.php#1","pie_csimex1.php#2","pie_csimex1.php#3",
+"pie_csimex1.php#4","pie_csimex1.php#5","pie_csimex1.php#6");
+$alts=array("val=%d","val=%d","val=%d","val=%d","val=%d","val=%d");
+$p1->SetCSIMTargets($targ,$alts);
+
+$graph->Add($p1);
+
+
+// Send back the HTML page which will call this script again
+// to retrieve the image.
+$graph->StrokeCSIM();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/piebkgex1.php b/web/classes/jpgraph/Examples/piebkgex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..d2371c01bd0804022963b90c3cbbf607f8ba3e58
--- /dev/null
+++ b/web/classes/jpgraph/Examples/piebkgex1.php
@@ -0,0 +1,94 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+require_once ('jpgraph/jpgraph_pie3d.php');
+
+// Some data
+$data = array(
+    array(80,18,15,17),
+    array(35,28,6,34),
+    array(10,28,10,5),
+    array(22,22,10,17));
+
+$piepos = array(0.2,0.4,0.65,0.28,0.25,0.75,0.8,0.75);
+$titles = array('USA','Sweden','South America','Australia');
+
+$n = count($piepos)/2;
+ 
+// A new graph
+$graph = new PieGraph(550,400,'auto');
+
+// Specify margins since we put the image in the plot area
+$graph->SetMargin(1,1,40,1);
+$graph->SetMarginColor('navy');
+$graph->SetShadow(false);
+
+// Setup background
+$graph->SetBackgroundImage('worldmap1.jpg',BGIMG_FILLPLOT);
+
+// Setup title
+$graph->title->Set("Pie plots with background image");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,20);
+$graph->title->SetColor('white');
+
+$p = array();
+// Create the plots
+for( $i=0; $i < $n; ++$i ) {
+    $d = "data$i";
+    $p[] = new PiePlot3D($data[$i]);
+}
+
+// Position the four pies
+for( $i=0; $i < $n; ++$i ) {
+    $p[$i]->SetCenter($piepos[2*$i],$piepos[2*$i+1]);
+}
+
+// Set the titles
+for( $i=0; $i < $n; ++$i ) {
+    $p[$i]->title->Set($titles[$i]);
+    $p[$i]->title->SetColor('white');
+    $p[$i]->title->SetFont(FF_ARIAL,FS_BOLD,12);
+}
+
+// Label font and color setup
+for( $i=0; $i < $n; ++$i ) {
+    $p[$i]->value->SetFont(FF_ARIAL,FS_BOLD);
+    $p[$i]->value->SetColor('white');
+}
+
+// Show the percetages for each slice
+for( $i=0; $i < $n; ++$i ) {
+    $p[$i]->value->Show();
+}
+
+// Label format
+for( $i=0; $i < $n; ++$i ) {
+    $p[$i]->value->SetFormat("%01.1f%%");
+}
+
+// Size of pie in fraction of the width of the graph
+for( $i=0; $i < $n; ++$i ) {
+    $p[$i]->SetSize(0.15);
+}
+
+// Format the border around each slice
+
+
+for( $i=0; $i < $n; ++$i ) {
+    $p[$i]->SetEdge(false);
+    $p[$i]->ExplodeSlice(1);
+}
+
+// Use one legend for the whole graph
+$p[0]->SetLegends(array("May","June","July","Aug"));
+$graph->legend->Pos(0.05,0.35);
+$graph->legend->SetShadow(false);
+
+for( $i=0; $i < $n; ++$i ) {
+    $graph->Add($p[$i]);
+}
+
+$graph->Stroke();
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/piec_csimex1.php b/web/classes/jpgraph/Examples/piec_csimex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..bffcb026c22674f06c1dc55d9bafd15838ca252a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/piec_csimex1.php
@@ -0,0 +1,87 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: piec_csimex1.php,v 1.1.2.1 2003/10/09 21:05:39 aditus Exp $
+// Example of pie with center circle
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+// Some data
+$data = array(50,28,25,27,31,20);
+
+// A new pie graph
+$graph = new PieGraph(400,400);
+
+// If you don't want any  border just uncomment this line
+// $graph->SetFrame(false);
+
+// Uncomment this line to add a drop shadow to the border
+// $graph->SetShadow();
+
+// Setup title
+$graph->title->Set("CSIM Center Pie plot ex 1");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,18);
+$graph->title->SetMargin(8); // Add a little bit more margin from the top
+
+// Create the pie plot
+$p1 = new PiePlotC($data);
+
+// Set the radius of pie (as fraction of image size)
+$p1->SetSize(0.32);
+
+// Move the center of the pie slightly to the top of the image
+$p1->SetCenter(0.5,0.45);
+
+// Label font and color setup
+$p1->value->SetFont(FF_ARIAL,FS_BOLD,12);
+$p1->value->SetColor('white');
+
+// Setup the title on the center circle
+$p1->midtitle->Set("Test mid\nRow 1\nRow 2");
+$p1->midtitle->SetFont(FF_ARIAL,FS_NORMAL,14);
+
+// Set color for mid circle
+$p1->SetMidColor('yellow');
+
+// Use percentage values in the legends values (This is also the default)
+$p1->SetLabelType(PIE_VALUE_PER);
+
+// The label array values may have printf() formatting in them. The argument to the
+// form,at string will be the value of the slice (either the percetage or absolute
+// depending on what was specified in the SetLabelType() above.
+$lbl = array("adam\n%.1f%%","bertil\n%.1f%%","johan\n%.1f%%",
+	     "peter\n%.1f%%","daniel\n%.1f%%","erik\n%.1f%%");
+$p1->SetLabels($lbl);
+
+// Uncomment this line to remove the borders around the slices
+// $p1->ShowBorder(false);
+
+// Add drop shadow to slices
+$p1->SetShadow();
+
+// Explode all slices 15 pixels
+$p1->ExplodeAll(15);
+
+// Setup the CSIM targets
+$targ=array("piec_csimex1.php#1","piec_csimex1.php#2","piec_csimex1.php#3",
+	    "piec_csimex1.php#4","piec_csimex1.php#5","piec_csimex1.php#6");
+$alts=array("val=%d","val=%d","val=%d","val=%d","val=%d","val=%d");
+$p1->SetCSIMTargets($targ,$alts);
+$p1->SetMidCSIM("piec_csimex1.php#7","Center");
+
+
+// Setup a small help text in the image
+$txt = new Text("Note: This is an example of image map. Hold\nyour mouse over the slices to see the values.\nThe URL just points back to this page");
+$txt->SetFont(FF_FONT1,FS_BOLD);
+$txt->SetPos(0.5,0.97,'center','bottom');
+$txt->SetBox('yellow','black');
+$txt->SetShadow();
+$graph->AddText($txt);
+
+// Add plot to pie graph
+$graph->Add($p1);
+
+// .. and send the image on it's marry way to the browser
+$graph->StrokeCSIM();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/piecex1.php b/web/classes/jpgraph/Examples/piecex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..af1f2419fc82fa0c3e4dc299ed58c9294413fc1e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/piecex1.php
@@ -0,0 +1,46 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id
+// Example of pie with center circle
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+// Some data
+$data = array(50,28,25,27,31,20);
+
+// A new pie graph
+$graph = new PieGraph(300,300,'auto');
+
+// Setup title
+$graph->title->Set("Pie plot with center circle");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph->title->SetMargin(8); // Add a little bit more margin from the top
+
+// Create the pie plot
+$p1 = new PiePlotC($data);
+
+// Set size of pie
+$p1->SetSize(0.32);
+
+// Label font and color setup
+$p1->value->SetFont(FF_ARIAL,FS_BOLD,10);
+$p1->value->SetColor('black');
+
+// Setup the title on the center circle
+$p1->midtitle->Set("Test mid\nRow 1\nRow 2");
+$p1->midtitle->SetFont(FF_ARIAL,FS_NORMAL,10);
+
+// Set color for mid circle
+$p1->SetMidColor('yellow');
+
+// Use percentage values in the legends values (This is also the default)
+$p1->SetLabelType(PIE_VALUE_PER);
+
+// Add plot to pie graph
+$graph->Add($p1);
+
+// .. and send the image on it's marry way to the browser
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/piecex2.php b/web/classes/jpgraph/Examples/piecex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..9dbe5f11c0f689ee69c6fac3224a107278da9e69
--- /dev/null
+++ b/web/classes/jpgraph/Examples/piecex2.php
@@ -0,0 +1,70 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: piecex2.php,v 1.3.2.1 2003/08/19 20:40:12 aditus Exp $
+// Example of pie with center circle
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+// Some data
+$data = array(50,28,25,27,31,20);
+
+// A new pie graph
+$graph = new PieGraph(400,400,'auto');
+
+// Don't display the border
+$graph->SetFrame(false);
+
+// Uncomment this line to add a drop shadow to the border
+// $graph->SetShadow();
+
+// Setup title
+$graph->title->Set("PiePlotC");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,18);
+$graph->title->SetMargin(8); // Add a little bit more margin from the top
+
+// Create the pie plot
+$p1 = new PiePlotC($data);
+
+// Set size of pie
+$p1->SetSize(0.35);
+
+// Label font and color setup
+$p1->value->SetFont(FF_ARIAL,FS_BOLD,12);
+$p1->value->SetColor('white');
+
+$p1->value->Show();
+
+// Setup the title on the center circle
+$p1->midtitle->Set("Test mid\nRow 1\nRow 2");
+$p1->midtitle->SetFont(FF_ARIAL,FS_NORMAL,14);
+
+// Set color for mid circle
+$p1->SetMidColor('yellow');
+
+// Use percentage values in the legends values (This is also the default)
+$p1->SetLabelType(PIE_VALUE_PER);
+
+// The label array values may have printf() formatting in them. The argument to the
+// form,at string will be the value of the slice (either the percetage or absolute
+// depending on what was specified in the SetLabelType() above.
+$lbl = array("adam\n%.1f%%","bertil\n%.1f%%","johan\n%.1f%%",
+	     "peter\n%.1f%%","daniel\n%.1f%%","erik\n%.1f%%");
+$p1->SetLabels($lbl);
+
+// Uncomment this line to remove the borders around the slices
+// $p1->ShowBorder(false);
+
+// Add drop shadow to slices
+$p1->SetShadow();
+
+// Explode all slices 15 pixels
+$p1->ExplodeAll(15);
+
+// Add plot to pie graph
+$graph->Add($p1);
+
+// .. and send the image on it's marry way to the browser
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pieex1.php b/web/classes/jpgraph/Examples/pieex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..156d6e2ed14b93119312c70adcd902d781f89fd1
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pieex1.php
@@ -0,0 +1,32 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+// Some data
+$data = array(113,5,160,3,15,10,1);
+
+// Create the Pie Graph.
+$graph = new PieGraph(300,200);
+$graph->SetShadow();
+
+// Set A title for the plot
+$graph->title->Set("Example 1 Pie plot");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,14); 
+$graph->title->SetColor("brown");
+
+// Create pie plot
+$p1 = new PiePlot($data);
+//$p1->SetSliceColors(array("red","blue","yellow","green"));
+$p1->SetTheme("earth");
+
+$p1->value->SetFont(FF_ARIAL,FS_NORMAL,10);
+// Set how many pixels each slice should explode
+$p1->Explode(array(0,15,15,25,15));
+
+
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pieex2.php b/web/classes/jpgraph/Examples/pieex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..195d9755c28db8379a5bd9851749915297b08808
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pieex2.php
@@ -0,0 +1,24 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+// Some data
+$data = array(40,21,17,14,23);
+
+// Create the Pie Graph. 
+$graph = new PieGraph(300,200);
+$graph->SetShadow();
+
+// Set A title for the plot
+$graph->title->Set("Example 2 Pie plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Create
+$p1 = new PiePlot($data);
+$p1->SetLegends(array("Jan","Feb","Mar","Apr","May","Jun","Jul"));
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pieex3.php b/web/classes/jpgraph/Examples/pieex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..a7795c3a2b5462b120cbf1f7774aa8afa9ec64db
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pieex3.php
@@ -0,0 +1,53 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+// Some data
+$data = array(40,21,17,14,23);
+
+// Create the Pie Graph.
+$graph = new PieGraph(350,300);
+$graph->SetShadow();
+
+// Set A title for the plot
+$graph->title->Set("Multiple - Pie plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Create plots
+$size=0.13;
+$p1 = new PiePlot($data);
+$p1->SetLegends(array("Jan","Feb","Mar","Apr","May"));
+$p1->SetSize($size);
+$p1->SetCenter(0.25,0.32);
+$p1->value->SetFont(FF_FONT0);
+$p1->title->Set("2001");
+
+$p2 = new PiePlot($data);
+$p2->SetSize($size);
+$p2->SetCenter(0.65,0.32);
+$p2->value->SetFont(FF_FONT0);
+$p2->title->Set("2002");
+
+$p3 = new PiePlot($data);
+$p3->SetSize($size);
+$p3->SetCenter(0.25,0.75);
+$p3->value->SetFont(FF_FONT0);
+$p3->title->Set("2003");
+
+$p4 = new PiePlot($data);
+$p4->SetSize($size);
+$p4->SetCenter(0.65,0.75);
+$p4->value->SetFont(FF_FONT0);
+$p4->title->Set("2004");
+
+$graph->Add($p1);
+$graph->Add($p2);
+$graph->Add($p3);
+$graph->Add($p4);
+
+$graph->Stroke();
+
+?>
+
+
+
diff --git a/web/classes/jpgraph/Examples/pieex4.php b/web/classes/jpgraph/Examples/pieex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..58544267b4c5edb2b8365a0cf47df25409276345
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pieex4.php
@@ -0,0 +1,25 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+$data = array(40,60,21,33);
+
+$graph = new PieGraph(300,200);
+$graph->SetShadow();
+
+$graph->title->Set("Example 4 of pie plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$p1 = new PiePlot($data);
+$p1->value->SetFont(FF_FONT1,FS_BOLD);
+$p1->value->SetColor("darkred");
+$p1->SetSize(0.3);
+$p1->SetCenter(0.4);
+$p1->SetLegends(array("Jan","Feb","Mar","Apr","May"));
+$graph->Add($p1);
+
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pieex5.php b/web/classes/jpgraph/Examples/pieex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..808ab3e9597c097d45503ea5ba854687e8e070ee
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pieex5.php
@@ -0,0 +1,31 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+$data = array(40,60,21,33);
+
+// Setup graph
+$graph = new PieGraph(300,200);
+$graph->SetShadow();
+
+// Setup graph title
+$graph->title->Set("Example 5 of pie plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Create pie plot
+$p1 = new PiePlot($data);
+$p1->value->SetFont(FF_VERDANA,FS_BOLD);
+$p1->value->SetColor("darkred");
+$p1->SetSize(0.3);
+$p1->SetCenter(0.4);
+$p1->SetLegends(array("Jan","Feb","Mar","Apr","May"));
+//$p1->SetStartAngle(M_PI/8);
+$p1->ExplodeSlice(3);
+
+$graph->Add($p1);
+
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pieex6.php b/web/classes/jpgraph/Examples/pieex6.php
new file mode 100755
index 0000000000000000000000000000000000000000..46621e7022088dec3b6bee8c14db8c6e2c324113
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pieex6.php
@@ -0,0 +1,48 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+// Some data
+$data = array(27,23,47,17);
+
+// A new graph
+$graph = new PieGraph(350,200);
+$graph->SetShadow();
+
+// Setup title
+$graph->title->Set("Example of pie plot with absolute labels");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// The pie plot
+$p1 = new PiePlot($data);
+
+// Move center of pie to the left to make better room
+// for the legend
+$p1->SetCenter(0.35,0.5);
+
+// No border
+$p1->ShowBorder(false);
+
+// Label font and color setup
+$p1->value->SetFont(FF_FONT1,FS_BOLD);
+$p1->value->SetColor("darkred");
+
+// Use absolute values (type==1)
+$p1->SetLabelType(PIE_VALUE_ABS);
+
+// Label format
+$p1->value->SetFormat("$%d");
+$p1->value->Show();
+
+// Size of pie in fraction of the width of the graph
+$p1->SetSize(0.3);
+
+// Legends
+$p1->SetLegends(array("May ($%d)","June ($%d)","July ($%d)","Aug ($%d)"));
+$graph->legend->Pos(0.05,0.15);
+
+$graph->Add($p1);
+$graph->Stroke();
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pieex7.php b/web/classes/jpgraph/Examples/pieex7.php
new file mode 100755
index 0000000000000000000000000000000000000000..77f46102027a754241b7ea6c30f9bd868996c2bd
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pieex7.php
@@ -0,0 +1,52 @@
+<?php // content="text/plain; charset=utf-8"
+//$Id: pieex7.php,v 1.1 2002/06/17 13:53:43 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+// Some data
+$data = array(27,23,0,17);
+
+// A new graph
+$graph = new PieGraph(350,200);
+$graph->SetShadow();
+
+// Setup title
+$graph->title->Set("Pie plot with absolute labels");
+$graph->subtitle->Set('(With hidden 0 labels)');
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// The pie plot
+$p1 = new PiePlot($data);
+
+
+// Move center of pie to the left to make better room
+// for the legend
+$p1->SetCenter(0.35,0.5);
+
+// No border
+$p1->ShowBorder(false);
+
+// Label font and color setup
+$p1->value->SetFont(FF_FONT1,FS_BOLD);
+$p1->value->SetColor("darkred");
+
+// Use absolute values (type==1)
+$p1->SetLabelType(PIE_VALUE_ABS);
+
+// Label format
+$p1->value->SetFormat("$%d");
+$p1->value->HideZero();
+$p1->value->Show();
+
+// Size of pie in fraction of the width of the graph
+$p1->SetSize(0.3);
+
+// Legends
+$p1->SetLegends(array("May ($%d)","June ($%d)","July ($%d)","Aug ($%d)"));
+$graph->legend->Pos(0.05,0.2);
+
+$graph->Add($p1);
+$graph->Stroke();
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pieex8.php b/web/classes/jpgraph/Examples/pieex8.php
new file mode 100755
index 0000000000000000000000000000000000000000..0ca17859d0015a66d663e33fd9bd0648091a07c2
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pieex8.php
@@ -0,0 +1,33 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+$data = array(40,60,31,35);
+
+// A new pie graph
+$graph = new PieGraph(250,200);
+$graph->SetShadow();
+
+// Title setup
+$graph->title->Set("Adjusting the label pos");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Setup the pie plot
+$p1 = new PiePlot($data);
+
+// Adjust size and position of plot
+$p1->SetSize(0.4);
+$p1->SetCenter(0.5,0.52);
+
+// Setup slice labels and move them into the plot
+$p1->value->SetFont(FF_FONT1,FS_BOLD);
+$p1->value->SetColor("darkred");
+$p1->SetLabelPos(0.6);
+
+// Finally add the plot
+$graph->Add($p1);
+
+// ... and stroke it
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/pieex9.php b/web/classes/jpgraph/Examples/pieex9.php
new file mode 100755
index 0000000000000000000000000000000000000000..2354d06d1f479d5540bdaab4119e049e9aa98538
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pieex9.php
@@ -0,0 +1,39 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+$data = array(40,60,31,35);
+
+// A new pie graph
+$graph = new PieGraph(250,200);
+$graph->SetShadow();
+
+// Title setup
+$graph->title->Set("Exploding all slices");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Setup the pie plot
+$p1 = new PiePlot($data);
+
+// Adjust size and position of plot
+$p1->SetSize(0.35);
+$p1->SetCenter(0.5,0.52);
+
+// Setup slice labels and move them into the plot
+$p1->value->SetFont(FF_FONT1,FS_BOLD);
+$p1->value->SetColor("darkred");
+$p1->SetLabelPos(0.65);
+
+// Explode all slices
+$p1->ExplodeAll(10);
+
+// Add drop shadow
+$p1->SetShadow();
+
+// Finally add the plot
+$graph->Add($p1);
+
+// ... and stroke it
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/pielabelsex1.php b/web/classes/jpgraph/Examples/pielabelsex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..d2cf93a07ab716f15ee253f374b8cfb8df987f1c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pielabelsex1.php
@@ -0,0 +1,38 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+$data = array(19,12,4,3,3,12,3,3,5,6,7,8,8,1,7,2,2,4,6,8,21,23,2,2,12);
+
+// Create the Pie Graph.
+$graph = new PieGraph(300,350);
+
+// Set A title for the plot
+$graph->title->Set("Label guide lines");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12); 
+$graph->title->SetColor("darkblue");
+$graph->legend->Pos(0.1,0.2);
+
+
+// Create pie plot
+$p1 = new PiePlot($data);
+$p1->SetCenter(0.5,0.55);
+$p1->SetSize(0.3);
+
+// Enable and set policy for guide-lines
+$p1->SetGuideLines();
+$p1->SetGuideLinesAdjust(1.4);
+
+// Setup the labels
+$p1->SetLabelType(PIE_VALUE_PER);	
+$p1->value->Show();			
+$p1->value->SetFont(FF_ARIAL,FS_NORMAL,9);	
+$p1->value->SetFormat('%2.1f%%');		
+
+// Add and stroke
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pielabelsex2.php b/web/classes/jpgraph/Examples/pielabelsex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..bb3cc2ab06119878d0069c0b506fd50fb06799f5
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pielabelsex2.php
@@ -0,0 +1,38 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+$data = array(19,12,4,3,3,12,3,3,5,6,7,8,8,1,7,2,2,4,6,8,21,23,2,2,12);
+
+// Create the Pie Graph.
+$graph = new PieGraph(300,350);
+
+// Set A title for the plot
+$graph->title->Set("Label guide lines");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12); 
+$graph->title->SetColor("darkblue");
+$graph->legend->Pos(0.1,0.2);
+
+
+// Create pie plot
+$p1 = new PiePlot($data);
+$p1->SetCenter(0.5,0.55);
+$p1->SetSize(0.3);
+
+// Enable and set policy for guide-lines. Make labels line up vertically
+$p1->SetGuideLines(true,false);
+$p1->SetGuideLinesAdjust(1.5);
+
+// Setup the labels
+$p1->SetLabelType(PIE_VALUE_PER);	
+$p1->value->Show();			
+$p1->value->SetFont(FF_ARIAL,FS_NORMAL,9);	
+$p1->value->SetFormat('%2.1f%%');		
+
+// Add and stroke
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pielabelsex3.php b/web/classes/jpgraph/Examples/pielabelsex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..cff6d40f91326f20d0151b5107de19f91720ba42
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pielabelsex3.php
@@ -0,0 +1,39 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+$data = array(19,12,4,3,3,12,3,3,5,6,7,8,8,1,7,2,2,4,6,8,21,23,2,2,12);
+
+// Create the Pie Graph.
+$graph = new PieGraph(300,350);
+
+// Set A title for the plot
+$graph->title->Set("Label guide lines");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12); 
+$graph->title->SetColor("darkblue");
+$graph->legend->Pos(0.1,0.2);
+
+
+// Create pie plot
+$p1 = new PiePlot($data);
+$p1->SetCenter(0.5,0.55);
+$p1->SetSize(0.3);
+
+// Enable and set policy for guide-lines. Make labels line up vertically
+// and force guide lines to always beeing used
+$p1->SetGuideLines(true,false,true);
+$p1->SetGuideLinesAdjust(1.5);
+
+// Setup the labels
+$p1->SetLabelType(PIE_VALUE_PER);	
+$p1->value->Show();			
+$p1->value->SetFont(FF_ARIAL,FS_NORMAL,9);	
+$p1->value->SetFormat('%2.1f%%');		
+
+// Add and stroke
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pielabelsex4.php b/web/classes/jpgraph/Examples/pielabelsex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..5187b3c51fec7c4719ba42145776e0dc30a359d1
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pielabelsex4.php
@@ -0,0 +1,38 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_pie.php');
+
+$data = array(19,12,4,3,3,12,3,3,5,6,7,8,8,1,7,2,2,4,6,8,21,23,2,2,12);
+
+// Create the Pie Graph.
+$graph = new PieGraph(300,350);
+
+// Set A title for the plot
+$graph->title->Set("Label guide lines");
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12); 
+$graph->title->SetColor("darkblue");
+$graph->legend->Pos(0.1,0.2);
+
+
+// Create pie plot
+$p1 = new PiePlot($data);
+$p1->SetCenter(0.5,0.55);
+$p1->SetSize(0.3);
+
+// Enable and set policy for guide-lines. Make labels line up vertically
+$p1->SetGuideLines(true,false);
+$p1->SetGuideLinesAdjust(1.1);
+
+// Setup the labels
+$p1->SetLabelType(PIE_VALUE_PER);	
+$p1->value->Show();			
+$p1->value->SetFont(FF_ARIAL,FS_NORMAL,9);	
+$p1->value->SetFormat('%2.1f%%');		
+
+// Add and stroke
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pielabelsex5.php b/web/classes/jpgraph/Examples/pielabelsex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..22e697d32ed25f9c4e0890817f1565ed9f546789
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pielabelsex5.php
@@ -0,0 +1,48 @@
+<?php // content="text/plain; charset=utf-8"
+include ("../jpgraph.php");
+include ("../jpgraph_pie.php");
+
+// Some data and the labels
+$data   = array(19,12,4,7,3,12,3);
+$labels = array("First\n(%.1f%%)",
+                "Second\n(%.1f%%)","Third\n(%.1f%%)",
+                "Fourth\n(%.1f%%)","Fifth\n(%.1f%%)",
+                "Sixth\n(%.1f%%)","Seventh\n(%.1f%%)");
+
+// Create the Pie Graph.
+$graph = new PieGraph(300,300);
+$graph->SetShadow();
+
+// Set A title for the plot
+$graph->title->Set('String labels with values');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+$graph->title->SetColor('black');
+
+// Create pie plot
+$p1 = new PiePlot($data);
+$p1->SetCenter(0.5,0.5);
+$p1->SetSize(0.3);
+
+// Setup the labels to be displayed
+$p1->SetLabels($labels);
+
+// This method adjust the position of the labels. This is given as fractions
+// of the radius of the Pie. A value < 1 will put the center of the label
+// inside the Pie and a value >= 1 will pout the center of the label outside the
+// Pie. By default the label is positioned at 0.5, in the middle of each slice.
+$p1->SetLabelPos(1);
+
+// Setup the label formats and what value we want to be shown (The absolute)
+// or the percentage.
+$p1->SetLabelType(PIE_VALUE_PER);
+$p1->value->Show();
+$p1->value->SetFont(FF_ARIAL,FS_NORMAL,9);
+$p1->value->SetColor('darkgray');
+
+// Add and stroke
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/plotbanddensity_ex0.php b/web/classes/jpgraph/Examples/plotbanddensity_ex0.php
new file mode 100755
index 0000000000000000000000000000000000000000..3615a9579a552b2c1505d615cd5c921bec9af154
--- /dev/null
+++ b/web/classes/jpgraph/Examples/plotbanddensity_ex0.php
@@ -0,0 +1,38 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(10,29,3,6);
+
+// Create the graph. 
+$graph = new Graph(200,200);	
+$graph->SetScale('textlin');
+$graph->SetMargin(25,10,20,25);
+$graph->SetBox(true);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("lightblue");
+
+$graph->ygrid->Show(false);
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add band
+$band = new PlotBand(HORIZONTAL,BAND_3DPLANE,15,35,'khaki4');
+$band->SetDensity(10);
+$band->ShowFrame(true);
+$graph->AddBand($band);
+
+// Set title
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->title->SetColor('darkred');
+$graph->title->Set('BAND_3DPLANE, Density=10');
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/plotbanddensity_ex1.php b/web/classes/jpgraph/Examples/plotbanddensity_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..ed07487e5e0605257c4e199978670f66fb481413
--- /dev/null
+++ b/web/classes/jpgraph/Examples/plotbanddensity_ex1.php
@@ -0,0 +1,38 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(10,29,3,6);
+
+// Create the graph. 
+$graph = new Graph(200,200);	
+$graph->SetScale('textlin');
+$graph->SetMargin(25,10,20,25);
+$graph->SetBox(true);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("lightblue");
+
+$graph->ygrid->Show(false);
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add band
+$band = new PlotBand(HORIZONTAL,BAND_3DPLANE,15,35,'khaki4');
+$band->SetDensity(40);
+$band->ShowFrame(true);
+$graph->AddBand($band);
+
+// Set title
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->title->SetColor('darkred');
+$graph->title->Set('BAND_3DPLANE, Density=40');
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/plotbanddensity_ex2.php b/web/classes/jpgraph/Examples/plotbanddensity_ex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..908efdf507943e4dedf1d10e959e60e1e200ceca
--- /dev/null
+++ b/web/classes/jpgraph/Examples/plotbanddensity_ex2.php
@@ -0,0 +1,38 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(10,29,3,6);
+
+// Create the graph. 
+$graph = new Graph(200,200);	
+$graph->SetScale('textlin');
+$graph->SetMargin(25,10,20,25);
+$graph->SetBox(true);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10);
+$graph->ygrid->Show(false);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("lightblue");
+
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add band
+$band = new PlotBand(HORIZONTAL,BAND_3DPLANE,15,35,'khaki4');
+$band->SetDensity(80);
+$band->ShowFrame(true);
+$graph->AddBand($band);
+
+// Set title
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->title->SetColor('darkred');
+$graph->title->Set('BAND_3DPLANE, Density=80');
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/plotlineex1.php b/web/classes/jpgraph/Examples/plotlineex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..43a8016edbe4695448d992cfa488f3be565d8913
--- /dev/null
+++ b/web/classes/jpgraph/Examples/plotlineex1.php
@@ -0,0 +1,36 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_plotline.php');
+
+$datay=array(2,3,5,8.5,11.5,6,3);
+
+// Create the graph.
+$graph = new Graph(460,400,'auto');
+$graph->SetScale("textlin");
+$graph->SetMargin(40,20,50,70);
+
+$graph->legend->SetPos(0.5,0.97,'center','bottom');
+
+$graph->title->Set('Plot line legend');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+$graph->SetTitleBackground('lightblue:1.3',TITLEBKG_STYLE2,TITLEBKG_FRAME_BEVEL);
+$graph->SetTitleBackgroundFillStyle(TITLEBKG_FILLSTYLE_HSTRIPED,'lightblue','navy');
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->value->Show();
+$bplot->value->SetFont(FF_VERDANA,FS_BOLD,8);
+$bplot->SetValuePos('top');
+$bplot->SetLegend('Bar Legend');
+$graph->Add($bplot);
+
+$pline = new PlotLine(HORIZONTAL,8,'red',2);
+$pline->SetLegend('Line Legend');
+$graph->legend->SetColumns(10);
+$graph->Add($pline);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/polar_csimex1.php b/web/classes/jpgraph/Examples/polar_csimex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..ffaac17674138489e2cd62b545fd93c90a2b4898
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polar_csimex1.php
@@ -0,0 +1,69 @@
+<?php // content="text/plain; charset=utf-8"
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+$data = array(0,1,10,2,30,25,40,60,
+	      50,110,60,160,70,210,75,230,80,260,85,370,
+	      90,480,
+	      95,370,100,260,105,230,
+	      110,210,120,160,130,110,140,60,
+	      150,25,170,2,180,1);
+
+$n = count($data);
+for( $i=0; $i < $n; ++$i ) {
+	$targets[$i] = "#$i";
+}
+
+$graph = new PolarGraph(350,320);
+$graph->SetScale('log',100);
+$graph->SetType(POLAR_180);
+
+// Hide frame around graph (by setting width=0)
+$graph->SetFrame(true,'white',1);
+
+// Show both major and minor grid lines
+$graph->axis->ShowGrid(true,true);
+
+// Set color for gradient lines
+$graph->axis->SetGridColor('lightblue:0.9','lightblue:0.9','lightblue:0.9');
+
+// Set label and axis colors
+$graph->axis->SetColor('black','navy','darkred');
+
+// Draw the ticks on the bottom side of the radius axis
+$graph->axis->SetTickSide(SIDE_DOWN);
+
+// Increase the margin for the labels since we changed the
+// side of the ticks.
+$graph->axis->SetLabelMargin(6);
+
+// Change fonts
+$graph->axis->SetFont(FF_ARIAL,FS_NORMAL,8);
+$graph->axis->SetAngleFont(FF_ARIAL,FS_NORMAL,8);
+
+// Setup axis title
+$graph->axis->SetTitle('Coverage (in meter)','middle');
+$graph->axis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Setup graph title
+$graph->title->Set('Polar plot #9');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,16);
+$graph->title->SetColor('navy');
+
+// Setup tab title
+$graph->tabtitle->Set('Microphone #1');
+$graph->tabtitle->SetColor('brown:0.5','lightyellow');
+
+// Setup the polar plot with CSIM targets for the marks
+$p = new PolarPlot($data);
+$p->SetFillColor('lightblue@0.5');
+$p->mark->SetType(MARK_SQUARE);
+$p->mark->SetWidth(10);
+$p->SetCSIMTargets( $targets );
+
+$graph->Add($p);
+
+$graph->StrokeCSIM();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarclockex1.php b/web/classes/jpgraph/Examples/polarclockex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..bdf9008e36947b5ca071b9b06b265d4512d65183
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarclockex1.php
@@ -0,0 +1,55 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+//$data = array(22,12,27,40,80,48,120,40,142,27,170,12);
+
+$data = array(
+0,0,10,2,30,25,40,60,
+50,110,60,140,70,170,80,190,
+85,195,90,200,95,195,100,190,
+110,170,120,140,130,110,140,60,
+150,25,170,2,180,0);
+
+//$data2 = array(0,0,50,2,60,30,65,90,60,120,50,150,20,170,0,180);
+
+$data2 = array(0,0,34,56,90,90,170,65,220,90,270,120,300,60,355,10);
+
+$graph = new PolarGraph(350,350);
+$graph->SetScale('lin',150);
+
+$graph->SetMarginColor('#FFE6C0');
+$graph->SetType(POLAR_360);
+$graph->SetMargin(40,40,50,40);
+$graph->SetClockwise(true);
+
+//$graph->Set90AndMargin(60,50,70,120);
+
+$graph->SetBox(true);
+$graph->SetFrame(false);
+$graph->axis->ShowGrid(true,false,true);
+$graph->axis->SetGridColor('gray','gray','gray');
+
+$graph->axis->SetFont(FF_ARIAL,FS_NORMAL,8);
+$graph->axis->SetTitle('X-Axis','center');
+
+$graph->axis->SetColor('black','black','darkred');
+$graph->axis->SetAngleFont(FF_ARIAL,FS_NORMAL,8);
+
+$graph->title->Set('Clockwise polar plot');
+$graph->title->SetFont(FF_COMIC,FS_NORMAL,16);
+$graph->title->SetColor('navy');
+
+
+
+$p = new PolarPlot($data);
+$p->SetFillColor('lightblue@0.5');
+$graph->Add($p);
+
+//$p2 = new PolarPlot($data2);
+//$p2->SetFillColor('red@0.5');
+//$graph->Add($p2);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarclockex2.php b/web/classes/jpgraph/Examples/polarclockex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..11cdeca668aa3b79c2e83c9a3bdb9b6a8f58bd5a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarclockex2.php
@@ -0,0 +1,53 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+//$data = array(22,12,27,40,80,48,120,40,142,27,170,12);
+
+$data = array(
+0,0,10,2,30,25,40,60,
+50,110,60,140,70,170,80,190,
+85,195,90,200,95,195,100,190,
+110,170,120,140,130,110,140,60,
+150,25,170,2,180,0);
+
+//$data2 = array(0,0,50,2,60,30,65,90,60,120,50,150,20,170,0,180);
+
+$data2 = array(0,0,34,56,90,90,170,65,220,90,270,120,300,60,355,10);
+
+$graph = new PolarGraph(350,350);
+$graph->SetScale('lin',150);
+
+$graph->SetMarginColor('#FFE6C0');
+$graph->SetType(POLAR_360);
+$graph->SetClockwise(true);
+$graph->Set90AndMargin(40,40,50,40);
+
+$graph->SetBox(true);
+$graph->SetFrame(false);
+$graph->axis->ShowGrid(true,false,true);
+$graph->axis->SetGridColor('gray','gray','gray');
+
+$graph->axis->SetFont(FF_ARIAL,FS_NORMAL,8);
+$graph->axis->SetTitle('X-Axis','center');
+
+$graph->axis->SetColor('black','black','darkred');
+$graph->axis->SetAngleFont(FF_ARIAL,FS_NORMAL,8);
+
+$graph->title->Set('Clockwise polar plot (rotated)');
+$graph->title->SetFont(FF_COMIC,FS_NORMAL,16);
+$graph->title->SetColor('navy');
+
+
+
+$p = new PolarPlot($data);
+$p->SetFillColor('lightblue@0.5');
+$graph->Add($p);
+
+//$p2 = new PolarPlot($data2);
+//$p2->SetFillColor('red@0.5');
+//$graph->Add($p2);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarex0-180.php b/web/classes/jpgraph/Examples/polarex0-180.php
new file mode 100755
index 0000000000000000000000000000000000000000..4fa344fa9118caafb2737442604e9ab7358bd699
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarex0-180.php
@@ -0,0 +1,27 @@
+<?php // content="text/plain; charset=utf-8"
+// A simple Polar graph, example 0
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+
+$data = array(0,1,10,2,30,25,40,60,
+	      50,110,60,160,70,210,75,230,80,260,
+	      85,270,90,280,
+	      95,270,100,260,105,230,
+	      110,210,120,160,130,110,140,60,
+	      150,25,170,2,180,1);
+
+
+$graph = new PolarGraph(250,250);
+$graph->SetScale('lin');
+$graph->SetMargin(35,35,25,25);
+$graph->SetType(POLAR_180);
+
+$p = new PolarPlot($data);
+$p->SetFillColor('lightblue@0.5');
+$graph->Add($p);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarex0.php b/web/classes/jpgraph/Examples/polarex0.php
new file mode 100755
index 0000000000000000000000000000000000000000..b11aa6e13625fcf1f5f1e9c48c8522104b54e4b4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarex0.php
@@ -0,0 +1,26 @@
+<?php // content="text/plain; charset=utf-8"
+// A simple Polar graph, example 0
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+
+$data = array(0,1,10,2,30,25,40,60,
+	      50,110,60,160,70,210,75,230,80,260,
+	      85,270,90,280,
+	      95,270,100,260,105,230,
+	      110,210,120,160,130,110,140,60,
+	      150,25,170,2,180,1);
+
+
+$graph = new PolarGraph(250,250);
+$graph->SetScale('lin');
+$graph->SetMargin(35,35,25,25);
+
+$p = new PolarPlot($data);
+$p->SetFillColor('lightblue@0.5');
+$graph->Add($p);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarex1.php b/web/classes/jpgraph/Examples/polarex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..b0c7f8afbae47e2fbe69542c00130f0846477cd0
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarex1.php
@@ -0,0 +1,30 @@
+<?php // content="text/plain; charset=utf-8"
+// A simple Polar graph, example 1
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+
+$data = array(0,1,10,2,30,25,40,60,
+	      50,110,60,160,70,210,75,230,80,260,
+	      85,270,90,280,
+	      95,270,100,260,105,230,
+	      110,210,120,160,130,110,140,60,
+	      150,25,170,2,180,1);
+
+
+$graph = new PolarGraph(600,500);
+$graph->SetScale('lin');
+$graph->SetType(POLAR_180);
+//$graph->SetAngle(90);
+//$graph->SetMargin(30-150,30-150,30+150,30+150);
+$graph->Set90AndMargin(40,40,40,40);
+//$graph->axis->SetLabelAlign('right','center');
+
+$p = new PolarPlot($data);
+$p->SetLegend("Test");
+$graph->Add($p);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarex10.php b/web/classes/jpgraph/Examples/polarex10.php
new file mode 100755
index 0000000000000000000000000000000000000000..d864a23d49ac63a19449b726714d003a79000ec8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarex10.php
@@ -0,0 +1,66 @@
+<?php // content="text/plain; charset=utf-8"
+// A simple Polar graph,
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+$data = array(5,1,20,5,30,25,40,60,
+	      50,110,60,160,70,210,75,230,80,260,85,370,
+	      90,480,
+	      95,370,100,260,105,230,
+	      110,210,120,160,130,110,140,60,
+	      150,25,160,5,175,1);
+$n = count($data);
+/*
+for($i=0; $i < $n; $i+=2 ) {
+    $data[$n+$i] = 360-$data[$i];
+    $data[$n+$i+1] = $data[$i+1];
+}
+*/
+$graph = new PolarGraph(350,480);
+$graph->SetScale('log',100);
+$graph->SetType(POLAR_360);
+
+// Hide frame around graph (by setting width=0)
+$graph->SetFrame(true,'white',1);
+
+// Show both major and minor grid lines
+$graph->axis->ShowGrid(true,true);
+
+// Set color for gradient lines
+$graph->axis->SetGridColor('lightblue:0.9','lightblue:0.9','lightblue:0.9');
+
+// Set label and axis colors
+$graph->axis->SetColor('black','navy','darkred');
+
+// Draw the ticks on the bottom side of the radius axis
+$graph->axis->SetTickSide(SIDE_DOWN);
+
+// Increase the margin for the labels since we changed the
+// side of the ticks.
+$graph->axis->SetLabelMargin(6);
+
+// Change fonts
+$graph->axis->SetFont(FF_ARIAL,FS_NORMAL,8);
+$graph->axis->SetAngleFont(FF_ARIAL,FS_NORMAL,8);
+
+
+// Setup graph title
+$graph->title->Set('Polar plot #10');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,16);
+$graph->title->SetColor('navy');
+
+// Setup tab title
+$graph->tabtitle->Set('Microphone #1');
+$graph->tabtitle->SetColor('brown:0.5','lightyellow');
+
+
+$p = new PolarPlot($data);
+$p->SetFillColor('lightblue@0.5');
+$p->mark->SetType(MARK_SQUARE);
+
+$graph->Add($p);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarex2.php b/web/classes/jpgraph/Examples/polarex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..d4a9779a2990a2a75c16d2d9bb4b67c9f6fcbe9a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarex2.php
@@ -0,0 +1,34 @@
+<?php // content="text/plain; charset=utf-8"
+// A simple Polar graph, example 2
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+
+$data = array(0,1,10,2,30,25,40,60,
+	      50,110,60,160,70,210,75,230,80,260,
+	      85,270,90,280,
+	      95,270,100,260,105,230,
+	      110,210,120,160,130,110,140,60,
+	      150,25,170,2,180,1);
+
+
+$graph = new PolarGraph(300,350);
+$graph->SetScale('lin');
+
+$graph->title->Set('Polar plot #2');
+$graph->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->title->SetColor('navy');
+
+// Hide last labels on the Radius axis
+// They intersect with the box otherwise
+$graph->axis->HideLastTickLabel();
+
+$p = new PolarPlot($data);
+$p->SetFillColor('lightred@0.5');
+
+$graph->Add($p);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarex3-lin.php b/web/classes/jpgraph/Examples/polarex3-lin.php
new file mode 100755
index 0000000000000000000000000000000000000000..430438c908494f71a336d9e75ac6d3494aff760b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarex3-lin.php
@@ -0,0 +1,33 @@
+<?php // content="text/plain; charset=utf-8"
+// A simple Polar graph, example 2
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+
+$data = array(0,1,10,2,30,25,40,60,
+	      50,110,60,160,70,210,75,230,80,260,
+	      85,270,90,280,
+	      95,270,100,260,105,230,
+	      110,210,120,160,130,110,140,60,
+	      150,25,170,2,180,1);
+
+
+$graph = new PolarGraph(300,300);
+$graph->SetScale('lin',200);
+$graph->SetType(POLAR_180);
+
+$graph->title->Set('Polar plot #3');
+$graph->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->title->SetColor('navy');
+
+$graph->axis->ShowGrid(true,false);
+
+$p = new PolarPlot($data);
+$p->SetFillColor('lightred@0.5');
+
+$graph->Add($p);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarex3.php b/web/classes/jpgraph/Examples/polarex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..82bf18a237b74a909f9db8e7dd48466aa4fb9583
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarex3.php
@@ -0,0 +1,33 @@
+<?php // content="text/plain; charset=utf-8"
+// A simple Polar graph, example 2
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+
+$data = array(0,1,10,2,30,25,40,60,
+	      50,110,60,160,70,210,75,230,80,260,
+	      85,270,90,280,
+	      95,270,100,260,105,230,
+	      110,210,120,160,130,110,140,60,
+	      150,25,170,2,180,1);
+
+
+$graph = new PolarGraph(300,300);
+$graph->SetScale('log',100);
+$graph->SetType(POLAR_180);
+
+$graph->title->Set('Polar plot #3');
+$graph->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->title->SetColor('navy');
+
+$graph->axis->ShowGrid(true,false);
+
+$p = new PolarPlot($data);
+$p->SetFillColor('lightred@0.5');
+
+$graph->Add($p);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarex4.php b/web/classes/jpgraph/Examples/polarex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..a4fb1d0841f74e6b7fea9b58f177d37d90328ddc
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarex4.php
@@ -0,0 +1,34 @@
+<?php // content="text/plain; charset=utf-8"
+// A simple Polar graph, example 2
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+
+$data = array(0,1,10,2,30,25,40,60,
+	      50,110,60,160,70,210,75,230,80,260,
+	      85,270,90,280,
+	      95,270,100,260,105,230,
+	      110,210,120,160,130,110,140,60,
+	      150,25,170,2,180,1);
+
+
+$graph = new PolarGraph(300,350);
+$graph->SetScale('log');
+
+$graph->title->Set('Polar plot #4');
+$graph->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->title->SetColor('navy');
+
+// Hide last labels on the Radius axis
+// They intersect with the box otherwise
+$graph->axis->HideLastTickLabel();
+
+$p = new PolarPlot($data);
+$p->SetFillColor('lightred@0.5');
+
+$graph->Add($p);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarex5.php b/web/classes/jpgraph/Examples/polarex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..7da58020b8cb9cb45a4eca0a2a2af7efe1bb8859
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarex5.php
@@ -0,0 +1,37 @@
+<?php // content="text/plain; charset=utf-8"
+// A simple Polar graph, example 2
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+
+$data = array(0,1,10,2,30,25,40,60,
+	      50,110,60,160,70,210,75,230,80,260,
+	      85,270,90,280,
+	      95,270,100,260,105,230,
+	      110,210,120,160,130,110,140,60,
+	      150,25,170,2,180,1);
+
+
+$graph = new PolarGraph(300,350);
+$graph->SetScale('log');
+
+// Show both major and minor grid lines
+$graph->axis->ShowGrid(true,true);
+
+$graph->title->Set('Polar plot #5');
+$graph->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->title->SetColor('navy');
+
+// Hide last labels on the Radius axis
+// They intersect with the box otherwise
+$graph->axis->HideLastTickLabel();
+
+$p = new PolarPlot($data);
+$p->SetFillColor('lightred@0.5');
+
+$graph->Add($p);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarex6.php b/web/classes/jpgraph/Examples/polarex6.php
new file mode 100755
index 0000000000000000000000000000000000000000..21ae6a277209cb330141c7d1bab0b40e6c3677cc
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarex6.php
@@ -0,0 +1,35 @@
+<?php // content="text/plain; charset=utf-8"
+// A simple Polar graph,
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+
+$data = array(0,1,10,2,30,25,40,60,
+	      50,110,60,160,70,210,75,230,80,260,85,270,
+	      90,480,
+	      95,270,100,260,105,230,
+	      110,210,120,160,130,110,140,60,
+	      150,25,170,2,180,1);
+
+
+$graph = new PolarGraph(300,350);
+$graph->SetScale('log');
+$graph->SetType(POLAR_180);
+
+// Show both major and minor grid lines
+$graph->axis->ShowGrid(true,true);
+
+$graph->title->Set('Polar plot #6');
+$graph->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->title->SetColor('navy');
+
+
+$p = new PolarPlot($data);
+$p->SetFillColor('lightred@0.5');
+
+$graph->Add($p);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarex7-1.php b/web/classes/jpgraph/Examples/polarex7-1.php
new file mode 100755
index 0000000000000000000000000000000000000000..5b593a19b5869f94498d8e0b3a15f3e376cc9305
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarex7-1.php
@@ -0,0 +1,50 @@
+<?php // content="text/plain; charset=utf-8"
+// A simple Polar graph,
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+
+$data = array(0,1,30,2,30,25,40,60,
+	      50,110,60,160,70,210,75,230,80,260,85,370,
+	      90,480,
+	      95,370,100,260,105,230,
+	      110,210,120,160,130,110,140,60,
+	      150,25,150,2,180,1);
+
+$graph = new PolarGraph(300,350);
+$graph->SetScale('log',100);
+$graph->SetType(POLAR_180);
+$graph->SetPlotSize(220,250);
+
+// Hide frame around graph (by setting width=0)
+$graph->SetFrame(true,'white',1);
+
+$graph->SetBackgroundGradient('blue:1.3','brown:1.4',GRAD_HOR,BGRAD_PLOT);
+
+// Set color for gradient lines
+$graph->axis->SetGridColor('gray','gray','gray');
+
+// Setup axis title
+$graph->axis->SetTitle('Coverage (in meter)','middle');
+$graph->axis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$graph->title->Set('Polar plot #7');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,16);
+$graph->title->SetColor('navy');
+
+// Adjust legen box position and color
+$graph->legend->SetColor('navy','darkgray');
+$graph->legend->SetFillColor('white');
+$graph->legend->SetShadow('darkgray@0.5',5);
+
+$p = new PolarPlot($data);
+$p->SetFillColor('lightblue@0.5');
+$p->mark->SetType(MARK_SQUARE);
+$p->SetLegend("Mirophone #1\n(No amps)");
+
+$graph->Add($p);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarex7-2.php b/web/classes/jpgraph/Examples/polarex7-2.php
new file mode 100755
index 0000000000000000000000000000000000000000..959749d2a9d10a4c061063b7f73ae2ea4bd082bb
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarex7-2.php
@@ -0,0 +1,53 @@
+<?php // content="text/plain; charset=utf-8"
+// A simple Polar graph,
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+
+$data = array(0,1,30,2,30,25,40,60,
+	      50,110,60,160,70,210,75,230,80,260,85,370,
+	      90,480,
+	      95,370,100,260,105,230,
+	      110,210,120,160,130,110,140,60,
+	      150,25,150,2,180,1);
+
+$n = count($data);
+for($i=0; $i < $n; $i+=2 ) {
+    $data[$n+$i] = 360-$data[$i];
+    $data[$n+$i+1] = $data[$i+1];
+}
+
+
+$graph = new PolarGraph(300,400);
+$graph->SetScale('log',100);
+$graph->SetType(POLAR_360);
+$graph->SetPlotSize(220,300);
+
+// Hide frame around graph (by setting width=0)
+$graph->SetFrame(true,'white',1);
+
+$graph->SetBackgroundGradient('blue:1.3','brown:1.4',GRAD_MIDHOR,BGRAD_PLOT);
+
+// Set color for gradient lines
+$graph->axis->SetGridColor('gray','gray','gray');
+
+$graph->title->Set('Polar plot #7-2');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,16);
+$graph->title->SetColor('navy');
+
+// Adjust legen box position and color
+$graph->legend->SetColor('navy','darkgray');
+$graph->legend->SetFillColor('white');
+$graph->legend->SetShadow('darkgray@0.5',5);
+
+$p = new PolarPlot($data);
+$p->SetFillColor('yellow@0.6');
+$p->mark->SetType(MARK_SQUARE);
+$p->SetLegend("Mirophone #1\n(No amps)");
+
+$graph->Add($p);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarex7.php b/web/classes/jpgraph/Examples/polarex7.php
new file mode 100755
index 0000000000000000000000000000000000000000..d7079a0a1450a9c2bc056968cc05043bbf479aa3
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarex7.php
@@ -0,0 +1,53 @@
+<?php // content="text/plain; charset=utf-8"
+// A simple Polar graph,
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+
+$data = array(0,1,10,2,30,25,40,60,
+	      50,110,60,160,70,210,75,230,80,260,85,370,
+	      90,480,
+	      95,370,100,260,105,230,
+	      110,210,120,160,130,110,140,60,
+	      150,25,170,2,180,1);
+
+$graph = new PolarGraph(300,350);
+$graph->SetScale('lin',300);
+$graph->SetType(POLAR_180);
+$graph->SetPlotSize(220,250);
+
+// Hide frame around graph (by setting width=0)
+$graph->SetFrame(true,'white',1);
+
+$graph->SetBackgroundGradient('blue:1.3','brown:1.4',GRAD_HOR,BGRAD_PLOT);
+
+// Show both major and minor grid lines
+$graph->axis->ShowGrid(true,true);
+
+// Set color for gradient lines
+$graph->axis->SetGridColor('gray','gray','gray');
+
+// Setup axis title
+$graph->axis->SetTitle('Coverage (in meter)','middle');
+$graph->axis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$graph->title->Set('Polar plot #7');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,16);
+$graph->title->SetColor('navy');
+
+// Adjust legen box position and color
+$graph->legend->SetColor('navy','darkgray');
+$graph->legend->SetFillColor('white');
+$graph->legend->SetShadow('darkgray@0.5',5);
+
+$p = new PolarPlot($data);
+$p->SetFillColor('lightblue@0.5');
+$p->mark->SetType(MARK_SQUARE);
+$p->SetLegend("Mirophone #1\n(No amps)");
+
+$graph->Add($p);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarex8.php b/web/classes/jpgraph/Examples/polarex8.php
new file mode 100755
index 0000000000000000000000000000000000000000..8322ebcd88f1fd4dc6ff5fb80db343271396921b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarex8.php
@@ -0,0 +1,54 @@
+<?php // content="text/plain; charset=utf-8"
+// A simple Polar graph,
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+
+$data = array(0,1,10,2,30,25,40,60,
+	      50,110,60,160,70,210,75,230,80,260,85,370,
+	      90,480,
+	      95,370,100,260,105,230,
+	      110,210,120,160,130,110,140,60,
+	      150,25,170,2,180,1);
+
+$graph = new PolarGraph(350,400);
+$graph->SetScale('log',100);
+$graph->SetType(POLAR_180);
+//$graph->SetPlotSize(250,250);
+
+// Hide frame around graph (by setting width=0)
+$graph->SetFrame(true,'white',1);
+
+// Set plotarea color
+$graph->SetColor('lightblue');
+
+// Show both major and minor grid lines
+$graph->axis->ShowGrid(true,true);
+
+// Set color for gradient lines
+$graph->axis->SetGridColor('lightblue:0.8','lightblue:0.8','lightblue:0.8');
+
+// Setup axis title
+$graph->axis->SetTitle('Coverage (in meter)','middle');
+$graph->axis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$graph->title->Set('Polar plot #8');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,16);
+$graph->title->SetColor('navy');
+
+// Adjust legen box position and color
+$graph->legend->SetColor('navy','darkgray');
+$graph->legend->SetFillColor('white');
+$graph->legend->SetShadow('darkgray@0.5',5);
+
+$p = new PolarPlot($data);
+$p->SetFillColor('white@0.5');
+$p->mark->SetType(MARK_SQUARE);
+$p->SetLegend("Mirophone #1\n(No amps)");
+
+$graph->Add($p);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/polarex9.php b/web/classes/jpgraph/Examples/polarex9.php
new file mode 100755
index 0000000000000000000000000000000000000000..ee239ec066161245694994361a2fb2238ba4443a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/polarex9.php
@@ -0,0 +1,63 @@
+<?php // content="text/plain; charset=utf-8"
+// A simple Polar graph,
+
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_polar.php');
+
+$data = array(0,1,10,2,30,25,40,60,
+	      50,110,60,160,70,210,75,230,80,260,85,370,
+	      90,480,
+	      95,370,100,260,105,230,
+	      110,210,120,160,130,110,140,60,
+	      150,25,170,2,180,1);
+
+$graph = new PolarGraph(350,320);
+$graph->SetScale('log',100);
+$graph->SetType(POLAR_180);
+
+// Hide frame around graph (by setting width=0)
+$graph->SetFrame(true,'white',1);
+
+// Show both major and minor grid lines
+$graph->axis->ShowGrid(true,true);
+
+// Set color for gradient lines
+$graph->axis->SetGridColor('lightblue:0.9','lightblue:0.9','lightblue:0.9');
+
+// Set label and axis colors
+$graph->axis->SetColor('black','navy','darkred');
+
+// Draw the ticks on the bottom side of the radius axis
+$graph->axis->SetTickSide(SIDE_DOWN);
+
+// Increase the margin for the labels since we changed the
+// side of the ticks.
+$graph->axis->SetLabelMargin(6);
+
+// Change fonts
+$graph->axis->SetFont(FF_ARIAL,FS_NORMAL,8);
+$graph->axis->SetAngleFont(FF_ARIAL,FS_NORMAL,8);
+
+// Setup axis title
+$graph->axis->SetTitle('Coverage (in meter)','middle');
+$graph->axis->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Setup graph title
+$graph->title->Set('Polar plot #9');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,16);
+$graph->title->SetColor('navy');
+
+// Setup tab title
+$graph->tabtitle->Set('Microphone #1');
+$graph->tabtitle->SetColor('brown:0.5','lightyellow');
+
+
+$p = new PolarPlot($data);
+$p->SetFillColor('lightblue@0.5');
+$p->mark->SetType(MARK_SQUARE);
+
+$graph->Add($p);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/prepaccdata_example.php b/web/classes/jpgraph/Examples/prepaccdata_example.php
new file mode 100755
index 0000000000000000000000000000000000000000..1f1fca313c5bbc8a7932fb7b87c28289e4d1ff22
--- /dev/null
+++ b/web/classes/jpgraph/Examples/prepaccdata_example.php
@@ -0,0 +1,61 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('../jpgraph.php');
+require_once ('../jpgraph_line.php');
+require_once ('../jpgraph_date.php');
+
+//Create some test data
+$xdata = array();
+$ydata = array();
+
+// Timestamps - 2h (=7200s) apart starting 
+$sampling = 7200;
+$n = 50; // data points
+for($i=0; $i < $n; ++$i ) {
+    $xdata[$i] = time() + $i * $sampling;
+    $ydata[0][$i] = rand(12,15);
+    $ydata[1][$i] = rand(100,155);
+    $ydata[2][$i] = rand(20,30);
+}
+
+function formatDate(&$aVal) {
+    $aVal = date('Y-m-d H:i',$aVal);
+}
+
+// Apply this format to all time values in the data to prepare it to be display
+array_walk($xdata,'formatDate');
+
+// Create the graph. 
+$graph  = new Graph(600, 350);
+$graph->title->Set('Accumulated values with specified X-axis scale');
+$graph->SetScale('textlin');
+
+// Setup margin color
+$graph->SetMarginColor('green@0.95');
+
+// Adjust the margin to make room for the X-labels
+$graph->SetMargin(40,30,40,120);
+
+// Turn the tick marks out from the plot area
+$graph->xaxis->SetTickSide(SIDE_BOTTOM);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+
+$p0 =new LinePlot($ydata[0]);
+$p0->SetFillColor('sandybrown');
+$p1 =new LinePlot($ydata[1]);
+$p1->SetFillColor('lightblue');
+$p2 =new LinePlot($ydata[2]);
+$p2->SetFillColor('red');
+$ap = new AccLinePlot(array($p0,$p1,$p2));
+
+$graph->xaxis->SetTickLabels($xdata);
+$graph->xaxis->SetTextLabelInterval(4);
+
+// Add the plot to the graph
+$graph->Add($ap);
+
+// Set the angle for the labels to 90 degrees
+$graph->xaxis->SetLabelAngle(90);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/pushpinex1.php b/web/classes/jpgraph/Examples/pushpinex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..4b100988301d8ae362d440279fcfbcfea85408dd
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pushpinex1.php
@@ -0,0 +1,62 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+DEFINE('WORLDMAP','worldmap1.jpg');
+
+function markCallback($y,$x) {
+    // Return array width
+    // width,color,fill color, marker filename, imgscale
+    // any value can be false, in that case the default value will
+    // be used.
+    // We only make one pushpin another color
+    if( $x == 54 ) 
+	return array(false,false,false,'red',0.8);
+    else
+	return array(false,false,false,'green',0.8);
+}
+
+// Data arrays
+$datax = array(10,20,30,40,54,60,70,80);
+$datay = array(12,23,65,18,84,28,86,44);
+
+// Setup the graph
+$graph = new Graph(400,270);
+
+// We add a small 1pixel left,right,bottom margin so the plot area
+// doesn't cover the frame around the graph.
+$graph->img->SetMargin(1,1,1,1);
+$graph->SetScale('linlin',0,100,0,100);
+
+// We don't want any axis to be shown
+$graph->xaxis->Hide();
+$graph->yaxis->Hide();
+
+// Use a worldmap as the background and let it fill the plot area
+$graph->SetBackgroundImage(WORLDMAP,BGIMG_FILLPLOT);
+
+// Setup a nice title with a striped bevel background
+$graph->title->Set("Pushpin graph");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,16);
+$graph->title->SetColor('white');
+$graph->SetTitleBackground('darkgreen',TITLEBKG_STYLE1,TITLEBKG_FRAME_BEVEL);
+$graph->SetTitleBackgroundFillStyle(TITLEBKG_FILLSTYLE_HSTRIPED,'blue','darkgreen');
+
+// Finally create the scatterplot
+$sp = new ScatterPlot($datay,$datax);
+
+// We want the markers to be an image
+$sp->mark->SetType(MARK_IMG_PUSHPIN,'blue',0.6);
+
+// Install the Y-X callback for the markers
+$sp->mark->SetCallbackYX('markCallback');
+
+// ...  and add it to the graph
+$graph->Add($sp);    
+
+// .. and output to browser
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/pushpinex2.php b/web/classes/jpgraph/Examples/pushpinex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..000d1cc2148a6b06f415f2d95300855425390330
--- /dev/null
+++ b/web/classes/jpgraph/Examples/pushpinex2.php
@@ -0,0 +1,63 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+DEFINE('WORLDMAP','worldmap1.jpg');
+
+function markCallback($y,$x) {
+    // Return array width
+    // width,color,fill color, marker filename, imgscale
+    // any value can be false, in that case the default value will
+    // be used.
+    // We only make one pushpin another color
+    if( $x == 54 ) 
+	return array(false,false,false,'red',0.8);
+    else
+	return array(false,false,false,'green',0.8);
+}
+
+// Data arrays
+$datax = array(10,20,30,40,54,60,70,80);
+$datay = array(12,23,65,18,84,28,86,44);
+
+// Setup the graph
+$graph = new Graph(400,270);
+
+// We add a small 1pixel left,right,bottom margin so the plot area
+// doesn't cover the frame around the graph.
+$graph->img->SetMargin(1,1,1,1);
+$graph->SetScale('linlin',0,100,0,100);
+
+// We don't want any axis to be shown
+$graph->xaxis->Hide();
+$graph->yaxis->Hide();
+
+// Use a worldmap as the background and let it fill the plot area
+$graph->SetBackgroundImage(WORLDMAP,BGIMG_FILLPLOT);
+
+// Setup a nice title with a striped bevel background
+$graph->title->Set("Pushpin graph");
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,16);
+$graph->title->SetColor('white');
+$graph->SetTitleBackground('darkgreen',TITLEBKG_STYLE1,TITLEBKG_FRAME_BEVEL);
+$graph->SetTitleBackgroundFillStyle(TITLEBKG_FILLSTYLE_HSTRIPED,'blue','darkgreen');
+
+// Finally create the lineplot
+$lp = new LinePlot($datay,$datax);
+$lp->SetColor('lightgray');
+
+// We want the markers to be an image
+$lp->mark->SetType(MARK_IMG_PUSHPIN,'blue',0.6);
+
+// Install the Y-X callback for the markers
+$lp->mark->SetCallbackYX('markCallback');
+
+// ...  and add it to the graph
+$graph->Add($lp);    
+
+// .. and output to browser
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/qr-input.txt b/web/classes/jpgraph/Examples/qr-input.txt
new file mode 100755
index 0000000000000000000000000000000000000000..1b3c2bcdf02dfe11a84b2e52aff6dffd7e07ccac
--- /dev/null
+++ b/web/classes/jpgraph/Examples/qr-input.txt
@@ -0,0 +1 @@
+01234567890
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/qr_template.php b/web/classes/jpgraph/Examples/qr_template.php
new file mode 100755
index 0000000000000000000000000000000000000000..e54ea7825f5e4690b5455968bb8a041c9bf5cc2c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/qr_template.php
@@ -0,0 +1,32 @@
+<?php
+require_once ('jpgraph/QR/qrencoder.inc.php');
+
+// Data to be encoded
+$data         = 'ABCDEFGH01234567';
+
+// QR Code specification
+$version      = -1;  				// -1 = Let the library decide version (same as default)
+$corrlevel    = QRCapacity::ErrM;   // Medium erro correction
+$modulewidth  = 2;					// Module width
+$back         = BACKEND_IMAGE;		// Default backend
+$quiet		  = 4; 					// Same as default value
+
+// Create encoder and backend
+$encoder = new QREncoder($version, $corrlevel);
+$backend = QRCodeBackendFactory::Create($encoder, $back);
+
+// Set the module size
+$backend->SetModuleWidth($modulewidth);
+
+// Set Quiet zone (this should rarely need changing from the default)
+$backend->SetQuietZone($quiet);
+
+if( $back == BACKEND_IMAGE ) {
+
+	$backend->Stroke($data);
+}
+else {
+	$str = $backend->Stroke($data);
+	echo '<pre>'.$str.'</pre>';
+}
+?>
diff --git a/web/classes/jpgraph/Examples/qrexample0.php b/web/classes/jpgraph/Examples/qrexample0.php
new file mode 100755
index 0000000000000000000000000000000000000000..46126fe7ae0ef778df5bf1ca82b985df33d986eb
--- /dev/null
+++ b/web/classes/jpgraph/Examples/qrexample0.php
@@ -0,0 +1,23 @@
+<?php
+require_once ('jpgraph/QR/qrencoder.inc.php');
+
+// Data to be encoded
+$data = '01234567';
+
+// Create a new instance of the encoder and let the library
+// decide a suitable QR version and error level
+$encoder = new QREncoder(1);
+
+// Use the image backend (this is also the default)
+$backend = QRCodeBackendFactory::Create($encoder);
+
+try {
+	// 	. send the QR Code back to the browser
+    $backend->Stroke($data);
+} catch (Exception $e) {
+    $errstr = $e->GetMessage();
+    echo 'QR Code error: '.$e->GetMessage()."\n";
+    exit(1);
+}
+
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/qrexample00.php b/web/classes/jpgraph/Examples/qrexample00.php
new file mode 100755
index 0000000000000000000000000000000000000000..f09fcd5d1a85958a7a9ee6d225c737a9dda31369
--- /dev/null
+++ b/web/classes/jpgraph/Examples/qrexample00.php
@@ -0,0 +1,16 @@
+<?php
+require_once ('jpgraph/QR/qrencoder.inc.php');
+
+// Data to be encoded
+$data = '01234567';
+
+// Create a new instance of the encoder and let the library
+// decide a suitable QR version and error level
+$e=new QREncoder();
+
+// Use the image backend (this is also the default)
+$b=QRCodeBackendFactory::Create($e);
+
+// .. send the barcode back to the browser for the data
+$b->Stroke($data);
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/Examples/qrexample01.php b/web/classes/jpgraph/Examples/qrexample01.php
new file mode 100755
index 0000000000000000000000000000000000000000..af99deaf11ede24bb7274d10d88050dcacb4a870
--- /dev/null
+++ b/web/classes/jpgraph/Examples/qrexample01.php
@@ -0,0 +1,19 @@
+<?php
+require_once ('jpgraph/QR/qrencoder.inc.php');
+
+// Data to be encoded
+$data = '01234567';
+
+// Create a new instance of the encoder and let the library
+// decide a suitable QR version and error level
+$encoder = new QREncoder();
+
+// Use the image backend
+$backend = QRCodeBackendFactory::Create($encoder, BACKEND_IMAGE);
+
+// Set the module size (quite big)
+$backend->SetModuleWidth(5);
+
+// .. send the barcode back to the browser for the data
+$backend->Stroke($data);
+?>
diff --git a/web/classes/jpgraph/Examples/qrexample02.php b/web/classes/jpgraph/Examples/qrexample02.php
new file mode 100755
index 0000000000000000000000000000000000000000..890d616c1c5d71b3ace69827df338321f1139664
--- /dev/null
+++ b/web/classes/jpgraph/Examples/qrexample02.php
@@ -0,0 +1,23 @@
+<?php
+    // Example 2 : QR Barcode with specified version
+
+    // Include the library
+    require_once ('jpgraph/QR/qrencoder.inc.php');
+
+    // Data to be encoded
+    $data = '01234567';
+    $version = 4;  // Use QR version 4
+
+    // Create a new instance of the encoder and let the library
+    // decide a suitable error level
+    $encoder = new QREncoder($version);
+
+    // Use the image backend
+    $backend = QRCodeBackendFactory::Create($encoder, BACKEND_IMAGE);
+
+    // Set the module size (quite big)
+    $backend->SetModuleWidth(5);
+
+    // .. send the barcode back to the browser for the data
+    $backend->Stroke($data);
+?>
diff --git a/web/classes/jpgraph/Examples/qrexample03.php b/web/classes/jpgraph/Examples/qrexample03.php
new file mode 100755
index 0000000000000000000000000000000000000000..858eede350168fbafe6e4de2c5ac3e1fd01e5ea0
--- /dev/null
+++ b/web/classes/jpgraph/Examples/qrexample03.php
@@ -0,0 +1,27 @@
+<?php
+    // Example 3 : QR Barcode with specified version and stored to a file
+
+    // Include the library
+    require_once ('jpgraph/QR/qrencoder.inc.php');
+
+    // Data to be encoded
+    $data = '01234567';
+    $version = 3;  // Use QR version 3
+    $fileName = 'qrexample03.png';
+
+    // Create a new instance of the encoder and let the library
+    // decide a suitable error level
+    $encoder = new QREncoder($version);
+
+    // Use the image backend
+    $backend = QRCodeBackendFactory::Create($encoder, BACKEND_IMAGE);
+
+    // Set the module size (quite big)
+    $backend->SetModuleWidth(5);
+
+    // Store the barcode in the specifed file
+    $backend->Stroke($data,$fileName);
+    list($version,$errorcorrection) = $backend->GetQRInfo();
+
+    echo "QR Barcode, (<b>Version: $version-$errorcorrection</b>), image stored in file $fileName";
+?>
diff --git a/web/classes/jpgraph/Examples/qrexample03.png b/web/classes/jpgraph/Examples/qrexample03.png
new file mode 100755
index 0000000000000000000000000000000000000000..091a1cc2e65f9ca3f2a640db9570919a73401dd5
Binary files /dev/null and b/web/classes/jpgraph/Examples/qrexample03.png differ
diff --git a/web/classes/jpgraph/Examples/qrexample04.php b/web/classes/jpgraph/Examples/qrexample04.php
new file mode 100755
index 0000000000000000000000000000000000000000..c86447ae761f8332fe18f345b3634ba6694c8ade
--- /dev/null
+++ b/web/classes/jpgraph/Examples/qrexample04.php
@@ -0,0 +1,24 @@
+<?php
+    // Example 4 : QR Barcode with specified version and error correction level
+
+    // Include the library
+    require_once ('jpgraph/QR/qrencoder.inc.php');
+
+    // Data to be encoded
+    $data = '01234567';
+    $version = 12;  // Use QR version 4
+    $corrlevel = QRCapacity::ErrH ; // Level H error correction (the highest possible)
+
+    // Create a new instance of the encoder using the specified
+    // QR version and error correction
+    $encoder = new QREncoder($version,$corrlevel);
+
+    // Use the image backend
+    $backend = QRCodeBackendFactory::Create($encoder, BACKEND_IMAGE);
+
+    // Set the module size
+    $backend->SetModuleWidth(3);
+
+    // Store the barcode in the specifed file
+    $backend->Stroke($data);
+?>
diff --git a/web/classes/jpgraph/Examples/qrexample05.php b/web/classes/jpgraph/Examples/qrexample05.php
new file mode 100755
index 0000000000000000000000000000000000000000..96f5f47a2f719b8c2563994c7a35dd4e660b2a55
--- /dev/null
+++ b/web/classes/jpgraph/Examples/qrexample05.php
@@ -0,0 +1,29 @@
+<?php
+    // Example 5 : QR Barcode with manually specified encodation
+
+    // Include the library
+    require_once ('jpgraph/QR/qrencoder.inc.php');
+
+    // Data to be encoded
+    // We want the data to be encoded using alphanumeric encoding even though
+    // it is only numbers
+    $data = array(
+        array(QREncoder::MODE_ALPHANUM,'01234567')
+    );
+
+    $version = 3;  // Use QR version 3
+    $corrlevel = QRCapacity::ErrH ; // Level H error correction (the highest possible)
+
+    // Create a new instance of the encoder using the specified
+    // QR version and error correction
+    $encoder = new QREncoder($version,$corrlevel);
+
+    // Use the image backend
+    $backend = QRCodeBackendFactory::Create($encoder, BACKEND_IMAGE);
+
+    // Set the module size
+    $backend->SetModuleWidth(4);
+
+    // Store the barcode in the specifed file
+    $backend->Stroke($data);
+?>
diff --git a/web/classes/jpgraph/Examples/qrexample06.php b/web/classes/jpgraph/Examples/qrexample06.php
new file mode 100755
index 0000000000000000000000000000000000000000..046627f23044eb2d2ab28f4b8d041046a86d36b2
--- /dev/null
+++ b/web/classes/jpgraph/Examples/qrexample06.php
@@ -0,0 +1,26 @@
+<?php
+    // Example 6 : QR Barcode with image in JPG format
+
+    // Include the library
+    require_once ('jpgraph/QR/qrencoder.inc.php');
+
+    $data      = 'ABCDEFGH01234567'; // Data to be encoded
+    $version   = -1;  // -1 = Let the library decide version (same as default)
+    $corrlevel = -1; // -1 = Let the library decide error correction level (same as default)
+
+    // Create a new instance of the encoder using the specified
+    // QR version and error correction
+    $encoder = new QREncoder($version,$corrlevel);
+
+    // Use the image backend
+    $backend=QRCodeBackendFactory::Create($encoder, BACKEND_IMAGE);
+
+    // Use JPEG format with 80% quality level
+    $backend->SetImgFormat('jpeg',80);
+
+    // Set the module size
+    $backend->SetModuleWidth(4);
+
+    // Store the barcode in the specifed file
+    $backend->Stroke($data);
+?>
diff --git a/web/classes/jpgraph/Examples/qrexample07.php b/web/classes/jpgraph/Examples/qrexample07.php
new file mode 100755
index 0000000000000000000000000000000000000000..68dde156ab5327e44561d494651666d2068b6243
--- /dev/null
+++ b/web/classes/jpgraph/Examples/qrexample07.php
@@ -0,0 +1,26 @@
+<?php
+    // Example 7 : QR Barcode with multiple manually specified encodation schemas
+    // (Note: Normally there would be no need to ever use manually specified encodation)
+
+    // Include the library
+    require_once ('jpgraph/QR/qrencoder.inc.php');
+
+    // Data to be encoded
+    $data = array(
+        array(QREncoder::MODE_ALPHANUM,'01234567'),
+        array(QREncoder::MODE_NUMERIC,'89012345')
+    );
+
+    // Create a new instance of the encoder (automatically determined QR version and
+    // error correction level)
+    $encoder = new QREncoder();
+
+    // Use the image backend
+    $backend = QRCodeBackendFactory::Create($encoder, BACKEND_IMAGE);
+
+    // Set the module size
+    $backend->SetModuleWidth(4);
+
+    // Store the barcode in the specifed file
+    $backend->Stroke($data);
+?>
diff --git a/web/classes/jpgraph/Examples/qrexample08.php b/web/classes/jpgraph/Examples/qrexample08.php
new file mode 100755
index 0000000000000000000000000000000000000000..08eb947b0882d199d17b0fb3a0fbef7a13222348
--- /dev/null
+++ b/web/classes/jpgraph/Examples/qrexample08.php
@@ -0,0 +1,22 @@
+<?php
+    // Example 8 : QR Barcode with data read from file
+
+    // Include the library
+    require_once ('jpgraph/jpgraph.php');
+    require_once ('jpgraph/QR/qrencoder.inc.php');
+
+    $readFromFilename = 'qr-input.txt';
+
+    // Create a new instance of the encoder and let the library
+    // decide a suitable QR version and error level
+    $encoder=new QREncoder();
+
+    // Use the image backend
+    $backend=QRCodeBackendFactory::Create($encoder, BACKEND_IMAGE);
+
+    // Set the module size (quite big)
+    $backend->SetModuleWidth(5);
+
+    // .. send the barcode back to the browser for the data in the file
+    $backend->StrokeFromFile($readFromFilename);
+?>
diff --git a/web/classes/jpgraph/Examples/qrexample09.php b/web/classes/jpgraph/Examples/qrexample09.php
new file mode 100755
index 0000000000000000000000000000000000000000..faa2a5de5178664fcf40fc61ef48dbced03f22e8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/qrexample09.php
@@ -0,0 +1,25 @@
+<?php
+    // Example 9 : QR Barcode with data read from file and different colors
+
+    // Include the library
+    require_once ('jpgraph/jpgraph.php');
+    require_once ('jpgraph/QR/qrencoder.inc.php');
+
+    $readFromFilename = 'qr-input.txt';
+
+    // Create a new instance of the encoder and let the library
+    // decide a suitable QR version and error level
+    $encoder = new QREncoder();
+
+    // Use the image backend
+    $backend = QRCodeBackendFactory::Create($encoder, BACKEND_IMAGE);
+
+    // Set the module size (quite big)
+    $backend->SetModuleWidth(5);
+
+    // Use blue and white colors instead
+    $backend->SetColor('navy','white');
+
+    // .. send the barcode back to the browser for the data in the file
+    $backend->StrokeFromFile($readFromFilename);
+?>
diff --git a/web/classes/jpgraph/Examples/qrexample10.php b/web/classes/jpgraph/Examples/qrexample10.php
new file mode 100755
index 0000000000000000000000000000000000000000..1232754a229c73008fcff04717850994e98febfd
--- /dev/null
+++ b/web/classes/jpgraph/Examples/qrexample10.php
@@ -0,0 +1,26 @@
+<?php
+    // Example 10 : Specified error correction level
+
+    // Include the library
+    require_once ('jpgraph/QR/qrencoder.inc.php');
+
+    $data      = 'ABCDEFGH01234567'; // Data to be encoded
+    $version   = -1;  // -1 = Let the library decide version (same as default)
+    $corrlevel = QRCapacity::ErrH; // Error correction level H (Highest possible)
+
+    // Create a new instance of the encoder using the specified
+    // QR version and error correction
+    $encoder = new QREncoder($version,$corrlevel);
+
+    // Use the image backend
+    $backend = QRCodeBackendFactory::Create($encoder, BACKEND_IMAGE);
+
+    // Set the module size
+    $backend->SetModuleWidth(3);
+
+    // Set color
+    $backend->SetColor('brown','white');
+
+    // Store the barcode in the specifed file
+    $backend->Stroke($data);
+?>
diff --git a/web/classes/jpgraph/Examples/qrexample11.php b/web/classes/jpgraph/Examples/qrexample11.php
new file mode 100755
index 0000000000000000000000000000000000000000..2f3e503e2eb30f4c4f09b1b09d270e2dac4f98f8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/qrexample11.php
@@ -0,0 +1,26 @@
+<?php
+// Include the library
+require_once ('jpgraph/QR/qrencoder.inc.php');
+
+// Example 11 : Generate postscript output
+
+$data         = 'ABCDEFGH01234567'; // Data to be encoded
+$version      = -1;  // -1 = Let the library decide version (same as default)
+$corrlevel    = QRCapacity::ErrH; // Error correction level H (Highest possible)
+$modulewidth  = 3;
+
+// Create a new instance of the encoder using the specified
+// QR version and error correction
+$encoder = new QREncoder($version,$corrlevel);
+
+// Use the image backend
+$backend = QRCodeBackendFactory::Create($encoder, BACKEND_PS);
+
+// Set the module size
+$backend->SetModuleWidth($modulewidth);
+
+// Store the barcode in the specifed file
+$ps_str = $backend->Stroke($data);
+
+echo '<pre>'.$ps_str.'</pre>';
+?>
diff --git a/web/classes/jpgraph/Examples/qrexample12.php b/web/classes/jpgraph/Examples/qrexample12.php
new file mode 100755
index 0000000000000000000000000000000000000000..d1e090465dae05b0fc4cc5b041259b62f43aa856
--- /dev/null
+++ b/web/classes/jpgraph/Examples/qrexample12.php
@@ -0,0 +1,26 @@
+<?php
+// Include the library
+require_once ('jpgraph/QR/qrencoder.inc.php');
+
+// Example 11 : Generate postscript output
+
+$data         = 'ABCDEFGH01234567'; // Data to be encoded
+$version      = -1;  // -1 = Let the library decide version (same as default)
+$corrlevel    = QRCapacity::ErrH; // Error correction level H (Highest possible)
+$modulewidth  = 1;
+
+// Create a new instance of the encoder using the specified
+// QR version and error correction
+$encoder = new QREncoder($version,$corrlevel);
+
+// Use the image backend
+$backend = QRCodeBackendFactory::Create($encoder, BACKEND_ASCII);
+
+// Set the module size
+$backend->SetModuleWidth($modulewidth);
+
+// Store the barcode in the specifed file
+$ps_str = $backend->Stroke($data);
+
+echo '<pre>'.$ps_str.'</pre>';
+?>
diff --git a/web/classes/jpgraph/Examples/radar_csimex1.php b/web/classes/jpgraph/Examples/radar_csimex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..1f0454d8f793f00ce0fa6c9d600294a6b7dd0730
--- /dev/null
+++ b/web/classes/jpgraph/Examples/radar_csimex1.php
@@ -0,0 +1,43 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_radar.php');
+
+$titles=array('Planning','Quality','Time','RR','CR','DR');
+$data=array(18, 40, 70, 90, 42, 66);
+
+$n = count($data);
+for( $i=0; $i < $n; ++$i ) {
+	$targets[$i] = "#$i";
+	$alts[$i] = "Data point #$i";
+}
+
+$graph = new RadarGraph (300,280);
+
+$graph->title->Set('Radar with marks');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+$graph->title->SetMargin(10);
+
+$graph->SetTitles($titles);
+$graph->SetCenter(0.5,0.55);
+$graph->HideTickMarks();
+$graph->SetColor('lightgreen@0.7');
+$graph->axis->SetColor('darkgray');
+$graph->grid->SetColor('darkgray');
+$graph->grid->Show();
+
+$graph->axis->title->SetFont(FF_ARIAL,FS_NORMAL,12);
+$graph->axis->title->SetMargin(5);
+$graph->SetGridDepth(DEPTH_BACK);
+$graph->SetSize(0.6);
+
+$plot = new RadarPlot($data);
+$plot->SetColor('red@0.2');
+$plot->SetLineWeight(2);
+$plot->SetFillColor('red@0.7');
+$plot->mark->SetType(MARK_IMG_DIAMOND,'red',0.6);
+$plot->mark->SetFillColor('darkred');
+$plot->SetCSIMTargets( $targets , $alts );
+
+$graph->Add($plot);
+$graph->StrokeCSIM();
+?>
diff --git a/web/classes/jpgraph/Examples/radarex1.php b/web/classes/jpgraph/Examples/radarex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..a21037574b53da5b8969bfa943e968887e3a1cc2
--- /dev/null
+++ b/web/classes/jpgraph/Examples/radarex1.php
@@ -0,0 +1,16 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_radar.php');
+require_once ('jpgraph/jpgraph_iconplot.php');
+
+// Some data to plot
+$data = array(55,80,46,71,95);
+
+// Create the graph and the plot
+$graph = new RadarGraph(250,200);
+$plot = new RadarPlot($data);
+
+// Add the plot and display the graph
+$graph->Add($plot);
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/radarex2.php b/web/classes/jpgraph/Examples/radarex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..a1400a3f2e3e5f035c67626b52eca538373074c7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/radarex2.php
@@ -0,0 +1,21 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_radar.php');
+	
+// Some data to plot
+$data = array(55,80,46,71,95);
+	
+// Create the graph and the plot
+$graph = new RadarGraph(300,200);
+
+$graph->title->Set('Weekly goals');
+$graph->subtitle->Set('Year 2003');
+
+$plot = new RadarPlot($data);
+$plot->SetFillColor('lightred');
+$graph->SetSize(0.6);
+$graph->SetPos(0.5,0.6);
+// Add the plot and display the graph
+$graph->Add($plot);
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/radarex3.php b/web/classes/jpgraph/Examples/radarex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..18fdd90216b89d43e89464fd367f55765e20f93a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/radarex3.php
@@ -0,0 +1,21 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_radar.php');
+	
+// Some data to plot
+$data = array(55,80,46,71,95);
+	
+// Create the graph and the plot
+$graph = new RadarGraph(250,200);
+
+// Create the titles for the axis
+$titles = $gDateLocale->GetShortMonth();
+$graph->SetTitles($titles);
+
+$plot = new RadarPlot($data);
+$plot->SetFillColor('lightblue');
+
+// Add the plot and display the graph
+$graph->Add($plot);
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/radarex4.php b/web/classes/jpgraph/Examples/radarex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..f64f6148208f700a64ecb63a02488398f1bbf3b9
--- /dev/null
+++ b/web/classes/jpgraph/Examples/radarex4.php
@@ -0,0 +1,28 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_radar.php');
+
+// Some data to plot
+$data = array(55,80,26,31,95);
+
+// Create the graph and the plot
+$graph = new RadarGraph(250,200);
+
+// Add a drop shadow to the graph
+$graph->SetShadow();
+
+// Create the titles for the axis
+$titles = $gDateLocale->GetShortMonth();
+$graph->SetTitles($titles);
+
+// Add grid lines
+$graph->grid->Show();
+$graph->grid->SetLineStyle('dashed');
+
+$plot = new RadarPlot($data);
+$plot->SetFillColor('lightblue');
+
+// Add the plot and display the graph
+$graph->Add($plot);
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/radarex5.php b/web/classes/jpgraph/Examples/radarex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..6ee42aef0a108a1b41bc7d92112f5799ec88282f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/radarex5.php
@@ -0,0 +1,26 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_radar.php');
+	
+// Some data to plot
+$data = array(55,80,26,31,95);
+	
+// Create the graph and the plot
+$graph = new RadarGraph(250,200);
+
+// Create the titles for the axis
+$titles = $gDateLocale->GetShortMonth();
+$graph->SetTitles($titles);
+
+// Add grid lines
+$graph->grid->Show();
+$graph->grid->SetColor('darkred');
+$graph->grid->SetLineStyle('dotted');
+
+$plot = new RadarPlot($data);
+$plot->SetFillColor('lightblue');
+
+// Add the plot and display the graph
+$graph->Add($plot);
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/radarex6.1.php b/web/classes/jpgraph/Examples/radarex6.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..e6f9a50eae74a058d47bcd9e60027ee6ae58099d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/radarex6.1.php
@@ -0,0 +1,45 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_radar.php');
+	
+// Some data to plot
+$data = array(55,80,26,31,95);
+$data2 = array(15,50,46,39,25);
+	
+// Create the graph and the plot
+$graph = new RadarGraph(250,200);
+
+// Add a drop shadow to the graph
+$graph->SetShadow();
+
+// Create the titles for the axis
+$titles = $gDateLocale->GetShortMonth();
+$graph->SetTitles($titles);
+$graph->SetColor('lightyellow');
+
+// ADjust the position to make more room
+// for the legend
+$graph->SetCenter(0.4,0.55);
+$graph->SetSize(0.6);
+
+// Add grid lines
+$graph->grid->Show();
+$graph->grid->SetColor('darkred');
+$graph->grid->SetLineStyle('dotted');
+
+$plot = new RadarPlot($data);
+$plot->SetFillColor('lightblue');
+$plot->SetLegend("QA results");
+
+$plot2 = new RadarPlot($data2);
+$plot2->SetLegend("Target");
+$plot2->SetColor('red');
+$plot2->SetFill(false);
+$plot2->SetLineWeight(2);
+
+
+// Add the plot and display the graph
+$graph->Add($plot);
+$graph->Add($plot2);
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/radarex6.php b/web/classes/jpgraph/Examples/radarex6.php
new file mode 100755
index 0000000000000000000000000000000000000000..d702f2941b1569278bcb8f6233560a371ecce57e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/radarex6.php
@@ -0,0 +1,35 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_radar.php');
+
+// Some data to plot
+$data = array(55,80,26,31,95);
+
+// Create the graph and the plot
+$graph = new RadarGraph(250,200);
+
+// Add a drop shadow to the graph
+$graph->SetShadow();
+
+// Create the titles for the axis
+$titles = $gDateLocale->GetShortMonth();
+$graph->SetTitles($titles);
+$graph->SetColor('lightyellow');
+
+// ADjust the position to make more room
+// for the legend
+$graph->SetCenter(0.45,0.5);
+
+// Add grid lines
+$graph->grid->Show();
+$graph->grid->SetColor('darkred');
+$graph->grid->SetLineStyle('dashed');
+
+$plot = new RadarPlot($data);
+$plot->SetFillColor('lightblue');
+$plot->SetLegend("QA results");
+
+// Add the plot and display the graph
+$graph->Add($plot);
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/radarex7.php b/web/classes/jpgraph/Examples/radarex7.php
new file mode 100755
index 0000000000000000000000000000000000000000..cb44c208999a884b70135592c495f5a35663a90d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/radarex7.php
@@ -0,0 +1,48 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_radar.php');
+
+// Create the basic rtadar graph
+$graph = new RadarGraph(300,200);
+
+// Set background color and shadow
+$graph->SetColor("white");
+$graph->SetShadow();
+
+// Position the graph
+$graph->SetCenter(0.4,0.55);
+
+// Setup the axis formatting 	
+$graph->axis->SetFont(FF_FONT1,FS_BOLD);
+$graph->axis->SetWeight(2);
+
+// Setup the grid lines
+$graph->grid->SetLineStyle("longdashed");
+$graph->grid->SetColor("navy");
+$graph->grid->Show();
+$graph->HideTickMarks();
+		
+// Setup graph titles
+$graph->title->Set("Quality result");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->SetTitles(array("One","Two","Three","Four","Five","Sex","Seven","Eight","Nine","Ten"));
+// Create the first radar plot		
+$plot = new RadarPlot(array(30,80,60,40,71,81,47));
+$plot->SetLegend("Goal");
+$plot->SetColor("red","lightred");
+$plot->SetFill(false);
+$plot->SetLineWeight(2);
+
+// Create the second radar plot
+$plot2 = new RadarPlot(array(70,40,30,80,31,51,14));
+$plot2->SetLegend("Actual");
+$plot2->SetColor("blue","lightred");
+
+// Add the plots to the graph
+$graph->Add($plot2);
+$graph->Add($plot);
+
+// And output the graph
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/radarex8.1.php b/web/classes/jpgraph/Examples/radarex8.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..e1f1336bc53020ac0b89a8b6fdf68a2868235d1f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/radarex8.1.php
@@ -0,0 +1,52 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_radar.php');
+
+// Create the basic radar graph
+$graph = new RadarGraph(300,200);
+$graph->img->SetAntiAliasing();
+
+// Set background color and shadow
+$graph->SetColor("white");
+$graph->SetShadow();
+
+// Position the graph
+$graph->SetCenter(0.4,0.55);
+
+// Setup the axis formatting 	
+$graph->axis->SetFont(FF_FONT1,FS_BOLD);
+
+// Setup the grid lines
+$graph->grid->SetLineStyle("solid");
+$graph->grid->SetColor("navy");
+$graph->grid->Show();
+$graph->HideTickMarks();
+		
+// Setup graph titles
+$graph->title->Set("Quality result");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$graph->SetTitles($gDateLocale->GetShortMonth());
+
+// Create the first radar plot		
+$plot = new RadarPlot(array(70,80,60,90,71,81,47));
+$plot->SetLegend("Goal");
+$plot->SetColor("red","lightred");
+$plot->SetFill(false);
+$plot->SetLineWeight(2);
+
+// Create the second radar plot
+$plot2 = new RadarPlot(array(70,40,30,80,31,51,14));
+$plot2->SetLegend("Actual");
+$plot2->SetLineWeight(2);
+$plot2->SetColor("blue");
+$plot2->SetFill(false);
+
+// Add the plots to the graph
+$graph->Add($plot2);
+$graph->Add($plot);
+
+// And output the graph
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/radarex8.php b/web/classes/jpgraph/Examples/radarex8.php
new file mode 100755
index 0000000000000000000000000000000000000000..0d6b0f872ea6b9748026515b736d35cc16202c4d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/radarex8.php
@@ -0,0 +1,51 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_radar.php');
+
+// Create the basic radar graph
+$graph = new RadarGraph(300,200);
+//$graph->img->SetAntiAliasing();
+
+// Set background color and shadow
+$graph->SetColor("white");
+$graph->SetShadow();
+
+// Position the graph
+$graph->SetCenter(0.4,0.55);
+
+// Setup the axis formatting 	
+$graph->axis->SetFont(FF_FONT1,FS_BOLD);
+
+// Setup the grid lines
+$graph->grid->SetLineStyle("solid");
+$graph->grid->SetColor("navy");
+$graph->grid->Show();
+$graph->HideTickMarks();
+		
+// Setup graph titles
+$graph->title->Set("Quality result");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->SetTitles($gDateLocale->GetShortMonth());
+
+// Create the first radar plot		
+$plot = new RadarPlot(array(70,80,60,90,71,81,47));
+$plot->SetLegend("Goal");
+$plot->SetColor("red","lightred");
+$plot->SetFill(false);
+$plot->SetLineWeight(2);
+
+// Create the second radar plot
+$plot2 = new RadarPlot(array(70,40,30,80,31,51,14));
+$plot2->SetLegend("Actual");
+$plot2->SetLineWeight(2);
+$plot2->SetColor("blue");
+$plot2->SetFill(false);
+
+// Add the plots to the graph
+$graph->Add($plot2);
+$graph->Add($plot);
+
+// And output the graph
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/radarex9.php b/web/classes/jpgraph/Examples/radarex9.php
new file mode 100755
index 0000000000000000000000000000000000000000..465ca262d718c85e5f0dd8b5cda3aac1499b55ad
--- /dev/null
+++ b/web/classes/jpgraph/Examples/radarex9.php
@@ -0,0 +1,33 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php'); 
+require_once ('jpgraph/jpgraph_radar.php');
+
+$titles=array("N", '', "NW", '', "W", '', "SW", '', 'S', '', "SE", '', "E", '', "NE", '');
+$data=array(0, 0, 8, 10, 70, 90, 42, 0, 70, 60, 50, 40, 30, 40, 37.8, 72);
+
+$graph = new RadarGraph (250,270); 
+
+$graph->title->Set("Accumulated PPM");
+$graph->title->SetFont(FF_VERDANA,FS_NORMAL,12);
+
+$graph->subtitle->Set("(according to direction)");
+$graph->subtitle->SetFont(FF_VERDANA,FS_ITALIC,10);
+
+
+$graph->SetTitles($titles);
+$graph->SetCenter(0.5,0.55);
+$graph->HideTickMarks(); 
+$graph->SetColor('lightyellow');
+$graph->axis->SetColor('darkgray@0.3'); 
+$graph->grid->SetColor('darkgray@0.3');
+$graph->grid->Show();
+
+$graph->SetGridDepth(DEPTH_BACK);
+
+$plot = new RadarPlot($data);
+$plot->SetColor('red@0.2');
+$plot->SetLineWeight(1);
+$plot->SetFillColor('red@0.7');
+$graph->Add($plot);
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/radarlogex1-aa.php b/web/classes/jpgraph/Examples/radarlogex1-aa.php
new file mode 100755
index 0000000000000000000000000000000000000000..8417fb764fa7c00d2e0807faf2b4bf0ce8447e3a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/radarlogex1-aa.php
@@ -0,0 +1,60 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_log.php');
+require_once ('jpgraph/jpgraph_radar.php');
+
+// Some data to plot
+$data = array(242,58,1500,12,1397,810,373);
+$data2 = array(447,176,1472,191,1616,42,46);
+
+// Create the graph
+$graph = new RadarGraph(300,350);
+
+// Use logarithmic scale (If you don't use any SetScale()
+// the radar graph will default to linear scale
+$graph->SetScale('log');
+
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,16);
+$graph->title->Set('Logarithmic scale');
+$graph->title->SetMargin(10);
+
+// Make the radar graph fill out it's bounding box
+$graph->SetPlotSize(0.8);
+$graph->SetCenter(0.5,0.55);
+
+// Note: Enabling this results in a very noticable slow
+// down of the image generation! And more load on your
+// server.
+$graph->img->SetAntiAliasing();
+
+// Uncomment the following line if you want to supress
+// minor tick marks
+//$graph->yscale->ticks->SupressMinorTickMarks();
+
+// We want the major tick marks to be black and minor
+// slightly less noticable
+$graph->yscale->ticks->SetMarkColor('black','darkgray');
+
+// Set the axis title font
+$graph->axis->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph->axis->title->SetColor('darkred:0.8');
+
+// Use blue axis
+$graph->axis->SetColor('blue');
+
+$plot = new RadarPlot($data);
+$plot->SetLineWeight(1);
+$plot->SetColor('forestgreen');
+$plot->SetFillColor('forestgreen@0.9');
+
+$plot2 = new RadarPlot($data2);
+$plot2->SetLineWeight(2);
+$plot2->SetColor('red');
+$plot2->SetFillColor('red@0.9');
+
+// Add the plot and display the graph
+$graph->Add($plot);
+$graph->Add($plot2);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/radarlogex1.php b/web/classes/jpgraph/Examples/radarlogex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..2d08310ed0f4bb6be5d98397043a0b4012032405
--- /dev/null
+++ b/web/classes/jpgraph/Examples/radarlogex1.php
@@ -0,0 +1,55 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_log.php');
+require_once ('jpgraph/jpgraph_radar.php');
+
+// Some data to plot
+$data = array(242,58,1500,12,1397,810,373);
+$data2 = array(447,176,1472,191,1616,42,46);
+
+// Create the graph
+$graph = new RadarGraph(300,350);
+
+// Use logarithmic scale (If you don't use any SetScale()
+// the radar graph will default to linear scale
+$graph->SetScale('log');
+
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,16);
+$graph->title->Set('Logarithmic scale');
+$graph->title->SetMargin(10);
+
+// Make the radar graph fill out it's bounding box
+$graph->SetPlotSize(0.8);
+$graph->SetCenter(0.5,0.55);
+
+// Uncomment the following line if you want to supress
+// minor tick marks
+//$graph->yscale->ticks->SupressMinorTickMarks();
+
+// We want the major tick marks to be black and minor
+// slightly less noticable
+$graph->yscale->ticks->SetMarkColor('black','darkgray');
+
+// Set the axis title font
+$graph->axis->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph->axis->title->SetColor('darkred:0.8');
+
+// Use blue axis
+$graph->axis->SetColor('blue');
+
+$plot = new RadarPlot($data);
+$plot->SetLineWeight(1);
+$plot->SetColor('forestgreen');
+$plot->SetFillColor('forestgreen@0.9');
+
+$plot2 = new RadarPlot($data2);
+$plot2->SetLineWeight(2);
+$plot2->SetColor('red');
+$plot2->SetFillColor('red@0.9');
+
+// Add the plot and display the graph
+$graph->Add($plot);
+$graph->Add($plot2);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/radarlogex2.php b/web/classes/jpgraph/Examples/radarlogex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..f347141c84928f239f171c55470acec913149ee8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/radarlogex2.php
@@ -0,0 +1,47 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_log.php');
+require_once ('jpgraph/jpgraph_radar.php');
+
+// Some data to plot
+$data = array(242,58,500,12,397,810,373);
+
+// Create the graph
+$graph = new RadarGraph(200,200);
+
+// Uncomment the following line to use anti-aliasing 
+// Note: Enabling this results in a very noticable slow
+// down of the image generation! And more load on your
+// server. Use it wisly!!
+$graph->img->SetAntiAliasing();
+
+// Make the spider graph fill out it's bounding box
+$graph->SetPlotSize(0.85);
+
+// Use logarithmic scale (If you don't use any SetScale()
+// the spider graph will default to linear scale
+$graph->SetScale("log");
+
+// Uncomment the following line if you want to supress
+// minor tick marks
+// $graph->yscale->ticks->SupressMinorTickMarks();
+
+// We want the major tick marks to be black and minor
+// slightly less noticable
+$graph->yscale->ticks->SetMarkColor("black","darkgray");
+
+// Set the axis title font 
+$graph->axis->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+// Use blue axis
+$graph->axis->SetColor("blue");
+
+$plot = new RadarPlot($data);
+$plot->SetLineWeight(2);
+$plot->SetColor('forestgreen');
+
+// Add the plot and display the graph
+$graph->Add($plot);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/radarmarkex1.php b/web/classes/jpgraph/Examples/radarmarkex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..f5595e8a165ea9809de26add372e5c1b59e1cb52
--- /dev/null
+++ b/web/classes/jpgraph/Examples/radarmarkex1.php
@@ -0,0 +1,35 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_radar.php');
+
+$titles=array('Planning','Quality','Time','RR','CR','DR');
+$data=array(18, 40, 70, 90, 42,66);
+
+$graph = new RadarGraph (300,280);
+
+$graph->title->Set('Radar with marks');
+$graph->title->SetFont(FF_VERDANA,FS_NORMAL,12);
+
+$graph->SetTitles($titles);
+$graph->SetCenter(0.5,0.55);
+$graph->HideTickMarks();
+$graph->SetColor('lightgreen@0.7');
+$graph->axis->SetColor('darkgray');
+$graph->grid->SetColor('darkgray');
+$graph->grid->Show();
+
+$graph->axis->title->SetFont(FF_ARIAL,FS_NORMAL,12);
+$graph->axis->title->SetMargin(5);
+$graph->SetGridDepth(DEPTH_BACK);
+$graph->SetSize(0.6);
+
+$plot = new RadarPlot($data);
+$plot->SetColor('red@0.2');
+$plot->SetLineWeight(1);
+$plot->SetFillColor('red@0.7');
+
+$plot->mark->SetType(MARK_IMG_SBALL,'red');
+
+$graph->Add($plot);
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/rose.gif b/web/classes/jpgraph/Examples/rose.gif
new file mode 100755
index 0000000000000000000000000000000000000000..59fe631985b302cced25e985e1e75fd1e0ac32e6
Binary files /dev/null and b/web/classes/jpgraph/Examples/rose.gif differ
diff --git a/web/classes/jpgraph/Examples/rose_example.php b/web/classes/jpgraph/Examples/rose_example.php
new file mode 100755
index 0000000000000000000000000000000000000000..7d3d7c5733e2772b648a7501db0b01aeb0163e9c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/rose_example.php
@@ -0,0 +1,57 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$theme = isset($_GET['theme']) ? $_GET['theme'] : null;
+
+$data = array (
+  0 => array (0 => 79, 1 => -25, 2 => -7, 3 => 85, 4 => -26, 5 => -32, ),
+  1 => array (0 => 76, 1 => 51, 2 => 86, 3 => 12, 4 => -7, 5 => 94, ),
+  2 => array (0 => 49, 1 => 38, 2 => 7, 3 => -40, 4 => 9, 5 => -7, ),
+  3 => array ( 0 => 69, 1 => 96, 2 => 49, 3 => 7, 4 => 92, 5 => -38, ),
+  4 => array ( 0 => 68, 1 => 16, 2 => 82, 3 => -49, 4 => 50, 5 => 7, ),
+  5 => array ( 0 => -37, 1 => 28, 2 => 32, 3 => 6, 4 => 13, 5 => 57, ),
+  6 => array ( 0 => 24, 1 => -11, 2 => 7, 3 => 10, 4 => 51, 5 => 51, ),
+  7 => array ( 0 => 3, 1 => -1, 2 => -12, 3 => 61, 4 => 10, 5 => 47, ),
+  8 => array ( 0 => -47, 1 => -21, 2 => 43, 3 => 53, 4 => 36, 5 => 34, ),
+);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(400,300);    
+
+$graph->SetScale("textlin");
+if ($theme) {
+  $graph->SetTheme(new $theme());
+}
+$theme_class = new RoseTheme;
+$graph->SetTheme($theme_class);
+
+$plot = array();
+// Create the bar plots
+for ($i = 0; $i < 4; $i++) {
+  $plot[$i] = new BarPlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.($i+1));
+}
+//$acc1 = new AccBarPlot(array($plot[0], $plot[1]));
+//$acc1->value->Show();
+$gbplot = new GroupBarPlot(array($plot[2], $plot[1] ));
+
+for ($i = 4; $i < 8; $i++) {
+  $plot[$i] = new LinePlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.$i);
+  $plot[$i]->value->Show();
+}
+
+$graph->Add($gbplot);
+$graph->Add($plot[4]);
+
+$title = "RoseTheme Example";
+$title = mb_convert_encoding($title,'UTF-8');
+$graph->title->Set($title);
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/rotateex1.php b/web/classes/jpgraph/Examples/rotateex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..a90a60033d499557d5f6885b64b37f327f44376b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/rotateex1.php
@@ -0,0 +1,46 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+$y2data = array(354,200,265,99,111,91,198,225,293,251);
+
+$graph = new Graph(350,300);	
+$graph->SetAngle(40);
+$graph->img->SetMargin(80,80,80,80);
+$graph->SetScale("textlin");
+$graph->SetY2Scale("lin");
+$graph->SetShadow();
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot2=new LinePlot($y2data);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+$graph->AddY2($lineplot2);
+$lineplot2->SetColor("orange");
+$lineplot2->SetWeight(2);
+$graph->y2axis->SetColor("orange");
+
+$graph->title->Set("Example 1 rotated graph (40 degree)");
+$graph->legend->Pos(0.05,0.1,"right","top");
+
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->yaxis->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->xaxis->title->SetFont(FF_FONT1,FS_BOLD);
+
+$lineplot->SetColor("blue");
+$lineplot->SetWeight(2);
+
+$lineplot2->SetColor("orange");
+$lineplot2->SetWeight(2);
+
+$graph->yaxis->SetColor("blue");
+
+$lineplot->SetLegend("Plot 1");
+$lineplot2->SetLegend("Plot 2");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/rotex0.php b/web/classes/jpgraph/Examples/rotex0.php
new file mode 100755
index 0000000000000000000000000000000000000000..83d26bb898343ecdad6827da48286908c05e8b38
--- /dev/null
+++ b/web/classes/jpgraph/Examples/rotex0.php
@@ -0,0 +1,22 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,17,22,19,5,15);
+
+$graph = new Graph(270,170);
+$graph->SetMargin(30,90,30,30);
+$graph->SetScale("textlin");
+
+$line = new LinePlot($ydata);
+$line->SetLegend('2002');
+$line->SetColor('darkred');
+$line->SetWeight(2);
+$graph->Add($line);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/rotex1.php b/web/classes/jpgraph/Examples/rotex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..f087b98e543c63e3375839c637128ec4251454f6
--- /dev/null
+++ b/web/classes/jpgraph/Examples/rotex1.php
@@ -0,0 +1,24 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,17,22,19,5,15);
+
+$graph = new Graph(270,170);
+$graph->SetMargin(30,90,30,30);
+$graph->SetScale("textlin");
+
+$graph->img->SetAngle(45);
+
+$line = new LinePlot($ydata);
+$line->SetLegend('2002');
+$line->SetColor('darkred');
+$line->SetWeight(2);
+$graph->Add($line);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/rotex2.php b/web/classes/jpgraph/Examples/rotex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..bfdea5a7fdb7e130278dc460a0dbbe0e22d6ea3f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/rotex2.php
@@ -0,0 +1,24 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,17,22,19,5,15);
+
+$graph = new Graph(270,170);
+$graph->SetMargin(30,90,30,30);
+$graph->SetScale("textlin");
+
+$graph->img->SetAngle(90);
+
+$line = new LinePlot($ydata);
+$line->SetLegend('2002');
+$line->SetColor('darkred');
+$line->SetWeight(2);
+$graph->Add($line);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/rotex3.php b/web/classes/jpgraph/Examples/rotex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..3a0a03d4363bc885ee2b213a8cc23314f08bd878
--- /dev/null
+++ b/web/classes/jpgraph/Examples/rotex3.php
@@ -0,0 +1,25 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,17,22,19,5,15);
+
+$graph = new Graph(270,170);
+$graph->SetMargin(30,90,30,30);
+$graph->SetScale("textlin");
+
+$graph->img->SetAngle(45);
+$graph->img->SetCenter(floor(270/2),floor(170/2));
+
+$line = new LinePlot($ydata);
+$line->SetLegend('2002');
+$line->SetColor('darkred');
+$line->SetWeight(2);
+$graph->Add($line);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/rotex4.php b/web/classes/jpgraph/Examples/rotex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..9c01a7b2fe232f8eb963d3d117a575a8ba52eb01
--- /dev/null
+++ b/web/classes/jpgraph/Examples/rotex4.php
@@ -0,0 +1,25 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,17,22,19,5,15);
+
+$graph = new Graph(270,170);
+$graph->SetMargin(30,90,30,30);
+$graph->SetScale("textlin");
+
+$graph->img->SetAngle(90);
+$graph->img->SetCenter(floor(270/2),floor(170/2));
+
+$line = new LinePlot($ydata);
+$line->SetLegend('2002');
+$line->SetColor('darkred');
+$line->SetWeight(2);
+$graph->Add($line);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/rotex5.php b/web/classes/jpgraph/Examples/rotex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..bdf0d93f0e1cfc3d6ffd428ef3887007bf6f7818
--- /dev/null
+++ b/web/classes/jpgraph/Examples/rotex5.php
@@ -0,0 +1,25 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$ydata = array(12,17,22,19,5,15);
+
+$graph = new Graph(270,170);
+$graph->SetMargin(30,90,30,30);
+$graph->SetScale("textlin");
+
+$graph->img->SetAngle(-30);
+$graph->img->SetCenter(30,170-30);
+
+$line = new LinePlot($ydata);
+$line->SetLegend('2002');
+$line->SetColor('darkred');
+$line->SetWeight(2);
+$graph->Add($line);
+
+// Output graph
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/saab_95.jpg b/web/classes/jpgraph/Examples/saab_95.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..189b0d48f8349a9fb2ac706c028e89a645f8c0c5
Binary files /dev/null and b/web/classes/jpgraph/Examples/saab_95.jpg differ
diff --git a/web/classes/jpgraph/Examples/scatter_csimex1.php b/web/classes/jpgraph/Examples/scatter_csimex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..2ab4306de4de31a688ab212b32bc0d9e6c1ad157
--- /dev/null
+++ b/web/classes/jpgraph/Examples/scatter_csimex1.php
@@ -0,0 +1,44 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+// Some data for the points
+$datax = array(3.5,13.7,3,4,6.2,6,3.5,8,14,8,11.1,13.7);
+$datay = array(10,22,12,13,17,20,16,19,30,31,40,43);
+
+// A new scatter graph
+$graph = new Graph(300,200,'auto');
+$graph->SetShadow();
+$graph->SetScale("linlin");
+
+//$graph->img->SetMargin(40,40,40,40);		
+
+$graph->title->Set("Scatter plot with Image Map");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Client side image map targets
+$targ=array("pie_csimex1.php#1","pie_csimex1.php#2","pie_csimex1.php#3",
+"pie_csimex1.php#4","pie_csimex1.php#5","pie_csimex1.php#6",
+"pie_csimex1.php#7","pie_csimex1.php#8","pie_csimex1.php#9" );
+
+// Strings to put as "alts" (and "title" value)
+$alts=array("val=%d","val=%d","val=%d","val=%d","val=%d","val=%d","val=%d","val=%d","val=%d");
+
+// Create a new scatter plot
+$sp1 = new ScatterPlot($datay,$datax);
+
+// Use diamonds as markerss
+$sp1->mark->SetType(MARK_DIAMOND);
+$sp1->mark->SetWidth(10);
+
+// Set the scatter plot image map targets
+$sp1->SetCSIMTargets($targ,$alts);
+
+// Add the plot
+$graph->Add($sp1);
+
+// Send back the HTML page which will call this script again
+// to retrieve the image.
+$graph->StrokeCSIM();
+
+?>
diff --git a/web/classes/jpgraph/Examples/scatterex1.php b/web/classes/jpgraph/Examples/scatterex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..83d830b87d3831ea88fea94932735d8adb192dae
--- /dev/null
+++ b/web/classes/jpgraph/Examples/scatterex1.php
@@ -0,0 +1,22 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+$datax = array(3.5,3.7,3,4,6.2,6,3.5,8,14,8,11.1,13.7);
+$datay = array(20,22,12,13,17,20,16,19,30,31,40,43);
+
+$graph = new Graph(300,200);
+$graph->SetScale("linlin");
+
+$graph->img->SetMargin(40,40,40,40);		
+$graph->SetShadow();
+
+$graph->title->Set("A simple scatter plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$sp1 = new ScatterPlot($datay,$datax);
+
+$graph->Add($sp1);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/scatterex2.php b/web/classes/jpgraph/Examples/scatterex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..ff2b847d1529ecb5c351db8d230d1d948fe4f436
--- /dev/null
+++ b/web/classes/jpgraph/Examples/scatterex2.php
@@ -0,0 +1,25 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+$datax = array(3.5,3.7,3,4,6.2,6,3.5,8,14,8,11.1,13.7);
+$datay = array(20,22,12,13,17,20,16,19,30,31,40,43);
+
+$graph = new Graph(300,200);
+$graph->SetScale("linlin");
+
+$graph->img->SetMargin(40,40,40,40);		
+$graph->SetShadow();
+
+$graph->title->Set("A simple scatter plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$sp1 = new ScatterPlot($datay,$datax);
+$sp1->mark->SetType(MARK_FILLEDCIRCLE);
+$sp1->mark->SetFillColor("red");
+$sp1->mark->SetWidth(8);
+
+$graph->Add($sp1);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/scatterlinkex1.php b/web/classes/jpgraph/Examples/scatterlinkex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..2f2d1bdd083cb5d450b91c0173b1c0bfa9964894
--- /dev/null
+++ b/web/classes/jpgraph/Examples/scatterlinkex1.php
@@ -0,0 +1,26 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+$datax = array(3.5,3.7,3,4,6.2,6,3.5,8,14,8,11.1,13.7);
+$datay = array(20,22,12,13,17,20,16,19,30,31,40,43);
+$graph = new Graph(300,200);
+$graph->img->SetMargin(40,40,40,40);	
+$graph->img->SetAntiAliasing();
+$graph->SetScale("linlin");
+$graph->SetShadow();
+$graph->title->Set("Linked Scatter plot ex1");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+$sp1 = new ScatterPlot($datay,$datax);
+$sp1->SetLinkPoints(true,"red",2);
+$sp1->mark->SetType(MARK_FILLEDCIRCLE);
+$sp1->mark->SetFillColor("navy");
+$sp1->mark->SetWidth(3);
+
+$graph->Add($sp1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/scatterlinkex2.php b/web/classes/jpgraph/Examples/scatterlinkex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..f45f1ec3eec6578d6560c549e53b690de9f66f53
--- /dev/null
+++ b/web/classes/jpgraph/Examples/scatterlinkex2.php
@@ -0,0 +1,43 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+
+// Make a circle with a scatterplot
+$steps=16;
+for($i=0; $i<$steps; ++$i) {
+	$a=2*M_PI/$steps*$i;
+	$datax[$i]=cos($a);
+	$datay[$i]=sin($a);
+}
+
+
+$graph = new Graph(300,200);
+$graph->SetScale("linlin");
+
+$graph->img->SetMargin(40,40,40,40);		
+
+$graph->SetShadow();
+$graph->title->Set("Linked scatter plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// 10% top and bottom grace
+$graph->yscale->SetGrace(5,5);
+$graph->xscale->SetGrace(1,1);
+
+$sp1 = new ScatterPlot($datay,$datax);
+$sp1->mark->SetType(MARK_FILLEDCIRCLE);
+$sp1->mark->SetFillColor("red");
+$sp1->SetColor("blue");
+
+//$sp1->SetWeight(3);
+$sp1->mark->SetWidth(4);
+$sp1->SetLinkPoints();
+
+$graph->Add($sp1);
+
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/scatterlinkex3.php b/web/classes/jpgraph/Examples/scatterlinkex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..aef51508e33e835f73c8fc637c8fb550922c792d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/scatterlinkex3.php
@@ -0,0 +1,45 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+
+// Make a circle with a scatterplot
+$steps=16;
+for($i=0; $i<$steps; ++$i) {
+	$a=2*M_PI/$steps*$i;
+	$datax[$i]=cos($a);
+	$datay[$i]=sin($a);
+}
+
+$graph = new Graph(350,230);
+$graph->SetScale('linlin');
+$graph->SetShadow();
+$graph->SetAxisStyle(AXSTYLE_BOXOUT);
+
+$graph->img->SetMargin(50,50,60,40);
+
+$graph->title->Set('Linked scatter plot');
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->subtitle->Set('(BOXOUT Axis style)');
+$graph->subtitle->SetFont(FF_FONT1,FS_NORMAL);
+
+
+// 10% top and bottom grace
+$graph->yscale->SetGrace(5,5);
+$graph->xscale->SetGrace(1,1);
+
+$sp1 = new ScatterPlot($datay,$datax);
+$sp1->mark->SetType(MARK_FILLEDCIRCLE);
+$sp1->mark->SetFillColor('red');
+$sp1->SetColor('blue');
+
+$sp1->mark->SetWidth(4);
+$sp1->link->Show();
+$sp1->link->SetStyle('dotted');
+
+$graph->Add($sp1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/scatterlinkex4.php b/web/classes/jpgraph/Examples/scatterlinkex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..63659e0e8a4245fbb9491031b01a4136b91dbf60
--- /dev/null
+++ b/web/classes/jpgraph/Examples/scatterlinkex4.php
@@ -0,0 +1,45 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+// Make a circle with a scatterplot
+$steps=16;
+for($i=0; $i<$steps; ++$i) {
+	$a=2*M_PI/$steps*$i;
+	$datax[$i]=cos($a);
+	$datay[$i]=sin($a);
+}
+
+$graph = new Graph(350,230);
+$graph->SetScale('linlin');
+$graph->SetShadow();
+$graph->SetAxisStyle(AXSTYLE_BOXIN);
+
+$graph->img->SetMargin(50,50,60,40);
+
+$graph->title->Set('Linked scatter plot');
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->subtitle->Set('(BOXIN Axis style)');
+$graph->subtitle->SetFont(FF_FONT1,FS_NORMAL);
+
+// 10% top and bottom grace
+$graph->yscale->SetGrace(5,5);
+$graph->xscale->SetGrace(1,1);
+
+$sp1 = new ScatterPlot($datay,$datax);
+$sp1->mark->SetType(MARK_FILLEDCIRCLE);
+$sp1->mark->SetFillColor('red');
+$sp1->SetColor('blue');
+
+$sp1->mark->SetWidth(4);
+$sp1->link->Show();
+$sp1->link->SetWeight(2);
+$sp1->link->SetColor('red@0.7');
+
+
+$graph->Add($sp1);
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/scatterrotex1.php b/web/classes/jpgraph/Examples/scatterrotex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..6d67e5b1f8c502ca8f88f7075a0be2180bc15ca3
--- /dev/null
+++ b/web/classes/jpgraph/Examples/scatterrotex1.php
@@ -0,0 +1,35 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+
+$datax = array(3.5,3.7,3,4,6.2,6,3.5,8,14,8,11.1,13.7);
+$datay = array(20,22,12,13,17,20,16,19,30,31,40,43);
+
+$graph = new Graph(300,200);
+$graph->SetScale("linlin");
+
+$graph->Set90AndMargin(40,40,40,40);		
+$graph->SetShadow();
+
+$graph->title->Set("A 90 degrees rotated scatter plot");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Adjust the label align for X-axis so they look good rotated
+$graph->xaxis->SetLabelAlign('right','center','right');
+
+// Adjust the label align for Y-axis so they look good rotated
+$graph->yaxis->SetLabelAlign('center','bottom');
+
+$graph->xaxis->SetTitle('X-Axis title','low');
+$graph->xaxis->title->SetAngle(90);
+$graph->xaxis->title->SetMargin(15);
+
+$sp1 = new ScatterPlot($datay,$datax);
+$sp1->mark->SetType(MARK_FILLEDCIRCLE);
+$sp1->mark->SetFillColor("red");
+$sp1->mark->SetWidth(5);
+
+$graph->Add($sp1);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/show-example.php b/web/classes/jpgraph/Examples/show-example.php
new file mode 100755
index 0000000000000000000000000000000000000000..b95ac274aa3f395be1b03999a2076e15a001b60e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/show-example.php
@@ -0,0 +1,24 @@
+<?php $target = urldecode($_GET['target']); ?>
+<!doctype html public "-//W3C//DTD HTML 4.0 Frameset//EN">
+<html>
+<head>
+<title> Test suite for JpGraph - <?php echo $target; ?></title>
+<script type="text/javascript" language="javascript">
+<!--
+function resize()
+{
+	return true;
+}
+//-->
+</script>
+</head>
+<frameset rows="*,*" onLoad="resize()">
+	<?php 
+	if( !strstr($target,"csim") )
+		echo "<frame src=\"show-image.php?target=".basename($target)."\" name=\"image\">";
+	else
+		echo	"<frame src=\"".basename($target)."\" name=\"image\">";
+	?>
+	<frame src="show-source.php?target=<?php echo basename($target); ?>" name="source">
+</frameset>
+</html>
diff --git a/web/classes/jpgraph/Examples/show-image.php b/web/classes/jpgraph/Examples/show-image.php
new file mode 100755
index 0000000000000000000000000000000000000000..85a987cd25647a9b34ae64dbd2cd8e8e66fc4f0c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/show-image.php
@@ -0,0 +1,10 @@
+<?php $target =  urldecode($_GET['target']); ?>
+<!doctype html public "-//W3C//DTD HTML 4.0 Transitional//EN">
+<html>
+<head>
+<title> Image <?php echo basename($target); ?></title>
+</head>
+<body>
+<img src="<?php echo basename($target); ?>" border=0 alt="<?php echo basename($target); ?>" align="left">
+</body>
+</html>
diff --git a/web/classes/jpgraph/Examples/show-source.php b/web/classes/jpgraph/Examples/show-source.php
new file mode 100755
index 0000000000000000000000000000000000000000..248f2dee6992919cc0bcef8c1313a36b71d21d72
--- /dev/null
+++ b/web/classes/jpgraph/Examples/show-source.php
@@ -0,0 +1 @@
+<?php highlight_file(basename(urldecode($_GET['target']))); ?>
diff --git a/web/classes/jpgraph/Examples/smallstaticbandsex1.php b/web/classes/jpgraph/Examples/smallstaticbandsex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..c78fc8bc6083d644d49236c9026d747dd262bfa8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/smallstaticbandsex1.php
@@ -0,0 +1,41 @@
+<?php // content="text/plain; charset=utf-8"
+// Illustration of the different patterns for bands
+// $Id: smallstaticbandsex1.php,v 1.1 2002/09/01 21:51:08 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(10,29,3,6);
+
+// Create the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->SetMargin(25,10,20,20);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("lightblue");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+$graph->ygrid->Show(false);
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add band
+$band = new PlotBand(HORIZONTAL,BAND_RDIAG,15,35,'khaki4');
+$band->ShowFrame(false);
+$graph->Add($band);
+
+// Set title
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->title->SetColor('darkred');
+$graph->title->Set('BAND_RDIAG');
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/smallstaticbandsex10.php b/web/classes/jpgraph/Examples/smallstaticbandsex10.php
new file mode 100755
index 0000000000000000000000000000000000000000..88a091ca3e046b2cf727b35cbac131febad0f504
--- /dev/null
+++ b/web/classes/jpgraph/Examples/smallstaticbandsex10.php
@@ -0,0 +1,41 @@
+<?php // content="text/plain; charset=utf-8"
+// Illustration of the different patterns for bands
+// $Id: smallstaticbandsex10.php,v 1.1 2002/09/01 21:51:08 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(10,29,3,6);
+
+// Create the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->SetMargin(25,10,20,20);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("lightblue");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+$graph->ygrid->Show(false);
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add band
+$band = new PlotBand(HORIZONTAL,BAND_DIAGCROSS,15,35,'khaki4');
+$band->ShowFrame(false);
+$graph->Add($band);
+
+// Set title
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->title->SetColor('darkred');
+$graph->title->Set('BAND_DIAGCROSS');
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/smallstaticbandsex11.php b/web/classes/jpgraph/Examples/smallstaticbandsex11.php
new file mode 100755
index 0000000000000000000000000000000000000000..88a091ca3e046b2cf727b35cbac131febad0f504
--- /dev/null
+++ b/web/classes/jpgraph/Examples/smallstaticbandsex11.php
@@ -0,0 +1,41 @@
+<?php // content="text/plain; charset=utf-8"
+// Illustration of the different patterns for bands
+// $Id: smallstaticbandsex10.php,v 1.1 2002/09/01 21:51:08 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(10,29,3,6);
+
+// Create the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->SetMargin(25,10,20,20);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("lightblue");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+$graph->ygrid->Show(false);
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add band
+$band = new PlotBand(HORIZONTAL,BAND_DIAGCROSS,15,35,'khaki4');
+$band->ShowFrame(false);
+$graph->Add($band);
+
+// Set title
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->title->SetColor('darkred');
+$graph->title->Set('BAND_DIAGCROSS');
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/smallstaticbandsex2.php b/web/classes/jpgraph/Examples/smallstaticbandsex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..d9add7af91080222cdad4170a32e903e88605a26
--- /dev/null
+++ b/web/classes/jpgraph/Examples/smallstaticbandsex2.php
@@ -0,0 +1,41 @@
+<?php // content="text/plain; charset=utf-8"
+// Illustration of the different patterns for bands
+// $Id: smallstaticbandsex2.php,v 1.1 2002/09/01 21:51:08 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(10,29,3,6);
+
+// Create the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->SetMargin(25,10,20,20);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("lightblue");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+$graph->ygrid->Show(false);
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add band
+$band = new PlotBand(HORIZONTAL,BAND_LDIAG,15,35,'khaki4');
+$band->ShowFrame(false);
+$graph->Add($band);
+
+// Set title
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->title->SetColor('darkred');
+$graph->title->Set('BAND_LDIAG');
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/smallstaticbandsex3.php b/web/classes/jpgraph/Examples/smallstaticbandsex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..aa2a94d70a6b28f41d98bf2e28c75bc523a88679
--- /dev/null
+++ b/web/classes/jpgraph/Examples/smallstaticbandsex3.php
@@ -0,0 +1,41 @@
+<?php // content="text/plain; charset=utf-8"
+// Illustration of the different patterns for bands
+// $Id: smallstaticbandsex3.php,v 1.1 2002/09/01 21:51:08 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(10,29,3,6);
+
+// Create the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->SetMargin(25,10,20,20);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("lightblue");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+$graph->ygrid->Show(false);
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add band
+$band = new PlotBand(HORIZONTAL,BAND_SOLID,15,35,'khaki4');
+$band->ShowFrame(false);
+$graph->Add($band);
+
+// Set title
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->title->SetColor('darkred');
+$graph->title->Set('BAND_SOLID');
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/smallstaticbandsex4.php b/web/classes/jpgraph/Examples/smallstaticbandsex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..e4bd999cea6c6700b0a095302e1dfb4e368a5121
--- /dev/null
+++ b/web/classes/jpgraph/Examples/smallstaticbandsex4.php
@@ -0,0 +1,42 @@
+<?php // content="text/plain; charset=utf-8"
+// Illustration of the different patterns for bands
+// $Id: smallstaticbandsex4.php,v 1.1 2002/09/01 21:51:08 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(10,29,3,6);
+
+// Create the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->SetMargin(25,10,20,20);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("lightblue");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+$graph->ygrid->Show(false);
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add band
+$band = new PlotBand(HORIZONTAL,BAND_3DPLANE,15,35,'khaki4');
+$band->SetDensity(80);
+$band->ShowFrame(true);
+$graph->Add($band);
+
+// Set title
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->title->SetColor('darkred');
+$graph->title->Set('BAND_3DPLANE, Density=60');
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/smallstaticbandsex5.php b/web/classes/jpgraph/Examples/smallstaticbandsex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..d7f9ebb2ab50731a825ced4e7eaa9750dc0210ba
--- /dev/null
+++ b/web/classes/jpgraph/Examples/smallstaticbandsex5.php
@@ -0,0 +1,42 @@
+<?php // content="text/plain; charset=utf-8"
+// Illustration of the different patterns for bands
+// $Id: smallstaticbandsex5.php,v 1.1 2002/09/01 21:51:08 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(10,29,3,6);
+
+// Create the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->SetMargin(25,10,20,20);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("lightblue");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+$graph->ygrid->Show(false);
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add band
+$band = new PlotBand(HORIZONTAL,BAND_HVCROSS,15,35,'khaki4');
+$band->ShowFrame(true);
+$band->SetOrder(DEPTH_FRONT);
+$graph->Add($band);
+
+// Set title
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->title->SetColor('darkred');
+$graph->title->Set('BAND_HVCROSS, In front');
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/smallstaticbandsex6.php b/web/classes/jpgraph/Examples/smallstaticbandsex6.php
new file mode 100755
index 0000000000000000000000000000000000000000..506e1a80f568431eed325f6462b919d574ae5747
--- /dev/null
+++ b/web/classes/jpgraph/Examples/smallstaticbandsex6.php
@@ -0,0 +1,41 @@
+<?php // content="text/plain; charset=utf-8"
+// Illustration of the different patterns for bands
+// $Id: smallstaticbandsex6.php,v 1.1 2002/09/01 21:51:08 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(10,29,3,6);
+
+// Create the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->SetMargin(25,10,20,20);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("lightblue");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+$graph->ygrid->Show(false);
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add band
+$band = new PlotBand(HORIZONTAL,BAND_VLINE,15,35,'khaki4');
+$band->ShowFrame(false);
+$graph->Add($band);
+
+// Set title
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->title->SetColor('darkred');
+$graph->title->Set('BAND_VLINE');
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/smallstaticbandsex7.php b/web/classes/jpgraph/Examples/smallstaticbandsex7.php
new file mode 100755
index 0000000000000000000000000000000000000000..e07dc6a953cadedb2c51c14f972062a0d326d668
--- /dev/null
+++ b/web/classes/jpgraph/Examples/smallstaticbandsex7.php
@@ -0,0 +1,41 @@
+<?php // content="text/plain; charset=utf-8"
+// Illustration of the different patterns for bands
+// $Id: smallstaticbandsex7.php,v 1.1 2002/09/01 21:51:08 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(10,29,3,6);
+
+// Create the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->SetMargin(25,10,20,20);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("lightblue");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+$graph->ygrid->Show(false);
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add band
+$band = new PlotBand(HORIZONTAL,BAND_HLINE,15,35,'khaki4');
+$band->ShowFrame(false);
+$graph->Add($band);
+
+// Set title
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->title->SetColor('darkred');
+$graph->title->Set('BAND_HLINE');
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/smallstaticbandsex8.php b/web/classes/jpgraph/Examples/smallstaticbandsex8.php
new file mode 100755
index 0000000000000000000000000000000000000000..6fbe40fb0f66de175187c37386353860e987e3a7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/smallstaticbandsex8.php
@@ -0,0 +1,41 @@
+<?php // content="text/plain; charset=utf-8"
+// Illustration of the different patterns for bands
+// $Id: smallstaticbandsex8.php,v 1.1 2002/09/01 21:51:08 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(10,29,3,6);
+
+// Create the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->SetMargin(25,10,20,20);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("lightblue");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+$graph->ygrid->Show(false);
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add band
+$band = new PlotBand(HORIZONTAL,BAND_3DPLANE,15,35,'khaki4');
+$band->ShowFrame(false);
+$graph->Add($band);
+
+// Set title
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->title->SetColor('darkred');
+$graph->title->Set('BAND_3DPLANE');
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/smallstaticbandsex9.php b/web/classes/jpgraph/Examples/smallstaticbandsex9.php
new file mode 100755
index 0000000000000000000000000000000000000000..b6126d80a393434b815116e3bbf6f1f5134eb957
--- /dev/null
+++ b/web/classes/jpgraph/Examples/smallstaticbandsex9.php
@@ -0,0 +1,41 @@
+<?php // content="text/plain; charset=utf-8"
+// Illustration of the different patterns for bands
+// $Id: smallstaticbandsex9.php,v 1.1 2002/09/01 21:51:08 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(10,29,3,6);
+
+// Create the graph. 
+$graph = new Graph(200,150);	
+$graph->SetScale("textlin");
+$graph->SetMargin(25,10,20,20);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("lightblue");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+$graph->ygrid->Show(false);
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add band
+$band = new PlotBand(HORIZONTAL,BAND_HVCROSS,15,35,'khaki4');
+$band->ShowFrame(false);
+$graph->Add($band);
+
+// Set title
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->title->SetColor('darkred');
+$graph->title->Set('BAND_HVCROSS');
+
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/softy_example.php b/web/classes/jpgraph/Examples/softy_example.php
new file mode 100755
index 0000000000000000000000000000000000000000..4d21fc989c38f658aa7c944ede2d85fed932d118
--- /dev/null
+++ b/web/classes/jpgraph/Examples/softy_example.php
@@ -0,0 +1,58 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$theme = isset($_GET['theme']) ? $_GET['theme'] : null;
+
+$data = array (
+  0 => array (0 => 79, 1 => -25, 2 => -7, 3 => 85, 4 => -26, 5 => -32, ),
+  1 => array (0 => 76, 1 => 51, 2 => 86, 3 => 12, 4 => -7, 5 => 94, ),
+  2 => array (0 => 49, 1 => 38, 2 => 7, 3 => -40, 4 => 9, 5 => -7, ),
+  3 => array ( 0 => 69, 1 => 96, 2 => 49, 3 => 7, 4 => 92, 5 => -38, ),
+  4 => array ( 0 => 68, 1 => 16, 2 => 82, 3 => -49, 4 => 50, 5 => 7, ),
+  5 => array ( 0 => -37, 1 => 28, 2 => 32, 3 => 6, 4 => 13, 5 => 57, ),
+  6 => array ( 0 => 24, 1 => -11, 2 => 7, 3 => 10, 4 => 51, 5 => 51, ),
+  7 => array ( 0 => 3, 1 => -1, 2 => -12, 3 => 61, 4 => 10, 5 => 47, ),
+  8 => array ( 0 => -47, 1 => -21, 2 => 43, 3 => 53, 4 => 36, 5 => 34, ),
+);
+
+
+// Create the graph. These two calls are always required
+$graph = new Graph(400,300);    
+
+$graph->SetScale("textlin");
+if ($theme) {
+  $graph->SetTheme(new $theme());
+}
+$theme_class = new SoftyTheme;
+$graph->SetTheme($theme_class);
+
+$plot = array();
+// Create the bar plots
+for ($i = 0; $i < 4; $i++) {
+  $plot[$i] = new BarPlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.($i+1));
+}
+//$acc1 = new AccBarPlot(array($plot[0], $plot[1]));
+//$acc1->value->Show();
+$gbplot = new GroupBarPlot(array($plot[2], $plot[1] ));
+
+for ($i = 4; $i < 8; $i++) {
+  $plot[$i] = new LinePlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.$i);
+  $plot[$i]->value->Show();
+}
+
+$graph->Add($gbplot);
+$graph->Add($plot[4]);
+
+$title = "SoftyTheme Example";
+$title = mb_convert_encoding($title,'UTF-8');
+$graph->title->Set($title);
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/splineex1.php b/web/classes/jpgraph/Examples/splineex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..61f60323a5a869a253d6bb00bd854c854fbfa786
--- /dev/null
+++ b/web/classes/jpgraph/Examples/splineex1.php
@@ -0,0 +1,56 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_scatter.php');
+require_once ('jpgraph/jpgraph_regstat.php');
+
+// Original data points
+$xdata = array(1,3,5,7,9,12,15,17.1);
+$ydata = array(5,1,9,6,4,3,19,12);
+
+// Get the interpolated values by creating
+// a new Spline object.
+$spline = new Spline($xdata,$ydata);
+
+// For the new data set we want 40 points to
+// get a smooth curve.
+list($newx,$newy) = $spline->Get(50);
+
+// Create the graph
+$g = new Graph(300,200);
+$g->SetMargin(30,20,40,30);
+$g->title->Set("Natural cubic splines");
+$g->title->SetFont(FF_ARIAL,FS_NORMAL,12);
+$g->subtitle->Set('(Control points shown in red)');
+$g->subtitle->SetColor('darkred');
+$g->SetMarginColor('lightblue');
+
+//$g->img->SetAntiAliasing();
+
+// We need a linlin scale since we provide both
+// x and y coordinates for the data points.
+$g->SetScale('linlin');
+
+// We want 1 decimal for the X-label
+$g->xaxis->SetLabelFormat('%1.1f');
+
+// We use a scatterplot to illustrate the original
+// contro points.
+$splot = new ScatterPlot($ydata,$xdata);
+
+// 
+$splot->mark->SetFillColor('red@0.3');
+$splot->mark->SetColor('red@0.5');
+
+// And a line plot to stroke the smooth curve we got
+// from the original control points
+$lplot = new LinePlot($newy,$newx);
+$lplot->SetColor('navy');
+
+// Add the plots to the graph and stroke
+$g->Add($lplot);
+$g->Add($splot);
+$g->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/staticbandbarex1.php b/web/classes/jpgraph/Examples/staticbandbarex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..5d59b26aaf0960fbe330f4f0f8c5dab17be7a12f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/staticbandbarex1.php
@@ -0,0 +1,52 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,0,-19,-7,17,-6);
+
+// Create the graph. 
+$graph = new Graph(400,300);	
+$graph->img->SetMargin(60,30,50,40);
+$graph->SetScale("textlin");
+$graph->SetShadow();
+
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,15);
+$graph->title->Set("Cash flow ");
+$graph->subtitle->Set("(Department X)");
+
+// Show both X and Y grid
+$graph->xgrid->Show(true,false);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10,10);
+
+// Turn the tick mark out from the plot area
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("orange");
+
+// Show the actual value for each bar on top/bottom
+$bplot->value->Show(true);
+$bplot->value->SetFormat("%02d kr");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add band
+$graph->Add(new PlotBand(HORIZONTAL,BAND_HLINE,0,10));
+
+//$graph->title->Set("Test of bar gradient fill");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->yaxis->title->SetFont(FF_ARIAL,FS_BOLD,11);
+$graph->xaxis->title->SetFont(FF_ARIAL,FS_BOLD,11);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/staticbandbarex2.php b/web/classes/jpgraph/Examples/staticbandbarex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..24d3bbcbaf8bbedb12348bb9bfc8a25416011c6a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/staticbandbarex2.php
@@ -0,0 +1,52 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,0,-19,-7,17,-6);
+
+// Create the graph. 
+$graph = new Graph(400,300);	
+$graph->img->SetMargin(60,30,50,40);
+$graph->SetScale("textlin");
+$graph->SetShadow();
+
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,15);
+$graph->title->Set("Cash flow ");
+$graph->subtitle->Set("(Department X)");
+
+// Show both X and Y grid
+$graph->xgrid->Show(true,false);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10,10);
+
+// Turn the tick mark out from the plot area
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("orange");
+
+// Show the actual value for each bar on top/bottom
+$bplot->value->Show(true);
+$bplot->value->SetFormat("%02d kr");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add band
+$graph->Add(new PlotBand(HORIZONTAL,BAND_RDIAG,0,"max","red",2));
+
+//$graph->title->Set("Test of bar gradient fill");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->yaxis->title->SetFont(FF_ARIAL,FS_BOLD,11);
+$graph->xaxis->title->SetFont(FF_ARIAL,FS_BOLD,11);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/staticbandbarex3.php b/web/classes/jpgraph/Examples/staticbandbarex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..fa38cca1cfb2f51a78e328ff1ebbe0b5cfe5d0b0
--- /dev/null
+++ b/web/classes/jpgraph/Examples/staticbandbarex3.php
@@ -0,0 +1,58 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,0,-19,-7,17,-6);
+
+// Create the graph. 
+$graph = new Graph(400,300);	
+$graph->img->SetMargin(60,30,50,40);
+$graph->SetScale("textlin");
+$graph->SetShadow();
+
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,15);
+$graph->title->Set("Cash flow ");
+$graph->subtitle->Set("(Department X)");
+
+// Show both X and Y grid
+$graph->xgrid->Show(true,false);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10,10);
+
+// Turn the tick mark out from the plot area
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("orange");
+
+// Show the actual value for each bar on top/bottom
+$bplot->value->Show(true);
+$bplot->value->SetFormat("%02d kr");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add upper and lower band and use no frames
+$uband=new PlotBand(HORIZONTAL,BAND_RDIAG,0,"max","green");
+$uband->ShowFrame(false);
+$lband=new PlotBand(HORIZONTAL,BAND_LDIAG,"min",0,"red");
+$lband->ShowFrame(false);
+
+$graph->Add($uband);
+$graph->Add($lband);
+
+//$graph->title->Set("Test of bar gradient fill");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->yaxis->title->SetFont(FF_ARIAL,FS_BOLD,11);
+$graph->xaxis->title->SetFont(FF_ARIAL,FS_BOLD,11);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/staticbandbarex4.php b/web/classes/jpgraph/Examples/staticbandbarex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..57ca6dbbbc4b77134263b92d17a2b50223292569
--- /dev/null
+++ b/web/classes/jpgraph/Examples/staticbandbarex4.php
@@ -0,0 +1,60 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,0,-19,-7,17,-6);
+
+// Create the graph. 
+$graph = new Graph(400,300);	
+$graph->img->SetMargin(60,30,50,40);
+$graph->SetScale("textlin");
+$graph->SetShadow();
+
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,15);
+$graph->title->Set("Cash flow ");
+$graph->subtitle->Set("(Department X)");
+
+// Show both X and Y grid
+$graph->xgrid->Show(true,false);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10,10);
+
+// Turn the tick mark out from the plot area
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("orange");
+
+// Show the actual value for each bar on top/bottom
+$bplot->value->Show(true);
+$bplot->value->SetFormat("%02d kr");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add upper and lower band and use no frames
+$uband=new PlotBand(HORIZONTAL,BAND_RDIAG,0,"max","green");
+$uband->ShowFrame(false);
+$uband->SetDensity(50); // 50% line density
+$lband=new PlotBand(HORIZONTAL,BAND_LDIAG,"min",0,"red");
+$lband->ShowFrame(false);
+$lband->SetDensity(20); // 20% line density
+
+$graph->Add($uband);
+$graph->Add($lband);
+
+//$graph->title->Set("Test of bar gradient fill");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->yaxis->title->SetFont(FF_ARIAL,FS_BOLD,11);
+$graph->xaxis->title->SetFont(FF_ARIAL,FS_BOLD,11);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/staticbandbarex5.php b/web/classes/jpgraph/Examples/staticbandbarex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..8d80855f98f86dc5732cf831649638bb9efdc43e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/staticbandbarex5.php
@@ -0,0 +1,63 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,0,-19,-7,17,-6);
+
+// Create the graph. 
+$graph = new Graph(400,300);	
+$graph->img->SetMargin(60,30,50,40);
+$graph->SetScale("textlin");
+$graph->SetShadow();
+
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,15);
+$graph->title->Set("Cash flow ");
+$graph->subtitle->Set("(Department X)");
+
+// Show both X and Y grid
+$graph->xgrid->Show(true,false);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10,10);
+
+// Turn the tick mark out from the plot area
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("orange");
+
+// Show the actual value for each bar on top/bottom
+$bplot->value->Show(true);
+$bplot->value->SetFormat("%02d kr");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add upper and lower band and use no frames
+$band[0]=new PlotBand(HORIZONTAL,BAND_RDIAG,10,20,"green");
+$band[0]->ShowFrame(false);
+$band[0]->SetDensity(30);
+$band[1]=new PlotBand(HORIZONTAL,BAND_LDIAG,-20,-10,"red");
+$band[1]->ShowFrame(false);
+$band[1]->SetDensity(40);
+$band[2]=new PlotBand(HORIZONTAL,BAND_LDIAG,"min",-20,"red");
+$band[2]->ShowFrame(false);
+$band[2]->SetDensity(80);
+
+// We can also add band in an array
+$graph->Add($band);
+
+//$graph->title->Set("Test of bar gradient fill");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->yaxis->title->SetFont(FF_ARIAL,FS_BOLD,11);
+$graph->xaxis->title->SetFont(FF_ARIAL,FS_BOLD,11);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/staticbandbarex6.php b/web/classes/jpgraph/Examples/staticbandbarex6.php
new file mode 100755
index 0000000000000000000000000000000000000000..df352ea9066fdc4bb1089847a06f5ca7581b4485
--- /dev/null
+++ b/web/classes/jpgraph/Examples/staticbandbarex6.php
@@ -0,0 +1,74 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_plotline.php');
+
+$datay=array(12,0,-19,-7,17,-6);
+
+// Create the graph. 
+$graph = new Graph(400,300);	
+$graph->img->SetMargin(60,30,50,40);
+$graph->SetScale("textlin");
+$graph->SetShadow();
+
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,15);
+$graph->title->Set("Cash flow ");
+$graph->subtitle->Set("Shows some possible patterns for bands");
+
+// Show both X and Y grid
+$graph->xgrid->Show(true,false);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10,10);
+
+// Turn the tick mark out from the plot area
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("orange");
+$bplot->SetShadow();
+
+// Show the actual value for each bar on top/bottom
+$bplot->value->Show(true);
+$bplot->value->SetFormat("%02d kr");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add upper and lower band and use no frames
+$band[0]=new PlotBand(HORIZONTAL,BAND_RDIAG,10,20,"green");
+$band[0]->ShowFrame(false);
+$band[1]=new PlotBand(HORIZONTAL,BAND_LDIAG,-20,-10,"red");
+$band[1]->ShowFrame(false);
+$band[1]->SetDensity(20);
+$band[2]=new PlotBand(HORIZONTAL,BAND_DIAGCROSS,"min",-20,"red");
+$band[2]->ShowFrame(false);
+$band[2]->SetDensity(40);
+$band[3]=new PlotBand(VERTICAL,BAND_HLINE,0,1,"darkgray");
+$band[3]->ShowFrame(false);
+$band[3]->SetOrder(DEPTH_FRONT);
+$band[4]=new PlotBand(VERTICAL,BAND_HVCROSS,5,"max","darkgray");
+$band[4]->ShowFrame(false);
+$band[4]->SetOrder(DEPTH_FRONT);
+$band[5]=new PlotBand(HORIZONTAL,BAND_SOLID,20,"max","lightgreen");
+$band[6]=new PlotBand(HORIZONTAL,BAND_3DPLANE,-10,0,"blue");
+$band[6]->SetDensity(70);
+$graph->Add($band);
+
+$graph->AddLine(new PlotLine(HORIZONTAL,0,"black",2));
+
+//$graph->title->Set("Test of bar gradient fill");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->yaxis->title->SetFont(FF_ARIAL,FS_BOLD,11);
+$graph->xaxis->title->SetFont(FF_ARIAL,FS_BOLD,11);
+
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/staticbandbarex7.php b/web/classes/jpgraph/Examples/staticbandbarex7.php
new file mode 100755
index 0000000000000000000000000000000000000000..399a172b85585d11afb12ac86c010bead1bd7bb7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/staticbandbarex7.php
@@ -0,0 +1,62 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_plotline.php');
+
+$datay=array(12,5,19,22,17,6);
+
+// Create the graph. 
+$graph = new Graph(400,300);	
+$graph->img->SetMargin(60,30,50,40);
+$graph->SetScale("textlin");
+$graph->SetShadow();
+
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,15);
+$graph->title->Set("Cash flow ");
+$graph->subtitle->Set("Use of static line, 3D and solid band");
+
+// Turn off Y-grid (it's on by default)
+$graph->ygrid->Show(false);
+
+// Add 10% grace ("space") at top of Y-scale. 
+$graph->yscale->SetGrace(10);
+$graph->yscale->SetAutoMin(-20);
+
+// Turn the tick mark out from the plot area
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("orange");
+$bplot->SetShadow("darkblue");
+
+// Show the actual value for each bar on top/bottom
+$bplot->value->Show(true);
+$bplot->value->SetFormat("%02d kr");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add upper and lower band and use no frames
+$band[0]=new PlotBand(HORIZONTAL,BAND_3DPLANE,"min",0,"blue");
+$band[0]->ShowFrame(false);
+$band[0]->SetDensity(20);
+$band[1]=new PlotBand(HORIZONTAL,BAND_SOLID,0,"max","steelblue");
+$band[1]->ShowFrame(false);
+$graph->Add($band);
+
+$graph->Add(new PlotLine(HORIZONTAL,0,"black",2));
+
+//$graph->title->Set("Test of bar gradient fill");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->yaxis->title->SetFont(FF_ARIAL,FS_BOLD,11);
+$graph->xaxis->title->SetFont(FF_ARIAL,FS_BOLD,11);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/staticlinebarex1.php b/web/classes/jpgraph/Examples/staticlinebarex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..9c63442b2bd60180e8798bd643580d83b8f7262a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/staticlinebarex1.php
@@ -0,0 +1,55 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_plotline.php');
+
+$datay=array(12,0,-19,-7,17,-6);
+
+// Create the graph. 
+$graph = new Graph(400,300);	
+$graph->img->SetMargin(60,30,50,40);
+$graph->SetScale("textlin");
+$graph->SetShadow();
+
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,15);
+$graph->title->Set("Cash flow ");
+$graph->subtitle->Set("(Department X)");
+
+// Show both X and Y grid
+$graph->xgrid->Show(true,false);
+
+// Add 10% grace ("space") at top and botton of Y-scale. 
+$graph->yscale->SetGrace(10,10);
+
+// Turn the tick mark out from the plot area
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+$graph->yaxis->SetTickSide(SIDE_LEFT);
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+$bplot->SetFillColor("orange");
+$bplot->SetShadow();
+
+// Show the actual value for each bar on top/bottom
+$bplot->value->Show();
+$bplot->value->SetFormat("%02d kr");
+
+// Position the X-axis at the bottom of the plotare
+$graph->xaxis->SetPos("min");
+
+// .. and add the plot to the graph
+$graph->Add($bplot);
+
+// Add mark graph with static lines
+$graph->AddLine(new PlotLine(HORIZONTAL,0,"black",2));
+$graph->AddLine(new PlotLine(VERTICAL,3,"black",2));
+
+//$graph->title->Set("Test of bar gradient fill");
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+$graph->yaxis->title->SetFont(FF_ARIAL,FS_BOLD,11);
+$graph->xaxis->title->SetFont(FF_ARIAL,FS_BOLD,11);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/stockex1.php b/web/classes/jpgraph/Examples/stockex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..d77145c7d780de2c3a5aec852faf5ab267d08fb4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/stockex1.php
@@ -0,0 +1,33 @@
+<?php // content="text/plain; charset=utf-8"
+// Example of a stock chart
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_stock.php');
+
+// Data must be in the format : open,close,min,max
+$datay = array(
+    34,42,27,45,
+    55,25,14,59,
+    15,40,12,47,
+    62,38,25,65,
+    38,49,32,64);
+
+// Setup a simple graph
+$graph = new Graph(300,200);
+$graph->SetScale("textlin");
+$graph->SetMarginColor('lightblue');
+$graph->title->Set('Stockchart example');
+
+// Create a new stock plot
+$p1 = new StockPlot($datay);
+
+// Width of the bars (in pixels)
+$p1->SetWidth(9);
+
+// Uncomment the following line to hide the horizontal end lines
+//$p1->HideEndLines();
+
+// Add the plot to the graph and send it back to the browser
+$graph->Add($p1);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/stockex2.php b/web/classes/jpgraph/Examples/stockex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..e038cca01a85cbfa2e66a0352ca8cb59a9cbcd8b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/stockex2.php
@@ -0,0 +1,39 @@
+<?php // content="text/plain; charset=utf-8"
+// $Id: stockex2.php,v 1.1 2003/01/31 17:41:29 aditus Exp $
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_stock.php');
+
+
+$datay = array(
+    34,42,27,45,
+    55,25,12,59,
+    38,49,32,64,
+    34,40,29,42,
+    40,29,22,45 );
+
+// Setup basic graph
+$graph = new Graph(300,200);
+$graph->SetScale("textlin");
+$graph->SetMarginColor('white');
+$graph->SetFrame(false);
+$graph->ygrid->SetFill(true,'#EFEFEF@0.5','#BBCCFF@0.5');
+$graph->SetBox();
+
+$graph->tabtitle->Set(' Week 34 ');
+$graph->tabtitle->SetFont(FF_ARIAL,FS_NORMAL,12);
+
+// Get week days in curent locale
+$days = $gDateLocale->GetShortDay();
+array_shift($days); // Start on monday
+$graph->xaxis->SetTickLabels($days);
+
+// Create stock plot
+$p1 = new StockPlot($datay);
+
+// Indent plot so first and last bar isn't on the edges
+$p1->SetCenter();
+
+// Add and stroke
+$graph->Add($p1);
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/stship.jpg b/web/classes/jpgraph/Examples/stship.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..7f3bae62d72c3815b419e494df122cad9cb4a3b9
Binary files /dev/null and b/web/classes/jpgraph/Examples/stship.jpg differ
diff --git a/web/classes/jpgraph/Examples/sunflower.gif b/web/classes/jpgraph/Examples/sunflower.gif
new file mode 100755
index 0000000000000000000000000000000000000000..b83709f848ca8319a3eed213d5d6a96c090d2e15
Binary files /dev/null and b/web/classes/jpgraph/Examples/sunflower.gif differ
diff --git a/web/classes/jpgraph/Examples/sunspotsex1.php b/web/classes/jpgraph/Examples/sunspotsex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..d5edb83e069106f263a48453a30bfe9e513ea21b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/sunspotsex1.php
@@ -0,0 +1,51 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+function readsunspotdata($aFile, &$aYears, &$aSunspots) {
+    $lines = @file($aFile,FILE_IGNORE_NEW_LINES|FILE_SKIP_EMPTY_LINES);
+    if( $lines === false ) {
+        throw new JpGraphException('Can not read sunspot data file.');
+    }
+    foreach( $lines as $line => $datarow ) {
+        $split = preg_split('/[\s]+/',$datarow);
+        $aYears[] = substr(trim($split[0]),0,4);
+        $aSunspots[] = trim($split[1]);
+    }
+}
+
+$year = array();
+$ydata = array();
+readsunspotdata('yearssn.txt',$year,$ydata);
+
+ // Width and height of the graph
+$width = 600; $height = 200;
+
+// Create a graph instance
+$graph = new Graph($width,$height);
+
+// Specify what scale we want to use,
+// int = integer scale for the X-axis
+// int = integer scale for the Y-axis
+$graph->SetScale('intint');
+
+// Setup a title for the graph
+$graph->title->Set('Sunspot example');
+
+// Setup titles and X-axis labels
+$graph->xaxis->title->Set('(year from 1701)');
+
+// Setup Y-axis title
+$graph->yaxis->title->Set('(# sunspots)');
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/sunspotsex2.php b/web/classes/jpgraph/Examples/sunspotsex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..817db15892ac7a0a2cb3d179ddafde7cc294426a
--- /dev/null
+++ b/web/classes/jpgraph/Examples/sunspotsex2.php
@@ -0,0 +1,52 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+function readsunspotdata($aFile, &$aYears, &$aSunspots) {
+    $lines = @file($aFile,FILE_IGNORE_NEW_LINES|FILE_SKIP_EMPTY_LINES);
+    if( $lines === false ) {
+        throw new JpGraphException('Can not read sunspot data file.');
+    }
+    foreach( $lines as $line => $datarow ) {
+        $split = preg_split('/[\s]+/',$datarow);
+        $aYears[] = substr(trim($split[0]),0,4);
+        $aSunspots[] = trim($split[1]);
+    }
+}
+
+$year = array();
+$ydata = array();
+readsunspotdata('yearssn.txt',$year,$ydata);
+
+ // Width and height of the graph
+$width = 600; $height = 200;
+
+// Create a graph instance
+$graph = new Graph($width,$height);
+
+// Specify what scale we want to use,
+// int = integer scale for the X-axis
+// int = integer scale for the Y-axis
+$graph->SetScale('intint');
+
+// Setup a title for the graph
+$graph->title->Set('Sunspot example');
+
+// Setup titles and X-axis labels
+$graph->xaxis->title->Set('(year from 1701)');
+
+// Setup Y-axis title
+$graph->yaxis->title->Set('(# sunspots)');
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetFillColor('orange@0.5');
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/sunspotsex3.php b/web/classes/jpgraph/Examples/sunspotsex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..cf54cb447146f6d61f03a4359cd65040789172ae
--- /dev/null
+++ b/web/classes/jpgraph/Examples/sunspotsex3.php
@@ -0,0 +1,53 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+function readsunspotdata($aFile, &$aYears, &$aSunspots) {
+    $lines = @file($aFile,FILE_IGNORE_NEW_LINES|FILE_SKIP_EMPTY_LINES);
+    if( $lines === false ) {
+        throw new JpGraphException('Can not read sunspot data file.');
+    }
+    foreach( $lines as $line => $datarow ) {
+        $split = preg_split('/[\s]+/',$datarow);
+        $aYears[] = substr(trim($split[0]),0,4);
+        $aSunspots[] = trim($split[1]);
+    }
+}
+
+$year = array();
+$ydata = array();
+readsunspotdata('yearssn.txt',$year,$ydata);
+
+ // Width and height of the graph
+$width = 600; $height = 200;
+
+// Create a graph instance
+$graph = new Graph($width,$height);
+
+// Specify what scale we want to use,
+// int = integer scale for the X-axis
+// int = integer scale for the Y-axis
+$graph->SetScale('intint');
+
+// Setup a title for the graph
+$graph->title->Set('Sunspot example');
+
+// Setup titles and X-axis labels
+$graph->xaxis->title->Set('(year from 1701)');
+$graph->xaxis->SetTickLabels($year);
+
+// Setup Y-axis title
+$graph->yaxis->title->Set('(# sunspots)');
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetFillColor('orange@0.5');
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/sunspotsex4.php b/web/classes/jpgraph/Examples/sunspotsex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..e0877e0360258fdefcfc683371faa33b315a3e17
--- /dev/null
+++ b/web/classes/jpgraph/Examples/sunspotsex4.php
@@ -0,0 +1,53 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+function readsunspotdata($aFile, &$aYears, &$aSunspots) {
+    $lines = @file($aFile,FILE_IGNORE_NEW_LINES|FILE_SKIP_EMPTY_LINES);
+    if( $lines === false ) {
+        throw new JpGraphException('Can not read sunspot data file.');
+    }
+    foreach( $lines as $line => $datarow ) {
+        $split = preg_split('/[\s]+/',$datarow);
+        $aYears[] = substr(trim($split[0]),0,4);
+        $aSunspots[] = trim($split[1]);
+    }
+}
+
+$year = array();
+$ydata = array();
+readsunspotdata('yearssn.txt',$year,$ydata);
+
+ // Width and height of the graph
+$width = 600; $height = 200;
+
+// Create a graph instance
+$graph = new Graph($width,$height);
+
+// Specify what scale we want to use,
+// int = integer scale for the X-axis
+// int = integer scale for the Y-axis
+$graph->SetScale('intint',0,0,0,max($year)-min($year)+1);
+
+// Setup a title for the graph
+$graph->title->Set('Sunspot example');
+
+// Setup titles and X-axis labels
+$graph->xaxis->title->Set('(year from 1701)');
+$graph->xaxis->SetTickLabels($year);
+
+// Setup Y-axis title
+$graph->yaxis->title->Set('(# sunspots)');
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetFillColor('orange@0.5');
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/sunspotsex5.php b/web/classes/jpgraph/Examples/sunspotsex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..3d7322a2d944ad6e0619b2b6619f29f8aa42907e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/sunspotsex5.php
@@ -0,0 +1,57 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+function readsunspotdata($aFile, &$aYears, &$aSunspots) {
+    $lines = @file($aFile,FILE_IGNORE_NEW_LINES|FILE_SKIP_EMPTY_LINES);
+    if( $lines === false ) {
+        throw new JpGraphException('Can not read sunspot data file.');
+    }
+    foreach( $lines as $line => $datarow ) {
+        $split = preg_split('/[\s]+/',$datarow);
+        $aYears[] = substr(trim($split[0]),0,4);
+        $aSunspots[] = trim($split[1]);
+    }
+}
+
+$year = array();
+$ydata = array();
+readsunspotdata('yearssn.txt',$year,$ydata);
+
+function year_callback($aLabel) {
+    return 1700+(int)$aLabel;
+}
+
+ // Width and height of the graph
+$width = 600; $height = 200;
+
+// Create a graph instance
+$graph = new Graph($width,$height);
+
+// Specify what scale we want to use,
+// int = integer scale for the X-axis
+// int = integer scale for the Y-axis
+$graph->SetScale('intint');
+
+// Setup a title for the graph
+$graph->title->Set('Sunspot example');
+
+// Setup titles and X-axis labels
+$graph->xaxis->title->Set('(year from 1701)');
+$graph->xaxis->SetLabelFormatCallback('year_callback');
+
+// Setup Y-axis title
+$graph->yaxis->title->Set('(# sunspots)');
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetFillColor('orange@0.5');
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/sunspotsex6.php b/web/classes/jpgraph/Examples/sunspotsex6.php
new file mode 100755
index 0000000000000000000000000000000000000000..2efe6448c49ef0e58a3da73477c1cfbd536ac7c4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/sunspotsex6.php
@@ -0,0 +1,52 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+function readsunspotdata($aFile, &$aYears, &$aSunspots) {
+
+    $lines = @file($aFile,FILE_IGNORE_NEW_LINES|FILE_SKIP_EMPTY_LINES);
+    if( $lines === false ) {
+        throw new JpGraphException('Can not read sunspot data file.');
+    }
+    foreach( $lines as $line => $datarow ) {
+        $split = preg_split('/[\s]+/',$datarow);
+        $aYears[] = substr(trim($split[0]),0,4);
+        $aSunspots[] = trim($split[1]);
+    }
+}
+
+$year = array();
+$ydata = array();
+readsunspotdata('yearssn.txt',$year,$ydata);
+
+ // Width and height of the graph
+$width = 600; $height = 200;
+
+// Create a graph instance
+$graph = new Graph($width,$height);
+
+// Specify what scale we want to use,
+// int = integer scale for the X-axis
+// int = integer scale for the Y-axis
+$graph->SetScale('intint');
+
+// Setup a title for the graph
+$graph->title->Set('Sunspot example');
+
+// Setup titles and X-axis labels
+$graph->xaxis->title->Set('(year from 1701)');
+
+// Setup Y-axis title
+$graph->yaxis->title->Set('(# sunspots)');
+
+// Create the bar plot
+$barplot=new BarPlot($ydata);
+
+// Add the plot to the graph
+$graph->Add($barplot);
+
+// Display the graph
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/sunspotsex7.php b/web/classes/jpgraph/Examples/sunspotsex7.php
new file mode 100755
index 0000000000000000000000000000000000000000..b104f9fee01c193a17fa39c9b6463aeb2a94723f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/sunspotsex7.php
@@ -0,0 +1,56 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+function readsunspotdata($aFile, &$aYears, &$aSunspots) {
+    $lines = @file($aFile,FILE_IGNORE_NEW_LINES|FILE_SKIP_EMPTY_LINES);
+    if( $lines === false ) {
+        throw new JpGraphException('Can not read sunspot data file.');
+    }
+    foreach( $lines as $line => $datarow ) {
+        $split = preg_split('/[\s]+/',$datarow);
+        $aYears[] = substr(trim($split[0]),0,4);
+        $aSunspots[] = trim($split[1]);
+    }
+}
+
+$year = array();
+$ydata = array();
+readsunspotdata('yearssn.txt',$year,$ydata);
+
+// Just keep the last 20 values in the arrays
+$year = array_slice($year, -20);
+$ydata = array_slice($ydata, -20);
+
+ // Width and height of the graph
+$width = 600; $height = 200;
+
+// Create a graph instance
+$graph = new Graph($width,$height);
+
+// Specify what scale we want to use,
+// text = txt scale for the X-axis
+// int = integer scale for the Y-axis
+$graph->SetScale('textint');
+
+// Setup a title for the graph
+$graph->title->Set('Sunspot example');
+
+// Setup titles and X-axis labels
+$graph->xaxis->title->Set('(year)');
+$graph->xaxis->SetTickLabels($year);
+
+// Setup Y-axis title
+$graph->yaxis->title->Set('(# sunspots)');
+
+// Create the bar plot
+$barplot=new BarPlot($ydata);
+
+// Add the plot to the graph
+$graph->Add($barplot);
+
+// Display the graph
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/table_flagex1.php b/web/classes/jpgraph/Examples/table_flagex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..8729561db055b782d7615b44a724ae7bc0e5efc4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_flagex1.php
@@ -0,0 +1,70 @@
+<?php
+include '../jpgraph.php';
+include '../jpgraph_canvas.php';
+include '../jpgraph_table.php';
+include '../jpgraph_iconplot.php';
+include '../jpgraph_flags.php';
+
+// Setup a basic canvas to use as graph to add the table
+$graph = new CanvasGraph(500,200);
+
+// Setup the basic table
+$data = array(
+    array('Areas'),
+    array(''),
+    array('','USA','UK','France','Denmark','Iceland','Canada'),
+    array('Feb',13,17,15,8,3,9),
+    array('Mar',34,35,26,20,22,16),
+    array('Apr',41,43,49,45,51,47),
+    array('Sum:',88,95,90,73,76,72));
+
+$countries = array('united states','united kingdom','french republic','denmark','iceland','canada');
+
+// Create a basic table and default fonr
+$table = new GTextTable();
+$table->Set($data);
+$table->SetFont(FF_TIMES,FS_NORMAL,11);
+
+// Adjust the font for row 0 and 6
+$table->SetColFont(0,FF_ARIAL,FS_BOLD,11);
+$table->SetRowFont(6,FF_TIMES,FS_BOLD,12);
+
+// Set the minimum heigth/width
+$table->SetMinRowHeight(2,10);
+$table->SetMinColWidth(70);
+
+// Add some padding (in pixels)
+$table->SetRowPadding(2,0);
+$table->SetRowGrid(6,1,'darkgray',TGRID_DOUBLE2);
+
+// Setup the grid
+$table->SetGrid(0);
+$table->SetRowGrid(6,1,'black',TGRID_DOUBLE2);
+
+// Merge all cells in row 0
+$table->MergeRow(0);
+
+// Set aligns
+$table->SetAlign(3,0,6,6,'right');
+$table->SetRowAlign(1,'center');
+$table->SetRowAlign(2,'center');
+
+// Set background colors
+$table->SetRowFillColor(0,'lightgray@0.5');
+$table->SetColFillColor(0,'lightgray@0.5');
+
+// Add the country flags in row 1
+$n = count($countries);
+for($i=0; $i < $n; ++$i ) {
+    $table->SetCellCountryFlag(1,$i+1,$countries[$i],0.5);
+    $table->SetCellImageConstrain(1,$i+1,TIMG_HEIGHT,20);
+}
+
+// Add the table to the graph
+$graph->Add($table);
+
+// Send back the table graph to the client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_howto1.php b/web/classes/jpgraph/Examples/table_howto1.php
new file mode 100755
index 0000000000000000000000000000000000000000..bb50fa035800d0ec035ad7c015ffc513de4628d4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_howto1.php
@@ -0,0 +1,21 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Create a canvas graph where the table can be added
+$graph = new CanvasGraph(70,50);
+
+// Setup the basic table
+$data = array( array(1,2,3,4),array(5,6,7,8));
+$table = new GTextTable();
+$table->Set($data);
+
+// Add the table to the graph
+$graph->Add($table);
+
+// ... and send back the table to the client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_howto2.php b/web/classes/jpgraph/Examples/table_howto2.php
new file mode 100755
index 0000000000000000000000000000000000000000..69d25e6b60e06a87c7d755508c45517cf58503b1
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_howto2.php
@@ -0,0 +1,25 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Create a canvas graph where the table can be added
+$graph = new CanvasGraph(70,50);
+
+// Setup the basic table
+$data = array( array(1,2,3,4),array(5,6,7,8));
+$table = new GTextTable();
+$table->Set($data);
+
+// Merge all cellsn in the rectangle with
+// top left corner = (0,2) and bottom right = (1,3)
+$table->MergeCells(0,2,1,3);
+
+// Add the table to the graph
+$graph->Add($table);
+
+// ... and send back the table to the client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_howto3.php b/web/classes/jpgraph/Examples/table_howto3.php
new file mode 100755
index 0000000000000000000000000000000000000000..26417b4a8525b230d2d437d45aa27d40f80ab4c1
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_howto3.php
@@ -0,0 +1,24 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Create a canvas graph where the table can be added
+$graph = new CanvasGraph(70,50);
+
+// Setup the basic table
+$data = array( array(1,2,3,4),array(5,6,7,8));
+$table = new GTextTable();
+$table->Set($data);
+
+// Merge all cells in row 0
+$table->MergeRow(0);
+
+// Add table to graph
+$graph->Add($table);
+
+// ... and send back the table to the client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_howto4.php b/web/classes/jpgraph/Examples/table_howto4.php
new file mode 100755
index 0000000000000000000000000000000000000000..d093fcb304c5854dac6af29181be4c22914e2140
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_howto4.php
@@ -0,0 +1,28 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Create a canvas graph where the table can be added
+$graph = new CanvasGraph(70,50);
+
+// Setup the basic table
+$data = array( array(1,2,3,4),array(5,6,7,8));
+$table = new GTextTable();
+$table->Set($data);
+
+// Merge all cells in row 0
+$table->MergeRow(0);
+
+// Set foreground and background color
+$table->SetCellFillColor(0,0,'orange@0.7');
+$table->SetCellColor(0,0,'darkred');
+
+// Add the table to the graph
+$graph->Add($table);
+
+// and send it back to the client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_howto5.php b/web/classes/jpgraph/Examples/table_howto5.php
new file mode 100755
index 0000000000000000000000000000000000000000..252318af4ed13855fc8efca9a6c3d7b48d07edb7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_howto5.php
@@ -0,0 +1,30 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Create a canvas graph where the table can be added
+$graph = new CanvasGraph(70,60);
+
+// Setup the basic table
+$data = array( array(1,2,3,4),array(5,6,7,8));
+$table = new GTextTable();
+$table->Set($data);
+
+// Merge all cells in row 0
+$table->MergeRow(0);
+
+// Adjust font in cell (0,0)
+$table->SetCellFont(0,0,FF_ARIAL,FS_BOLD,14);
+
+// Set left align for all cells in rectangle (0,0) - (0,3)
+$table->SetAlign(0,0,0,3,'Left');
+
+// Add table to graph
+$graph->Add($table);
+
+// ... send it back to the client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_howto6.php b/web/classes/jpgraph/Examples/table_howto6.php
new file mode 100755
index 0000000000000000000000000000000000000000..c776494ed38f20f5c3c351af0041fdc1c2377a2c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_howto6.php
@@ -0,0 +1,32 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Create a canvas graph where the table can be added
+$graph = new CanvasGraph(150,60);
+
+// Setup the basic table
+$data = array( array(1,2,3,4),array(5,6,7,8));
+$table = new GTextTable();
+$table->Set($data);
+
+// Merge all cells in row 0
+$table->MergeRow(0);
+
+// Setup font and color
+$table->SetCellFont(0,0,FF_ARIAL,FS_BOLD,14);
+$table->SetRowFillColor(0,'orange@0.5');
+$table->SetRowColor(0,'darkred');
+
+// Setup the minimum width of all columns
+$table->SetMinColWidth(35);
+
+// Add table to the graph
+$graph->Add($table);
+
+// ... send it back to the client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_howto7.1.php b/web/classes/jpgraph/Examples/table_howto7.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..4dbe52d73d8782b14c351b43efda9fdd5698ffaa
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_howto7.1.php
@@ -0,0 +1,34 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Create a canvas graph where the table can be added
+$graph = new CanvasGraph(150,90);
+
+// Setup the basic table
+$data = array( array(1,2,3,4),array(5,6,7,8), array(6,8,10,12));
+$table = new GTextTable();
+$table->Set($data);
+
+// Set default font in entire table
+$table->SetFont(FF_ARIAL,FS_NORMAL,11);
+
+// Setup font and color for row = 2
+$table->SetRowFont(2,FF_ARIAL,FS_BOLD,11);
+$table->SetRowFillColor(2,'orange@0.5');
+
+// Setup minimum color width
+$table->SetMinColWidth(35);
+
+// Setup grid on row 2
+$table->SetRowGrid(2,1,'black',TGRID_DOUBLE);
+
+// Add table to the graph
+$graph->Add($table);
+
+// and send it back to the client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_howto7.2.php b/web/classes/jpgraph/Examples/table_howto7.2.php
new file mode 100755
index 0000000000000000000000000000000000000000..8a159f8aa2541f9f11b34a3aa07f3dfc4c1ab8b8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_howto7.2.php
@@ -0,0 +1,34 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Create a canvas graph where the table can be added
+$graph = new CanvasGraph(150,90);
+
+// Setup the basic table
+$data = array( array(1,2,3,4),array(5,6,7,8), array(6,8,10,12));
+$table = new GTextTable();
+$table->Set($data);
+
+// Set default font in entire table
+$table->SetFont(FF_ARIAL,FS_NORMAL,11);
+
+// Setup font and color for row = 2
+$table->SetRowFont(2,FF_ARIAL,FS_BOLD,11);
+$table->SetRowFillColor(2,'orange@0.5');
+
+// Setup minimum color width
+$table->SetMinColWidth(35);
+
+// Setup grid on row 2
+$table->SetRowGrid(2,1,'black',TGRID_DOUBLE2);
+
+// Add table to the graph
+$graph->Add($table);
+
+// and send it back to the client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_howto7.php b/web/classes/jpgraph/Examples/table_howto7.php
new file mode 100755
index 0000000000000000000000000000000000000000..8a159f8aa2541f9f11b34a3aa07f3dfc4c1ab8b8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_howto7.php
@@ -0,0 +1,34 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Create a canvas graph where the table can be added
+$graph = new CanvasGraph(150,90);
+
+// Setup the basic table
+$data = array( array(1,2,3,4),array(5,6,7,8), array(6,8,10,12));
+$table = new GTextTable();
+$table->Set($data);
+
+// Set default font in entire table
+$table->SetFont(FF_ARIAL,FS_NORMAL,11);
+
+// Setup font and color for row = 2
+$table->SetRowFont(2,FF_ARIAL,FS_BOLD,11);
+$table->SetRowFillColor(2,'orange@0.5');
+
+// Setup minimum color width
+$table->SetMinColWidth(35);
+
+// Setup grid on row 2
+$table->SetRowGrid(2,1,'black',TGRID_DOUBLE2);
+
+// Add table to the graph
+$graph->Add($table);
+
+// and send it back to the client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_howto8.php b/web/classes/jpgraph/Examples/table_howto8.php
new file mode 100755
index 0000000000000000000000000000000000000000..a89785b3ffd1dc24acd343df6f5783b8eb4a531b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_howto8.php
@@ -0,0 +1,43 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Create a canvas graph where the table can be added
+$graph = new CanvasGraph(150,90);
+
+// Setup the basic table
+$data = array( array(1,2,3,4),array(5,6,7,8), array(6,8,10,12));
+$table = new GTextTable();
+$table->Set($data);
+
+// Setup overall table font
+$table->SetFont(FF_ARIAL,FS_NORMAL,11);
+
+// Setup font and color for row = 2
+$table->SetRowFont(2,FF_ARIAL,FS_BOLD,11);
+$table->SetRowFillColor(2,'orange@0.5');
+
+// Setup minimum color width
+$table->SetMinColWidth(35);
+
+// Setup overall cell alignment for the table
+$table->SetAlign('right');
+
+// Setup overall table border
+$table->SetBorder(0,'black');
+
+// Setup overall table grid
+$table->setGrid(0,'black');
+
+// Set specific frid for row = 2
+$table->SetRowGrid(2,1,'black',TGRID_DOUBLE2);
+
+// Add the table to the graph
+$graph->Add($table);
+
+// and send it back to the browser
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_howto9.php b/web/classes/jpgraph/Examples/table_howto9.php
new file mode 100755
index 0000000000000000000000000000000000000000..cf6f65f457725b4a48440be384264ddab6c1ae1d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_howto9.php
@@ -0,0 +1,46 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Setup graph context
+$graph = new CanvasGraph(165,90);
+
+// Setup the basic table
+$data = array( array(1,2,3,4),array(5,6,7,8), array(6,8,10,12));
+$table = new GTextTable();
+$table->Set($data);
+
+// Setup overall table font
+$table->SetFont(FF_ARIAL,FS_NORMAL,11);
+
+// Setup font and color for row = 2
+$table->SetRowFont(2,FF_ARIAL,FS_BOLD,11);
+$table->SetRowFillColor(2,'orange@0.5');
+
+// Setup minimum color width
+$table->SetMinColWidth(40);
+
+// Setup overall cell alignment for the table
+$table->SetAlign('right');
+
+// Setup overall table border
+$table->SetBorder(0,'black');
+
+// Setup overall table grid
+$table->setGrid(0,'black');
+
+// Set specific frid for row = 2
+$table->SetRowGrid(2,1,'black',TGRID_DOUBLE2);
+
+// Setup overall number format in all cells
+$table->SetNumberFormat("%0.1f");
+
+// Add table to the graph
+$graph->Add($table);
+
+// and send it back to the browser
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_mex0.php b/web/classes/jpgraph/Examples/table_mex0.php
new file mode 100755
index 0000000000000000000000000000000000000000..9568874e80fc96875d5aca719678174a07407346
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_mex0.php
@@ -0,0 +1,50 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Setup graph context
+$graph = new CanvasGraph(430,150);
+
+// Setup the basic table
+$data = array(
+    array('',        'w631','w632','w633','w634','w635','w636'),
+    array('Critical (sum)',13,17,15,8,3,9),
+    array('High (sum)',34,35,26,20,22,16),
+    array('Low (sum)',41,43,49,45,51,47),
+    array('Sum:',88,95,90,73,76,72)
+    );
+
+// Setup a basic table
+$table = new GTextTable();
+$table->Set($data);
+
+// Setup fonts
+$table->SetFont(FF_TIMES,FS_NORMAL,11);
+$table->SetColFont(0,FF_ARIAL,FS_NORMAL,11);
+$table->SetRowFont(0,FF_ARIAL,FS_NORMAL,11);
+$table->SetRowFont(4,FF_TIMES,FS_BOLD,14);
+
+// Turn off the grid
+$table->SetGrid(0);
+
+// Setup color
+$table->SetRowFillColor(0,'lightgray@0.5');
+$table->SetRowFillColor(4,'lightgray@0.5');
+$table->SetColFillColor(0,'lightgray@0.5');
+$table->SetFillColor(0,0,4,0,'lightgray@0.5');
+
+// Set default minimum column width
+$table->SetMinColWidth(45);
+
+// Set default table alignment
+$table->SetAlign('right');
+
+// Add table to the graph
+$graph->Add($table);
+
+// and send it back to the client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_mex00.php b/web/classes/jpgraph/Examples/table_mex00.php
new file mode 100755
index 0000000000000000000000000000000000000000..ecd7410d7b0c3235a46597722e6f2b4f8e52fd26
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_mex00.php
@@ -0,0 +1,33 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Setup graph context
+$graph = new CanvasGraph(430,150);
+
+// Setup the basic table
+$data = array(
+    array('',        'w631','w632','w633','w634','w635','w636'),
+    array('Critical (sum)',13,17,15,8,3,9),
+    array('High (sum)',34,35,26,20,22,16),
+    array('Low (sum)',41,43,49,45,51,47),
+    array('Sum:',88,95,90,73,76,72)
+    );
+
+// Setup the basic table and font
+$table = new GTextTable();
+$table->Set($data);
+$table->SetFont(FF_TIMES,FS_NORMAL,11);
+
+// Set default table alignment
+$table->SetAlign('right');
+
+// Add table to graph
+$graph->Add($table);
+
+// and send it back to the client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_mex1.php b/web/classes/jpgraph/Examples/table_mex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..ce40d0e774c0c35907f855c21523c827ab92e968
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_mex1.php
@@ -0,0 +1,56 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Setup graph context
+$graph = new CanvasGraph(430,150);
+
+// Setup the basic table
+$data = array(
+    array('', 'w631', 'w632', 'w633', 'w634', 'w635', 'w636'),
+    array('Critical (sum)',13,17,15,8,3,9),
+    array('High (sum)',34,35,26,20,22,16),
+    array('Low (sum)',41,43,49,45,51,47),
+    array('Sum',88,95,90,73,76,72)
+    );
+
+// Setup the basic table and font
+$table = new GTextTable();
+$table->Set($data);
+$table->SetFont(FF_ARIAL,FS_NORMAL,11);
+
+// Setup default column width
+$table->SetMinColWidth(40);
+
+// Setup defalt table alignment
+$table->SetAlign('right');
+
+// Turn off border
+$table->SetBorder(0);
+
+// Turn off grid
+$table->setGrid(0);
+
+// Setup font for row 4 and 0
+$table->SetRowFont(4,FF_ARIAL,FS_BOLD,11);
+$table->SetRowFont(0,FF_ARIAL,FS_BOLD,11);
+
+// Setup color
+$table->SetRowFillColor(4,'orange@0.5');
+$table->SetFillColor(0,1,0,6,'teal@0.8');
+
+
+// Setup grids
+$table->SetRowGrid(4,1,'black',TGRID_DOUBLE2);
+$table->SetColGrid(1,1,'black',TGRID_SINGLE);
+$table->SetRowGrid(1,1,'black',TGRID_SINGLE);
+
+// Add table to the graph
+$graph->Add($table);
+
+// Send it back to the client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_mex2.php b/web/classes/jpgraph/Examples/table_mex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..a4acc9d8013a68211a5102d8fa6d03a8f192c7cf
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_mex2.php
@@ -0,0 +1,58 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Setup graph context
+$graph = new CanvasGraph(430,150);
+
+// Setup the basic table
+$data = array(
+    array('',        'w631','w632','w633','w634','w635','w636'),
+    array('Critical (sum)',13,17,15,8,3,9),
+    array('High (sum)',34,35,26,20,22,16),
+    array('Low (sum)',41,43,49,45,51,47),
+    array('Sum:',88,95,90,73,76,72)
+    );
+
+// Setup the basic table and font
+$table = new GTextTable();
+$table->Set($data);
+$table->SetFont(FF_ARIAL,FS_NORMAL,11);
+
+// Set default minimum color width
+$table->SetMinColWidth(40);
+
+// Set default table alignment
+$table->SetAlign('right');
+
+// Set table border
+$table->SetBorder(0);
+
+// Turn off grid
+$table->setGrid(0);
+
+// Setup font
+$table->SetRowFont(4,FF_ARIAL,FS_BOLD,11);
+$table->SetRowFont(0,FF_ARIAL,FS_BOLD,11);
+
+// Setup various grid lines
+$table->SetRowGrid(4,2,'black',TGRID_SINGLE);
+$table->SetColGrid(1,3,'black',TGRID_SINGLE);
+$table->SetRowGrid(1,1,'black',TGRID_SINGLE);
+
+// Setup various colors
+$table->SetFillColor(0,1,0,6,'black');
+$table->SetRowColor(0,'white');
+$table->SetRowFillColor(4,'lightyellow');
+$table->SetFillColor(2,0,2,6,'lightgray');
+
+// Add table to the graph
+$graph->Add($table);
+
+
+// Send back to client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_mex3.php b/web/classes/jpgraph/Examples/table_mex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..981181c47705a36f17aa6cc8bdaebe6d7f755d4e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_mex3.php
@@ -0,0 +1,59 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Setup graph context
+$graph = new CanvasGraph(430,150);
+
+// Setup the basic table
+$data = array(
+    array('',        'w631','w632','w633','w634','w635','w636'),
+    array('Critical (sum)',13,17,15,8,3,9),
+    array('High (sum)',34,35,26,20,22,16),
+    array('Low (sum)',41,43,49,45,51,47),
+    array('Sum:',88,95,90,73,76,72),
+    );
+
+// Setup the basic table and font
+$table = new GTextTable();
+$table->Set($data);
+$table->SetFont(FF_ARIAL,FS_NORMAL,11);
+
+// Set default minimum color width
+$table->SetMinColWidth(40);
+
+// Set default table alignment
+$table->SetAlign('right');
+
+// Turn off grid
+$table->setGrid(0);
+
+// Set table border
+$table->SetBorder(2);
+
+// Setup font
+$table->SetRowFont(4,FF_ARIAL,FS_BOLD,11);
+$table->SetRowFont(0,FF_ARIAL,FS_BOLD,11);
+$table->SetFont(1,2,1,3,FF_ARIAL,FS_BOLD,11);
+
+// Setup grids
+$table->SetRowGrid(4,2,'black',TGRID_SINGLE);
+$table->SetColGrid(1,1,'black',TGRID_SINGLE);
+$table->SetRowGrid(1,1,'black',TGRID_SINGLE);
+
+// Setup colors
+$table->SetFillColor(0,1,0,6,'black');
+$table->SetRowColor(0,'white');
+$table->SetRowFillColor(4,'lightgray@0.3');
+$table->SetFillColor(2,0,2,6,'lightgray@0.6');
+$table->SetFillColor(1,2,1,3,'lightred');
+
+// Add table to graph
+$graph->Add($table);
+
+// Send back to the client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_vtext.php b/web/classes/jpgraph/Examples/table_vtext.php
new file mode 100755
index 0000000000000000000000000000000000000000..1b2b349ae321aac05a61f4e7310f6d0c86f9865c
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_vtext.php
@@ -0,0 +1,42 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Setup a basic canvas graph context
+$graph = new CanvasGraph(630,600);
+
+// Setup the basic table
+$data = array(
+    array('GROUP 1O',        'w631','w632','w633','w634','w635','w636'),
+    array('Critical (sum)',13,17,15,8,3,9),
+    array('High (sum)',34,35,26,20,22,16),
+    array('Low (sum)',41,43,49,45,51,47),
+    array('Sum:',88,95,90,73,76,72)
+    );
+
+// Setup a basic table
+$table = new GTextTable();
+$table->Set($data);
+$table->SetAlign('right');
+$table->SetFont(FF_TIMES,FS_NORMAL,12);
+$table->SetCellFont(0,0,FF_ARIAL,FS_BOLD,16);
+
+// Rotate the entire table 90 degrees
+$table->SetTextOrientation(90);
+//$table->SetCellTextOrientation(0,0,0);
+
+// Setup background color for header column
+$table->SetColFillColor(0,'lightgray');
+
+// Set the imnimum row height
+$table->SetMinRowHeight(0,150);
+
+// Add table to graph
+$graph->Add($table);
+
+// and send it back to the client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/table_vtext_ex1.php b/web/classes/jpgraph/Examples/table_vtext_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..9581884b323ca7ac13b983e14349d3bf76b06ed6
--- /dev/null
+++ b/web/classes/jpgraph/Examples/table_vtext_ex1.php
@@ -0,0 +1,42 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+// Setup a basic canvas graph context
+$graph = new CanvasGraph(430,600);
+
+// Setup the basic table
+$data = array(
+    array('GROUP 1O',        'w631','w632','w633','w634','w635','w636'),
+    array('Critical (sum)',13,17,15,8,3,9),
+    array('High (sum)',34,35,26,20,22,16),
+    array('Low (sum)',41,43,49,45,51,47),
+    array('Sum:',88,95,90,73,76,72)
+    );
+
+// Setup the basic table and default font
+$table = new GTextTable();
+$table->Set($data);
+$table->SetFont(FF_TIMES,FS_NORMAL,11);
+
+// Default table alignment
+$table->SetAlign('right');
+
+// Adjust font in (0,0)
+$table->SetCellFont(0,0,FF_TIMES,FS_BOLD,14);
+
+// Rotate all textxs in row  0
+$table->SetRowTextOrientation(0,90);
+
+// Adjust alignment in cell (0,0)
+$table->SetCellAlign(0,0,'center','center');
+
+// Add table to graph
+$graph->Add($table);
+
+// Send back table to client
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/tablebarex1.php b/web/classes/jpgraph/Examples/tablebarex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..7956716422477e35cc62f941e79adcf2ce0410e0
--- /dev/null
+++ b/web/classes/jpgraph/Examples/tablebarex1.php
@@ -0,0 +1,70 @@
+<?php
+include ("../jpgraph.php");
+include ("../jpgraph_bar.php");
+include ("../jpgraph_table.php");
+
+$datay = array(
+    array('Jan','Feb','Mar','Apr','May','Jun'),
+    array(12,18,19,7,17,6),
+    array(3,5,2,7,5,25),
+    array(6,1.5,2.4,2.1,6.9,12.3))
+;
+
+// Some basic defines to specify the shape of the bar+table
+$nbrbar = 6;
+$cellwidth = 50;
+$tableypos = 200;
+$tablexpos = 60;
+$tablewidth = $nbrbar*$cellwidth;
+$rightmargin = 30;
+
+// Overall graph size
+$height = 320;
+$width = $tablexpos+$tablewidth+$rightmargin;
+
+// Create the basic graph. 
+$graph = new Graph($width,$height);	
+$graph->img->SetMargin($tablexpos,$rightmargin,30,$height-$tableypos);
+$graph->SetScale("textlin");
+$graph->SetMarginColor('white');
+
+// Setup titles and fonts
+$graph->title->Set('Bar and table');
+$graph->title->SetFont(FF_VERDANA,FS_NORMAL,14);
+$graph->yaxis->title->Set("Flow");
+$graph->yaxis->title->SetFont(FF_ARIAL,FS_NORMAL,12);
+$graph->yaxis->title->SetMargin(10);
+
+// Create the bars and the accbar plot
+$bplot = new BarPlot($datay[3]);
+$bplot->SetFillColor("orange");
+$bplot2 = new BarPlot($datay[2]);
+$bplot2->SetFillColor("red");
+$bplot3 = new BarPlot($datay[1]);
+$bplot3->SetFillColor("darkgreen");
+$accbplot = new AccBarPlot(array($bplot,$bplot2,$bplot3));
+$accbplot->value->Show();
+$graph->Add($accbplot);
+
+//Setup the table
+$table = new GTextTable();
+$table->Set($datay);
+$table->SetPos($tablexpos,$tableypos+1);
+
+// Basic table formatting
+$table->SetFont(FF_ARIAL,FS_NORMAL,10);
+$table->SetAlign('right');
+$table->SetMinColWidth($cellwidth);
+$table->SetNumberFormat('%0.1f');
+
+// Format table header row
+$table->SetRowFillColor(0,'teal@0.7');
+$table->SetRowFont(0,FF_ARIAL,FS_BOLD,11);
+$table->SetRowAlign(0,'center');
+
+// .. and add it to the graph
+$graph->Add($table);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/tablebarex1_csim.php b/web/classes/jpgraph/Examples/tablebarex1_csim.php
new file mode 100755
index 0000000000000000000000000000000000000000..96061493724a612d5f12d4e3adc7c27d0856cb7d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/tablebarex1_csim.php
@@ -0,0 +1,72 @@
+<?php
+include ("../jpgraph.php");
+include ("../jpgraph_bar.php");
+include ("../jpgraph_table.php");
+
+$datay = array(
+    array('Jan','Feb','Mar','Apr','May','Jun'),
+    array(12,18,19,7,17,6),
+    array(3,5,2,7,5,25),
+    array(6,1.5,2.4,2.1,6.9,12.3))
+;
+
+// Some basic defines to specify the shape of the bar+table
+$nbrbar = 6;
+$cellwidth = 50;
+$tableypos = 200;
+$tablexpos = 60;
+$tablewidth = $nbrbar*$cellwidth;
+$rightmargin = 30;
+
+// Overall graph size
+$height = 320;
+$width = $tablexpos+$tablewidth+$rightmargin;
+
+// Create the basic graph. 
+$graph = new Graph($width,$height);	
+$graph->img->SetMargin($tablexpos,$rightmargin,30,$height-$tableypos);
+$graph->SetScale("textlin");
+$graph->SetMarginColor('white');
+
+// Setup titles and fonts
+$graph->title->Set('Bar and table');
+$graph->title->SetFont(FF_VERDANA,FS_NORMAL,14);
+$graph->yaxis->title->Set("Flow");
+$graph->yaxis->title->SetFont(FF_ARIAL,FS_NORMAL,12);
+$graph->yaxis->title->SetMargin(10);
+
+// Create the bars and the accbar plot
+$bplot = new BarPlot($datay[3]);
+$bplot->SetFillColor("orange");
+$bplot2 = new BarPlot($datay[2]);
+$bplot2->SetFillColor("red");
+$bplot3 = new BarPlot($datay[1]);
+$bplot3->SetFillColor("darkgreen");
+$accbplot = new AccBarPlot(array($bplot,$bplot2,$bplot3));
+$accbplot->value->Show();
+$graph->Add($accbplot);
+
+//Setup the table
+$table = new GTextTable();
+$table->Set($datay);
+$table->SetPos($tablexpos,$tableypos+1);
+
+$table->SetCellCSIMTarget(1,1,'tableex02.php','View details');
+
+// Basic table formatting
+$table->SetFont(FF_ARIAL,FS_NORMAL,10);
+$table->SetAlign('right');
+$table->SetMinColWidth($cellwidth);
+$table->SetNumberFormat('%0.1f');
+
+// Format table header row
+$table->SetRowFillColor(0,'teal@0.7');
+$table->SetRowFont(0,FF_ARIAL,FS_BOLD,11);
+$table->SetRowAlign(0,'center');
+
+// .. and add it to the graph
+$graph->Add($table);
+
+$graph->StrokeCSIM();
+
+?>
diff --git a/web/classes/jpgraph/Examples/tableex00.php b/web/classes/jpgraph/Examples/tableex00.php
new file mode 100755
index 0000000000000000000000000000000000000000..0acabaed2e3f318b84bd62ef017b9a271c1c3743
--- /dev/null
+++ b/web/classes/jpgraph/Examples/tableex00.php
@@ -0,0 +1,25 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+$cols = 4;
+$rows = 3;
+$data = array( array('','Jan','Feb','Mar','Apr'),
+	       array('Min','15.2', '12.5', '9.9', '70.0'),
+	       array('Max','23.9', '14.2', '18.6', '71.3'));
+
+// Create a basic graph context
+$graph = new CanvasGraph(300,200);
+
+// Create a basic table
+$table = new GTextTable($cols,$rows);
+$table->Set($data);
+
+//Add table to the graph
+$graph->Add($table);
+
+// Send back table to the client
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/tableex01.php b/web/classes/jpgraph/Examples/tableex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..8efe9f9f513f7f9f2fb57f34895c4b7f72b9074e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/tableex01.php
@@ -0,0 +1,29 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+$cols = 4;
+$rows = 3;
+$data = array( array('','Jan','Feb','Mar','Apr'),
+	       array('Min','15.2', '12.5', '9.9', '70.0'),
+	       array('Max','23.9', '14.2', '18.6', '71.3'));
+
+$graph = new CanvasGraph(300,200);
+
+$table = new GTextTable($cols,$rows);
+$table->Init();
+$table->Set($data);
+
+$table->SetRowFont(0,FF_FONT1,FS_BOLD);
+$table->SetRowColor(0,'navy');
+$table->SetRowFillColor(0,'lightgray');
+
+$table->SetColFont(0,FF_FONT1,FS_BOLD);
+$table->SetColColor(0,'navy');
+$table->SetColFillColor(0,'lightgray');
+
+$graph->Add($table);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/tableex01_csim.php b/web/classes/jpgraph/Examples/tableex01_csim.php
new file mode 100755
index 0000000000000000000000000000000000000000..ff11a70b8ebac63f9f31925eadbd1073976e1cfc
--- /dev/null
+++ b/web/classes/jpgraph/Examples/tableex01_csim.php
@@ -0,0 +1,33 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+$cols = 4;
+$rows = 3;
+$data = array( array('','Jan','Feb','Mar','Apr'),
+	       array('Min','15.2', '12.5', '9.9', '70.0'),
+	       array('Max','23.9', '14.2', '18.6', '71.3'));
+
+// Setup basic graph canvas
+$graph = new CanvasGraph(300,200);
+
+// Create a basic table
+$table = new GTextTable($cols,$rows);
+$table->Set($data);
+
+$table->SetCellCSIMTarget(1,1,'tableex02.php','View details');
+
+$table->SetRowFont(0,FF_FONT1,FS_BOLD);
+$table->SetRowColor(0,'navy');
+$table->SetRowFillColor(0,'lightgray');
+
+$table->SetColFont(0,FF_FONT1,FS_BOLD);
+$table->SetColColor(0,'navy');
+$table->SetColFillColor(0,'lightgray');
+
+$graph->Add($table);
+
+$graph->StrokeCSIM();
+
+?>
diff --git a/web/classes/jpgraph/Examples/tableex02.php b/web/classes/jpgraph/Examples/tableex02.php
new file mode 100755
index 0000000000000000000000000000000000000000..193f49f179423a079754faf2e40ecd90cbad130d
--- /dev/null
+++ b/web/classes/jpgraph/Examples/tableex02.php
@@ -0,0 +1,33 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+$cols = 4;
+$rows = 3;
+$data = array( array('','Jan','Feb','Mar','Apr'),
+	       array('Min','15.2', '12.5', '9.9', '70.0'),
+	       array('Max','23.9', '14.2', '18.6', '71.3'));
+
+$graph = new CanvasGraph(300,200);
+
+$table = new GTextTable($cols,$rows);
+$table->Init();
+$table->Set($data);
+
+// Setup row and column headers
+$table->SetRowFont(0,FF_TIMES,FS_BOLD,11);
+$table->SetRowAlign(0,'left','bottom');
+$table->SetRowColor(0,'navy');
+$table->SetRowFillColor(0,'lightgray');
+$table->SetColFont(0,FF_ARIAL,FS_BOLD,11);
+$table->SetColColor(0,'navy');
+$table->SetColFillColor(0,'lightgray');
+
+// Highlight cell 2,3
+$table->SetCellFillColor(2,3,'yellow');
+
+$graph->Add($table);
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/tableex03.php b/web/classes/jpgraph/Examples/tableex03.php
new file mode 100755
index 0000000000000000000000000000000000000000..5ac72151e106d12a3ec3532a3c8aa1884a5cda6b
--- /dev/null
+++ b/web/classes/jpgraph/Examples/tableex03.php
@@ -0,0 +1,58 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+$cols = 4;
+$rows = 3;
+$data = array( array('2007'),
+               array('','Q1','','','Q2'),
+	       array('','Jan','Feb','Mar','Apr','May','Jun'),
+	       array('Min','15.2', '12.5', '9.9', '70.0', '22.4','21.5'),
+	       array('Max','23.9', '14.2', '18.6', '71.3','66.8','42.6'));
+
+$q=1;
+
+$graph = new CanvasGraph(350,200);
+
+$table = new GTextTable($cols,$rows);
+$table->Init();
+$table->Set($data);
+$table->SetBorder(2,'black');
+
+// Setup top row with the year title
+$table->MergeCells(0,0,0,6);
+$table->SetRowFont(0,FF_ARIAL,FS_BOLD,16);
+$table->SetRowColor(0,'navy');
+$table->SetRowAlign(0,'center');
+
+// Setup quarter header
+$table->MergeCells(1,1,1,3);
+$table->MergeCells(1,4,1,6);
+$table->SetRowAlign(1,'center');
+$table->SetRowFont(1,FF_ARIAL,FS_BOLD,10);
+$table->SetRowColor(1,'navy');
+$table->SetRowFillColor(1,'lightgray');
+$table->SetRowGrid(2,'',0); // Turn off the gridline just under the top row
+
+// Setup row and column headers
+$table->SetRowFont(2,FF_ARIAL,FS_NORMAL,11);
+$table->SetRowColor(2,'navy');
+$table->SetRowFillColor(2,'lightgray');
+
+$table->SetColFont(0,FF_ARIAL,FS_NORMAL,11);
+$table->SetColColor(0,'navy');
+$table->SetColFillColor(0,'lightgray');
+
+$table->SetCellFillColor(0,0,'lightgreen');
+$table->SetCellFillColor(1,0,'lightgreen');
+$table->SetCellFillColor(2,0,'lightgreen');
+
+// Highlight cell 2,3
+$table->SetCellFillColor(4,3,'yellow');
+
+$graph->Add($table);
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/tableex04.php b/web/classes/jpgraph/Examples/tableex04.php
new file mode 100755
index 0000000000000000000000000000000000000000..21f540d38b6c1ea352f5d6efb5c77b7c994e9ddd
--- /dev/null
+++ b/web/classes/jpgraph/Examples/tableex04.php
@@ -0,0 +1,50 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+$data = array( array('','Jan','Feb','Mar','Apr','May','Jun'),
+	       array('Team 1','15.2', '12.5', '9.9', '70.0', '22.4','21.5'),
+	       array('Team 2','23.9', '14.2', '18.6', '71.3','66.8','42.6'),
+	       array('Sum:')
+);
+
+$r = count($data);
+$c = 7;
+
+for( $i=1; $i < $c; ++$i ) {
+    $tmp=0;
+    for($j=1; $j < $r-1; ++$j) {
+	$tmp += $data[$j][$i];
+    }
+    $data[3][$i] = sprintf('%2.1f',$tmp);;
+}
+
+
+$graph = new CanvasGraph(350,200);
+
+$table = new GTextTable();
+$table->Init();
+$table->Set($data);
+$table->SetBorder(2,'black');
+
+// Highlight summation row
+$table->SetRowFillColor($r-1,'yellow');
+$table->SetCellAlign($r-1,0,'right');
+
+// Setup row and column headers
+$table->SetRowFont(0,FF_ARIAL,FS_NORMAL,10);
+$table->SetRowColor(0,'navy');
+$table->SetRowFillColor(0,'lightgray');
+
+$table->SetColFont(0,FF_ARIAL,FS_NORMAL,10);
+$table->SetColColor(0,'navy');
+$table->SetColFillColor(0,'lightgray');
+
+$table->SetRowGrid($r-1,1,'black',TGRID_DOUBLE);
+
+$graph->Add($table);
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/tableex05.php b/web/classes/jpgraph/Examples/tableex05.php
new file mode 100755
index 0000000000000000000000000000000000000000..aad9e00d585a1232e7decdfeee4475d46fc66489
--- /dev/null
+++ b/web/classes/jpgraph/Examples/tableex05.php
@@ -0,0 +1,53 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+require_once ('jpgraph/jpgraph_table.php');
+
+$data = array( array('','Jan','Feb','Mar','Apr','May','Jun'),
+	       array('Team 1','15.2', '12.5', '9.9', '70.0', '22.4','21.5'),
+	       array('Team 2','23.9', '14.2', '18.6', '71.3','66.8','42.6'),
+	       array('Sum:')
+);
+
+$r = count($data);
+$c = 7;
+
+for( $i=1; $i < $c; ++$i ) {
+    $tmp=0;
+    for($j=1; $j < $r-1; ++$j) {
+	$tmp += $data[$j][$i];
+    }
+    $data[3][$i] = sprintf('%2.1f',$tmp);;
+}
+
+$graph = new CanvasGraph(350,200);
+
+$table = new GTextTable();
+$table->Init();
+$table->Set($data);
+$table->SetBorder(2,'black');
+
+// Highlight summation row
+$table->SetRowFillColor($r-1,'yellow');
+$table->SetCellAlign($r-1,0,'right');
+
+// Setup row and column headers
+$table->SetRowFont(0,FF_ARIAL,FS_NORMAL,10);
+$table->SetRowColor(0,'navy');
+$table->SetRowFillColor(0,'lightgray');
+
+$table->SetColFont(0,FF_ARIAL,FS_NORMAL,10);
+$table->SetColColor(0,'navy');
+$table->SetColFillColor(0,'lightgray');
+
+$table->SetRowGrid($r-1,1,'black',TGRID_DOUBLE);
+
+$table->SetFont(1,4,2,6,FF_TIMES,FS_NORMAL,18);
+$table->SetFillColor(1,1,2,3,'red');
+
+$table->MergeCol(1);
+$graph->Add($table);
+$graph->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/tabtitleex1.php b/web/classes/jpgraph/Examples/tabtitleex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..55d87ea14606ea18cd009cebf60fff93cdbe2c0f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/tabtitleex1.php
@@ -0,0 +1,51 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$datay1 = array(20,15,23,15);
+$datay2 = array(12,9,42,8);
+$datay3 = array(5,17,32,24);
+
+// Setup the graph
+$graph = new Graph(300,200);
+$graph->SetMarginColor('white');
+$graph->SetScale("textlin");
+$graph->SetFrame(false);
+$graph->SetMargin(30,50,30,30);
+
+$graph->tabtitle->Set(' Year 2003 ' );
+$graph->tabtitle->SetFont(FF_ARIAL,FS_BOLD,13);
+
+
+$graph->yaxis->HideZeroLabel();
+$graph->ygrid->SetFill(true,'#EFEFEF@0.5','#BBCCFF@0.5');
+$graph->xgrid->Show();
+
+$graph->xaxis->SetTickLabels($gDateLocale->GetShortMonth());
+
+// Create the first line
+$p1 = new LinePlot($datay1);
+$p1->SetColor("navy");
+$p1->SetLegend('Line 1');
+$graph->Add($p1);
+
+// Create the second line
+$p2 = new LinePlot($datay2);
+$p2->SetColor("red");
+$p2->SetLegend('Line 2');
+$graph->Add($p2);
+
+// Create the third line
+$p3 = new LinePlot($datay3);
+$p3->SetColor("orange");
+$p3->SetLegend('Line 3');
+$graph->Add($p3);
+
+$graph->legend->SetShadow('gray@0.4',5);
+$graph->legend->SetPos(0.1,0.1,'right','top');
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/testsuit.php b/web/classes/jpgraph/Examples/testsuit.php
new file mode 100755
index 0000000000000000000000000000000000000000..4ffb28929afa7183590fb7b0f639f064c33fadcc
--- /dev/null
+++ b/web/classes/jpgraph/Examples/testsuit.php
@@ -0,0 +1,107 @@
+<?php // content="text/plain; charset=utf-8"
+//=======================================================================
+// File:	TESTSUIT.PHP
+// Description:	Run all the example script in current directory
+// Created: 	2002-07-11
+// Ver:		$Id: testsuit.php,v 1.1.2.1 2004/03/27 12:43:07 aditus Exp $
+//
+// License:	This code is released under QPL 1.0 
+// Copyright (C) 2001,2002 Johan Persson 
+//========================================================================
+
+//-------------------------------------------------------------------------
+//
+// Usage: testsuit.php[?type=1]    Generates all non image map scripts
+//        testsuit.php?type=2      Generates client side image map scripts 
+//       
+//-------------------------------------------------------------------------
+class TestDriver {
+    
+    private $iType;
+    private $iDir;
+
+    function TestDriver($aType=1,$aDir='') {
+	$this->iType = $aType;
+	if( $aDir == '' ) {
+	    $aDir = getcwd();
+	}
+	if( !chdir($aDir) ) {
+	    die("PANIC: Can't access directory : $aDir");
+	}
+	$this->iDir = $aDir;
+    }
+
+    function GetFiles() {
+	$d = @dir($this->iDir);
+	$a = array();
+	while( $entry=$d->Read() ) {
+	    if( strstr($entry,".php") && strstr($entry,"x") && !strstr($entry,"show") && !strstr($entry,"csim") ) {
+		$a[] = $entry;
+	    }
+	}
+	$d->Close();
+	if( count($a) == 0 ) {
+	    die("PANIC: Apache/PHP does not have enough permission to read the scripts in directory: $this->iDir");	    
+	}
+	sort($a);
+	return $a;
+    }
+
+    function GetCSIMFiles() {
+	$d = @dir($this->iDir);
+	$a = array();
+	while( $entry=$d->Read() ) {
+	    if( strstr($entry,".php") && strstr($entry,"csim") ) {
+		$a[] = $entry;
+	    }
+	}
+	$d->Close();
+	if( count($a) == 0 ) {
+	    die("PANIC: Apache/PHP does not have enough permission to read the CSIM scripts in directory: $this->iDir");	    
+	}
+	sort($a);
+	return $a;
+    }
+
+    
+    function Run() {
+	switch( $this->iType ) {
+	    case 1:
+		$files = $this->GetFiles();
+		break;
+	    case 2:
+		$files = $this->GetCSIMFiles();
+		break;
+	    default:
+		die('Panic: Unknown type of test');
+		break;
+	}
+	$n = count($files);
+	echo "<h2>Visual test suit for JpGraph</h2>";
+	echo "Testtype: " . ($this->iType==1 ? ' Standard images ':' Image map tests ');
+	echo "<br>Number of tests: $n<p>";
+	echo "<ol>";
+	
+	for( $i=0; $i<$n; ++$i ) {
+	    if( $this->iType ==1 ) {
+	    echo '<li><a href="show-example.php?target='.urlencode($files[$i]).'"><img src="'.$files[$i].'" border=0 align=top></a><br><strong>Filename:</strong> <i>'.basename($files[$i])."</i>\n";
+	    }
+	    else {
+		echo '<li><a href="show-example.php?target='.urlencode($files[$i]).'">'.$files[$i]."</a>\n";
+	    }
+	}
+	echo "</ol>";
+
+	echo "<p>Done.</p>";
+    }
+}
+
+$type=@$_GET['type'];
+if( empty($type) ) {
+    $type=1;
+}
+
+$driver = new TestDriver($type);
+$driver->Run();
+
+?>
diff --git a/web/classes/jpgraph/Examples/text-example1.php b/web/classes/jpgraph/Examples/text-example1.php
new file mode 100755
index 0000000000000000000000000000000000000000..99de8ffe8af43af68c6a873501a79e3832f5ab69
--- /dev/null
+++ b/web/classes/jpgraph/Examples/text-example1.php
@@ -0,0 +1,18 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+
+// Create the graph. 
+$graph = new CanvasGraph(350,200);	
+
+$t1 = new Text("This is a text with more text");
+$t1->SetPos(0.05,0.5);
+$t1->SetOrientation("h");
+$t1->SetFont(FF_FONT1,FS_NORMAL);
+$t1->SetBox("white","black",'gray');
+$t1->SetColor("black");
+$graph->AddText($t1);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/text-example2.php b/web/classes/jpgraph/Examples/text-example2.php
new file mode 100755
index 0000000000000000000000000000000000000000..b20cfa8e9dac222d12b8894bd00579cdb9e46116
--- /dev/null
+++ b/web/classes/jpgraph/Examples/text-example2.php
@@ -0,0 +1,18 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_canvas.php');
+
+// Create the graph. 
+$graph = new CanvasGraph(350,200);	
+
+$t1 = new Text("a good\nas you can see right now per see\nThis is a text with\nseveral lines\n");
+$t1->SetPos(0.05,100);
+$t1->SetFont(FF_FONT1,FS_NORMAL);
+$t1->SetBox("white","black",true);
+$t1->ParagraphAlign("right");
+$t1->SetColor("black");
+$graph->AddText($t1);
+
+$graph->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/Examples/textalignex1.php b/web/classes/jpgraph/Examples/textalignex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..a7b33c577a345722ddd14a08def360ca2f2d0aac
--- /dev/null
+++ b/web/classes/jpgraph/Examples/textalignex1.php
@@ -0,0 +1,91 @@
+<?php // content="text/plain; charset=utf-8"
+require_once "jpgraph/jpgraph.php";
+require_once "jpgraph/jpgraph_canvas.php";
+
+// We accept a URI argument to adjust the angle at what we display the text
+if( empty($_GET['a']) ) {
+    $angle=40;
+}
+else {
+    $angle=$_GET['a'];
+}
+
+// Caption below the image
+$caption = "Demonstration of different anchor points for texts as specified with\n".
+    "TextAlign(). The red cross marks the coordinate that was given to\n".
+    "stroke each instance of the string.\n(The green box is the bounding rectangle for the text.)";
+
+$txt="TextAlign()";
+
+
+// Initial width and height since we need a "dummy" canvas to
+// calculate the height of the text strings
+$w=480;$h=50;
+$xm=90;$ym=80;
+
+$g = new CanvasGraph($w,$h);
+
+// Make the image easier to access
+$img = $g->img;
+
+// Get the bounding box for text
+$img->SetFont(FF_ARIAL,FS_NORMAL,16);
+$tw=$img->GetBBoxWidth($txt,$angle);
+$th=$img->GetBBoxHeight($txt,$angle);
+
+$img->SetFont(FF_ARIAL,FS_NORMAL,11);
+$ch=$img->GetBBoxHeight($caption);
+
+// Calculate needed height for the image
+$h = 3*$th+2*$ym + $ch;
+$g = new CanvasGraph($w,$h);
+$img = $g->img;
+
+// Alignment for anchor points to use
+$anchors = array('left','top',
+              'center','top',
+              'right','top',
+              'left','center',
+              'center','center',
+              'right','center',
+              'left','bottom',
+              'center','bottom',
+              'right','bottom');
+
+$n = count($anchors)/2;
+
+for( $i=0,$r=0,$c=0; $i < $n; ++$i ) {
+
+    $x = $c*($tw+$xm)+$xm/2;
+    $y = $r*($th+$ym)+$ym/2-10;
+
+    $img->SetColor('blue');
+    $img->SetTextAlign($anchors[$i*2],$anchors[$i*2+1]);
+    $img->SetFont(FF_ARIAL,FS_NORMAL,16);
+    $img->StrokeText($x,$y,$txt,$angle,"left",true);
+
+    $img->SetColor('black');
+    $img->SetFont(FF_FONT1,FS_BOLD);
+    $img->SetTextAlign('center','top');
+    $align = sprintf('("%s","%s")',$anchors[$i*2],$anchors[$i*2+1]);
+    $img->StrokeText($c*($tw/2+$xm)+$xm/2+$tw/2,$r*($th/2+$ym)+$th+$ym/2-4,$align);
+
+    $c++;
+    if( $c==3 ) {
+        $c=0;$r++;
+    }
+}
+
+// Draw the caption text
+$img->SetTextAlign('center','bottom');
+$img->SetFont(FF_ARIAL,FS_ITALIC,11);
+$img->StrokeText($w/2,$h-10,$caption,0,'left');
+
+$img->SetColor('navy');
+$img->Rectangle(0,0,$w-1,$h-1);
+
+// .. and send back to browser
+$g->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/textpalignex1.php b/web/classes/jpgraph/Examples/textpalignex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..b4dfb36f07ce0bc4c1d1bb2d1dc8a4372cb1cdc7
--- /dev/null
+++ b/web/classes/jpgraph/Examples/textpalignex1.php
@@ -0,0 +1,44 @@
+<?php // content="text/plain; charset=utf-8"
+require_once "jpgraph/jpgraph.php";
+require_once "jpgraph/jpgraph_canvas.php";
+
+// Caption below the image
+$txt="The day was rapidly becoming more and\nmore strange.\n\nNot only had he managed to\nget by the first pass without so much as\na hint of questions but now when he\ncould feel that the second pass wouldn't\nlong be noone had yet seen him.";
+
+$w=950;$h=250;
+$xm=20;$ym=20;
+$tw=300;
+
+$g = new CanvasGraph($w,$h);
+$img = $g->img;
+
+// Alignment for anchor points to use
+$palign = array('left','center','right');
+
+$n = count($palign);
+$t = new Text($txt);
+
+$y = $ym;
+for( $i=0; $i < $n; ++$i ) {
+
+    $x = $xm + $i*$tw;
+
+    $t->SetColor('black');
+    $t->SetAlign('left','top');
+    $t->SetFont(FF_ARIAL,FS_NORMAL,11);
+    $t->SetBox();
+    $t->SetParagraphAlign($palign[$i]);
+    $t->Stroke($img, $x,$y);
+
+    $img->SetColor('black');
+    $img->SetFont(FF_FONT1,FS_BOLD);
+    $img->SetTextAlign('center','top');
+    $img->StrokeText($x+140,$y+160,'"'.$palign[$i].'"'.' pargraph align');
+
+}
+
+// .. and send back to browser
+$g->Stroke();
+
+?>
+
diff --git a/web/classes/jpgraph/Examples/theme_example.php b/web/classes/jpgraph/Examples/theme_example.php
new file mode 100755
index 0000000000000000000000000000000000000000..73d2da004cbddddb8130f6a81093a879e256f076
--- /dev/null
+++ b/web/classes/jpgraph/Examples/theme_example.php
@@ -0,0 +1,26 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$data1y=array(47,80,40,116);
+$graph = new Graph(400, 300, 'auto');
+$graph->SetScale('textlin');
+
+$theme_class = new AquaTheme;
+$graph->SetTheme($theme_class);
+
+// after setting theme, you can change details as you want
+$graph->SetFrame(true, 'lightgray');                        // set frame visible
+
+$graph->xaxis->SetTickLabels(array('A','B','C','D')); // change xaxis lagels
+$graph->title->Set("Theme Example");                    // add title
+
+// add barplot
+$bplot = new BarPlot($data1y);
+$graph->Add($bplot);
+
+// you can change properties of the plot only after calling Add()
+$bplot->SetWeight(0);
+$bplot->SetFillGradient('#FFAAAA:0.7', '#FFAAAA:1.2', GRAD_VER);    
+
+$graph->Stroke();
diff --git a/web/classes/jpgraph/Examples/tiger1.jpg b/web/classes/jpgraph/Examples/tiger1.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..99596101406fa259b88286f2d48033ac67e7a0ac
Binary files /dev/null and b/web/classes/jpgraph/Examples/tiger1.jpg differ
diff --git a/web/classes/jpgraph/Examples/tiger_bkg.gif b/web/classes/jpgraph/Examples/tiger_bkg.gif
new file mode 100755
index 0000000000000000000000000000000000000000..3faaa174dcf1cb1d07fadff28c88f134fe42cc1e
Binary files /dev/null and b/web/classes/jpgraph/Examples/tiger_bkg.gif differ
diff --git a/web/classes/jpgraph/Examples/tiger_bkg.jpg b/web/classes/jpgraph/Examples/tiger_bkg.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..43d45f30e8d3f7beffb1b501359e39bfd5dcbc4b
Binary files /dev/null and b/web/classes/jpgraph/Examples/tiger_bkg.jpg differ
diff --git a/web/classes/jpgraph/Examples/tiger_bkg.png b/web/classes/jpgraph/Examples/tiger_bkg.png
new file mode 100755
index 0000000000000000000000000000000000000000..78d8e25b0c44e565c7aacb811f5df5dec7c9667f
Binary files /dev/null and b/web/classes/jpgraph/Examples/tiger_bkg.png differ
diff --git a/web/classes/jpgraph/Examples/timestampex01.php b/web/classes/jpgraph/Examples/timestampex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..b2ee12e96a3f428a63addbb8a472c570f0c7b025
--- /dev/null
+++ b/web/classes/jpgraph/Examples/timestampex01.php
@@ -0,0 +1,59 @@
+<?php // content="text/plain; charset=utf-8"
+// Example on how to treat and format timestamp as human readable labels
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Number of "fake" data points
+DEFINE('NDATAPOINTS',500);
+
+// Assume data points are sample every 10th second
+DEFINE('SAMPLERATE',10); 
+
+// Callback formatting function for the X-scale to convert timestamps
+// to hour and minutes.
+function TimeCallback($aVal) {
+    return Date('H:i', $aVal);
+}
+
+// Get start time
+$start = time();
+// Set the start time to be on the closest minute just before the "start" timestamp
+$adjstart = floor($start / 60);
+
+// Create a data set in range (20,100) and X-positions
+// We also apply a simple low pass filter on the data to make it less
+// random and a little smoother
+$data = array();
+$xdata = array();
+$data[0] = rand(20,100);
+$xdata[0] = $adjstart;
+for( $i=1; $i < NDATAPOINTS; ++$i ) {
+    $data[$i] = rand(20,100)*0.2 + $data[$i-1]*0.8;
+    $xdata[$i] = $adjstart + $i * SAMPLERATE;
+}
+
+// Assume that the data points represents data that is sampled every 10s
+// when determing the end value on the scale. We also add some extra
+// length to end on an even label tick.
+$adjend = $adjstart  + (NDATAPOINTS+10)*10;
+
+$graph = new Graph(500,250);
+$graph->SetMargin(40,20,30,50);
+
+// Now specify the X-scale explicit but let the Y-scale be auto-scaled
+$graph->SetScale("intlin",0,0,$adjstart,$adjend);
+$graph->title->Set("Example on TimeStamp Callback");
+
+// Setup the callback and adjust the angle of the labels
+$graph->xaxis->SetLabelFormatCallback('TimeCallback');
+$graph->xaxis->SetLabelAngle(90);
+
+// Set the labels every 5min (i.e. 300seconds) and minor ticks every minute
+$graph->xaxis->scale->ticks->Set(300,60);
+
+$line = new LinePlot($data,$xdata);
+$line->SetColor('lightblue');
+$graph->Add($line);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/titlecsimex01.php b/web/classes/jpgraph/Examples/titlecsimex01.php
new file mode 100755
index 0000000000000000000000000000000000000000..a44290e52ec4fd84d55065dfe7714b02bd9ded19
--- /dev/null
+++ b/web/classes/jpgraph/Examples/titlecsimex01.php
@@ -0,0 +1,62 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+$datay=array(12,26,9,17,31);
+
+// Create the graph. 
+$graph = new Graph(400,250);
+$graph->SetScale("textlin");
+$graph->SetMargin(50,80,20,40);
+$graph->yaxis->SetTitleMargin(30);
+$graph->yaxis->scale->SetGrace(30);
+$graph->SetShadow();
+
+
+// Create a bar pot
+$bplot = new BarPlot($datay);
+
+// Create targets for the bars image maps. One for each column
+$targ=array("bar_clsmex1.php#1","bar_clsmex1.php#2","bar_clsmex1.php#3","bar_clsmex1.php#4","bar_clsmex1.php#5","bar_clsmex1.php#6");
+$alts=array("val=%d","val=%d","val=%d","val=%d","val=%d","val=%d");
+$bplot->SetCSIMTargets($targ,$alts);
+$bplot->SetFillColor("orange");
+$bplot->SetLegend('Year 2001 %%','#kalle ','%s');
+
+// Display the values on top of each bar
+$bplot->SetShadow();
+$bplot->value->SetFormat(" $ %2.1f",70);
+$bplot->value->SetFont(FF_ARIAL,FS_NORMAL,9);
+$bplot->value->SetColor("blue");
+$bplot->value->Show();
+
+$graph->Add($bplot);
+
+// Create a big "button" that has an image map action
+$txt1 = new Text("A simple text with\ntwo rows");
+$txt1->SetFont(FF_ARIAL);
+$txt1->SetBox('lightblue','black','white@1',5);
+$txt1->SetParagraphAlign('center');
+$txt1->SetPos(40,50);
+$txt1->SetCSIMTarget('#88','Text element');
+$graph->Add($txt1);
+
+// Add image map to the graph title as well (you can do this to the 
+// sub- and subsub-title as well)
+$graph->title->Set("Image maps barex1");
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+$graph->title->SetCSIMTarget('#45','Title for Bar');
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+// Setup the axis title image map and font style
+$graph->yaxis->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->yaxis->title->SetCSIMTarget('#55','Y-axis title');
+$graph->xaxis->title->SetFont(FF_FONT2,FS_BOLD);
+$graph->xaxis->title->SetCSIMTarget('#55','X-axis title');
+
+// Send back the HTML page which will call this script again
+// to retrieve the image.
+$graph->StrokeCSIM();
+
+?>
diff --git a/web/classes/jpgraph/Examples/titleex1.php b/web/classes/jpgraph/Examples/titleex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..77baa00bcd0b856011b058e52e07f2430ef25342
--- /dev/null
+++ b/web/classes/jpgraph/Examples/titleex1.php
@@ -0,0 +1,29 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some data
+$ydata = array(11,3,8,12,5,1,9,13,5,7);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(200,150);
+$graph->SetScale("textlin");
+$graph->SetMargin(25,10,30,30);
+
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+$graph->title->Set('The Title');
+$graph->subtitle->SetFont(FF_ARIAL,FS_BOLD,10);
+$graph->subtitle->Set('The Subtitle');
+$graph->subsubtitle->SetFont(FF_ARIAL,FS_ITALIC,9);
+$graph->subsubtitle->Set('The Subsubitle');
+
+// Create the linear plot
+$lineplot=new LinePlot($ydata);
+$lineplot->SetColor("blue");
+
+// Add the plot to the graph
+$graph->Add($lineplot);
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/topxaxisex1.php b/web/classes/jpgraph/Examples/topxaxisex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..6143875e55259430495a239cdda859760c75f338
--- /dev/null
+++ b/web/classes/jpgraph/Examples/topxaxisex1.php
@@ -0,0 +1,49 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+// Some data
+$datay = array(25,29,29,39,55);
+
+$graph = new Graph(400,200,'auto');
+$graph->img->SetMargin(40,40,40,20);
+
+$graph->SetScale("linlin");
+$graph->SetShadow();
+$graph->title->Set("Top X-axis");
+
+// Start at 0
+$graph->yscale->SetAutoMin(0);
+
+// Add some air around the Y-scale
+$graph->yscale->SetGrace(100);
+
+// Use built in font
+$graph->title->SetFont(FF_FONT1,FS_BOLD);
+
+// Adjust the X-axis
+$graph->xaxis->SetPos("max");
+$graph->xaxis->SetLabelSide(SIDE_UP);
+$graph->xaxis->SetTickSide(SIDE_DOWN);
+
+// Create the line plot
+$p1 = new LinePlot($datay);
+$p1->SetColor("blue");
+
+// Specify marks for the line plots
+$p1->mark->SetType(MARK_FILLEDCIRCLE);
+$p1->mark->SetFillColor("red");
+$p1->mark->SetWidth(4);
+
+// Show values
+$p1->value->Show();
+
+// Add lineplot to graph
+$graph->Add($p1);
+
+// Output line
+$graph->Stroke();
+
+?>
+
+
diff --git a/web/classes/jpgraph/Examples/tornado.jpg b/web/classes/jpgraph/Examples/tornado.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..24c1ea1b3dd0ac585e3d4f59c539727b860967ee
Binary files /dev/null and b/web/classes/jpgraph/Examples/tornado.jpg differ
diff --git a/web/classes/jpgraph/Examples/tr1.jpg b/web/classes/jpgraph/Examples/tr1.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..f855e31e4b121f6e7b14ab6d37a2b8f032dd70a6
Binary files /dev/null and b/web/classes/jpgraph/Examples/tr1.jpg differ
diff --git a/web/classes/jpgraph/Examples/tr2.jpg b/web/classes/jpgraph/Examples/tr2.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..6a75e474b26870b69984f3524ecf087af71dd5ed
Binary files /dev/null and b/web/classes/jpgraph/Examples/tr2.jpg differ
diff --git a/web/classes/jpgraph/Examples/tr3.jpg b/web/classes/jpgraph/Examples/tr3.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..799e097d5659fc34157a51c6b7ff2c51ef10872b
Binary files /dev/null and b/web/classes/jpgraph/Examples/tr3.jpg differ
diff --git a/web/classes/jpgraph/Examples/tr4.jpg b/web/classes/jpgraph/Examples/tr4.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..fe411c1ca3b34e7594c7b07e88fade0f49c4425e
Binary files /dev/null and b/web/classes/jpgraph/Examples/tr4.jpg differ
diff --git a/web/classes/jpgraph/Examples/tr5.jpg b/web/classes/jpgraph/Examples/tr5.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..33c974881ed1f5c39324270e8ef78272f295e998
Binary files /dev/null and b/web/classes/jpgraph/Examples/tr5.jpg differ
diff --git a/web/classes/jpgraph/Examples/tr6.jpg b/web/classes/jpgraph/Examples/tr6.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..81321b7daad4b6ba4ccaecd63ce255a7e7189f05
Binary files /dev/null and b/web/classes/jpgraph/Examples/tr6.jpg differ
diff --git a/web/classes/jpgraph/Examples/universal_example.php b/web/classes/jpgraph/Examples/universal_example.php
new file mode 100755
index 0000000000000000000000000000000000000000..eae0c19004d2c27281622dd82027dae929de7b43
--- /dev/null
+++ b/web/classes/jpgraph/Examples/universal_example.php
@@ -0,0 +1,58 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$theme = isset($_GET['theme']) ? $_GET['theme'] : null;
+
+$data = array (
+  0 => array (0 => 79, 1 => -25, 2 => -7, 3 => 85, 4 => -26, 5 => -32, ),
+  1 => array (0 => 76, 1 => 51, 2 => 86, 3 => 12, 4 => -7, 5 => 94, ),
+  2 => array (0 => 49, 1 => 38, 2 => 7, 3 => -40, 4 => 9, 5 => -7, ),
+  3 => array ( 0 => 69, 1 => 96, 2 => 49, 3 => 7, 4 => 92, 5 => -38, ),
+  4 => array ( 0 => 68, 1 => 16, 2 => 82, 3 => -49, 4 => 50, 5 => 7, ),
+  5 => array ( 0 => -37, 1 => 28, 2 => 32, 3 => 6, 4 => 13, 5 => 57, ),
+  6 => array ( 0 => 24, 1 => -11, 2 => 7, 3 => 10, 4 => 51, 5 => 51, ),
+  7 => array ( 0 => 3, 1 => -1, 2 => -12, 3 => 61, 4 => 10, 5 => 47, ),
+  8 => array ( 0 => -47, 1 => -21, 2 => 43, 3 => 53, 4 => 36, 5 => 34, ),
+);
+
+
+// Create the graph. These two calls are always required
+$graph = new Graph(400,300);    
+
+$graph->SetScale("textlin");
+if ($theme) {
+  $graph->SetTheme(new $theme());
+}
+$theme_class = new UniversalTheme;
+$graph->SetTheme($theme_class);
+
+$plot = array();
+// Create the bar plots
+for ($i = 0; $i < 4; $i++) {
+  $plot[$i] = new BarPlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.($i+1));
+}
+//$acc1 = new AccBarPlot(array($plot[0], $plot[1]));
+//$acc1->value->Show();
+$gbplot = new GroupBarPlot(array($plot[2], $plot[1] ));
+
+for ($i = 4; $i < 8; $i++) {
+  $plot[$i] = new LinePlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.$i);
+  $plot[$i]->value->Show();
+}
+
+$graph->Add($gbplot);
+$graph->Add($plot[4]);
+
+$title = "UniversalTheme Example";
+$title = mb_convert_encoding($title,'UTF-8');
+$graph->title->Set($title);
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/vivid_example.php b/web/classes/jpgraph/Examples/vivid_example.php
new file mode 100755
index 0000000000000000000000000000000000000000..1d2274813a84fd91884bc826f1619dc92293cb1f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/vivid_example.php
@@ -0,0 +1,57 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_bar.php');
+require_once ('jpgraph/jpgraph_line.php');
+
+$theme = isset($_GET['theme']) ? $_GET['theme'] : null;
+
+$data = array (
+  0 => array (0 => 79, 1 => -25, 2 => -7, 3 => 85, 4 => -26, 5 => -32, ),
+  1 => array (0 => 76, 1 => 51, 2 => 86, 3 => 12, 4 => -7, 5 => 94, ),
+  2 => array (0 => 49, 1 => 38, 2 => 7, 3 => -40, 4 => 9, 5 => -7, ),
+  3 => array ( 0 => 69, 1 => 96, 2 => 49, 3 => 7, 4 => 92, 5 => -38, ),
+  4 => array ( 0 => 68, 1 => 16, 2 => 82, 3 => -49, 4 => 50, 5 => 7, ),
+  5 => array ( 0 => -37, 1 => 28, 2 => 32, 3 => 6, 4 => 13, 5 => 57, ),
+  6 => array ( 0 => 24, 1 => -11, 2 => 7, 3 => 10, 4 => 51, 5 => 51, ),
+  7 => array ( 0 => 3, 1 => -1, 2 => -12, 3 => 61, 4 => 10, 5 => 47, ),
+  8 => array ( 0 => -47, 1 => -21, 2 => 43, 3 => 53, 4 => 36, 5 => 34, ),
+);
+
+// Create the graph. These two calls are always required
+$graph = new Graph(400,300);    
+
+$graph->SetScale("textlin");
+if ($theme) {
+  $graph->SetTheme(new $theme());
+}
+$theme_class = new VividTheme;
+$graph->SetTheme($theme_class);
+
+$plot = array();
+// Create the bar plots
+for ($i = 0; $i < 4; $i++) {
+  $plot[$i] = new BarPlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.($i+1));
+}
+//$acc1 = new AccBarPlot(array($plot[0], $plot[1]));
+//$acc1->value->Show();
+$gbplot = new GroupBarPlot(array($plot[2], $plot[1] ));
+
+for ($i = 4; $i < 8; $i++) {
+  $plot[$i] = new LinePlot($data[$i]);
+  $plot[$i]->SetLegend('plot'.$i);
+  $plot[$i]->value->Show();
+}
+
+$graph->Add($gbplot);
+$graph->Add($plot[4]);
+
+$title = "VividTheme Example";
+$title = mb_convert_encoding($title,'UTF-8');
+$graph->title->Set($title);
+$graph->xaxis->title->Set("X-title");
+$graph->yaxis->title->Set("Y-title");
+
+// Display the graph
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/windrose_2plots_ex1.php b/web/classes/jpgraph/Examples/windrose_2plots_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..7aee315429a5ee76acea41969da086bdb83fee21
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_2plots_ex1.php
@@ -0,0 +1,44 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+// Data can be specified using both ordinal idex of axis as well
+// as the direction label
+$data = array(
+    1 => array(10,10,13,7),
+	2 => array(2,8,10),
+	4 => array(1,12,22),
+    );
+
+$data2 = array(
+    4 => array(12,8,2,3),
+    2 => array(5,4,4,5,2),
+    );
+
+// Create a new small windrose graph
+$graph = new WindroseGraph(660,400);
+$graph->SetShadow();
+
+$graph->title->Set('Two windrose plots in one graph');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+$graph->subtitle->Set('(Using Box() for each plot)');
+
+$wp = new WindrosePlot($data);
+$wp->SetType(WINDROSE_TYPE8);
+$wp->SetSize(0.42);
+$wp->SetPos(0.25,0.55);
+$wp->SetBox();
+
+$wp2 = new WindrosePlot($data2);
+$wp2->SetType(WINDROSE_TYPE16);
+$wp2->SetSize(0.42);
+$wp2->SetPos(0.74,0.55);
+$wp2->SetBox();
+$wp2->SetRangeColors(array('green','yellow','red','brown'));
+
+$graph->Add($wp);
+$graph->Add($wp2);
+
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_bgimg_ex1.php b/web/classes/jpgraph/Examples/windrose_bgimg_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..e51372d8ef17005773abc62e16c4b3fe463070ed
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_bgimg_ex1.php
@@ -0,0 +1,50 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+require_once ('jpgraph/jpgraph_flags.php');
+
+// Data can be specified using both ordinal idex of axis as well
+// as the direction label
+$data2 = array(
+    'vsv' => array(12,8,2,3),
+    6 => array(5,4,4,5,4),
+    );
+
+$se_CompassLbl = array('O','ONO','NO','NNO','N','NNV','NV','VNV','V','VSV','SV','SSV','S','SSO','SO','OSO');
+
+// Create a new small windrose graph
+$graph = new WindroseGraph(400,400);
+$graph->SetMargin(25,25,25,25);
+$graph->SetFrame();
+
+$graph->title->Set('Example with background flag');
+#$graph->title->SetFont(FF_VERA,FS_BOLD,14);
+
+
+//$graph->SetBackgroundImage('bkgimg.jpg',BGIMG_FILLFRAME);
+//$graph->SetBackgroundImageMix(90);
+$graph->SetBackgroundCFlag(28,BGIMG_FILLFRAME,15);
+
+
+$wp2 = new WindrosePlot($data2);
+$wp2->SetType(WINDROSE_TYPE16);
+$wp2->SetSize(0.55);
+$wp2->SetPos(0.5,0.5);
+$wp2->SetAntiAlias(false);
+
+$wp2->SetFont(FF_ARIAL,FS_BOLD,10);
+$wp2->SetFontColor('black');
+
+$wp2->SetCompassLabels($se_CompassLbl);
+$wp2->legend->SetMargin(20,5);
+
+$wp2->scale->SetZFont(FF_ARIAL,FS_NORMAL,8);
+$wp2->scale->SetFont(FF_ARIAL,FS_NORMAL,9);
+$wp2->scale->SetLabelFillColor('white','white');
+
+$wp2->SetRangeColors(array('green','yellow','red','brown'));
+
+$graph->Add($wp2);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_ex0.php b/web/classes/jpgraph/Examples/windrose_ex0.php
new file mode 100755
index 0000000000000000000000000000000000000000..897d4283c249a256023497c7a13bfde686ae80f3
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_ex0.php
@@ -0,0 +1,25 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+// Data can be specified using both ordinal index of the axis
+// as well as the direction label
+$data = array(
+    0 => array(5,5,5,8),
+    1 => array(3,4,1,4),
+    'WSW' => array(1,5,5,3),
+    'N' => array(2,3,8,1,1),
+    15 => array(2,3,5));
+
+// First create a new windrose graph with a title
+$graph = new WindroseGraph(400,400);
+$graph->title->Set('A basic Windrose graph');
+
+// Create the windrose plot.
+$wp = new WindrosePlot($data);
+
+// Add and send back to browser
+$graph->Add($wp);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_ex1.php b/web/classes/jpgraph/Examples/windrose_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..e892a21e6608ff42fcb3117ed1a3211829e4954e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_ex1.php
@@ -0,0 +1,28 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+$data = array(
+    0 => array(1,1,2.5,4),
+    1 => array(3,4,1,4),
+    'wsw' => array(1,5,5,3),
+    'N' => array(2,7,5,4,2),
+    15 => array(2,7,12));
+
+// First create a new windrose graph with a title
+$graph = new WindroseGraph(400,400);
+
+// Setup title
+$graph->title->Set('Windrose basic example');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+$graph->title->SetColor('navy');
+
+// Create the windrose plot.
+$wp = new WindrosePlot($data);
+$wp->SetRadialGridStyle('solid');
+$graph->Add($wp);
+
+// Send the graph to the browser
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_ex1b.php b/web/classes/jpgraph/Examples/windrose_ex1b.php
new file mode 100755
index 0000000000000000000000000000000000000000..c24a98c83b79478721a4906e3baffe4cfcf3a35f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_ex1b.php
@@ -0,0 +1,33 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+// Data can be specified using both ordinal index of the axis
+// as well as the direction label
+$data = array(
+    0 => array(1,1,2.5,4),
+    1 => array(3,4,1,4),
+    'wsw' => array(1,5,5,3),
+    'N' => array(2,7,5,4,2),
+    15 => array(2,7,12));
+
+// First create a new windrose graph with a title
+$graph = new WindroseGraph(400,400);
+$graph->title->Set('Windrose example 1b');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+$graph->title->SetColor('navy');
+
+// Create the windrose plot.
+// The default plot will have 16 compass axis.
+$wp = new WindrosePlot($data);
+$wp->SetRadialGridStyle('solid');
+$graph->Add($wp);
+
+// Setup the range so that the values do not touch eachother
+$wp->SetRanges(array(0,1,2,3,4,5,6,7,8,10));
+$wp->SetRangeStyle(RANGE_DISCRETE); // Cmp with RANGE_OVERLAPPING as default
+
+// Send the graph to the browser
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_ex2.1.php b/web/classes/jpgraph/Examples/windrose_ex2.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..48781acc761a59772a8f3ecd1525bbdf426d8fd8
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_ex2.1.php
@@ -0,0 +1,49 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+// Data can be specified using both ordinal index of the axis
+// as well as the direction label
+$data = array(
+    0 => array(1,1,6,4),
+    1 => array(3,8,1,4),
+    2 => array(2,7,4,4,3),
+    3 => array(2,7,1,2));
+
+// First create a new windrose graph with a title
+$graph = new WindroseGraph(400,400);
+
+// Setup title
+$graph->title->Set('Windrose example 2');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+$graph->title->SetColor('navy');
+
+// Create the windrose plot.
+$wp = new WindrosePlot($data);
+
+// Make it have 8 compass direction
+$wp->SetType(WINDROSE_TYPE4);
+
+// Setup the weight of the laegs for the different ranges
+$weights = array_fill(0,8,10);
+$wp->SetRangeWeights($weights);
+
+// Adjust the font and font color for scale labels
+$wp->scale->SetFont(FF_TIMES,FS_NORMAL,11);
+$wp->scale->SetFontColor('navy');
+
+// Set the diametr for the plot to 160 pixels
+$wp->SetSize(160);
+
+// Set the size of the innermost center circle to 30% of the plot size
+$wp->SetZCircleSize(0.2);
+
+// Adjust the font and font color for compass directions
+$wp->SetFont(FF_ARIAL,FS_NORMAL,12);
+$wp->SetFontColor('darkgreen');
+
+// Add and send back to browser
+$graph->Add($wp);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_ex2.php b/web/classes/jpgraph/Examples/windrose_ex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..23822cca65d9a7d9a49f90a29ddbfea797221947
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_ex2.php
@@ -0,0 +1,49 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+// Data can be specified using both ordinal index of the axis
+// as well as the direction label
+$data = array(
+    0 => array(1,1,2.5,4),
+    1 => array(3,4,1,4),
+    3 => array(2,7,4,4,3),
+    5 => array(2,7,1,2));
+
+// First create a new windrose graph with a title
+$graph = new WindroseGraph(400,400);
+
+// Setup title
+$graph->title->Set('Windrose example 2');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+$graph->title->SetColor('navy');
+
+// Create the windrose plot.
+$wp = new WindrosePlot($data);
+
+// Make it have 8 compass direction
+$wp->SetType(WINDROSE_TYPE8);
+
+// Setup the weight of the laegs for the different ranges
+$weights = array_fill(0,8,10);
+$wp->SetRangeWeights($weights);
+
+// Adjust the font and font color for scale labels
+$wp->scale->SetFont(FF_TIMES,FS_NORMAL,11);
+$wp->scale->SetFontColor('navy');
+
+// Set the diametr for the plot to 160 pixels
+$wp->SetSize(200);
+
+// Set the size of the innermost center circle to 30% of the plot size
+$wp->SetZCircleSize(0.2);
+
+// Adjust the font and font color for compass directions
+$wp->SetFont(FF_ARIAL,FS_NORMAL,12);
+$wp->SetFontColor('darkgreen');
+
+// Add and send back the graph to the client
+$graph->Add($wp);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_ex3.php b/web/classes/jpgraph/Examples/windrose_ex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..39c12ceac5f12e89dfc5897c59150e651ed2c37e
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_ex3.php
@@ -0,0 +1,73 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+// Data can be specified using both ordinal index of the axis
+// as well as the direction label
+$data[0] = array(
+    0 => array(1,1,2.5,4),
+    1 => array(3,4,1,4),
+    3 => array(2,7,4,4,3),
+    5 => array(2,7,1,2));
+
+$data[1] = array(
+    "n" => array(1,1,2.5,4),
+    "ssw" => array(3,4,1,4),
+    "se" => array(2,7,4,4,3));
+
+// Store the position and size data for each plot in an
+// array to make it easier to create multiple plots.
+// The format choosen for the layout data is
+// (type,x-pos,y-pos,size, z-circle size)
+$layout = array(
+    array(WINDROSE_TYPE8,0.25,0.55,0.4,0.25),
+    array(WINDROSE_TYPE16,0.75,0.55,0.4,0.25));
+
+$legendtxt = array('(m/s) Station 7','(m/s) Station 12');
+
+// First create a new windrose graph with a dropshadow
+$graph = new WindroseGraph(600,350);
+$graph->SetShadow('darkgray');
+
+// Setup titles
+$graph->title->Set('Windrose example 3');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+$graph->title->SetColor('navy');
+$graph->subtitle->Set('(Multiple plots in the same graph)');
+$graph->subtitle->SetFont(FF_VERDANA,FS_NORMAL,9);
+$graph->subtitle->SetColor('navy');
+
+// Create the two windrose plots.
+for( $i=0; $i < count($data); ++$i ) {
+    $wp[$i] = new WindrosePlot($data[$i]);
+
+    // Make it have 8 compass direction
+    $wp[$i]->SetType($layout[$i][0]);
+
+    // Adjust the font and font color for scale labels
+    $wp[$i]->scale->SetFont(FF_TIMES,FS_NORMAL,10);
+    $wp[$i]->scale->SetFontColor('navy');
+
+    // Set the position of the plot
+    $wp[$i]->SetPos($layout[$i][1],$layout[$i][2]);
+
+    // Set the diameter for the plot to 30% of the width of the graph pixels
+    $wp[$i]->SetSize($layout[$i][3]);
+
+    // Set the size of the innermost center circle to 30% of the plot size
+    $wp[$i]->SetZCircleSize($layout[$i][4]);
+
+    // Adjust the font and font color for compass directions
+    $wp[$i]->SetFont(FF_ARIAL,FS_NORMAL,10);
+    $wp[$i]->SetFontColor('darkgreen');
+
+    // Add legend text
+    $wp[$i]->legend->SetText($legendtxt[$i]);
+
+    $graph->Add($wp[$i]);
+}
+
+// Send the graph to the browser
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_ex4.php b/web/classes/jpgraph/Examples/windrose_ex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..0465204135e430989f5f921b54f3d8f0900ca025
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_ex4.php
@@ -0,0 +1,58 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+// Data can be specified using both ordinal index of the axis
+// as well as the direction label
+$data = array(
+    0 => array(1,1,2.5,4),
+    1 => array(3,4,1,4),
+    3 => array(2,7,4,4,3),
+    5 => array(2,7,1,2));
+
+// First create a new windrose graph with a title
+$graph = new WindroseGraph(400,400);
+
+// Setup title
+$graph->title->Set('Windrose example 4');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+$graph->title->SetColor('navy');
+
+// Create the windrose plot.
+$wp = new WindrosePlot($data);
+
+// Adjust the font and font color for scale labels
+$wp->scale->SetFont(FF_TIMES,FS_NORMAL,11);
+$wp->scale->SetFontColor('navy');
+
+// Set the diameter and position for plot
+$wp->SetSize(190);
+
+// Set the size of the innermost center circle to 40% of the plot size
+// Note that we can have the automatic "Zero" sum appear in our custom text
+$wp->SetZCircleSize(0.38);
+$wp->scale->SetZeroLabel("Station 12\n(Calm %d%%)");
+
+// Adjust color and font for center circle text
+$wp->scale->SetZFont(FF_ARIAL,FS_NORMAL,9);
+$wp->scale->SetZFontColor('darkgreen');
+
+// Adjust the font and font color for compass directions
+$wp->SetFont(FF_ARIAL,FS_NORMAL,10);
+$wp->SetFontColor('darkgreen');
+
+// Adjust the margin to the compass directions
+$wp->SetLabelMargin(50);
+
+// Adjust grid colors
+$wp->SetGridColor('silver','blue');
+
+// Add (m/s) text to legend
+$wp->legend->SetText('(m/s)');
+$wp->legend->SetMargin(20,5);
+
+// Add and send back to client
+$graph->Add($wp);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_ex5.php b/web/classes/jpgraph/Examples/windrose_ex5.php
new file mode 100755
index 0000000000000000000000000000000000000000..f013c3bf145d168173eece1bfacda5488bf71539
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_ex5.php
@@ -0,0 +1,94 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+// Data
+$data = array(
+    0 => array(1,1,2.5,4),
+    1 => array(3,4,1,4),
+    3 => array(2,7,4,4,3),
+    5 => array(2,7,1,2));
+
+// Text to be added.
+$txt=array();
+$txt[0] = "It is possible to add arbitrary,multi line, text to a graph. ";
+$txt[0] .= "Such a paragraph can have it's text be left, right or center ";
+$txt[0] .= "aligned.";
+$txt[1] = "This is an example of a right aligned paragraph.";
+$txt[2] = "Finally we can show a center aligned paragraph without box.";
+
+// We store the layout for each of the text boxes in an array
+// to keep the code clean
+$txtlayout = array(
+    array(0.97,0.15,25,'left','black','lightblue'),
+    array(0.97,0.4,20,'right','black','lightblue'),
+    array(0.97,0.7,20,'center','darkred',false,FF_COMIC,FS_NORMAL,12),
+);
+
+// Range colors to be used
+$rangeColors = array('silver','khaki','orange','brown','blue','navy','maroon','red');
+
+// First create a new windrose graph with a title
+$graph = new WindroseGraph(570,430);
+$graph->title->Set('Windrose example 5');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+$graph->title->SetColor('navy');
+
+// Setup graph background color
+$graph->SetColor('darkgreen@0.7');
+
+// Setup all the defined text boxes
+$n = count($txt);
+for( $i=0; $i < $n; ++$i ) {
+    $txtbox[$i] = new Text($txt[$i]);
+    $txtbox[$i]->SetPos($txtlayout[$i][0],$txtlayout[$i][1],'right');
+    $txtbox[$i]->SetWordwrap($txtlayout[$i][2]);
+    $txtbox[$i]->SetParagraphAlign($txtlayout[$i][3]);
+    $txtbox[$i]->SetColor($txtlayout[$i][4]);
+    $txtbox[$i]->SetBox($txtlayout[$i][5]);
+    if( count($txtlayout[$i]) > 6 )
+	$txtbox[$i]->SetFont($txtlayout[$i][6],$txtlayout[$i][7],$txtlayout[$i][8]);
+}
+$graph->Add($txtbox);
+
+// Create the windrose plot.
+$wp = new WindrosePlot($data);
+
+// Set background color for plot area
+$wp->SetColor('lightyellow');
+
+// Add a box around the plot
+$wp->SetBox();
+
+// Setup the colors for the ranges
+$wp->SetRangeColors($rangeColors);
+
+// Adjust the font and font color for scale labels
+$wp->scale->SetFont(FF_ARIAL,FS_NORMAL,9);
+$wp->scale->SetFontColor('navy');
+
+// Set the diameter and position for plot
+$wp->SetSize(190);
+$wp->SetPos(0.35,0.53);
+
+$wp->SetZCircleSize(0.2);
+
+// Adjust the font and font color for compass directions
+$wp->SetFont(FF_ARIAL,FS_NORMAL,10);
+$wp->SetFontColor('darkgreen');
+
+// Adjust the margin to the compass directions
+$wp->SetLabelMargin(50);
+
+// Adjust grid colors
+$wp->SetGridColor('silver','blue');
+
+// Add (m/s) text to legend
+$wp->legend->SetText('(m/s)');
+$wp->legend->SetMargin(20,5);
+
+// Add plot and send back to client
+$graph->Add($wp);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_ex6.1.php b/web/classes/jpgraph/Examples/windrose_ex6.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..61504c86e977dc56ae3cca942fa140e16ef12355
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_ex6.1.php
@@ -0,0 +1,89 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+$data = array(
+    '10'  => array(1,1,2.5,4),
+    '32.0' => array(3,4,1,4),
+    '120.5' => array(2,3,4,4,3,2,1),
+    '223.2' => array(2,4,1,2,2),
+    '285.7' => array(2,2,1,2,4,2,1,1)
+);
+
+// This file is encode din utf-8. The two Kanji characters roughly means
+// 中 = Chinese
+// 文 = Sentences
+$ctxt = '中文';
+
+// Specify text for direction labels
+$labels = array(
+	'120.5' => $ctxt,
+	'232.2' => "Reference\n#13 Ver:2");
+
+// Range colors to be used
+$rangeColors = array('khaki','yellow','orange','orange:0.7','brown','darkred','black');
+
+// First create a new windrose graph with a title
+$graph = new WindroseGraph(400,450);
+
+// Setup title
+$graph->title->Set('Using chinese charecters');
+#$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+$graph->title->SetColor('navy');
+$graph->subtitle->Set('(Free type plot)');
+#$graph->subtitle->SetFont(FF_VERDANA,FS_ITALIC,10);
+$graph->subtitle->SetColor('navy');
+
+// Create the windrose plot.
+$wp = new WindrosePlot($data);
+
+// Setup a free plot
+$wp->SetType(WINDROSE_TYPEFREE);
+
+// Setup labels
+$wp->SetLabels($labels);
+$wp->SetLabelPosition(LBLPOSITION_CENTER);
+$wp->SetLabelMargin(30);
+
+// Setup the colors for the ranges
+$wp->SetRangeColors($rangeColors);
+
+// Adjust the font and font color for scale labels
+#$wp->scale->SetFont(FF_ARIAL,FS_NORMAL,9);
+
+// Set the diameter and position for plot
+#$wp->SetSize(240);
+$wp->SetSize(200);
+$wp->SetZCircleSize(30);
+$wp->SetPos(0.5,0.5);
+
+// Adjust the font and font color for compass directions
+#$wp->SetFont(FF_CHINESE,FS_NORMAL,12);
+$wp->SetFontColor('darkgreen');
+
+// Adjust grid colors
+$wp->SetGridColor('darkgreen@0.7','blue');
+
+// Add (m/s) text to legend
+$wp->legend->SetText('(m/s)');
+$wp->legend->SetTFontColor('blue');
+
+// Set legend label font color
+$wp->legend->SetLFontColor('orange:0.7');
+#$wp->legend->SetLFont(FF_ARIAL,FS_ITALIC,8);
+
+// Display legend values with no decimals
+$wp->legend->SetFormat('%d');
+
+// Set the circle font to use chinse character set
+// Note: When FF_CHINESE is used the input charectr data are
+// assumed to already be in utf-8 encoding
+#$wp->legend->SetCFont(FF_CHINESE,FS_NORMAL,14);
+$wp->legend->SetCircleText($ctxt);
+$wp->legend->SetCFontColor('red');
+
+// Add plot to graph and send back to client
+$graph->Add($wp);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_ex6.php b/web/classes/jpgraph/Examples/windrose_ex6.php
new file mode 100755
index 0000000000000000000000000000000000000000..557f005a1311fb68249f1b24dcfaec0b9fbeef66
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_ex6.php
@@ -0,0 +1,72 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+// Data can be specified using both ordinal index of the axis
+// as well as the direction label
+$data = array(
+    '10'  => array(1,1,2.5,4),
+    '32.0' => array(3,4,1,4),
+    '120.5' => array(2,3,4,4,3,2,1),
+    '223.2' => array(2,4,1,2,2),
+    '285.7' => array(2,2,1,2,4,2,1,1)
+);
+
+// Specify text for direction labels
+$labels = array( '120.5' => "Plant\n#1275",
+		 '285.7' => "Reference\n#13 Ver:2");
+
+// Range colors to be used
+$rangeColors = array('khaki','yellow','orange','orange:0.7','brown','darkred','black');
+
+// First create a new windrose graph with a title
+$graph = new WindroseGraph(400,450);
+
+// Setup titles
+$graph->title->Set('Windrose example 6');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+$graph->title->SetColor('navy');
+
+$graph->subtitle->Set('(Free type plot)');
+$graph->subtitle->SetFont(FF_VERDANA,FS_ITALIC,10);
+$graph->subtitle->SetColor('navy');
+
+// Create the windrose plot.
+$wp = new WindrosePlot($data);
+
+// Setup a free plot
+$wp->SetType(WINDROSE_TYPEFREE);
+
+// Setup labels
+$wp->SetLabels($labels);
+$wp->SetLabelPosition(LBLPOSITION_CENTER);
+$wp->SetLabelMargin(30);
+
+// Setup the colors for the ranges
+$wp->SetRangeColors($rangeColors);
+
+// Adjust the font and font color for scale labels
+$wp->scale->SetFont(FF_ARIAL,FS_NORMAL,9);
+
+// Set the diameter and position for plot
+$wp->SetSize(230);
+$wp->SetZCircleSize(30);
+
+// Adjust the font and font color for compass directions
+$wp->SetFont(FF_ARIAL,FS_NORMAL,10);
+$wp->SetFontColor('darkgreen');
+
+// Adjust grid colors
+$wp->SetGridColor('darkgreen@0.7','blue');
+
+// Add (m/s) text to legend
+$wp->legend->SetText('(m/s)');
+
+// Display legend values with no decimals
+$wp->legend->SetFormat('%d');
+
+// Add plot to graph and send back to the client
+$graph->Add($wp);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_ex7.1.php b/web/classes/jpgraph/Examples/windrose_ex7.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..44987168b8423e60a31c43dbce881379c31ae920
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_ex7.1.php
@@ -0,0 +1,67 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+
+
+// Data can be specified using both ordinal index of the axis
+// as well as the direction label.
+$data = array(
+    2 => array(1,15,7.5,2),
+    5 => array(1,1,1.5,2),
+    7 => array(1,2,10,3,2),
+    8 => array(2,3,1,3,1,2),
+    );
+
+// First create a new windrose graph with a title
+$graph = new WindroseGraph(590,580);
+$graph->title->Set('Japanese locale');
+#$graph->title->SetFont(FF_VERDANA,FS_BOLD,14);
+$graph->title->SetColor('navy');
+
+// Create the free windrose plot.
+$wp = new WindrosePlot($data);
+$wp->SetType(WINDROSE_TYPE8);
+
+// Add some "arbitrary" text to the center
+$wp->scale->SetZeroLabel("SOx\n8%%");
+
+// Localize the compass direction labels into Japanese
+// Note: The labels for data must now also match the exact
+// string for the compass directions.
+//
+// E   東
+// NE  北東
+// N   北
+// NW  北西
+// W   西
+// SW  南西
+// S   南
+// SE  南東
+$jp_CompassLbl = array('東','','北東','','北','','北西','',
+ 					   '西','','南西','','南','','南東','');
+$wp->SetCompassLabels($jp_CompassLbl);
+#$wp->SetFont(FF_MINCHO,FS_NORMAL,15);
+
+// Localize the "Calm" text into Swedish and make the circle
+// slightly bigger than default
+$jp_calmtext = '平穏';
+$wp->legend->SetCircleText($jp_calmtext);
+$wp->legend->SetCircleRadius(20);
+#$wp->legend->SetCFont(FF_MINCHO,FS_NORMAL,10);
+$wp->legend->SetMargin(5,0);
+$wp->SetPos(0.5, 0.5);
+
+// Adjust the displayed ranges
+$ranges = array(1,3,5,8,12,19,29);
+$wp->SetRanges($ranges);
+
+// Set the scale to always have max value of 30
+$wp->scale->Set(30,10);
+#$wp->scale->SetFont(FF_VERA,FS_NORMAL,12);
+
+// Finally add it to the graph and send back to client
+$graph->Add($wp);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_ex7.php b/web/classes/jpgraph/Examples/windrose_ex7.php
new file mode 100755
index 0000000000000000000000000000000000000000..b7a9b83e735dd5b290a624f1cf1bebce2fba849f
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_ex7.php
@@ -0,0 +1,51 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+$data = array(
+    2 => array(1,15,7.5,2),
+    5 => array(1,1,1.5,2),
+    7 => array(1,2,10,3,2),
+    9 => array(2,3,1,3,1,2),
+    );
+
+// First create a new windrose graph with a title
+$graph = new WindroseGraph(400,450);
+$graph->title->Set('Windrose example 7');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,14);
+$graph->title->SetColor('navy');
+
+// Create the free windrose plot.
+$wp = new WindrosePlot($data);
+$wp->SetType(WINDROSE_TYPE16);
+
+// Add some "arbitrary" text to the center
+$wp->scale->SetZeroLabel("SOx\n8%%");
+
+// Localize the compass direction labels into Swedish
+// Note: The labels for data must now also match the exact
+// string for the compass directions.
+$se_CompassLbl = array('O','ONO','NO','NNO','N','NNV','NV','VNV',
+		       		   'V','VSV','SV','SSV','S','SSO','SO','OSO');
+$wp->SetCompassLabels($se_CompassLbl);
+
+// Localize the "Calm" text into Swedish and make the circle
+// slightly bigger than default
+$se_calmtext = 'Lugnt';
+$wp->legend->SetCircleText($se_calmtext);
+$wp->legend->SetCircleRadius(20);
+
+// Adjust the displayed ranges
+$ranges = array(1,3,5,8,12,19,29);
+$wp->SetRanges($ranges);
+//$wp->SetAntiAlias(true);
+
+// Set the scale to always have max value of 30 with a step
+// size of 12.
+$wp->scale->Set(30,12);
+
+// Finally add it to the graph and send back to client
+$graph->Add($wp);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_ex8.1.php b/web/classes/jpgraph/Examples/windrose_ex8.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..caaff637142277166f42287c6108418a84a111ef
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_ex8.1.php
@@ -0,0 +1,49 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+// Data can be specified using both ordinal index of the axis
+// as well as the direction label.
+$data = array(
+    '45.9' => array(3,2,1,2,2),
+    355 => array(1,1,1.5,2),
+    180 => array(1,1,1.5,2),
+    150 => array(1,2,1,3),
+    'S' => array(2,3,5,1),
+    );
+
+// Add some labels for  afew of the directions
+$labels = array(355=>"At\nHome base",180=>"Probe\n123",150=>"Power\nplant");
+
+// Define the color,weight and style of some individual radial grid lines.
+$axiscolors = array(355=>"red");
+$axisweights = array(355=>8);
+$axisstyles = array(355=>'solid',150=>'solid');
+
+// First create a new windrose graph with a title
+$graph = new WindroseGraph(400,460);
+$graph->title->Set('Adding label backgrounds');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,14);
+$graph->title->SetColor('navy');
+
+// Create the free windrose plot.
+$wp = new WindrosePlot($data);
+$wp->SetType(WINDROSE_TYPEFREE);
+$wp->scale->SetLabelFillColor('lightblue','black');
+
+// Specify colors weights and style for the radial gridlines
+$wp->SetRadialColors($axiscolors);
+$wp->SetRadialWeights($axisweights);
+$wp->SetRadialStyles($axisstyles);
+
+// Add a few labels
+$wp->SetLabels($labels);
+
+// Add some "arbitrary" text to the center
+$wp->scale->SetZeroLabel("SOx\n8%%");
+
+// Finally add it to the graph and send back to client
+$graph->Add($wp);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_ex8.php b/web/classes/jpgraph/Examples/windrose_ex8.php
new file mode 100755
index 0000000000000000000000000000000000000000..b81c874db6ea501538e344420bbc52a0b2b40399
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_ex8.php
@@ -0,0 +1,48 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+// Data can be specified using both ordinal index of the axis
+// as well as the direction label.
+$data = array(
+    '45.9' => array(3,2,1,2,2),
+    355 => array(1,1,1.5,2),
+    180 => array(1,1,1.5,2),
+    150 => array(1,2,1,3),
+    'S' => array(2,3,5,1),
+    );
+
+// Add some labels for  afew of the directions
+$labels = array(355=>"At\nHome base",180=>"Probe\n123",150=>"Power\nplant");
+
+// Define the color,weight and style of some individual radial grid lines.
+$axiscolors = array(355=>"red");
+$axisweights = array(355=>8);
+$axisstyles = array(355=>'solid',150=>'solid');
+
+// First create a new windrose graph with a title
+$graph = new WindroseGraph(400,500);
+$graph->title->Set('Windrose example 8');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,14);
+$graph->title->SetColor('navy');
+
+// Create the free windrose plot.
+$wp = new WindrosePlot($data);
+$wp->SetType(WINDROSE_TYPEFREE);
+
+// Specify colors weights and style for the radial gridlines
+$wp->SetRadialColors($axiscolors);
+$wp->SetRadialWeights($axisweights);
+$wp->SetRadialStyles($axisstyles);
+
+// Add a few labels
+$wp->SetLabels($labels);
+
+// Add some "arbitrary" text to the center
+$wp->scale->SetZeroLabel("SOx\n8%%");
+
+// Finally add it to the graph and send back to client
+$graph->Add($wp);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_ex9.1.php b/web/classes/jpgraph/Examples/windrose_ex9.1.php
new file mode 100755
index 0000000000000000000000000000000000000000..dbdebed42f078fe6a48ea405249c31f62bc4c119
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_ex9.1.php
@@ -0,0 +1,62 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+// Data can be specified using both ordinal index of the axis
+// as well as the direction label.
+$data = array(
+    0 => array(3,2,1,2,2),
+    4 => array(1,1,1.5,2),
+    6 => array(1,1,1.5,2),
+    12 => array(2,3,5,1),
+);
+
+$xpos1 = 0.26;
+$xpos2 = 0.74;
+$ypos1 = 0.5;
+$ypos2 = 0.9;
+
+// First create a new windrose graph with a title
+$graph = new WindroseGraph(650,350);
+$graph->title->Set('Interpretation of ordinal keys');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,14);
+$graph->title->SetColor('navy');
+
+// Create the first plot
+$wp1 = new WindrosePlot($data);
+$wp1->SetType(WINDROSE_TYPE16);
+
+// This is the default encoding
+$wp1->SetDataKeyEncoding(KEYENCODING_ANTICLOCKWISE);
+$wp1->legend->Hide();
+$wp1->SetPos($xpos1,$ypos1);
+$wp1->SetSize(0.5);
+
+// Create the second plot
+$wp2 = new WindrosePlot($data);
+$wp2->SetType(WINDROSE_TYPE16);
+$wp2->SetDataKeyEncoding(KEYENCODING_CLOCKWISE);
+$wp2->legend->Hide();
+$wp2->SetPos($xpos2,$ypos1);
+$wp2->SetSize(0.5);
+
+$txt1 = new Text('KEYENCODING_ANTICLOCKWISE');
+$txt1->SetFont(FF_COURIER,FS_BOLD,12);
+$txt1->SetPos($xpos1,$ypos2);
+$txt1->SetAlign('center','top');
+
+$txt2 = new Text('KEYENCODING_CLOCKWISE');
+$txt2->SetFont(FF_COURIER,FS_BOLD,12);
+$txt2->SetPos($xpos2,$ypos2);
+$txt2->SetAlign('center','top');
+
+// Finally add it to the graph and send back to the client
+$graph->Add($wp1);
+$graph->Add($txt1);
+
+$graph->Add($wp2);
+$graph->Add($txt2);
+
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_ex9.php b/web/classes/jpgraph/Examples/windrose_ex9.php
new file mode 100755
index 0000000000000000000000000000000000000000..53f3dda746d3b7ad30df48d7f2ebd136be7d1a45
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_ex9.php
@@ -0,0 +1,46 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+// Data can be specified using both ordinal index of the axis
+// as well as the direction label.
+$data = array(
+    'E' => array(3,2,1,2,2),
+    'N' => array(1,1,1.5,2),
+    'nw' => array(1,1,1.5,2),
+    'S' => array(2,3,5,1),
+    );
+
+// Define the color,weight and style of some individual radial
+// grid lines. Axis can be specified either by their (localized)
+// label or by their index.
+// Note; Depending on how many axis you have in the plot the
+// index will vary between 0..n where n is the number of
+// compass directions.
+$axiscolors = array('nw'=>'brown');
+$axisweights = array('nw'=>8);  // Could also be specified as 6 => 8
+$axisstyles = array('nw'=>'solid');
+
+// First create a new windrose graph with a title
+$graph = new WindroseGraph(400,500);
+$graph->title->Set('Windrose example 9');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,14);
+$graph->title->SetColor('navy');
+
+// Create the free windrose plot.
+$wp = new WindrosePlot($data);
+$wp->SetType(WINDROSE_TYPE16);
+
+// Specify colors weights and style for the radial gridlines
+$wp->SetRadialColors($axiscolors);
+$wp->SetRadialWeights($axisweights);
+$wp->SetRadialStyles($axisstyles);
+
+// Add some "arbitrary" text to the center
+$wp->scale->SetZeroLabel("SOx\n8%%");
+
+// Finally add it to the graph and send back to the client
+$graph->Add($wp);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_icon_ex1.php b/web/classes/jpgraph/Examples/windrose_icon_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..44811747863a6ee24f0508a50297cb2a263a30f0
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_icon_ex1.php
@@ -0,0 +1,33 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+require_once ('jpgraph/jpgraph_iconplot.php');
+
+$data = array(
+    0 => array(1,1,2.5,4),
+    1 => array(3,4,1,4),
+    'wsw' => array(1,5,5,3),
+    'N' => array(2,7,5,4,2),
+    15 => array(2,7,12));
+
+// First create a new windrose graph with a title
+$graph = new WindroseGraph(400,400);
+
+// Creta an icon to be added to the graph
+$icon = new IconPlot('tornado.jpg',10,10,1.3,50);
+$icon->SetAnchor('left','top');
+$graph->Add($icon);
+
+// Setup title
+$graph->title->Set('Windrose icon example');
+$graph->title->SetFont(FF_VERDANA,FS_BOLD,12);
+$graph->title->SetColor('navy');
+
+// Create the windrose plot.
+$wp = new WindrosePlot($data);
+
+// Add to graph and send back to client
+$graph->Add($wp);
+$graph->Stroke();
+?>
+
diff --git a/web/classes/jpgraph/Examples/windrose_layout_ex0.php b/web/classes/jpgraph/Examples/windrose_layout_ex0.php
new file mode 100755
index 0000000000000000000000000000000000000000..cd6f43cbb9285afc67027bb1a629b6b20c71f037
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_layout_ex0.php
@@ -0,0 +1,45 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+// Some data for the five windrose plots
+$data = array(
+	array(
+    	1 => array(10,10,13,7),
+		2 => array(2,8,10),
+		4 => array(1,12,22)),
+	array(
+    	4 => array(12,8,2,3),
+    	2 => array(5,4,4,5,2)),
+	array(
+    	1 => array(12,8,2,3),
+    	3 => array(5,4,4,5,2)),
+	array(
+    	2 => array(12,8,2,3),
+    	3 => array(5,4,4,5,2)),
+);
+
+// Create a windrose graph with titles
+$graph = new WindroseGraph(600,650);
+$graph->SetShadow();
+
+$graph->title->Set('Multiple plots with automatic layout');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+// Setup the individual windrose plots
+$wp = array();
+for( $i=0; $i < 4; ++$i ) {
+	$wp[$i] = new WindrosePlot($data[$i]);
+	$wp[$i]->SetSize(0.22);
+	$wp[$i]->SetCenterSize(0.25);
+}
+
+// Position with two rows. Two plots in top row and three plots in
+// bottom row.
+$hl1 = new LayoutHor( array( $wp[0], $wp[1] ) );
+$hl2 = new LayoutHor( array( $wp[2], $wp[3] ) );
+$vl = new LayoutVert( array( $hl1, $hl2) );
+
+$graph->Add($vl);
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/windrose_layout_ex1.php b/web/classes/jpgraph/Examples/windrose_layout_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..d44a61c2ef07878cc3faebaaca055fac30d7ef47
--- /dev/null
+++ b/web/classes/jpgraph/Examples/windrose_layout_ex1.php
@@ -0,0 +1,58 @@
+<?php
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_windrose.php');
+
+// Some data for the five windrose plots
+$data = array(
+	array(
+    	1 => array(10,10,13,7),
+		2 => array(2,8,10),
+		4 => array(1,12,22)),
+	array(
+    	4 => array(12,8,2,3),
+    	2 => array(5,4,4,5,2)),
+	array(
+    	1 => array(12,8,2,3),
+    	3 => array(5,4,4,5,2)),
+	array(
+    	2 => array(12,8,2,3),
+    	3 => array(5,4,4,5,2)),
+	array(
+    	4 => array(12,8,2,3),
+    	6 => array(5,4,4,5,2))
+);
+
+// Legend range colors
+$rangecolors = array('green','yellow','red','brown');
+
+// Create a windrose graph with titles
+$graph = new WindroseGraph(750,700);
+
+$graph->title->Set('Multiple plots with automatic layout');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,14);
+
+// Setup the individual windrose plots
+$wp = array();
+for( $i=0; $i < 5; ++$i ) {
+	$wp[$i] = new WindrosePlot($data[$i]);
+	$wp[$i]->SetType(WINDROSE_TYPE8);
+	if( $i < 2) {
+		$wp[$i]->SetSize(0.28);
+	}
+	else {
+		$wp[$i]->legend->Hide();
+		$wp[$i]->SetSize(0.16);
+		$wp[$i]->SetCenterSize(0.25);
+	}
+	$wp[$i]->SetRangeColors($rangecolors);
+}
+
+// Position with two rows. Two plots in top row and three plots in
+// bottom row.
+$hl1 = new LayoutHor( array( $wp[0], $wp[1] ) );
+$hl2 = new LayoutHor( array( $wp[2], $wp[3], $wp[4] ) );
+$vl = new LayoutVert( array( $hl1, $hl2) );
+
+$graph->Add($vl);
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/worldmap1.jpg b/web/classes/jpgraph/Examples/worldmap1.jpg
new file mode 100755
index 0000000000000000000000000000000000000000..caa7c140457ac20219fdf0a4b64f429e37197cbe
Binary files /dev/null and b/web/classes/jpgraph/Examples/worldmap1.jpg differ
diff --git a/web/classes/jpgraph/Examples/y2synch.php b/web/classes/jpgraph/Examples/y2synch.php
new file mode 100755
index 0000000000000000000000000000000000000000..f00ad73ea1a6185499a932ccf4bec5980e509ea6
--- /dev/null
+++ b/web/classes/jpgraph/Examples/y2synch.php
@@ -0,0 +1,60 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+
+function toFahrenheit($aVal) {
+    return round(($aVal*9/5)+32,2);
+}
+
+function toCelcius($aVal) {
+    return round(($aVal-32)*5/9,2);
+}
+
+
+$datay =array(2,3,8,19,7,17,6,22);
+
+// Create the graph. 
+$graph = new Graph(400,280);
+
+// Slightly bigger margins than default to make room for titles
+$graph->SetMargin(50,60,40,45);
+$graph->SetMarginColor('white');
+
+
+// Setup the scales for X,Y and Y2 axis
+$graph->SetScale("intlin"); // X and Y axis
+$graph->SetY2Scale("lin"); // Y2 axis
+
+// Overall graph title
+$graph->title->Set('Synchronized Y & Y2 scales');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+// Title for X-axis
+$graph->xaxis->title->Set('Measurement');
+$graph->xaxis->title->SetMargin(5);
+$graph->xaxis->title->SetFont(FF_ARIAL,FS_NORMAL,11);
+
+// Create Y data set 
+$lplot = new LinePlot($datay);
+$graph->yaxis->title->Set('Celcius (C)');
+$graph->yaxis->title->SetMargin(5);
+$graph->yaxis->title->SetFont(FF_ARIAL,FS_NORMAL,11);
+// ... and add the plot to the Y-axis
+$graph->Add($lplot);
+
+// Create Y2 scale data set 
+$l2plot = new LinePlot($datay);
+$l2plot->SetWeight(0);
+$graph->y2axis->title->Set('Fahrenheit (F)');
+$graph->y2axis->title->SetMargin(5); // Some extra margin to clear labels
+$graph->y2axis->title->SetFont(FF_ARIAL,FS_NORMAL,11);
+$graph->y2axis->SetLabelFormatCallback('toFahrenheit');
+$graph->y2axis->SetColor('navy');
+
+// ... and add the plot to the Y2-axis
+$graph->AddY2($l2plot);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/y2synch2.php b/web/classes/jpgraph/Examples/y2synch2.php
new file mode 100755
index 0000000000000000000000000000000000000000..5d6a88f4dbd47ad77abb0e814bab3892a365fc20
--- /dev/null
+++ b/web/classes/jpgraph/Examples/y2synch2.php
@@ -0,0 +1,60 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('jpgraph/jpgraph.php');
+require_once ('jpgraph/jpgraph_line.php');
+require_once ('jpgraph/jpgraph_bar.php');
+
+
+function toFahrenheit($aVal) {
+    return round(($aVal*9/5)+32,2);
+}
+
+function toCelcius($aVal) {
+    return round(($aVal-32)*5/9,2);
+}
+
+
+$datay =array(2,3,8,19,7,17,6,22);
+
+// Create the graph. 
+$graph = new Graph(400,280);
+
+// Slightly bigger margins than default to make room for titles
+$graph->SetMargin(50,60,40,45);
+$graph->SetMarginColor('white');
+
+
+// Setup the scales for X,Y and Y2 axis
+$graph->SetScale("textlin"); // X and Y axis
+$graph->SetY2Scale("lin"); // Y2 axis
+
+// Overall graph title
+$graph->title->Set('Synchronized Y & Y2 scales');
+$graph->title->SetFont(FF_ARIAL,FS_BOLD,12);
+
+// Title for X-axis
+$graph->xaxis->title->Set('Measurement');
+$graph->xaxis->title->SetMargin(5);
+$graph->xaxis->title->SetFont(FF_ARIAL,FS_NORMAL,11);
+
+// Create Y data set 
+$lplot = new BarPlot($datay);
+$graph->yaxis->title->Set('Celcius (C)');
+$graph->yaxis->title->SetMargin(5);
+$graph->yaxis->title->SetFont(FF_ARIAL,FS_NORMAL,11);
+// ... and add the plot to the Y-axis
+$graph->Add($lplot);
+
+// Create Y2 scale data set 
+$l2plot = new LinePlot($datay);
+$l2plot->SetWeight(0);
+$graph->y2axis->title->Set('Fahrenheit (F)');
+$graph->y2axis->title->SetMargin(5); // Some extra margin to clear labels
+$graph->y2axis->title->SetFont(FF_ARIAL,FS_NORMAL,11);
+$graph->y2axis->SetLabelFormatCallback('toFahrenheit');
+$graph->y2axis->SetColor('navy');
+
+// ... and add the plot to the Y2-axis
+$graph->AddY2($l2plot);
+
+$graph->Stroke();
+?>
diff --git a/web/classes/jpgraph/Examples/yearssn.txt b/web/classes/jpgraph/Examples/yearssn.txt
new file mode 100755
index 0000000000000000000000000000000000000000..bafcd7b3ddaf9ef335c1a323819eb7b003cedea4
--- /dev/null
+++ b/web/classes/jpgraph/Examples/yearssn.txt
@@ -0,0 +1,309 @@
+1700.5   5.0  
+1701.5  11.0  
+1702.5  16.0  
+1703.5  23.0  
+1704.5  36.0  
+1705.5  58.0  
+1706.5  29.0  
+1707.5  20.0  
+1708.5  10.0  
+1709.5   8.0  
+1710.5   3.0  
+1711.5   0.0  
+1712.5   0.0  
+1713.5   2.0  
+1714.5  11.0  
+1715.5  27.0  
+1716.5  47.0  
+1717.5  63.0  
+1718.5  60.0  
+1719.5  39.0  
+1720.5  28.0  
+1721.5  26.0  
+1722.5  22.0  
+1723.5  11.0  
+1724.5  21.0  
+1725.5  40.0  
+1726.5  78.0  
+1727.5 122.0  
+1728.5 103.0  
+1729.5  73.0  
+1730.5  47.0  
+1731.5  35.0  
+1732.5  11.0  
+1733.5   5.0  
+1734.5  16.0  
+1735.5  34.0  
+1736.5  70.0  
+1737.5  81.0  
+1738.5 111.0  
+1739.5 101.0  
+1740.5  73.0  
+1741.5  40.0  
+1742.5  20.0  
+1743.5  16.0  
+1744.5   5.0  
+1745.5  11.0  
+1746.5  22.0  
+1747.5  40.0  
+1748.5  60.0  
+1749.5  80.9  
+1750.5  83.4  
+1751.5  47.7  
+1752.5  47.8  
+1753.5  30.7  
+1754.5  12.2  
+1755.5   9.6  
+1756.5  10.2  
+1757.5  32.4  
+1758.5  47.6  
+1759.5  54.0  
+1760.5  62.9  
+1761.5  85.9  
+1762.5  61.2  
+1763.5  45.1  
+1764.5  36.4  
+1765.5  20.9  
+1766.5  11.4  
+1767.5  37.8  
+1768.5  69.8  
+1769.5 106.1  
+1770.5 100.8  
+1771.5  81.6  
+1772.5  66.5  
+1773.5  34.8  
+1774.5  30.6  
+1775.5   7.0  
+1776.5  19.8  
+1777.5  92.5  
+1778.5 154.4  
+1779.5 125.9  
+1780.5  84.8  
+1781.5  68.1  
+1782.5  38.5  
+1783.5  22.8  
+1784.5  10.2  
+1785.5  24.1  
+1786.5  82.9  
+1787.5 132.0  
+1788.5 130.9  
+1789.5 118.1  
+1790.5  89.9  
+1791.5  66.6  
+1792.5  60.0  
+1793.5  46.9  
+1794.5  41.0  
+1795.5  21.3  
+1796.5  16.0  
+1797.5   6.4  
+1798.5   4.1  
+1799.5   6.8  
+1800.5  14.5  
+1801.5  34.0  
+1802.5  45.0  
+1803.5  43.1  
+1804.5  47.5  
+1805.5  42.2  
+1806.5  28.1  
+1807.5  10.1  
+1808.5   8.1  
+1809.5   2.5  
+1810.5   0.0  
+1811.5   1.4  
+1812.5   5.0  
+1813.5  12.2  
+1814.5  13.9  
+1815.5  35.4  
+1816.5  45.8  
+1817.5  41.0  
+1818.5  30.1  
+1819.5  23.9  
+1820.5  15.6  
+1821.5   6.6  
+1822.5   4.0  
+1823.5   1.8  
+1824.5   8.5  
+1825.5  16.6  
+1826.5  36.3  
+1827.5  49.6  
+1828.5  64.2  
+1829.5  67.0  
+1830.5  70.9  
+1831.5  47.8  
+1832.5  27.5  
+1833.5   8.5  
+1834.5  13.2  
+1835.5  56.9  
+1836.5 121.5  
+1837.5 138.3  
+1838.5 103.2  
+1839.5  85.7  
+1840.5  64.6  
+1841.5  36.7  
+1842.5  24.2  
+1843.5  10.7  
+1844.5  15.0  
+1845.5  40.1  
+1846.5  61.5  
+1847.5  98.5  
+1848.5 124.7  
+1849.5  96.3  
+1850.5  66.6  
+1851.5  64.5  
+1852.5  54.1  
+1853.5  39.0  
+1854.5  20.6  
+1855.5   6.7  
+1856.5   4.3  
+1857.5  22.7  
+1858.5  54.8  
+1859.5  93.8  
+1860.5  95.8  
+1861.5  77.2  
+1862.5  59.1  
+1863.5  44.0  
+1864.5  47.0  
+1865.5  30.5  
+1866.5  16.3  
+1867.5   7.3  
+1868.5  37.6  
+1869.5  74.0  
+1870.5 139.0  
+1871.5 111.2  
+1872.5 101.6  
+1873.5  66.2  
+1874.5  44.7  
+1875.5  17.0  
+1876.5  11.3  
+1877.5  12.4  
+1878.5   3.4  
+1879.5   6.0  
+1880.5  32.3  
+1881.5  54.3  
+1882.5  59.7  
+1883.5  63.7  
+1884.5  63.5  
+1885.5  52.2  
+1886.5  25.4  
+1887.5  13.1  
+1888.5   6.8  
+1889.5   6.3  
+1890.5   7.1  
+1891.5  35.6  
+1892.5  73.0  
+1893.5  85.1  
+1894.5  78.0  
+1895.5  64.0  
+1896.5  41.8  
+1897.5  26.2  
+1898.5  26.7  
+1899.5  12.1  
+1900.5   9.5  
+1901.5   2.7  
+1902.5   5.0  
+1903.5  24.4  
+1904.5  42.0  
+1905.5  63.5  
+1906.5  53.8  
+1907.5  62.0  
+1908.5  48.5  
+1909.5  43.9  
+1910.5  18.6  
+1911.5   5.7  
+1912.5   3.6  
+1913.5   1.4  
+1914.5   9.6  
+1915.5  47.4  
+1916.5  57.1  
+1917.5 103.9  
+1918.5  80.6  
+1919.5  63.6  
+1920.5  37.6  
+1921.5  26.1  
+1922.5  14.2  
+1923.5   5.8  
+1924.5  16.7  
+1925.5  44.3  
+1926.5  63.9  
+1927.5  69.0  
+1928.5  77.8  
+1929.5  64.9  
+1930.5  35.7  
+1931.5  21.2  
+1932.5  11.1  
+1933.5   5.7  
+1934.5   8.7  
+1935.5  36.1  
+1936.5  79.7  
+1937.5 114.4  
+1938.5 109.6  
+1939.5  88.8  
+1940.5  67.8  
+1941.5  47.5  
+1942.5  30.6  
+1943.5  16.3  
+1944.5   9.6  
+1945.5  33.2  
+1946.5  92.6  
+1947.5 151.6  
+1948.5 136.3  
+1949.5 134.7  
+1950.5  83.9  
+1951.5  69.4  
+1952.5  31.5  
+1953.5  13.9  
+1954.5   4.4  
+1955.5  38.0  
+1956.5 141.7  
+1957.5 190.2  
+1958.5 184.8  
+1959.5 159.0  
+1960.5 112.3  
+1961.5  53.9  
+1962.5  37.6  
+1963.5  27.9  
+1964.5  10.2  
+1965.5  15.1  
+1966.5  47.0  
+1967.5  93.7  
+1968.5 105.9  
+1969.5 105.5  
+1970.5 104.5  
+1971.5  66.6  
+1972.5  68.9  
+1973.5  38.0  
+1974.5  34.5  
+1975.5  15.5  
+1976.5  12.6  
+1977.5  27.5  
+1978.5  92.5  
+1979.5 155.4  
+1980.5 154.6  
+1981.5 140.5  
+1982.5 115.9  
+1983.5  66.6  
+1984.5  45.9  
+1985.5  17.9  
+1986.5  13.4  
+1987.5  29.2  
+1988.5 100.2  
+1989.5 157.6  
+1990.5 142.6  
+1991.5 145.7  
+1992.5  94.3  
+1993.5  54.6  
+1994.5  29.9  
+1995.5  17.5  
+1996.5   8.6  
+1997.5  21.5  
+1998.5  64.3  
+1999.5  93.3  
+2000.5 119.6  
+2001.5 111.0  
+2002.5 104.0  
+2003.5  63.7  
+2004.5  40.4  
+2005.5  29.8  
+2006.5  15.2  
+2007.5   7.5  
+2008.5   2.9  
diff --git a/web/classes/jpgraph/barcode/demoapp/barcode_image.php b/web/classes/jpgraph/barcode/demoapp/barcode_image.php
new file mode 100755
index 0000000000000000000000000000000000000000..2ad88fd6a0dfebcbed1b65306ad62a55cae78006
--- /dev/null
+++ b/web/classes/jpgraph/barcode/demoapp/barcode_image.php
@@ -0,0 +1,75 @@
+<?php
+require_once "jpgraph/jpgraph.php";
+require_once "jpgraph/jpgraph_canvas.php";
+require_once "jpgraph/jpgraph_barcode.php";
+
+$params = array(
+    array('code',1),array('data',''),array('modwidth',1),array('info',false),
+    array('notext',false),array('checksum',false),array('showframe',false),
+    array('vertical',false) , array('backend','IMAGE'), array('file',''),
+    array('scale',1), array('height',70), array('pswidth','') );
+
+$n=count($params);
+for($i=0; $i < $n; ++$i ) {
+    $v  = $params[$i][0];
+    if( empty($_GET[$params[$i][0]]) ) {
+	$$v = $params[$i][1];
+    }
+    else
+	$$v = $_GET[$params[$i][0]];
+}
+
+if( $modwidth < 1 || $modwidth > 5 ) {
+    echo "<h4>Module width must be between 1 and 5 pixels</h4>";
+}
+elseif( $data==="" ) {
+    echo "<h3>Please enter data to be encoded, select symbology and press 'Ok'.</h3>";
+    echo "<i>Note: Data must be valid for the choosen encoding.</i>";
+}
+elseif( $code==-1 ) {
+    echo "<h4>No code symbology selected.</h4>";
+}
+elseif( $height < 10 || $height > 500 ) {
+    echo "<h4> Height must be in range [10, 500]</h4>";
+}
+elseif( $scale < 0.1 || $scale > 15 ) {
+    echo "<h4> Scale must be in range [0.1, 15]</h4>";
+}
+else {
+    if( $code==20 ) {
+	$encoder = BarcodeFactory::Create(6);
+	$encoder->UseExtended();
+    }
+    else {
+	$encoder = BarcodeFactory::Create($code);
+    }
+    $b =  $backend=='EPS' ? 'PS' : $backend;
+    $b = substr($backend,0,5) == 'IMAGE' ? 'IMAGE' : $b;
+    $e = BackendFactory::Create($b,$encoder);
+    if( substr($backend,0,5) == 'IMAGE' ) {
+	if( substr($backend,5,1) == 'J' ) 
+	    $e->SetImgFormat('JPEG');
+    }
+    if( $e ) {
+	if( $backend == 'EPS' )
+	    $e->SetEPS();
+	if( $pswidth!='' )
+	    $modwidth = $pswidth;
+	$e->SetModuleWidth($modwidth);
+	$e->AddChecksum($checksum);
+	$e->NoText($notext);
+	$e->SetScale($scale);
+	$e->SetVertical($vertical);
+	$e->ShowFrame($showframe);
+	$e->SetHeight($height);
+	$r = $e->Stroke($data,$file,$info,$info);
+	if( $r )
+	    echo nl2br(htmlspecialchars($r));
+	if( $file != '' )
+	    echo "<p>Wrote file $file.";
+    }
+    else
+	echo "<h3>Can't create choosen backend: $backend.</h3>";
+}
+
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/barcode/demoapp/barcode_menu.php b/web/classes/jpgraph/barcode/demoapp/barcode_menu.php
new file mode 100755
index 0000000000000000000000000000000000000000..ea5030665e1ffaae4345dbdd1d696aa757c1cb2a
--- /dev/null
+++ b/web/classes/jpgraph/barcode/demoapp/barcode_menu.php
@@ -0,0 +1,125 @@
+<H2>JpGraph Barcode 1.0</h2>
+<hr>
+</font>
+<form name="barcodespec" action="barcode_image.php" target=barcode
+method post>
+<table cellspacing=4 cellpadding=0>
+<tr>
+<td colspan=2>
+Data:<br>
+<input type=text name=data size=25 maxlength=30>
+</td>
+<tr><td>
+Encoding:<br>
+<select name=code>
+<option selected value=-1> Choose encoding </option>
+<option   value=4> UPC A </option>
+<option   value=5> UPC E </option>
+<option   value=3> EAN 8 </option>
+<option   value=2> EAN 13 </option>
+<option   value=1> EAN 128 </option>
+<option   value=11> Industrial 2 of 5 </option>
+<option   value=12> Interleaved 2 of 5 </option>
+<option   value=14> CODE 11 </option>
+<option   value=6> CODE 39 </option>
+<option   value=20> CODE 39 Extended </option>
+<option   value=8> CODE 128 </option>
+<option   value=13> CODABAR </option>
+<option   value=10> BOOKLAND (ISBN) </option>
+</select>
+</td>
+<td>
+Module width:<br>
+<select name=modwidth>
+<option value=1> One </option>
+<option value=2> Two </option>
+<option value=3> Three </option>
+<option value=4> Four </option>
+<option value=5> Five </option>
+</select>
+</td>
+</tr>
+
+<tr>
+<td>
+Add checksum:<br>
+<input type=checkbox value=1 name=checksum>
+</td>
+
+<td>
+Hide text:<br>
+<input type=checkbox value=1 name=notext>
+</td>
+</tr>
+<tr>
+<td>
+Show frame:<br>
+<input type=checkbox value=1 name=showframe>
+</td>
+<td>
+Vertical layout:<br>
+<input type=checkbox value=1 name=vertical>
+</td>
+</tr>
+
+<tr>
+<td>
+Height:<br>
+<input type=text name=height value="70" size=3 maxlength=3>
+</td>
+<td>
+Scale:<br>
+<input type=text name=scale value="1.0" size=4 maxlength=4>
+</td>
+</tr>
+
+
+
+<tr>
+<td>
+Write to file:<br>
+<input type=text name=file size=15 maxlength=80>
+</td>
+<td>
+Format:<br>
+<select name=backend>
+<option selected value="IMAGEPNG">Image (PNG)</option>
+<option value="IMAGEJPG">Image (JPEG)</option>
+<option value="PS">Postscript</option>
+<option value="EPS">EPS</option>
+</select>
+</td>
+
+<tr>
+<td>
+PS module width:
+</td>
+<td>
+<input type=text name=pswidth size=4 maxlength=4><br>
+</td>
+</tr>
+
+<tr>
+<td colspan=2>
+<small><i>(If specified will override Module width above)</i></small><br>
+</td>
+</tr>
+
+
+<tr>
+<td>
+Debug info:<br>
+<input type=checkbox value=1 name=info>
+</td>
+<td align=right valign=bottom>
+<br>
+<input type=submit name=submit value="&nbsp; Create &nbsp;" style="font-weight:bold;">
+</td>
+</tr></table>
+</form>
+
+<p>
+<hr>
+
+
+
diff --git a/web/classes/jpgraph/barcode/demoapp/index.html b/web/classes/jpgraph/barcode/demoapp/index.html
new file mode 100755
index 0000000000000000000000000000000000000000..e65107cba77665289e2e0d9374c785036760a42f
--- /dev/null
+++ b/web/classes/jpgraph/barcode/demoapp/index.html
@@ -0,0 +1,10 @@
+<!doctype html public "-//W3C//DTD HTML 4.0 Frameset//EN">
+<HTML><HEAD>
+<LINK REL=STYLESHEET TYPE="text/css" HREF="de_normal.css">
+<title>Barcode SYSTEMTEST</title>
+</head>
+<frameset cols="280,*">
+<frame src=barcode_menu.php name=menu>;
+<frame  src=barcode_image.php name=barcode>
+</frameset>
+</html>
diff --git a/web/classes/jpgraph/barcode/examples/barcode_errhandling_ex0.php b/web/classes/jpgraph/barcode/examples/barcode_errhandling_ex0.php
new file mode 100755
index 0000000000000000000000000000000000000000..4f5b5393bf53c865023746fd4ac164c22e988da6
--- /dev/null
+++ b/web/classes/jpgraph/barcode/examples/barcode_errhandling_ex0.php
@@ -0,0 +1,16 @@
+<?php
+// ==============================================
+// Output Image using Code 39 using only default values
+// ==============================================
+require_once ('jpgraph/jpgraph_barcode.php');
+
+try {
+$encoder = BarcodeFactory::Create(ENCODING_CODE39);
+$e = BackendFactory::Create(BACKEND_IMAGE,$encoder);
+$e->Stroke('abc123');
+} catch( JpGraphException $e ) {
+	//echo 'Error: ' . $e->getMessage()."\n";
+	JpGraphError::Raise($e->getMessage());
+}
+
+?>
diff --git a/web/classes/jpgraph/barcode/examples/barcode_ex0.php b/web/classes/jpgraph/barcode/examples/barcode_ex0.php
new file mode 100755
index 0000000000000000000000000000000000000000..021b5c7cc2fdec854072e19119f0fe863a84335c
--- /dev/null
+++ b/web/classes/jpgraph/barcode/examples/barcode_ex0.php
@@ -0,0 +1,11 @@
+<?php
+// ==============================================
+// Output Image using Code 39 using only default values
+// ==============================================
+require_once ('jpgraph/jpgraph_barcode.php');
+
+$encoder = BarcodeFactory::Create(ENCODING_CODE39);
+$e = BackendFactory::Create(BACKEND_IMAGE,$encoder);
+$e->Stroke('ABC123');
+
+?>
diff --git a/web/classes/jpgraph/barcode/examples/barcode_ex1.php b/web/classes/jpgraph/barcode/examples/barcode_ex1.php
new file mode 100755
index 0000000000000000000000000000000000000000..df7653b5cbc874b0eb36e425735675a9b838f8fb
--- /dev/null
+++ b/web/classes/jpgraph/barcode/examples/barcode_ex1.php
@@ -0,0 +1,14 @@
+<?php
+// ==============================================
+// Output Image using Code 128
+// ==============================================
+require_once ('jpgraph/jpgraph_barcode.php');
+
+$encoder = BarcodeFactory::Create(ENCODING_CODE128);
+$e = BackendFactory::Create(BACKEND_PS,$encoder);
+$e->SetModuleWidth(2);
+$e->SetHeight(20);
+echo nl2br($e->Stroke('3125134772'));
+
+
+?>
diff --git a/web/classes/jpgraph/barcode/examples/barcode_ex2.php b/web/classes/jpgraph/barcode/examples/barcode_ex2.php
new file mode 100755
index 0000000000000000000000000000000000000000..8fce58e62fb167fdbd8638a2f325f0d0d354f025
--- /dev/null
+++ b/web/classes/jpgraph/barcode/examples/barcode_ex2.php
@@ -0,0 +1,14 @@
+<?php
+// ==============================================
+// Output Postscript of nterleaved 2 of 5
+// ==============================================
+require_once ('jpgraph/jpgraph_barcode.php');
+
+$encoder = BarcodeFactory::Create(ENCODING_CODEI25);
+$e = BackendFactory::Create(BACKEND_PS,$encoder);
+$e->SetModuleWidth(2);
+$e->SetHeight(70);
+$ps = $e->Stroke('3125134772');
+echo nl2br(htmlspecialchars($ps));
+
+?>
diff --git a/web/classes/jpgraph/barcode/examples/barcode_ex3.php b/web/classes/jpgraph/barcode/examples/barcode_ex3.php
new file mode 100755
index 0000000000000000000000000000000000000000..a63f4ad43b0e35bd4dcd5073057f98f2b8461ee3
--- /dev/null
+++ b/web/classes/jpgraph/barcode/examples/barcode_ex3.php
@@ -0,0 +1,17 @@
+<?php
+// ==============================================
+// Output Encapsulated Postscript of interleaved 2 of 5
+// ==============================================
+require_once ('jpgraph/jpgraph_barcode.php');
+
+echo "Start ...<br>";
+$encoder = BarcodeFactory::Create(ENCODING_CODEI25);
+$e = BackendFactory::Create(BACKEND_PS,$encoder);
+$e->SetModuleWidth(2);
+$e->SetHeight(70);
+$e->SetEPS();
+$ps = $e->Stroke('3125134772');
+echo nl2br(htmlspecialchars($ps));
+
+
+?>
diff --git a/web/classes/jpgraph/barcode/examples/barcode_ex4.php b/web/classes/jpgraph/barcode/examples/barcode_ex4.php
new file mode 100755
index 0000000000000000000000000000000000000000..721b56baff0b1da95a9830d65ffac02d0ac4ef45
--- /dev/null
+++ b/web/classes/jpgraph/barcode/examples/barcode_ex4.php
@@ -0,0 +1,12 @@
+<?php
+// ==============================================
+// Output Image using Code Interleaved 2 of 5
+// ==============================================
+require_once ('jpgraph/jpgraph_barcode.php');
+
+$encoder = BarcodeFactory::Create(ENCODING_CODEI25);
+$e = BackendFactory::Create(BACKEND_IMAGE,$encoder);
+$e->SetModuleWidth(2);
+$e->Stroke('1234');
+
+?>
diff --git a/web/classes/jpgraph/barcode/examples/barcode_usps_example.php b/web/classes/jpgraph/barcode/examples/barcode_usps_example.php
new file mode 100755
index 0000000000000000000000000000000000000000..80469beafa8dee3bb964f51cc1e16dd7ec8edeaa
--- /dev/null
+++ b/web/classes/jpgraph/barcode/examples/barcode_usps_example.php
@@ -0,0 +1,74 @@
+<?php
+// =======================================================
+// Example of how to format US Postal shipping information
+// =======================================================
+require_once ('jpgraph/jpgraph_barcode.php');
+
+// The Full barcode standard is described in
+// http://www.usps.com/cpim/ftp/pubs/pub91/91c4.html#508hdr1
+//
+// The data start with AI=420 which means
+// "Ship to/Deliver To Postal Code (within single authority)
+//
+class USPS_Confirmation {
+    function USPS_Confirmation() {
+    }
+
+    // Private utility function
+    function _USPS_chkd($aData) {
+	$n = strlen($aData);
+
+	// Add all even numbers starting from position 1 from the end
+	$et = 0 ;
+	for( $i=1; $i <= $n; $i+=2 ) {
+	    $d = intval(substr($aData,-$i,1));
+	    $et += $d;
+	}
+
+	// Add all odd numbers starting from position 2 from the end
+	$ot = 0 ;
+	for( $i=2; $i <= $n; $i+=2 ) {
+	    $d = intval(substr($aData,-$i,1));
+	    $ot += $d;
+	}
+	$tot = 3*$et + $ot;
+	$chkdigit = (10 - ($tot % 10))%10;;
+	return $chkdigit;
+    }
+
+    // Get type 1 of confirmation code (with ZIP)
+    function GetPICwithZIP($aZIP,$aServiceType,$aDUNS,$aSeqNbr) {
+	// Convert to USPS format with AI=420 and extension starting with AI=91
+	$data = '420'. $aZIP . '91' . $aServiceType . $aDUNS . $aSeqNbr;
+	// Only calculate the checkdigit from the AI=91 and forward
+	// and do not include the ~1 (FUNC1) in the calculation
+	$cd = $this->_USPS_chkd(substr($data,8));
+	$data = '420'. $aZIP . '~191' . $aServiceType . $aDUNS . $aSeqNbr;
+	return $data . $cd;
+    }
+
+    // Get type 2 of confirmation code (without ZIP)
+    function GetPIC($aServiceType,$aDUNS,$aSeqNbr) {
+	// Convert to USPS format with AI=91
+	$data = '91' . $aServiceType . $aDUNS . $aSeqNbr;
+	$cd = $this->_USPS_chkd($data);
+	return $data . $cd;
+    }
+
+}
+
+$usps = new USPS_Confirmation();
+$zip     = '92663';
+$service = '21';
+$DUNS    = '805213907';
+$seqnr   = '04508735';
+$data = $usps->GetPICwithZIP($zip,$service,$DUNS,$seqnr);
+//$data = $usps->GetPIC('01','123456789','00000001');
+
+$encoder = BarcodeFactory::Create(ENCODING_EAN128);
+$e = BackendFactory::Create(BACKEND_IMAGE,$encoder);
+$e->SetModuleWidth(2);
+$e->SetFont(FF_ARIAL,FS_NORMAL,14);
+$e->Stroke($data);
+
+?>
\ No newline at end of file
diff --git a/web/classes/jpgraph/barcode/mkbarcode.php b/web/classes/jpgraph/barcode/mkbarcode.php
new file mode 100755
index 0000000000000000000000000000000000000000..57ef6ec07ab12065cebce689aa8dddaf57ec5f76
--- /dev/null
+++ b/web/classes/jpgraph/barcode/mkbarcode.php
@@ -0,0 +1,281 @@
+<?php
+require_once('jpgraph/jpgraph_barcode.php');
+
+/*=======================================================================
+ // File:        MKBARCODE.PHP
+ // Description: Comman line tool to generate linear barcodes
+ // Created:     2009-06-20
+ // Ver:         $Id: mkbarcode.php 1455 2009-07-03 18:52:25Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //=======================================================================
+ */
+
+//----------------------------------------------------------------------
+// CLASS ParseArgs
+// Parse command line arguments and make sanity checks
+//----------------------------------------------------------------------
+class ParseArgs {
+    var $argc,$argv;
+
+    function ParseArgs() {
+        // Get command line argument
+        $this->argv = ($_SERVER['argv']);
+        $this->argc = ($_SERVER['argc']);
+    }
+
+    function PrintUsage() {
+    	$n = $this->argv[0];
+        echo "$n -b <symbology> [-r -h -c -o <output format> -m <width> -s <scale> -y <height> -f <filename> ] datastring \n".
+            "Create the specified barcode\n".
+            "-b           What symbology to use, one of the following strings (case insensitive)\n".
+            "             UPCA \n".
+            "             UPCE \n".
+            "             EAN128 \n".
+            "             EAN13 \n".
+            "             EAN8 \n".
+            "             CODE11 \n".
+            "             CODE39 \n".
+            "             CODE128 \n".
+            "             CODE25 \n".
+            "             CODEI25 \n".
+            "             CODABAR \n".
+            "             BOOKLAND \n".
+            "-c           Add checkdigit for symbologies where this is optional\n".
+            "-o           Output format. 0=Image, 1=PS, 2=EPS\n".
+            "-m           Module width\n".
+            "-s           Scale factor\n".
+            "-h           Show this help\n".
+			"-f           Filename to write to\n".
+        	"-r           Rotate barcode 90 degrees\n".
+        	"-y height    Set height in pixels\n".
+            "-x           Hide the human readable text\n".
+        	"--silent     Silent. Don't give any error mesages\n";
+        exit(1);
+    }
+
+    function Get() {
+        $barcode='code39';
+        $hide=false;
+        $checkdigit=false;
+        $modulewidth=2;
+        $scale=1;
+        $output=0;
+        $filename='';
+        $data = '';
+        $rotate = false;
+        $silent=false;
+        $height = 70;
+        if( ($n=$this->GetNum()) > 0 ) {
+            $i=1;
+            while( $i <= $n ) {
+                switch( $this->argv[$i] ) {
+                    case '-h':
+                        $this->PrintUsage();
+                        exit(0);
+                        break;
+                    case '-b':
+                        $barcode = $this->argv[++$i];
+                        break;
+                    case '-o':
+                        $output = (int)$this->argv[++$i];
+                        break;
+                    case '-y':
+                        $height = (int)$this->argv[++$i];
+                        break;
+					case '-x':
+                        $hide=true;
+                        break;
+                    case '-r':
+                        $rotate=true;
+                        break;
+                    case '-c':
+                        $checkdigit=true;
+                        break;
+                    case '--silent':
+                        $silent=true;
+                        break;
+                    case '-s':
+                        $scale = (float)$this->argv[++$i];
+                        break;
+                    case '-m':
+                        $modulewidth = (float)$this->argv[++$i];
+                        break;
+                    case '-f':
+                        $filename = $this->argv[++$i];
+                        break;
+                    default:
+                    	if( $data == '' ) {
+                        	$data = $this->argv[$i];
+                    	}
+                    	else {
+  							$this->PrintUsage();
+  							die("Illegal specified parameters");
+                    	}
+                        break;
+                }
+                ++$i;
+            }
+
+        }
+
+        if( $output < 0 || $output > 2 ) {
+        	fwrite(STDERR,"Unkown output format ($output)\n");
+        	exit(1);
+        }
+
+        if( $output === 0  ) {
+        	$modulewidth = floor($modulewidth);
+        }
+
+        // Sanity check
+        if( $modulewidth > 15 ) {
+        	fwrite(STDERR,"Too large modulewidth\n");
+        	exit(1);
+        }
+
+        // Sanity check
+        if( $height > 1000 ) {
+        	fwrite(STDERR,"Too large height\n");
+        	exit(1);
+        }
+
+		// Sanity check
+        if( $scale > 15 ) {
+        	fwrite(STDERR,"Too large scale factor\n");
+        	exit(1);
+        }
+
+        if( strlen($filename) > 256 ) {
+        	fwrite(STDERR,"Too long filename\n");
+        	exit(1);
+        }
+
+        if( trim($data) == '' ) {
+			fwrite(STDERR,"No input data specified\n");
+			exit(1);
+        }
+
+        $barcodes = array(
+            'UPCA' => ENCODING_UPCA,
+            'UPCE' => ENCODING_UPCE,
+            'EAN128' => ENCODING_EAN128,
+            'EAN13' => ENCODING_EAN13,
+            'EAN8' => ENCODING_EAN8,
+            'CODE11' => ENCODING_CODE11,
+            'CODE39' => ENCODING_CODE39,
+            'CODE128' => ENCODING_CODE128,
+            'CODE25' => ENCODING_CODE25,
+            'CODEI25' => ENCODING_CODEI25,
+            'CODABAR' => ENCODING_CODABAR,
+            'BOOKLAND' => ENCODING_BOOKLAND,
+        );
+        $barcode = strtoupper($barcode);
+        if( key_exists($barcode,$barcodes) ) {
+        	$barcode = $barcodes[$barcode];
+        }
+        else {
+        	fwrite(STDERR,'Specified barcode symbology ('.$barcode.") is not supported\n");
+        	exit(1);
+        }
+
+		$ret = array(
+				'barcode'     => $barcode,
+		        'hide' 	      => $hide,
+		        'modulewidth' => $modulewidth,
+		        'scale'       => $scale,
+		        'output'      => $output,
+		        'data'        => $data,
+		        'silent'      => $silent,
+		        'rotate'      => $rotate,
+		        'height'      => $height,
+				'checkdigit'  => $checkdigit,
+		        'filename'    => $filename
+			);
+
+		return $ret;
+    }
+
+    function _Dump() {
+        var_dump($this->argv);
+    }
+
+    function GetNum() {
+        return $this->argc-1;
+    }
+}
+
+//----------------------------------------------------------------------
+// CLASS Driver
+// Main driver class to create barcodes with the parmeters specified on
+// the command line.
+//----------------------------------------------------------------------
+class Driver {
+
+	private $iParams;
+	static public $silent=false;
+
+	static public function ErrHandlerPS(Exception $e) {
+		if( !Driver::$silent )
+			fwrite(STDERR,$e->getMessage()."\n");
+        exit(1);
+	}
+
+	static public function ErrHandlerImg(Exception $e) {
+		if( !Driver::$silent )
+			fwrite(STDERR,$e->getMessage()."\n");
+        $errobj = new JpGraphErrObjectImg();
+        $errobj->Raise($e->getMessage());
+        exit(1);
+	}
+
+	function Run($aParams) {
+
+		$this->iParams = $aParams;
+
+		Driver::$silent = $aParams['silent'];
+
+		$encoder = BarcodeFactory::Create($aParams['barcode']);
+		$encoder->AddChecksum($aParams['checkdigit']);
+		switch( $aParams['output'] ) {
+			case 0:
+				$e = BackendFactory::Create(BACKEND_IMAGE,$encoder);
+				set_exception_handler(array('Driver','ErrHandlerImg'));
+				break;
+			case 1:
+				$e = BackendFactory::Create(BACKEND_PS,$encoder);
+				set_exception_handler(array('Driver','ErrHandlerPS'));
+				break;
+			case 2:
+				$e = BackendFactory::Create(BACKEND_PS,$encoder);
+				$e->SetEPS();
+				set_exception_handler(array('Driver','ErrHandlerPS'));
+				break;
+		}
+		$e->SetHeight($aParams['height']);
+		$e->SetVertical($aParams['rotate']);
+		$e->SetModuleWidth($aParams['modulewidth']);
+		$e->SetScale($aParams['scale']);
+		$e->HideText($aParams['hide']);
+		if( $aParams['output'] === 0 ) {
+			$err = $e->Stroke($aParams['data'], $aParams['filename']);
+		}
+		else {
+			$s = $e->Stroke($aParams['data'], $aParams['filename']);
+			if( $aParams['filename'] == '' ) {
+				// If no filename specified then return the generated postscript
+				echo $s;
+			}
+		}
+	}
+}
+
+$pa = new ParseArgs();
+$params = $pa->Get();
+$driver = new Driver();
+$driver->Run($params);
+
+// Successfull termination
+exit(0);
+
+?>
diff --git a/web/classes/jpgraph/contour_dev/findpolygon.php b/web/classes/jpgraph/contour_dev/findpolygon.php
new file mode 100644
index 0000000000000000000000000000000000000000..4d105280ff5925ea026436281e80d14cf04bd8ae
--- /dev/null
+++ b/web/classes/jpgraph/contour_dev/findpolygon.php
@@ -0,0 +1,798 @@
+<?php
+require_once '../jpgraph.php';
+require_once '../jpgraph_canvas.php';
+require_once '../jpgraph_canvtools.php';
+/* 
+ * To change this template, choose Tools | Templates
+ * and open the template in the editor.
+ */
+
+/**
+ * Description of test_findpolygon
+ *
+ * @author ljp
+ */
+class Findpolygon {
+    private $nbrContours=-1;
+    public $contourCoord=array();
+    private $scale = array(0,6,0,8);
+
+    function flattenEdges($p) {
+        $fp=array();
+        for ($i = 0 ; $i < count($p) ; $i++) {
+            $fp[] = $p[$i][0];
+            $fp[] = $p[$i][1];
+        }
+        return $fp;
+    }
+
+    function SetupTestData() {
+    //        for($i=0; $i<count($this->contourCoord[0]); ++$i) {
+    //            echo '('.$this->contourCoord[0][$i][0][0].','.$this->contourCoord[0][$i][0][1].') -> '.
+    //            '('.$this->contourCoord[0][$i][1][0].','.$this->contourCoord[0][$i][1][1].")\n";
+    //        }
+    //
+
+        $c=0;
+        $p[$c] = array(0.6,1, 1,0.5, 2,0.5, 3,0.5, 3.5,1, 3.5,2, 3,2.5, 2,2.5, 1,2.5, 0.5,2, 0.6,1);
+        $c++;
+        $p[$c] = array(6,0.5, 5.5,1, 5.5,2, 6,2.5);
+
+        $this->nbrContours = $c+1;
+
+        for ($c = 0 ; $c < count($p) ; $c++) {
+            $n=count($p[$c]);
+
+            $this->contourCoord[$c][0] = array(array($p[$c][0],$p[$c][1]),array($p[$c][2],$p[$c][3]));
+            $k=1;
+            for ($i = 0; $i < ($n-4)/2; $i++, $k++) {
+                $this->contourCoord[$c][$k] = array($this->contourCoord[$c][$k-1][1], array($p[$c][2*$k+2],$p[$c][2*$k+1+2]));
+            }
+
+            // Swap edges order at random
+            $n = count($this->contourCoord[$c]);
+            for($i=0; $i < floor($n/2); ++$i) {
+                $swap1 = rand(0,$n-1);
+                $t = $this->contourCoord[$c][$swap1];
+                while( $swap1 == ($swap2 = rand(0,$n-1)) )
+                    ;
+                $this->contourCoord[$c][$swap1] = $this->contourCoord[$c][$swap2];
+                $this->contourCoord[$c][$swap2] = $t;
+            }
+
+            // Swap vector direction on 1/3 of the edges
+            for ($i = 0 ; $i < floor(count($this->contourCoord[$c])/3) ; $i++) {
+                $e = rand(0, count($this->contourCoord[$c])-1);
+                $edge = $this->contourCoord[$c][$e];
+                $v1 = $edge[0]; $v2 = $edge[1];
+                $this->contourCoord[$c][$e][0] = $v2;
+                $this->contourCoord[$c][$e][1] = $v1;
+            }
+        }
+
+        $pp = array();
+        for($j=0; $j < count($p); ++$j ) {
+            for( $i=0; $i < count($p[$j])/2; ++$i ) {
+                $pp[$j][$i] = array($p[$j][2*$i],$p[$j][2*$i+1]);
+            }
+        }
+        return $pp;
+    }
+
+    function p_edges($v) {
+        for ($i = 0 ; $i < count($v) ; $i++) {
+            echo "(".$v[$i][0][0].",".$v[$i][0][1].") -> (".$v[$i][1][0].",".$v[$i][1][1].")\n";
+        }
+        echo "\n";
+    }
+
+    function CompareCyclic($a,$b,$forward=true) {
+
+    // We assume disjoint vertices and if last==first this just means
+    // that the polygon is closed. For this comparison it must be unique
+    // elements
+        if( $a[count($a)-1] == $a[0] ) {
+            array_pop($a);
+        }
+        if( $b[count($b)-1] == $b[0] ) {
+            array_pop($b);
+        }
+
+        $n1 = count($a); $n2 = count($b);
+        if( $n1 != $n2 )
+            return false;
+
+        $i=0;
+        while( ($i < $n2) && ($a[0] != $b[$i]) )
+            ++$i;
+
+        if( $i >= $n2 )
+            return false;
+
+        $j=0;
+        if( $forward ) {
+            while( ($j < $n1) && ($a[$j] == $b[$i]) ) {
+                $i = ($i + 1) % $n2;
+                ++$j;
+            }
+        }
+        else {
+            while( ($j < $n1) && ($a[$j] == $b[$i]) ) {
+                --$i;
+                if( $i < 0 ) {
+                    $i = $n2-1;
+                }
+                ++$j;
+            }
+        }
+        return $j >= $n1;
+    }
+
+    function dbg($s) {
+    // echo $s."\n";
+    }
+
+    function IsVerticeOnBorder($x1,$y1) {
+    // Check if the vertice lies on any of the four border
+        if( $x1==$this->scale[0] || $x1==$this->scale[1] ) {
+            return true;
+        }
+        if( $y1==$this->scale[2] || $y1==$this->scale[3] ) {
+            return true;
+        }
+        return false;
+    }
+
+    function FindPolygons($debug=false) {
+
+        $pol = 0;
+        for ($c = 0; $c < $this->nbrContours; $c++) {
+
+            $this->dbg("\n** Searching polygon chain $c ... ");
+            $this->dbg("------------------------------------------\n");
+
+            $edges = $this->contourCoord[$c];
+            while( count($edges) > 0 ) {
+
+                $edge = array_shift($edges);
+                list($x1,$y1) = $edge[0];
+                list($x2,$y2) = $edge[1];
+                $polygons[$pol]=array(
+                    array($x1,$y1),array($x2,$y2)
+                );
+
+                $this->dbg("Searching on second vertice.");
+
+                $found=false;
+                if( ! $this->IsVerticeOnBorder($x2,$y2) ) {
+                    do {
+
+                        $this->dbg(" --Searching on edge: ($x1,$y1)->($x2,$y2)");
+
+                        $found=false;
+                        $nn = count($edges);
+                        for( $i=0; $i < $nn && !$found; ++$i ) {
+                            $edge = $edges[$i];
+                            if( $found = ($x2==$edge[0][0] && $y2==$edge[0][1]) ) {
+                                $polygons[$pol][] = array($edge[1][0],$edge[1][1]);
+                                $x1 = $x2; $y1 = $y2;
+                                $x2 = $edge[1][0]; $y2 = $edge[1][1];
+                            }
+                            elseif( $found = ($x2==$edge[1][0] && $y2==$edge[1][1]) ) {
+                                $polygons[$pol][] = array($edge[0][0],$edge[0][1]);
+                                $x1 = $x2; $y1 = $y2;
+                                $x2 = $edge[0][0]; $y2 = $edge[0][1];
+                            }
+                            if( $found ) {
+                                $this->dbg("    --Found next edge: [i=$i], (%,%) -> ($x2,$y2)");
+                                unset($edges[$i]);
+                                $edges = array_values($edges);
+                            }
+                        }
+
+                    } while( $found );
+                }
+
+                if( !$found && count($edges)>0 ) {
+                    $this->dbg("Searching on first vertice.");
+                    list($x1,$y1) = $polygons[$pol][0];
+                    list($x2,$y2) = $polygons[$pol][1];
+
+                    if( ! $this->IsVerticeOnBorder($x1,$y1) ) {
+                        do {
+
+                            $this->dbg(" --Searching on edge: ($x1,$y1)->($x2,$y2)");
+
+                            $found=false;
+                            $nn = count($edges);
+                            for( $i=0; $i < $nn && !$found; ++$i ) {
+                                $edge = $edges[$i];
+                                if( $found = ($x1==$edge[0][0] && $y1==$edge[0][1]) ) {
+                                    array_unshift($polygons[$pol],array($edge[1][0],$edge[1][1]));
+                                    $x2 = $x1; $y2 = $y1;
+                                    $x1 = $edge[1][0]; $y1 = $edge[1][1];
+                                }
+                                elseif( $found = ($x1==$edge[1][0] && $y1==$edge[1][1]) ) {
+                                    array_unshift($polygons[$pol],array($edge[0][0],$edge[0][1]));
+                                    $x2 = $x1; $y2 = $y1;
+                                    $x1 = $edge[0][0]; $y1 = $edge[0][1];
+                                }
+                                if( $found ) {
+                                    $this->dbg("    --Found next edge: [i=$i], ($x1,$y1) -> (%,%)");
+                                    unset($edges[$i]);
+                                    $edges = array_values($edges);
+                                }
+                            }
+
+                        } while( $found );
+                    }
+
+                }
+
+                $pol++;
+            }
+        }
+
+        return $polygons;
+    }
+
+}
+define('HORIZ_EDGE',0);
+define('VERT_EDGE',1);
+
+class FillGridRect {
+    private $edges,$dataPoints,$colors,$isoBars;
+    private $invert=false;
+
+    function __construct(&$edges,&$dataPoints,$isoBars,$colors) {
+        $this->edges = $edges;
+        $this->dataPoints = $dataPoints;
+        $this->colors = $colors;
+        $this->isoBars = $isoBars;
+    }
+
+    function GetIsobarColor($val) {
+        for ($i = 0 ; $i < count($this->isoBars) ; $i++) {
+            if( $val <= $this->isoBars[$i] ) {
+                return $this->colors[$i];
+            }
+        }
+        return $this->colors[$i]; // The color for all values above the highest isobar
+    }
+
+    function GetIsobarVal($a,$b) {
+    // Get the isobar that is between the values a and b
+    // If there are more isobars then return the one with lowest index
+        if( $b < $a ) {
+            $t=$a; $a=$b; $b=$t;
+        }
+        $i = 0 ;
+        $n = count($this->isoBars);
+        while( $i < $n && $this->isoBars[$i] < $a ) {
+            ++$i;
+        }
+        if( $i >= $n )
+            die("Internal error. Cannot find isobar values for ($a,$b)");
+        return $this->isoBars[$i];
+    }
+
+    function getCrossingCoord($aRow,$aCol,$aEdgeDir,$aIsobarVal) {
+    // In order to avoid numerical problem when two vertices are very close
+    // we have to check and avoid dividing by close to zero denumerator.
+        if( $aEdgeDir == HORIZ_EDGE ) {
+            $d = abs($this->dataPoints[$aRow][$aCol] - $this->dataPoints[$aRow][$aCol+1]);
+            if( $d > 0.001 ) {
+                $xcoord = $aCol + abs($aIsobarVal - $this->dataPoints[$aRow][$aCol]) / $d;
+            }
+            else {
+                $xcoord = $aCol;
+            }
+            $ycoord = $aRow;
+        }
+        else {
+            $d = abs($this->dataPoints[$aRow][$aCol] - $this->dataPoints[$aRow+1][$aCol]);
+            if( $d > 0.001 ) {
+                $ycoord = $aRow + abs($aIsobarVal - $this->dataPoints[$aRow][$aCol]) / $d;
+            }
+            else {
+                $ycoord = $aRow;
+            }
+            $xcoord = $aCol;
+        }
+        if( $this->invert ) {
+            $ycoord = $this->nbrRows-1 - $ycoord;
+        }
+        return array($xcoord,$ycoord);
+    }
+
+    function Fill(ContCanvas $canvas) {
+
+        $nx_vertices = count($this->dataPoints[0]);
+        $ny_vertices = count($this->dataPoints);
+
+        // Loop through all squares in the grid
+        for($col=0; $col < $nx_vertices-1; ++$col) {
+            for($row=0; $row < $ny_vertices-1; ++$row) {
+
+                $n = 0;$quad_edges=array();
+                if ( $this->edges[VERT_EDGE][$row][$col] )    $quad_edges[$n++] = array($row,  $col,  VERT_EDGE);
+                if ( $this->edges[VERT_EDGE][$row][$col+1] )  $quad_edges[$n++] = array($row,  $col+1,VERT_EDGE);
+                if ( $this->edges[HORIZ_EDGE][$row][$col] )   $quad_edges[$n++] = array($row,  $col,  HORIZ_EDGE);
+                if ( $this->edges[HORIZ_EDGE][$row+1][$col] ) $quad_edges[$n++] = array($row+1,$col,  HORIZ_EDGE);
+
+                if( $n == 0 ) {
+                // Easy, fill the entire quadrant with one color since we have no crossings
+                // Select the top left datapoint as representing this quadrant
+                // color for this quadrant
+                    $color = $this->GetIsobarColor($this->dataPoints[$row][$col]);
+                    $polygon = array($col,$row,$col,$row+1,$col+1,$row+1,$col+1,$row,$col,$row);
+                    $canvas->FilledPolygon($polygon,$color);
+
+                } elseif( $n==2 ) {
+
+                // There is one isobar edge crossing this quadrant. In order to fill we need to
+                // find out the orientation of the two areas this edge is separating in order to
+                // construct the two polygons that define the two areas to be filled
+                // There are six possible variants
+                // 0) North-South
+                // 1) West-East
+                // 2) West-North
+                // 3) East-North
+                // 4) West-South
+                // 5) East-South
+                    $type=-1;
+                    if( $this->edges[HORIZ_EDGE][$row][$col] ) {
+                        if( $this->edges[HORIZ_EDGE][$row+1][$col] ) $type=0; // North-South
+                        elseif( $this->edges[VERT_EDGE][$row][$col] ) $type=2;
+                        elseif( $this->edges[VERT_EDGE][$row][$col+1] ) $type=3;
+                    }
+                    elseif( $this->edges[HORIZ_EDGE][$row+1][$col] ) {
+                        if( $this->edges[VERT_EDGE][$row][$col] ) $type=4;
+                        elseif( $this->edges[VERT_EDGE][$row][$col+1] ) $type=5;
+                    }
+                    else {
+                        $type=1;
+                    }
+                    if( $type==-1 ) {
+                        die('Internal error: n=2 but no edges in the quadrant was find to determine type.');
+                    }
+
+                    switch( $type ) {
+                        case 0: //North-South
+
+                        // North vertice
+                            $v1 = $this->dataPoints[$row][$col];
+                            $v2 = $this->dataPoints[$row][$col+1];
+                            $isobarValue = $this->GetIsobarVal($v1, $v2);
+                            list($x1,$y1) = $this->getCrossingCoord($row, $col,HORIZ_EDGE, $isobarValue);
+
+                            // South vertice
+                            $v1 = $this->dataPoints[$row+1][$col];
+                            $v2 = $this->dataPoints[$row+1][$col+1];
+                            $isobarValue = $this->GetIsobarVal($v1, $v2);
+                            list($x2,$y2) = $this->getCrossingCoord($row+1, $col,HORIZ_EDGE, $isobarValue);
+
+                            $polygon = array($col,$row,$x1,$y1,$x2,$y2,$col,$row+1,$col,$row);
+                            $canvas->FilledPolygon($polygon,$this->GetIsobarColor($v1));
+
+                            $polygon = array($col+1,$row,$x1,$y1,$x2,$y2,$col+1,$row+1,$col+1,$row);
+                            $canvas->FilledPolygon($polygon,$this->GetIsobarColor($v2));
+
+                            break;
+
+                        case 1: // West-East
+
+                        // West vertice
+                            $v1 = $this->dataPoints[$row][$col];
+                            $v2 = $this->dataPoints[$row+1][$col];
+                            $isobarValue = $this->GetIsobarVal($v1, $v2);
+                            list($x1,$y1) = $this->getCrossingCoord($row, $col,VERT_EDGE, $isobarValue);
+
+                            // East vertice
+                            $v1 = $this->dataPoints[$row][$col+1];
+                            $v2 = $this->dataPoints[$row+1][$col+1];
+                            $isobarValue = $this->GetIsobarVal($v1, $v2);
+                            list($x2,$y2) = $this->getCrossingCoord($row, $col+1,VERT_EDGE, $isobarValue);
+
+                            $polygon = array($col,$row,$x1,$y1,$x2,$y2,$col+1,$row,$col,$row);
+                            $canvas->FilledPolygon($polygon,$this->GetIsobarColor($v1));
+
+                            $polygon = array($col,$row+1,$x1,$y1,$x2,$y2,$col+1,$row+1,$col,$row+1);
+                            $canvas->FilledPolygon($polygon,$this->GetIsobarColor($v2));
+                            break;
+
+                        case 2: // West-North
+
+                        // West vertice
+                            $v1 = $this->dataPoints[$row][$col];
+                            $v2 = $this->dataPoints[$row+1][$col];
+                            $isobarValue = $this->GetIsobarVal($v1, $v2);
+                            list($x1,$y1) = $this->getCrossingCoord($row, $col,VERT_EDGE, $isobarValue);
+
+                            // North vertice
+                            $v1 = $this->dataPoints[$row][$col];
+                            $v2 = $this->dataPoints[$row][$col+1];
+                            $isobarValue = $this->GetIsobarVal($v1, $v2);
+                            list($x2,$y2) = $this->getCrossingCoord($row, $col,HORIZ_EDGE, $isobarValue);
+
+                            $polygon = array($col,$row,$x1,$y1,$x2,$y2,$col,$row);
+                            $canvas->FilledPolygon($polygon,$this->GetIsobarColor($v1));
+
+                            $polygon = array($x1,$y1,$x2,$y2,$col+1,$row,$col+1,$row+1,$col,$row+1,$x1,$y1);
+                            $canvas->FilledPolygon($polygon,$this->GetIsobarColor($v2));
+
+                            break;
+
+                        case 3: // East-North
+
+                        //                            if( $row==3 && $col==1 && $n==2 ) {
+                        //                                echo " ** East-North<br>";
+                        //                            }
+
+
+                        // East vertice
+                            $v1 = $this->dataPoints[$row][$col+1];
+                            $v2 = $this->dataPoints[$row+1][$col+1];
+                            $isobarValue = $this->GetIsobarVal($v1, $v2);
+                            list($x1,$y1) = $this->getCrossingCoord($row, $col+1,VERT_EDGE, $isobarValue);
+                            //
+                            //                            if( $row==3 && $col==1 && $n==2 ) {
+                            //                                echo "   ** E_val($v1,$v2), isobar=$isobarValue<br>";
+                            //                                echo "   ** E($x1,$y1)<br>";
+                            //                            }
+
+
+                            // North vertice
+                            $v1 = $this->dataPoints[$row][$col];
+                            $v2 = $this->dataPoints[$row][$col+1];
+                            $isobarValue = $this->GetIsobarVal($v1, $v2);
+                            list($x2,$y2) = $this->getCrossingCoord($row, $col,HORIZ_EDGE, $isobarValue);
+
+                            //                            if( $row==3 && $col==1 && $n==2 ) {
+                            //                                echo "   ** N_val($v1,$v2), isobar=$isobarValue<br>";
+                            //                                echo "   ** N($x2,$y2)<br>";
+                            //                            }
+                            //                            if( $row==3 && $col==1 && $n==2 )
+                            //                                $canvas->Line($x1,$y1,$x2,$y2,'blue');
+
+                            $polygon = array($x1,$y1,$x2,$y2,$col+1,$row,$x1,$y1);
+                            $canvas->FilledPolygon($polygon,$this->GetIsobarColor($v2));
+
+                            $polygon = array($col,$row,$x2,$y2,$x1,$y1,$col+1,$row+1,$col,$row+1,$col,$row);
+                            $canvas->FilledPolygon($polygon,$this->GetIsobarColor($v1));
+
+                            break;
+
+                        case 4: // West-South
+
+                        // West vertice
+                            $v1 = $this->dataPoints[$row][$col];
+                            $v2 = $this->dataPoints[$row+1][$col];
+                            $isobarValue = $this->GetIsobarVal($v1, $v2);
+                            list($x1,$y1) = $this->getCrossingCoord($row, $col,VERT_EDGE, $isobarValue);
+
+                            // South vertice
+                            $v1 = $this->dataPoints[$row+1][$col];
+                            $v2 = $this->dataPoints[$row+1][$col+1];
+                            $isobarValue = $this->GetIsobarVal($v1, $v2);
+                            list($x2,$y2) = $this->getCrossingCoord($row+1, $col,HORIZ_EDGE, $isobarValue);
+
+                            $polygon = array($col,$row+1,$x1,$y1,$x2,$y2,$col,$row+1);
+                            $canvas->FilledPolygon($polygon,$this->GetIsobarColor($v1));
+
+                            $polygon = array($x1,$y1,$x2,$y2,$col+1,$row+1,$col+1,$row,$col,$row,$x1,$y1);
+                            $canvas->FilledPolygon($polygon,$this->GetIsobarColor($v2));
+
+                            break;
+
+                        case 5: // East-South
+
+                        //
+                        //                            if( $row==1 && $col==1 && $n==2 ) {
+                        //                                echo " ** Sout-East<br>";
+                        //                            }
+
+                        // East vertice
+                            $v1 = $this->dataPoints[$row][$col+1];
+                            $v2 = $this->dataPoints[$row+1][$col+1];
+                            $isobarValue = $this->GetIsobarVal($v1, $v2);
+                            list($x1,$y1) = $this->getCrossingCoord($row, $col+1,VERT_EDGE, $isobarValue);
+
+                            //                            if( $row==1 && $col==1 && $n==2 ) {
+                            //                                echo "   ** E_val($v1,$v2), isobar=$isobarValue<br>";
+                            //                                echo "   ** E($x1,$y1)<br>";
+                            //                            }
+
+                            // South vertice
+                            $v1 = $this->dataPoints[$row+1][$col];
+                            $v2 = $this->dataPoints[$row+1][$col+1];
+                            $isobarValue = $this->GetIsobarVal($v1, $v2);
+                            list($x2,$y2) = $this->getCrossingCoord($row+1, $col,HORIZ_EDGE, $isobarValue);
+
+                            //                            if( $row==1 && $col==1 && $n==2 ) {
+                            //                                echo "   ** S_val($v1,$v2), isobar=$isobarValue<br>";
+                            //                                echo "   ** S($x2,$y2)<br>";
+                            //                            }
+
+                            $polygon = array($col+1,$row+1,$x1,$y1,$x2,$y2,$col+1,$row+1);
+                            $canvas->FilledPolygon($polygon,$this->GetIsobarColor($v2));
+
+                            $polygon = array($x1,$y1,$x2,$y2,$col,$row+1,$col,$row,$col+1,$row,$x1,$y1);
+                            $canvas->FilledPolygon($polygon,$this->GetIsobarColor($v1));
+
+                            break;
+
+                    }
+
+                }
+
+            }
+        }
+
+    }
+}
+
+
+class ContCanvas {
+    public $g;
+    public $shape,$scale;
+    function __construct($xmax=6,$ymax=6,$width=400,$height=400) {
+
+        $this->g = new CanvasGraph($width,$height);
+        $this->scale = new CanvasScale($this->g, 0, $xmax, 0, $ymax);
+        $this->shape = new Shape($this->g, $this->scale);
+
+        //$this->g->SetFrame(true);
+        $this->g->SetMargin(5,5,5,5);
+        $this->g->SetMarginColor('white@1');
+        $this->g->InitFrame();
+
+
+        $this->shape->SetColor('gray');
+        for( $col=1; $col<$xmax; ++$col ) {
+            $this->shape->Line($col, 0, $col, $ymax);
+        }
+        for( $row=1; $row<$ymax; ++$row ) {
+            $this->shape->Line(0, $row, $xmax, $row);
+        }
+    }
+
+    function SetDatapoints($datapoints) {
+        $ny=count($datapoints);
+        $nx=count($datapoints[0]);
+        $t = new Text();
+        $t->SetFont(FF_ARIAL,FS_NORMAL,8);
+        for( $x=0; $x < $nx; ++$x ) {
+            for( $y=0; $y < $ny; ++$y ) {
+                list($x1,$y1) = $this->scale->Translate($x,$y);
+
+                if( $datapoints[$y][$x] > 0 )
+                    $t->SetColor('blue');
+                else
+                    $t->SetColor('black');
+                $t->SetFont(FF_ARIAL,FS_BOLD,8);
+                $t->Set($datapoints[$y][$x]);
+                $t->Stroke($this->g->img,$x1,$y1);
+
+                $t->SetColor('gray');
+                $t->SetFont(FF_ARIAL,FS_NORMAL,8);
+                $t->Set("($y,$x)");
+                $t->Stroke($this->g->img,$x1+10,$y1);
+
+            }
+        }
+    }
+
+    function DrawLinePolygons($p,$color='red') {
+        $this->shape->SetColor($color);
+        for ($i = 0 ; $i < count($p) ; $i++) {
+            $x1 = $p[$i][0][0]; $y1 = $p[$i][0][1];
+            for ($j = 1 ; $j < count($p[$i]) ; $j++) {
+                $x2=$p[$i][$j][0]; $y2 = $p[$i][$j][1];
+                $this->shape->Line($x1, $y1, $x2, $y2);
+                $x1=$x2; $y1=$y2;
+            }
+        }
+    }
+
+    function Line($x1,$y1,$x2,$y2,$color='red') {
+        $this->shape->SetColor($color);
+        $this->shape->Line($x1, $y1, $x2, $y2);
+    }
+    function Polygon($p,$color='blue') {
+        $this->shape->SetColor($color);
+        $this->shape->Polygon($p);
+    }
+
+    function FilledPolygon($p,$color='lightblue') {
+        $this->shape->SetColor($color);
+        $this->shape->FilledPolygon($p);
+    }
+
+    function Point($x,$y,$color) {
+        list($x1,$y1) = $this->scale->Translate($x, $y);
+        $this->shape->SetColor($color);
+        $this->g->img->Point($x1,$y1);
+    }
+
+    function Stroke() {
+        $this->g->Stroke();
+    }
+
+}
+
+
+class PixelFill {
+
+    private $edges,$dataPoints,$colors,$isoBars;
+
+    function __construct(&$edges,&$dataPoints,$isoBars,$colors) {
+        $this->edges = $edges;
+        $this->dataPoints = $dataPoints;
+        $this->colors = $colors;
+        $this->isoBars = $isoBars;
+    }
+
+    function GetIsobarColor($val) {
+        for ($i = 0 ; $i < count($this->isoBars) ; $i++) {
+            if( $val <= $this->isoBars[$i] ) {
+                return $this->colors[$i];
+            }
+        }
+        return $this->colors[$i]; // The color for all values above the highest isobar
+    }
+
+    function Fill(ContCanvas $canvas) {
+
+        $nx_vertices = count($this->dataPoints[0]);
+        $ny_vertices = count($this->dataPoints);
+
+        // Loop through all squares in the grid
+        for($col=0; $col < $nx_vertices-1; ++$col) {
+            for($row=0; $row < $ny_vertices-1; ++$row) {
+
+                $v=array(
+                    $this->dataPoints[$row][$col],
+                    $this->dataPoints[$row][$col+1],
+                    $this->dataPoints[$row+1][$col+1],
+                    $this->dataPoints[$row+1][$col],
+                );
+                
+                list($x1,$y1) = $canvas->scale->Translate($col, $row);
+                list($x2,$y2) = $canvas->scale->Translate($col+1, $row+1);
+
+                for( $x=$x1; $x < $x2; ++$x ) {
+                    for( $y=$y1; $y < $y2; ++$y ) {
+
+                        $v1 = $v[0] + ($v[1]-$v[0])*($x-$x1)/($x2-$x1);
+                        $v2 = $v[3] + ($v[2]-$v[3])*($x-$x1)/($x2-$x1);
+                        $val = $v1 + ($v2-$v1)*($y-$y1)/($y2-$y1);
+
+                        if( $row==2 && $col==2 ) {
+                            //echo " ($val ($x,$y)) (".$v[0].",".$v[1].",".$v[2].",".$v[3].")<br>";
+                        }
+                        $color = $this->GetIsobarColor($val);
+                        $canvas->g->img->SetColor($color);
+                        $canvas->g->img->Point($x, $y);
+                    }
+                }
+            }
+        }
+
+    }
+
+}
+
+$edges=array(array(),array(),array());
+$datapoints=array();
+for($col=0; $col<6; $col++) {
+    for($row=0; $row<6; $row++) {
+        $datapoints[$row][$col]=0;
+        $edges[VERT_EDGE][$row][$col] = false;
+        $edges[HORIZ_EDGE][$row][$col] = false;
+    }
+}
+
+$datapoints[1][2] = 2;
+$datapoints[2][1] = 1;
+$datapoints[2][2] = 7;
+$datapoints[2][3] = 2;
+$datapoints[3][1] = 2;
+$datapoints[3][2] = 17;
+$datapoints[3][3] = 4;
+$datapoints[4][2] = 3;
+
+$datapoints[1][4] = 12;
+
+$edges[VERT_EDGE][1][2] = true;
+$edges[VERT_EDGE][3][2] = true;
+
+$edges[HORIZ_EDGE][2][1] = true;
+$edges[HORIZ_EDGE][2][2] = true;
+$edges[HORIZ_EDGE][3][1] = true;
+$edges[HORIZ_EDGE][3][2] = true;
+
+
+
+$isobars = array(5,10,15);
+$colors = array('lightgray','lightblue','lightred','red');
+
+$engine = new PixelFill($edges, $datapoints, $isobars, $colors);
+$canvas = new ContCanvas();
+$engine->Fill($canvas);
+$canvas->SetDatapoints($datapoints);
+$canvas->Stroke();
+die();
+
+
+//$tst = new Findpolygon();
+//$p1 = $tst->SetupTestData();
+//
+//$canvas = new ContCanvas();
+//for ($i = 0 ; $i < count($tst->contourCoord); $i++) {
+//    $canvas->DrawLinePolygons($tst->contourCoord[$i]);
+//}
+//
+//$p2 = $tst->FindPolygons();
+//for ($i = 0 ; $i < count($p2) ; $i++) {
+//    $canvas->FilledPolygon($tst->flattenEdges($p2[$i]));
+//}
+//
+//for ($i = 0 ; $i < count($p2) ; $i++) {
+//    $canvas->Polygon($tst->flattenEdges($p2[$i]));
+//}
+//
+//$canvas->Stroke();
+//die();
+
+
+//for( $trial = 0; $trial < 1; ++$trial ) {
+//    echo "\nTest $trial:\n";
+//    echo "========================================\n";
+//    $tst = new Findpolygon();
+//    $p1 = $tst->SetupTestData();
+//
+//    //    for ($i = 0 ; $i < count($p1) ; $i++) {
+//    //        echo "Test polygon $i:\n";
+//    //        echo "---------------------\n";
+//    //        $tst->p_edges($tst->contourCoord[$i]);
+//    //        echo "\n";
+//    //    }
+//    //
+//    $p2 = $tst->FindPolygons();
+//    $npol = count($p2);
+//    //echo "\n** Found $npol separate polygon chains.\n\n";
+//
+//    for( $i=0; $i<$npol; ++$i ) {
+//
+//        $res_forward = $tst->CompareCyclic($p1[$i], $p2[$i],true);
+//        $res_backward = $tst->CompareCyclic($p1[$i], $p2[$i],false);
+//        if( $res_backward || $res_forward ) {
+//        //            if( $res_forward )
+//        //                echo "Forward matches!\n";
+//        //            else
+//        //                echo "Backward matches!\n";
+//        }
+//        else {
+//            echo "********** NO MATCH!!.\n\n";
+//            echo "\nBefore find:\n";
+//            for ($j = 0 ; $j < count($p1[$i]) ; $j++) {
+//                echo "(".$p1[$i][$j][0].','.$p1[$i][$j][1]."), ";
+//            }
+//            echo "\n";
+//
+//            echo "\nAfter find:\n";
+//            for ($j = 0 ; $j < count($p2[$i]) ; $j++) {
+//                echo "(".$p2[$i][$j][0].','.$p2[$i][$j][1]."), ";
+//            }
+//            echo "\n";
+//        }
+//
+//    }
+//}
+//
+//echo "\n\nAll tests ready.\n\n";
+//
+
+
+?>
diff --git a/web/classes/jpgraph/contour_dev/tri-quad.php b/web/classes/jpgraph/contour_dev/tri-quad.php
new file mode 100644
index 0000000000000000000000000000000000000000..7281f8e3690fa183be2f238e4cbb8b1dfeec1193
--- /dev/null
+++ b/web/classes/jpgraph/contour_dev/tri-quad.php
@@ -0,0 +1,790 @@
+<?php
+require_once '../jpgraph.php';
+require_once '../jpgraph_canvas.php';
+require_once '../jpgraph_canvtools.php';
+
+
+class ContCanvas {
+    public $g;
+    public $shape,$scale;
+    function __construct($xmax=5,$ymax=5,$width=350,$height=350) {
+
+        $this->g = new CanvasGraph($width,$height);
+        $this->scale = new CanvasScale($this->g, 0, $xmax, 0, $ymax);
+        $this->shape = new Shape($this->g, $this->scale);
+
+        //$this->g->SetFrame(true);
+        $this->g->SetMargin(2,2,2,2);
+        $this->g->SetMarginColor('white@1');
+        $this->g->InitFrame();
+    }
+
+    function StrokeGrid() {
+        list($xmin,$xmax,$ymin,$ymax) = $this->scale->Get();
+        $this->shape->SetColor('gray');
+        for( $col=1; $col<$xmax; ++$col ) {
+            $this->shape->Line($col, 0, $col, $ymax);
+        }
+        for( $row=1; $row<$ymax; ++$row ) {
+            $this->shape->Line(0, $row, $xmax, $row);
+        }
+    }
+
+    function SetDatapoints($datapoints) {
+        $ny=count($datapoints);
+        $nx=count($datapoints[0]);
+        $t = new Text();
+        $t->SetFont(FF_ARIAL,FS_NORMAL,8);
+        for( $x=0; $x < $nx; ++$x ) {
+            for( $y=0; $y < $ny; ++$y ) {
+                list($x1,$y1) = $this->scale->Translate($x,$y);
+
+                if( $datapoints[$y][$x] > 0 )
+                    $t->SetColor('blue');
+                else
+                    $t->SetColor('black');
+                $t->SetFont(FF_ARIAL,FS_BOLD,8);
+                $t->Set($datapoints[$y][$x]);
+                $t->Stroke($this->g->img,$x1,$y1);
+
+                $t->SetColor('gray');
+                $t->SetFont(FF_ARIAL,FS_NORMAL,8);
+                $t->Set("($y,$x)");
+                $t->Stroke($this->g->img,$x1+10,$y1);
+
+            }
+        }
+    }
+
+    function DrawLinePolygons($p,$color='red') {
+        $this->shape->SetColor($color);
+        for ($i = 0 ; $i < count($p) ; $i++) {
+            $x1 = $p[$i][0][0]; $y1 = $p[$i][0][1];
+            for ($j = 1 ; $j < count($p[$i]) ; $j++) {
+                $x2=$p[$i][$j][0]; $y2 = $p[$i][$j][1];
+                $this->shape->Line($x1, $y1, $x2, $y2);
+                $x1=$x2; $y1=$y2;
+            }
+        }
+    }
+
+    function Line($x1,$y1,$x2,$y2,$color='red') {
+        $this->shape->SetColor($color);
+        $this->shape->Line($x1, $y1, $x2, $y2);
+    }
+    function Polygon($p,$color='blue') {
+        $this->shape->SetColor($color);
+        $this->shape->Polygon($p);
+    }
+
+    function FilledPolygon($p,$color='lightblue') {
+        $this->shape->SetColor($color);
+        $this->shape->FilledPolygon($p);
+    }
+
+    function Point($x,$y,$color) {
+        list($x1,$y1) = $this->scale->Translate($x, $y);
+        $this->shape->SetColor($color);
+        $this->g->img->Point($x1,$y1);
+    }
+
+    function Stroke() {
+        $this->g->Stroke();
+    }
+
+}
+
+// Calculate the area for a simple polygon. This will not work for
+// non-simple polygons, i.e. self crossing.
+function polygonArea($aX, $aY) {
+    $n = count($aX);
+    $area = 0 ;
+    $j = 0 ;
+    for ($i=0; $i < $n; $i++) {
+        $j++;
+        if ( $j == $n) {
+            $j=0;
+        }
+        $area += ($aX[i]+$aX[j])*($aY[i]-$aY[j]);
+    }
+    return area*.5;
+}
+
+class SingleTestTriangle {
+    const contval=5;
+    static $maxdepth=2;
+    static $cnt=0;
+    static $t;
+    public $g;
+    public $shape,$scale;
+    public $cont = array(2,4,5);
+    public $contcolors = array('yellow','purple','seagreen','green','lightblue','blue','teal','orange','red','darkred','brown');
+    public $dofill=false;
+    public $showtriangulation=false,$triangulation_color="lightgray";
+    public $showannotation=false;
+    public $contlinecolor='black',$showcontlines=true;
+    private $labels = array(), $showlabels=false;
+    private $labelColor='black',$labelFF=FF_ARIAL,$labelFS=FS_BOLD,$labelFSize=9;
+
+    function __construct($width,$height,$nx,$ny) {
+        $xmax=$nx+0.1;$ymax=$ny+0.1;
+        $this->g = new CanvasGraph($width,$height);
+        $this->scale = new CanvasScale($this->g, -0.1, $xmax, -0.1, $ymax);
+        $this->shape = new Shape($this->g, $this->scale);
+
+        //$this->g->SetFrame(true);
+        $this->g->SetMargin(2,2,2,2);
+        $this->g->SetMarginColor('white@1');
+        //$this->g->InitFrame();
+
+        self::$t = new Text();
+        self::$t->SetColor('black');        
+        self::$t->SetFont(FF_ARIAL,FS_BOLD,9);
+        self::$t->SetAlign('center','center');
+    }
+
+    function getPlotSize() {
+        return array($this->g->img->width,$this->g->img->height);
+    }
+
+    function SetContours($c) {
+        $this->cont = $c;
+    }
+
+    function ShowLabels($aFlg=true) {
+        $this->showlabels = $aFlg;
+    }
+
+    function ShowLines($aFlg=true) {
+        $this->showcontlines=$aFlg;
+    }
+
+    function SetFilled($f=true) {
+        $this->dofill = $f;
+    }
+
+    function ShowTriangulation($f=true) {
+        $this->showtriangulation = $f;
+    }
+
+    function Stroke() {
+        $this->g->Stroke();
+    }
+
+    function FillPolygon($color,&$p) {
+        self::$cnt++;
+        if( $this->dofill ) {
+            $this->shape->SetColor($color);
+            $this->shape->FilledPolygon($p);
+        }
+        if( $this->showtriangulation ) {
+            $this->shape->SetColor($this->triangulation_color);
+            $this->shape->Polygon($p);
+        }
+    }
+    
+    function GetNextHigherContourIdx($val) {
+        for( $i=0; $i < count($this->cont); ++$i ) {
+            if( $val < $this->cont[$i] ) return $i;
+        }
+        return count($this->cont);
+    }
+
+    function GetContVal($v1) {
+        for( $i=0; $i < count($this->cont); ++$i ) {
+            if( $this->cont[$i] > $v1 ) {
+                return $this->cont[$i];
+            }
+        }
+        die('No contour value is larger or equal than : '.$v1);
+    }
+    
+    function GetColor($v) {
+        return $this->contcolors[$this->GetNextHigherContourIdx($v)];
+    }
+
+    function storeAnnotation($x1,$y1,$v1,$angle) {
+        $this->labels[$this->GetNextHigherContourIdx($v1)][] = array($x1,$y1,$v1,$angle);
+    }
+
+    function labelProx($x1,$y1,$v1) {
+
+        list($w,$h) = $this->getPlotSize();
+
+
+        if( $x1 < 20 || $x1 > $w-20 )
+            return true;
+
+        if( $y1 < 20 || $y1 > $h-20 )
+            return true;
+            
+        if( !isset ($this->labels[$this->GetNextHigherContourIdx($v1)]) ) {
+            return false;
+        }
+        $p = $this->labels[$this->GetNextHigherContourIdx($v1)];
+        $n = count($p);
+        $d = 999999;
+        for ($i = 0 ; $i < $n ; $i++) {
+            $xp = $p[$i][0];
+            $yp = $p[$i][1];
+            $d = min($d, ($x1-$xp)*($x1-$xp) + ($y1-$yp)*($y1-$yp));
+        }
+        
+        $limit = $w*$h/9;
+        $limit = max(min($limit,20000),3500);
+        if( $d < $limit ) return true;
+        else return false;
+    }
+
+    function putLabel($x1,$y1,$x2,$y2,$v1) {
+
+        $angle = 0;
+        if( $x2 - $x1 != 0 ) {
+            $grad = ($y2-$y1)/($x2-$x1);
+            $angle = -(atan($grad) * 180/M_PI);
+            self::$t->SetAngle($angle);
+        }
+
+        $x = $this->scale->TranslateX($x1);
+        $y = $this->scale->TranslateY($y1);
+        if( !$this->labelProx($x, $y, $v1) ) {
+            $this->storeAnnotation($x, $y, $v1, $angle);
+        }
+    }
+
+    function strokeLabels() {
+        $t = new Text();
+        $t->SetColor($this->labelColor);
+        $t->SetFont($this->labelFF,$this->labelFS,$this->labelFSize);
+        $t->SetAlign('center','center');
+
+        foreach ($this->labels as $cont_idx => $pos) {
+            if( $cont_idx >= 10 ) return;
+            foreach ($pos as $idx => $coord) {
+                $t->Set( sprintf("%.1f",$coord[2]) );
+                $t->SetAngle($coord[3]);
+                $t->Stroke($this->g->img,$coord[0],$coord[1]);
+            }
+        }
+    }
+
+    function annotate($x1,$y1,$x2,$y2,$x1p,$y1p,$v1,$v2,$v1p) {
+        if( !$this->showannotation ) return;
+        /*
+        $this->g->img->SetColor('green');
+        $this->g->img->FilledCircle($this->scale->TranslateX($x1),$this->scale->TranslateY($y1), 4);
+        $this->g->img->FilledCircle($this->scale->TranslateX($x2),$this->scale->TranslateY($y2), 4);
+
+        $this->g->img->SetColor('red');
+        $this->g->img->FilledCircle($this->scale->TranslateX($x1p),$this->scale->TranslateY($y1p), 4);
+*/
+        //self::$t->Set(sprintf("%.1f",$v1,$this->VC($v1)));
+        //self::$t->Stroke($this->g->img,$this->scale->TranslateX($x1),$this->scale->TranslateY($y1));
+        //self::$t->Set(sprintf("%.1f",$v2,$this->VC($v2)));
+        //self::$t->Stroke($this->g->img,$this->scale->TranslateX($x2),$this->scale->TranslateY($y2));
+
+        $x = $this->scale->TranslateX($x1p);
+        $y = $this->scale->TranslateY($y1p);
+        if( !$this->labelProx($x, $y, $v1p) ) {
+            $this->storeAnnotation($x, $y, $v1p);
+            self::$t->Set(sprintf("%.1f",$v1p,$this->VC($v1p)));
+            self::$t->Stroke($this->g->img,$x,$y);
+        }
+    }
+
+    function Pertubate(&$v1,&$v2,&$v3,&$v4) {
+        $pert = 0.9999;
+        $n = count($this->cont);
+        for($i=0; $i < $n; ++$i) {
+            if( $v1==$this->cont[$i] ) {
+                $v1 *= $pert;
+                break;
+            }
+        }
+        for($i=0; $i < $n; ++$i) {
+            if( $v2==$this->cont[$i] ) {
+                $v2 *= $pert;
+                break;
+            }
+        }
+        for($i=0; $i < $n; ++$i) {
+            if( $v3==$this->cont[$i] ) {
+                $v3 *= $pert;
+                break;
+            }
+        }
+        for($i=0; $i < $n; ++$i) {
+            if( $v4==$this->cont[$i] ) {
+                $v4 *= $pert;
+                break;
+            }
+        }
+    }
+
+    function interp2($x1,$y1,$x2,$y2,$v1,$v2) {
+        $cv = $this->GetContVal(min($v1,$v2));
+        $alpha = ($v1-$cv)/($v1-$v2);
+        $x1p = $x1*(1-$alpha) + $x2*$alpha;
+        $y1p = $y1*(1-$alpha) + $y2*$alpha;
+        $v1p = $v1 + $alpha*($v2-$v1);
+        return array($x1p,$y1p,$v1p);
+    }
+
+    function RectFill($v1,$v2,$v3,$v4,$x1,$y1,$x2,$y2,$x3,$y3,$x4,$y4,$depth) {
+         if( $depth >= self::$maxdepth ) {
+            // Abort and just appoximate the color of this area
+            // with the average of the three values
+            $color = $this->GetColor(($v1+$v2+$v3+$v4)/4);
+            $p = array($x1, $y1, $x2, $y2, $x3, $y3, $x4, $y4, $x1, $y1);
+            $this->FillPolygon($color,$p) ;
+        }
+        else {
+
+            $this->Pertubate($v1,$v2,$v3,$v4);
+
+            $fcnt = 0 ;
+            $vv1 = $this->GetNextHigherContourIdx($v1);
+            $vv2 = $this->GetNextHigherContourIdx($v2);
+            $vv3 = $this->GetNextHigherContourIdx($v3);
+            $vv4 = $this->GetNextHigherContourIdx($v4);
+            $eps = 0.0001;
+
+           if( $vv1 == $vv2 && $vv2 == $vv3 && $vv3 == $vv4 ) {
+                $color = $this->GetColor($v1);
+                $p = array($x1, $y1, $x2, $y2, $x3, $y3, $x4, $y4, $x1, $y1);
+                $this->FillPolygon($color,$p) ;
+            }
+            else {
+
+                $dv1 = abs($vv1-$vv2);
+                $dv2 = abs($vv2-$vv3);
+                $dv3 = abs($vv3-$vv4);
+                $dv4 = abs($vv1-$vv4);
+                
+                if( $dv1 == 1 ) {
+                    list($x1p,$y1p,$v1p) = $this->interp2($x1,$y1,$x2,$y2,$v1,$v2);
+                    $fcnt++;
+                }
+                
+                if( $dv2 == 1 ) {
+                    list($x2p,$y2p,$v2p) = $this->interp2($x2,$y2,$x3,$y3,$v2,$v3);
+                    $fcnt++;
+                }
+                
+                if( $dv3 == 1 ) {
+                    list($x3p,$y3p,$v3p) = $this->interp2($x3,$y3,$x4,$y4,$v3,$v4);
+                    $fcnt++;
+                }               
+
+                if( $dv4 == 1 ) {
+                    list($x4p,$y4p,$v4p) = $this->interp2($x4,$y4,$x1,$y1,$v4,$v1);
+                    $fcnt++;
+                }
+
+                $totdv = $dv1 + $dv2 + $dv3 + $dv4 ;
+                
+                if( ($fcnt == 2 && $totdv==2) || ($fcnt == 4 && $totdv==4) ) {
+
+                    if( $fcnt == 2 && $totdv==2 ) {
+
+                        if( $dv1 == 1 && $dv2 == 1) {
+                            $color1 = $this->GetColor($v2);
+                            $p1 = array($x1p,$y1p,$x2,$y2,$x2p,$y2p,$x1p,$y1p);
+                            $color2 = $this->GetColor($v4);
+                            $p2 = array($x1,$y1,$x1p,$y1p,$x2p,$y2p,$x3,$y3,$x4,$y4,$x1,$y1);
+
+                            $color = $this->GetColor($v1p);
+                            $p = array($x1p,$y1p,$x2p,$y2p);
+                            $v = $v1p;
+                        }
+                        elseif( $dv1 == 1 && $dv3 == 1 ) {
+                            $color1 = $this->GetColor($v2);
+                            $p1 = array($x1p,$y1p,$x2,$y2,$x3,$y3,$x3p,$y3p,$x1p,$y1p);
+                            $color2 = $this->GetColor($v4);
+                            $p2 = array($x1,$y1,$x1p,$y1p,$x3p,$y3p,$x4,$y4,$x1,$y1);
+
+                            $color = $this->GetColor($v1p);
+                            $p = array($x1p,$y1p,$x3p,$y3p);
+                            $v = $v1p;
+                        }
+                        elseif( $dv1 == 1 && $dv4 == 1 ) {
+                            $color1 = $this->GetColor($v1);
+                            $p1 = array($x1,$y1,$x1p,$y1p,$x4p,$y4p,$x1,$y1);
+                            $color2 = $this->GetColor($v3);
+                            $p2 = array($x1p,$y1p,$x2,$y2,$x3,$y3,$x4,$y4,$x4p,$y4p,$x1p,$y1p);
+
+                            $color = $this->GetColor($v1p);
+                            $p = array($x1p,$y1p,$x4p,$y4p);
+                            $v = $v1p;
+                        }
+                        elseif( $dv2 == 1 && $dv4 == 1 ) {
+                            $color1 = $this->GetColor($v1);
+                            $p1 = array($x1,$y1,$x2,$y2,$x2p,$y2p,$x4p,$y4p,$x1,$y1);
+                            $color2 = $this->GetColor($v3);
+                            $p2 = array($x4p,$y4p,$x2p,$y2p,$x3,$y3,$x4,$y4,$x4p,$y4p);
+
+                            $color = $this->GetColor($v2p);
+                            $p = array($x2p,$y2p,$x4p,$y4p);
+                            $v = $v2p;
+                        }
+                        elseif( $dv2 == 1 && $dv3 == 1 ) {
+                            $color1 = $this->GetColor($v1);
+                            $p1 = array($x1,$y1,$x2,$y2,$x2p,$y2p,$x3p,$y3p,$x4,$y4,$x1,$y1);
+                            $color2 = $this->GetColor($v3);
+                            $p2 = array($x2p,$y2p,$x3,$y3,$x3p,$y3p,$x2p,$y2p);
+
+                            $color = $this->GetColor($v2p);
+                            $p = array($x2p,$y2p,$x3p,$y3p);
+                            $v = $v2p;
+                        }
+                        elseif( $dv3 == 1 && $dv4 == 1 ) {
+                            $color1 = $this->GetColor($v1);
+                            $p1 = array($x1,$y1,$x2,$y2,$x3,$y3,$x3p,$y3p,$x4p,$y4p,$x1,$y1);
+                            $color2 = $this->GetColor($v4);
+                            $p2 = array($x4p,$y4p,$x3p,$y3p,$x4,$y4,$x4p,$y4p);
+
+                            $color = $this->GetColor($v4p);
+                            $p = array($x4p,$y4p,$x3p,$y3p);
+                            $v = $v4p;
+                        }
+
+                        $this->FillPolygon($color1,$p1);
+                        $this->FillPolygon($color2,$p2);
+
+                        if( $this->showcontlines ) {
+                            if( $this->dofill ) {
+                                $this->shape->SetColor($this->contlinecolor);
+                            }
+                            else {
+                                $this->shape->SetColor($color);
+                            }
+                            $this->shape->Line($p[0],$p[1],$p[2],$p[3]);
+                        }
+                        if( $this->showlabels ) {
+                            $this->putLabel( ($p[0]+$p[2])/2, ($p[1]+$p[3])/2, $p[2],$p[3] , $v);
+                        }
+                    }
+                    elseif( $fcnt == 4 && $totdv==4 ) {
+                        $vc = ($v1+$v2+$v3+$v4)/4;
+
+                        if( $v1p == $v2p && $v2p == $v3p && $v3p == $v4p ) {
+                            // Four edge crossings (saddle point) of the same contour
+                            // so we first need to
+                            // find out how the saddle is crossing "/" or "\"
+
+                            if( $this->GetNextHigherContourIdx($vc) == $this->GetNextHigherContourIdx($v1) ) {
+                                // "\"
+                                $color1 = $this->GetColor($v1);
+                                $p1 = array($x1,$y1,$x1p,$y1p,$x4p,$y4p,$x1,$y1);
+
+                                $color2 = $this->GetColor($v2);
+                                $p2 = array($x1p,$y1p,$x2,$y2,$x2p,$y2p,$x3p,$y3p,$x4,$y4,$x4p,$y4p,$x1p,$y1p);
+
+                                $color3 = $color1;
+                                $p3 = array($x2p,$y2p,$x3,$y3,$x3p,$y3p,$x2p,$y2p);
+
+                                $colorl1 = $this->GetColor($v1p);
+                                $pl1 = array($x1p,$y1p,$x4p,$y4p);
+                                $colorl2 = $this->GetColor($v2p);
+                                $pl2 = array($x2p,$y2p,$x3p,$y3p);
+                                $vl1 = $v1p; $vl2 = $v2p;
+
+                            }
+                            else {
+                                // "/"
+                                $color1 = $this->GetColor($v2);
+                                $p1 = array($x1p,$y1p,$x2,$y2,$x2p,$y2p,$x1p,$y1p);
+
+                                $color2 = $this->GetColor($v3);
+                                $p2 = array($x1p,$y1p,$x2p,$y2p,$x3,$y3,$x3p,$y3p,$x4p,$y4p,$x1,$y1,$x1p,$y1p);
+
+                                $color3 = $color1;
+                                $p3 = array($x4p,$y4p,$x3p,$y3p,$x4,$y4,$x4p,$y4p);
+
+                                $colorl1 = $this->GetColor($v1p);
+                                $pl1 = array($x1p,$y1p,$x2p,$y2p);
+                                $colorl2 = $this->GetColor($v4p);
+                                $pl2 = array($x4p,$y4p,$x3p,$y3p);
+                                $vl1 = $v1p; $vl2 = $v4p;
+                            }
+                        }
+                        else {
+                            // There are two different contours crossing so we need to find
+                            // out which belongs to which
+                            if( $v1p == $v2p ) {
+                                // "/"
+                                $color1 = $this->GetColor($v2);
+                                $p1 = array($x1p,$y1p,$x2,$y2,$x2p,$y2p,$x1p,$y1p);
+
+                                $color2 = $this->GetColor($v3);
+                                $p2 = array($x1p,$y1p,$x2p,$y2p,$x3,$y3,$x3p,$y3p,$x4p,$y4p,$x1,$y1,$x1p,$y1p);
+
+                                $color3 = $this->GetColor($v4);
+                                $p3 = array($x4p,$y4p,$x3p,$y3p,$x4,$y4,$x4p,$y4p);
+
+                                $colorl1 = $this->GetColor($v1p);
+                                $pl1 = array($x1p,$y1p,$x2p,$y2p);
+                                $colorl2 = $this->GetColor($v4p);
+                                $pl2 = array($x4p,$y4p,$x3p,$y3p);
+                                $vl1 = $v1p; $vl2 = $v4p;
+                            }
+                            else { //( $v1p == $v4p )
+                                // "\"
+                                $color1 = $this->GetColor($v1);
+                                $p1 = array($x1,$y1,$x1p,$y1p,$x4p,$y4p,$x1,$y1);
+
+                                $color2 = $this->GetColor($v2);
+                                $p2 = array($x1p,$y1p,$x2,$y2,$x2p,$y2p,$x3p,$y3p,$x4,$y4,$x4p,$y4p,$x1p,$y1p);
+
+                                $color3 = $this->GetColor($v3);
+                                $p3 = array($x2p,$y2p,$x3,$y3,$x3p,$y3p,$x2p,$y2p);
+
+                                $colorl1 = $this->GetColor($v1p);
+                                $pl1 = array($x1p,$y1p,$x4p,$y4p);
+                                $colorl2 = $this->GetColor($v2p);
+                                $pl2 = array($x2p,$y2p,$x3p,$y3p);
+                                $vl1 = $v1p; $vl2 = $v2p;
+                            }
+                        }
+                        $this->FillPolygon($color1,$p1);
+                        $this->FillPolygon($color2,$p2);
+                        $this->FillPolygon($color3,$p3);
+
+                        if( $this->showcontlines ) {
+                            if( $this->dofill ) {
+                                $this->shape->SetColor($this->contlinecolor);
+                                $this->shape->Line($pl1[0],$pl1[1],$pl1[2],$pl1[3]);
+                                $this->shape->Line($pl2[0],$pl2[1],$pl2[2],$pl2[3]);
+                            }
+                            else {
+                                $this->shape->SetColor($colorl1);
+                                $this->shape->Line($pl1[0],$pl1[1],$pl1[2],$pl1[3]);
+                                $this->shape->SetColor($colorl2);
+                                $this->shape->Line($pl2[0],$pl2[1],$pl2[2],$pl2[3]);
+                            }
+                        }
+                        if( $this->showlabels ) {
+                            $this->putLabel( ($pl1[0]+$pl1[2])/2, ($pl1[1]+$pl1[3])/2, $pl1[2], $pl1[3], $vl1);
+                            $this->putLabel( ($pl2[0]+$pl2[2])/2, ($pl2[1]+$pl2[3])/2, $pl2[2], $pl2[3],$vl2);
+                        }
+                    }
+                }
+                else {
+                    $vc = ($v1+$v2+$v3+$v4)/4;
+                    $xc = ($x1+$x4)/2;
+                    $yc = ($y1+$y2)/2;
+
+                    // Top left
+                    $this->RectFill(($v1+$v2)/2, $v2, ($v2+$v3)/2, $vc,
+                                    $x1,$yc, $x2,$y2, $xc,$y2, $xc,$yc, $depth+1);
+                    // Top right
+                    $this->RectFill($vc, ($v2+$v3)/2, $v3, ($v3+$v4)/2,
+                                    $xc,$yc, $xc,$y2, $x3,$y3, $x3,$yc, $depth+1);
+
+                    // Bottom left
+                    $this->RectFill($v1, ($v1+$v2)/2, $vc, ($v1+$v4)/2,
+                                    $x1,$y1, $x1,$yc, $xc,$yc, $xc,$y4, $depth+1);
+
+                    // Bottom right
+                    $this->RectFill(($v1+$v4)/2, $vc, ($v3+$v4)/2, $v4,
+                                    $xc,$y1, $xc,$yc, $x3,$yc, $x4,$y4, $depth+1);
+
+                }
+            }
+        }
+    }
+
+    function TriFill($v1,$v2,$v3,$x1,$y1,$x2,$y2,$x3,$y3,$depth) {
+        if( $depth >= self::$maxdepth ) {
+            // Abort and just appoximate the color of this area
+            // with the average of the three values
+            $color = $this->GetColor(($v1+$v2+$v3)/3);
+            $p = array($x1, $y1, $x2, $y2, $x3, $y3, $x1, $y1);
+            $this->FillPolygon($color,$p) ;
+        }
+        else {
+            // In order to avoid some real unpleasentness in case a vertice is exactly
+            // the same value as a contour we pertuberate them so that we do not end up
+            // in udefined situation. This will only affect the calculations and not the
+            // visual appearance
+
+            $dummy=0;
+            $this->Pertubate($v1,$v2,$v3,$dummy);
+
+            $fcnt = 0 ;
+            $vv1 = $this->GetNextHigherContourIdx($v1);
+            $vv2 = $this->GetNextHigherContourIdx($v2);
+            $vv3 = $this->GetNextHigherContourIdx($v3);
+            $eps = 0.0001;
+
+            if( $vv1 == $vv2 && $vv2 == $vv3 ) {
+                $color = $this->GetColor($v1);
+                $p = array($x1, $y1, $x2, $y2, $x3, $y3, $x1, $y1);
+                $this->FillPolygon($color,$p) ;
+            }             
+            else {
+                $dv1 = abs($vv1-$vv2);
+                $dv2 = abs($vv2-$vv3);
+                $dv3 = abs($vv1-$vv3);
+
+                if( $dv1 == 1 ) {
+                    list($x1p,$y1p,$v1p) = $this->interp2($x1,$y1,$x2,$y2,$v1,$v2);
+                    $fcnt++;
+                }
+                else {
+                    $x1p = ($x1+$x2)/2;
+                    $y1p = ($y1+$y2)/2;
+                    $v1p = ($v1+$v2)/2;
+                }
+
+                if( $dv2 == 1 ) {
+                    list($x2p,$y2p,$v2p) = $this->interp2($x2,$y2,$x3,$y3,$v2,$v3);
+                    $fcnt++;
+                }
+                else {
+                    $x2p = ($x2+$x3)/2;
+                    $y2p = ($y2+$y3)/2;
+                    $v2p = ($v2+$v3)/2;
+                }
+
+                if( $dv3 == 1 ) {
+                    list($x3p,$y3p,$v3p) = $this->interp2($x3,$y3,$x1,$y1,$v3,$v1);
+                    $fcnt++;
+                }
+                else {
+                    $x3p = ($x3+$x1)/2;
+                    $y3p = ($y3+$y1)/2;
+                    $v3p = ($v3+$v1)/2;
+                }
+
+                if( $fcnt == 2 &&
+                    ((abs($v1p-$v2p) < $eps && $dv1 ==1 && $dv2==1 ) ||
+                    (abs($v1p-$v3p) < $eps && $dv1 ==1 && $dv3==1 ) ||
+                    (abs($v2p-$v3p) < $eps && $dv2 ==1 && $dv3==1 )) ) {
+
+                    // This means that the contour line crosses exactly two sides
+                    // and that the values of each vertice is such that only this
+                    // contour line will cross this section.
+                    // We can now be smart. The cotour line will simply divide the
+                    // area in two polygons that we can fill and then return. There is no
+                    // need to recurse.
+                    
+                    // First find out which two sides the contour is crossing
+                    if( abs($v1p-$v2p) < $eps ) {
+                        $p4 = array($x1,$y1,$x1p,$y1p,$x2p,$y2p,$x3,$y3,$x1,$y1);
+                        $color4 = $this->GetColor($v1);
+                        
+                        $p3 = array($x1p,$y1p,$x2,$y2,$x2p,$y2p,$x1p,$y1p);
+                        $color3 = $this->GetColor($v2);
+
+                        $p = array($x1p,$y1p,$x2p,$y2p);
+                        $color = $this->GetColor($v1p);
+                        $v = $v1p;
+                    }
+                    elseif( abs($v1p-$v3p) < $eps ) { 
+                        $p4 = array($x1p,$y1p,$x2,$y2,$x3,$y3,$x3p,$y3p,$x1p,$y1p);
+                        $color4 = $this->GetColor($v2);
+                        
+                        $p3 = array($x1,$y1,$x1p,$y1p,$x3p,$y3p,$x1,$y1);
+                        $color3 = $this->GetColor($v1);
+
+                        $p = array($x1p,$y1p,$x3p,$y3p);
+                        $color = $this->GetColor($v1p);
+                        $v = $v1p;
+                    }
+                    else {
+                        $p4 = array($x1,$y1,$x2,$y2,$x2p,$y2p,$x3p,$y3p,$x1,$y1);
+                        $color4 = $this->GetColor($v2);
+
+                        $p3 = array($x3p,$y3p,$x2p,$y2p,$x3,$y3,$x3p,$y3p);
+                        $color3 = $this->GetColor($v3);
+
+                        $p = array($x3p,$y3p,$x2p,$y2p);
+                        $color = $this->GetColor($v3p);
+                        $v = $v3p;
+                    }                    
+                    $this->FillPolygon($color4,$p4);
+                    $this->FillPolygon($color3,$p3);
+
+                    if( $this->showcontlines ) {
+                        if( $this->dofill ) {
+                            $this->shape->SetColor($this->contlinecolor);
+                        }
+                        else {
+                            $this->shape->SetColor($color);
+                        }
+                        $this->shape->Line($p[0],$p[1],$p[2],$p[3]);
+                    }
+                    if( $this->showlabels ) {
+                        $this->putLabel( ($p[0]+$p[2])/2, ($p[1]+$p[3])/2, $p[2], $p[3], $v);
+                    }
+                }
+                else {
+                    $this->TriFill($v1, $v1p, $v3p, $x1, $y1, $x1p, $y1p, $x3p, $y3p, $depth+1);
+                    $this->TriFill($v1p, $v2, $v2p, $x1p, $y1p, $x2, $y2, $x2p, $y2p, $depth+1);
+                    $this->TriFill($v3p, $v1p, $v2p, $x3p, $y3p, $x1p, $y1p, $x2p, $y2p, $depth+1);
+                    $this->TriFill($v3p, $v2p, $v3, $x3p, $y3p, $x2p, $y2p, $x3, $y3, $depth+1);
+                }
+            }
+        }
+    }
+
+    function Fill($v1,$v2,$v3,$maxdepth) {
+        $x1=0; $y1=1;
+        $x2=1; $y2=0;
+        $x3=1; $y3=1;
+        self::$maxdepth = $maxdepth;
+        $this->TriFill($v1, $v2, $v3, $x1, $y1, $x2, $y2, $x3, $y3, 0);
+    }
+
+    function Fillmesh($meshdata,$maxdepth,$method='tri') {
+        $nx = count($meshdata[0]);
+        $ny = count($meshdata);
+        self::$maxdepth = $maxdepth;
+        for( $x=0; $x < $nx-1; ++$x ) {
+            for( $y=0; $y < $ny-1; ++$y ) {
+                $v1 = $meshdata[$y][$x];
+                $v2 = $meshdata[$y][$x+1];
+                $v3 = $meshdata[$y+1][$x+1];
+                $v4 = $meshdata[$y+1][$x];
+
+                if( $method == 'tri' ) {
+                    // Fill upper and lower triangle
+                    $this->TriFill($v4, $v1, $v2, $x, $y+1, $x, $y, $x+1, $y, 0);
+                    $this->TriFill($v4, $v2, $v3, $x, $y+1, $x+1, $y, $x+1, $y+1, 0);
+                }
+                else {
+                    $this->RectFill($v4, $v1, $v2, $v3, $x, $y+1, $x, $y, $x+1, $y, $x+1, $y+1, 0);
+                }
+            }
+        }
+        if( $this->showlabels ) {
+            $this->strokeLabels();
+        }
+    }
+}
+
+$meshdata = array(
+    array (12,12,10,10),
+    array (10,10,8,14),
+    array (7,7,13,17),
+    array (4,5,8,12),
+    array (10,8,7,8));
+
+$tt = new SingleTestTriangle(400,400,count($meshdata[0])-1,count($meshdata)-1);
+$tt->SetContours(array(4.7, 6.0, 7.2, 8.6, 9.9, 11.2, 12.5, 13.8, 15.1, 16.4));
+$tt->SetFilled(true);
+
+//$tt->ShowTriangulation(true);
+$tt->ShowLines(true);
+
+//$tt->ShowLabels(true);
+$tt->Fillmesh($meshdata, 8, 'rect');
+
+//$tt->Fill(4.0,3.0,7.0, 4);
+//$tt->Fill(7,4,1,5);
+//$tt->Fill(1,7,4,5);
+
+$tt->Stroke();
+
+?>
diff --git a/web/classes/jpgraph/flag_mapping b/web/classes/jpgraph/flag_mapping
new file mode 100755
index 0000000000000000000000000000000000000000..7f9c3c5fa26cfd829097356dd9b04813fea205cf
--- /dev/null
+++ b/web/classes/jpgraph/flag_mapping
@@ -0,0 +1,237 @@
+class JpCountryFlags {
+
+$iCountryFlags = array(
+    'Afghanistan' => 'afgh.gif',
+    'Republic of Angola' => 'agla.gif',
+    'Republic of Albania' => 'alba.gif',
+    'Alderney' => 'alde.gif',
+    'Democratic and Popular Republic of Algeria' => 'alge.gif',
+    'Territory of American Samoa' => 'amsa.gif',
+    'Principality of Andorra' => 'andr.gif',
+    'British Overseas Territory of Anguilla' => 'angu.gif',
+    'Antarctica' => 'anta.gif',
+    'Argentine Republic' => 'arge.gif',
+    'League of Arab States' => 'arle.gif',
+    'Republic of Armenia' => 'arme.gif',
+    'Aruba' => 'arub.gif',
+    'Commonwealth of Australia' => 'astl.gif',
+    'Republic of Austria' => 'aust.gif',
+    'Azerbaijani Republic' => 'azer.gif',
+    'British Antarctic Territory' => 'bant.gif',
+    'Kingdom of Belgium' => 'belg.gif',
+    'British Overseas Territory of Bermuda' => 'berm.gif',
+    'Commonwealth of the Bahamas' => 'bhms.gif',
+    'Kingdom of Bahrain' => 'bhrn.gif',
+    'Republic of Belarus' => 'blru.gif',
+    'Republic of Bolivia' => 'blva.gif',
+    'Belize' => 'blze.gif',
+    'Republic of Benin' => 'bnin.gif',
+    'Republic of Botswana' => 'bots.gif',
+    'Federative Republic of Brazil' => 'braz.gif',
+    'Barbados' => 'brbd.gif',
+    'British Indian Ocean Territory' => 'brin.gif',
+    'Brunei Darussalam' => 'brun.gif',
+    'Republic of Burkina' => 'bufa.gif',
+    'Republic of Bulgaria' => 'bulg.gif',
+    'Republic of Burundi' => 'buru.gif',
+    'Overseas Territory of the British Virgin Islands' => 'bvis.gif',
+    'Central African Republic' => 'cafr.gif',
+    'Kingdom of Cambodia' => 'camb.gif',
+    'Republic of Cameroon' => 'came.gif',
+    'Dominion of Canada' => 'cana.gif',
+    'Caribbean Community' => 'cari.gif',
+    'Republic of Cape Verde' => 'cave.gif',
+    'Republic of Chad' => 'chad.gif',
+    'Republic of Chile' => 'chil.gif',
+    'Territory of Christmas Island' => 'chms.gif',
+    'Commonwealth of Independent States' => 'cins.gif',
+    'Cook Islands' => 'ckis.gif',
+    'Republic of Colombia' => 'clmb.gif',
+    'Territory of Cocos Islands' => 'cois.gif',
+    'Commonwealth' => 'comn.gif',
+    'Union of the Comoros' => 'como.gif',
+    'Republic of the Congo' => 'cong.gif',
+    'Republic of Costa Rica' => 'corc.gif',
+    'Republic of Croatia' => 'croa.gif',
+    'Republic of Cuba' => 'cuba.gif',
+    'British Overseas Territory of the Cayman Islands' => 'cyis.gif',
+    'Republic of Cyprus' => 'cypr.gif',
+    'The Czech Republic' => 'czec.gif',
+    'Kingdom of Denmark' => 'denm.gif',
+    'Republic of Djibouti' => 'djib.gif',
+    'Commonwealth of Dominica' => 'domn.gif',
+    'Dominican Republic' => 'dore.gif',
+    'Republic of Ecuador' => 'ecua.gif',
+    'Arab Republic of Egypt' => 'egyp.gif',
+    'Republic of El Salvador' => 'elsa.gif',
+    'England' => 'engl.gif',
+    'Republic of Equatorial Guinea' => 'eqgu.gif',
+    'State of Eritrea' => 'erit.gif',
+    'Republic of Estonia' => 'estn.gif',
+    'Ethiopia' => 'ethp.gif',
+    'European Union' => 'euun.gif',
+    'British Overseas Territory of the Falkland Islands' => 'fais.gif',
+    'International Federation of Vexillological Associations' => 'fiav.gif',
+    'Republic of Fiji' => 'fiji.gif',
+    'Republic of Finland' => 'finl.gif',
+    'Territory of French Polynesia' => 'fpol.gif',
+    'French Republic' => 'fran.gif',
+    'Overseas Department of French Guiana' => 'frgu.gif',
+    'Gabonese Republic' => 'gabn.gif',
+    'Republic of the Gambia' => 'gamb.gif',
+    'Republic of Georgia' => 'geor.gif',
+    'Federal Republic of Germany' => 'germ.gif',
+    'Republic of Ghana' => 'ghan.gif',
+    'Gibraltar' => 'gibr.gif',
+    'Hellenic Republic' => 'grec.gif',
+    'State of Grenada' => 'gren.gif',
+    'Overseas Department of Guadeloupe' => 'guad.gif',
+    'Territory of Guam' => 'guam.gif',
+    'Republic of Guatemala' => 'guat.gif',
+    'The Bailiwick of Guernsey' => 'guer.gif',
+    'Republic of Guinea' => 'guin.gif',
+    'Republic of Haiti' => 'hait.gif',
+    'Hong Kong Special Administrative Region' => 'hokn.gif',
+    'Republic of Honduras' => 'hond.gif',
+    'Republic of Hungary' => 'hung.gif',
+    'Republic of Iceland' => 'icel.gif',
+    'International Committee of the Red Cross' => 'icrc.gif',
+    'Republic of India' => 'inda.gif',
+    'Republic of Indonesia' => 'indn.gif',
+    'Republic of Iraq' => 'iraq.gif',
+    'Republic of Ireland' => 'irel.gif',
+    'Organization of the Islamic Conference' => 'isco.gif',
+    'Isle of Man' => 'isma.gif',
+    'State of Israel' => 'isra.gif',
+    'Italian Republic' => 'ital.gif',
+    'Jamaica' => 'jama.gif',
+    'Japan' => 'japa.gif',
+    'The Bailiwick of Jersey' => 'jers.gif',
+    'Hashemite Kingdom of Jordan' => 'jord.gif',
+    'Republic of Kazakhstan' => 'kazk.gif',
+    'Republic of Kenya' => 'keny.gif',
+    'Republic of Kiribati' => 'kirb.gif',
+    'State of Kuwait' => 'kuwa.gif',
+    'Kyrgyz Republic' => 'kyrg.gif',
+    'Republic of Latvia' => 'latv.gif',
+    'Lebanese Republic' => 'leba.gif',
+    'Kingdom of Lesotho' => 'lest.gif',
+    'Republic of Liberia' => 'libe.gif',
+    'Principality of Liechtenstein' => 'liec.gif',
+    'Republic of Lithuania' => 'lith.gif',
+    'Grand Duchy of Luxembourg' => 'luxe.gif',
+    'Macao Special Administrative Region' => 'maca.gif',
+    'Republic of Macedonia' => 'mace.gif',
+    'Republic of Madagascar' => 'mada.gif',
+    'Republic of the Marshall Islands' => 'mais.gif',
+    'Republic of Maldives' => 'mald.gif',
+    'Republic of Mali' => 'mali.gif',
+    'Federation of Malaysia' => 'mals018.gif',
+    'Republic of Malta' => 'malt.gif',
+    'Republic of Malawi' => 'malw.gif',
+    'Overseas Department of Martinique' => 'mart.gif',
+    'Islamic Republic of Mauritania' => 'maur.gif',
+    'Territorial Collectivity of Mayotte' => 'mayt.gif',
+    'United Mexican States' => 'mexc.gif',
+    'Federated States of Micronesia' => 'micr.gif',
+    'Midway Islands' => 'miis.gif',
+    'Republic of Moldova' => 'mold.gif',
+    'Principality of Monaco' => 'mona.gif',
+    'Republic of Mongolia' => 'mong.gif',
+    'British Overseas Territory of Montserrat' => 'mont.gif',
+    'Kingdom of Morocco' => 'morc.gif',
+    'Republic of Mozambique' => 'moza.gif',
+    'Republic of Mauritius' => 'mrts.gif',
+    'Union of Myanmar' => 'myan.gif',
+    'Republic of Namibia' => 'namb.gif',
+    'North Atlantic Treaty Organization' => 'nato.gif',
+    'Republic of Nauru' => 'naur.gif',
+    'Turkish Republic of Northern Cyprus' => 'ncyp.gif',
+    'Netherlands Antilles' => 'nean.gif',
+    'Kingdom of Nepal' => 'nepa.gif',
+    'Kingdom of the Netherlands' => 'neth.gif',
+    'Territory of Norfolk Island' => 'nfis.gif',
+    'Federal Republic of Nigeria' => 'ngra.gif',
+    'Republic of Nicaragua' => 'nica.gif',
+    'Republic of Niger' => 'nigr.gif',
+    'Niue' => 'niue.gif',
+    'Commonwealth of the Northern Mariana Islands' => 'nmar.gif',
+    'Province of Northern Ireland' => 'noir.gif',
+    'Nordic Council' => 'nord.gif',
+    'Kingdom of Norway' => 'norw.gif',
+    'Territory of New Caledonia and Dependencies' => 'nwca.gif',
+    'New Zealand' => 'nwze.gif',
+    'Organization of American States' => 'oast.gif',
+    'Organization of African Unity' => 'oaun.gif',
+    'International Olympic Committee' => 'olym.gif',
+    'Sultanate of Oman' => 'oman.gif',
+    'Organization of Petroleum Exporting Countries' => 'opec.gif',
+    'Islamic Republic of Pakistan' => 'paks.gif',
+    'Republic of Palau' => 'pala.gif',
+    'Independent State of Papua New Guinea' => 'pang.gif',
+    'Republic of Paraguay' => 'para.gif',
+    'Republic of the Philippines' => 'phil.gif',
+    'British Overseas Territory of the Pitcairn Islands' => 'piis.gif',
+    'Republic of Poland' => 'pola.gif',
+    'Republic of Portugal' => 'port.gif',
+    'Commonwealth of Puerto Rico' => 'purc.gif',
+    'State of Qatar' => 'qata.gif',
+    'Russian Federation' => 'russ.gif',
+    'Republic of Rwanda' => 'rwan.gif',
+    'Kingdom of Saudi Arabia' => 'saar.gif',
+    'Republic of San Marino' => 'sama.gif',
+    'Nordic Sami Conference' => 'sami.gif',
+    'Sark' => 'sark.gif',
+    'Scotland' => 'scot.gif',
+    'Principality of Seborga' => 'sebo.gif',
+    'Republic of Sierra Leone' => 'sile.gif',
+    'Republic of Singapore' => 'sing.gif',
+    'Republic of Korea' => 'skor.gif',
+    'Republic of Slovenia' => 'slva.gif',
+    'Somali Republic' => 'smla.gif',
+    'Republic of Somaliland' => 'smld.gif',
+    'Republic of South Africa' => 'soaf.gif',
+    'Solomon Islands' => 'sois.gif',
+    'Kingdom of Spain' => 'span.gif',
+    'Secretariat of the Pacific Community' => 'spco.gif',
+    'Democratic Socialist Republic of Sri Lanka' => 'srla.gif',
+    'Saint Lucia' => 'stlu.gif',
+    'Republic of the Sudan' => 'suda.gif',
+    'Republic of Suriname' => 'surn.gif',
+    'Slovak Republic' => 'svka.gif',
+    'Kingdom of Sweden' => 'swdn.gif',
+    'Swiss Confederation' => 'swit.gif',
+    'Syrian Arab Republic' => 'syra.gif',
+    'Kingdom of Swaziland' => 'szld.gif',
+    'Republic of China' => 'taiw.gif',
+    'Republic of Tajikistan' => 'tajk.gif',
+    'United Republic of Tanzania' => 'tanz.gif',
+    'Kingdom of Thailand' => 'thal.gif',
+    'Autonomous Region of Tibet' => 'tibe.gif',
+    'Turkmenistan' => 'tkst.gif',
+    'Togolese Republic' => 'togo.gif',
+    'Tokelau' => 'toke.gif',
+    'Kingdom of Tonga' => 'tong.gif',
+    'Tristan da Cunha' => 'trdc.gif',
+    'Tromelin' => 'tris.gif',
+    'Republic of Tunisia' => 'tuns.gif',
+    'Republic of Turkey' => 'turk.gif',
+    'Tuvalu' => 'tuva.gif',
+    'United Arab Emirates' => 'uaem.gif',
+    'Republic of Uganda' => 'ugan.gif',
+    'Ukraine' => 'ukrn.gif',
+    'United Kingdom of Great Britain' => 'unkg.gif',
+    'United Nations' => 'unna.gif',
+    'United States of America' => 'unst.gif',
+    'Oriental Republic of Uruguay' => 'urgy.gif',
+    'Virgin Islands of the United States' => 'usvs.gif',
+    'Republic of Uzbekistan' => 'uzbk.gif',
+    'State of the Vatican City' => 'vacy.gif',
+    'Republic of Vanuatu' => 'vant.gif',
+    'Bolivarian Republic of Venezuela' => 'venz.gif',
+    'Republic of Yemen' => 'yemn.gif',
+    'Democratic Republic of Congo' => 'zare.gif',
+    'Republic of Zimbabwe' => 'zbwe.gif' 
+) ;
+
+
diff --git a/web/classes/jpgraph/flags.dat b/web/classes/jpgraph/flags.dat
new file mode 100755
index 0000000000000000000000000000000000000000..1cd2e72345fa62b81201376256dc29a708c54347
Binary files /dev/null and b/web/classes/jpgraph/flags.dat differ
diff --git a/web/classes/jpgraph/flags_thumb100x100.dat b/web/classes/jpgraph/flags_thumb100x100.dat
new file mode 100755
index 0000000000000000000000000000000000000000..545e7ade5805e60e3ee1eb23e5c93f4b1aac78d4
Binary files /dev/null and b/web/classes/jpgraph/flags_thumb100x100.dat differ
diff --git a/web/classes/jpgraph/flags_thumb35x35.dat b/web/classes/jpgraph/flags_thumb35x35.dat
new file mode 100755
index 0000000000000000000000000000000000000000..7335011ec99e98dba5d52d6a02a5e0453d69cce4
Binary files /dev/null and b/web/classes/jpgraph/flags_thumb35x35.dat differ
diff --git a/web/classes/jpgraph/flags_thumb60x60.dat b/web/classes/jpgraph/flags_thumb60x60.dat
new file mode 100755
index 0000000000000000000000000000000000000000..6107d084eb5b719e0fd0bfccb314e9c69647d854
Binary files /dev/null and b/web/classes/jpgraph/flags_thumb60x60.dat differ
diff --git a/web/classes/jpgraph/fonts/DejaVuSans-Bold.ttf b/web/classes/jpgraph/fonts/DejaVuSans-Bold.ttf
new file mode 100755
index 0000000000000000000000000000000000000000..ac313d269caed984fa1bb5c811330546e1249a25
Binary files /dev/null and b/web/classes/jpgraph/fonts/DejaVuSans-Bold.ttf differ
diff --git a/web/classes/jpgraph/fonts/DejaVuSans-BoldOblique.ttf b/web/classes/jpgraph/fonts/DejaVuSans-BoldOblique.ttf
new file mode 100755
index 0000000000000000000000000000000000000000..c818ae6e7c2480231dc41baa3b8908ad0be45282
Binary files /dev/null and b/web/classes/jpgraph/fonts/DejaVuSans-BoldOblique.ttf differ
diff --git a/web/classes/jpgraph/fonts/DejaVuSans-Oblique.ttf b/web/classes/jpgraph/fonts/DejaVuSans-Oblique.ttf
new file mode 100755
index 0000000000000000000000000000000000000000..d5ac60d6aa1dad102d9a63d330baf5c67a5ff775
Binary files /dev/null and b/web/classes/jpgraph/fonts/DejaVuSans-Oblique.ttf differ
diff --git a/web/classes/jpgraph/fonts/DejaVuSans.ttf b/web/classes/jpgraph/fonts/DejaVuSans.ttf
new file mode 100755
index 0000000000000000000000000000000000000000..a99969e1b2db618ae9611559809c9216fa4e303a
Binary files /dev/null and b/web/classes/jpgraph/fonts/DejaVuSans.ttf differ
diff --git a/web/classes/jpgraph/fonts/FF_FONT0-Bold.gdf b/web/classes/jpgraph/fonts/FF_FONT0-Bold.gdf
new file mode 100755
index 0000000000000000000000000000000000000000..3b371f8a62fc99f82d59d4c3fb384779dc7a2bdb
Binary files /dev/null and b/web/classes/jpgraph/fonts/FF_FONT0-Bold.gdf differ
diff --git a/web/classes/jpgraph/fonts/FF_FONT0.gdf b/web/classes/jpgraph/fonts/FF_FONT0.gdf
new file mode 100755
index 0000000000000000000000000000000000000000..e231b71314a9c610c3ec07463c8da6d7b81015b4
Binary files /dev/null and b/web/classes/jpgraph/fonts/FF_FONT0.gdf differ
diff --git a/web/classes/jpgraph/fonts/FF_FONT1-Bold.gdf b/web/classes/jpgraph/fonts/FF_FONT1-Bold.gdf
new file mode 100755
index 0000000000000000000000000000000000000000..d62f0b3bb7e4fbd2cda2f1741604b65b42df4b76
Binary files /dev/null and b/web/classes/jpgraph/fonts/FF_FONT1-Bold.gdf differ
diff --git a/web/classes/jpgraph/fonts/FF_FONT1.gdf b/web/classes/jpgraph/fonts/FF_FONT1.gdf
new file mode 100755
index 0000000000000000000000000000000000000000..7b5b0f628b7662425416f5b6ffa5ade11ffba6db
Binary files /dev/null and b/web/classes/jpgraph/fonts/FF_FONT1.gdf differ
diff --git a/web/classes/jpgraph/fonts/FF_FONT2-Bold.gdf b/web/classes/jpgraph/fonts/FF_FONT2-Bold.gdf
new file mode 100755
index 0000000000000000000000000000000000000000..6e402847c2aa02b57e2bc3eefd85ed391b798cc7
Binary files /dev/null and b/web/classes/jpgraph/fonts/FF_FONT2-Bold.gdf differ
diff --git a/web/classes/jpgraph/fonts/FF_FONT2.gdf b/web/classes/jpgraph/fonts/FF_FONT2.gdf
new file mode 100755
index 0000000000000000000000000000000000000000..50bca09e089de70c5634670e3789da40b17d2849
Binary files /dev/null and b/web/classes/jpgraph/fonts/FF_FONT2.gdf differ
diff --git a/web/classes/jpgraph/gd_image.inc.php b/web/classes/jpgraph/gd_image.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..c2102056f455bc103817c53bb046185e4da4ff62
--- /dev/null
+++ b/web/classes/jpgraph/gd_image.inc.php
@@ -0,0 +1,2305 @@
+<?php
+//=======================================================================
+// File:        GD_IMAGE.INC.PHP
+// Description: PHP Graph Plotting library. Low level image drawing routines
+// Created:     2001-01-08, refactored 2008-03-29
+// Ver:         $Id: gd_image.inc.php 1922 2010-01-11 11:42:50Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+require_once 'jpgraph_rgb.inc.php';
+require_once 'jpgraph_ttf.inc.php';
+require_once 'imageSmoothArc.php';
+
+// Line styles
+define('LINESTYLE_SOLID',1);
+define('LINESTYLE_DOTTED',2);
+define('LINESTYLE_DASHED',3);
+define('LINESTYLE_LONGDASH',4);
+
+// The DEFAULT_GFORMAT sets the default graphic encoding format, i.e.
+// PNG, JPG or GIF depending on what is installed on the target system
+// in that order.
+if( !DEFINED("DEFAULT_GFORMAT") ) {
+    define("DEFAULT_GFORMAT","auto");
+}
+
+//========================================================================
+// CLASS Image
+// Description: The very coor image drawing class that encapsulates all
+//              calls to the GD library
+//              Note: The class used by the library is the decendant
+//              class RotImage which extends the Image class with transparent
+//              rotation.
+//=========================================================================
+class Image {
+    public $img=null;
+    public $rgb=null;
+    public $img_format;
+    public $ttf=null;
+    public $line_style=LINESTYLE_SOLID;
+    public $current_color,$current_color_name;
+    public $original_width=0, $original_height=0;
+    public $plotwidth=0,$plotheight=0;
+
+    // for __get, __set
+    private $_left_margin=30,$_right_margin=30,$_top_margin=20,$_bottom_margin=30;
+    //private $_plotwidth=0,$_plotheight=0;
+    private $_width=0, $_height=0;
+    private $_line_weight=1;
+
+    protected $expired=true;
+    protected $lastx=0, $lasty=0;
+    protected $obs_list=array();
+    protected $font_size=12,$font_family=FF_DEFAULT, $font_style=FS_NORMAL;
+    protected $font_file='';
+    protected $text_halign="left",$text_valign="bottom";
+    protected $use_anti_aliasing=false;
+    protected $quality=null;
+    protected $colorstack=array(),$colorstackidx=0;
+    protected $canvascolor = 'white' ;
+    protected $langconv = null ;
+    protected $iInterlace=false;
+    protected $bbox_cache = array(); // STore the last found tetx bounding box
+    protected $ff_font0;
+    protected $ff_font0_bold;
+    protected $ff_font1;
+    protected $ff_font1_bold;
+    protected $ff_font2;
+    protected $ff_font2_bold;
+
+
+    //---------------
+    // CONSTRUCTOR
+    function __construct($aWidth=0,$aHeight=0,$aFormat=DEFAULT_GFORMAT,$aSetAutoMargin=true) {
+
+        $this->original_width  = $aWidth;
+        $this->original_height = $aHeight;
+        $this->CreateImgCanvas($aWidth, $aHeight);
+
+        if( $aSetAutoMargin ) {
+            $this->SetAutoMargin();
+        }
+
+        if( !$this->SetImgFormat($aFormat) ) {
+            JpGraphError::RaiseL(25081,$aFormat);//("JpGraph: Selected graphic format is either not supported or unknown [$aFormat]");
+        }
+        $this->ttf = new TTF();
+        $this->langconv = new LanguageConv();
+
+        $this->ff_font0 =  imageloadfont(dirname(__FILE__) . "/fonts/FF_FONT0.gdf");
+        $this->ff_font1 =  imageloadfont(dirname(__FILE__) . "/fonts/FF_FONT1.gdf");
+        $this->ff_font2 =  imageloadfont(dirname(__FILE__) . "/fonts/FF_FONT2.gdf");
+        $this->ff_font1_bold =  imageloadfont(dirname(__FILE__) . "/fonts/FF_FONT1-Bold.gdf");
+        $this->ff_font2_bold =  imageloadfont(dirname(__FILE__) . "/fonts/FF_FONT2-Bold.gdf");
+    }
+
+    // Enable interlacing in images
+    function SetInterlace($aFlg=true) {
+        $this->iInterlace=$aFlg;
+    }
+
+    // Should we use anti-aliasing. Note: This really slows down graphics!
+    function SetAntiAliasing($aFlg=true) {
+        $this->use_anti_aliasing = $aFlg;
+        if( function_exists('imageantialias') ) {
+            imageantialias($this->img,$aFlg);
+        }
+        else {
+// don't throw an error
+//            JpGraphError::RaiseL(25128);//('The function imageantialias() is not available in your PHP installation. Use the GD version that comes with PHP and not the standalone version.')
+        }
+    }
+
+    function GetAntiAliasing() {
+        return $this->use_anti_aliasing ;
+    }
+
+    function CreateRawCanvas($aWidth=0,$aHeight=0) {
+
+        $aWidth  *= SUPERSAMPLING_SCALE;
+        $aHeight *= SUPERSAMPLING_SCALE;
+
+        if( $aWidth <= 1 || $aHeight <= 1 ) {
+            JpGraphError::RaiseL(25082,$aWidth,$aHeight);//("Illegal sizes specified for width or height when creating an image, (width=$aWidth, height=$aHeight)");
+        }
+
+        $this->img = @imagecreatetruecolor($aWidth, $aHeight);
+        if( $this->img < 1 ) {
+            JpGraphError::RaiseL(25126);
+            //die("Can't create truecolor image. Check that you really have GD2 library installed.");
+        }
+        $this->SetAlphaBlending();
+
+        if( $this->iInterlace ) {
+            imageinterlace($this->img,1);
+        }
+        if( $this->rgb != null ) {
+            $this->rgb->img = $this->img ;
+        }
+        else {
+            $this->rgb = new RGB($this->img);
+        }
+    }
+
+    function CloneCanvasH() {
+        $oldimage = $this->img;
+        $this->CreateRawCanvas($this->width,$this->height);
+        imagecopy($this->img,$oldimage,0,0,0,0,$this->width,$this->height);
+        return $oldimage;
+    }
+
+    function CreateImgCanvas($aWidth=0,$aHeight=0) {
+
+        $old = array($this->img,$this->width,$this->height);
+
+        $aWidth = round($aWidth);
+        $aHeight = round($aHeight);
+
+        $this->width=$aWidth;
+        $this->height=$aHeight;
+
+
+        if( $aWidth==0 || $aHeight==0 ) {
+            // We will set the final size later.
+            // Note: The size must be specified before any other
+            // img routines that stroke anything are called.
+            $this->img = null;
+            $this->rgb = null;
+            return $old;
+        }
+
+        $this->CreateRawCanvas($aWidth,$aHeight);
+        // Set canvas color (will also be the background color for a
+        // a pallett image
+        $this->SetColor($this->canvascolor);
+        $this->FilledRectangle(0,0,$this->width-1,$this->height-1);
+
+        return $old ;
+    }
+
+    function CopyCanvasH($aToHdl,$aFromHdl,$aToX,$aToY,$aFromX,$aFromY,$aWidth,$aHeight,$aw=-1,$ah=-1) {
+        if( $aw === -1 ) {
+            $aw = $aWidth;
+            $ah = $aHeight;
+            $f = 'imagecopyresized';
+        }
+        else {
+            $f = 'imagecopyresampled';
+        }
+        $f($aToHdl,$aFromHdl,$aToX,$aToY,$aFromX,$aFromY, $aWidth,$aHeight,$aw,$ah);
+    }
+
+    function Copy($fromImg,$toX,$toY,$fromX,$fromY,$toWidth,$toHeight,$fromWidth=-1,$fromHeight=-1) {
+        $this->CopyCanvasH($this->img,$fromImg,$toX,$toY,$fromX,$fromY,$toWidth,$toHeight,$fromWidth,$fromHeight);
+    }
+
+    function CopyMerge($fromImg,$toX,$toY,$fromX,$fromY,$toWidth,$toHeight,$fromWidth=-1,$fromHeight=-1,$aMix=100) {
+        if( $aMix == 100 ) {
+            $this->CopyCanvasH($this->img,$fromImg,
+            $toX,$toY,$fromX,$fromY,$toWidth,$toHeight,$fromWidth,$fromHeight);
+        }
+        else {
+            if( ($fromWidth  != -1 && ($fromWidth != $toWidth)) || ($fromHeight != -1 && ($fromHeight != $fromHeight)) ) {
+                // Create a new canvas that will hold the re-scaled original from image
+                if( $toWidth <= 1 || $toHeight <= 1 ) {
+                    JpGraphError::RaiseL(25083);//('Illegal image size when copying image. Size for copied to image is 1 pixel or less.');
+                }
+
+                $tmpimg = @imagecreatetruecolor($toWidth, $toHeight);
+
+                if( $tmpimg < 1 ) {
+                    JpGraphError::RaiseL(25084);//('Failed to create temporary GD canvas. Out of memory ?');
+                }
+                $this->CopyCanvasH($tmpimg,$fromImg,0,0,0,0,
+                $toWidth,$toHeight,$fromWidth,$fromHeight);
+                $fromImg = $tmpimg;
+            }
+            imagecopymerge($this->img,$fromImg,$toX,$toY,$fromX,$fromY,$toWidth,$toHeight,$aMix);
+        }
+    }
+
+    static function GetWidth($aImg=null) {
+        if( $aImg === null ) {
+            $aImg = $this->img;
+        }
+        return imagesx($aImg);
+    }
+
+    static function GetHeight($aImg=null) {
+        if( $aImg === null ) {
+            $aImg = $this->img;
+        }
+        return imagesy($aImg);
+    }
+
+    static function CreateFromString($aStr) {
+        $img = imagecreatefromstring($aStr);
+        if( $img === false ) {
+            JpGraphError::RaiseL(25085);
+            //('An image can not be created from the supplied string. It is either in a format not supported or the string is representing an corrupt image.');
+        }
+        return $img;
+    }
+
+    function SetCanvasH($aHdl) {
+        $this->img = $aHdl;
+        $this->rgb->img = $aHdl;
+    }
+
+    function SetCanvasColor($aColor) {
+        $this->canvascolor = $aColor ;
+    }
+
+    function SetAlphaBlending($aFlg=true) {
+        ImageAlphaBlending($this->img,$aFlg);
+    }
+
+    function SetAutoMargin() {
+        $min_bm=5;
+        $lm = min(40,$this->width/7);
+        $rm = min(20,$this->width/10);
+        $tm = max(5,$this->height/7);
+        $bm = max($min_bm,$this->height/6);
+        $this->SetMargin($lm,$rm,$tm,$bm);
+    }
+
+    //---------------
+    // PUBLIC METHODS
+
+    function SetFont($family,$style=FS_NORMAL,$size=10) {
+        $this->font_family=$family;
+        $this->font_style=$style;
+        $this->font_size=$size*SUPERSAMPLING_SCALE;
+        $this->font_file='';
+        if( ($this->font_family==FF_FONT1 || $this->font_family==FF_FONT2) && $this->font_style==FS_BOLD ){
+            ++$this->font_family;
+        }
+        if( $this->font_family > FF_FONT2+1 ) { // A TTF font so get the font file
+
+            // Check that this PHP has support for TTF fonts
+            if( !function_exists('imagettfbbox') ) {
+                // use internal font when php is configured without '--with-ttf'
+                $this->font_family = FF_FONT1;
+//                JpGraphError::RaiseL(25087);//('This PHP build has not been configured with TTF support. You need to recompile your PHP installation with FreeType support.');
+            } else {
+                $this->font_file = $this->ttf->File($this->font_family,$this->font_style);
+            }
+        }
+    }
+
+    // Get the specific height for a text string
+    function GetTextHeight($txt="",$angle=0) {
+        $tmp = preg_split('/\n/',$txt);
+        $n = count($tmp);
+        $m=0;
+        for($i=0; $i< $n; ++$i) {
+            $m = max($m,strlen($tmp[$i]));
+        }
+
+        if( $this->font_family <= FF_FONT2+1 ) {
+            if( $angle==0 ) {
+                $h = imagefontheight($this->font_family);
+                if( $h === false ) {
+                    JpGraphError::RaiseL(25088);//('You have a misconfigured GD font support. The call to imagefontwidth() fails.');
+                }
+
+                return $n*$h;
+            }
+            else {
+                $w = @imagefontwidth($this->font_family);
+                if( $w === false ) {
+                    JpGraphError::RaiseL(25088);//('You have a misconfigured GD font support. The call to imagefontwidth() fails.');
+                }
+
+                return $m*$w;
+            }
+        }
+        else {
+            $bbox = $this->GetTTFBBox($txt,$angle);
+            return $bbox[1]-$bbox[5]+1;
+        }
+    }
+
+    // Estimate font height
+    function GetFontHeight($angle=0) {
+        $txt = "XOMg";
+        return $this->GetTextHeight($txt,$angle);
+    }
+
+    // Approximate font width with width of letter "O"
+    function GetFontWidth($angle=0) {
+        $txt = 'O';
+        return $this->GetTextWidth($txt,$angle);
+    }
+
+    // Get actual width of text in absolute pixels. Note that the width is the
+    // texts projected with onto the x-axis. Call with angle=0 to get the true
+    // etxt width.
+    function GetTextWidth($txt,$angle=0) {
+
+        $tmp = preg_split('/\n/',$txt);
+        $n = count($tmp);
+        if( $this->font_family <= FF_FONT2+1 ) {
+
+            $m=0;
+            for($i=0; $i < $n; ++$i) {
+                $l=strlen($tmp[$i]);
+                if( $l > $m ) {
+                    $m = $l;
+                }
+            }
+
+            if( $angle==0 ) {
+                $w = @imagefontwidth($this->font_family);
+                if( $w === false ) {
+                    JpGraphError::RaiseL(25088);//('You have a misconfigured GD font support. The call to imagefontwidth() fails.');
+                }
+                return $m*$w;
+            }
+            else {
+                // 90 degrees internal so height becomes width
+                $h = @imagefontheight($this->font_family);
+                if( $h === false ) {
+                    JpGraphError::RaiseL(25089);//('You have a misconfigured GD font support. The call to imagefontheight() fails.');
+                }
+                return $n*$h;
+            }
+        }
+        else {
+            // For TTF fonts we must walk through a lines and find the
+            // widest one which we use as the width of the multi-line
+            // paragraph
+            $m=0;
+            for( $i=0; $i < $n; ++$i ) {
+                $bbox = $this->GetTTFBBox($tmp[$i],$angle);
+                $mm =  $bbox[2] - $bbox[0];
+                if( $mm > $m )
+                    $m = $mm;
+            }
+            return $m;
+        }
+    }
+
+
+    // Draw text with a box around it
+    function StrokeBoxedText($x,$y,$txt,$dir=0,$fcolor="white",$bcolor="black",
+                             $shadowcolor=false,$paragraph_align="left",
+                             $xmarg=6,$ymarg=4,$cornerradius=0,$dropwidth=3) {
+
+		$oldx = $this->lastx;
+		$oldy = $this->lasty;
+
+        if( !is_numeric($dir) ) {
+            if( $dir=="h" ) $dir=0;
+            elseif( $dir=="v" ) $dir=90;
+            else JpGraphError::RaiseL(25090,$dir);//(" Unknown direction specified in call to StrokeBoxedText() [$dir]");
+        }
+
+        if( $this->font_family >= FF_FONT0 && $this->font_family <= FF_FONT2+1) {
+            $width=$this->GetTextWidth($txt,$dir) ;
+            $height=$this->GetTextHeight($txt,$dir) ;
+        }
+        else {
+            $width=$this->GetBBoxWidth($txt,$dir) ;
+            $height=$this->GetBBoxHeight($txt,$dir) ;
+        }
+
+        $height += 2*$ymarg;
+        $width  += 2*$xmarg;
+
+        if( $this->text_halign=="right" )      $x -= $width;
+        elseif( $this->text_halign=="center" ) $x -= $width/2;
+
+        if( $this->text_valign=="bottom" )     $y -= $height;
+        elseif( $this->text_valign=="center" ) $y -= $height/2;
+
+        $olda = $this->SetAngle(0);
+
+        if( $shadowcolor ) {
+            $this->PushColor($shadowcolor);
+            $this->FilledRoundedRectangle($x-$xmarg+$dropwidth,$y-$ymarg+$dropwidth,
+                                          $x+$width+$dropwidth,$y+$height-$ymarg+$dropwidth,
+                                          $cornerradius);
+            $this->PopColor();
+            $this->PushColor($fcolor);
+            $this->FilledRoundedRectangle($x-$xmarg,$y-$ymarg,
+                                          $x+$width,$y+$height-$ymarg,
+                                          $cornerradius);
+            $this->PopColor();
+            $this->PushColor($bcolor);
+            $this->RoundedRectangle($x-$xmarg,$y-$ymarg,
+                                    $x+$width,$y+$height-$ymarg,$cornerradius);
+            $this->PopColor();
+        }
+        else {
+            if( $fcolor ) {
+                $oc=$this->current_color;
+                $this->SetColor($fcolor);
+                $this->FilledRoundedRectangle($x-$xmarg,$y-$ymarg,$x+$width,$y+$height-$ymarg,$cornerradius);
+                $this->current_color=$oc;
+            }
+            if( $bcolor ) {
+                $oc=$this->current_color;
+                $this->SetColor($bcolor);
+                $this->RoundedRectangle($x-$xmarg,$y-$ymarg,$x+$width,$y+$height-$ymarg,$cornerradius);
+                $this->current_color=$oc;
+            }
+        }
+
+        $h=$this->text_halign;
+        $v=$this->text_valign;
+        $this->SetTextAlign("left","top");
+
+        $debug=false;
+        $this->StrokeText($x, $y, $txt, $dir, $paragraph_align,$debug);
+
+        $bb = array($x-$xmarg,$y+$height-$ymarg,$x+$width,$y+$height-$ymarg,
+                    $x+$width,$y-$ymarg,$x-$xmarg,$y-$ymarg);
+        $this->SetTextAlign($h,$v);
+
+        $this->SetAngle($olda);
+		$this->lastx = $oldx;
+		$this->lasty = $oldy;
+
+        return $bb;
+    }
+
+    // Draw text with a box around it. This time the box will be rotated
+    // with the text. The previous method will just make a larger enough non-rotated
+    // box to hold the text inside.
+    function StrokeBoxedText2($x,$y,$txt,$dir=0,$fcolor="white",$bcolor="black",
+                             $shadowcolor=false,$paragraph_align="left",
+                             $xmarg=6,$ymarg=4,$cornerradius=0,$dropwidth=3) {
+
+       // This version of boxed text will stroke a rotated box round the text
+       // thta will follow the angle of the text.
+       // This has two implications:
+       // 1) This methos will only support TTF fonts
+       // 2) The only two alignment that makes sense are centered or baselined
+
+       if( $this->font_family <= FF_FONT2+1 ) {
+           JpGraphError::RaiseL(25131);//StrokeBoxedText2() Only support TTF fonts and not built in bitmap fonts
+       }
+
+		$oldx = $this->lastx;
+		$oldy = $this->lasty;
+        $dir = $this->NormAngle($dir);
+
+        if( !is_numeric($dir) ) {
+            if( $dir=="h" ) $dir=0;
+            elseif( $dir=="v" ) $dir=90;
+            else JpGraphError::RaiseL(25090,$dir);//(" Unknown direction specified in call to StrokeBoxedText() [$dir]");
+        }
+
+        $width=$this->GetTextWidth($txt,0) + 2*$xmarg;
+        $height=$this->GetTextHeight($txt,0) + 2*$ymarg ;
+        $rect_width=$this->GetBBoxWidth($txt,$dir) ;
+        $rect_height=$this->GetBBoxHeight($txt,$dir) ;
+
+        $baseline_offset = $this->bbox_cache[1]-1;
+
+        if( $this->text_halign=="center" ) {
+            if( $dir >= 0 && $dir <= 90 ) {
+
+                $x -= $rect_width/2;
+                $x += sin($dir*M_PI/180)*$height;
+                $y += $rect_height/2;
+
+            } elseif( $dir >= 270 && $dir <= 360 ) {
+
+                $x -= $rect_width/2;
+                $y -= $rect_height/2;
+                $y += cos($dir*M_PI/180)*$height;
+
+            } elseif( $dir >= 90 && $dir <= 180 ) {
+
+                $x += $rect_width/2;
+                $y += $rect_height/2;
+                $y += cos($dir*M_PI/180)*$height;
+
+            }
+            else {
+                // $dir > 180 &&  $dir < 270
+                $x += $rect_width/2;
+                $x += sin($dir*M_PI/180)*$height;
+                $y -= $rect_height/2;
+            }
+        }
+
+        // Rotate the box around this point
+        $this->SetCenter($x,$y);
+        $olda = $this->SetAngle(-$dir);
+
+        // We need to use adjusted coordinats for the box to be able
+        // to draw the box below the baseline. This cannot be done before since
+        // the rotating point must be the original x,y since that is arounbf the
+        // point where the text will rotate and we cannot change this since
+        // that is where the GD/GreeType will rotate the text
+
+
+        // For smaller <14pt font we need to do some additional
+        // adjustments to make it look good
+        if( $this->font_size < 14 ) {
+            $x -= 2;
+            $y += 2;
+        }
+        else {
+          //  $y += $baseline_offset;
+        }
+
+        if( $shadowcolor ) {
+            $this->PushColor($shadowcolor);
+            $this->FilledRectangle($x-$xmarg+$dropwidth,$y+$ymarg+$dropwidth-$height,
+                                          $x+$width+$dropwidth,$y+$ymarg+$dropwidth);
+                                          //$cornerradius);
+            $this->PopColor();
+            $this->PushColor($fcolor);
+            $this->FilledRectangle($x-$xmarg, $y+$ymarg-$height,
+                                          $x+$width, $y+$ymarg);
+                                          //$cornerradius);
+            $this->PopColor();
+            $this->PushColor($bcolor);
+            $this->Rectangle($x-$xmarg,$y+$ymarg-$height,
+                                    $x+$width,$y+$ymarg);
+                                    //$cornerradius);
+            $this->PopColor();
+        }
+        else {
+            if( $fcolor ) {
+                $oc=$this->current_color;
+                $this->SetColor($fcolor);
+                $this->FilledRectangle($x-$xmarg,$y+$ymarg-$height,$x+$width,$y+$ymarg);//,$cornerradius);
+                $this->current_color=$oc;
+            }
+            if( $bcolor ) {
+                $oc=$this->current_color;
+                $this->SetColor($bcolor);
+                $this->Rectangle($x-$xmarg,$y+$ymarg-$height,$x+$width,$y+$ymarg);//,$cornerradius);
+                $this->current_color=$oc;
+            }
+        }
+
+        if( $this->font_size < 14 ) {
+            $x += 2;
+            $y -= 2;
+        }
+        else {
+
+            // Restore the original y before we stroke the text
+           // $y -= $baseline_offset;
+
+        }
+
+        $this->SetCenter(0,0);
+        $this->SetAngle($olda);
+
+        $h=$this->text_halign;
+        $v=$this->text_valign;
+        if( $this->text_halign == 'center') {
+            $this->SetTextAlign('center','basepoint');
+        }
+        else {
+            $this->SetTextAlign('basepoint','basepoint');
+        }
+
+        $debug=false;
+        $this->StrokeText($x, $y, $txt, $dir, $paragraph_align,$debug);
+
+        $bb = array($x-$xmarg, $y+$height-$ymarg,
+                    $x+$width, $y+$height-$ymarg,
+                    $x+$width, $y-$ymarg,
+                    $x-$xmarg, $y-$ymarg);
+
+        $this->SetTextAlign($h,$v);
+        $this->SetAngle($olda);
+
+		$this->lastx = $oldx;
+		$this->lasty = $oldy;
+
+        return $bb;
+    }
+
+    // Set text alignment
+    function SetTextAlign($halign,$valign="bottom") {
+        $this->text_halign=$halign;
+        $this->text_valign=$valign;
+    }
+
+    function _StrokeBuiltinFont($x,$y,$txt,$dir,$paragraph_align,&$aBoundingBox,$aDebug=false) {
+
+        if( is_numeric($dir) && $dir!=90 && $dir!=0)
+        JpGraphError::RaiseL(25091);//(" Internal font does not support drawing text at arbitrary angle. Use TTF fonts instead.");
+
+        $h=$this->GetTextHeight($txt);
+        $fh=$this->GetFontHeight();
+        $w=$this->GetTextWidth($txt);
+
+        if( $this->text_halign=="right") {
+            $x -= $dir==0 ? $w : $h;
+        }
+        elseif( $this->text_halign=="center" ) {
+            // For center we subtract 1 pixel since this makes the middle
+            // be prefectly in the middle
+            $x -= $dir==0 ? $w/2-1 : $h/2;
+        }
+        if( $this->text_valign=="top" ) {
+            $y += $dir==0 ? $h : $w;
+        }
+        elseif( $this->text_valign=="center" ) {
+            $y += $dir==0 ? $h/2 : $w/2;
+        }
+
+        $use_font = $this->font_family;
+
+        if( $dir==90 ) {
+            imagestringup($this->img,$use_font,$x,$y,$txt,$this->current_color);
+            $aBoundingBox = array(round($x),round($y),round($x),round($y-$w),round($x+$h),round($y-$w),round($x+$h),round($y));
+            if( $aDebug ) {
+                // Draw bounding box
+                $this->PushColor('green');
+                $this->Polygon($aBoundingBox,true);
+                $this->PopColor();
+            }
+        }
+        else {
+            if( preg_match('/\n/',$txt) ) {
+                $tmp = preg_split('/\n/',$txt);
+                for($i=0; $i < count($tmp); ++$i) {
+                    $w1 = $this->GetTextWidth($tmp[$i]);
+                    if( $paragraph_align=="left" ) {
+                        imagestring($this->img,$use_font,$x,$y-$h+1+$i*$fh,$tmp[$i],$this->current_color);
+                    }
+                    elseif( $paragraph_align=="right" ) {
+                        imagestring($this->img,$use_font,$x+($w-$w1),$y-$h+1+$i*$fh,$tmp[$i],$this->current_color);
+                    }
+                    else {
+                        imagestring($this->img,$use_font,$x+$w/2-$w1/2,$y-$h+1+$i*$fh,$tmp[$i],$this->current_color);
+                    }
+                }
+            }
+            else {
+                //Put the text
+                imagestring($this->img,$use_font,$x,$y-$h+1,$txt,$this->current_color);
+            }
+            if( $aDebug ) {
+                // Draw the bounding rectangle and the bounding box
+                $p1 = array(round($x),round($y),round($x),round($y-$h),round($x+$w),round($y-$h),round($x+$w),round($y));
+
+                // Draw bounding box
+                $this->PushColor('green');
+                $this->Polygon($p1,true);
+                $this->PopColor();
+
+            }
+            $aBoundingBox=array(round($x),round($y),round($x),round($y-$h),round($x+$w),round($y-$h),round($x+$w),round($y));
+        }
+    }
+
+    function AddTxtCR($aTxt) {
+        // If the user has just specified a '\n'
+        // instead of '\n\t' we have to add '\r' since
+        // the width will be too muchy otherwise since when
+        // we print we stroke the individually lines by hand.
+        $e = explode("\n",$aTxt);
+        $n = count($e);
+        for($i=0; $i<$n; ++$i) {
+            $e[$i]=str_replace("\r","",$e[$i]);
+        }
+        return implode("\n\r",$e);
+    }
+
+    function NormAngle($a) {
+        // Normalize angle in degrees
+        // Normalize angle to be between 0-360
+        while( $a > 360 )
+            $a -= 360;
+        while( $a < -360 )
+            $a += 360;
+        if( $a < 0 )
+            $a = 360 + $a;
+        return $a;
+    }
+
+    function imagettfbbox_fixed($size, $angle, $fontfile, $text) {
+
+
+        if( ! USE_LIBRARY_IMAGETTFBBOX ) {
+
+            $bbox = @imagettfbbox($size, $angle, $fontfile, $text);
+            if( $bbox === false ) {
+                JpGraphError::RaiseL(25092,$this->font_file);
+                //("There is either a configuration problem with TrueType or a problem reading font file (".$this->font_file."). Make sure file exists and is in a readable place for the HTTP process. (If 'basedir' restriction is enabled in PHP then the font file must be located in the document root.). It might also be a wrongly installed FreeType library. Try uppgrading to at least FreeType 2.1.13 and recompile GD with the correct setup so it can find the new FT library.");
+            }
+            $this->bbox_cache = $bbox;
+            return $bbox;
+        }
+
+        // The built in imagettfbbox is buggy for angles != 0 so
+        // we calculate this manually by getting the bounding box at
+        // angle = 0 and then rotate the bounding box manually
+        $bbox = @imagettfbbox($size, 0, $fontfile, $text);
+        if( $bbox === false ) {
+            JpGraphError::RaiseL(25092,$this->font_file);
+            //("There is either a configuration problem with TrueType or a problem reading font file (".$this->font_file."). Make sure file exists and is in a readable place for the HTTP process. (If 'basedir' restriction is enabled in PHP then the font file must be located in the document root.). It might also be a wrongly installed FreeType library. Try uppgrading to at least FreeType 2.1.13 and recompile GD with the correct setup so it can find the new FT library.");
+        }
+
+        $angle = $this->NormAngle($angle);
+
+        $a = $angle*M_PI/180;
+        $ca = cos($a);
+        $sa = sin($a);
+        $ret = array();
+
+        // We always add 1 pixel to the left since the left edge of the bounding
+        // box is sometimes coinciding with the first pixel of the text
+        //$bbox[0] -= 1;
+        //$bbox[6] -= 1;
+
+        // For roatated text we need to add extra width for rotated
+        // text since the kerning and stroking of the TTF is not the same as for
+        // text at a 0 degree angle
+
+        if( $angle > 0.001 && abs($angle-360) > 0.001 ) {
+            $h = abs($bbox[7]-$bbox[1]);
+            $w = abs($bbox[2]-$bbox[0]);
+
+            $bbox[0] -= 2;
+            $bbox[6] -= 2;
+            // The width is underestimated so compensate for that
+            $bbox[2] += round($w*0.06);
+            $bbox[4] += round($w*0.06);
+
+            // and we also need to compensate with increased height
+            $bbox[5] -= round($h*0.1);
+            $bbox[7] -= round($h*0.1);
+
+            if( $angle > 90 ) {
+                // For angles > 90 we also need to extend the height further down
+                // by the baseline since that is also one more problem
+                $bbox[1] += round($h*0.15);
+                $bbox[3] += round($h*0.15);
+
+                // and also make it slighty less height
+                $bbox[7] += round($h*0.05);
+                $bbox[5] += round($h*0.05);
+
+                // And we need to move the box slightly top the rright (from a tetx perspective)
+                $bbox[0] += round($w*0.02);
+                $bbox[6] += round($w*0.02);
+
+                if( $angle > 180 ) {
+                    // And we need to move the box slightly to the left (from a text perspective)
+                    $bbox[0] -= round($w*0.02);
+                    $bbox[6] -= round($w*0.02);
+                    $bbox[2] -= round($w*0.02);
+                    $bbox[4] -= round($w*0.02);
+
+                }
+
+            }
+            for($i = 0; $i < 7; $i += 2) {
+                $ret[$i] = round($bbox[$i] * $ca + $bbox[$i+1] * $sa);
+                $ret[$i+1] = round($bbox[$i+1] * $ca - $bbox[$i] * $sa);
+            }
+            $this->bbox_cache = $ret;
+            return $ret;
+        }
+        else {
+            $this->bbox_cache = $bbox;
+            return $bbox;
+        }
+    }
+
+    // Deprecated
+    function GetTTFBBox($aTxt,$aAngle=0) {
+        $bbox = $this->imagettfbbox_fixed($this->font_size,$aAngle,$this->font_file,$aTxt);
+         return $bbox;
+    }
+
+    function GetBBoxTTF($aTxt,$aAngle=0) {
+        // Normalize the bounding box to become a minimum
+        // enscribing rectangle
+
+        $aTxt = $this->AddTxtCR($aTxt);
+
+        if( !is_readable($this->font_file) ) {
+            JpGraphError::RaiseL(25093,$this->font_file);
+            //('Can not read font file ('.$this->font_file.') in call to Image::GetBBoxTTF. Please make sure that you have set a font before calling this method and that the font is installed in the TTF directory.');
+        }
+        $bbox = $this->imagettfbbox_fixed($this->font_size,$aAngle,$this->font_file,$aTxt);
+
+        if( $aAngle==0 ) return $bbox;
+
+        if( $aAngle >= 0 ) {
+            if(  $aAngle <= 90 ) { //<=0
+                $bbox = array($bbox[6],$bbox[1],$bbox[2],$bbox[1],
+                              $bbox[2],$bbox[5],$bbox[6],$bbox[5]);
+            }
+            elseif(  $aAngle <= 180 ) { //<= 2
+                $bbox = array($bbox[4],$bbox[7],$bbox[0],$bbox[7],
+                              $bbox[0],$bbox[3],$bbox[4],$bbox[3]);
+            }
+            elseif(  $aAngle <= 270 )  { //<= 3
+                $bbox = array($bbox[2],$bbox[5],$bbox[6],$bbox[5],
+                              $bbox[6],$bbox[1],$bbox[2],$bbox[1]);
+            }
+            else {
+                $bbox = array($bbox[0],$bbox[3],$bbox[4],$bbox[3],
+                              $bbox[4],$bbox[7],$bbox[0],$bbox[7]);
+            }
+        }
+        elseif(  $aAngle < 0 ) {
+            if( $aAngle <= -270 ) { // <= -3
+                $bbox = array($bbox[6],$bbox[1],$bbox[2],$bbox[1],
+                              $bbox[2],$bbox[5],$bbox[6],$bbox[5]);
+            }
+            elseif( $aAngle <= -180 ) { // <= -2
+                $bbox = array($bbox[0],$bbox[3],$bbox[4],$bbox[3],
+                              $bbox[4],$bbox[7],$bbox[0],$bbox[7]);
+            }
+            elseif( $aAngle <= -90 ) { // <= -1
+                $bbox = array($bbox[2],$bbox[5],$bbox[6],$bbox[5],
+                              $bbox[6],$bbox[1],$bbox[2],$bbox[1]);
+            }
+            else {
+                $bbox = array($bbox[0],$bbox[3],$bbox[4],$bbox[3],
+                              $bbox[4],$bbox[7],$bbox[0],$bbox[7]);
+            }
+        }
+        return $bbox;
+    }
+
+    function GetBBoxHeight($aTxt,$aAngle=0) {
+        $box = $this->GetBBoxTTF($aTxt,$aAngle);
+        return abs($box[7]-$box[1]);
+    }
+
+    function GetBBoxWidth($aTxt,$aAngle=0) {
+        $box = $this->GetBBoxTTF($aTxt,$aAngle);
+        return $box[2]-$box[0]+1;
+    }
+
+
+    function _StrokeTTF($x,$y,$txt,$dir,$paragraph_align,&$aBoundingBox,$debug=false) {
+
+        // Setup default inter line margin for paragraphs to be
+        // 3% of the font height.
+        $ConstLineSpacing = 0.03 ;
+
+        // Remember the anchor point before adjustment
+        if( $debug ) {
+            $ox=$x;
+            $oy=$y;
+        }
+
+        if( !preg_match('/\n/',$txt) || ($dir>0 && preg_match('/\n/',$txt)) ) {
+            // Format a single line
+
+            $txt = $this->AddTxtCR($txt);
+            $bbox=$this->GetBBoxTTF($txt,$dir);
+            $width  = $this->GetBBoxWidth($txt,$dir);
+            $height = $this->GetBBoxHeight($txt,$dir);
+
+            // The special alignment "basepoint" is mostly used internally
+            // in the library. This will put the anchor position at the left
+            // basepoint of the tetx. This is the default anchor point for
+            // TTF text.
+
+            if( $this->text_valign != 'basepoint' ) {
+                // Align x,y ot lower left corner of bbox
+
+
+                if( $this->text_halign=='right' ) {
+                    $x -= $width;
+                    $x -= $bbox[0];
+                }
+                elseif( $this->text_halign=='center' ) {
+                    $x -= $width/2;
+                    $x -= $bbox[0];
+                }
+                elseif( $this->text_halign=='baseline' ) {
+                    // This is only support for text at 90 degree !!
+                    // Do nothing the text is drawn at baseline by default
+                }
+
+                if( $this->text_valign=='top' ) {
+                    $y -= $bbox[1]; // Adjust to bottom of text
+                    $y += $height;
+                }
+                elseif( $this->text_valign=='center' ) {
+                    $y -= $bbox[1]; // Adjust to bottom of text
+                    $y += $height/2;
+                }
+                elseif( $this->text_valign=='baseline' ) {
+                    // This is only support for text at 0 degree !!
+                    // Do nothing the text is drawn at baseline by default
+                }
+            }
+            ImageTTFText ($this->img, $this->font_size, $dir, $x, $y,
+                          $this->current_color,$this->font_file,$txt);
+
+            // Calculate and return the co-ordinates for the bounding box
+            $box = $this->imagettfbbox_fixed($this->font_size,$dir,$this->font_file,$txt);
+            $p1 = array();
+
+            for($i=0; $i < 4; ++$i) {
+                $p1[] = round($box[$i*2]+$x);
+                $p1[] = round($box[$i*2+1]+$y);
+            }
+            $aBoundingBox = $p1;
+
+            // Debugging code to highlight the bonding box and bounding rectangle
+            // For text at 0 degrees the bounding box and bounding rectangle are the
+            // same
+            if( $debug ) {
+            // Draw the bounding rectangle and the bounding box
+
+                $p = array();
+                $p1 = array();
+
+                for($i=0; $i < 4; ++$i) {
+                    $p[] =  $bbox[$i*2]+$x ;
+                    $p[] =  $bbox[$i*2+1]+$y;
+                    $p1[] = $box[$i*2]+$x ;
+                    $p1[] = $box[$i*2+1]+$y ;
+                }
+
+                // Draw bounding box
+                $this->PushColor('green');
+                $this->Polygon($p1,true);
+                $this->PopColor();
+
+                // Draw bounding rectangle
+                $this->PushColor('darkgreen');
+                $this->Polygon($p,true);
+                $this->PopColor();
+
+                // Draw a cross at the anchor point
+                $this->PushColor('red');
+                $this->Line($ox-15,$oy,$ox+15,$oy);
+                $this->Line($ox,$oy-15,$ox,$oy+15);
+                $this->PopColor();
+            }
+        }
+        else {
+            // Format a text paragraph
+            $fh=$this->GetFontHeight();
+
+            // Line margin is 25% of font height
+            $linemargin=round($fh*$ConstLineSpacing);
+            $fh += $linemargin;
+            $w=$this->GetTextWidth($txt);
+
+            $y -= $linemargin/2;
+            $tmp = preg_split('/\n/',$txt);
+            $nl = count($tmp);
+            $h = $nl * $fh;
+
+            if( $this->text_halign=='right') {
+                $x -= $dir==0 ? $w : $h;
+            }
+            elseif( $this->text_halign=='center' ) {
+                $x -= $dir==0 ? $w/2 : $h/2;
+            }
+
+            if( $this->text_valign=='top' ) {
+                $y += $dir==0 ? $h : $w;
+            }
+            elseif( $this->text_valign=='center' ) {
+                $y += $dir==0 ? $h/2 : $w/2;
+            }
+
+            // Here comes a tricky bit.
+            // Since we have to give the position for the string at the
+            // baseline this means thaht text will move slightly up
+            // and down depending on any of it's character descend below
+            // the baseline, for example a 'g'. To adjust the Y-position
+            // we therefore adjust the text with the baseline Y-offset
+            // as used for the current font and size. This will keep the
+            // baseline at a fixed positoned disregarding the actual
+            // characters in the string.
+            $standardbox = $this->GetTTFBBox('Gg',$dir);
+            $yadj = $standardbox[1];
+            $xadj = $standardbox[0];
+            $aBoundingBox = array();
+            for($i=0; $i < $nl; ++$i) {
+                $wl = $this->GetTextWidth($tmp[$i]);
+                $bbox = $this->GetTTFBBox($tmp[$i],$dir);
+                if( $paragraph_align=='left' ) {
+                    $xl = $x;
+                }
+                elseif( $paragraph_align=='right' ) {
+                    $xl = $x + ($w-$wl);
+                }
+                else {
+                    // Center
+                    $xl = $x + $w/2 - $wl/2 ;
+                }
+
+                // In theory we should adjust with full pre-lead to get the lines
+                // lined up but this doesn't look good so therfore we only adjust with
+                // half th pre-lead
+                $xl -= $bbox[0]/2;
+                $yl = $y - $yadj;
+                //$xl = $xl- $xadj;
+                ImageTTFText($this->img, $this->font_size, $dir, $xl, $yl-($h-$fh)+$fh*$i,
+                             $this->current_color,$this->font_file,$tmp[$i]);
+
+               // echo "xl=$xl,".$tmp[$i]." <br>";
+                if( $debug  ) {
+                    // Draw the bounding rectangle around each line
+                    $box=@ImageTTFBBox($this->font_size,$dir,$this->font_file,$tmp[$i]);
+                    $p = array();
+                    for($j=0; $j < 4; ++$j) {
+                        $p[] = $bbox[$j*2]+$xl;
+                        $p[] = $bbox[$j*2+1]+$yl-($h-$fh)+$fh*$i;
+                    }
+
+                    // Draw bounding rectangle
+                    $this->PushColor('darkgreen');
+                    $this->Polygon($p,true);
+                    $this->PopColor();
+                }
+            }
+
+            // Get the bounding box
+            $bbox = $this->GetBBoxTTF($txt,$dir);
+            for($j=0; $j < 4; ++$j) {
+                $bbox[$j*2]+= round($x);
+                $bbox[$j*2+1]+= round($y - ($h-$fh) - $yadj);
+            }
+            $aBoundingBox = $bbox;
+
+            if( $debug ) {
+                // Draw a cross at the anchor point
+                $this->PushColor('red');
+                $this->Line($ox-25,$oy,$ox+25,$oy);
+                $this->Line($ox,$oy-25,$ox,$oy+25);
+                $this->PopColor();
+            }
+
+        }
+    }
+
+    function StrokeText($x,$y,$txt,$dir=0,$paragraph_align="left",$debug=false) {
+
+        $x = round($x);
+        $y = round($y);
+
+        // Do special language encoding
+        $txt = $this->langconv->Convert($txt,$this->font_family);
+
+        if( !is_numeric($dir) ) {
+            JpGraphError::RaiseL(25094);//(" Direction for text most be given as an angle between 0 and 90.");
+        }
+
+        if( $this->font_family >= FF_FONT0 && $this->font_family <= FF_FONT2+1) {
+            $this->_StrokeBuiltinFont($x,$y,$txt,$dir,$paragraph_align,$boundingbox,$debug);
+        }
+        elseif( $this->font_family >= _FIRST_FONT && $this->font_family <= _LAST_FONT)  {
+            $this->_StrokeTTF($x,$y,$txt,$dir,$paragraph_align,$boundingbox,$debug);
+        }
+        else {
+            JpGraphError::RaiseL(25095);//(" Unknown font font family specification. ");
+        }
+        return $boundingbox;
+    }
+
+    function SetMargin($lm,$rm,$tm,$bm) {
+
+        $this->left_margin=$lm;
+        $this->right_margin=$rm;
+        $this->top_margin=$tm;
+        $this->bottom_margin=$bm;
+
+        $this->plotwidth  = $this->width  - $this->left_margin - $this->right_margin;
+        $this->plotheight = $this->height - $this->top_margin  - $this->bottom_margin;
+
+        if( $this->width  > 0 && $this->height > 0 ) {
+            if( $this->plotwidth < 0  || $this->plotheight < 0 ) {
+            	JpGraphError::RaiseL(25130, $this->plotwidth, $this->plotheight);
+                //JpGraphError::raise("To small plot area. ($lm,$rm,$tm,$bm : $this->plotwidth x $this->plotheight). With the given image size and margins there is to little space left for the plot. Increase the plot size or reduce the margins.");
+            }
+        }
+    }
+
+    function SetTransparent($color) {
+        imagecolortransparent ($this->img,$this->rgb->allocate($color));
+    }
+
+    function SetColor($color,$aAlpha=0) {
+        $this->current_color_name = $color;
+        $this->current_color=$this->rgb->allocate($color,$aAlpha);
+        if( $this->current_color == -1 ) {
+            $tc=imagecolorstotal($this->img);
+            JpGraphError::RaiseL(25096);
+            //("Can't allocate any more colors. Image has already allocated maximum of <b>$tc colors</b>. This might happen if you have anti-aliasing turned on together with a background image or perhaps gradient fill since this requires many, many colors. Try to turn off anti-aliasing. If there is still a problem try downgrading the quality of the background image to use a smaller pallete to leave some entries for your graphs. You should try to limit the number of colors in your background image to 64. If there is still problem set the constant DEFINE(\"USE_APPROX_COLORS\",true); in jpgraph.php This will use approximative colors when the palette is full. Unfortunately there is not much JpGraph can do about this since the palette size is a limitation of current graphic format and what the underlying GD library suppports.");
+        }
+        return $this->current_color;
+    }
+
+    function PushColor($color) {
+        if( $color != "" ) {
+            $this->colorstack[$this->colorstackidx]=$this->current_color_name;
+            $this->colorstack[$this->colorstackidx+1]=$this->current_color;
+            $this->colorstackidx+=2;
+            $this->SetColor($color);
+        }
+        else {
+            JpGraphError::RaiseL(25097);//("Color specified as empty string in PushColor().");
+        }
+    }
+
+    function PopColor() {
+        if( $this->colorstackidx < 1 ) {
+            JpGraphError::RaiseL(25098);//(" Negative Color stack index. Unmatched call to PopColor()");
+        }
+        $this->current_color=$this->colorstack[--$this->colorstackidx];
+        $this->current_color_name=$this->colorstack[--$this->colorstackidx];
+    }
+
+
+    function SetLineWeight($weight) {
+        $old = $this->line_weight;
+        imagesetthickness($this->img,$weight);
+        $this->line_weight = $weight;
+        return $old;
+    }
+
+    function SetStartPoint($x,$y) {
+        $this->lastx=round($x);
+        $this->lasty=round($y);
+    }
+
+    function Arc($cx,$cy,$w,$h,$s,$e) {
+        // GD Arc doesn't like negative angles
+        while( $s < 0) $s += 360;
+        while( $e < 0) $e += 360;
+        imagearc($this->img,round($cx),round($cy),round($w),round($h),$s,$e,$this->current_color);
+    }
+
+    function FilledArc($xc,$yc,$w,$h,$s,$e,$style='') {
+        $s = round($s);
+        $e = round($e);
+        while( $s < 0 ) $s += 360;
+        while( $e < 0 ) $e += 360;
+        if( $style=='' )
+        $style=IMG_ARC_PIE;
+        if( abs($s-$e) > 0 ) {
+            imagefilledarc($this->img,round($xc),round($yc),round($w),round($h),$s,$e,$this->current_color,$style);
+//            $this->DrawImageSmoothArc($this->img,round($xc),round($yc),round($w),round($h),$s,$e,$this->current_color,$style);
+        }
+    }
+
+    function FilledCakeSlice($cx,$cy,$w,$h,$s,$e) {
+        $this->CakeSlice($cx,$cy,$w,$h,$s,$e,$this->current_color_name);
+    }
+
+    function CakeSlice($xc,$yc,$w,$h,$s,$e,$fillcolor="",$arccolor="") {
+        $s = round($s); $e = round($e);
+        $w = round($w); $h = round($h);
+        $xc = round($xc); $yc = round($yc);
+        if( $s == $e ) {
+            // A full circle. We draw this a plain circle
+            $this->PushColor($fillcolor);
+            imagefilledellipse($this->img,$xc,$yc,2*$w,2*$h,$this->current_color);
+
+            // If antialiasing is used then we often don't have any color no the surrounding
+            // arc. So, we need to check for this special case so we don't send an empty
+            // color to the push function. In this case we use the fill color for the arc as well
+            if( $arccolor != '' ) {
+                $this->PopColor();
+                $this->PushColor($arccolor);
+            }
+            imageellipse($this->img,$xc,$yc,2*$w,2*$h,$this->current_color);
+            $this->Line($xc,$yc,cos($s*M_PI/180)*$w+$xc,$yc+sin($s*M_PI/180)*$h);
+            $this->PopColor();
+        }
+        else {
+            $this->PushColor($fillcolor);
+            $this->FilledArc($xc,$yc,2*$w,2*$h,$s,$e);
+            $this->PopColor();
+            if( $arccolor != "" ) {
+                $this->PushColor($arccolor);
+                // We add 2 pixels to make the Arc() better aligned with
+                // the filled arc.
+                imagefilledarc($this->img,$xc,$yc,2*$w,2*$h,$s,$e,$this->current_color,IMG_ARC_NOFILL | IMG_ARC_EDGED ) ;
+                $this->PopColor();
+            }
+        }
+    }
+
+    function Ellipse($xc,$yc,$w,$h) {
+        $this->Arc($xc,$yc,$w,$h,0,360);
+    }
+
+    function Circle($xc,$yc,$r) {
+        imageellipse($this->img,round($xc),round($yc),$r*2,$r*2,$this->current_color);
+//        $this->DrawImageSmoothArc($this->img,round($xc),round($yc),$r*2+1,$r*2+1,0,360,$this->current_color);
+//        $this->imageSmoothCircle($this->img, round($xc),round($yc), $r*2+1, $this->current_color);
+    }
+
+    function FilledCircle($xc,$yc,$r) {
+        imagefilledellipse($this->img,round($xc),round($yc),2*$r,2*$r,$this->current_color);
+//        $this->DrawImageSmoothArc($this->img, round($xc), round($yc), 2*$r, 2*$r, 0, 360, $this->current_color);
+    }
+
+    // Linear Color InterPolation
+    function lip($f,$t,$p) {
+        $p = round($p,1);
+        $r = $f[0] + ($t[0]-$f[0])*$p;
+        $g = $f[1] + ($t[1]-$f[1])*$p;
+        $b = $f[2] + ($t[2]-$f[2])*$p;
+        return array($r,$g,$b);
+    }
+
+    // Set line style dashed, dotted etc
+    function SetLineStyle($s) {
+        if( is_numeric($s) ) {
+            if( $s<1 || $s>4 ) {
+                JpGraphError::RaiseL(25101,$s);//(" Illegal numeric argument to SetLineStyle(): ($s)");
+            }
+        }
+        elseif( is_string($s) ) {
+            if( $s == "solid" ) $s=1;
+            elseif( $s == "dotted" ) $s=2;
+            elseif( $s == "dashed" ) $s=3;
+            elseif( $s == "longdashed" ) $s=4;
+            else {
+                JpGraphError::RaiseL(25102,$s);//(" Illegal string argument to SetLineStyle(): $s");
+            }
+        }
+        else {
+            JpGraphError::RaiseL(25103,$s);//(" Illegal argument to SetLineStyle $s");
+        }
+        $old = $this->line_style;
+        $this->line_style=$s;
+        return $old;
+    }
+
+    // Same as Line but take the line_style into account
+    function StyleLine($x1,$y1,$x2,$y2,$aStyle='', $from_grid_class = false) {
+        if( $this->line_weight <= 0 ) return;
+
+        if( $aStyle === '' ) {
+            $aStyle = $this->line_style;
+        }
+
+        $dashed_line_method = 'DashedLine';
+        if ($from_grid_class) {
+            $dashed_line_method = 'DashedLineForGrid';
+        }
+
+        // Add error check since dashed line will only work if anti-alias is disabled
+        // this is a limitation in GD
+
+        if( $aStyle == 1 ) {
+            // Solid style. We can handle anti-aliasing for this
+            $this->Line($x1,$y1,$x2,$y2);
+        }
+        else {
+            // Since the GD routines doesn't handle AA for styled line
+            // we have no option than to turn it off to get any lines at
+            // all if the weight > 1
+            $oldaa = $this->GetAntiAliasing();
+            if( $oldaa && $this->line_weight > 1 ) {
+                 $this->SetAntiAliasing(false);
+            }
+
+            switch( $aStyle ) {
+                case 2: // Dotted
+                    $this->$dashed_line_method($x1,$y1,$x2,$y2,2,6);
+                    break;
+                case 3: // Dashed
+                    $this->$dashed_line_method($x1,$y1,$x2,$y2,5,9);
+                    break;
+                case 4: // Longdashes
+                    $this->$dashed_line_method($x1,$y1,$x2,$y2,9,13);
+                    break;
+                default:
+                    JpGraphError::RaiseL(25104,$this->line_style);//(" Unknown line style: $this->line_style ");
+                    break;
+            }
+            if( $oldaa ) {
+                $this->SetAntiAliasing(true);
+            }
+        }
+    }
+
+    function DashedLine($x1,$y1,$x2,$y2,$dash_length=1,$dash_space=4) {
+
+        if( $this->line_weight <= 0 ) return;
+
+        // Add error check to make sure anti-alias is not enabled.
+        // Dashed line does not work with anti-alias enabled. This
+        // is a limitation in GD.
+        if( $this->use_anti_aliasing ) {
+//            JpGraphError::RaiseL(25129); // Anti-alias can not be used with dashed lines. Please disable anti-alias or use solid lines.
+        }
+
+        $x1 = round($x1);
+        $x2 = round($x2);
+        $y1 = round($y1);
+        $y2 = round($y2);
+
+        $dash_length *= SUPERSAMPLING_SCALE;
+        $dash_space  *= SUPERSAMPLING_SCALE;
+
+        $style = array_fill(0,$dash_length,$this->current_color);
+        $style = array_pad($style,$dash_space,IMG_COLOR_TRANSPARENT);
+        imagesetstyle($this->img, $style);
+        imageline($this->img, $x1, $y1, $x2, $y2, IMG_COLOR_STYLED);
+
+        $this->lastx = $x2;
+        $this->lasty = $y2;
+    }
+
+    function DashedLineForGrid($x1,$y1,$x2,$y2,$dash_length=1,$dash_space=4) {
+
+        if( $this->line_weight <= 0 ) return;
+
+        // Add error check to make sure anti-alias is not enabled.
+        // Dashed line does not work with anti-alias enabled. This
+        // is a limitation in GD.
+        if( $this->use_anti_aliasing ) {
+//            JpGraphError::RaiseL(25129); // Anti-alias can not be used with dashed lines. Please disable anti-alias or use solid lines.
+        }
+
+        $x1 = round($x1);
+        $x2 = round($x2);
+        $y1 = round($y1);
+        $y2 = round($y2);
+
+        /*
+        $dash_length *= $this->scale;
+        $dash_space  *= $this->scale;
+        */
+
+        $dash_length = 2;
+        $dash_length = 4;
+        imagesetthickness($this->img, 1);
+        $style = array_fill(0,$dash_length, $this->current_color); //hexdec('CCCCCC'));
+        $style = array_pad($style,$dash_space,IMG_COLOR_TRANSPARENT);
+        imagesetstyle($this->img, $style);
+        imageline($this->img, $x1, $y1, $x2, $y2, IMG_COLOR_STYLED);
+
+        $this->lastx = $x2;
+        $this->lasty = $y2;
+    }
+
+    function Line($x1,$y1,$x2,$y2) {
+
+        if( $this->line_weight <= 0 ) return;
+
+        $x1 = round($x1);
+        $x2 = round($x2);
+        $y1 = round($y1);
+        $y2 = round($y2);
+
+        imageline($this->img,$x1,$y1,$x2,$y2,$this->current_color);
+//        $this->DrawLine($this->img, $x1, $y1, $x2, $y2, $this->line_weight, $this->current_color);
+        $this->lastx=$x2;
+        $this->lasty=$y2;
+    }
+
+    function Polygon($p,$closed=FALSE,$fast=FALSE) {
+
+        if( $this->line_weight <= 0 ) return;
+
+        $n=count($p);
+        $oldx = $p[0];
+        $oldy = $p[1];
+        if( $fast ) {
+            for( $i=2; $i < $n; $i+=2 ) {
+                imageline($this->img,$oldx,$oldy,$p[$i],$p[$i+1],$this->current_color);
+                $oldx = $p[$i];
+                $oldy = $p[$i+1];
+            }
+            if( $closed ) {
+                imageline($this->img,$p[$n*2-2],$p[$n*2-1],$p[0],$p[1],$this->current_color);
+            }
+        }
+        else {
+            for( $i=2; $i < $n; $i+=2 ) {
+                $this->StyleLine($oldx,$oldy,$p[$i],$p[$i+1]);
+                $oldx = $p[$i];
+                $oldy = $p[$i+1];
+            }
+            if( $closed ) {
+                $this->StyleLine($oldx,$oldy,$p[0],$p[1]);
+            }
+        }
+    }
+
+    function FilledPolygon($pts) {
+        $n=count($pts);
+        if( $n == 0 ) {
+            JpGraphError::RaiseL(25105);//('NULL data specified for a filled polygon. Check that your data is not NULL.');
+        }
+        for($i=0; $i < $n; ++$i) {
+            $pts[$i] = round($pts[$i]);
+        }
+        $old = $this->line_weight;
+        imagesetthickness($this->img,1);
+        imagefilledpolygon($this->img,$pts,count($pts)/2,$this->current_color);
+        $this->line_weight = $old;
+        imagesetthickness($this->img,$old);
+    }
+
+    function Rectangle($xl,$yu,$xr,$yl) {
+        $this->Polygon(array($xl,$yu,$xr,$yu,$xr,$yl,$xl,$yl,$xl,$yu));
+    }
+
+    function FilledRectangle($xl,$yu,$xr,$yl) {
+        $this->FilledPolygon(array($xl,$yu,$xr,$yu,$xr,$yl,$xl,$yl));
+    }
+
+    function FilledRectangle2($xl,$yu,$xr,$yl,$color1,$color2,$style=1) {
+        // Fill a rectangle with lines of two colors
+        if( $style===1 ) {
+            // Horizontal stripe
+            if( $yl < $yu ) {
+                $t = $yl; $yl=$yu; $yu=$t;
+            }
+            for( $y=$yu; $y <= $yl; ++$y) {
+                $this->SetColor($color1);
+                $this->Line($xl,$y,$xr,$y);
+                ++$y;
+                $this->SetColor($color2);
+                $this->Line($xl,$y,$xr,$y);
+            }
+        }
+        else {
+            if( $xl < $xl ) {
+                $t = $xl; $xl=$xr; $xr=$t;
+            }
+            for( $x=$xl; $x <= $xr; ++$x) {
+                $this->SetColor($color1);
+                $this->Line($x,$yu,$x,$yl);
+                ++$x;
+                $this->SetColor($color2);
+                $this->Line($x,$yu,$x,$yl);
+            }
+        }
+    }
+
+    function ShadowRectangle($xl,$yu,$xr,$yl,$fcolor=false,$shadow_width=4,$shadow_color='darkgray',$useAlpha=true) {
+        // This is complicated by the fact that we must also handle the case where
+        // the reactangle has no fill color
+        $xl = floor($xl);
+        $yu = floor($yu);
+        $xr = floor($xr);
+        $yl = floor($yl);
+        $this->PushColor($shadow_color);
+        $shadowAlpha=0;
+        $this->SetLineWeight(1);
+        $this->SetLineStyle('solid');
+        $basecolor = $this->rgb->Color($shadow_color);
+        $shadow_color = array($basecolor[0],$basecolor[1],$basecolor[2],);
+        for( $i=0; $i < $shadow_width; ++$i ) {
+            $this->SetColor($shadow_color,$shadowAlpha);
+            $this->Line($xr-$shadow_width+$i,   $yu+$shadow_width,
+                        $xr-$shadow_width+$i,   $yl-$shadow_width-1+$i);
+            $this->Line($xl+$shadow_width,   $yl-$shadow_width+$i,
+                        $xr-$shadow_width+$i,   $yl-$shadow_width+$i);
+            if( $useAlpha ) $shadowAlpha += 1.0/$shadow_width;
+        }
+
+        $this->PopColor();
+        if( $fcolor==false ) {
+            $this->Rectangle($xl,$yu,$xr-$shadow_width-1,$yl-$shadow_width-1);
+        }
+        else {
+            $this->PushColor($fcolor);
+            $this->FilledRectangle($xl,$yu,$xr-$shadow_width-1,$yl-$shadow_width-1);
+            $this->PopColor();
+            $this->Rectangle($xl,$yu,$xr-$shadow_width-1,$yl-$shadow_width-1);
+        }
+    }
+
+    function FilledRoundedRectangle($xt,$yt,$xr,$yl,$r=5) {
+        if( $r==0 ) {
+            $this->FilledRectangle($xt,$yt,$xr,$yl);
+            return;
+        }
+
+        // To avoid overlapping fillings (which will look strange
+        // when alphablending is enabled) we have no choice but
+        // to fill the five distinct areas one by one.
+
+        // Center square
+        $this->FilledRectangle($xt+$r,$yt+$r,$xr-$r,$yl-$r);
+        // Top band
+        $this->FilledRectangle($xt+$r,$yt,$xr-$r,$yt+$r);
+        // Bottom band
+        $this->FilledRectangle($xt+$r,$yl-$r,$xr-$r,$yl);
+        // Left band
+        $this->FilledRectangle($xt,$yt+$r,$xt+$r,$yl-$r);
+        // Right band
+        $this->FilledRectangle($xr-$r,$yt+$r,$xr,$yl-$r);
+
+        // Topleft & Topright arc
+        $this->FilledArc($xt+$r,$yt+$r,$r*2,$r*2,180,270);
+        $this->FilledArc($xr-$r,$yt+$r,$r*2,$r*2,270,360);
+
+        // Bottomleft & Bottom right arc
+        $this->FilledArc($xt+$r,$yl-$r,$r*2,$r*2,90,180);
+        $this->FilledArc($xr-$r,$yl-$r,$r*2,$r*2,0,90);
+
+    }
+
+    function RoundedRectangle($xt,$yt,$xr,$yl,$r=5) {
+
+        if( $r==0 ) {
+            $this->Rectangle($xt,$yt,$xr,$yl);
+            return;
+        }
+
+        // Top & Bottom line
+        $this->Line($xt+$r,$yt,$xr-$r,$yt);
+        $this->Line($xt+$r,$yl,$xr-$r,$yl);
+
+        // Left & Right line
+        $this->Line($xt,$yt+$r,$xt,$yl-$r);
+        $this->Line($xr,$yt+$r,$xr,$yl-$r);
+
+        // Topleft & Topright arc
+        $this->Arc($xt+$r,$yt+$r,$r*2,$r*2,180,270);
+        $this->Arc($xr-$r,$yt+$r,$r*2,$r*2,270,360);
+
+        // Bottomleft & Bottomright arc
+        $this->Arc($xt+$r,$yl-$r,$r*2,$r*2,90,180);
+        $this->Arc($xr-$r,$yl-$r,$r*2,$r*2,0,90);
+    }
+
+    function FilledBevel($x1,$y1,$x2,$y2,$depth=2,$color1='white@0.4',$color2='darkgray@0.4') {
+        $this->FilledRectangle($x1,$y1,$x2,$y2);
+        $this->Bevel($x1,$y1,$x2,$y2,$depth,$color1,$color2);
+    }
+
+    function Bevel($x1,$y1,$x2,$y2,$depth=2,$color1='white@0.4',$color2='black@0.5') {
+        $this->PushColor($color1);
+        for( $i=0; $i < $depth; ++$i ) {
+            $this->Line($x1+$i,$y1+$i,$x1+$i,$y2-$i);
+            $this->Line($x1+$i,$y1+$i,$x2-$i,$y1+$i);
+        }
+        $this->PopColor();
+
+        $this->PushColor($color2);
+        for( $i=0; $i < $depth; ++$i ) {
+            $this->Line($x1+$i,$y2-$i,$x2-$i,$y2-$i);
+            $this->Line($x2-$i,$y1+$i,$x2-$i,$y2-$i-1);
+        }
+        $this->PopColor();
+    }
+
+    function StyleLineTo($x,$y) {
+        $this->StyleLine($this->lastx,$this->lasty,$x,$y);
+        $this->lastx=$x;
+        $this->lasty=$y;
+    }
+
+    function LineTo($x,$y) {
+        $this->Line($this->lastx,$this->lasty,$x,$y);
+        $this->lastx=$x;
+        $this->lasty=$y;
+    }
+
+    function Point($x,$y) {
+        imagesetpixel($this->img,round($x),round($y),$this->current_color);
+    }
+
+    function Fill($x,$y) {
+        imagefill($this->img,round($x),round($y),$this->current_color);
+    }
+
+    function FillToBorder($x,$y,$aBordColor) {
+        $bc = $this->rgb->allocate($aBordColor);
+        if( $bc == -1 ) {
+            JpGraphError::RaiseL(25106);//('Image::FillToBorder : Can not allocate more colors');
+        }
+        imagefilltoborder($this->img,round($x),round($y),$bc,$this->current_color);
+    }
+
+    function SetExpired($aFlg=true) {
+        $this->expired = $aFlg;
+    }
+
+    // Generate image header
+    function Headers() {
+
+        // In case we are running from the command line with the client version of
+        // PHP we can't send any headers.
+        $sapi = php_sapi_name();
+        if( $sapi == 'cli' ) return;
+
+        // These parameters are set by headers_sent() but they might cause
+        // an undefined variable error unless they are initilized
+        $file='';
+        $lineno='';
+        if( headers_sent($file,$lineno) ) {
+            $file=basename($file);
+            $t = new ErrMsgText();
+            $msg = $t->Get(10,$file,$lineno);
+            die($msg);
+        }
+
+        if ($this->expired) {
+            header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
+            header("Last-Modified: " . gmdate("D, d M Y H:i:s") . "GMT");
+            header("Cache-Control: no-cache, must-revalidate");
+            header("Pragma: no-cache");
+        }
+        header("Content-type: image/$this->img_format");
+    }
+
+    // Adjust image quality for formats that allow this
+    function SetQuality($q) {
+        $this->quality = $q;
+    }
+
+    // Stream image to browser or to file
+    function Stream($aFile="") {
+        $this->DoSupersampling();
+
+        $func="image".$this->img_format;
+        if( $this->img_format=="jpeg" && $this->quality != null ) {
+            $res = @$func($this->img,$aFile,$this->quality);
+        }
+        else {
+            if( $aFile != "" ) {
+                $res = @$func($this->img,$aFile);
+                if( !$res ) {
+                    JpGraphError::RaiseL(25107,$aFile);//("Can't write to file '$aFile'. Check that the process running PHP has enough permission.");
+                }
+            }
+            else {
+                $res = @$func($this->img);
+                if( !$res ) {
+                    JpGraphError::RaiseL(25108);//("Can't stream image. This is most likely due to a faulty PHP/GD setup. Try to recompile PHP and use the built-in GD library that comes with PHP.");
+                }
+
+            }
+        }
+    }
+
+    // Do SuperSampling using $scale
+    function DoSupersampling() {
+        if (SUPERSAMPLING_SCALE <= 1) {
+            return $this->img;
+        }
+
+        $dst_img = @imagecreatetruecolor($this->original_width, $this->original_height);
+        imagecopyresampled($dst_img, $this->img, 0, 0, 0, 0, $this->original_width, $this->original_height, $this->width, $this->height);
+        $this->Destroy();
+        return $this->img = $dst_img;
+    }
+
+    // Clear resources used by image (this is normally not used since all resources are/should be
+    // returned when the script terminates
+    function Destroy() {
+        imagedestroy($this->img);
+    }
+
+    // Specify image format. Note depending on your installation
+    // of PHP not all formats may be supported.
+    function SetImgFormat($aFormat,$aQuality=75) {
+        $this->quality = $aQuality;
+        $aFormat = strtolower($aFormat);
+        $tst = true;
+        $supported = imagetypes();
+        if( $aFormat=="auto" ) {
+            if( $supported & IMG_PNG )      $this->img_format="png";
+            elseif( $supported & IMG_JPG )  $this->img_format="jpeg";
+            elseif( $supported & IMG_GIF )  $this->img_format="gif";
+            elseif( $supported & IMG_WBMP ) $this->img_format="wbmp";
+            elseif( $supported & IMG_XPM )  $this->img_format="xpm";
+            else {
+                JpGraphError::RaiseL(25109);//("Your PHP (and GD-lib) installation does not appear to support any known graphic formats. You need to first make sure GD is compiled as a module to PHP. If you also want to use JPEG images you must get the JPEG library. Please see the PHP docs for details.");
+            }
+            return true;
+        }
+        else {
+            if( $aFormat=="jpeg" || $aFormat=="png" || $aFormat=="gif" ) {
+                if( $aFormat=="jpeg" && !($supported & IMG_JPG) )       $tst=false;
+                elseif( $aFormat=="png" && !($supported & IMG_PNG) )    $tst=false;
+                elseif( $aFormat=="gif" && !($supported & IMG_GIF) )    $tst=false;
+                elseif( $aFormat=="wbmp" && !($supported & IMG_WBMP) )  $tst=false;
+                elseif( $aFormat=="xpm" && !($supported & IMG_XPM) )    $tst=false;
+                else {
+                    $this->img_format=$aFormat;
+                    return true;
+                }
+            }
+            else {
+                $tst=false;
+            }
+            if( !$tst ) {
+                JpGraphError::RaiseL(25110,$aFormat);//(" Your PHP installation does not support the chosen graphic format: $aFormat");
+            }
+        }
+    }
+
+    /**
+    * Draw Line
+    */
+    function DrawLine($im, $x1, $y1, $x2, $y2, $weight, $color) {
+        if ($weight == 1) {
+            return imageline($im,$x1,$y1,$x2,$y2,$color);
+        }
+
+        $angle=(atan2(($y1 - $y2), ($x2 - $x1)));
+
+        $dist_x = $weight * (sin($angle)) / 2;
+        $dist_y = $weight * (cos($angle)) / 2;
+
+        $p1x=ceil(($x1 + $dist_x));
+        $p1y=ceil(($y1 + $dist_y));
+        $p2x=ceil(($x2 + $dist_x));
+        $p2y=ceil(($y2 + $dist_y));
+        $p3x=ceil(($x2 - $dist_x));
+        $p3y=ceil(($y2 - $dist_y));
+        $p4x=ceil(($x1 - $dist_x));
+        $p4y=ceil(($y1 - $dist_y));
+
+        $array=array($p1x,$p1y,$p2x,$p2y,$p3x,$p3y,$p4x,$p4y);
+        imagefilledpolygon ( $im, $array, (count($array)/2), $color );
+
+        // for antialias
+        imageline($im, $p1x, $p1y, $p2x, $p2y, $color);
+        imageline($im, $p3x, $p3y, $p4x, $p4y, $color);
+        return;
+
+
+
+          return imageline($this->img,$x1,$y1,$x2,$y2,$this->current_color);
+      $weight = 8;
+        if ($weight <= 1) {
+          return imageline($this->img,$x1,$y1,$x2,$y2,$this->current_color);
+        }
+
+        $pts = array();
+
+        $weight /= 2;
+
+        if ($y2 - $y1 == 0) {
+            // x line
+            $pts = array();
+            $pts[] = $x1; $pts[] = $y1 - $weight;
+            $pts[] = $x1; $pts[] = $y1 + $weight;
+            $pts[] = $x2; $pts[] = $y2 + $weight;
+            $pts[] = $x2; $pts[] = $y2 - $weight;
+
+        } elseif ($x2 - $x1 == 0) {
+            // y line
+            $pts = array();
+            $pts[] = $x1 - $weight; $pts[] = $y1;
+            $pts[] = $x1 + $weight; $pts[] = $y1;
+            $pts[] = $x2 + $weight; $pts[] = $y2;
+            $pts[] = $x2 - $weight; $pts[] = $y2;
+
+        } else {
+
+            var_dump($x1, $x2, $y1, $y2);
+            $length = sqrt(pow($x2 - $x1, 2) + pow($y2 - $y1, 2));
+            var_dump($length);exit;
+            exit;
+
+/*
+            $lean = ($y2 - $y1) / ($x2 - $x1);
+            $lean2 = -1 / $lean;
+            $sin = $lean / ($y2 - $y1);
+            $cos = $lean / ($x2 - $x1);
+
+            $pts[] = $x1 + (-$weight * $sin); $pts[] = $y1 + (-$weight * $cos);
+            $pts[] = $x1 + (+$weight * $sin); $pts[] = $y1 + (+$weight * $cos);
+            $pts[] = $x2 + (+$weight * $sin); $pts[] = $y2 + (+$weight * $cos);
+            $pts[] = $x2 + (-$weight * $sin); $pts[] = $y2 + (-$weight * $cos);
+*/
+        }
+
+//print_r($pts);exit;
+        if (count($pts)/2 < 3) {
+            return;
+        }
+
+        imagesetthickness($im, 1);
+        imagefilledpolygon($im, $pts,count($pts)/2, $color);
+
+
+        $weight *= 2;
+
+//        $this->DrawImageSmoothArc($im, $x1, $y1, $weight, $weight, 0, 360, $color);
+//        $this->DrawImageSmoothArc($im, $x2, $y2, $weight, $weight, 0, 360, $color);
+    }
+
+
+    function DrawImageSmoothArc($im, $xc, $yc, $w, $h, $s, $e, $color, $style = null) {
+        $tmp = $s;
+        $s = (360 - $e) / 180 * M_PI;
+        $e = (360 - $tmp) / 180 * M_PI;
+        return imageSmoothArc($im, round($xc), round($yc), round($w), round($h), $this->CreateColorForImageSmoothArc($color), $s, $e);
+    }
+
+    function CreateColorForImageSmoothArc($color) {
+        $alpha = $color >> 24 & 0xFF;
+        $red   = $color >> 16 & 0xFF;
+        $green = $color >> 8 & 0xFF;
+        $blue  = $color & 0xFF;
+
+//var_dump($alpha, $red, $green, $blue);exit;
+
+        return array($red, $green, $blue, $alpha);
+    }
+
+    function imageSmoothCircle( &$img, $cx, $cy, $cr, $color ) {
+        $ir = $cr;
+        $ix = 0;
+        $iy = $ir;
+        $ig = 2 * $ir - 3;
+        $idgr = -6;
+        $idgd = 4 * $ir - 10;
+        $fill = imageColorExactAlpha( $img, $color[ 'R' ], $color[ 'G' ], $color[ 'B' ], 0 );
+        imageLine( $img, $cx + $cr - 1, $cy, $cx, $cy, $fill );
+        imageLine( $img, $cx - $cr + 1, $cy, $cx - 1, $cy, $fill );
+        imageLine( $img, $cx, $cy + $cr - 1, $cx, $cy + 1, $fill );
+        imageLine( $img, $cx, $cy - $cr + 1, $cx, $cy - 1, $fill );
+        $draw = imageColorExactAlpha( $img, $color[ 'R' ], $color[ 'G' ], $color[ 'B' ], 42 );
+        imageSetPixel( $img, $cx + $cr, $cy, $draw );
+        imageSetPixel( $img, $cx - $cr, $cy, $draw );
+        imageSetPixel( $img, $cx, $cy + $cr, $draw );
+        imageSetPixel( $img, $cx, $cy - $cr, $draw );
+        while ( $ix <= $iy - 2 ) {
+            if ( $ig < 0 ) {
+                $ig += $idgd;
+                $idgd -= 8;
+                $iy--;
+            } else {
+                $ig += $idgr;
+                $idgd -= 4;
+            }
+            $idgr -= 4;
+            $ix++;
+            imageLine( $img, $cx + $ix, $cy + $iy - 1, $cx + $ix, $cy + $ix, $fill );
+            imageLine( $img, $cx + $ix, $cy - $iy + 1, $cx + $ix, $cy - $ix, $fill );
+            imageLine( $img, $cx - $ix, $cy + $iy - 1, $cx - $ix, $cy + $ix, $fill );
+            imageLine( $img, $cx - $ix, $cy - $iy + 1, $cx - $ix, $cy - $ix, $fill );
+            imageLine( $img, $cx + $iy - 1, $cy + $ix, $cx + $ix, $cy + $ix, $fill );
+            imageLine( $img, $cx + $iy - 1, $cy - $ix, $cx + $ix, $cy - $ix, $fill );
+            imageLine( $img, $cx - $iy + 1, $cy + $ix, $cx - $ix, $cy + $ix, $fill );
+            imageLine( $img, $cx - $iy + 1, $cy - $ix, $cx - $ix, $cy - $ix, $fill );
+            $filled = 0;
+            for ( $xx = $ix - 0.45; $xx < $ix + 0.5; $xx += 0.2 ) {
+                for ( $yy = $iy - 0.45; $yy < $iy + 0.5; $yy += 0.2 ) {
+                    if ( sqrt( pow( $xx, 2 ) + pow( $yy, 2 ) ) < $cr ) $filled += 4;
+                }
+            }
+            $draw = imageColorExactAlpha( $img, $color[ 'R' ], $color[ 'G' ], $color[ 'B' ], ( 100 - $filled ) );
+            imageSetPixel( $img, $cx + $ix, $cy + $iy, $draw );
+            imageSetPixel( $img, $cx + $ix, $cy - $iy, $draw );
+            imageSetPixel( $img, $cx - $ix, $cy + $iy, $draw );
+            imageSetPixel( $img, $cx - $ix, $cy - $iy, $draw );
+            imageSetPixel( $img, $cx + $iy, $cy + $ix, $draw );
+            imageSetPixel( $img, $cx + $iy, $cy - $ix, $draw );
+            imageSetPixel( $img, $cx - $iy, $cy + $ix, $draw );
+            imageSetPixel( $img, $cx - $iy, $cy - $ix, $draw );
+        }
+    }
+
+    function __get($name) {
+
+        if (strpos($name, 'raw_') !== false) {
+            // if $name == 'raw_left_margin' , return $this->_left_margin;
+            $variable_name = '_' . str_replace('raw_', '', $name);
+            return $this->$variable_name;
+        }
+
+        $variable_name = '_' . $name;
+
+        if (isset($this->$variable_name)) {
+            return $this->$variable_name * SUPERSAMPLING_SCALE;
+        } else {
+            JpGraphError::RaiseL('25132', $name);
+        }
+    }
+
+    function __set($name, $value) {
+        $this->{'_'.$name} = $value;
+    }
+
+} // CLASS
+
+//===================================================
+// CLASS RotImage
+// Description: Exactly as Image but draws the image at
+// a specified angle around a specified rotation point.
+//===================================================
+class RotImage extends Image {
+    public $a=0;
+    public $dx=0,$dy=0,$transx=0,$transy=0;
+    private $m=array();
+
+    function __construct($aWidth,$aHeight,$a=0,$aFormat=DEFAULT_GFORMAT,$aSetAutoMargin=true) {
+        parent::__construct($aWidth,$aHeight,$aFormat,$aSetAutoMargin);
+        $this->dx=$this->left_margin+$this->plotwidth/2;
+        $this->dy=$this->top_margin+$this->plotheight/2;
+        $this->SetAngle($a);
+    }
+
+    function SetCenter($dx,$dy) {
+        $old_dx = $this->dx;
+        $old_dy = $this->dy;
+        $this->dx=$dx;
+        $this->dy=$dy;
+        $this->SetAngle($this->a);
+        return array($old_dx,$old_dy);
+    }
+
+    function SetTranslation($dx,$dy) {
+        $old = array($this->transx,$this->transy);
+        $this->transx = $dx;
+        $this->transy = $dy;
+        return $old;
+    }
+
+    function UpdateRotMatrice()  {
+        $a = $this->a;
+        $a *= M_PI/180;
+        $sa=sin($a); $ca=cos($a);
+        // Create the rotation matrix
+        $this->m[0][0] = $ca;
+        $this->m[0][1] = -$sa;
+        $this->m[0][2] = $this->dx*(1-$ca) + $sa*$this->dy ;
+        $this->m[1][0] = $sa;
+        $this->m[1][1] = $ca;
+        $this->m[1][2] = $this->dy*(1-$ca) - $sa*$this->dx ;
+    }
+
+    function SetAngle($a) {
+        $tmp = $this->a;
+        $this->a = $a;
+        $this->UpdateRotMatrice();
+        return $tmp;
+    }
+
+    function Circle($xc,$yc,$r) {
+        list($xc,$yc) = $this->Rotate($xc,$yc);
+        parent::Circle($xc,$yc,$r);
+    }
+
+    function FilledCircle($xc,$yc,$r) {
+        list($xc,$yc) = $this->Rotate($xc,$yc);
+        parent::FilledCircle($xc,$yc,$r);
+    }
+
+
+    function Arc($xc,$yc,$w,$h,$s,$e) {
+        list($xc,$yc) = $this->Rotate($xc,$yc);
+        $s += $this->a;
+        $e += $this->a;
+        parent::Arc($xc,$yc,$w,$h,$s,$e);
+    }
+
+    function FilledArc($xc,$yc,$w,$h,$s,$e,$style='') {
+        list($xc,$yc) = $this->Rotate($xc,$yc);
+        $s += $this->a;
+        $e += $this->a;
+        parent::FilledArc($xc,$yc,$w,$h,$s,$e);
+    }
+
+    function SetMargin($lm,$rm,$tm,$bm) {
+        parent::SetMargin($lm,$rm,$tm,$bm);
+        $this->dx=$this->left_margin+$this->plotwidth/2;
+        $this->dy=$this->top_margin+$this->plotheight/2;
+        $this->UpdateRotMatrice();
+    }
+
+    function Rotate($x,$y) {
+        // Optimization. Ignore rotation if Angle==0 || Angle==360
+        if( $this->a == 0 || $this->a == 360 ) {
+            return array($x + $this->transx, $y + $this->transy );
+        }
+        else {
+            $x1=round($this->m[0][0]*$x + $this->m[0][1]*$y,1) + $this->m[0][2] + $this->transx;
+            $y1=round($this->m[1][0]*$x + $this->m[1][1]*$y,1) + $this->m[1][2] + $this->transy;
+            return array($x1,$y1);
+        }
+    }
+
+    function CopyMerge($fromImg,$toX,$toY,$fromX,$fromY,$toWidth,$toHeight,$fromWidth=-1,$fromHeight=-1,$aMix=100) {
+        list($toX,$toY) = $this->Rotate($toX,$toY);
+        parent::CopyMerge($fromImg,$toX,$toY,$fromX,$fromY,$toWidth,$toHeight,$fromWidth,$fromHeight,$aMix);
+
+    }
+
+    function ArrRotate($pnts) {
+        $n = count($pnts)-1;
+        for($i=0; $i < $n; $i+=2) {
+            list ($x,$y) = $this->Rotate($pnts[$i],$pnts[$i+1]);
+            $pnts[$i] = $x; $pnts[$i+1] = $y;
+        }
+        return $pnts;
+    }
+
+    function DashedLine($x1,$y1,$x2,$y2,$dash_length=1,$dash_space=4) {
+        list($x1,$y1) = $this->Rotate($x1,$y1);
+        list($x2,$y2) = $this->Rotate($x2,$y2);
+        parent::DashedLine($x1,$y1,$x2,$y2,$dash_length,$dash_space);
+    }
+
+    function Line($x1,$y1,$x2,$y2) {
+        list($x1,$y1) = $this->Rotate($x1,$y1);
+        list($x2,$y2) = $this->Rotate($x2,$y2);
+        parent::Line($x1,$y1,$x2,$y2);
+    }
+
+    function Rectangle($x1,$y1,$x2,$y2) {
+        // Rectangle uses Line() so it will be rotated through that call
+        parent::Rectangle($x1,$y1,$x2,$y2);
+    }
+
+    function FilledRectangle($x1,$y1,$x2,$y2) {
+        if( $y1==$y2 || $x1==$x2 )
+        $this->Line($x1,$y1,$x2,$y2);
+        else
+        $this->FilledPolygon(array($x1,$y1,$x2,$y1,$x2,$y2,$x1,$y2));
+    }
+
+    function Polygon($pnts,$closed=FALSE,$fast=FALSE) {
+        // Polygon uses Line() so it will be rotated through that call unless
+        // fast drawing routines are used in which case a rotate is needed
+        if( $fast ) {
+            parent::Polygon($this->ArrRotate($pnts));
+        }
+        else {
+            parent::Polygon($pnts,$closed,$fast);
+        }
+    }
+
+    function FilledPolygon($pnts) {
+        parent::FilledPolygon($this->ArrRotate($pnts));
+    }
+
+    function Point($x,$y) {
+        list($xp,$yp) = $this->Rotate($x,$y);
+        parent::Point($xp,$yp);
+    }
+
+    function StrokeText($x,$y,$txt,$dir=0,$paragraph_align="left",$debug=false) {
+        list($xp,$yp) = $this->Rotate($x,$y);
+        return parent::StrokeText($xp,$yp,$txt,$dir,$paragraph_align,$debug);
+    }
+}
+
+//=======================================================================
+// CLASS ImgStreamCache
+// Description: Handle caching of graphs to files. All image output goes
+//              through this class
+//=======================================================================
+class ImgStreamCache {
+    private $cache_dir, $timeout=0;  // Infinite timeout
+    //---------------
+    // CONSTRUCTOR
+    function __construct($aCacheDir=CACHE_DIR) {
+        $this->cache_dir = $aCacheDir;
+    }
+
+    //---------------
+    // PUBLIC METHODS
+
+    // Specify a timeout (in minutes) for the file. If the file is older then the
+    // timeout value it will be overwritten with a newer version.
+    // If timeout is set to 0 this is the same as infinite large timeout and if
+    // timeout is set to -1 this is the same as infinite small timeout
+    function SetTimeout($aTimeout) {
+        $this->timeout=$aTimeout;
+    }
+
+    // Output image to browser and also write it to the cache
+    function PutAndStream($aImage,$aCacheFileName,$aInline,$aStrokeFileName) {
+
+        // Check if we should always stroke the image to a file
+        if( _FORCE_IMGTOFILE ) {
+            $aStrokeFileName = _FORCE_IMGDIR.GenImgName();
+        }
+
+        if( $aStrokeFileName != '' ) {
+
+            if( $aStrokeFileName == 'auto' ) {
+                $aStrokeFileName = GenImgName();
+            }
+
+            if( file_exists($aStrokeFileName) ) {
+
+                // Wait for lock (to make sure no readers are trying to access the image)
+                $fd = fopen($aStrokeFileName,'w');
+                $lock = flock($fd, LOCK_EX);
+
+                // Since the image write routines only accepts a filename which must not
+                // exist we need to delete the old file first
+                if( !@unlink($aStrokeFileName) ) {
+                    $lock = flock($fd, LOCK_UN);
+                    JpGraphError::RaiseL(25111,$aStrokeFileName);
+                    //(" Can't delete cached image $aStrokeFileName. Permission problem?");
+                }
+                $aImage->Stream($aStrokeFileName);
+                $lock = flock($fd, LOCK_UN);
+                fclose($fd);
+
+            }
+            else {
+                $aImage->Stream($aStrokeFileName);
+            }
+
+            return;
+        }
+
+        if( $aCacheFileName != '' && USE_CACHE) {
+
+            $aCacheFileName = $this->cache_dir . $aCacheFileName;
+            if( file_exists($aCacheFileName) ) {
+                if( !$aInline ) {
+                    // If we are generating image off-line (just writing to the cache)
+                    // and the file exists and is still valid (no timeout)
+                    // then do nothing, just return.
+                    $diff=time()-filemtime($aCacheFileName);
+                    if( $diff < 0 ) {
+                        JpGraphError::RaiseL(25112,$aCacheFileName);
+                        //(" Cached imagefile ($aCacheFileName) has file date in the future!!");
+                    }
+                    if( $this->timeout>0 && ($diff <= $this->timeout*60) ) return;
+                }
+
+                // Wait for lock (to make sure no readers are trying to access the image)
+                $fd = fopen($aCacheFileName,'w');
+                $lock = flock($fd, LOCK_EX);
+
+                if( !@unlink($aCacheFileName) ) {
+                    $lock = flock($fd, LOCK_UN);
+                    JpGraphError::RaiseL(25113,$aStrokeFileName);
+                    //(" Can't delete cached image $aStrokeFileName. Permission problem?");
+                }
+                $aImage->Stream($aCacheFileName);
+                $lock = flock($fd, LOCK_UN);
+                fclose($fd);
+
+            }
+            else {
+                $this->MakeDirs(dirname($aCacheFileName));
+                if( !is_writeable(dirname($aCacheFileName)) ) {
+                    JpGraphError::RaiseL(25114,$aCacheFileName);
+                    //('PHP has not enough permissions to write to the cache file '.$aCacheFileName.'. Please make sure that the user running PHP has write permission for this file if you wan to use the cache system with JpGraph.');
+                }
+                $aImage->Stream($aCacheFileName);
+            }
+
+            $res=true;
+            // Set group to specified
+            if( CACHE_FILE_GROUP != '' ) {
+                $res = @chgrp($aCacheFileName,CACHE_FILE_GROUP);
+            }
+            if( CACHE_FILE_MOD != '' ) {
+                $res = @chmod($aCacheFileName,CACHE_FILE_MOD);
+            }
+            if( !$res ) {
+                JpGraphError::RaiseL(25115,$aStrokeFileName);
+                //(" Can't set permission for cached image $aStrokeFileName. Permission problem?");
+            }
+
+            $aImage->Destroy();
+            if( $aInline ) {
+                if ($fh = @fopen($aCacheFileName, "rb") ) {
+                    $aImage->Headers();
+                    fpassthru($fh);
+                    return;
+                }
+                else {
+                    JpGraphError::RaiseL(25116,$aFile);//(" Cant open file from cache [$aFile]");
+                }
+            }
+        }
+        elseif( $aInline ) {
+            $aImage->Headers();
+            $aImage->Stream();
+            return;
+        }
+    }
+
+    function IsValid($aCacheFileName) {
+        $aCacheFileName = $this->cache_dir.$aCacheFileName;
+        if ( USE_CACHE && file_exists($aCacheFileName) ) {
+            $diff=time()-filemtime($aCacheFileName);
+            if( $this->timeout>0 && ($diff > $this->timeout*60) ) {
+                return false;
+            }
+            else {
+                return true;
+            }
+        }
+        else {
+            return false;
+        }
+    }
+
+    function StreamImgFile($aImage,$aCacheFileName) {
+        $aCacheFileName = $this->cache_dir.$aCacheFileName;
+        if ( $fh = @fopen($aCacheFileName, 'rb') ) {
+            $lock = flock($fh, LOCK_SH);
+            $aImage->Headers();
+            fpassthru($fh);
+            $lock = flock($fh, LOCK_UN);
+            fclose($fh);
+            return true;
+        }
+        else {
+            JpGraphError::RaiseL(25117,$aCacheFileName);//(" Can't open cached image \"$aCacheFileName\" for reading.");
+        }
+    }
+
+    // Check if a given image is in cache and in that case
+    // pass it directly on to web browser. Return false if the
+    // image file doesn't exist or exists but is to old
+    function GetAndStream($aImage,$aCacheFileName) {
+        if( $this->Isvalid($aCacheFileName) ) {
+            $this->StreamImgFile($aImage,$aCacheFileName);
+        }
+        else {
+            return false;
+        }
+    }
+
+    //---------------
+    // PRIVATE METHODS
+    // Create all necessary directories in a path
+    function MakeDirs($aFile) {
+        $dirs = array();
+        // In order to better work when open_basedir is enabled
+        // we do not create directories in the root path
+        while ( $aFile != '/' && !(file_exists($aFile)) ) {
+            $dirs[] = $aFile.'/';
+            $aFile = dirname($aFile);
+        }
+        for ($i = sizeof($dirs)-1; $i>=0; $i--) {
+            if(! @mkdir($dirs[$i],0777) ) {
+                JpGraphError::RaiseL(25118,$aFile);//(" Can't create directory $aFile. Make sure PHP has write permission to this directory.");
+            }
+            // We also specify mode here after we have changed group.
+            // This is necessary if Apache user doesn't belong the
+            // default group and hence can't specify group permission
+            // in the previous mkdir() call
+            if( CACHE_FILE_GROUP != "" ) {
+                $res=true;
+                $res =@chgrp($dirs[$i],CACHE_FILE_GROUP);
+                $res = @chmod($dirs[$i],0777);
+                if( !$res ) {
+                    JpGraphError::RaiseL(25119,$aFile);//(" Can't set permissions for $aFile. Permission problems?");
+                }
+            }
+        }
+        return true;
+    }
+} // CLASS Cache
+
+?>
diff --git a/web/classes/jpgraph/imageSmoothArc.php b/web/classes/jpgraph/imageSmoothArc.php
new file mode 100755
index 0000000000000000000000000000000000000000..a1d581ff4d1ca57b42b439cb35841cbc105dc625
--- /dev/null
+++ b/web/classes/jpgraph/imageSmoothArc.php
@@ -0,0 +1,344 @@
+<?php
+
+/*
+    
+    Copyright (c) 2006-2008 Ulrich Mierendorff
+
+    Permission is hereby granted, free of charge, to any person obtaining a
+    copy of this software and associated documentation files (the "Software"),
+    to deal in the Software without restriction, including without limitation
+    the rights to use, copy, modify, merge, publish, distribute, sublicense,
+    and/or sell copies of the Software, and to permit persons to whom the
+    Software is furnished to do so, subject to the following conditions:
+
+    The above copyright notice and this permission notice shall be included in
+    all copies or substantial portions of the Software.
+
+    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
+    THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+    FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+    DEALINGS IN THE SOFTWARE.
+    
+    Changelog:
+    version 1.1
+        - improved the rendering speed by ~20%
+        
+        - Thanks to Matthias Mächler for fixing some small errors:
+            * uninitialized variables
+            * deprecated passing of $img reference in imageSmoothArc ()
+    
+    version 1.0
+        Release of rewritten script
+
+*/
+
+function imageSmoothArcDrawSegment (&$img, $cx, $cy, $a, $b, $aaAngleX, $aaAngleY, $color, $start, $stop, $seg)
+{
+    // Originally written from scratch by Ulrich Mierendorff, 06/2006
+    // Rewritten and improved, 04/2007, 07/2007
+    
+    // Please do not use THIS function directly. Scroll down to imageSmoothArc(...).
+    
+    $fillColor = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], $color[3] );
+    
+    $xStart = abs($a * cos($start));
+    $yStart = abs($b * sin($start));
+    $xStop  = abs($a * cos($stop));
+    $yStop  = abs($b * sin($stop));
+    $dxStart = 0;
+    $dyStart = 0;
+    $dxStop = 0;
+    $dyStop = 0;
+    if ($xStart != 0)
+        $dyStart = $yStart/$xStart;
+    if ($xStop != 0)
+        $dyStop = $yStop/$xStop;
+    if ($yStart != 0)
+        $dxStart = $xStart/$yStart;
+    if ($yStop != 0)
+        $dxStop = $xStop/$yStop;
+    if (abs($xStart) >= abs($yStart)) {
+        $aaStartX = true;
+    } else {
+        $aaStartX = false;
+    }
+    if ($xStop >= $yStop) {
+        $aaStopX = true;
+    } else {
+        $aaStopX = false;
+    }
+    //$xp = +1; $yp = -1; $xa = +1; $ya = 0;
+    for ( $x = 0; $x < $a; $x += 1 ) {
+        /*$y = $b * sqrt( 1 - ($x*$x)/($a*$a) );
+        
+        $error = $y - (int)($y);
+        $y = (int)($y);
+        
+        $diffColor = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error );*/
+        
+        $_y1 = $dyStop*$x;
+        $_y2 = $dyStart*$x;
+        if ($xStart > $xStop)
+        {
+            $error1 = $_y1 - (int)($_y1);
+            $error2 = 1 - $_y2 + (int)$_y2;
+            $_y1 = $_y1-$error1;
+            $_y2 = $_y2+$error2;
+        }
+        else
+        {
+            $error1 = 1 - $_y1 + (int)$_y1;
+            $error2 = $_y2 - (int)($_y2);
+            $_y1 = $_y1+$error1;
+            $_y2 = $_y2-$error2;
+        }
+        /*
+        if ($aaStopX)
+            $diffColor1 = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error1 );
+        if ($aaStartX)
+            $diffColor2 = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error2 );
+        */
+        
+        if ($seg == 0 || $seg == 2)
+        {
+            $i = $seg;
+            if (!($start > $i*M_PI/2 && $x > $xStart)) {
+                if ($i == 0) {
+                    $xp = +1; $yp = -1; $xa = +1; $ya = 0;
+                } else {
+                    $xp = -1; $yp = +1; $xa = 0; $ya = +1;
+                }
+                if ( $stop < ($i+1)*(M_PI/2) && $x <= $xStop ) {
+                    $diffColor1 = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error1 );
+                    $y1 = $_y1; if ($aaStopX) imageSetPixel($img, $cx+$xp*($x)+$xa, $cy+$yp*($y1+1)+$ya, $diffColor1);
+                    
+                } else {
+                    $y = $b * sqrt( 1 - ($x*$x)/($a*$a) );
+                    $error = $y - (int)($y);
+                    $y = (int)($y);
+                    $diffColor = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error );
+                    $y1 = $y; if ($x < $aaAngleX ) imageSetPixel($img, $cx+$xp*$x+$xa, $cy+$yp*($y1+1)+$ya, $diffColor);
+                }
+                if ($start > $i*M_PI/2 && $x <= $xStart) {
+                    $diffColor2 = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error2 );
+                    $y2 = $_y2; if ($aaStartX) imageSetPixel($img, $cx+$xp*$x+$xa, $cy+$yp*($y2-1)+$ya, $diffColor2);
+                } else {
+                    $y2 = 0;
+                }
+                if ($y2 <= $y1) imageLine($img, $cx+$xp*$x+$xa, $cy+$yp*$y1+$ya , $cx+$xp*$x+$xa, $cy+$yp*$y2+$ya, $fillColor);
+            }
+        }
+        
+        if ($seg == 1 || $seg == 3)
+        {
+            $i = $seg;
+            if (!($stop < ($i+1)*M_PI/2 && $x > $xStop)) {
+                if ($i == 1) {
+                    $xp = -1; $yp = -1; $xa = 0; $ya = 0;
+                } else {
+                    $xp = +1; $yp = +1; $xa = 1; $ya = 1;
+                }
+                if ( $start > $i*M_PI/2 && $x < $xStart ) {
+                    $diffColor2 = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error2 );
+                    $y1 = $_y2; if ($aaStartX) imageSetPixel($img, $cx+$xp*$x+$xa, $cy+$yp*($y1+1)+$ya, $diffColor2);
+                    
+                } else {
+                    $y = $b * sqrt( 1 - ($x*$x)/($a*$a) );
+                    $error = $y - (int)($y);
+                    $y = (int) $y;
+                    $diffColor = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error );
+                    $y1 = $y; if ($x < $aaAngleX ) imageSetPixel($img, $cx+$xp*$x+$xa, $cy+$yp*($y1+1)+$ya, $diffColor);
+                }
+                if ($stop < ($i+1)*M_PI/2 && $x <= $xStop) {
+                    $diffColor1 = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error1 );
+                    $y2 = $_y1; if ($aaStopX)  imageSetPixel($img, $cx+$xp*$x+$xa, $cy+$yp*($y2-1)+$ya, $diffColor1);
+                } else {
+                    $y2 = 0;
+                }
+                if ($y2 <= $y1) imageLine($img, $cx+$xp*$x+$xa, $cy+$yp*$y1+$ya, $cx+$xp*$x+$xa, $cy+$yp*$y2+$ya, $fillColor);
+            }
+        }
+    }
+    
+    ///YYYYY
+    
+    for ( $y = 0; $y < $b; $y += 1 ) {
+        /*$x = $a * sqrt( 1 - ($y*$y)/($b*$b) );
+        
+        $error = $x - (int)($x);
+        $x = (int)($x);
+        
+        $diffColor = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error );
+        */
+        $_x1 = $dxStop*$y;
+        $_x2 = $dxStart*$y;
+        if ($yStart > $yStop)
+        {
+            $error1 = $_x1 - (int)($_x1);
+            $error2 = 1 - $_x2 + (int)$_x2;
+            $_x1 = $_x1-$error1;
+            $_x2 = $_x2+$error2;
+        }
+        else
+        {
+            $error1 = 1 - $_x1 + (int)$_x1;
+            $error2 = $_x2 - (int)($_x2);
+            $_x1 = $_x1+$error1;
+            $_x2 = $_x2-$error2;
+        }
+/*
+        if (!$aaStopX)
+            $diffColor1 = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error1 );
+        if (!$aaStartX)
+            $diffColor2 = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error2 );
+*/
+        
+        if ($seg == 0 || $seg == 2)
+        {
+            $i = $seg;
+            if (!($start > $i*M_PI/2 && $y > $yStop)) {
+                if ($i == 0) {
+                    $xp = +1; $yp = -1; $xa = 1; $ya = 0;
+                } else {
+                    $xp = -1; $yp = +1; $xa = 0; $ya = 1;
+                }
+                if ( $stop < ($i+1)*(M_PI/2) && $y <= $yStop ) {
+                    $diffColor1 = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error1 );
+                    $x1 = $_x1; if (!$aaStopX) imageSetPixel($img, $cx+$xp*($x1-1)+$xa, $cy+$yp*($y)+$ya, $diffColor1);
+                } 
+                if ($start > $i*M_PI/2 && $y < $yStart) {
+                    $diffColor2 = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error2 );
+                    $x2 = $_x2; if (!$aaStartX) imageSetPixel($img, $cx+$xp*($x2+1)+$xa, $cy+$yp*($y)+$ya, $diffColor2);
+                } else {
+                    $x = $a * sqrt( 1 - ($y*$y)/($b*$b) );
+                    $error = $x - (int)($x);
+                    $x = (int)($x);
+                    $diffColor = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error );
+                    $x1 = $x; if ($y < $aaAngleY && $y <= $yStop ) imageSetPixel($img, $cx+$xp*($x1+1)+$xa, $cy+$yp*$y+$ya, $diffColor);
+                }
+            }
+        }
+        
+        if ($seg == 1 || $seg == 3)
+        {
+            $i = $seg;
+            if (!($stop < ($i+1)*M_PI/2 && $y > $yStart)) {
+                if ($i == 1) {
+                    $xp = -1; $yp = -1; $xa = 0; $ya = 0;
+                } else {
+                    $xp = +1; $yp = +1; $xa = 1; $ya = 1;
+                }
+                if ( $start > $i*M_PI/2 && $y < $yStart ) {
+                    $diffColor2 = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error2 );
+                    $x1 = $_x2; if (!$aaStartX) imageSetPixel($img, $cx+$xp*($x1-1)+$xa, $cy+$yp*$y+$ya,  $diffColor2);
+                } 
+                if ($stop < ($i+1)*M_PI/2 && $y <= $yStop) {
+                    $diffColor1 = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error1 );
+                    $x2 = $_x1; if (!$aaStopX)  imageSetPixel($img, $cx+$xp*($x2+1)+$xa, $cy+$yp*$y+$ya, $diffColor1);
+                } else {
+                    $x = $a * sqrt( 1 - ($y*$y)/($b*$b) );
+                    $error = $x - (int)($x);
+                    $x = (int)($x);
+                    $diffColor = imageColorExactAlpha( $img, $color[0], $color[1], $color[2], 127-(127-$color[3])*$error );
+                    $x1 = $x; if ($y < $aaAngleY  && $y < $yStart) imageSetPixel($img,$cx+$xp*($x1+1)+$xa,  $cy+$yp*$y+$ya, $diffColor);
+                }
+            }
+        }
+    }
+}
+
+
+function imageSmoothArc ( &$img, $cx, $cy, $w, $h, $color, $start, $stop)
+{
+    // Originally written from scratch by Ulrich Mierendorff, 06/2006
+    // Rewritten and improved, 04/2007, 07/2007
+    // compared to old version:
+    // + Support for transparency added
+    // + Improved quality of edges & antialiasing
+    
+    // note: This function does not represent the fastest way to draw elliptical
+    // arcs. It was written without reading any papers on that subject. Better
+    // algorithms may be twice as fast or even more.
+    
+    // what it cannot do: It does not support outlined arcs, only filled
+    
+    // Parameters:
+    // $cx      - Center of ellipse, X-coord
+    // $cy      - Center of ellipse, Y-coord
+    // $w       - Width of ellipse ($w >= 2)
+    // $h       - Height of ellipse ($h >= 2 )
+    // $color   - Color of ellipse as a four component array with RGBA
+    // $start   - Starting angle of the arc, no limited range!
+    // $stop    - Stop     angle of the arc, no limited range!
+    // $start _can_ be greater than $stop!
+    // If any value is not in the given range, results are undefined!
+    
+    // This script does not use any special algorithms, everything is completely
+    // written from scratch; see http://de.wikipedia.org/wiki/Ellipse for formulas.
+    
+    while ($start < 0)
+        $start += 2*M_PI;
+    while ($stop < 0)
+        $stop += 2*M_PI;
+    
+    while ($start > 2*M_PI)
+        $start -= 2*M_PI;
+    
+    while ($stop > 2*M_PI)
+        $stop -= 2*M_PI;
+    
+    
+    if ($start > $stop)
+    {
+        imageSmoothArc ( $img, $cx, $cy, $w, $h, $color, $start, 2*M_PI);
+        imageSmoothArc ( $img, $cx, $cy, $w, $h, $color, 0, $stop);
+        return;
+    }
+    
+    $a = 1.0*round ($w/2);
+    $b = 1.0*round ($h/2);
+    $cx = 1.0*round ($cx);
+    $cy = 1.0*round ($cy);
+    
+    $aaAngle = atan(($b*$b)/($a*$a)*tan(0.25*M_PI));
+    $aaAngleX = $a*cos($aaAngle);
+    $aaAngleY = $b*sin($aaAngle);
+    
+    $a -= 0.5; // looks better...
+    $b -= 0.5;
+    
+    for ($i=0; $i<4;$i++)
+    {
+        if ($start < ($i+1)*M_PI/2)
+        {
+            if ($start > $i*M_PI/2)
+            {
+                if ($stop > ($i+1)*M_PI/2)
+                {
+                    imageSmoothArcDrawSegment($img, $cx, $cy, $a, $b, $aaAngleX, $aaAngleY , $color, $start, ($i+1)*M_PI/2, $i);
+                }
+                else
+                {
+                    imageSmoothArcDrawSegment($img, $cx, $cy, $a, $b, $aaAngleX, $aaAngleY, $color, $start, $stop, $i);
+                    break;
+                }
+            }
+            else
+            {
+                if ($stop > ($i+1)*M_PI/2)
+                {
+                    imageSmoothArcDrawSegment($img, $cx, $cy, $a, $b, $aaAngleX, $aaAngleY, $color, $i*M_PI/2, ($i+1)*M_PI/2, $i);
+                }
+                else
+                {
+                    imageSmoothArcDrawSegment($img, $cx, $cy, $a, $b, $aaAngleX, $aaAngleY, $color, $i*M_PI/2, $stop, $i);
+                    break;
+                }
+            }
+        }
+    }
+}
+?>
diff --git a/web/classes/jpgraph/imgdata_balls.inc.php b/web/classes/jpgraph/imgdata_balls.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..ee5db492720d1f57066980ce2ca8279399358b4c
--- /dev/null
+++ b/web/classes/jpgraph/imgdata_balls.inc.php
@@ -0,0 +1,1061 @@
+<?php
+//=======================================================================
+// File:        IMGDATA_ROUNDBALLS.INC
+// Description: Base64 encoded images for small round markers
+// Created:     2003-03-20
+// Ver:         $Id: imgdata_balls.inc.php 1106 2009-02-22 20:16:35Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+class ImgData_Balls extends ImgData {
+    protected $name = 'Round Balls';
+    protected $an = array(MARK_IMG_LBALL => 'imgdata_large',
+    MARK_IMG_MBALL => 'imgdata_small',
+    MARK_IMG_SBALL => 'imgdata_xsmall',
+    MARK_IMG_BALL => 'imgdata_xsmall');
+    protected $colors,$index,$maxidx;
+    private $colors_1 = array('blue','lightblue','brown','darkgreen',
+         'green','purple','red','gray','yellow','silver','gray');
+    private $index_1  = array('blue'=>9,'lightblue'=>1,'brown'=>6,'darkgreen'=>7,
+         'green'=>8,'purple'=>4,'red'=>0,'gray'=>5,'silver'=>3,'yellow'=>2);
+    private $maxidx_1 = 9 ;
+
+    private $colors_2 = array('blue','bluegreen','brown','cyan',
+     'darkgray','greengray','gray','green',
+     'greenblue','lightblue','lightred',
+     'purple','red','white','yellow');
+     
+
+    private $index_2 =  array('blue'=>9,'bluegreen'=>13,'brown'=>8,'cyan'=>12,
+     'darkgray'=>5,'greengray'=>6,'gray'=>2,'green'=>10,
+     'greenblue'=>3,'lightblue'=>1,'lightred'=>14,
+     'purple'=>7,'red'=>0,'white'=>11,'yellow'=>4);
+     
+    private $maxidx_2 = 14 ;
+
+
+    private $colors_3 = array('bluegreen','cyan','darkgray','greengray',
+     'gray','graypurple','green','greenblue','lightblue',
+     'lightred','navy','orange','purple','red','yellow');
+
+    private $index_3 = array('bluegreen'=>1,'cyan'=>11,'darkgray'=>14,'greengray'=>10,
+    'gray'=>3,'graypurple'=>4,'green'=>9,'greenblue'=>7,
+    'lightblue'=>13,'lightred'=>0,'navy'=>2,'orange'=>12,
+    'purple'=>8,'red'=>5,'yellow'=>6);
+    private $maxidx_3 = 14 ;
+
+    protected $imgdata_large, $imgdata_small, $imgdata_xsmall ;
+
+
+    function GetImg($aMark,$aIdx) {
+        switch( $aMark ) {
+            case MARK_IMG_SBALL:
+            case MARK_IMG_BALL:
+                $this->colors = $this->colors_3;
+                $this->index = $this->index_3 ;
+                $this->maxidx = $this->maxidx_3 ;
+                break;
+            case MARK_IMG_MBALL:
+                $this->colors = $this->colors_2;
+                $this->index = $this->index_2 ;
+                $this->maxidx = $this->maxidx_2 ;
+                break;
+            default:
+                $this->colors = $this->colors_1;
+                $this->index = $this->index_1 ;
+                $this->maxidx = $this->maxidx_1 ;
+                break;
+        }
+        return parent::GetImg($aMark,$aIdx);
+    }
+
+    function __construct() {
+
+        //==========================================================
+        // File: bl_red.png
+        //==========================================================
+        $this->imgdata_large[0][0]= 1072 ;
+        $this->imgdata_large[0][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAMAAACelLz8AAAByF'.
+     'BMVEX/////////xsb/vb3/lIz/hIT/e3v/c3P/c2v/a2v/Y2P/'.
+     'UlL/Skr/SkL/Qjn/MTH/MSn/KSn/ISH/IRj/GBj/GBD/EBD/EA'.
+     'j/CAj/CAD/AAD3QkL3MTH3KSn3KSH3GBj3EBD3CAj3AAD1zMzv'.
+     'QkLvISHvIRjvGBjvEBDvEAjvAADnUlLnSkrnMTnnKSnnIRjnGB'.
+     'DnEBDnCAjnAADec3PeSkreISHeGBjeGBDeEAjWhITWa2vWUlLW'.
+     'SkrWISnWGBjWEBDWEAjWCAjWAADOnp7Oa2vOGCHOGBjOGBDOEB'.
+     'DOCAjOAADJrq7Gt7fGGBjGEBDGCAjGAADEpKS/v7+9QkK9GBC9'.
+     'EBC9CAi9AAC1e3u1a2u1Skq1KSm1EBC1CAi1AACtEBCtCBCtCA'.
+     'itAACngYGlCAilAACghIScOTmcCAicAACYgYGUGAiUCAiUAAiU'.
+     'AACMKSmMEACMAACEa2uEGAiEAAB7GBh7CAB7AABzOTlzGBBzCA'.
+     'BzAABrSkprOTlrGBhrAABjOTljAABaQkJaOTlaCABaAABSKSlS'.
+     'GBhSAABKKSlKGBhKAABCGBhCCABCAAA5CAA5AAAxCAAxAAApCA'.
+     'ApAAAhAAAYAACc9eRyAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgF'.
+     'HUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAwkRFD'.
+     'UHLytKAAAB4UlEQVR4nGNgIAK4mGjrmNq6BmFIWMmISUpKSmk5'.
+     'B8ZEokj4qoiLiQCBgqald3xaBpKMj6y4sLCQkJCIvIaFV0RaUR'.
+     'lCSk5cWEiAn19ASN7QwisuraihHiajKyEixM/NwckjoKrvEACU'.
+     'qumpg7pAUlREiJdNmZmLT9/cMzwps7Smc3I2WEpGUkxYkJuFiY'.
+     'lTxszePzY1v7Shc2oX2D+K4iLCgjzsrOw8embuYUmZeTVtPVOn'.
+     'gqSslYAOF+Ln4ZHWtXMPTcjMrWno7J82rRgoZWOsqaCgrqaqqm'.
+     'fn5peQmlsK1DR52vRaoFSIs5GRoYG5ub27n19CYm5pdVPnxKnT'.
+     'pjWDpLydnZwcHTz8QxMSEnJLgDL9U6dNnQ6Sio4PDAgICA+PTU'.
+     'zNzSkph8hADIxKS46Pj0tKTc3MLSksqWrtmQySAjuDIT8rKy0r'.
+     'Kz+vtLSmur6jb9JUIJgGdjxDQUVRUVFpaUVNQ1NrZ9+kKVOmTZ'.
+     'k6vR0sldJUAwQNTU2dnX0TgOJTQLrSIYFY2dPW1NbW2TNxwtQp'.
+     'U6ZMmjJt2rRGWNB3TO7vnzh5MsgSoB6gy7sREdY7bRrQEDAGOb'.
+     'wXOQW0TJsOEpwClmxBTTbZ7UDVIPkp7dkYaYqhuLa5trYYUxwL'.
+     'AADzm6uekAAcXAAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        // File: bl_bluegreen.png
+        //==========================================================
+        $this->imgdata_large[1][0]= 1368 ;
+        $this->imgdata_large[1][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAYAAACpSkzOAAAABm'.
+     'JLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsRAAALEQF/ZF+RAAAA'.
+     'B3RJTUUH0wMMFi8hE9b2uAAABOVJREFUeNq9lk2sJFUVx3+3qv'.
+     'tW95t57zFvhiFxmCFRUJRoNCQiJARMhiFx/Igxii5goTG6ZDAu'.
+     '/EhcSCIrTAgLEiKsJ8ywABNZEMJXEDYCukAmjgjzBkK/j35V1d'.
+     '333FtV97io97pfzwxfG86qcu/N+Z3zP+fcW/Apmfk4hx57+R/6'.
+     'Rqmc9ykhsWjlsUngAA1fXIQ7b73pI/186IGHnn9dH/8frC8v4I'.
+     'PiG53uaerR4GmKkv31mB8cyfjd946ZTwR66qVX9OTWIi8UKUv9'.
+     'BOrZXpYZvFeiBvzI0fgSUSFKwbVG+Pl1V3HH0VvNR4KeeukV/f'.
+     'PmMmdHhst76aXD64AbeVQ9bjNHaiGOC2o3wLrAb2/4LL/84ffn'.
+     'fCdzkOdayKpLppBemrBsU5Y1Zdmm9LJdGU6E/t4M24Q26jRDRL'.
+     'j3mdc49cSTekFsMzs5XuTsyLDUNSDQ25NwKOly9YIl22MYhJr/'.
+     'uoDtBBoT0CxBRGYOAhibIaOCe//2MpfM6KHnX9cXipSlbkKWmS'.
+     'nk9iv38J0jixw7vJfrTMYBOvhSoQHJBS09ANELloAGDxW8tfoW'.
+     'J+5/UC8CPS0LU7r3SpYarr7M8rmFjMPLXT6/33L4si7Z2GCrQC'.
+     '+0ctlOaNs9DReV8vSLr85ndPLpZ/WNvHW+01kAVFBOGvJx0wYg'.
+     'Sp47RIQ4Emwa8FGJXlDxSCFo5YlVgAo2hwPue/hRndboTV3EW2'.
+     'Wp3k6wBp8q56QiWzecW6vwQfnPRkAWhFgILnq08jQ+R2nlUzzN'.
+     'uES9Q7Vd+9fba7NmWJW61db2247qACmcjxXr45psYphsFGSLBu'.
+     'kIajxqtjNwHkvAjQt0sg3crhPA2+fPz0CuyNFOghsGsr19mnFg'.
+     'DGwrRm8UoAtNmQPQtRXDgdC4HImCFEKcCE0oieUWUYq2LtbiGp'.
+     'mBQmppfIkjw45DK0QNNkvQ0jMBtPL0UnDRM1rN+cxKwzvOo2NP'.
+     'tykR9a1kfpZNDLMG6QDYJqCTBvUe1+uxs+YKyPoGrTwY2HhvC4'.
+     'CDWQd5d4xNApNQEEMgjgLdUCLBQ5cprL/trwNwKG2IUmDqDFd5'.
+     'sr5BWrlxuSdLDFEFlqAzXGc4zFjupqh6uqYihpxJcEgp026l2w'.
+     '7wFUv7Z6AvrfRo/n0OYzPwIKE3HUKAJg2otMBiElnsF7wngis9'.
+     '3ZDjNnLi7huCWUZfueZKTu/M0V3HvmkOFDVxVKDG04ScejSgW5'.
+     'V0q5JYFEghuDLHlTmToqDeGOCKIVtrW9hsdmXufEcNLPSXuPHa'.
+     'a+bvuh9df5AH/v5PDFmbWQC3Mx+TVvfGVTRB2CodNgT2JBX003'.
+     'aANZAYS/BxCv32TV/l2C03G7jgmfjGiT/qmeEmibEYm7XzAO2k'.
+     'A+pbgHhBgydqu54YO5eRiLCy7yDvPP6Xqf+5Z+Lu277OYuOpiw'.
+     'H15oBmlNOMcmK5RbP+PrEscGU+DSAxdg4CICIkxnLP8aNz63Og'.
+     'H3/rdvOb795GVhuaYo0oBc3GGrEsUPVTwO6a7LYd+X51x3Hu/t'.
+     'lP5tS65FN+6okn9U+n/sqb596dTvhOF+02myXTmkQNrOw7yD3H'.
+     'j14E+UDQjp24/0E9/eKrbA4HH3aMK1b2ccvXvswjv//1J/s5ud'.
+     'Due/hRPfP+OmfOrk7vrn7a48ihA3zh8CH+8Iuffiw/n4r9H1ZZ'.
+     '0zz7G56hAAAAAElFTkSuQmCC' ; 
+
+        //==========================================================
+        // File: bl_yellow.png
+        //==========================================================
+        $this->imgdata_large[2][0]= 1101 ;
+        $this->imgdata_large[2][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAMAAACelLz8AAAB2l'.
+     'BMVEX//////////+///+f//9b//8b//73//7X//63//6X//5T/'.
+     '/4z//4T//3P//2v//1r//0r//0L//zH//yn//yH//xj//xD//w'.
+     'j//wD/90L/9zn/9zH/9xj/9xD/9wj/9wD39yn37zn37zH37yH3'.
+     '7xD37wj37wDv70Lv50rv50Lv5znv5yHv5xjv5wjv5wDn51Ln5x'.
+     'Dn3jHn3iHn3hjn3hDn3gje3oze3nPe3lLe1oze1nPe1lLe1ine'.
+     '1iHe1hje1hDe1gje1gDW1qXW1mvWzqXWzkLWzhjWzhDWzgjWzg'.
+     'DOzrXOzq3OzpzOzgDOxkrOxinOxhjOxhDOxgjOxgDGxqXGxnvG'.
+     'xmvGvRjGvRDGvQjGvQDFxbnAvr6/v7+9vaW9vZS9vQi9vQC9tR'.
+     'C9tQi9tQC7u7W1tZS1tXu1tTG1tQi1rRC1rQi1rQCtrYytrSGt'.
+     'rQitrQCtpYStpSGtpQitpQClpYSlpXulpQClnBClnAilnACcnG'.
+     'ucnAicnACclAiclACUlFqUlCmUlAiUlACUjFKUjAiUjACMjFKM'.
+     'jEqMjACMhACEhACEewB7ezF7exB7ewB7cwBzcylzcwBzaxBzaw'.
+     'BraxhrawhrawBrYxBrYwBjYwBjWgBaWgBaUgCXBwRMAAAAAXRS'.
+     'TlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAd'.
+     'LdfvwAAAAHdElNRQfTAwkRFBKiJZ4hAAAB7ElEQVR4nI3S+1vS'.
+     'UBgHcB67WJmIMWAVdDHEDLBC6Go0slj3Ft0m9RRBWQEmFZFDEM'.
+     'Qgt0EMFBY7p/+198hj1kM/9N1+++x73rOd6XT/kStnTx4fPzd9'.
+     'uwfOjFhomj7smAhwj/6Cm2O0xUwy6g7cCL99uCW3jtBmE7lsdr'.
+     'fvejgpzP7uEDFRRoqy2k8xQPnypo2BUMP6waF9Vpf3ciiSzErL'.
+     'XTkPc0zDe3bsHDAcc00yoVgqL3UWN2iENpspff+2vn6D0+NnZ9'.
+     '6lC5K6RuSqBTZn1O/a3rd7v/MSez+WyIpVFX8GuuCA9SjD4N6B'.
+     'oRNTfo5PCAVR0fBXoIuOQzab1XjwwNHx00GOj8/nKtV1DdeArk'.
+     '24R+0ul9PjmbrHPYl+EipyU0OoQSjg8/m83kl/MMhx0fjCkqio'.
+     'SMOE7t4JMAzDsizH81AqSdW2hroLPg4/CEF4PhKNx98vlevrbY'.
+     'QQXgV6kXwVfjkTiSXmhYVcSa7DIE1DOENe7GM6lUym0l+EXKks'.
+     'K20VAeH2M0JvVgrZfL5Qqkiy0lRVaMBd7H7EZUmsiJJcrTdVja'.
+     'wGpdbTLj3/3qwrUOjAfGgg4LnNA5tdQx14Hm00QFBm65hfNzAm'.
+     '+yIFhFtzuj+z2MI/MQn6Uez5pz4Ua41G7VumB/6RX4zMr1TKBr'.
+     'SXAAAAAElFTkSuQmCC' ; 
+
+        //==========================================================
+        // File: bl_silver.png
+        //==========================================================
+        $this->imgdata_large[3][0]= 1481 ;
+        $this->imgdata_large[3][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAMAAAAM7l6QAAADAF'.
+     'BMVEUAAADOzs7Gxsa9vb21tbXOxsbOzsbGzsb3///O1ta1vb2c'.
+     'paVSWlpKWlpSY2ve5+97hIze7/9aY2vO5/9zhJRaa3tSY3PGzt'.
+     'aMlJxrc3tja3NKUlpCSlK1vcZze4RSWmPW5/+Upb3G3v9zhJxS'.
+     'Y3t7jKVaa4TO3veltc6ElK1re5Rjc4ycpbV7hJRaY3M5QlLn7/'.
+     '/Gzt6lrb2EjJzO3v9ja3vG1ve9zu+1xueltdacrc6UpcaMnL1C'.
+     'SlqElLV7jK1zhKVre5zW3u/O1ue1vc6ttcaMlKVze4xrc4RSWm'.
+     'tKUmPG1v+9zve1xu+tveeltd6crdbe5/+9xt6cpb17hJxaY3s5'.
+     'QlrW3vfO1u/Gzue1vdattc6lrcaUnLWMlK2EjKVze5Rrc4xja4'.
+     'RSWnNKUmtCSmO9xuecpcZ7hKVaY4TW3v/O1vfGzu+1vd6ttdal'.
+     'rc69xu+UnL2MlLWEjK1ze5xrc5R7hK1ja4zO1v+1veettd6lrd'.
+     'aMlL3Gzv/39//W1t7Gxs61tb29vcatrbWlpa2cnKWUlJyEhIx7'.
+     'e4TW1ufGxta1tcZSUlqcnK3W1u+UlKW9vda1tc57e4ytrcalpb'.
+     '1ra3vOzu9jY3OUlK29vd6MjKWEhJxaWmtSUmNzc4xKSlpjY3tK'.
+     'SmNCQlqUjJzOxs7///8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'.
+     'AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'.
+     'AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'.
+     'AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'.
+     'AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'.
+     'AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'.
+     'AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'.
+     'AAAAAAAAAAAAAAAAAAAAAAAAD///9fnkWVAAAAAnRSTlP/AOW3'.
+     'MEoAAAABYktHRP+lB/LFAAAACXBIWXMAAABFAAAARQBP+QatAA'.
+     'AB/klEQVR42mNgxAsYqCdd3+lcb4hLmj8wMMvEu8DCMqYbU9op'.
+     'UEFB2MTb26eyysomFl06XEEhUCHLpAKo2z/fujikEUVaXUFBMB'.
+     'BouLePuV+VVWGRciIXknSEsImCQd3//xwmPr65llaFcSFJHkjS'.
+     '3iYmWUDZ//8NfCr989NjNUMSUyTg0jneSiaCINn/gmlVQM12qg'.
+     'lJnp5waTMTE5NAkCyHWZW/lXWNfUlikmdYK0zax7siS4EDKJtd'.
+     'mQeU1XRwLBdLkRGASucWmGVnZ4dnhZvn5lmm29iVOWpnJqcuko'.
+     'JKR1Wm5eTkRKYF5eblp9sU2ZeUJiV7zbfVg0pH56UFBQXNjIqK'.
+     'jgkujItX1koKTVmYajsdKu2qETVhwgSXiUDZ2Bn9xqUeoZ5e0t'.
+     'LzYYZ3B092ndjtOnmKTmycW1s7SHa+l5dtB8zlccE6RlN0dGbM'.
+     'mDVbd5KupNBcL6+F82XgHouLj5vRP2PWLGNdd4+ppnxe8tJec6'.
+     'XnNsKkm0uVQ5RDRHQTPTym68nPlZbvkfYCexsa5rpJ2qXa5Umm'.
+     'ocmec3m8vHjmSs+fgxyhC5JDQ8WSPT2lvbzm8vDIe0nbtiBLN8'.
+     '8BigNdu1B6Lsje+fPbUFMLi5TMfGmvHi/puUAv23q2YCTFNqH5'.
+     'MvPnSwPh3HasCbm3XUpv+nS5VtrkEkwAANSTpGHdye9PAAAASn'.
+     'RFWHRzaWduYXR1cmUANGJkODkyYmE4MWZhNTk4MTIyNDJjNjUx'.
+     'NzZhY2UxMDAzOGFhZjdhZWIyNzliNTM2ZGFmZDlkM2RiNDU3Zm'.
+     'NlNT9CliMAAAAASUVORK5CYII=' ; 
+
+        //==========================================================
+        // File: bl_purple.png
+        //==========================================================
+        $this->imgdata_large[4][0]= 1149 ;
+        $this->imgdata_large[4][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAMAAACelLz8AAACAV'.
+     'BMVEX/////////7///5///1v//xv//rf//pf//lP//jP//hP//'.
+     'c///a///Wv//Wvf/Uv//Sv//Qv//Qvf/Off/Mf//Kf//If//If'.
+     'f/GP//GPf/EP//EPf/CP//CPf/CO//AP//APf3Oe/3Kff3Ke/3'.
+     'Ie/3GO/3EO/3AO/vSu/vSufvOefvMefvIefvGOfvEOfvCOfvAO'.
+     'fnUufnSufnMd7nId7nGN7nGNbnEN7nCN7nAN7ejN7ejNbec97e'.
+     'c9beUtbeQtbeIdbeGNbeENbeCNbeANbWpdbWa9bWQs7WGM7WEM'.
+     '7WCM7WAM7Otc7Orc7OnM7OSsbOIb3OGMbOEMbOCMbOAM7OAMbG'.
+     'pcbGnMbGe8bGa8bGKbXGEL3GCL3GAL3FucXBu73AvsC/v7+9pb'.
+     '29Ka29GLW9ELW9CLW9AL29ALW5rrm1lLW1e7W1MbW1GKW1EK21'.
+     'CLW1CK21AK2tjK2thKWtMaWtIaWtGJytCK2tCKWtAK2tAKWlhK'.
+     'Wle6WlEJylCJylAKWlAJyca5ycGJScEJScCJScAJycAJSUWpSU'.
+     'UoyUKZSUEIyUCIyUAJSUAIyMUoyMSoyMIYSMEISMCISMAIyMAI'.
+     'SECHuEAISEAHt7MXt7EHt7CHt7AHt7AHNzKXNzEGtzAHNzAGtr'.
+     'GGtrEGNrCGtrAGtrAGNjCFpjAGNjAFpaAFpaAFIpZn4bAAAAAX'.
+     'RSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsS'.
+     'AdLdfvwAAAAHdElNRQfTAwkRFB0ymoOwAAAB9UlEQVR4nGNgIA'.
+     'K42hhqGtm5+WFIWClKycvLK6gbuARGoEj4aMjLSElISUir6Tt7'.
+     'x+aEIWR8leQlwEBSTc/CK7awLguuR0lGQkJMVFRUTFJVzwko1d'.
+     'oFk9OQl5IQE+Dh5hVR0TV3CkkvbJgyASJjDZIR5GBl5eRX0TH1'.
+     'DEqrbJ2ypBEspSgvJSXKw8bMxMavbOLoGZNf1TZlybw4oIyfLN'.
+     'BxotxsLEzsQiaOHkFpBQ2905esrAZK2SpIAaUEuDm5+LTNPAKj'.
+     'C+pbps1evrIDKGWnLictKSkuLKyoZQyUya9o7Z2+YMXKGUApew'.
+     'M9PTVdXR0TEwf3wOjUirruafOXL18xFyjl72Kpb25qaurg4REU'.
+     'EFVe2zJ5zpLlK1aCpbydnZ2dnDwDA6NTopLLeiZNXbB8BcTAyP'.
+     'TQ0JDg4KCY1NS83JKmiVOBepYvX9UPlAovzEiPSU/LLyior2vq'.
+     'mjZr3vLlIF01IC+XVhUWFlZW1Lc290ycOGfxohVATSsXx4Oksn'.
+     'vaWlsb2tq6J0+bM2/RohVA81asbIcEYueU3t7JU6ZNnwNyGkhm'.
+     '+cp5CRCppJnzZ8+ZM3/JUogECBbBIixr8Yqly8FCy8F6ltUgoj'.
+     'lz7sqVK2ByK+cVMSCDxoUrwWDVysXt8WhJKqG4Y8bcuTP6qrGk'.
+     'QwwAABiMu7T4HMi4AAAAAElFTkSuQmCC' ; 
+
+        //==========================================================
+        // File: bl_gray.png
+        //==========================================================
+        $this->imgdata_large[5][0]= 905 ;
+        $this->imgdata_large[5][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAMAAACelLz8AAABO1'.
+     'BMVEX////////3///39/fv7+/e5+fW3t7Wzs7WxsbG1tbGzsbG'.
+     'xsbDxMS/v7++wMC+v7+9zsa9xsa9vb29tbW9ra29pa24uLi1xs'.
+     'a1vb21tbWxtrattbWmpqalra2cra2cpaWcnJycjIyUpaWUnJyU'.
+     'lJSUjIyMnJyMnJSMlJSMlIyMjJSMjIyElJSElIyEjIyEhIR7jI'.
+     'x7hIR7hHt7e3t7e3N7e2tzhIRze3tze3Nzc3Nre3trc3Nrc2tr'.
+     'a2tjc3Njc2tja3Nja2tjY2NjWlpaa2taY2taY2NaY1paWlpaUl'.
+     'JSY2NSY1pSWlpSWlJSUlJSUkpKWlpKWlJKUlpKUlJKUkpKSkpK'.
+     'SkJCUlJCUkJCSkpCSkJCQkI5Sko5QkI5Qjk5OUI5OTkxQkIxOT'.
+     'kxMTkxMTEpMTEhMTEhKSkYISEpy7AFAAAAAXRSTlMAQObYZgAA'.
+     'AAFiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdE'.
+     'lNRQfTAwkRFQfW40uLAAABx0lEQVR4nI3SbXfSMBQA4NV3nce5'.
+     'TecAHUywRMHSgFuBCFsQUqwBS1OsWQh0GTj//y8wZUzdwQ/efM'.
+     'tzcm/uuXdj4z9ic/PR9k4qk1qDnf0X2/uZzKt8GaRvSubg4LVp'.
+     'mkWzCGAT/i3Zsm2XNQHLsm2n2937LaaNnGoJFAEo27B50qN0ay'.
+     'Wg26lXsw8fP8nmzcJb2CbsnF5JmmCE8ncN404KvLfsYwd7/MdV'.
+     'Pdgl/VbKMIzbuwVgVZw2JlSKJTVJ3609vWUY957lgAUd1KNcqr'.
+     'yWnOcOPn8q7d5/8PywAqsOOiVDrn42NFk+HQ7dVuXNYeFdBTpN'.
+     'nY5JdZl8xI5Y+HXYaTVqEDp1hAnRohZM03EUjMdhn5wghOoNnD'.
+     'wSK7KiiDPqEtz+iD4ctdyAifNYzUnScBSxwPd6GLfRURW7Ay5i'.
+     'pS5bmrY8348C5vvUI+TLiIVSJrVA0heK/GDkJxYMRoyfCSmk4s'.
+     'uWc3yic/oBo4yF374LGQs5Xw0GyQljI8bYmEsxVUoKxa6HMpAT'.
+     'vgyhU2mR8uU1pXmsa8ezqb6U4mwWF/5MeY8uLtQ0nmmQ8UWYvb'.
+     'EcJaYWar7QhztrO5Wr4Q4hDbAG/4hfTAF2iCiWrCEAAAAASUVO'.
+     'RK5CYII=' ; 
+
+        //==========================================================
+        // File: bl_brown.png
+        //==========================================================
+        $this->imgdata_large[6][0]= 1053 ;
+        $this->imgdata_large[6][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABkAAAAZCAMAAADzN3VRAAABoV'.
+     'BMVEX////Gzs7GvbXGrZTGpXu9nHO1nHO1nIy9taXGxs7GtaXO'.
+     'nHPGlFrGjEq9hEq1hEqte0Klczmcazmce1KtnIzGxsbGvb3OlF'.
+     'LOlFq9hFKte0qcc0KUYzGEWimMc1K9ta3OnGvOnGPWnGO9jFq9'.
+     'jFKlc0KUazmMYzl7UilzUjGtpZzGxr3GnGPWpWvepXO1hFJ7Wj'.
+     'FrSiFjUjG1ra3GnHPvxpT/5733zpythFKUa0KEYzlzUilaOSF7'.
+     'Wjm9jErvvYz/99b///f/78bnrYS1hFqle0p7UjFrSiljQiFCMR'.
+     'iMhHO9lGvGjFLWnGv/3q3////erXuthEqlc0paQiFKMRhSQin/'.
+     '1qX/997//++cc0pjSilaQilKORhCKRiclIy9pYzGlGPntYT33q'.
+     '3vvZSEWjlSOSE5KRB7c2O1lHutczmthFqte1JrWkqtjGtCKRBa'.
+     'SjmljGuca0KMYzGMaznOztaclISUYzmEWjFKOSF7a1qEYzFaSi'.
+     'GUjISEa0pKOSm9vb2llIxaQhg5IQiEc2tzY0paORilnJy1raVS'.
+     'OSljUkJjWkKTpvQWAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHU'.
+     'gAAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAwkREiei'.
+     'zP2EAAAB9UlEQVR4nGWS/VfSUBjHL5QluhhBxtwyWcCus5Blpm'.
+     'wDC4ONaWXCyBi7RMZmpQ2Bypm9W/byV3cHHo/W88s95/s5z/d5'.
+     'uwCcCh/4L3zAf+bs0NC588On9QAYGSUuBINk6GI4cmnsBLk8Go'.
+     '1SFEGMkzRzZeLq5JE8FvDHouw1lqXiCZJOcnCKnx4AcP0GBqmZ'.
+     'mRgRT9MMB4Wbs7cGSXNRik3dnp9fiMUzNCNKgpzN9bsaWaQo9s'.
+     '7dfH7pXiFTZCBU1JK27LmtBO8TDx7mV1eXHqXXyiIUFLWiVzHx'.
+     'BxcJIvV4/cn6wkqmWOOwmVE3UQOAp6HxRKL5bGPj+VwhUhalFq'.
+     '8alm5vAt+LlySZTsebzcKrraIIW4JqZC3N3ga+1+EQTZKZta1M'.
+     'pCZCSeDViqVrThsEdsLJZLJYLpZrHVGScrKBvTQNtQHY6XIM02'.
+     'E6Ik7odRW1Dzy3N28n3kGuB3tQagm7UMBFXI/sATAs7L5vdbEs'.
+     '8Lycm923NB0j5wMe6KOsKIIyxcuqauxbrmlqyEWfPmPy5assY1'.
+     'U1SvWKZWom9nK/HfQ3+v2HYZSMStayTNN0PYKqg11P1nWsWq7u'.
+     '4gJeY8g9PLrddNXRdW8Iryv86I3ja/9s26gvukhDdvUQnIjlKr'.
+     'IdZCNH+3Xw779qbG63f//ZOzb6C4+ofdbzERrSAAAAAElFTkSu'.
+     'QmCC' ; 
+
+        //==========================================================
+        // File: bl_darkgreen.png
+        //==========================================================
+        $this->imgdata_large[7][0]= 1113 ;
+        $this->imgdata_large[7][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAMAAACelLz8AAAB2l'.
+     'BMVEX////////3///v///n/+/e99bW/+/W99bO786/v7++vr69'.
+     '/96999a7wb24vbu1/9a1zqW1u7itxrWosq6l772l1qWlxrWlxq'.
+     '2lva2cxpSU562U3q2UxqWUvaWUpZyM77WM57WMvYyMtZyMrZyM'.
+     'pZSMnJSEvZyEtYyErZSElIx7zpR7xpx7xpR7vZR7jIRz1pRzxp'.
+     'RzjIRrzpRrzoxrxoxrtYRrrYxrrXtrpYRrhHNjzoxjxoxjxoRj'.
+     'vYRjtYRjrXtjpXtjlGNje2tazoxazoRaxoxaxoRavYRatYRatX'.
+     'tarXtapXNanHNajFpae2tSzoRSxoRSvXtStXtSrXtSrXNSpXNS'.
+     'nHNSnGtSlGtSlGNSjGtSjGNKvXtKtXNKrXNKpWtKnGtKlGNKjG'.
+     'NKhGNKhFJKc1pKa1JCrWtCpWtCnGtClGNCjGNCjFpChFpCe1JC'.
+     'a1JCY1I5pWs5nGM5lGM5jFo5hFo5e1o5c0o5WkoxjFoxhFoxhF'.
+     'Ixe1Ixc1Ixc0oxa0ophFIpe0opc0opa0opa0IpY0IpWkIpWjkp'.
+     'UkIpUjkhc0oha0IhY0IhWjkhWjEhUjkhUjEhSjEhSikhQjEhQi'.
+     'kYWjkYSjEYSikYQjEYQikQSikQQikQQiEQOSExf8saAAAAAXRS'.
+     'TlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAd'.
+     'LdfvwAAAAHdElNRQfTAwkRFCaDkWqUAAAB+ElEQVR4nI3S+1vS'.
+     'UBgHcGZlPV0ks/vFrmQWFimJjiwiYUJWjFBWFhClyZCy5hLrwA'.
+     'x2EIwJC1w7zf2vnU0re+iHvs9++7x7zznvORbLf+TA6ct9fYMX'.
+     'jrfAUYefpp+/iM1ykxf/lmuhUZ/PTwXC8dml5Wcd23o5H5Mk6b'.
+     '5NUU8icXbhS67rNzn9JDnguOEYGQtEEtwC+Crs3RJ76P5A/znr'.
+     'vsNX7wQnEiwHCtK7TTkW8rvdZ9uJtvZTLkxpHhSrP66bNEj7/P'.
+     '3WNoLYeeSWQQCIpe9lQw7RNEU5rDsIYtcJ14Nocg7kRUlBNkxn'.
+     'YmGKcp7cv3vPwR7XOJPmc0VYU3Sv0e9NOBAYG7Hbz/cMjTMveZ'.
+     'CHkqxuTBv0PhYJB4N3XR6PJ5rMAPMnpGUxDX1IxSeMTEaZp1OZ'.
+     'nGAIQiYtsalUIhFlmGTy3sO3AizJCKn6DKYryxzHsWyaneMzr6'.
+     'cWxRVZVlFTe4SpE3zm+U/4+whyiwJcWVMQNr3XONirVWAklxcE'.
+     'EdbqchPhjhVzGpeqhUKhWBQhLElr9fo3pDaQPrw5xOl1CGG1JE'.
+     'k1uYEBIVkrb02+o6RItfq6rBhbw/tuINT96766KhuqYpY3UFPF'.
+     'BbY/19yZ1XF1U0UNBa9T7rZsz80K0jWk6bpWGW55UzbvTHZ+3t'.
+     'vbAv/IT+K1uCmhIrKJAAAAAElFTkSuQmCC' ; 
+
+        //==========================================================
+        // File: bl_green.png
+        //==========================================================
+        $this->imgdata_large[8][0]= 1484 ;
+        $this->imgdata_large[8][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAYAAACpSkzOAAAABm'.
+     'JLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsRAAALEQF/ZF+RAAAA'.
+     'B3RJTUUH0wMMFjM4kcoDJQAABVlJREFUeNq9ll2MJFUVx3/11V'.
+     'Vd/TE9vU0v4zLDwJIF16jBqLAPhsRXEiDqg0QTJiQSjcSNvCzw'.
+     'sBEDDxizhvAAxBgf1oR9QF9NiE9ESFZkQyZB5WtddmdnZ3qqqr'.
+     'uqbt367Cofqu3ZZpWVaDzJfbkf53//55z/PVdZXV3l/2H6f7Lp'.
+     '5VdOV/4Nb+GmHpUeA7AdBNxc3kafNb73jRPK9Xwon8ToxVefqU'.
+     'b91wibH5EkCQBCizFihTSviHUHR0hWws9xe3wvJ7/7nPKpgX5y'.
+     '9oFqt3eOgWniRBoAbUBGGqZUibSYaeoT2B5bnkdaSA6793Cv/S'.
+     'QPPbihXBfo5VdOV+8dfgnvwAU62YH5fCZ12sDujFkwyegCqTrB'.
+     'iUOKTOJKj8jr88jS8zy6cXwBTP048nuHX0I0nDlIp7RpTG7kM0'.
+     'sdyAYsTVukUuWGhlWHMq0ITL92lnUp9R1Obz/GmTNnqn9bDD8/'.
+     '+0D1oX0O0zQZZDYCsK2j3Gl9jQqDfHiei8GfiKVLlsZkJaBAN1'.
+     '0i6PgwUbB0GxG5/PrtE/xLRr959Znqw9452oVNI+jiJhnr1pe4'.
+     'k29zB1/nFr5Kj7tpt1YYhJ0FJ7nUYbcJQBgahN2MzeCP/OipR6'.
+     'prgN6Qr6ELFQFUWoRpNVjlKwxZB8DCpE+PtfEKqV1cUzxpVudu'.
+     'GTBHA5Y1g99e+dUio9O/P1Vpq+/WE5GGjDSMoAtAQjrf3C52IP'.
+     'QxpY4WK2hpReka9Gfrhqgz0bACRoCWjDh56kQ1z9FeuUUQxVhK'.
+     'B92sD1VahM+bAJgcoJhGjP/6Ln8rAgDiRCVRKiIzxMkkodBJ85'.
+     'im1IlEHbE4k1xyNveL4YP8HarmGJIOpqyjeQmfNHmTvnqZTWBt'.
+     'vIJXpPwlukJSuSTKGK3pEwtJmiX00ZlInTyNscImO6XBITvH1c'.
+     '8vVt2OucdKvIyeKRTNCivsEMgcpg6taYs30nfq0Gqg6hOSSFJ4'.
+     'BSnJPht0IqEjWmOGocEI6F0J94F0qaL6BntTF0MtUfweKQKAPU'.
+     'Wwp4OcVnQAmVb0p9DLOzjEhEKnGRmoRc7EzRGlwA6NujAKG4yP'.
+     '6Sjwc4aVznZ7DK0xXdkDoJf0kGmFBniFBOBGcZSCCSKd0IwN0k'.
+     'IS+QZWCGVZex4BnUxya3+Zt9iugQbcRFpIAtuHvAZulPUdLhUJ'.
+     'RqegI3WcqaSXddlT3idsWMSRRGkEtNwmyTifAwyBo7LP+11J0e'.
+     '7tM7pZOYblHkBLcqZ5LcYtw6Wbd4CM3SpE9foYZsIHoqDKCrbz'.
+     'mLSQtPwmuhXgtBLs0GBdbXOhFGB7WBKO2F8GXt9/VO97Ya3atF'.
+     '7nUHnwGjGGQqcPxFEdFqURkEidiZszAERoYIsGju1hq21kWee3'.
+     'bw15+8WpsvAy3K1+i3JkkhZyPpxxjjPOsfOYiZ+TFhLPzQnHOU'.
+     'tpzGB2dgA4tscIkKIx19Cxg/fPL7vQJu47eXt1VvsDK8pwPueZ'.
+     'PuZoQMOqhRoJHSs0kKLBWjvjYinmeQGw1TaX1RFdfZ3LMzYLjA'.
+     'C++dkn6AaH2Nobk6cxEzdnuG0TdC8zvdJkN0hqkFkO/jwL0fxa'.
+     'so8sBcuFzQ+/+MRC+BeAHnpwQzn++ee5KT9Eshuy46dcKAXm32'.
+     '0uzPQhS4GttkH2GQID2Wc0Y4LtAbDxhZ/x5A+e/uTG9+jGceXH'.
+     '9/ySnnIXnUzOxXe1038mW3ZynNmam4yYWkO+f9cv+Oljz16/lV'.
+     '9tDz/9nerc1hm8ZEScSRK7VvtYl1i1dklsOKyvc+zg/bzw1O8+'.
+     '/efkajt56kR1ydlEJBc5H46xzbrJ3dY9wrB7hGcff+6/+279L+'.
+     '0fHxyiE8XMLl4AAAAASUVORK5CYII=' ; 
+
+        //==========================================================
+        // File: bl_blue.png
+        //==========================================================
+        $this->imgdata_large[9][0]= 1169 ;
+        $this->imgdata_large[9][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAMAAACelLz8AAACEF'.
+     'BMVEX/////////7//35//v1v/exv/Wvf/Wrf/Wpf/Orf+/v7+9'.
+     'tc69jP+9hP+5ucW1tc6tlP+rq7Wlpdalpcalpb2cnM6cnMacc/'.
+     '+cWv+UlLWUjN6UjK2Uc/+Ma/+MUv+EhKWEa/+EQvd7e8Z7e7V7'.
+     'e6V7c957Wv9za9Zza8ZzSv9ra5xrSv9rOf9rMe9jUudjQv9jOe'.
+     '9aWpRaUt5aUpRaSu9aSudSUoxSSs5SSoxSMf9KQtZKOfdKMedK'.
+     'Kf9KKe9CKf9CKb1CKa1CIfdCIedCId45MXs5Kfc5If85Iec5Id'.
+     'Y5GP8xMbUxMXsxKc4xKZQxIf8xGP8xGO8xGN4xGNYxGL0xGK0p'.
+     'KXMpIYwpGP8pGO8pGOcpGNYpGM4pEP8pEPcpEOcpEN4pENYpEM'.
+     'YpEL0hGKUhEP8hEPchEO8hEOchEN4hENYhEM4hEMYhELUhCP8h'.
+     'CO8hCN4YGJwYGGsYEL0YEK0YEHMYCN4YCM4YCMYYCL0YCKUYAP'.
+     '8QEJQQEIwQEHsQEGsQCM4QCLUQCK0QCKUQCJwQCJQQCIwQCHMQ'.
+     'CGsQAP8QAPcQAO8QAOcQAN4QANYQAM4QAMYQAL0QALUQAKUQAJ'.
+     'QQAIQICGsICGMIAO8IANYIAL0IALUIAK0IAKUIAJwIAJQIAIwI'.
+     'AIQIAHsIAHMIAGsIAGMAAN4AAMYAAK0AAJQAAIwAAIQAAHMAAG'.
+     'sAAGMAAFrR1dDlAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgA'.
+     'AAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAwkRFRPMOZ'.
+     '/2AAAB+klEQVR4nGNgIAIIqeqZmBqpi2JISNml5lVXV3d198Yo'.
+     'oUjwm1SnxsbGRsSm5ZfNXO4tjCTjVh0ABhFx6QV9E1Y0S8JkuN'.
+     '3yAgLc7W3t/QPi4jPKJ8ye1yoIlTKpjvVy15eVUbN0i4zKLJ8w'.
+     'ae6qcKgLqmMj3PUFWFl5NJ0CExLLJzbNW7BWCyxlXR0ba6/Axs'.
+     'zELmfnkRBT0QiSKgXJCOflxUbYy3KyMHEoOrtEZ1c2TZ6/cMl6'.
+     'eaCUamdsbIC7tjgPr4SBS3BMMVDTwkXr1hsDpYy6UmMj/O0tdX'.
+     'QNbDxjknJLWqYsXLx0vStQynxGflpkZGCgs7Onp29SbtNkoMy6'.
+     'pevCgFJWy3oyMuKjgoKCPWNCvEuqWhcsWrJ06XqQlPnMvrKyrM'.
+     'TomJjkZAfHlNa2qdOWrlu63gcopbG8v7+hvLwip7g4JdSxsLZu'.
+     '8dKlS9ettwBKic2eNXHChIkTG5tKqgpr2uo6loLAehWQx0LnzJ'.
+     '49p6mpeXLLlNq6RUvqly6dvnR9Bx9ISnnlvLmT582bMr9t4aL2'.
+     '+vrp60GaDCGB6Ld6wfwFCxYCJZYsXQ+SmL6+FBryInVrFi1atH'.
+     'jJkqVQsH6pNCzCJNvXrQW6CmQJREYFEc2CYevXrwMLAyXXl0oz'.
+     'IAOt0vVQUGSIkabkDV3DwlzNVDAksAAAfUbNQRCwr88AAAAASU'.
+     'VORK5CYII=' ; 
+
+        //==========================================================
+        // File: bs_red.png
+        //==========================================================
+        $this->imgdata_small[0][0]= 437 ;
+        $this->imgdata_small[0][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAAAk1'.
+     'BMVEX////////GxsbGra3/xsbOhITWhIT/hIT/e3v/c3P/a2vG'.
+     'UlK1SkrOUlL/Y2PWUlLGSkrnUlLeSkrnSkr/SkqEGBj/KSmlGB'.
+     'jeGBjvGBj3GBj/EBD/CAj/AAD3AADvAADnAADeAADWAADOAADG'.
+     'AAC9AAC1AACtAAClAACcAACUAACMAACEAAB7AABzAABrAABjAA'.
+     'BuukXBAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZ'.
+     'cwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAwkUGDNEMgOYAAAAm0'.
+     'lEQVR4nI3Q3RKCIBAFYGZMy9RKzX7MVUAUlQTe/+kS0K49d3wD'.
+     '7JlFaG+CvIR3FvzPXgpLatxevVVS+Jzv0BDGk/UJwOkQ1ph2g/'.
+     'Ct5ACX4wNT1o/zzUoJUFUGBiGfVnDTYGJgmrWy8iKEtp0Bpd2d'.
+     'jLGu56MB7f4JOOfDJAwoNwslk/jOUi+Jts6RVNrC1hkhPy50Ef'.
+     'u79/ADQMQSGQ8bBywAAAAASUVORK5CYII=' ; 
+
+
+        //==========================================================
+        // File: bs_lightblue.png
+        //==========================================================
+        $this->imgdata_small[1][0]= 657 ;
+        $this->imgdata_small[1][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAABVl'.
+     'BMVEX////////d///AwMC7wcS08P+y+P+xxdCwxM+uws2twMur'.
+     'vsinzNynytylzuKhyN6e5v6d5P+d1fOcwNWcu8ub4f+at8iZ3v'.
+     '+ZvdGY2/yW2f+VscGU1vuT1fqTr72Sx+SSxeKR0fWRz/GPz/OP'.
+     'rr+OyeqMy+6Myu2LyeyKxueJudSGw+SGorGDvt+Cvd6CvN2Aud'.
+     'p+uNd+t9Z9tdV8tdR8tNN6sc94r813rct2q8h0qcZ0qMVzp8Rx'.
+     'o8Bwor5tn7ptnrptnrlsnbhqmbRpmbNpi51ol7Flkqtkkqtkka'.
+     'pjj6hijaRhjaZgi6NfiqJfiaFdh55bhJtag5pZgphYgJZYf5VX'.
+     'cn9Ve5FSeI1RdopRdYlQdYlPc4dPcoZPcoVNcINLboBLbH9GZn'.
+     'hGZXdFZHZEY3RDYnJCXW4/W2s/WWg+Wmo7VmU7VGM7U2E6VGM6'.
+     'VGI5UV82T1wGxheQAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHU'.
+     'gAAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAwkUGTok'.
+     '9Yp9AAAAtElEQVR4nGNgIBaw8wkpKghzwvksPAKiUsraprYiLF'.
+     'ARXkE2JiZ1PXMHXzGIAIekOFBE08TGLTCOCyzCLyvDxsZqZOnk'.
+     'E56kAhaRV9NQUjW2tPcMjs9wBYsY6Oobmlk7egRGpxZmgkW0zC'.
+     '2s7Jy9giKT8gohaiQcnVzc/UNjkrMLCyHmcHr7BYREJKTlFxbm'.
+     'QOxiEIuKTUzJKgQCaZibpdOzQfwCOZibGRi4dcJyw3S4iQ4HAL'.
+     'qvIlIAMH7YAAAAAElFTkSuQmCC' ; 
+
+        //==========================================================
+        // File: bs_gray.png
+        //==========================================================
+        $this->imgdata_small[2][0]= 550 ;
+        $this->imgdata_small[2][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAAQCAMAAADH72RtAAABI1'.
+     'BMVEX///8AAAD8EAD8IAD8NAD8RAD8VAAYGBi/v7+goKCCgoJk'.
+     'ZGRGRkb8yAD83AD87AD8/AD4+ADo+ADY+ADI+AC0+ACk+ACU+A'.
+     'CE+AB0/ABk/ABU/ABE/AAw/AAg/AAQ/AAA/AAA+AAA6BAA2CAA'.
+     'yDQAtEQApFQAlGQAhHQAdIgAZJgAVKgARLgAMMgAINwAEOwAAP'.
+     'wAAPgIAPAQAOgYAOAkANgsANA0AMg8AMBEALhMALBUAKhcAKBo'.
+     'AJhwAJB4AIiAAID////4+Pjy8vLs7Ozm5ubg4ODa2trT09PNzc'.
+     '3Hx8fBwcG7u7u1tbWurq6oqKiioqKcnJyWlpaQkJCJiYmDg4N9'.
+     'fX13d3dxcXFra2tkZGReXl5YWFhSUlJMTExGRkZAQEA1BLn4AA'.
+     'AAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxIA'.
+     'AAsSAdLdfvwAAAAHdElNRQfTAwkUGiIctEHoAAAAfElEQVR4nI'.
+     '2N2xKDIAwF+bZ2kAa8cNFosBD//yvKWGh9dN+yk9kjxH28R7ze'.
+     'wzBOYSX6CaNB927Z9qZ66KTSNmBM7UU9Hx2c5qjmJaWCaV5j4t'.
+     'o1ANr40sn5a+x4biElrqHgrXMeac/c1nEpFHG0LSFoo/jO/BeF'.
+     'lJnFbT58ayUf0BpA8wAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        // File: bs_greenblue.png
+        //==========================================================
+        $this->imgdata_small[3][0]= 503 ;
+        $this->imgdata_small[3][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAAAxl'.
+     'BMVEX///////+/v79znJQhSkJ7raU5hHtjraVKnJRCjIRClIyU'.
+     '9++E595avbVaxr2/v7+ctbWcvb17nJxrjIx7paUxQkK9//+Mvb'.
+     '17ra2Evb17tbVCY2MQGBiU5+ec9/eM5+d71tZanJxjra1rvb1j'.
+     'tbVSnJxara1rzs5jxsZKlJRChIQpUlIhQkJatbVSpaU5c3MxY2'.
+     'MYMTEQISFavb1Sra1KnJxCjIw5e3sxa2spWlpClJQhSkoYOTkp'.
+     'Y2MhUlIQKSkIGBgQMTH+e30mAAAAAXRSTlMAQObYZgAAAAFiS0'.
+     'dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfT'.
+     'AwkUGTIqLgJPAAAAqklEQVR4nI2QVxOCMBCEM6Mi2OiCvSslJB'.
+     'CUoqjn//9TYgCfubf9Zu9uZxFqO+rscO7b6l/LljMZX29J2pNr'.
+     'YjmX4ZaIEs2NeiWO19NNacl8rHAyD4LR6jjw6PMRdTjZE0JOiU'.
+     'dDv2ALTlzRvSdCCfAHGCc7yRPSrAQRQOWxKc3C/IUjBlDdUcM8'.
+     '97vFGwBY9QsZGBc/A4DWZNbeXIPWZEZI0c2lqSute/gCO9MXGY'.
+     '4/IOkAAAAASUVORK5CYII=' ; 
+
+        //==========================================================
+        // File: bs_yellow.png
+        //==========================================================
+        $this->imgdata_small[4][0]= 507 ;
+        $this->imgdata_small[4][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAAAzF'.
+     'BMVEX///////+/v79zYwCMewDOxoTWzoTezkr/5wj/5wDnzgDe'.
+     'xgC1pQCtnACllACcjACUhABjWgDGvVK1rUrOxlLGvUqEexilnB'.
+     'jv3hj35xj/7wj/7wD35wDv3gDn1gDezgDWxgDOvQDGtQC9rQCE'.
+     'ewB7cwBzawBrYwDWzlLn3lLe1krn3kre1hi9tQC1rQCtpQClnA'.
+     'CclACUjACMhAD/9wC/v7///8bOzoT//4T//3v//3P//2v//2Pn'.
+     '50r//0r//yn39xj//xD//wBjYwDO8noaAAAAAXRSTlMAQObYZg'.
+     'AAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAH'.
+     'dElNRQfTAwkUGSDZl3MHAAAAqElEQVR4nI3QWRNDMBAA4My09E'.
+     'IF1SME0VT1okXvM/3//6kEfbZv+81eswA0DfHxRpOV+M+zkDGG'.
+     'rL63zCoJ2ef2RLZDIqNqYexyvFrY9ePkxGWdpvfzC7tEGtIRly'.
+     'nqzboFKMlizAXbNnZyiFUKAy4bZ+B6W0lRaQDLmg4h/k7eFwDL'.
+     'OWIky8qhXUBQ7gKGmsxpC+ah1TdriwByqG8GQNDNr6kLjf/wAx'.
+     'KgEq+FpPbfAAAAAElFTkSuQmCC' ; 
+
+        //==========================================================
+        // File: bs_darkgray.png
+        //==========================================================
+        $this->imgdata_small[5][0]= 611 ;
+        $this->imgdata_small[5][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAA8AAAAPCAMAAAAMCGV4AAABJl'.
+     'BMVEX////////o8v/f6O7W4OnR3PXL1OTL0evEyLvCzePAwMC/'.
+     'v7a8wsq7t7C1xum1vtS1q6GzopmyxeKsrsOqvNWoq7anvN+nsb'.
+     'qhrcGgqbGfpq6cp7+bqMuVmJKRm7yPlKKMnL6FkKWFipOEkLSE'.
+     'j6qEhoqAiaB+jqd8haF7hZR4iJt4g5l3hZl2gIt2cod1hJVzeY'.
+     'VzboJvhp9sfJJsb41peY1pd5xpdoVod4xndI5lcHxka4BjcYVg'.
+     'Z3BfboFbb4lbZnZbYntaZ4laZYVZV3JYYWpXX3JWWm5VX4RVW2'.
+     'NUYX9SXHxPWn5OVFxNWWtNVXVMVWFKV3xHUGZGU3dGTldFSlxE'.
+     'Sk9ESXBCRlNBS3k/SGs/RU4+R1k9R2U6RFU2PUg0PEQxNU0ECL'.
+     'QWAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAA'.
+     'CxIAAAsSAdLdfvwAAAAHdElNRQfTAwkUGQmbJetrAAAAtklEQV'.
+     'R4nGNgwAK4JZTNNOWlYDxhMT4ZDTOzQE1uMF9CiJWVU0LbxDlS'.
+     'G8QVF+FnZ2KRNHAIiPUHaZGSlmZj5lH19A1KjLUA8lXU5MWllF'.
+     'yjo30TYr2BfG19G11b37CEeN84H38gX1HbwTUkOjo+zjfG3hLI'.
+     'l1exCvCNCwnxjfMz0gTyRdXNHXx9fUNCQu2MwU6SN3ZwD42LCH'.
+     'W30IK4T8vUJSAkNMhDiwPqYiktXWN9JZj7UQAAjWEfhlG+kScA'.
+     'AAAASUVORK5CYII=' ; 
+
+
+        //==========================================================
+        // File: bs_darkgreen.png
+        //==========================================================
+        $this->imgdata_small[6][0]= 666 ;
+        $this->imgdata_small[6][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAABX1'.
+     'BMVEX////////l/+nAwMC86r+8wb28wby8wLy78sCzw7SywrSx'.
+     'wLKwvrGuvK+syK+ryq2rx62n36ym3aumxKmk2qij0Keh16ahva'.
+     'Og1aSguKKe06KeuaCetZ+d0KGdtZ+bz6Cay56ZyZ2Zwp2Zr5qZ'.
+     'rpqYwJuXyZuXrJmVw5mUxZiTxJeTw5eTq5WRwJWPtJKOvZKKuI'.
+     '6Kt42Kn4yJt42ItIuGsomFsYmEsIiEr4eDr4eBrIR/qoN+qIJ8'.
+     'poB7pH56o356on14nnt2nXl0mndzmnZzmXZymHVwlXNvlHJukn'.
+     'FtiHBqjm1qjW1oi2toiWpniWplh2hlhmdkhWdig2VggGNgf2Je'.
+     'fmFdfGBde19bbl1aeFxXdFpWclhVclhVcVdUcFZTb1VSbVRQal'.
+     'JPaVFKY0xKYkxJYUtIYEpHX0lEWkZCWERCV0NCVkM/U0A+U0A+'.
+     'UUA+UEA9Uj89UT48Tj45TDvewfrHAAAAAXRSTlMAQObYZgAAAA'.
+     'FiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElN'.
+     'RQfTAwkUGRjxlcuZAAAAtElEQVR4nGNgIBZw8osqqIpzw/msfI'.
+     'IiUmr6lo6SbFARASEOJiYtQ2uXADmIAJeEGFBE18LBMySBBywi'.
+     'LC/LwcFiZuvmH5WiAxZR0tRW1DC3dfYJS8zyAouYGBibWtm7+o'.
+     'TEpZfkgEX0rG3snNx9Q2NSCksgaqRd3Ty8gyLiU/NKSiDmcPsF'.
+     'BodHJ2UUlZTkQ+xikIlNSE7LLgECZagL2VQyc0H8YnV2uD94jS'.
+     'ILIo14iQ4HALarJBNwbJVNAAAAAElFTkSuQmCC' ; 
+
+        //==========================================================
+        // File: bs_purple.png
+        //==========================================================
+        $this->imgdata_small[7][0]= 447 ;
+        $this->imgdata_small[7][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAAAnF'.
+     'BMVEX///////+/v7/Gvca9rb3Grcb/xv+1hLWte629hL21e7XG'.
+     'hMbWhNbOe87We9b/hP//e/97OXv/c///a///Y/+cOZz/Sv/WOd'.
+     'bnOefvOe//Kf9jCGNrCGv/EP//CP/nCOf/AP/3APfvAO/nAOfe'.
+     'AN7WANbOAM7GAMa9AL21ALWtAK2lAKWcAJyUAJSMAIyEAIR7AH'.
+     'tzAHNrAGtjAGPP1sZnAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgF'.
+     'HUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAwkUGS'.
+     'o5QpoZAAAAnElEQVR4nI3Q2xJDMBAG4MyQokWrZz3oSkJISJH3'.
+     'f7dK0Gv/Xb7J7vyzCK0NjtPsHuH/2wlhTE7LnTNLCO/TFQjjIp'.
+     'hHAA6bY06LSqppMAY47x+04HXTba2kAFlmQKr+YuVDCGUG2k6/'.
+     'rNwYK8rKwKCnPxHnVS0aA3rag4UQslUGhrlk0Kpv1+sx3tLZ6w'.
+     'dtYemMkOsnz8R3V9/hB87DEu2Wos5+AAAAAElFTkSuQmCC' ; 
+
+
+        //==========================================================
+        // File: bs_brown.png
+        //==========================================================
+        $this->imgdata_small[8][0]= 677 ;
+        $this->imgdata_small[8][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAABaF'.
+     'BMVEX//////////8X/3oD/3nj/1HX/0Gr/xGP/rkv/gBf+iS/2'.
+     'bAL1agDxaQDuZwDrZwLpZQDmZQLlZADjcx7gZATeYQDdZgraXw'.
+     'DZXwHYXgDXiEvXZAvUjlfUXwXTjVfTbR7ShUvRbR7RWwDMWQDL'.
+     'WADKooLKWADJoYLJgkvHWATGoILFn4LFgEvFVgDEZx7EVQDDt6'.
+     '/DVQDCt6/CnoLChlfCVADAwMC+hFe+UgC8UgC6UQC4gVe4UAC3'.
+     'gVe3UAC1gFe1eUu1TwC1TgCzTgCwTQKuTACrSgCqSgCpSgCpSQ'.
+     'CodEulSACkRwCiRgCdRACcRACaQwCYQgCWQgKVQQCVQACUQACS'.
+     'UR6RPwCOPgCNPQCLPACKPACJOwCEOQCBOAB+NwB9NgB8NgB7NQ'.
+     'B6NwJ4NAB3RR52MwB0MgBuLwBtLwBsLwBqLgBpLQBkLQJiKgBh'.
+     'KgBgKwRcKABbKQJbJwBaKQRaJwBYKAJVJQDZvdIYAAAAAXRSTl'.
+     'MAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAdLd'.
+     'fvwAAAAHdElNRQfTAwkUGho0tvl2AAAAtklEQVR4nGNgIBaoSg'.
+     'mLKGpowfkGMty8AqJKpi4mRlAROR5ONg4JFUv3YHOIgDo/HwsT'.
+     'q6yps29EsjZYREFIkJ2ZS9/OMzA20wEsIi8uKSZtaOPmH5WSFw'.
+     'YW0VRW07Vw8vCLSMguLwCL6FlaObp6B0TGZxSXQ9TouHv6+IXG'.
+     'JGYWlpdDzNEKCgmPjkvLKS0vL4LYxWAen5SelV8OBNZQFxrZ5h'.
+     'aC+GX2MDczMBh7pZakehkTHQ4AA0Am/jsB5gkAAAAASUVORK5C'.
+     'YII=' ; 
+
+        //==========================================================
+        // File: bs_blue.png
+        //==========================================================
+        $this->imgdata_small[9][0]= 436 ;
+        $this->imgdata_small[9][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAAAk1'.
+     'BMVEX///////+/v7+trcbGxv+EhM6EhNaEhP97e/9zc/9ra/9S'.
+     'UsZKSrVSUs5jY/9SUtZKSsZSUudKSt5KSudKSv8YGIQpKf8YGK'.
+     'UYGN4YGO8YGPcQEP8ICP8AAP8AAPcAAO8AAOcAAN4AANYAAM4A'.
+     'AMYAAL0AALUAAK0AAKUAAJwAAJQAAIwAAIQAAHsAAHMAAGsAAG'.
+     'ONFkFbAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZ'.
+     'cwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAwkUGhNNakHSAAAAmk'.
+     'lEQVR4nI3P2xKCIBAGYGfM6SBWo1nauIqogaDA+z9dK9Lhrv47'.
+     'vtl/2A2CfxNlJRRp9IETYGraJeEb7ocLNKznia8A7Db7umWDUG'.
+     'sxAzhurxRHxok4KQGqCuEhlL45oU1D2w5BztY4KRhj/bCAsetM'.
+     '2uObjwvY8/oX50JItYDxSyZSTrO2mNhvGMbaWAevnbFIcpuTr7'.
+     't+5AkyfBIKSJHdSQAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        // File: bs_green.png
+        //==========================================================
+        $this->imgdata_small[10][0]= 452 ;
+        $this->imgdata_small[10][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAAAn1'.
+     'BMVEX///////+/v7+/v7/G/8aUxpSMvYyUzpSMzoyM1oxarVqE'.
+     '/4R7/3tavVpKnEpaxlpz/3Nr/2tKtUpj/2Na51pKzkpK1kpK50'.
+     'pK/0oYcxgp/ykYlBgY3hgY7xgY9xgQ/xAI/wgA/wAA9wAA7wAA'.
+     '5wAA3gAA1gAAzgAAxgAAvQAAtQAArQAApQAAnAAAlAAAjAAAhA'.
+     'AAewAAcwAAawAAYwA0tyxUAAAAAXRSTlMAQObYZgAAAAFiS0dE'.
+     'AIgFHUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAw'.
+     'kUGgW5vvSDAAAAnklEQVR4nI3QSxKCMAwA0M4gqCgoiiJ+kEAL'.
+     'LQUq0PufzX7ENdnlJZNkgtDS2CYZvK6bf+7EoKLA9cH5SQzv6A'.
+     'YloTywsAbYr44FrlgrXCMJwHl3xxVtuuFkJAPIcw2tGB9GcFli'.
+     'oqEf5GTkSUhVMw2TtD0XSlnDOw3SznE5520vNEi7CwW9+Ayjyq'.
+     'U/3+yPuq5gvhkhL0xlGnqL//AFf14UIh4mkEkAAAAASUVORK5C'.
+     'YII=' ; 
+
+
+        //==========================================================
+        // File: bs_white.png
+        //==========================================================
+        $this->imgdata_small[11][0]= 480 ;
+        $this->imgdata_small[11][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAAQCAYAAADwMZRfAAAABm'.
+     'JLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsRAAALEQF/ZF+RAAAA'.
+     'B3RJTUUH0wMLFTsY/ewvBQAAAW1JREFUeJytkz2u4jAUhT/jic'.
+     'gfBUKiZhE0bIKeVbCWrIKenp6eDiGlCEEEBArIxvzGU4xeZjLk'.
+     'jWb05lRXuvbx+exr4bouX1Xjyw7Atz81F4uFBYjjGIDhcCjq1o'.
+     'k6nN1uZwFerxfP55Msy1itVmRZBsB4PK6YveHkeW5d18XzPIIg'.
+     'wPd9Wq0WnU6HMAxJkoQoiuynOIfDwUopkVIihKAoCgAcx6Hdbm'.
+     'OMIU1T5vN55eBKEikljUYDIX6kFUKU9e8aDAZlmjcca+1b7TgO'.
+     '1+uVy+VS9nzfr8e53++VzdZaiqIgz3OMMWitOZ/PaK0JgqDeRC'.
+     'mF53lIKYGfr3O73TDGoJQiTVO01nS73XqT4/FIs9kkCAIej0eZ'.
+     'brPZEMcxSZKgtQZgMpmIWpN+vy+m06n1PK9yTx8Gy+WS/X5Pr9'.
+     'er9GuHLYoiG4YhSilOpxPr9Zrtdlti/JriU5MPjUYjq7UuEWaz'.
+     '2d+P/b/qv/zi75oetJcv7QQXAAAAAElFTkSuQmCC' ; 
+
+
+        //==========================================================
+        // File: bs_cyan.png
+        //==========================================================
+        $this->imgdata_small[12][0]= 633 ;
+        $this->imgdata_small[12][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAABPl'.
+     'BMVEX////////F///AwMCvxsaC1NSC0dGCz8+CzMyA//94//91'.
+     '//9q//9j//9X4uJX09NXz89Xx8dXxMRL//9L5uZL3d1L2NhLxs'.
+     'ZLt7cv//8e9fUe8fEe7u4e398epqYehoYX//8L+PgK//8F9fUE'.
+     '/v4E5+cEb28EZ2cC//8C/v4C/f0CzMwCrq4Cjo4CdXUCaWkCZW'.
+     'UB/PwA//8A/f0A+/sA8/MA7e0A7OwA6+sA5eUA5OQA4uIA4eEA'.
+     '3NwA2toA2NgA1dUA09MA0tIA0NAAysoAxsYAxcUAxMQAv78Avr'.
+     '4AvLwAtrYAtbUAs7MAsLAAra0Aq6sAqKgApaUApKQAoqIAoKAA'.
+     'n58AmpoAlZUAk5MAkpIAkJAAj48AjIwAiYkAh4cAf38AfX0Ae3'.
+     'sAenoAcnIAcHAAa2sAaWkAaGgAYmIUPEuTAAAAAXRSTlMAQObY'.
+     'ZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAA'.
+     'AHdElNRQfTAwkUGQDi+VPPAAAAtElEQVR4nGNgIBawikipyIiy'.
+     'wfksfJpGRkamNtr8LFARPiMFHmFDcztXfwGoFi0jLiZuZRtnry'.
+     'BddrCIiJEGL6eklYO7X3iCOFhE2thESdHawdUnJDZFDiyiamZh'.
+     'aevk5h0UlZSpBhaRtbN3dPHwDY5MSM+EqBFzc/f0DgiLTkjLzI'.
+     'SYw6bjHxgaEZeckZmpD7GLQSAqJj4xNRMIBGFuFtRLA/ENhGBu'.
+     'ZmDgkJBXl5fgIDocAAKcINaFePT4AAAAAElFTkSuQmCC' ; 
+
+        //==========================================================
+        // File: bs_bluegreen.png
+        //==========================================================
+        $this->imgdata_small[13][0]= 493 ;
+        $this->imgdata_small[13][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAAAvV'.
+     'BMVEX///////+/v79j//855/8x3v851v9Spb1C1v8AOUqEtcZK'.
+     'lK1StdYxzv8hxv8AY4QASmNSlK1KpcZKtd4YQlIYnM4YrecIvf'.
+     '8AtfcAre8AjL0AhLUAc5wAa5QAWnsAQloAKTkAGCFKhJxKrdYY'.
+     'jL0Ypd4Atf8ArfcApecAnN4AlM4AjMYAe60Ac6UAY4wAUnNSnL'.
+     '0AlNYAWoQASmsAOVIAITGEtc4YWnsAUnsAMUqtvcaErcYAKUIA'.
+     'GCkAECHUyVh/AAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAA'.
+     'AJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAwkUGxNUcXCT'.
+     'AAAAqUlEQVR4nI2Q1xKCMBREM2NHLCCogAGCjd6SqLT8/2cZKT'.
+     '6zb3tm987OBWCsXoejp8rC35fi4+l6gXFZlD0Rz6fZ1tdDmKR9'.
+     'RdOmkzmP7DDpilfX3SzvRgQ/Vr1uiZplfsCBiVf03RJd140wgj'.
+     'kmNqMtuYXcxyYmNWJdRoYwzpM9qRvGujuCmSR7q7ARY00/MiWk'.
+     'sCnjkobNEm1+HknDZgAqR0GKU43+wxdu2hYzbsHU6AAAAABJRU'.
+     '5ErkJggg==' ; 
+
+        //==========================================================
+        // File: bs_lightred.png
+        //==========================================================
+        $this->imgdata_small[14][0]= 532 ;
+        $this->imgdata_small[14][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAAA3l'.
+     'BMVEX///////+/v7/Gvb0hGBj/5///3v//zu//1u//xucpGCG9'.
+     'nK21lKVSQkp7Wms5KTExISlaOUpjQlIhEBj/tdbOhKXnrcbGjK'.
+     'Wla4TetcbGnK2EWmv/rc73pcZ7UmOcY3vOpbW1jJzenLW9e5Rz'.
+     'Slq1c4xrQlJSOULGhJz/pcb3nL2chIzOnK33rcbelK3WjKWMWm'.
+     'vGe5SEUmM5ISnOtb3GrbXerb3vpb2ca3v/rcaUY3POhJxCKTF7'.
+     'SlrWnK21e4ytc4TvnLXnlK2la3taOUK1lJxrSlLGhJRjQkpSMT'.
+     'lw+q2nAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZ'.
+     'cwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAwkUGjoP2Nm+AAAAr0'.
+     'lEQVR4nGNgIBaYiOk62imYwPnMkiIyso76yhJSzFARMxkRNk49'.
+     'a3t5OW6oFk1LVkYOfWUHKxUXiEYzLS12DnN3VXkjIRtFsIiSk5'.
+     '6evqGqhYGKugAfWMRa1FpD2UHeQEXQRlgALCJur+rgbCUNFOAS'.
+     'hqjRkZe3MpBTcwEKCEPMMTGSs3Xz8OQHCnBBHckt6OJpIyAMBD'.
+     'wwN/MYc4H4LK4wNzMwmGrzcvFqmxIdDgDiHRT6VVQkrAAAAABJ'.
+     'RU5ErkJggg==' ;
+
+        //==========================================================
+        // File: bxs_lightred.png
+        //==========================================================
+        $this->imgdata_xsmall[0][0]= 432 ;
+        $this->imgdata_xsmall[0][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAMAAAC67D+PAAAA3l'.
+     'BMVEX///////+/v7/Gvb0hGBj/5///3v//zu//1u//xucpGCG9'.
+     'nK21lKVSQkp7Wms5KTExISlaOUpjQlIhEBj/tdbOhKXnrcbGjK'.
+     'Wla4TetcbGnK2EWmv/rc73pcZ7UmOcY3vOpbW1jJzenLW9e5Rz'.
+     'Slq1c4xrQlJSOULGhJz/pcb3nL2chIzOnK33rcbelK3WjKWMWm'.
+     'vGe5SEUmM5ISnOtb3GrbXerb3vpb2ca3v/rcaUY3POhJxCKTF7'.
+     'SlrWnK21e4ytc4TvnLXnlK2la3taOUK1lJxrSlLGhJRjQkpSMT'.
+     'lw+q2nAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZ'.
+     'cwAACxEAAAsRAX9kX5EAAAAHdElNRQfTAwkUKBOgGhWjAAAAS0'.
+     'lEQVR4nGNgQAEmunYmEJaMCKe1vBxYzJKVQ9lKBSSupKdnaKGi'.
+     'zgdkiqs6WKnYcIGYJnK2HvzCwmCNgi42wsLCECNMeXlNUY0HAL'.
+     'DaB7Du8MiEAAAAAElFTkSuQmCC' ; 
+
+        //==========================================================
+        // File: bxs_bluegreen.png
+        //==========================================================
+        $this->imgdata_xsmall[1][0]= 397 ;
+        $this->imgdata_xsmall[1][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAMAAAC67D+PAAAAvV'.
+     'BMVEX///////+/v79j//855/8x3v851v9Spb1C1v8AOUqEtcZK'.
+     'lK1StdYxzv8hxv8AY4QASmNSlK1KpcZKtd4YQlIYnM4YrecIvf'.
+     '8AtfcAre8AjL0AhLUAc5wAa5QAWnsAQloAKTkAGCFKhJxKrdYY'.
+     'jL0Ypd4Atf8ArfcApecAnN4AlM4AjMYAe60Ac6UAY4wAUnNSnL'.
+     '0AlNYAWoQASmsAOVIAITGEtc4YWnsAUnsAMUqtvcaErcYAKUIA'.
+     'GCkAECHUyVh/AAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAA'.
+     'AJcEhZcwAACxEAAAsRAX9kX5EAAAAHdElNRQfTAwkUKDVyF5Be'.
+     'AAAASUlEQVR4nGNgQAFmYqJcEJaEOJ+UrD5YTJKFTZrfGCQuaq'.
+     'glLWvMaQ5kqujo6hnbKIKYXPr68gp2dmCNJiZAlh3ECGsREWtU'.
+     '4wF1kwdpAHfnSwAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        // File: bxs_navy.png
+        //==========================================================
+        $this->imgdata_xsmall[2][0]= 353 ;
+        $this->imgdata_xsmall[2][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAMAAAC67D+PAAAAk1'.
+     'BMVEX///////+/v7+trcbGxv+EhM6EhNaEhP97e/9zc/9ra/9S'.
+     'UsZKSrVSUs5jY/9SUtZKSsZSUudKSt5KSudKSv8YGIQpKf8YGK'.
+     'UYGN4YGO8YGPcQEP8ICP8AAP8AAPcAAO8AAOcAAN4AANYAAM4A'.
+     'AMYAAL0AALUAAK0AAKUAAJwAAJQAAIwAAIQAAHsAAHMAAGsAAG'.
+     'ONFkFbAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZ'.
+     'cwAACxEAAAsRAX9kX5EAAAAHdElNRQfTAwkUJxXO4axZAAAAR0'.
+     'lEQVR4nGNgQAGskhKsEJaslIi8ijpYTJaDU1FVAyQuKSujoKKh'.
+     'LQ5kSigpqWro6oOYrOoaWroGBmCNWiCWAdQwUVFWVOMBOp4GCJ'.
+     's5S60AAAAASUVORK5CYII=' ; 
+
+        //==========================================================
+        // File: bxs_gray.png
+        //==========================================================
+        $this->imgdata_xsmall[3][0]= 492 ;
+        $this->imgdata_xsmall[3][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAMAAAC67D+PAAABI1'.
+     'BMVEX///8AAAD8EAD8IAD8NAD8RAD8VAAYGBi/v7+goKCCgoJk'.
+     'ZGRGRkb8yAD83AD87AD8/AD4+ADo+ADY+ADI+AC0+ACk+ACU+A'.
+     'CE+AB0/ABk/ABU/ABE/AAw/AAg/AAQ/AAA/AAA+AAA6BAA2CAA'.
+     'yDQAtEQApFQAlGQAhHQAdIgAZJgAVKgARLgAMMgAINwAEOwAAP'.
+     'wAAPgIAPAQAOgYAOAkANgsANA0AMg8AMBEALhMALBUAKhcAKBo'.
+     'AJhwAJB4AIiAAID////4+Pjy8vLs7Ozm5ubg4ODa2trT09PNzc'.
+     '3Hx8fBwcG7u7u1tbWurq6oqKiioqKcnJyWlpaQkJCJiYmDg4N9'.
+     'fX13d3dxcXFra2tkZGReXl5YWFhSUlJMTExGRkZAQEA1BLn4AA'.
+     'AAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxEA'.
+     'AAsRAX9kX5EAAAAHdElNRQfTAwkUKC74clmyAAAAQklEQVR4nG'.
+     'NgQAVBYVCGt5dXYEQ0mOnp5h4QFgVmeri6+4dHxYMVeHoFRUTH'.
+     'gTUFBIZBWAwMkZEx8bFQM2Lj0UwHANc/DV6yq/BiAAAAAElFTk'.
+     'SuQmCC' ; 
+
+        //==========================================================
+        // File: bxs_graypurple.png
+        //==========================================================
+        $this->imgdata_xsmall[4][0]= 542 ;
+        $this->imgdata_xsmall[4][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAMAAAC67D+PAAABSl'.
+     'BMVEX////////11P/MqdvKrNfAwMC+u7+9u7+4rr24lsi3rby3'.
+     'lMe1rLq1o720q7i0oL20ksSzoryyqbaykMGxlb2wkL+vnbiujb'.
+     '2sjLuri7qpl7GoirWoibenmK2mla6mjLKmhrSllauki7CjhrCj'.
+     'hLGihLChg6+ggq2fkqadkKOcfqqai6Gag6WYe6WXeqSWeaOTd6'.
+     'CTd5+Rdp6RdZ6RdZ2Qg5eOc5qMcpiLcZeJb5WIbpOHbZKGbJGE'.
+     'a4+CaY2AZ4t/Z4p/Zop/Zol+Zol7ZIZ6Y4V5YoR1ZH11X391Xn'.
+     '9zXX1yXXtxXHtvWnluWXhsV3VqVnNpVXJoVHFnU3BmUm9jUGth'.
+     'VGdgTmheTGZcS2RcSmRaSWJYR19XRl5SQllRQlhQQVdPQFZOP1'.
+     'VLPlFJO09IPE5IOk5FOEtEN0lDOEpDOElDNklCNkc/M0XhbrfD'.
+     'AAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACx'.
+     'EAAAsRAX9kX5EAAAAHdElNRQfTAwkUKCgREfyHAAAATUlEQVR4'.
+     'nGNgQAEcIko8EBY3M5Ougy+IxSXMwmTsFsAHZMqrSRvZB0W7A5'.
+     'k6FlYugXEZICaPr394Um4uSAFDRFRCbm4uxAihsDAhVOMBHT0L'.
+     'hkeRpo8AAAAASUVORK5CYII=' ; 
+
+        //==========================================================
+        // File: bxs_red.png
+        //==========================================================
+        $this->imgdata_xsmall[5][0]= 357 ;
+        $this->imgdata_xsmall[5][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAMAAAC67D+PAAAAk1'.
+     'BMVEX////////GxsbGra3/xsbOhITWhIT/hIT/e3v/c3P/a2vG'.
+     'UlK1SkrOUlL/Y2PWUlLGSkrnUlLeSkrnSkr/SkqEGBj/KSmlGB'.
+     'jeGBjvGBj3GBj/EBD/CAj/AAD3AADvAADnAADeAADWAADOAADG'.
+     'AAC9AAC1AACtAAClAACcAACUAACMAACEAAB7AABzAABrAABjAA'.
+     'BuukXBAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZ'.
+     'cwAACxEAAAsRAX9kX5EAAAAHdElNRQfTAwkUIyjy5SVMAAAAS0'.
+     'lEQVR4nGNgQAFsUpJsEJastIi8ijpYTJaDU0FVgxXIlJKVUVDR'.
+     '0BYHMiUUlVQ1dPVBTDZ1dS1dAwOQAgYtbSDLAGIEq6goK6rxAD'.
+     'yXBg73lwGUAAAAAElFTkSuQmCC' ; 
+
+        //==========================================================
+        // File: bxs_yellow.png
+        //==========================================================
+        $this->imgdata_xsmall[6][0]= 414 ;
+        $this->imgdata_xsmall[6][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAMAAAC67D+PAAAAzF'.
+     'BMVEX///////+/v79zYwCMewDOxoTWzoTezkr/5wj/5wDnzgDe'.
+     'xgC1pQCtnACllACcjACUhABjWgDGvVK1rUrOxlLGvUqEexilnB'.
+     'jv3hj35xj/7wj/7wD35wDv3gDn1gDezgDWxgDOvQDGtQC9rQCE'.
+     'ewB7cwBzawBrYwDWzlLn3lLe1krn3kre1hi9tQC1rQCtpQClnA'.
+     'CclACUjACMhAD/9wC/v7///8bOzoT//4T//3v//3P//2v//2Pn'.
+     '50r//0r//yn39xj//xD//wBjYwDO8noaAAAAAXRSTlMAQObYZg'.
+     'AAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxEAAAsRAX9kX5EAAAAH'.
+     'dElNRQfTAwkUIzoBXFQEAAAAS0lEQVR4nGNgQAFsDhJsEJaTo5'.
+     '2skj5YzMnSSk7ZwBzIlOSUklPiMxYHMnW4FXT5VNVBTDZeXiNV'.
+     'QUGQAgYBYyBLEGIEq5gYK6rxAH4kBmHBaMQQAAAAAElFTkSuQm'.
+     'CC' ; 
+
+        //==========================================================
+        // File: bxs_greenblue.png
+        //==========================================================
+        $this->imgdata_xsmall[7][0]= 410 ;
+        $this->imgdata_xsmall[7][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAMAAAC67D+PAAAAxl'.
+     'BMVEX///////+/v79znJQhSkJ7raU5hHtjraVKnJRCjIRClIyU'.
+     '9++E595avbVaxr2/v7+ctbWcvb17nJxrjIx7paUxQkK9//+Mvb'.
+     '17ra2Evb17tbVCY2MQGBiU5+ec9/eM5+d71tZanJxjra1rvb1j'.
+     'tbVSnJxara1rzs5jxsZKlJRChIQpUlIhQkJatbVSpaU5c3MxY2'.
+     'MYMTEQISFavb1Sra1KnJxCjIw5e3sxa2spWlpClJQhSkoYOTkp'.
+     'Y2MhUlIQKSkIGBgQMTH+e30mAAAAAXRSTlMAQObYZgAAAAFiS0'.
+     'dEAIgFHUgAAAAJcEhZcwAACxEAAAsRAX9kX5EAAAAHdElNRQfT'.
+     'AwkUJy5/6kV9AAAATUlEQVR4nGNgQAGCyuyCEJaGugKHviVYzF'.
+     'hO3sxCWwDIVNLTM9PXtpEGMhW12Cy0DR1ATEFLSxZ7BweQAgYd'.
+     'HUMHBweIEQKiogKoxgMAo/4H5AfSehsAAAAASUVORK5CYII=' ; 
+
+        //==========================================================
+        // File: bxs_purple.png
+        //==========================================================
+        $this->imgdata_xsmall[8][0]= 364 ;
+        $this->imgdata_xsmall[8][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAMAAAC67D+PAAAAnF'.
+     'BMVEX///////+/v7/Gvca9rb3Grcb/xv+1hLWte629hL21e7XG'.
+     'hMbWhNbOe87We9b/hP//e/97OXv/c///a///Y/+cOZz/Sv/WOd'.
+     'bnOefvOe//Kf9jCGNrCGv/EP//CP/nCOf/AP/3APfvAO/nAOfe'.
+     'AN7WANbOAM7GAMa9AL21ALWtAK2lAKWcAJyUAJSMAIyEAIR7AH'.
+     'tzAHNrAGtjAGPP1sZnAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgF'.
+     'HUgAAAAJcEhZcwAACxEAAAsRAX9kX5EAAAAHdElNRQfTAwkUIj'.
+     'mBTjT/AAAASUlEQVR4nGNgQAGskhKsEJaCrJiSuhZYTEFASFlD'.
+     'GyQuqSCnrK6tJwpkiquoamgbGIGYrFpaugbGxmCNunpAljHECB'.
+     'ZBQRZU4wFSMAZsXeM71AAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        // File: bxs_green.png
+        //==========================================================
+        $this->imgdata_xsmall[9][0]= 370 ;
+        $this->imgdata_xsmall[9][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAMAAAC67D+PAAAAn1'.
+     'BMVEX///////+/v7+/v7/G/8aUxpSMvYyUzpSMzoyM1oxarVqE'.
+     '/4R7/3tavVpKnEpaxlpz/3Nr/2tKtUpj/2Na51pKzkpK1kpK50'.
+     'pK/0oYcxgp/ykYlBgY3hgY7xgY9xgQ/xAI/wgA/wAA9wAA7wAA'.
+     '5wAA3gAA1gAAzgAAxgAAvQAAtQAArQAApQAAnAAAlAAAjAAAhA'.
+     'AAewAAcwAAawAAYwA0tyxUAAAAAXRSTlMAQObYZgAAAAFiS0dE'.
+     'AIgFHUgAAAAJcEhZcwAACxEAAAsRAX9kX5EAAAAHdElNRQfTAw'.
+     'kUKBrZxq0HAAAATElEQVR4nGNgQAGccrIcEJaivISyhjaIxa7I'.
+     'I6CiqcMKZMopKqho6OhLA5kyqmqaOobGICartraeoYkJSAGDnj'.
+     '6QZQIxgk1Skg3VeABlVgbItqEBUwAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        // File: bxs_darkgreen.png
+        //==========================================================
+        $this->imgdata_xsmall[10][0]= 563 ;
+        $this->imgdata_xsmall[10][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAMAAAC67D+PAAABX1'.
+     'BMVEX////////l/+nAwMC86r+8wb28wby8wLy78sCzw7SywrSx'.
+     'wLKwvrGuvK+syK+ryq2rx62n36ym3aumxKmk2qij0Keh16ahva'.
+     'Og1aSguKKe06KeuaCetZ+d0KGdtZ+bz6Cay56ZyZ2Zwp2Zr5qZ'.
+     'rpqYwJuXyZuXrJmVw5mUxZiTxJeTw5eTq5WRwJWPtJKOvZKKuI'.
+     '6Kt42Kn4yJt42ItIuGsomFsYmEsIiEr4eDr4eBrIR/qoN+qIJ8'.
+     'poB7pH56o356on14nnt2nXl0mndzmnZzmXZymHVwlXNvlHJukn'.
+     'FtiHBqjm1qjW1oi2toiWpniWplh2hlhmdkhWdig2VggGNgf2Je'.
+     'fmFdfGBde19bbl1aeFxXdFpWclhVclhVcVdUcFZTb1VSbVRQal'.
+     'JPaVFKY0xKYkxJYUtIYEpHX0lEWkZCWERCV0NCVkM/U0A+U0A+'.
+     'UUA+UEA9Uj89UT48Tj45TDvewfrHAAAAAXRSTlMAQObYZgAAAA'.
+     'FiS0dEAIgFHUgAAAAJcEhZcwAACxEAAAsRAX9kX5EAAAAHdElN'.
+     'RQfTAwkUKCFozUQjAAAATUlEQVR4nGNgQAGcoqrcEJYQB5OhSw'.
+     'CIxSXGwWThGcIDZCppK5o7hyV6AZl6NnbuoSmFICZ3YHB0RkkJ'.
+     'SAFDbEJaSUkJxAjeyEheVOMBQj4MOEkWew4AAAAASUVORK5CYI'.
+     'I=' ; 
+
+        //==========================================================
+        // File: bxs_cyan.png
+        //==========================================================
+        $this->imgdata_xsmall[11][0]= 530 ;
+        $this->imgdata_xsmall[11][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAMAAAC67D+PAAABPl'.
+     'BMVEX////////F///AwMCvxsaC1NSC0dGCz8+CzMyA//94//91'.
+     '//9q//9j//9X4uJX09NXz89Xx8dXxMRL//9L5uZL3d1L2NhLxs'.
+     'ZLt7cv//8e9fUe8fEe7u4e398epqYehoYX//8L+PgK//8F9fUE'.
+     '/v4E5+cEb28EZ2cC//8C/v4C/f0CzMwCrq4Cjo4CdXUCaWkCZW'.
+     'UB/PwA//8A/f0A+/sA8/MA7e0A7OwA6+sA5eUA5OQA4uIA4eEA'.
+     '3NwA2toA2NgA1dUA09MA0tIA0NAAysoAxsYAxcUAxMQAv78Avr'.
+     '4AvLwAtrYAtbUAs7MAsLAAra0Aq6sAqKgApaUApKQAoqIAoKAA'.
+     'n58AmpoAlZUAk5MAkpIAkJAAj48AjIwAiYkAh4cAf38AfX0Ae3'.
+     'sAenoAcnIAcHAAa2sAaWkAaGgAYmIUPEuTAAAAAXRSTlMAQObY'.
+     'ZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxEAAAsRAX9kX5EAAA'.
+     'AHdElNRQfTAwkUKQFKuFWqAAAATUlEQVR4nGNgQAGsUjJsEJaR'.
+     'grC5qz9YzIiL28YriB3IlDZRsnYNiZUDMmXtHT2CE9JBTDb/wI'.
+     'jkzEyQAoaomMTMzEyIERzy8hyoxgMAN2MLVPW0f4gAAAAASUVO'.
+     'RK5CYII=' ; 
+
+        //==========================================================
+        // File: bxs_orange.png
+        //==========================================================
+        $this->imgdata_xsmall[12][0]= 572 ;
+        $this->imgdata_xsmall[12][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAMAAAC67D+PAAABaF'.
+     'BMVEX//////////8X/3oD/3nj/1HX/0Gr/xGP/rkv/gBf+iS/2'.
+     'bAL1agDxaQDuZwDrZwLpZQDmZQLlZADjcx7gZATeYQDdZgraXw'.
+     'DZXwHYXgDXiEvXZAvUjlfUXwXTjVfTbR7ShUvRbR7RWwDMWQDL'.
+     'WADKooLKWADJoYLJgkvHWATGoILFn4LFgEvFVgDEZx7EVQDDt6'.
+     '/DVQDCt6/CnoLChlfCVADAwMC+hFe+UgC8UgC6UQC4gVe4UAC3'.
+     'gVe3UAC1gFe1eUu1TwC1TgCzTgCwTQKuTACrSgCqSgCpSgCpSQ'.
+     'CodEulSACkRwCiRgCdRACcRACaQwCYQgCWQgKVQQCVQACUQACS'.
+     'UR6RPwCOPgCNPQCLPACKPACJOwCEOQCBOAB+NwB9NgB8NgB7NQ'.
+     'B6NwJ4NAB3RR52MwB0MgBuLwBtLwBsLwBqLgBpLQBkLQJiKgBh'.
+     'KgBgKwRcKABbKQJbJwBaKQRaJwBYKAJVJQDZvdIYAAAAAXRSTl'.
+     'MAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxEAAAsRAX9k'.
+     'X5EAAAAHdElNRQfTAwkUJBSSy88MAAAATUlEQVR4nGNgQAGqwo'.
+     'paEBYPJ4eKezCIpc7HwmrqG6ENZMpLihm6RaWEAZl6Vo7ekRnF'.
+     'IKZWSHhcTnk5SAFDfFJWeXk5xAjj1FRjVOMBeFwNcWYSLjsAAA'.
+     'AASUVORK5CYII=' ; 
+
+        //==========================================================
+        // File: bxs_lightblue.png
+        //==========================================================
+        $this->imgdata_xsmall[13][0]= 554 ;
+        $this->imgdata_xsmall[13][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAMAAAC67D+PAAABVl'.
+     'BMVEX////////d///AwMC7wcS08P+y+P+xxdCwxM+uws2twMur'.
+     'vsinzNynytylzuKhyN6e5v6d5P+d1fOcwNWcu8ub4f+at8iZ3v'.
+     '+ZvdGY2/yW2f+VscGU1vuT1fqTr72Sx+SSxeKR0fWRz/GPz/OP'.
+     'rr+OyeqMy+6Myu2LyeyKxueJudSGw+SGorGDvt+Cvd6CvN2Aud'.
+     'p+uNd+t9Z9tdV8tdR8tNN6sc94r813rct2q8h0qcZ0qMVzp8Rx'.
+     'o8Bwor5tn7ptnrptnrlsnbhqmbRpmbNpi51ol7Flkqtkkqtkka'.
+     'pjj6hijaRhjaZgi6NfiqJfiaFdh55bhJtag5pZgphYgJZYf5VX'.
+     'cn9Ve5FSeI1RdopRdYlQdYlPc4dPcoZPcoVNcINLboBLbH9GZn'.
+     'hGZXdFZHZEY3RDYnJCXW4/W2s/WWg+Wmo7VmU7VGM7U2E6VGM6'.
+     'VGI5UV82T1wGxheQAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHU'.
+     'gAAAAJcEhZcwAACxEAAAsRAX9kX5EAAAAHdElNRQfTAwkUJziL'.
+     'PvAsAAAATUlEQVR4nGNgQAHsQgqcEJYgG5Oegy+IxSHOxmTiFs'.
+     'gFZMprKBnbB8e7AplaFlbOQUl5ICanX0BEWmEhSAFDVGxKYWEh'.
+     'xAjusDBuVOMBJO8LrFHRAykAAAAASUVORK5CYII=' ; 
+
+        //==========================================================
+        // File: bxs_darkgray.png
+        //==========================================================
+        $this->imgdata_xsmall[14][0]= 574 ;
+        $this->imgdata_xsmall[14][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAYAAACNMs+9AAAABm'.
+     'JLR0QAAAAAAAD5Q7t/AAAACXBIWXMAAAsRAAALEQF/ZF+RAAAB'.
+     'iElEQVR42k3QPU8TYRwA8P//ebkXrgdIColXRAOEkJqbaExMut'.
+     'DBhE1GNjYHPg+DG6ODiU6QOLjVxITBcFKBYCstlAC2Bz17fe76'.
+     'vLD6+wg/1FpTRFR5lpaub/u1eGBGaAT4HneD4OlXx7avtDYUjT'.
+     'HQabd2Ti8e3vVSKzxrtHS32wIpFVldno22Nqvvg2Bhl0gp/aNm'.
+     'vJ3qqXAtLIva+ks1H0wqlSXi4+d6+OFTfRsAfHJx2d1od24rZP'.
+     'xP2HzopINr1mkesX7ccojqif0v9crxWXODZTno3+dNGA7uWLsd'.
+     'mUYU4fHJCViMG9umLBmM4L6fagZGg9QKfjZ+Qfy3C3G/B3mugF'.
+     'IHHNcDf64E3KJALApk2p8CSolUUqLjFkyxOGMsTtFyJ+Wz57NQ'.
+     '8DghS4sLB0svioeZZo7nPhFoUKZDIVFbglkTTnl5/rC8snjAkJ'.
+     'Bk/XV5LxHC/v7tR8jzTFPbg8LENK9WX0Vv31T2AEmCSmlKCCoh'.
+     'ROnP1U1tPFYjJBRcbtzSf+GPsFTAQBq1n4AAAABKdEVYdHNpZ2'.
+     '5hdHVyZQBiYzYyMDIyNjgwYThjODMyMmUxNjk0NWUzZjljOGFh'.
+     'N2VmZWFhMjA4OTE2ZjkwOTdhZWE1MzYyMjk0MWRkM2I5EqaPDA'.
+     'AAAABJRU5ErkJggg==' ; 
+    }
+}
+
+?>
diff --git a/web/classes/jpgraph/imgdata_bevels.inc.php b/web/classes/jpgraph/imgdata_bevels.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..c98fa571f2148c6f562192fc6bde7b5d43c831d2
--- /dev/null
+++ b/web/classes/jpgraph/imgdata_bevels.inc.php
@@ -0,0 +1,104 @@
+<?php
+//=======================================================================
+// File:        IMGDATA_BEVELS.INC
+// Description: Base64 encoded images for round bevels
+// Created:     2003-03-20
+// Ver:         $Id: imgdata_bevels.inc.php 1106 2009-02-22 20:16:35Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+class ImgData_Bevels extends ImgData {
+    protected $name = 'Round Bevels';
+    protected $an = array(MARK_IMG_BEVEL => 'imgdata');
+
+    protected $colors = array('green','purple','orange','red','yellow');
+    protected $index  = array('green'=>1,'purple'=>4,'orange'=>2,'red'=>0,'yellow'=>3);
+    protected $maxidx = 4 ;
+
+    protected $imgdata ;
+
+    function __construct() {
+        //==========================================================
+        // File: bullets_balls_red_013.png
+        //==========================================================
+        $this->imgdata[0][0]= 337 ;
+        $this->imgdata[0][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAAAM1'.
+     'BMVEX////////27t/f3+LFwcmNxMuxm62DmqKth1VpZmIWg6fv'.
+     'HCa7K0BwMEytCjFnIyUlEBg9vhQvAAAAAXRSTlMAQObYZgAAAA'.
+     'FiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElN'.
+     'RQfTAxcBNhk+pYJVAAAAl0lEQVR4nE2Q2xLDIAgFHUWBKJf//9'.
+     'oekmbafVDZARRbK/pYTKP9WNcNv64zzUdd9BjmrgnsVXRNSzO3'.
+     'CJ5ahdhy0XKQkxld1kxb45j7dp0x2lBNOyVgQpMaoadX7Hs7zr'.
+     'P1yKj47DKBnKaBKiSAkNss7O6PkMx6kIgYXISQJpcZCqdY6KR+'.
+     'J1PkS5Xob/h7MNz8x6D3fz5DKQjpkZOBYAAAAABJRU5ErkJggg'.
+     '==' ; 
+
+        //==========================================================
+        // File: bullets_balls_green_013.png
+        //==========================================================
+        $this->imgdata[1][0]= 344 ;
+        $this->imgdata[1][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAAAM1'.
+     'BMVEX////////27t/e3+K3vriUub/Dm18j4xc3ob10k0ItqQlU'.
+     'e5JBmwpxY1ENaKBgUh0iHgwsSre9AAAAAXRSTlMAQObYZgAAAA'.
+     'FiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElN'.
+     'RQfTAxcBNTfJXtxZAAAAnklEQVR4nE2QWY4EMQhDUVhSIRC4/2'.
+     'kbaqLp9p+f2AxAayAzDfiK9znPORuvH0x8Ss9z6I9sHp6tcxE9'.
+     'nLmWmebmt5F5p2AR0+C9AWpLBjXRaZsCAT3SqklVp0YkAWaGtd'.
+     'c5Z41/STYpPzW7BjyiRrwkVmQto/Cw9tNEMvsgcekyCyFPboIu'.
+     'IsuXiKffYB4NK4r/h6d4g9HPPwCR7i8+GscIiiaonUAAAAAASU'.
+     'VORK5CYII=' ; 
+
+        //==========================================================
+        // File: bullets_balls_oy_035.png
+        //==========================================================
+        $this->imgdata[2][0]= 341 ;
+        $this->imgdata[2][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAAAM1'.
+     'BMVEX////////27t/f3+K5tbqNwcjnkjXjbxR2i5anfEoNkbis'.
+     'PBxpU0sZbZejKgdqIRIlERIwYtkYAAAAAXRSTlMAQObYZgAAAA'.
+     'FiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElN'.
+     'RQfTAxcBNgK0wEu5AAAAm0lEQVR4nE3QVxIEIQgEUErAgTHA/U'.
+     '+7zbipf9RXgoGo0liMmX6RdSPLPtZM9F4LuuSIaZtZWffiU6Iz'.
+     'Y8SOMF0NogBj30ioGRGLZgiPvce1TbIRz6oBQEbOFGK0rIoxrn'.
+     '5hDomMA1cfGRCaRVhjS3gkzheM+4HtnlkXcvdZhWG4qZawewe6'.
+     '9Jnz/TKLB/ML6HUepn//QczazuwFO/0Ivpolhi4AAAAASUVORK'.
+     '5CYII=' ; 
+
+        //==========================================================
+        // File: bullets_balls_oy_036.png
+        //==========================================================
+        $this->imgdata[3][0]= 340 ;
+        $this->imgdata[3][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAAAM1'.
+     'BMVEX////////27t/e3+LO3hfYzz65ubiNwci6uQ12ipadgVGa'.
+     'fwsNkbhnVkcaZ5dwSA8lFg7CEepmAAAAAXRSTlMAQObYZgAAAA'.
+     'FiS0dEAIgFHUgAAAAJcEhZcwAACxEAAAsRAX9kX5EAAAAHdElN'.
+     'RQfTAxcCBySi1nevAAAAjElEQVR4nFXPWw7EIAgFUNMoCMhj/6'.
+     'staKczc/2RkwjS2glQ+w3YytgXCXCZpRo8gJdGxZadJws13CUP'.
+     '4SZI4MYiUxypeiGGw1XShVBTNN9kLXP2GRrZPFvKgd7z/sqGGV'.
+     '7C7r7r3l09alYN3iA8Yn+ImdVrNoEeSRqJPAaHfhZzLYwXstdZ'.
+     'rP3n2bvdAI4INwtihiwAAAAASUVORK5CYII=' ;
+
+        //==========================================================
+        // File: bullets_balls_pp_019.png
+        //==========================================================
+        $this->imgdata[4][0]= 334 ;
+        $this->imgdata[4][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABEAAAARCAMAAAAMs7fIAAAAM1'.
+     'BMVEX////+/v7i4eO/w8eHxcvKroNVormtfkjrMN2BeXQrepPc'.
+     'Esy4IL+OFaR7F25LHF8mFRh5XXtUAAAAAXRSTlMAQObYZgAAAA'.
+     'FiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElN'.
+     'RQfTAxcBNgkjEpIxAAAAlElEQVR4nE2QAQ7FIAhDDTAVndL7n3'.
+     'ZV/7JfEwMvFIWUlkTMVNInbVv5ZeJqG7Smh2QTBwJBpsdizAZP'.
+     '5NyW0awhK8kYodnZxS6ECvPRp2sI+y7PBv1mN02KH7h77QCJ8D'.
+     '4VvY5NUgEmCwj6ZMzHtJRgRSXwC1gfcqJJH0GBnSnK1kUQ72DY'.
+     'CPBv+MCS/e0jib77eQAJxwiEWm7hFwAAAABJRU5ErkJggg==' ; 
+
+    }
+}
+
+
+?>
diff --git a/web/classes/jpgraph/imgdata_diamonds.inc.php b/web/classes/jpgraph/imgdata_diamonds.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..a0d6a4215eb07ff52c95aa795fe67e64a95ed4e7
--- /dev/null
+++ b/web/classes/jpgraph/imgdata_diamonds.inc.php
@@ -0,0 +1,177 @@
+<?php
+//=======================================================================
+// File:        IMGDATA_DIAMONDS.INC
+// Description: Base64 encoded images for diamonds
+// Created:     2003-03-20
+// Ver:         $Id: imgdata_diamonds.inc.php 1106 2009-02-22 20:16:35Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+class ImgData_Diamonds extends ImgData {
+    protected $name = 'Diamonds';
+    protected $an = array(MARK_IMG_DIAMOND =>'imgdata');
+    protected $colors = array('lightblue','darkblue','gray',
+   'blue','pink','purple','red','yellow');
+    protected $index  = array('lightblue' =>7,'darkblue'=>2,'gray'=>6,
+   'blue'=>4,'pink'=>1,'purple'=>5,'red'=>0,'yellow'=>3);
+
+    protected $maxidx = 7 ;
+    protected $imgdata ;
+
+    function __construct() {
+        //==========================================================
+        // File: diam_red.png
+        //==========================================================
+        $this->imgdata[0][0]= 668 ;
+        $this->imgdata[0][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABsAAAAbCAMAAAC6CgRnAAAA/F'.
+     'BMVEX///////+cAAD/AADOAABjAABrAADWGBjOCAj/CAj/GBj/'.
+     'EBCcCAiMOTl7KSl7ISFzGBilGBjOEBBrCAjv5+eMQkK1QkKtMT'.
+     'GtKSnWKSn/KSlzEBCcEBDexsb/tbXOe3ucWlqcUlKUSkr/e3vn'.
+     'a2u9UlL/a2uEMTHeUlLeSkqtOTn/UlL/SkrWOTn/QkL/OTmlIS'.
+     'H/MTH/ISH39/f/9/f35+fezs7/5+fvzs7WtbXOra3nvb3/zs7G'.
+     'nJzvtbXGlJTepaW9jIy1hITWlJS1e3uta2ulY2P/lJTnhITne3'.
+     'vGY2O9Wlr/c3PeY2O1Skr/Y2P/WlreQkLWISGlEBCglEUaAAAA'.
+     'AXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxIAAA'.
+     'sSAdLdfvwAAAAHdElNRQfTAwsWEw5WI4qnAAABGUlEQVR4nHXQ'.
+     '1XLDMBAFUKUCM1NiO8zcpIxpp8z0//9SWY7b2LHv6EU6s1qtAN'.
+     'iMBAojLPkigpJvogKC4pxDuQipjanlICXof1RQDkYEF21mKIfg'.
+     '/GGKtjAmOKt9oSyuCU7OhyiDCQnjowGfRnooCJIkiWJvv8NxnG'.
+     'nyNAwFcekvZpPP3mu7Vrp8fOq8DYbTyjdnAvBj7Jbd7nP95urs'.
+     '+MC2D6unF+Cu0VJULQBAlsOQuueN3Hrp2nGUvqppemBZ0aU7Se'.
+     'SXvYZFMKaLJn7MH3btJmZEMEmGSOreqy0SI/4ffo3uiUOYEACy'.
+     'OFopmNWlP5uZd9uPWmUoxvK9ilO9NtBo6mS7KkZD0fOJYqgGBU'.
+     'S/T7OKCAA9tfsFOicXcbxt29cAAAAASUVORK5CYII=' ; 
+
+        //==========================================================
+        // File: diam_pink.png
+        //==========================================================
+        $this->imgdata[1][0]= 262 ;
+        $this->imgdata[1][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABsAAAAbBAMAAAB/+ulmAAAAEl'.
+     'BMVEX///+AgID/M5n/Zpn/zMz/mZn1xELhAAAAAXRSTlMAQObY'.
+     'ZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAA'.
+     'AHdElNRQfTAwsWEi3tX8qUAAAAbUlEQVR4nFXJwQ3AMAhDUdRm'.
+     'kKojuCswABf2X6UEEiC+WF+PyDfoGEuvwXogq3Rk1Y6W0tBSG8'.
+     '6Uwpla6CmJnpoYKRsjjb/Y63vo9kIkLcZCCsbGYGwMRqIzEp1R'.
+     'OBmFk9HQGA2N0ZEIz5HX+h/jailYpfz4dAAAAABJRU5ErkJggg'.
+     '==' ; 
+
+        //==========================================================
+        // File: diam_blue.png
+        //==========================================================
+        $this->imgdata[2][0]= 662 ;
+        $this->imgdata[2][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABsAAAAbCAMAAAC6CgRnAAAA+V'.
+     'BMVEX///+AgIAAAJwAAP8AAM4AAGMAAGsQEP8YGHMQEHMYGP8Q'.
+     'EKUICJwICM5KSpQxMYQpKXsYGNYQEM4ICGsICP97e85aWpw5OY'.
+     'xSUv85ObVCQt4xMa0pKa0hIaUpKf+9vd6EhLVra+dzc/9SUr1r'.
+     'a/9aWt5SUt5CQrVaWv9KSv8hIXs5Of8xMf8pKdYhIdYYGKUhIf'.
+     '/Ozs739//v7/fn5+/v7//n5/fW1ufOzufOzu/W1v+trc69veel'.
+     'pc6trd6UlMa9vf+MjL21tfe1tf+UlNZzc61ra6Wlpf+EhOeMjP'.
+     '9ra8ZSUpyEhP9CQoxKSrVCQv85Od4xMdYQENZnJhlWAAAAAXRS'.
+     'TlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAd'.
+     'LdfvwAAAAHdElNRQfTAwsWEx3Snct5AAABFklEQVR4nHXR5XbD'.
+     'IBgGYM6AuHsaqbvOfeuknev9X8xISbplSd5/8JyXwwcA/I0AKm'.
+     'PFchVBdvKNKggKQx2VIoRwMZihMiQE49YUlWBCcPL0hYq4ITh+'.
+     'qKECUoLDZWqoQNA766F/mJHlHXblPJJNiyURhM5eU9cNw5BlmS'.
+     'IrLOLxhzfotF7vwO2j3ez2ap/TmW4AIM7DoN9+tu+vLk6Pdg9O'.
+     '6ufXjfXLm6pxPACSJIpRFAa+/26DhuK6qjbiON40k0N3skjOvm'.
+     'NijBmchF5mi+1jhQqDmWyIzPp1hUlrv8On5l+6mMm1tigFNyrt'.
+     '5R97g+FKKyGKkTNKesXPJTZXOFIrUoKiypcTQVHjK4g8H2dWEQ'.
+     'B8bvUDLSQXSr41rmEAAAAASUVORK5CYII=' ; 
+
+        //==========================================================
+        // File: diam_yellow.png
+        //==========================================================
+        $this->imgdata[3][0]= 262 ;
+        $this->imgdata[3][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABsAAAAbBAMAAAB/+ulmAAAAEl'.
+     'BMVEX///+AgIBmMwCZZgD/zADMmQD/QLMZAAAAAXRSTlMAQObY'.
+     'ZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAA'.
+     'AHdElNRQfTAwsWEwcv/zIDAAAAbUlEQVR4nFXJwQ3AMAhDUdRm'.
+     'kKojuCswABf2X6UEEiC+WF+PyDfoGEuvwXogq3Rk1Y6W0tBSG8'.
+     '6Uwpla6CmJnpoYKRsjjb/Y63vo9kIkLcZCCsbGYGwMRqIzEp1R'.
+     'OBmFk9HQGA2N0ZEIz5HX+h/jailYpfz4dAAAAABJRU5ErkJggg'.
+     '==' ; 
+
+        //==========================================================
+        // File: diam_lightblue.png
+        //==========================================================
+        $this->imgdata[4][0]= 671 ;
+        $this->imgdata[4][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABsAAAAbCAMAAAC6CgRnAAAA/1'.
+     'BMVEX///+AgIAAnP8A//8Azv8AY/8Aa/8I//8Y1v8Izv8Y//8Q'.
+     '//8InP8Qzv8Ypf85jP8he/8Yc/8Ia/8pe/8p//8p1v9Ctf8xrf'.
+     '8prf8QnP8Qc/9CjP+1//97//9r//9S//9K//9C//85//8x//8h'.
+     '//9r5/9K3v9S3v851v97zv9Svf85rf8hpf/G3v9SnP9anP9KlP'.
+     '8xhP/n7//v7+f3///n///O//+U//9z//9j//9a//975/9C3v8h'.
+     '1v+E5/+17/9j3v/O7//n9/+95/+l3v9jxv+U1v8Qpf9avf9Ktf'.
+     '+Uxv+11v97tf9rrf+cxv+Mvf9jpf+tzv+Etf/O3v/39/8Akkxr'.
+     'AAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACx'.
+     'IAAAsSAdLdfvwAAAAHdElNRQfTAwsWEiHk6Ya/AAABGUlEQVR4'.
+     'nHXQ13KDMBAF0J2o0E01GHDvJa7p3em95/+/JQJMYjDc0Yt0Zr'.
+     'VaAaxHgtxwbSGPkGQpOIeQ2ORxJiJmNWYZyAhZR0WcgQGhViU0'.
+     'nEGoedDHGxgRapRPcRpXhOr7XZzCmLjaXk9IIjvkOEmSRLG62+'.
+     'F5XlEElhA5sW21GvXj6mGlDBfnJ51lr9svnvEKwH1hu2QPbwd3'.
+     'N9eXVzuL7/Hn29frdKaamgcgy67L3HFG9gDefV+dm5qme4YRXL'.
+     'oVR374mRqUELZYosf84XAxISFRQuMh4rrH8YxGSP6HX6H97NNQ'.
+     'KEAaR08qCeuSnx2a8zIPWqUowtKHSRK91rAw0elmVYQFVc8mhq'.
+     '7p5RD7Ps3IIwA9sfsFxFUX6eZ4Zh4AAAAASUVORK5CYII=' ; 
+
+        //==========================================================
+        // File: diam_purple.png
+        //==========================================================
+        $this->imgdata[5][0]= 657 ;
+        $this->imgdata[5][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABsAAAAbCAMAAAC6CgRnAAAA/F'.
+     'BMVEX///////8xAP/OAP+cAP9jAP9rAP+cCP85CP/OEP9SKf/O'.
+     'CP9CEP9zGP9rCP+lGP/WOf/WIf9KIf9jOf+MQv+EMf97If9zEP'.
+     '+1Sv+lIf/ne//eUv/na//n5//Oxv/Wzv+chP9zUv97Wv9rQv9a'.
+     'Mf9KGP/v5/+te/97Kf+9Y/+tOf+tKf+lEP/vtf/WMf/WKf/v7+'.
+     'f39/+tnP+9rf9rSv9jQv9CGP+ljP+EY//Gtf+tlP+Ma/9zSv/e'.
+     'zv+UUv+9lP+cWv+lY/+cUv+MOf+EKf+UQv/Opf/OhP/Ga/+1Qv'.
+     '/Oe/+9Uv/ntf/eWv/eSv/WGP/3zv/vlP/WEP//9/+pL4oHAAAA'.
+     'AXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxIAAA'.
+     'sSAdLdfvwAAAAHdElNRQfTAwsWEjX+M1LCAAABDklEQVR4nHXQ'.
+     '1bLDIBAGYFqIEW+ksbr7cXd3ff93OUCamdOE/Mxw882yywLwPz'.
+     '+gNKotlRFUVnNUQlCxTMRFCKEdE+MgpJaEiIOU4DKaoSIygtb3'.
+     'FBUQrm3xjPK4JvXjK0A5hFniYSBtIilQVYUm+X0KTVNiYah+2q'.
+     'ulFb8nUbSovD2+TCavwXQWmnMA6ro+di+uR5cPzfPhVqPV3N1p'.
+     'n3b3+rimAWAYhP3xnXd7P6oc9vadPsa1wYEs00dFQRAFehlX21'.
+     '25Sg9NOgwF5jeNTjVL9om0TjDc1lmeCKZ17nFPzhPtSRt6J06R'.
+     'WKUoeG3MoXRa/wjLHGLodwZcotPqjsYngnWslRBZH91hWTbpD2'.
+     'EdF1ECWW1SAAAAAElFTkSuQmCC' ; 
+
+        //==========================================================
+        // File: diam_gray.png
+        //==========================================================
+        $this->imgdata[6][0]= 262 ;
+        $this->imgdata[6][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABsAAAAbBAMAAAB/+ulmAAAAEl'.
+     'BMVEX//////wAzMzNmZmbMzMyZmZlq4Qo5AAAAAXRSTlMAQObY'.
+     'ZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAA'.
+     'AHdElNRQfTAwsWExZFTxLxAAAAbUlEQVR4nFXJwQ3AMAhDUdRm'.
+     'kKojuCswABf2X6UEEiC+WF+PyDfoGEuvwXogq3Rk1Y6W0tBSG8'.
+     '6Uwpla6CmJnpoYKRsjjb/Y63vo9kIkLcZCCsbGYGwMRqIzEp1R'.
+     'OBmFk9HQGA2N0ZEIz5HX+h/jailYpfz4dAAAAABJRU5ErkJggg'.
+     '==' ; 
+
+        //==========================================================
+        // File: diam_blgr.png
+        //==========================================================
+        $this->imgdata[7][0]= 262 ;
+        $this->imgdata[7][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABsAAAAbBAMAAAB/+ulmAAAAEl'.
+     'BMVEX///+AgIBmzP9m///M//+Z//8hMmBVAAAAAXRSTlMAQObY'.
+     'ZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAA'.
+     'AHdElNRQfTAwsWEwCxm6egAAAAbUlEQVR4nFXJwQ3AMAhDUdRm'.
+     'kKojuCswABf2X6UEEiC+WF+PyDfoGEuvwXogq3Rk1Y6W0tBSG8'.
+     '6Uwpla6CmJnpoYKRsjjb/Y63vo9kIkLcZCCsbGYGwMRqIzEp1R'.
+     'OBmFk9HQGA2N0ZEIz5HX+h/jailYpfz4dAAAAABJRU5ErkJggg'.
+     '==' ; 
+    }
+}
+
+?>
diff --git a/web/classes/jpgraph/imgdata_pushpins.inc.php b/web/classes/jpgraph/imgdata_pushpins.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..e59b7427bcb6f51befced8cac407609793ab20c7
--- /dev/null
+++ b/web/classes/jpgraph/imgdata_pushpins.inc.php
@@ -0,0 +1,517 @@
+<?php
+//=======================================================================
+// File: IMGDATA_PUSHPINS.INC
+// Description: Base64 encoded images for pushpins
+// Created:  2003-03-20
+// Ver:  $Id: imgdata_pushpins.inc.php 1106 2009-02-22 20:16:35Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+class ImgData_PushPins extends ImgData {
+    protected $name = 'Push pins';
+    protected $an = array(MARK_IMG_PUSHPIN => 'imgdata_small',
+    MARK_IMG_SPUSHPIN => 'imgdata_small',
+    MARK_IMG_LPUSHPIN => 'imgdata_large');
+
+    protected $colors = array('blue','green','orange','pink','red');
+    protected $index  = array('red' => 0, 'orange' => 1, 'pink' => 2, 'blue' => 3, 'green' => 4 ) ;
+    protected $maxidx = 4 ;
+    protected $imgdata_large, $imgdata_small ;
+
+    function __construct() {
+
+        // The anchor should be where the needle "hits" the paper
+        // (bottom left corner)
+        $this->anchor_x = 0;
+        $this->anchor_y = 1;
+
+        //==========================================================
+        // File: ppl_red.png
+        //==========================================================
+        $this->imgdata_large[0][0]= 2490 ;
+        $this->imgdata_large[0][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAACgAAAAoCAYAAACM/rhtAAAABm'.
+     'JLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsRAAALEQF/ZF+RAAAA'.
+     'B3RJTUUH0wMKBh4Ryh89CgAACUdJREFUeJy9mNtTFFcexz+/7p'.
+     '4Lw1wZJKDGCAwmDAqUySamcCq1ed6k9mn3UfMP7F+1T3nYqn2J'.
+     'lZdoDEjpbq0KG8EBFBFBEJye6Zmenkv32Ydu5GYiUMmeqq6uqT'.
+     '6Xz3zP73aOcIKmAQkIFyD3N/jrBPwlKjLQEglVlJKyUjR3u7cc'.
+     'WLoP3/4dvv03LNrQ8I6x1rFbDML9kOmHvh7IRHU9JKmUSG8vpF'.
+     'IoXX/TV0AiEM5A5jT0noFMFMJHXUt/d5f9TUAbhtQ3cPFruDog'.
+     '8klHMnmO0dGYe/myOJGINEwTz3F2higFXgy8PpAkOC+h8hoaCt'.
+     '4ppHFcQAWSgOQlyI/p+lUjmRxWAwNJd3xca/f34yoFi4tgmjtD'.
+     'NIFkJ4xcgBCgVqEBFJ9DqcZea/gNAAVEg7AOGYnHe9XoaJd3+X'.
+     'LISSSwnz6lsbKCZ9sHh4UVdBkwdA6cPwNnIfJPmC3Ctgft3wwQ'.
+     'QPkvTZJJnbExzfvsM2nMzVG7e5fG48d4lnXwTwEYCjJxuHQBog'.
+     'BHUfKkgAIIhiGk06hTp/Dm5qS1uYlXLvtWd4gPgIiCrAEcVckT'.
+     'Ab5p7TaYJrK1hQaEenrwSiVfQdc91P0kSp7Ii89D5ksY/kAkLy'.
+     'IZXFdXkQjS1YUSEbdcRu168V6+HTUNIKJDRwdE+sBIQmP9Ld59'.
+     'bEBA3of4F/D+uXb7rGaaCSmXI3pPj64PDaHCYfEqFVSjgWo2D2'.
+     '73XlJNQTgCyQykIuBWoNKEeh1aLXBPBCggGdBOgxZVSjoajVhH'.
+     'o5HWlIpq4bCQSgm9vXhK4ZZKh5SUYygp4J1EQVUD9xlU18BJQD'.
+     'bUbJ5T5XJStyxN9fSI099P3baxV1dRloW2h2ivx/yakg2ot6F1'.
+     'EkCa4G1D+zVEq5ArKTWM42Q6HUczQV7U66w9e0ZpdRXlOIQ5vF'.
+     'VHUXILKify4jiEzkOqC3peQMoBQymFlMt4Dx6wUSxSsm2UZXEK'.
+     'P30QvOUt8/2Sd78CdWwFDTA+gsw3cOlPcPUD+CQB52oQ21RKXM'.
+     'eRhGXhOg7VoKrx8KuS4ygZhVg3ZI8FGIfwR9BVgAtfwxdXdP3L'.
+     '86nUR91dXelNXTeWWy10paQHX602YAP1ADASAL7LJvFtMpOCc0'.
+     'cG3FHuGlz6Gr4YEpnoTCbzsdHRbOzy5RCRiLRMk5rjyOtAimwA'.
+     'U4U3SurBN/0wnAASBCVDIKpB4kiAB5Ub0/UvO9LpPAMDGfn005'.
+     'AxPCzxep3Q6iqPLUseBoufCZRsAE6g5g5kKIDfKUj3wnpAG8QB'.
+     '/Z1OIqANQuI65AtwNScyYXR2XlAXL2YZHzcklRKWl5GVFXFtGx'.
+     'MoAiV/EQaAGH6BUQNWgQpwFngv+Ca8KUAQEBcwgTJHyMV7679R'.
+     'XS8YqdSI6u/PMD5ukMtJY3GR2uQkr5aXeWVZOEALmA8WsIAxfL'.
+     'd0goVLAdCOd+/YpgqeVtBv4yiA++q/RKKXixe7GB8PSyoljcVF'.
+     'yg8fyubyMpulEk2lyAIfAAvAC+B+oOQFoAt/+0rAejB/EzjNri'.
+     'vvqNnCd64jxcE39V8spnP+vMbAgDSePKE2NcXm06dslMuUlcID'.
+     'TuFvqwXMBU8N39bGgRR+ki0Dz4L5DSAe9NGD7zq+6kcN1L6H2b'.
+     'ao5WWaQHllRTafPmWrVMJUimoAQrBYJFjQwre7B6A8YAi8LCgD'.
+     '5DVo6/hbb/iHK1KggvFeD3hHziQKEMuiNTNDbXGRTdtmw7Iwla'.
+     'KGH0oqwbscLOoG46rAY6AOzRhY74PT6QuUKEN4PegXxd/yEDTT'.
+     'YMWOk+oEaLkuFdNk0zTZwjfkavDUArXWgGXgFb4dEShXhfYqlI'.
+     'ow3w9rg3B6ED60IOOA5oEYQBrcpG+mj9bg0VG8GMJhVDZLyzAo'.
+     'VSq8rFYxXXefcjVgG9+uisDrXUCApoKSBcUHMBmHhfcgNwhtD3'.
+     'q9IG6Lr15b4OUTmPwBJt8JqGuapp05o0mhoHnptLQfPsR+8IBK'.
+     'uYyNH3yr+B77LHheA3tK1Ta+IrMeTL2C6Xl48TOsNWDDgAz7s5'.
+     '/r+krP/eddCsbj8fDQ4GBm9MqVvvRXX2VULBayRGRzaYn1SoWa'.
+     'UjgB4PIB5QK4ZgBXBKaAHxQsrED1H7CRgCUPwgHZDqACmhWwXv'.
+     '2aDRqGYeRyufS169cvThQKV88PDuYbW1vJ5VRK+5euqxWlPMdX'.
+     'SRqgreHbZGN3ijfKBXBTAeh2Fdwi2MofshP/dvKwCmKhp4m83Y'.
+     'vj8Xg4l8tlCoXC0MTExMTFkZE/1m37wvLGRvKRacoD1209E7Fc'.
+     'pZwYREOQqEJ4z3HskHLsz4AoXykPIBSN0t3dTTQafROoHdumXC'.
+     '4fjoMiog0ODiauX7+eLxQKV3O53ETdti88nJnJ3rl505ifmWm3'.
+     'arWSodR8GNbycDoNHy5C5jFold1k8d+DyvELNwg93d18/vnn9P'.
+     'X1oes6nufx/Plz7t+/fxhQKSWJRCI5NjaWHxkZKdj1+sjSwkJm'.
+     '+uZN/dZ337VqCwullGUVdZjsgIUC5LqhrUPvCugWuApeApPAzY'.
+     'PKHWyaphGNRunt7WVwcBARwfM8Ojo6sCzrMKBhGLphGFEF2Wq1'.
+     '2jc7M5OZ/vHH0MPbt93awkJJmeZsC6ZaMK3DCwvWdNioQUb5B6'.
+     'AdBR+9SzkAz/NwHIeXL18iIui6TjgcJplMMjY2th8wHo+Hh4aG'.
+     'MsPDw6fddru7+Phxx51bt/RbN260qwsLpZhlFZsw9QJ+2Pbrga'.
+     'oJG2FY2oKwuTtVEz9uV34NbqdtbW0xPT1NNBoF4MyZM1y5coWu'.
+     'rq5dQBHRcrlc4tq1a/l8Pj9RMs38ndu3Ez//9JNXLRZNyuXZJk'.
+     'xVYKoExQpsK/+IaAuYb7no8zjC/R+A4zisrq7u+53NZjl16tQ+'.
+     'QIlEIslsNpuPRCJXZ2dnh2/duNFRW1oy07a96MKd575yxRqU1B'.
+     '5vPMpF5HHa1tYW9+7do7Ozc/eQpZTSQ6FQt1Lq8pMnT/5w7969'.
+     'nuLcXE1rNufO9fRMhlKpOyvt9qPtVmvb25fFfvvWbrepVCqHwo'.
+     'xaX19vff/996ZhGC8qlkW9Wt1Onz073fXxxz+6MB+9e9dUjuO+'.
+     '7ebq9wLdB9hoNCrr6+s/4wf3FCJW3fPmTZhXsNWCprjuW66Dfr'.
+     '928KAfBhJAEgiJSLuzs7OSTqctoFkqlZRt26j/I+L/AGjPTN4d'.
+     'Nqn4AAAAAElFTkSuQmCC' ; 
+
+        //==========================================================
+        // File: ppl_orange.png
+        //==========================================================
+        $this->imgdata_large[1][0]= 2753 ;
+        $this->imgdata_large[1][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAACgAAAAoCAYAAACM/rhtAAAABm'.
+     'JLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsRAAALEQF/ZF+RAAAA'.
+     'B3RJTUUH0wMLFQ0VCkHCzQAACk5JREFUeJytmGtzG0d2hp8zNw'.
+     'AEcRdJ6EJK9FL0CqZUm9jWbkwq3vhDstl8dmLvz8rP2H8Q75ZT'.
+     'pkRfpLgqsS6WIFEKGYkiSBCDO+banQ8DUpRWEkklXQUUqlCDfv'.
+     'rp857pgfAOQ4AMOJdg4R/hX96Hf06bvDc5iT07i8yeg8ksiIAI'.
+     '4TBi/ds9/vivD/njapNHvRBfHXMu410AM+BUoVSF05NQsi1sO4'.
+     '8402AXwLQTuP31OAZO2aG0MEn14iSlnI1z3LnMk8IZYJyBwjIs'.
+     '/TWsVIWPJkvMFS4zMfMhUp5BsoCpAAEBLYKaMFGn00jBxnvu02'.
+     '35+JHmSJEnBpQEcPo38MmCxd/nS9Ry71Ga/g1W9a8gn0GsHkgA'.
+     '6DGjxkqb5CoO+YxF3A3p+jGjQUzoK+L/V0ADzFMwtSR8eLbAr8'.
+     'uXOTf9NzhTc0geSLUQcYHgYEH786RMg0zWJHV2Aitv4x/HpHVS'.
+     'QA2YBqTTGIUq5qkPMWaWkVwPnPtAA/BevmZcjxaaUtHh8pJJGu'.
+     'DpCB9FvT7A7YT7S3p5vFMNzmWo/O0MSx/Ms3TqI8r59zFTfUQe'.
+     'I7SBODE3tnfoIxYnNHligwik0zAzDdVpyKbA8sff5YAeMEwgkV'.
+     'cufQeTJzZoCsaFLKXPTnNpoUTNsSgJmNoGsuNQjIDwYD2HlnZy'.
+     'k++yxTKXZfKTU8zOpjhneeQYkorSmGERtIlICBKRbLX+y98YN3'.
+     'ADcNIm+bJD4U3pPnmbEaRgYVRTGBkDSSsmxKfY7ZLuDJA4hdjl'.
+     'JEgyBB2SJOvQ9RzTpNKoEwNq0CNFvOXR3/HxMgYVPObaz8kPmh'.
+     'hkEWMatAfRONGGvLizyOE9P8KkpwhPDAgQKJQbELUD0oOIhbbH'.
+     'JeVTmowxjAgZutB5AoOngA+2DdYrcTyOyYZP9+QpBvI29vwEhb'.
+     'It042BVQgDy9KTMfkwQG1A9ACCLlgBBGUwxxoc52WDh2ATyEPp'.
+     '1hoaPvrEBh0Dq5an9OUsl/9hylk5b5c+mowLc4E2Jtw4Eoljyf'.
+     'ogA/AGEAagNRjGyUxOmEycyVA5EWDBxrmUp3ytLIv/NJP69Goh'.
+     '+9mFydIvS5PZYkvH1oY/RFtKymlwBFQAgQd+kAA6qSQ8pvn2mp'.
+     'SkJkuVFHPHBnQMrEt5Sl+e4/Lvp51PF1PF5Xy6WMvOWZXMom8z'.
+     'OZTQ8+j5sbQiMEwopsCIwRtBGIJSCdzbTGo9NimkDcgdC7Bg49'.
+     'TG5n4/nfr0Si77WdYp1YzyZEkWPdteaEnB7pPqBTxuIf/VgciE'.
+     'SgasCPwh+GNIkaNNag1RiPge5pEhMQVjfoLcF+eoXSvbKxedwn'.
+     'LKzC3KWbOi5/sW5a44/SHFUSgVA7SCzRG0AvA9mPOgFIETgu4n'.
+     'Ww0wNQWFAqRSL6D2ZQYBdDrQ7R7jXiwgRcvIL02makuTmWtpM/'.
+     '+BlLMl5vuWzLVEuwH6oYnR1KS8kJINGXMM2YdfRlALoQoQQKeb'.
+     'bDVwoMdxQMaLCwLo96HZTF5HbrEhmOftianfZisfzueKv7ZmrX'.
+     'MsjhxKXZGBjzyeEHmSE3oWiggtyVGmE8DTIXTC5NxgAxOAGUM8'.
+     'fun9mnSSLQ/CxNzOTgJ3LIMgoGwkKBiiMyaVviHVkdCO4FEKNv'.
+     'LQzWBYHfITPa4UBVM0LR/WB7ARJsdDDTjA6deYFIFUOimJ3d0E'.
+     'sNdLavYYgBpthqKcjiiJRO8K6CK0CsJTjfQAGaJtD9vQFAxNNQ'.
+     '1FB0yBAfA8gdMAIagLoCVAen0M00zMOTYShNDtoHs9CAIUoI4E'.
+     '1IBihCdNhsMhsj6NuV7BCC2IBpBqQaaFOENCCeiEsO1BO4RQgy'.
+     'I5Hm4k4oIU9MrgZSAdBeTabZz+ODxKQRRBFBJo6IUc51anYRQo'.
+     'dto+24FNxYCiaWKkQsj00KkO4gxRRkAngJ868M0u3OkkM+hxQA'.
+     'cQ7YD7GO5XYSsPZybh/TCkFIYY+kWniTW4Q7jXgHvHMhiRpmuW'.
+     'ca08GZkkZ/nY6TZMNhCnf2CuPoDVJvxpB+q9BHA8Ag1uH+oP4c'.
+     'YEPCzDwmzSLquShHW/E0YRbG/BjZtw40hAy7aNzJlzRn75E6N0'.
+     'qiwTzafI7kOU3gWrhzZC2iHcbsPqLlxvJnCt4KC1RYAL3I5hzY'.
+     'Xv/huePYCtITQMKEnyB4KQvMURuJvw889HGSwUCs7CwkLpo6tX'.
+     'Ty/+7nel6VLGDn/8N9m+eZuo1UP8iNhLau6b3RfmOsHBGTUYw9'.
+     'WBNeDrGB4+h/4qNLKwTnLbHj9CJw/6GoIh9Jpvq0HHcayFhYXi'.
+     'l3/4w9LK8vLKexfma3G/mb/3n1njTivS7tNQaaU1grQDjJ868D'.
+     'Axx6vmxnBrY9C9IcSbSXbavNjb/S3eN6/0m1JcKBScixcvllZW'.
+     'Vi6uLC8v12q1v/M8b/HxVjP//YYr32yE4dYWvShO0ogi14xwxq'.
+     'F4rbnxZ3cMjtpvEEeMvwA0TdOYn5/PffHFF7Vr166tvPeLXyx7'.
+     'nrd4+/btyg/frFo//Xgncnd67qCn78earQqcmYD3fSi1wPCTSV'.
+     '3gzqvm9uFOMl5nUAqFQn5paal26dKla57vf7D+6FHph9VV88af'.
+     'vgq79bo70e3VT2l9A3hYg4UiRALVHTCHSZvYBm4A//6quf8zoG'.
+     '3bpuM4acMwKr1+//SDe/dK31+/bv90/Xrcq9fduNW6rbVeC+E7'.
+     'gWdD2DKg4UEpBmPcm10RuScida31ntb62HAigoigDw6Gh0axWH'.
+     'QWFhZKi4uLZ+I4PrVer2e+u37dXPvqq6hbr7tOp1NXWq89h6/b'.
+     '8FBB34WGBesdcPrj38lkMkGlUuml0+mu53nR3t4eo9HoSLhMJk'.
+     'OlUiGdTuN5Hq7rvgA0TdO4cOFC7vPPP6/VarXldqdTu7m2lrv7'.
+     '7beq++BBO263b/tKrfWSXlbvwJ6CuAtDgTYiaBFMw6BSqfDxxx'.
+     '+rarWqGo0GN2/eZGtrC6XenAkRoVKpcPXqVWZmZmg0Gty6desF'.
+     'oIhIOp3Ol8vlmmVZK3fv3Lm09uc/Zwbr653ccPgoNIzvnmn99Z'.
+     '7W9QG46lAaM5mM2l95GIYUi0VOnz7N7OwsWmsymQzyuse5Q8Mw'.
+     'DNLpNDMzM5w/f/7A6AGgUkoajYa9urpayOXzUz/fvZutr68Pim'.
+     'F4/2y1+n2o9Q/ru7uPesPhXnyo4A+vfHp6mmazybNnz9jZ2UFr'.
+     'TbPZJAhe+8/aS0Mphed5NBoNABqNBqPR6MWBVWstvu/nnj9/Pv'.
+     'vo0aPq5uZmPBgM/qcwPf39xV/9ajU1M3Nvq9PZaw8GoT50PjdN'.
+     'k6mpKa5cucL58+eJ45j19XWePHnCzs4OnudhmiaWZRGGIVH05r'.
+     'yEYYjrumxubrKxsfFyDQJ6NBp1Pc+7C4jWumBaVm+kVL2l1H2l'.
+     '1G6otS+H6V6z8u3tbVzXpdFooJRicXGRqakptre3uXXr1ltrcT'.
+     'Qa8ezZszemWAE9rfUdYBOwtVLRbrPZ+48ff+wDvuu6Sr3MB4Dr'.
+     'uty6desgfa1WC3iRyrNnz4pSSmezWUzTfGtYtNYcdvC/9sMlgP'.
+     'n5N4cAAAAASUVORK5CYII=' ; 
+
+        //==========================================================
+        // File: ppl_pink.png
+        //==========================================================
+        $this->imgdata_large[2][0]= 2779 ;
+        $this->imgdata_large[2][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAACgAAAAoCAYAAACM/rhtAAAABm'.
+     'JLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsRAAALEQF/ZF+RAAAA'.
+     'B3RJTUUH0wMLFQolY9lkpgAACmhJREFUeJy9mOtzFNl5h5+3b9'.
+     'Mz0kzPBWmEVtIiWYhIiC0HCDhB8lb8ISk7nzdZ5+/zJ/8BTmpT'.
+     '660CZLwG1pVFgBkgGIHECEaa+/T9nHzQCCQuRpCNz6mp6g893U'.
+     '8/c37ve3qEjxiC4OA4n/Lp/EUu/tsMM/+aEWduVBx7WhdkShcY'.
+     'xUH2zo0Dwod/5N6vf8V//PoGdx8M8EOFPtK9jI8BdHCcMuVSmf'.
+     'LxHLmSZdm2U8xIbmKETDGDZZnIy4dBbCynyGhphurEDBOlHFnn'.
+     'qPcyPxTOwDCOccw7w5nlBRZWylI+ny/mZ6rL1dzUZ5/IWGZU3D'.
+     'ZIOMQDDaJcHDVGWUbJBi9odVr0QoVSPzigIEaZ8vgSS/8wZU3/'.
+     'k1fylipz5dLM2WlrZqHKaGCKbEbontq3KAKWQyZfZKTgYqc9Bp'.
+     '2I2PcJ4ogk/UEBQcwipbFZmT13vDBx8fhnE1Ofnp9yJopFyT3X'.
+     'yANfks0QHSQMDaL37pOxMLIu2UyVkjVKLjyKSeuD8dAYCFkso1'.
+     'gYMaeWJ40T56cl8yAi/O4FSa2P6kYczIDsgVpAqcDImZPMuAB1'.
+     'dkLQtcc8a/bwox8IUHAxZVxGZMouSLVYwKuMkD5IxN+JSdsRJB'.
+     'pexuTVgYYM6EoGmxkmg3/hEhNUMr/hd7dqbOzExMn/GRDAxWZc'.
+     'j3I8HiXfMjF2FQowKw7pjoN6E/Llw/GBJj8qxVOMlX4ipxc/lY'.
+     'kl2zBLkmrTcEzMkoNoRLVidLi/9g+Z3I+1xRHX5EcAihxnbPRv'.
+     'OTU9kZSmpKPy9FTGrLimPZ1H+UiyGaF67w6n7E1DwMngFDxGvc'.
+     'w70v0xZUby5IxjlIyMssUJrJwVWkXBdbXvSvwEibcSdKCAFI16'.
+     '4/sc0SRo9cGAGq1DwvQFzV6DVuBiV4zYnlEts6A2TSPcSiXoxo'.
+     'QqJCEEFMbQ2b69o5qMiOOPqIMQkagu/aSL7waE8101WFShLjk9'.
+     'yxgEvjRUiyYd+gwAjY2J9VpXfZ/JEXLhDp3OR6U4T97+hEnPwx'.
+     'tv4HsRjy2tTQSFzQgDUnwSLBQRI+x1ZgcH87Vcv4SF19Kt0ezS'.
+     '1h9s0Ma25pgr/YJfnLnEysok0+ezjM6EBLldGqKIJYuDRhOQEJ'.
+     'Oih8X9Q0xmcXNjlCofBJgn78wxVz7L2YWf8tPPz1hnfjbjzfxN'.
+     'qVwutq2etZXUQSXikcXGIgUiUkJSDIQMJgYGJsaB3c7b1qQ4GZ'.
+     'xSkdGZIwMeNLfK6uezMnvJK3pLxeVixfvMsyVjSNSO6IV9adPG'.
+     'AArkEEz8oUkFmBjYGO80qfd6pCWIayD59wIKcsjcKqufn7JO/S'.
+     'xfyi+5c24pey5rZ09mJRNkiDdT/tzbkBr3SYkpMYpgEaIJSYhI'.
+     'kSOY1GhilAQk5ntDIojxCZ/kf87Pl85xbuWEnLiUy+cW3NNuJX'.
+     'MmY5meKf6mT7wZS+THdOjxlG06tIlIOMZxchSxcFFEGAwAGGME'.
+     'jwyZYSnWL3cXWiIUbUI6hO/vxXuFOV84ycmlBWthNeflTjuzTi'.
+     'lzJmM5s46Ej0J63/ZoPmoy6PYxtYVNhmfs0mbAND1mmKVMBY1L'.
+     'mxA1LN7WgXQbCApNhKJHRIM+DQbv7yQGhjnJ5NgFuXBuxpu5mD'.
+     'udm3LPuY7pmZLUE6L1SIJaIPFuDAqyw9lnwDYv6NFHkWJh4ZDB'.
+     'wCBFD3uMxsTAwcBAiElpE/KcPg36dIiOvpsRxDCyhmlP2YY9ZU'.
+     'v8NMb/1id+FGO0DTztkSXLOONUqeITsMkW2zwnJEIDFhYGx+A1'.
+     'kwK4mASkvKDPc3p0iYhRRwYUhZLUTyV6Eu0t4s1Y4kcx6W6KaM'.
+     'EZThcXH59RRhGEgIAddnBwNEBKqqpUtWBIF22YDIhJsbEkJqFN'.
+     'qLtERHs7GnUkwISEQAf0uj30bY39PzbiC6qrDu2cExJ69Nhhhz'.
+     '59UlIUipCQOnVi4sjG7ubJBy6um0C+he/0iDHQKIQERYyKFLqr'.
+     'SI/W6kJCnvOcrWSLSquC1/Jw9Ks3R0FQKHr0uMc9bnCDGjX69A'.
+     'H0XlcJkibN5jOe/alCZStHbjJL9lSMLkXExvCXRiDV6GZEeGeX'.
+     '3TvvBVQoEjfBL/v0rT75Th7VU5C8gktI6NLlMY+5yU3WWGODDf'.
+     'r098tHpNFNH7/2lKdXXdz7efLzVaqJIBOCmK8AJUlI6g0aV+9y'.
+     '9+p7AR3bMQpTBWPy7yeN6fy0jNwewfpvC9Xe+3kFoUuXe9zj5n'.
+     'BusEGHjh6GIAGawC2FWuvSvbbF1maFylZAsC1ISZADBiVNSJrP'.
+     'eX73MY//skHP85z5+fnSxQsXj//4n39cmnPn7LbZlsajBmEnBL'.
+     '1nuEGDG9x4aa5Ldz+h0RCuBqwBv1Wo+7vs9r7n++0MmYeAM+zB'.
+     '+61EK1QUEnbbtN+9Bh3Hsebn54u//PdfLq9eWl2ZnZ1dSnaSwu'.
+     'Pin40b9g3doKE0WoNIl65xj3v75njd3BBubQi6ExKmDWkMRKSl'.
+     'tSbVKQcMao1Go5Ugb0+x53nOyZMnSysrKydXLq1cWlxa/McgCB'.
+     'Yev3hU+GPrD3I5/q94k3pXYQY58q6B5Bs0HB//neaGx00gyWaz'.
+     'VCoV7bquCoKAnZ0dfN/f03egLGj0m3XQNE1jdnY2/+WXXy6trq'.
+     '6uzP3oR5eCIFi4detW5feXL1vr679Let37zVB3/mQytjXJwmSB'.
+     'wikHp9ShY0RESqObwPrr5oBERKhUKly4cIFqtUq9XufmzZtsbW'.
+     '2hXvuDwTTNtxZq8TyvsLy8vLS4uLgahOHphw8elL69fNlc++qr'.
+     'uFOrNXPddm1cczVL5f5P+Lv5MuOJgTGxwYbZpZsCdeAq8M1Bcw'.
+     'CGYeC6LtVqlRMnTjAyMkKn0yGXyx0N0LZt03Ec1zCMSrfXO37v'.
+     'zp3S769csb+/ciXt1mrNdHf3ltZ6Lca8ZpJsduhtCdb2gEFJoQ'.
+     'xADYHuHDS3f32lFEEQUK/XGRkZoVAocP78eZaXl9FaI/Jq25Uk'.
+     'yWHAYrHozM/PlxYWFibTND32sFbLXrtyxVz76qukXas1M61WTW'.
+     'm99gx+20TdN9jqtfjP7QzOwwYNp037Zd0DukDnIByA1pqdnR2+'.
+     '++472u02Z8+eZWJiAsMwDsEBRNGBzYJpmsaJEyfyX3zxxdLS0t'.
+     'KlVqu1dP3q1cLta9ekU6u1dat1J9b6Sk9kraV1rYXegW7apDYw'.
+     'kFY6fPc4MNTw88bwfZ/NzU2UUnieRxAEiAiGcXiXfcigiIjruo'.
+     'VyubxkWdbK7fX1xWvffFMInjzBM82uMT5+p++6V1UUrSe7u03t'.
+     '+8lezlKt3gHyl0aSJDQaDa5fv876+vo+w6FzDq1BpZRsb2/bly'.
+     '9f9vL5/Njdu3fzG0+eMJHNxsfn532vXN5NPG/7abPZal6/Hvfe'.
+     'kroPHfsm98f7AHW9Xo+//vrrlmVZm71+37QNw3JnZ9PK4uJGpV'.
+     'pt4Dh+vLGhsrmcfv1iHzu01m89HjIdCon2fb8TBMHtvYeRUn50'.
+     '1Oj4vqp3Ok1f5LYSadfr9dQfDN642P/XeF2DA+SBAuA4jkOhUK'.
+     'BQKESO43S11p3BYBDt7u4y+CtB/i/q7jp1GMiw2AAAAABJRU5E'.
+     'rkJggg==' ; 
+
+        //==========================================================
+        // File: ppl_blue.png
+        //==========================================================
+        $this->imgdata_large[3][0]= 2284 ;
+        $this->imgdata_large[3][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAACgAAAAoCAYAAACM/rhtAAAABm'.
+     'JLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsRAAALEQF/ZF+RAAAA'.
+     'B3RJTUUH0wMLFRAiTZAL3gAACHlJREFUeJy9mGtv29YZgJ9zKF'.
+     'F3y/Q9jh05tuQkarKgbYasde0UBdZgwNou/Vqga/sD9mP2B4a1'.
+     'BbZ9atFPxb5sqOtmXbI19bqsluPYiR3HN90vFEWRZx/IJI5zqa'.
+     'x0OwBBSgR5Hj7v+55zSEFXTUgIJyA9C6/9RsjMjAyFIxxJCDc7'.
+     'iBqKgyZACGg3G2x9+xXf/fG33P3mC9qNKsp1O+1JdkEnQTdgIO'.
+     'ttCSMUi8gj072MnugllAyB9G8rBGi6RsToJTF6iuRoFi1kHKZf'.
+     '7fB8Iggj0/Dy23D2dakNTR3JDsXPvzstxmZGRMER1EwHhQAEgE'.
+     'CLhIkPD6InY9S3djGLJVBtQP1Qb4HDAyoJYQOOZkPx49nhTH9i'.
+     '7MUBGT7egxkJgd70wZS/CUkoZtA/fRoE1DZ2ACiv52ibReCp4e'.
+     '7CIEHomxDiuVdGTqUnf/ZeOjR8fpiVXZul5ZrY3bWwbdcLr/dA'.
+     'AAIpAwQjUWIjQ+g9HZvswiCgBVF9/SI6OSLGzo0i+oLi6+Utbq'.
+     '+bKEftgwOE/0Ohocf66M+cBjo22U2RQLIHMhmYnvaOpR9S8bSU'.
+     'UqCURGpRkuMZMm9cIvPGJZLj0yBjT2LprkiSkykx9cuXIhOnUs'.
+     'm+QNC2XdG02ggBTcvFabsPWwTPpBAChSCgh4kYBpoeplWp47Qs'.
+     '7EYDt21xINzd5GCAxLExRl89Z+nHjpbKMmjbmkgfDzI0JEW53K'.
+     'Jaa6NcAOEX8v52uJzsBlAS6u0hcnTIccPRqhWPCUcLD+s1EaUp'.
+     'HCEhEMCyHNpt9SjgIU12A6iw6xb123vYhaaKjB9tlgMD5X+uBp'.
+     'zdkpg6azA8EaNQtKlVba+Xez4eCntnJrsDdFsW5nYFpxlFN846'.
+     'DXe8utkM4mhi+EgQmjYbS2WqexZKk6BpjwJ2YlK5VjeA3pNDiH'.
+     'YjRWPzPE7tmBo8EWwGhkXx+z3uXL7D3rU97LIF8RBEAl6lK/Uo'.
+     '6JNM1rZ2aTcr3eUgIQOGTgbdwXMGyRejenLYTvQGbAdRuetSud'.
+     'OivVuFZgtCEgICghICnZoMhmlVTPR49LCAEkQUhk/B7KXe0MWf'.
+     'nxj8xVR/cDheK14WZmtVMJSBnlGoN6FmQq0FLfdwJgORKPHRo/'.
+     'Snzx4G0F/FjJ4KiOdmjPCrrx8bffnMybMv9MQGNG3rzlVqtR1B'.
+     'sh/CYXCD4Aag1oCW7ZnUOjSp6WFi/QNEB8Y7BfTNjZyCmUvJ0I'.
+     'XXT47MTp98Ybon9VZCk8cVazfqlNargsY34G7ByAlIjkHd9CCr'.
+     'LbBdiHViUgiECuDKYCdz8b2cywREdiYZOj8zNnLuzOTzx6ODp+'.
+     'OaGaqwVzBFqz0Idhz2loE7YEwBLaAJLQcKbW8qjAcBF5Jh0AMP'.
+     'IOHe6kxgtb3UMO2OxkF//ffK28nQqxfvm3szrtnDVa799Qb/+v'.
+     'NtsbNSpm3tAv8B+w7Ub0FhAyoBcMPec9oK6raXk48ziQBXQcmC'.
+     'pT3YqHa0mpEBkTR6wz/Jjo2cy04+fzwxdDquNfQKO7sFUbpu0c'.
+     'wp3JoAYsA42Bbkl4GCryUNDEM7Avm6Z/CgSYBWG8pNuFuDu1Wo'.
+     'tjoxKIJGeHIiM/jmK9NnX5ycuJQMtUcqXPvLDTa+qIie4hAJ1U'.
+     'vdrmO2HaDfB931twJgAn1A4lGT96obPHPLBbhVgUoTHHWo9aAA'.
+     'JVAKpyKEmQNzWRENAsL18ycKjAFN/9gCNvzLB/390MMmE7pnDi'.
+     'Bvwt0K5Jv3O+0oB22nJ1Vvjb/UMhOpcKknqN1OiMB2DNHU2G5s'.
+     'sVndpGJVcZXjX1IAlvw9PmhRQcOFPhsSDkiBrQR1G7brgs0a7D'.
+     'ag3FK4rguqBXarI4Nt1SJv5gls7TEWtJDRBO2GwnIs8maevFnA'.
+     'Gx6awLZvzeTBu4kFbLigijC47pscpx0xyDfkvtUEnlarCDtrUC'.
+     't2HGIhvPHVdVwqjTIrxRU2a5uUrYoP0QZ2gMvACl7+3V/LuKDq'.
+     'sJuDy597516+CEezIHXv7vcgXQu2l+Bvn8He9Y4AE4kgk5P9DE'.
+     'R6aFdq5Et5Nit3yTf3m9sBcsAN3+D98c0Fit5JawE25r1zg1Fo'.
+     '5B8GFD7g+nVYnu8EUEop9XTa0N/9dUbqcphP/rDJzbUClVbpgR'.
+     'y2fXM3fND95qj75J8AC6BWPINfVSBieK+x+6cS5UCzCLu3oFV9'.
+     'GqCMx2NGOp2Znpv7aXZudsool3T5J/179sxVlHJ4kGPrP2COBX'.
+     '/7DmiApWCjxIMXpYNznYuXM+6TAKWUMppOZzLvv//ery5cuDCT'.
+     'SqVS336bCwr1JfAPB9r+2KAFwJS+OcETzZHz/7v3etl6ipz77X'.
+     'GAMh6PG+l0OjM3NzczOzs3k0pNnFlbW43+e/GKtMqrblSsF03V'.
+     'WHcJA0PjIAzvg9JTze2H67g9DjAwOTmZ+uCDD96anZ2dnZiYmF'.
+     '5dW41++Lvfa1fnr7qllVK9103mXNTnJgPA+YugsvB3HTaEl+Qs'.
+     'AZ/yeHPPDCiTyaRx5syZbGoilV1dW00szC9oV+avusuLy0Xd0X'.
+     'MgFkDM+zkYBZEHV8f7wwKu84zmngQoNU0LaZoWUa4K31y5qX/8'.
+     '4cfyyvwVN5/L10NOKNeg8UmDxoKF5Vfj1xXAgD0JrgAcvBDfel'.
+     'a4g4AykUgY6XR6emJiIru2ttZXq9S0K19eUcuLy8WQE8o5OAsN'.
+     'Ggsmpl+NpoL1g9X4UBU+C9xDgEKIwNTUVOqdd955M9mbnJ3/cj'.
+     '6Vu5aTheXCQXNdVeMzAwJSCGEA2XKpnF1cXIzlFnOVhJPIKdR+'.
+     'c88ctq4AlVKsrKzw0UcfKcC5uXqzXnNqSzb2pwLxOHP/l7Z/BN'.
+     'eB01LKt4HTrusKvGr8jB+hGn8MQAkYQMrfw4Nq/MFPtf+rdvDb'.
+     'k8QL+/5Z4Uepxm7bfwHuTAVUWpWaqAAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        // File: ppl_green.png
+        //==========================================================
+        $this->imgdata_large[4][0]= 2854 ;
+        $this->imgdata_large[4][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAACgAAAAoCAYAAACM/rhtAAAABm'.
+     'JLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsRAAALEQF/ZF+RAAAA'.
+     'B3RJTUUH0wMLFQ4hANhluwAACrNJREFUeJytmF1zE1eagJ+3u9'.
+     'XdkvUty2AbmLEtEzDBgZ0UpDBOalNTUzU3czl7tct/2n+wt3M/'.
+     'NVM12SSTQQSyW2TA+QAJQogtYYFtyfrqL3WfvWj5g8AEjzfvhS'.
+     'SXjk8//Zz3Pf3qCMcJAWxMKlT4kH+jwu/FknnJSUItKFHzCrKA'.
+     'BggBQx5ziz/wn/yBz3hED4/oaJfSjgVoYjJJgTLTZCjohp7IGT'.
+     'k5aZ4kb+bRTR30Q7djj8f/kpPMUSCFedRL6W8e8qMQNE6S4xpv'.
+     'c5HrTPFubiJ3ZnlyOXV59rJYU5Z00h1c3d0brxAiUkScRijisk'.
+     '6XLTyiN3s8HuAJpniXa/q8/pt8Or+0kF8oXJm5YiydWcIpOrJu'.
+     'rjOQwd54AQwsMpTJYhPSoYuLQ58An/DnBQSdImXO8avsTPbqpc'.
+     'lLp67OXDVzMznZLGxSs2qyIRu4at8gKHQEC50kE1icxqCAdxST'.
+     'xjEA44tqaJlERl8uLWvvnX5PHuQfcCdxh5qq0aX76vj4WgWyXO'.
+     'QiNgBP8IAaddr08X8+wHFmJSQhBbPAZGoSZSt5wQs6qoNC7UEd'.
+     '4AEoLIQSCaCCy78Dv8Tiv1hjjW1CRj8XIAgEKqDtt9keboMJZa'.
+     'vMjuzQVd3Xr9prTJo+GF/jKZea95R25Lxs8jg5qFGiwDnOS0mW'.
+     'NE0rjNRIt3WbklUCA9mV3Zdz8OBT/JfCQLB0SKYVVjGFYSfx/E'.
+     '26ow4e6uDujlPFQpE0FU6P8qNTHdXJdEdda0qf0itWBVM3pa/3'.
+     'ccUlIECJet0cAJoeYk5EZCeS5IwEoerSxccJBwRqFFf38QCTaO'.
+     'TRVFKJm3NTbtLNSyh2IkhIXsvLCesEGNCWdmwyruSD/z9kUlRc'.
+     '3bqNlSxhJNJ43p5JITrOEis8Qtr0cXEpU/JT/pmO18n2vb42pU'.
+     '3JnDnHMBqyPlpnoAaxhr2llv1ZUBqEGlqYwDQMsskMOcMgVL3Y'.
+     'ZOQTHAcQQiIGjHCwCaiovjrv4hbcpKuJJjIcDHm685RGr4GLCx'.
+     'YHkAcrLoAoDSLBiAQrMkjqybHJCbxgh+7xAC1MpsgzwRwD3qHL'.
+     'WyTIBdlAa6u2rHfXaew06PV78ZZjAwleNnkolECoH5i090wOcY'.
+     '+TgwYzFHiPi1zkOkXexeAMASnVU+LiyiA1wFUuaqggACLizeWw'.
+     'ycMzyssmVYKkbpGyC5T+OUALk2mKLHKWf+ED/az+YW42d66YL+'.
+     'aNrmEEzQCFEnKw368EgEvcN1m80eTIQIt0TFOjMJHkzNEBBYPp'.
+     'sblf8QHzrORO5JaWZ5ZLl6cuJyyxpNPv4PZdoT+GyIxBfI5uUg'.
+     'eJMCwP2/bIHO1JEudcgUUWOceKNq99mCvnzs5PzRcuTV4y5mRO'.
+     'SMIjo47z5S7a94oQCNKgJsZwO7D/IDNg3/LLhRNXt4JohBb4aG'.
+     '82GLdXcf93mQ+Y43r2RHZp+cRy6cqJK4l8MS+tdItaqiYtc0Mm'.
+     'QpfJARh98HYh9IiXVcaAo58wGb+LBAjbSPgCOcoSa0wzxXtc08'.
+     '/pv8mfyL+9MLVQvDJ1JVHJV6SZbFI1qtTsB+KlehRtRTGE8Afo'.
+     'P4DRcAxiEudhAHjjzz+ubgX4oHowakHQOlqzICQwyVPITGVOXi'.
+     'xfLF6aumzmczl5lHzMff2+fCdPaGttEkXoLQAO9B7C6EugPYby'.
+     'gVPjGXc5eIbNAJPjGwiAbaAJUQv8wVG7GROkJFpyOqn/ovgLba'.
+     '44L0+sDaraXb6jzq7aBQWjBOyUoHcaopOgmaA3IRyNDZnA1HjO'.
+     'HSBkr7eEFDAEngHrQCf+/s2A8cSiSkqcKUeeTjwFy2Jd78t3+L'.
+     'TR4itIiBLwLQhzkJyB5Cx4HXDaENVQCBAQcRqFIHTRaBIvuYXg'.
+     'AdsouuNxEL0ZUBHnSQp66R73zYfUtQ6OytKT8RckQAJQoLtgO5'.
+     'BJgj0D/WfgdyHaAHx8THoUcbGx8ciwhUl3bDEiToURPooeI7pH'.
+     'MziK9Yd9nU5a6GgKjOH41vsgI4hAcyC5AZkapF+AoYNrjjsuhx'.
+     'FbtPmeB5ykyQQzTPAWAQWC8S9oAI0QRRuPb9jkmyMZNAOTklvC'.
+     'GGYZaFkGmkVAh8h4DtKFMIBunG+pB5B5AIkGBDsQ+qBiL20caj'.
+     'zhJknq5KlgMkLjJHJos4kYEbFJi5vc5eYbATVN02bNWe19+32t'.
+     'aJWlFm3wbf8Rz5NbDFJdlOFBF/g7cBf0JkrbBb+F6j1DOduEkU'.
+     '8bWCOiSofPWadBnSZDWmgUkEMGhZCINut8S/0NBtPptFlZrBSu'.
+     'vnt1+ndnflfIp9OJ/279Ubbbd+lP7KBKPoEBsgnqLph/BRzwdS'.
+     'LnBUFvHcfdpRsGPAGqwMco6jynz+e0SPKYCHMfLX5VKHwcenR+'.
+     'Igd1XTcqlUr+xn/cePv91fevzy8sLO2OtrOpWkqL7gXKSAVRdh'.
+     'ZFEmEXoYkwBNqovoc/3GHH3aUR+jwC1oD/AWrANi4hGwyBzqEG'.
+     'Vvb77Dgi0eT1VZzJZMxKpVJYXV1dXF1dXVm6sPSvruue3Xzcyj'.
+     '6/syvDzwj0lNazK6Fj5LFCRZouZpBABj6jXouu3+Np6HNvDHaf'.
+     'g91t74msbMuOJicnSSaTKKUQEUQEpRSO69But1/dB0VEm5uby9'.
+     'y4cWNpdXX1+sLCworrume//PuXpeqnVeOban0U1PW2kcx+O9L7'.
+     'Te9sUB4lWFR9SqNtNGcHx+/RDD2+Am4D94CnQA8OjjlEhMnyJC'.
+     'srK8zOzu7BiYioMAzZ2Njg9u3brwIqpSSXy2WXl5eXLly4sOo4'.
+     'zoV6vV6oflrVP/7Tx8Hmw1Zb6ydqmpWp7ha8h4O3gjOhzVANmF'.
+     'XPMNQWvdDnCXCXuHR+APqH4fbCtm2mp6eZn59H13WJuYXRaKSU'.
+     'UiSTyVcBdV3XDcOwRaTU7/en19bWCn/79G+JL/76RbhZ22y7u+'.
+     '6ahl71nPDz/nO17m7wAxlabFOihy4+DvAcqAMbPzZ3OFzX5dmz'.
+     'Z2iahoiosUUVhiGNRgPHcV4GzGQy5uLiYuH8+fMzo9FoslarJW'.
+     '9+elP75E+fBJu1zY7qqpqBUW3T/niohnVvy+1zm5aVtp+WE2XT'.
+     'nrHFzbjh1tYLz3XdPjD4R3BKKba2tqhWq4dzUO3noBPn4H5PKy'.
+     'LaO++8U7hx48byhQsXVne7u6tf3/v64t3P7mbq9+odt+OuaWi3'.
+     'PLxbW2ytubjbQCgiMnt6VlaurWgz0zM0m02q1WrUaDSUUuqI56'.
+     'ivDxE5MCgiYllWtlwuL5mmufLV/a/O/uXPf9Ff1F+80Lv6Yx29'.
+     '2qHzyZBh3cdvc7gaTZuZkzPh/Py8ACqVSv1/uPZDKXUAGEWRtF'.
+     'qtxEcffZTL5XLF+2v39fqjeivshA/TpP83JLwzYFBzcA4370Cc'.
+     'S81nTRBUs9lkOByi1GuOPI4Rh3+26JZlnSkWi781DOPXvV4v3+'.
+     '/2G0R8kSBxB/jew+tERK+c49m2TblcxrZtXNfl+fPneJ6HZVmU'.
+     'y2VJJpNyaJ9TSinlOA5bW1u4rntkQA0oAG8D54gb9W3ianxM3A'.
+     'e/cn73U3Hq1Cm5du2aPjs7a+ztcSIShmE4ajQa6tatWzQajZ+0'.
+     'fbiKI+It4SvijVUj7kL2qvGfgkskEqTTaZmcnDROnTplJhIJTU'.
+     'QiwPd9P/Q8T6XTaQzDIAiCfzjP/wFVfszuFqdHXgAAAABJRU5E'.
+     'rkJggg==' ; 
+
+
+        //==========================================================
+        // File: pp_red.png
+        //==========================================================
+        $this->imgdata_small[0][0]= 384 ;
+        $this->imgdata_small[0][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAABm'.
+     'JLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsSAAALEgHS3X78AAAA'.
+     'B3RJTUUH0wMJFhouFobZrQAAAQ1JREFUeJyV1dFtwyAQBuD/og'.
+     'xQdYxa8gRY6hJ0jK6QdohMkTEuE5wUj5ERen05IoLvID7Jkn2G'.
+     'j8MgTMyMXqRlUQBYq9ydmaL2h1cwqD7l30t+L1iwlbYFRegY7I'.
+     'SHjkEifGg4ww3aBa/l4+9AhxWWr/dLhEunXUGHq6yGniw3QkOw'.
+     '3jJ7UBd82n/VVAlAtvsfp98lAj2sAJOhU4AeQ7DC1ubVBODWDJ'.
+     'TtCsEWa6u5M1NeFs1NzgdtuhHGtj+9Q2IDppQUAL6Cyrlz0gDN'.
+     'ohSMiJCt861672EiAhEhESG3woJ9V9OKTkwRKbdqz4cHmFLSFg'.
+     's69+LvAZKdeZ/n89uLnd2g0S+gjd5g8zzjH5Y/eLLi+NPEAAAA'.
+     'AElFTkSuQmCC' ; 
+
+        //==========================================================
+        // File: pp_orange.png
+        //==========================================================
+        $this->imgdata_small[1][0]= 403 ;
+        $this->imgdata_small[1][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAABm'.
+     'JLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsSAAALEgHS3X78AAAA'.
+     'B3RJTUUH0wMJFhwAnApz5AAAASBJREFUeJyN1dFthDAMBuDf7S'.
+     '3BCm2VCRKpS4QxbhikW6IewzcBqm6Fm6JyH7iEEByCn5AJH38g'.
+     'BBIRHNUzBAWAGNfe/SrUGv92CtNt309BrfFdMGPjvt9CD8Fyml'.
+     'ZZaDchRgA/59FDMD18pvNoNyHxMnUmgLmPHoJ+CqqfMaNAH22C'.
+     'fgqKRwR+GRpxGjXBEiuXDBWQhTK3plxijyWWvtKVS5KNG1xM8I'.
+     'OBr7geV1WupDqpmTAPKjCqLhxk/z0PImQmjKrAuI6vMXlhFroD'.
+     'vfdqITXWqg2YMSJEAFcReoag6UXU2DzPG8w5t09YYsAyLWvHrL'.
+     'HUy6D3XmvMAAhAay8kAJpBosX4vt0G4+4Jam6s6Rz1fgFG0ncA'.
+     'f3XfOQcA+Acv5IUSdQw9hgAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        // File: pp_pink.png
+        //==========================================================
+        $this->imgdata_small[2][0]= 419 ;
+        $this->imgdata_small[2][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAABm'.
+     'JLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsSAAALEgHS3X78AAAA'.
+     'B3RJTUUH0wMJFhsQzvz1RwAAATBJREFUeJyd1MFthDAQheF/oi'.
+     'gF+JYWQKICkCJRA1vGtrDbxFbhGvY0HVjCLeS2BeTiHFgTB2wg'.
+     'eRISstCnmcG2qCpbuXf3ADBQzWsPfZfS9y9HsEu4/Fo33Wf4Fx'.
+     'gxL3a1XkI3wbTNXHLoboVeLFUYDqObYBy+Fw/Uh9DdCmtOwIjF'.
+     'YvG76CZoOhNGRmpO8zz30CJoOhMAqlDxFzQLppgXj2XaNlP7FF'.
+     'GLL7ccMYCBgZERgCvXLBrfi2DEclmiKZwFY4tp6sW26bVfnede'.
+     'e5Hc5dC2bUgrXGKqWrwcXnNYDjmCrcCIiQgDcFYV05kQ8SXmnB'.
+     'NgPiVN06wrTDGAhz5EWY/FOccTk+cTnHM/YNu2YYllgFxCWuUM'.
+     'ikzGx+2Gc+4N+CoJW8n+5a2UKm2aBoBvGA6L7wfl8aoAAAAASU'.
+     'VORK5CYII=' ; 
+
+
+        //==========================================================
+        // File: pp_blue.png
+        //==========================================================
+        $this->imgdata_small[3][0]= 883 ;
+        $this->imgdata_small[3][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAMAAAC6V+0/AAACi1'.
+     'BMVEX///8AAAAAADMAAGYAAJkAAMwAAP8zAAAzADMzAGYzAJkz'.
+     'AMwzAP9mAABmADNmAGZmAJlmAMxmAP+ZAACZADOZAGaZAJmZAM'.
+     'yZAP/MAADMADPMAGbMAJnMAMzMAP//AAD/ADP/AGb/AJn/AMz/'.
+     'AP8AMwAAMzMAM2YAM5kAM8wAM/8zMwAzMzMzM2YzM5kzM8wzM/'.
+     '9mMwBmMzNmM2ZmM5lmM8xmM/+ZMwCZMzOZM2aZM5mZM8yZM//M'.
+     'MwDMMzPMM2bMM5nMM8zMM///MwD/MzP/M2b/M5n/M8z/M/8AZg'.
+     'AAZjMAZmYAZpkAZswAZv8zZgAzZjMzZmYzZpkzZswzZv9mZgBm'.
+     'ZjNmZmZmZplmZsxmZv+ZZgCZZjOZZmaZZpmZZsyZZv/MZgDMZj'.
+     'PMZmbMZpnMZszMZv//ZgD/ZjP/Zmb/Zpn/Zsz/Zv8AmQAAmTMA'.
+     'mWYAmZkAmcwAmf8zmQAzmTMzmWYzmZkzmcwzmf9mmQBmmTNmmW'.
+     'ZmmZlmmcxmmf+ZmQCZmTOZmWaZmZmZmcyZmf/MmQDMmTPMmWbM'.
+     'mZnMmczMmf//mQD/mTP/mWb/mZn/mcz/mf8AzAAAzDMAzGYAzJ'.
+     'kAzMwAzP8zzAAzzDMzzGYzzJkzzMwzzP9mzABmzDNmzGZmzJlm'.
+     'zMxmzP+ZzACZzDOZzGaZzJmZzMyZzP/MzADMzDPMzGbMzJnMzM'.
+     'zMzP//zAD/zDP/zGb/zJn/zMz/zP8A/wAA/zMA/2YA/5kA/8wA'.
+     '//8z/wAz/zMz/2Yz/5kz/8wz//9m/wBm/zNm/2Zm/5lm/8xm//'.
+     '+Z/wCZ/zOZ/2aZ/5mZ/8yZ///M/wDM/zPM/2bM/5nM/8zM////'.
+     '/wD//zP//2b//5n//8z///9jJVUgAAAAAXRSTlMAQObYZgAAAA'.
+     'FiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElN'.
+     'RQfTAwkWGTNerea3AAAAYUlEQVR4nHXNwQ3AIAxDUUfyoROxRZ'.
+     'icARin0EBTIP3Hp1gBRqSqYo0seqjZpnngojlWBir5+b8o06lM'.
+     'ha5uFKEpDZulV8l52axhVzqaCdxQp32qVSSwC1wN3fYiw7b76w'.
+     'bN4SMue4/KbwAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        // File: pp_green.png
+        //==========================================================
+        $this->imgdata_small[4][0]= 447 ;
+        $this->imgdata_small[4][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAABm'.
+     'JLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsSAAALEgHS3X78AAAA'.
+     'B3RJTUUH0wMJFhkLdq9eKQAAAUxJREFUeJyN1LFVwzAQxvH/8f'.
+     'IeDS0FLKABlN6eIwPYAzCHB0gWYI2jj+i1ABUTQN4TRSQ7iiWZ'.
+     'qxLn9Mt9ydmiqrSq930AYFiu6YdKrf/hP1gYQn6960PxwBaYMG'.
+     'E9UA3dBFtVQjdBOQmBakLennK0CapRwbZRZ3N0O/IeEsqp3HKL'.
+     'Smtt5pUZgTPg4gdDud+6xoS97wM2rsxxmRSoTgoVcMZsXJkBho'.
+     'SmKqCuOuEtls6nmGMFPTUmxBKx/MeyNfQGLoOOiC2ddsxb1Kzv'.
+     'ZzUqu5IXbGDvBJf+hDisi77qFSuhq7Xpuu66TyJLRGbsXVUPxV'.
+     'SxsgkzDMt0mKT3/RcjL8C5hHnvJToXY0xYRZ4xnVKsV/S+a8YA'.
+     'AvCb3s9g13UhYj+TTo93B3fApRV1FVlEAD6H42DjN9/WvzDYuJ'.
+     'dL5b1/ji+/IX8EGWP4AwRii8PdFHTqAAAAAElFTkSuQmCC' ; 
+    }
+}
+
+?>
diff --git a/web/classes/jpgraph/imgdata_squares.inc.php b/web/classes/jpgraph/imgdata_squares.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..895dc936d910808a8431b384f54519cbf87dc4a0
--- /dev/null
+++ b/web/classes/jpgraph/imgdata_squares.inc.php
@@ -0,0 +1,150 @@
+<?php
+//=======================================================================
+// File:        IMGDATA_SQUARES.INC
+// Description: Base64 encoded images for squares
+// Created:     2003-03-20
+// Ver:         $Id: imgdata_squares.inc.php 1106 2009-02-22 20:16:35Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+class ImgData_Squares extends ImgData {
+    protected $name = 'Squares';
+    protected $an = array(MARK_IMG_SQUARE =>'imgdata');
+
+    protected $colors = array('bluegreen','blue','green',
+   'lightblue','orange','purple','red','yellow');
+    protected $index  = array('bluegreen' =>2,'blue'=>5,'green'=>6,
+   'lightblue'=>0,'orange'=>7,'purple'=>4,'red'=>3,'yellow'=>1);
+    protected $maxidx = 7 ;
+    protected $imgdata ;
+
+    function ImgData_Squares () {
+        //==========================================================
+        //sq_lblue.png
+        //==========================================================
+        $this->imgdata[0][0]= 362 ;
+        $this->imgdata[0][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAIAAADZrBkAAAAABm'.
+     'JLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsRAAALEQF/ZF+RAAAA'.
+     'B3RJTUUH0wMLFgojiPx/ygAAAPdJREFUeNpj/P377+kzHx89/c'.
+     'VAHNBQ5VBX52HavPWWjg6nnDQbkXoUFTnnL7zD9PPXrz17HxCj'.
+     'E6Jn6fL7H7/+ZWJgYCBGJ7IeBgYGJogofp1oehDa8OjE1IOiDa'.
+     'tOrHoYGBhY0NwD0enirMDAwMDFxYRVD7ptyDrNTAU0NXix6sGu'.
+     'jYGBgZOT9e/f/0xMjFyczFgVsGAKCfBza2kKzpl3hIuT1c9Xb/'.
+     'PW58/foKchJqx6tmy98vbjj8cvPm/afMnXW1JShA2fNmQ9EBFc'.
+     'Opnw6MGjkwm/Hlw6mQjqwaqTiRg9mDoZv//4M2/+UYJ64EBWgj'.
+     'cm2hwA8l24oNDl+DMAAAAASUVORK5CYII=' ; 
+
+        //==========================================================
+        //sq_yellow.png
+        //==========================================================
+        $this->imgdata[1][0]= 338 ;
+        $this->imgdata[1][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAMAAABhEH5lAAAAWl'.
+     'BMVEX////+/+H+/9/9/9v8/8P8/8H8/7v8/7n6/4P5/335/3n5'.
+     '/3X4/1f4/1P3/031/w30/wn0/wPt+ADp9ADm8ADk7gDc5gDa5A'.
+     'DL1ADFzgCwuACqsgClrABzeAC9M0MzAAAAAWJLR0QAiAUdSAAA'.
+     'AAlwSFlzAAALEgAACxIB0t1+/AAAAAd0SU1FB9MDCxYEDlOgDj'.
+     'EAAAB+SURBVHjaVcpbCsQgDEDRGERGKopjDa2a/W9zfLWj9/Nw'.
+     'Ac21ZRBOtZlRN9ApzSYFaDUj79KIorRDbJNO9bN/GUSh2ZRJFJ'.
+     'S18iorURBiyksO8buT0zkfYaUqzI91ckfhWhoGXTLzsDjI68Sz'.
+     'pGMjrzPzauA/iXk1AtykmvgBC8UcWUdc9HkAAAAASUVORK5CYI'.
+     'I=' ; 
+
+        //==========================================================
+        //sq_blgr.png
+        //==========================================================
+        $this->imgdata[2][0]= 347 ;
+        $this->imgdata[2][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAMAAABhEH5lAAAAZl'.
+     'BMVEX////0+vv0+vrz+fry+frv+Png7e/d7e/a6+zY6+250tSz'.
+     '0tSyztCtztGM0NWIz9SDzdNfsLVcrrRZrbJOp61MpqtIr7dHn6'.
+     'RErrZArLQ6q7M2g4kygYcsp68npa4ctr8QZ20JnqepKsl4AAAA'.
+     'AWJLR0QAiAUdSAAAAAlwSFlzAAALEgAACxIB0t1+/AAAAAd0SU'.
+     '1FB9MDCxYEByp8tpUAAAB7SURBVHjaVcjRFoIgDADQWZpWJpjY'.
+     'MsnG//9kzIFn3McLzfArDA3MndFjrhvgfDHFBEB9pt0CVzwrY3'.
+     'n2yicjhY4vTSp0nbXtN+hCV53SHDWe61dZY+/9463r2XuifHAM'.
+     '0SoH+6xEcovUlCfefeFSIwfTTQ3fB+pi4lV/bTIgvmaA7a0AAA'.
+     'AASUVORK5CYII=' ; 
+
+        //==========================================================
+        //sq_red.png
+        //==========================================================
+        $this->imgdata[3][0]= 324 ;
+        $this->imgdata[3][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAMAAABhEH5lAAAAXV'.
+     'BMVEX////++Pn99/j99ff99fb98/X98/T98PL55uj43+P24+bw'.
+     'kKPvjaHviJ3teJHpxMnoL2Pjs73WW3rWNljVWXnUVnbUK1DTJk'.
+     '3SUHPOBz/KQmmxPVmuOFasNFOeIkWVka/fAAAAAWJLR0QAiAUd'.
+     'SAAAAAlwSFlzAAALEgAACxIB0t1+/AAAAAd0SU1FB9MDCxYEHd'.
+     'ceT+8AAABtSURBVHjaVchbAkMwEAXQq6i3VrQiQfa/zDYTw8z5'.
+     'PCjGt9JVWFt1XWPh1fWNdfDy+tq6WPfRUPENNKnSnXNWPB4uv2'.
+     'b54nSZ8jHrMtOxvWZZZtpD4KP6xLkO9/AhzhaCOMhJh68cOjzV'.
+     '/K/4Ac2cG+nBcaRuAAAAAElFTkSuQmCC' ; 
+
+        //==========================================================
+        //sq_pink.png
+        //==========================================================
+        $this->imgdata[4][0]= 445 ;
+        $this->imgdata[4][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAMAAABhEH5lAAAApV'.
+     'BMVEX////6+Pz69/v49Pr38/r17/jr4+/l3Onj2efh1ua/L+i+'.
+     'q8m+Lue9Lua8qsS8LuW8LeS7pca5LOG4LN+2Y9O2YNW1ZdO1Kt'.
+     'y0atC0aNGzb82zbc6zKtuzKdqycsuwa8qtJtOISZ2GRpuFN6GE'.
+     'NqCDQpmCMZ+BPpd/LJ1/K519S5B9Jpx9Jpt9JZt6RY11BJZ1BJ'.
+     'V0BJV0BJRzBJNvNoRtIoJUEmdZ/XbrAAAAAWJLR0QAiAUdSAAA'.
+     'AAlwSFlzAAALEgAACxIB0t1+/AAAAAd0SU1FB9MDCxYDF3iKMD'.
+     'YAAACeSURBVHjaVczbEoIgGARgCiMtrexoWpaa2FHUgvd/tH4Y'.
+     'BnEvv9ldhNPradPnnGBUTtPDzMRPSIF46SaBoR25dYjz3I20Lb'.
+     'ek6BgQz73Il7KKpSgCO0pTHU0886J1sCe0ZYbALjGhjFnEM2es'.
+     'VhZVI4d+B1QtfnV47ywCEaKeP/p7JdLejSYt0j6NIiOq1wJZIs'.
+     'QTDA0ELHwhPBCwyR/Cni9cOmzJtwAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        //sq_blue.png
+        //==========================================================
+        $this->imgdata[5][0]= 283 ;
+        $this->imgdata[5][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAMAAABhEH5lAAAAQl'.
+     'BMVEX////4+fz39/z19vvy8vru7/ni4+7g4fHW1ue8vteXmt6B'.
+     'hdhiZ7FQVaZETcxCSJo1Oq4zNoMjKakhJHcKFaMEC2jRVYdWAA'.
+     'AAAWJLR0QAiAUdSAAAAAlwSFlzAAALEgAACxIB0t1+/AAAAAd0'.
+     'SU1FB9MDCxYDN0PkEP4AAABfSURBVHjaVchHAoAgDATAVcCCIF'.
+     'j4/1elJEjmOFDHKVgDv4iz640gLs+LMF6ZUv/VqcXXplU7Gqpy'.
+     'PFzBT5qml9NzlOX259riWHlS4kOffviHD8PQYZx2EFMPRkw+9Q'.
+     'FSnRPeWEDzKAAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        //sq_green.png
+        //==========================================================
+        $this->imgdata[6][0]= 325 ;
+        $this->imgdata[6][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAMAAABhEH5lAAAAXV'.
+     'BMVEX////2+vX1+vX1+fT0+fPz+PPx9/Dv9u7u9e3h7uHe697a'.
+     '6dnO2s3I1sa10LOvza2ay5aEwYBWlE9TqE5Tkk1RkEpMrUJMg0'.
+     'hKiUNGpEFBojw8oTcsbScaYBMWlwmMT0NtAAAAAWJLR0QAiAUd'.
+     'SAAAAAlwSFlzAAALEgAACxIB0t1+/AAAAAd0SU1FB9MDCxYEFd'.
+     'nFx90AAABuSURBVHjaVc9HAoAgDADB2HuJWLDx/2cKBITscW4L'.
+     '5byzMIWtZobNDZIZtrcCGZsRQ8GwvRSRNxIiMuysODKG3alikl'.
+     'ueOPlpKTLBaRmOZxQxaXlfb5ZWI9om4WntrXiDSJzp7SBkwMQa'.
+     'FEy0VR/NAB2kNuj7rgAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        //sq_orange.png
+        //==========================================================
+        $this->imgdata[7][0]= 321 ;
+        $this->imgdata[7][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAMAAABhEH5lAAAAUV'.
+     'BMVEX/////8+n/8uf/8OP/59H/5Mv/zqH/zJ3/ypv/yJf/vYH/'.
+     'u33/uXn/n0n/nUX/m0H/lzn/ljf/lDP/kS3/kCv/iR//hxv/fg'.
+     'n/fAX/eQDYZgDW6ia5AAAAAWJLR0QAiAUdSAAAAAlwSFlzAAAL'.
+     'EgAACxIB0t1+/AAAAAd0SU1FB9MDCxYEJIgbx+cAAAB2SURBVH'.
+     'jaVczRCoQwDETRbLAWLZSGUA35/w/dVI0283i4DODew3YESmWW'.
+     'kg5gWkoQAe6TleUQI/66Sy7i56+kLk7cht2N0+hcnJgQu0SqiC'.
+     '1SzSIbzWSi6gavqJ63wSduRi2f+kwyD5rEukwCdZ1kGAMGMfv9'.
+     'AbWuGMOr5COSAAAAAElFTkSuQmCC' ; 
+    }
+}
+
+?>
diff --git a/web/classes/jpgraph/imgdata_stars.inc.php b/web/classes/jpgraph/imgdata_stars.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..bc696902a6ffc2a6cd41e9f89cdb9331444431bb
--- /dev/null
+++ b/web/classes/jpgraph/imgdata_stars.inc.php
@@ -0,0 +1,144 @@
+<?php
+//=======================================================================
+// File:        IMGDATA_STARS.INC
+// Description: Base64 encoded images for stars
+// Created:     2003-03-20
+// Ver:         $Id: imgdata_stars.inc.php 1106 2009-02-22 20:16:35Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+
+class ImgData_Stars extends ImgData {
+    protected $name = 'Stars';
+    protected $an = array(MARK_IMG_STAR => 'imgdata');
+
+    protected $colors = array('bluegreen','lightblue','purple','blue','green','pink','red','yellow');
+    protected $index  = array('bluegreen'=>3,'lightblue'=>4,'purple'=>1,
+   'blue'=>5,'green'=>0,'pink'=>7,'red'=>2,'yellow'=>6);
+    protected $maxidx = 7 ;
+    protected $imgdata ;
+
+    function __construct() {
+        //==========================================================
+        // File: bstar_green_001.png
+        //==========================================================
+        $this->imgdata[0][0]= 329 ;
+        $this->imgdata[0][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABQAAAASCAMAAABsDg4iAAAAUV'.
+     'BMVEX///////+/v7+83rqcyY2Q/4R7/15y/1tp/05p/0lg/zdX'.
+     '/zdX/zVV/zdO/zFJ9TFJvDFD4yg+8Bw+3iU68hwurhYotxYosx'.
+     'YokBoTfwANgQFUp7DWAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgF'.
+     'HUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAxYTJj'.
+     'CRyxgTAAAAcUlEQVR4nH3MSw6AIAwEUBL/IKBWwXL/g0pLojUS'.
+     'ZzGLl8ko9Zumhr5iy66/GH0dp49llNPB5sTotDY5PVuLG6tnM9'.
+     'CVKSIe1joSgPsAKSuANNaENFQvTAGzmheSkUpMBWeJZwqBT8wo'.
+     'hmysD4bnnPsC/x8ItUdGPfAAAAAASUVORK5CYII=' ; 
+        //==========================================================
+        // File: bstar_blred.png
+        //==========================================================
+        $this->imgdata[1][0]= 325 ;
+        $this->imgdata[1][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABQAAAASCAMAAABsDg4iAAAATl'.
+     'BMVEX///+/v79uRJ6jWPOSUtKrb+ejWO+gWPaGTruJTr6rZvF2'.
+     'RqC2ocqdVuCeV+egV/GsnLuIXL66rMSpcOyATbipY/OdWOp+VK'.
+     'aTU9WhV+yJKBoLAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgA'.
+     'AAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAxYTJwynv1'.
+     'XVAAAAcElEQVR4nH3MyQ6AIAwEUFIqiwju2///qLQmWiJxDnN4'.
+     'mYxSv5lqGCs2nvaLLtZx/VhGOW1MjnPJWp0zsw2wsUY2jd09BY'.
+     'DFmESC+BwA5UCUxhqAhqrA4CGrLpCMVGK4sZe4B+/5RLdiyMb6'.
+     'on/PuS9CdQNC7yBXEQAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        // File: bstar_red_001.png
+        //==========================================================
+        $this->imgdata[2][0]= 325 ;
+        $this->imgdata[2][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABQAAAASCAMAAABsDg4iAAAATl'.
+     'BMVEX///+/v7+eRFHzWG3SUmHnb37vWGr2WHG7Tlm+TljxZneg'.
+     'Rk3KoaXgVmXnV2nxV227nJ++XGzErK3scIS4TVzzY3fqWG2mVF'.
+     'zVU2PsV2rJFw9VAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgA'.
+     'AAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAxYTJzCI0C'.
+     'lSAAAAcElEQVR4nH3MyQ6AIAwEUFIqiwju2///qLQmWiJxDnN4'.
+     'mYxSv5lqGCs2nvaLLtZx/VhGOW1MjnPJWp0zsw2wsUY2jd09BY'.
+     'DFmESC+BwA5UCUxhqAhqrA4CGrLpCMVGK4sZe4B+/5RLdiyMb6'.
+     'on/PuS9CdQNC7yBXEQAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        // File: bstar_blgr_001.png
+        //==========================================================
+        $this->imgdata[3][0]= 325 ;
+        $this->imgdata[3][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABQAAAASCAMAAABsDg4iAAAATl'.
+     'BMVEX///+/v79Ehp5Yx/NSq9Jvw+dYwu9YzfZOmbtOmb5myPFG'.
+     'gqChvcpWteBXvedXxvGcsbtcpb6su8RwzOxNmrhjyvNYwupUjK'.
+     'ZTr9VXwOyJhmWNAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgA'.
+     'AAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAxYTJTC65k'.
+     'vQAAAAcElEQVR4nH3MyQ6AIAwEUFIqiwju2///qLQmWiJxDnN4'.
+     'mYxSv5lqGCs2nvaLLtZx/VhGOW1MjnPJWp0zsw2wsUY2jd09BY'.
+     'DFmESC+BwA5UCUxhqAhqrA4CGrLpCMVGK4sZe4B+/5RLdiyMb6'.
+     'on/PuS9CdQNC7yBXEQAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        // File: bstar_blgr_002.png
+        //==========================================================
+        $this->imgdata[4][0]= 325 ;
+        $this->imgdata[4][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABQAAAASCAMAAABsDg4iAAAATl'.
+     'BMVEX///+/v79EnpxY8/FS0dJv5+dY7+9Y9vBOubtOur5m8fFG'.
+     'nKChycpW3uBX5+ZX8e2curtcvrqswsRw7OdNuLZj8/BY6udUpK'.
+     'ZT1dRX7OtNkrW5AAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgA'.
+     'AAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAxYTJgXHeN'.
+     'wwAAAAcElEQVR4nH3MyQ6AIAwEUFIqiwju2///qLQmWiJxDnN4'.
+     'mYxSv5lqGCs2nvaLLtZx/VhGOW1MjnPJWp0zsw2wsUY2jd09BY'.
+     'DFmESC+BwA5UCUxhqAhqrA4CGrLpCMVGK4sZe4B+/5RLdiyMb6'.
+     'on/PuS9CdQNC7yBXEQAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        // File: bstar_blue_001.png
+        //==========================================================
+        $this->imgdata[5][0]= 325 ;
+        $this->imgdata[5][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABQAAAASCAMAAABsDg4iAAAATl'.
+     'BMVEX///+/v79EY55Yi/NSetJvledYiO9YkPZOb7tObr5mkvFG'.
+     'X6ChrcpWgOBXhedXi/Gcpbtcf76sssRwnOxNcbhjk/NYiepUbK'.
+     'ZTfdVXh+ynNEzzAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgA'.
+     'AAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAxYTJhStyP'.
+     'zCAAAAcElEQVR4nH3MyQ6AIAwEUFIqiwju2///qLQmWiJxDnN4'.
+     'mYxSv5lqGCs2nvaLLtZx/VhGOW1MjnPJWp0zsw2wsUY2jd09BY'.
+     'DFmESC+BwA5UCUxhqAhqrA4CGrLpCMVGK4sZe4B+/5RLdiyMb6'.
+     'on/PuS9CdQNC7yBXEQAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        // File: bstar_oy_007.png
+        //==========================================================
+        $this->imgdata[6][0]= 325 ;
+        $this->imgdata[6][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABQAAAASCAMAAABsDg4iAAAATl'.
+     'BMVEX///+/v7+ejUTz11jSvVLn02/v1lj21li7q06+r07x2mag'.
+     'lUbKxKHgy1bnz1fx1Ve7t5y+qlzEwqzs03C4pE3z2WPqz1imml'.
+     'TVv1Ps01dGRjeyAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgA'.
+     'AAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAxYTJjsGGc'.
+     'GbAAAAcElEQVR4nH3MyQ6AIAwEUFIqiwju2///qLQmWiJxDnN4'.
+     'mYxSv5lqGCs2nvaLLtZx/VhGOW1MjnPJWp0zsw2wsUY2jd09BY'.
+     'DFmESC+BwA5UCUxhqAhqrA4CGrLpCMVGK4sZe4B+/5RLdiyMb6'.
+     'on/PuS9CdQNC7yBXEQAAAABJRU5ErkJggg==' ; 
+
+        //==========================================================
+        // File: bstar_lred.png
+        //==========================================================
+        $this->imgdata[7][0]= 325 ;
+        $this->imgdata[7][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABQAAAASCAMAAABsDg4iAAAATl'.
+     'BMVEX///+/v7+eRJPzWN3SUr7nb9TvWNj2WOS7Tqi+TqnxZtyg'.
+     'Ro/KocPgVsjnV9LxV927nLa+XLTErL7scN24TarzY9/qWNemVJ'.
+     'jVU8LsV9VCwcc9AAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgA'.
+     'AAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfTAxYTJxi9ZY'.
+     'GoAAAAcElEQVR4nH3MyQ6AIAwEUFIqiwju2///qLQmWiJxDnN4'.
+     'mYxSv5lqGCs2nvaLLtZx/VhGOW1MjnPJWp0zsw2wsUY2jd09BY'.
+     'DFmESC+BwA5UCUxhqAhqrA4CGrLpCMVGK4sZe4B+/5RLdiyMb6'.
+     'on/PuS9CdQNC7yBXEQAAAABJRU5ErkJggg==' ; 
+    }
+}
+
+?>
diff --git a/web/classes/jpgraph/jpg-config.inc.php b/web/classes/jpgraph/jpg-config.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..ea16c1e224ba00974073facd04bcd301518755bd
--- /dev/null
+++ b/web/classes/jpgraph/jpg-config.inc.php
@@ -0,0 +1,138 @@
+<?php
+//=======================================================================
+// File:        JPG-CONFIG.INC
+// Description: Configuration file for JpGraph library
+// Created:     2004-03-27
+// Ver:         $Id: jpg-config.inc.php 1871 2009-09-29 05:56:39Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+
+//------------------------------------------------------------------------
+// Directories for cache and font directory.
+//
+// CACHE_DIR:
+// The full absolute name of the directory to be used to store the
+// cached image files. This directory will not be used if the USE_CACHE
+// define (further down) is false. If you enable the cache please note that
+// this directory MUST be readable and writable for the process running PHP.
+// Must end with '/'
+//
+// TTF_DIR:
+// Directory where TTF fonts can be found. Must end with '/'
+//
+// The default values used if these defines are left commented out are:
+//
+// UNIX:
+//   CACHE_DIR /tmp/jpgraph_cache/
+//   TTF_DIR   /usr/share/fonts/truetype/
+//   MBTTF_DIR /usr/share/fonts/truetype/
+//
+// WINDOWS:
+//   CACHE_DIR $SERVER_TEMP/jpgraph_cache/
+//   TTF_DIR   $SERVER_SYSTEMROOT/fonts/
+//   MBTTF_DIR $SERVER_SYSTEMROOT/fonts/
+//
+//------------------------------------------------------------------------
+// define('CACHE_DIR','/tmp/jpgraph_cache/');
+// define('TTF_DIR','/usr/share/fonts/TrueType/');
+// define('MBTTF_DIR','/usr/share/fonts/TrueType/');
+
+//-------------------------------------------------------------------------
+// Cache directory specification for use with CSIM graphs that are
+// using the cache.
+// The directory must be the filesysystem name as seen by PHP
+// and the 'http' version must be the same directory but as
+// seen by the HTTP server relative to the 'htdocs' ddirectory.
+// If a relative path is specified it is taken to be relative from where
+// the image script is executed.
+// Note: The default setting is to create a subdirectory in the
+// directory from where the image script is executed and store all files
+// there. As ususal this directory must be writeable by the PHP process.
+define('CSIMCACHE_DIR','csimcache/');
+define('CSIMCACHE_HTTP_DIR','csimcache/');
+
+//------------------------------------------------------------------------
+// Various JpGraph Settings. Adjust accordingly to your
+// preferences. Note that cache functionality is turned off by
+// default (Enable by setting USE_CACHE to true)
+//------------------------------------------------------------------------
+
+// Deafult locale for error messages.
+// This defaults to English = 'en'
+define('DEFAULT_ERR_LOCALE','en');
+
+// Deafult graphic format set to 'auto' which will automatically
+// choose the best available format in the order png,gif,jpeg
+// (The supported format depends on what your PHP installation supports)
+define('DEFAULT_GFORMAT','auto');
+
+// Should the cache be used at all? By setting this to false no
+// files will be generated in the cache directory.
+// The difference from READ_CACHE being that setting READ_CACHE to
+// false will still create the image in the cache directory
+// just not use it. By setting USE_CACHE=false no files will even
+// be generated in the cache directory.
+define('USE_CACHE',false);
+
+// Should we try to find an image in the cache before generating it?
+// Set this define to false to bypass the reading of the cache and always
+// regenerate the image. Note that even if reading the cache is
+// disabled the cached will still be updated with the newly generated
+// image. Set also 'USE_CACHE' below.
+define('READ_CACHE',true);
+
+// Determine if the error handler should be image based or purely
+// text based. Image based makes it easier since the script will
+// always return an image even in case of errors.
+define('USE_IMAGE_ERROR_HANDLER',true);
+
+// Should the library examine the global php_errmsg string and convert
+// any error in it to a graphical representation. This is handy for the
+// occasions when, for example, header files cannot be found and this results
+// in the graph not being created and just a 'red-cross' image would be seen.
+// This should be turned off for a production site.
+define('CATCH_PHPERRMSG',true);
+
+// Determine if the library should also setup the default PHP
+// error handler to generate a graphic error mesage. This is useful
+// during development to be able to see the error message as an image
+// instead as a 'red-cross' in a page where an image is expected.
+define('INSTALL_PHP_ERR_HANDLER',false);
+
+// Should usage of deprecated functions and parameters give a fatal error?
+// (Useful to check if code is future proof.)
+define('ERR_DEPRECATED',true);
+
+// The builtin GD function imagettfbbox() fuction which calculates the bounding box for
+// text using TTF fonts is buggy. By setting this define to true the library
+// uses its own compensation for this bug. However this will give a
+// slightly different visual apparance than not using this compensation.
+// Enabling this compensation will in general give text a bit more space to more
+// truly reflect the actual bounding box which is a bit larger than what the
+// GD function thinks.
+define('USE_LIBRARY_IMAGETTFBBOX',true);
+
+//------------------------------------------------------------------------
+// The following constants should rarely have to be changed !
+//------------------------------------------------------------------------
+
+// What group should the cached file belong to
+// (Set to '' will give the default group for the 'PHP-user')
+// Please note that the Apache user must be a member of the
+// specified group since otherwise it is impossible for Apache
+// to set the specified group.
+define('CACHE_FILE_GROUP','www');
+
+// What permissions should the cached file have
+// (Set to '' will give the default persmissions for the 'PHP-user')
+define('CACHE_FILE_MOD',0664);
+
+// Default theme class name
+define('DEFAULT_THEME_CLASS', 'UniversalTheme');
+
+define('SUPERSAMPLING', true);
+define('SUPERSAMPLING_SCALE', 1);
+
+?>
diff --git a/web/classes/jpgraph/jpgraph.php b/web/classes/jpgraph/jpgraph.php
new file mode 100755
index 0000000000000000000000000000000000000000..0fc29c0b9972fcb79fbd7787167b4721b2cf8755
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph.php
@@ -0,0 +1,5626 @@
+<?php
+//=======================================================================
+// File:        JPGRAPH.PHP
+// Description: PHP Graph Plotting library. Base module.
+// Created:     2001-01-08
+// Ver:         $Id: jpgraph.php 1924 2010-01-11 14:03:26Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+require_once('jpg-config.inc.php');
+require_once('jpgraph_gradient.php');
+require_once('jpgraph_errhandler.inc.php');
+require_once('jpgraph_ttf.inc.php');
+require_once('jpgraph_rgb.inc.php');
+require_once('jpgraph_text.inc.php');
+require_once('jpgraph_legend.inc.php');
+require_once('jpgraph_theme.inc.php');
+require_once('gd_image.inc.php');
+
+// Version info
+define('JPG_VERSION','3.5.0b1');
+
+// Minimum required PHP version
+define('MIN_PHPVERSION','5.1.0');
+
+// Special file name to indicate that we only want to calc
+// the image map in the call to Graph::Stroke() used
+// internally from the GetHTMLCSIM() method.
+define('_CSIM_SPECIALFILE','_csim_special_');
+
+// HTTP GET argument that is used with image map
+// to indicate to the script to just generate the image
+// and not the full CSIM HTML page.
+define('_CSIM_DISPLAY','_jpg_csimd');
+
+// Special filename for Graph::Stroke(). If this filename is given
+// then the image will NOT be streamed to browser of file. Instead the
+// Stroke call will return the handler for the created GD image.
+define('_IMG_HANDLER','__handle');
+
+// Special filename for Graph::Stroke(). If this filename is given
+// the image will be stroked to a file with a name based on the script name.
+define('_IMG_AUTO','auto');
+
+// Tick density
+define("TICKD_DENSE",1);
+define("TICKD_NORMAL",2);
+define("TICKD_SPARSE",3);
+define("TICKD_VERYSPARSE",4);
+
+// Side for ticks and labels.
+define("SIDE_LEFT",-1);
+define("SIDE_RIGHT",1);
+define("SIDE_DOWN",-1);
+define("SIDE_BOTTOM",-1);
+define("SIDE_UP",1);
+define("SIDE_TOP",1);
+
+// Legend type stacked vertical or horizontal
+define("LEGEND_VERT",0);
+define("LEGEND_HOR",1);
+
+// Mark types for plot marks
+define("MARK_SQUARE",1);
+define("MARK_UTRIANGLE",2);
+define("MARK_DTRIANGLE",3);
+define("MARK_DIAMOND",4);
+define("MARK_CIRCLE",5);
+define("MARK_FILLEDCIRCLE",6);
+define("MARK_CROSS",7);
+define("MARK_STAR",8);
+define("MARK_X",9);
+define("MARK_LEFTTRIANGLE",10);
+define("MARK_RIGHTTRIANGLE",11);
+define("MARK_FLASH",12);
+define("MARK_IMG",13);
+define("MARK_FLAG1",14);
+define("MARK_FLAG2",15);
+define("MARK_FLAG3",16);
+define("MARK_FLAG4",17);
+
+// Builtin images
+define("MARK_IMG_PUSHPIN",50);
+define("MARK_IMG_SPUSHPIN",50);
+define("MARK_IMG_LPUSHPIN",51);
+define("MARK_IMG_DIAMOND",52);
+define("MARK_IMG_SQUARE",53);
+define("MARK_IMG_STAR",54);
+define("MARK_IMG_BALL",55);
+define("MARK_IMG_SBALL",55);
+define("MARK_IMG_MBALL",56);
+define("MARK_IMG_LBALL",57);
+define("MARK_IMG_BEVEL",58);
+
+// Inline defines
+define("INLINE_YES",1);
+define("INLINE_NO",0);
+
+// Format for background images
+define("BGIMG_FILLPLOT",1);
+define("BGIMG_FILLFRAME",2);
+define("BGIMG_COPY",3);
+define("BGIMG_CENTER",4);
+define("BGIMG_FREE",5);
+
+// Depth of objects
+define("DEPTH_BACK",0);
+define("DEPTH_FRONT",1);
+
+// Direction
+define("VERTICAL",1);
+define("HORIZONTAL",0);
+
+// Axis styles for scientific style axis
+define('AXSTYLE_SIMPLE',1);
+define('AXSTYLE_BOXIN',2);
+define('AXSTYLE_BOXOUT',3);
+define('AXSTYLE_YBOXIN',4);
+define('AXSTYLE_YBOXOUT',5);
+
+// Style for title backgrounds
+define('TITLEBKG_STYLE1',1);
+define('TITLEBKG_STYLE2',2);
+define('TITLEBKG_STYLE3',3);
+define('TITLEBKG_FRAME_NONE',0);
+define('TITLEBKG_FRAME_FULL',1);
+define('TITLEBKG_FRAME_BOTTOM',2);
+define('TITLEBKG_FRAME_BEVEL',3);
+define('TITLEBKG_FILLSTYLE_HSTRIPED',1);
+define('TITLEBKG_FILLSTYLE_VSTRIPED',2);
+define('TITLEBKG_FILLSTYLE_SOLID',3);
+
+// Styles for axis labels background
+define('LABELBKG_NONE',0);
+define('LABELBKG_XAXIS',1);
+define('LABELBKG_YAXIS',2);
+define('LABELBKG_XAXISFULL',3);
+define('LABELBKG_YAXISFULL',4);
+define('LABELBKG_XYFULL',5);
+define('LABELBKG_XY',6);
+
+
+// Style for background gradient fills
+define('BGRAD_FRAME',1);
+define('BGRAD_MARGIN',2);
+define('BGRAD_PLOT',3);
+
+// Width of tab titles
+define('TABTITLE_WIDTHFIT',0);
+define('TABTITLE_WIDTHFULL',-1);
+
+// Defines for 3D skew directions
+define('SKEW3D_UP',0);
+define('SKEW3D_DOWN',1);
+define('SKEW3D_LEFT',2);
+define('SKEW3D_RIGHT',3);
+
+// For internal use only
+define("_JPG_DEBUG",false);
+define("_FORCE_IMGTOFILE",false);
+define("_FORCE_IMGDIR",'/tmp/jpgimg/');
+
+
+//
+// Automatic settings of path for cache and font directory
+// if they have not been previously specified
+//
+if(USE_CACHE) {
+    if (!defined('CACHE_DIR')) {
+        if ( strstr( PHP_OS, 'WIN') ) {
+            if( empty($_SERVER['TEMP']) ) {
+                $t = new ErrMsgText();
+                $msg = $t->Get(11,$file,$lineno);
+                die($msg);
+            }
+            else {
+                define('CACHE_DIR', $_SERVER['TEMP'] . '/');
+            }
+        } else {
+            define('CACHE_DIR','/tmp/jpgraph_cache/');
+        }
+    }
+}
+elseif( !defined('CACHE_DIR') ) {
+    define('CACHE_DIR', '');
+}
+
+//
+// Setup path for western/latin TTF fonts
+//
+if (!defined('TTF_DIR')) {
+    if (strstr( PHP_OS, 'WIN') ) {
+        $sroot = getenv('SystemRoot');
+        if( empty($sroot) ) {
+            $t = new ErrMsgText();
+            $msg = $t->Get(12,$file,$lineno);
+            die($msg);
+        }
+        else {
+            define('TTF_DIR', $sroot.'/fonts/');
+        }
+    } else {
+        define('TTF_DIR','/usr/share/fonts/truetype/');
+    }
+}
+
+//
+// Setup path for MultiByte TTF fonts (japanese, chinese etc.)
+//
+if (!defined('MBTTF_DIR')) {
+    if (strstr( PHP_OS, 'WIN') ) {
+        $sroot = getenv('SystemRoot');
+        if( empty($sroot) ) {
+            $t = new ErrMsgText();
+            $msg = $t->Get(12,$file,$lineno);
+            die($msg);
+        }
+        else {
+            define('MBTTF_DIR', $sroot.'/fonts/');
+        }
+    } else {
+        define('MBTTF_DIR','/usr/share/fonts/truetype/');
+    }
+}
+
+//
+// Check minimum PHP version
+//
+function CheckPHPVersion($aMinVersion) {
+    list($majorC, $minorC, $editC) = preg_split('/[\/.-]/', PHP_VERSION);
+    list($majorR, $minorR, $editR) = preg_split('/[\/.-]/', $aMinVersion);
+
+    if ($majorC != $majorR) return false;
+    if ($majorC < $majorR) return false;
+    // same major - check minor
+    if ($minorC > $minorR) return true;
+    if ($minorC < $minorR) return false;
+    // and same minor
+    if ($editC  >= $editR)  return true;
+    return true;
+}
+
+//
+// Make sure PHP version is high enough
+//
+if( !CheckPHPVersion(MIN_PHPVERSION) ) {
+    JpGraphError::RaiseL(13,PHP_VERSION,MIN_PHPVERSION);
+    die();
+}
+
+//
+// Make GD sanity check
+//
+if( !function_exists("imagetypes") || !function_exists('imagecreatefromstring') ) {
+    JpGraphError::RaiseL(25001);
+    //("This PHP installation is not configured with the GD library. Please recompile PHP with GD support to run JpGraph. (Neither function imagetypes() nor imagecreatefromstring() does exist)");
+}
+
+//
+// Setup PHP error handler
+//
+function _phpErrorHandler($errno,$errmsg,$filename, $linenum, $vars) {
+    // Respect current error level
+    if( $errno & error_reporting() ) {
+        JpGraphError::RaiseL(25003,basename($filename),$linenum,$errmsg);
+    }
+}
+
+if( INSTALL_PHP_ERR_HANDLER ) {
+    set_error_handler("_phpErrorHandler");
+}
+
+//
+// Check if there were any warnings, perhaps some wrong includes by the user. In this
+// case we raise it immediately since otherwise the image will not show and makes
+// debugging difficult. This is controlled by the user setting CATCH_PHPERRMSG
+//
+if( isset($GLOBALS['php_errormsg']) && CATCH_PHPERRMSG && !preg_match('/|Deprecated|/i', $GLOBALS['php_errormsg']) ) {
+    JpGraphError::RaiseL(25004,$GLOBALS['php_errormsg']);
+}
+
+// Useful mathematical function
+function sign($a) {return $a >= 0 ? 1 : -1;}
+
+//
+// Utility function to generate an image name based on the filename we
+// are running from and assuming we use auto detection of graphic format
+// (top level), i.e it is safe to call this function
+// from a script that uses JpGraph
+//
+function GenImgName() {
+    // Determine what format we should use when we save the images
+    $supported = imagetypes();
+    if( $supported & IMG_PNG )    $img_format="png";
+    elseif( $supported & IMG_GIF ) $img_format="gif";
+    elseif( $supported & IMG_JPG ) $img_format="jpeg";
+    elseif( $supported & IMG_WBMP ) $img_format="wbmp";
+    elseif( $supported & IMG_XPM ) $img_format="xpm";
+
+
+    if( !isset($_SERVER['PHP_SELF']) ) {
+        JpGraphError::RaiseL(25005);
+        //(" Can't access PHP_SELF, PHP global variable. You can't run PHP from command line if you want to use the 'auto' naming of cache or image files.");
+    }
+    $fname = basename($_SERVER['PHP_SELF']);
+    if( !empty($_SERVER['QUERY_STRING']) ) {
+        $q = @$_SERVER['QUERY_STRING'];
+        $fname .= '_'.preg_replace("/\W/", "_", $q).'.'.$img_format;
+    }
+    else {
+        $fname = substr($fname,0,strlen($fname)-4).'.'.$img_format;
+    }
+    return $fname;
+}
+
+//===================================================
+// CLASS JpgTimer
+// Description: General timing utility class to handle
+// time measurement of generating graphs. Multiple
+// timers can be started.
+//===================================================
+class JpgTimer {
+    private $start, $idx;
+
+    function __construct() {
+        $this->idx=0;
+    }
+
+    // Push a new timer start on stack
+    function Push() {
+        list($ms,$s)=explode(" ",microtime());
+        $this->start[$this->idx++]=floor($ms*1000) + 1000*$s;
+    }
+
+    // Pop the latest timer start and return the diff with the
+    // current time
+    function Pop() {
+        assert($this->idx>0);
+        list($ms,$s)=explode(" ",microtime());
+        $etime=floor($ms*1000) + (1000*$s);
+        $this->idx--;
+        return $etime-$this->start[$this->idx];
+    }
+} // Class
+
+//===================================================
+// CLASS DateLocale
+// Description: Hold localized text used in dates
+//===================================================
+class DateLocale {
+
+    public $iLocale = 'C'; // environmental locale be used by default
+    private $iDayAbb = null, $iShortDay = null, $iShortMonth = null, $iMonthName = null;
+
+    function __construct() {
+        settype($this->iDayAbb, 'array');
+        settype($this->iShortDay, 'array');
+        settype($this->iShortMonth, 'array');
+        settype($this->iMonthName, 'array');
+        $this->Set('C');
+    }
+
+    function Set($aLocale) {
+        if ( in_array($aLocale, array_keys($this->iDayAbb)) ){
+            $this->iLocale = $aLocale;
+            return TRUE;  // already cached nothing else to do!
+        }
+
+        $pLocale = setlocale(LC_TIME, 0); // get current locale for LC_TIME
+
+        if (is_array($aLocale)) {
+            foreach ($aLocale as $loc) {
+                $res = @setlocale(LC_TIME, $loc);
+                if ( $res ) {
+                    $aLocale = $loc;
+                    break;
+                }
+            }
+        }
+        else {
+            $res = @setlocale(LC_TIME, $aLocale);
+        }
+
+        if ( ! $res ) {
+            JpGraphError::RaiseL(25007,$aLocale);
+            //("You are trying to use the locale ($aLocale) which your PHP installation does not support. Hint: Use '' to indicate the default locale for this geographic region.");
+            return FALSE;
+        }
+
+        $this->iLocale = $aLocale;
+        for( $i = 0, $ofs = 0 - strftime('%w'); $i < 7; $i++, $ofs++ ) {
+            $day = strftime('%a', strtotime("$ofs day"));
+            $day[0] = strtoupper($day[0]);
+            $this->iDayAbb[$aLocale][]= $day[0];
+            $this->iShortDay[$aLocale][]= $day;
+        }
+
+        for($i=1; $i<=12; ++$i) {
+            list($short ,$full) = explode('|', strftime("%b|%B",strtotime("2001-$i-01")));
+            $this->iShortMonth[$aLocale][] = ucfirst($short);
+            $this->iMonthName [$aLocale][] = ucfirst($full);
+        }
+
+        setlocale(LC_TIME, $pLocale);
+
+        return TRUE;
+    }
+
+
+    function GetDayAbb() {
+        return $this->iDayAbb[$this->iLocale];
+    }
+
+    function GetShortDay() {
+        return $this->iShortDay[$this->iLocale];
+    }
+
+    function GetShortMonth() {
+        return $this->iShortMonth[$this->iLocale];
+    }
+
+    function GetShortMonthName($aNbr) {
+        return $this->iShortMonth[$this->iLocale][$aNbr];
+    }
+
+    function GetLongMonthName($aNbr) {
+        return $this->iMonthName[$this->iLocale][$aNbr];
+    }
+
+    function GetMonth() {
+        return $this->iMonthName[$this->iLocale];
+    }
+}
+
+// Global object handlers
+$gDateLocale = new DateLocale();
+$gJpgDateLocale = new DateLocale();
+
+//=======================================================
+// CLASS Footer
+// Description: Encapsulates the footer line in the Graph
+//=======================================================
+class Footer {
+    public $iLeftMargin = 3, $iRightMargin = 3, $iBottomMargin = 3 ;
+    public $left,$center,$right;
+    private $iTimer=null, $itimerpoststring='';
+
+    function __construct() {
+        $this->left = new Text();
+        $this->left->ParagraphAlign('left');
+        $this->center = new Text();
+        $this->center->ParagraphAlign('center');
+        $this->right = new Text();
+        $this->right->ParagraphAlign('right');
+    }
+
+    function SetTimer($aTimer,$aTimerPostString='') {
+        $this->iTimer = $aTimer;
+        $this->itimerpoststring = $aTimerPostString;
+    }
+
+    function SetMargin($aLeft=3,$aRight=3,$aBottom=3) {
+        $this->iLeftMargin = $aLeft;
+        $this->iRightMargin = $aRight;
+        $this->iBottomMargin = $aBottom;
+    }
+
+    function Stroke($aImg) {
+        $y = $aImg->height - $this->iBottomMargin;
+        $x = $this->iLeftMargin;
+        $this->left->Align('left','bottom');
+        $this->left->Stroke($aImg,$x,$y);
+
+        $x = ($aImg->width - $this->iLeftMargin - $this->iRightMargin)/2;
+        $this->center->Align('center','bottom');
+        $this->center->Stroke($aImg,$x,$y);
+
+        $x = $aImg->width - $this->iRightMargin;
+        $this->right->Align('right','bottom');
+        if( $this->iTimer != null ) {
+            $this->right->Set( $this->right->t . sprintf('%.3f',$this->iTimer->Pop()/1000.0) . $this->itimerpoststring );
+        }
+        $this->right->Stroke($aImg,$x,$y);
+    }
+}
+
+
+//===================================================
+// CLASS Graph
+// Description: Main class to handle graphs
+//===================================================
+class Graph {
+    public $cache=null;   // Cache object (singleton)
+    public $img=null;   // Img object (singleton)
+    public $plots=array();  // Array of all plot object in the graph (for Y 1 axis)
+    public $y2plots=array();  // Array of all plot object in the graph (for Y 2 axis)
+    public $ynplots=array();
+    public $xscale=null;  // X Scale object (could be instance of LinearScale or LogScale
+    public $yscale=null,$y2scale=null, $ynscale=array();
+    public $iIcons = array();  // Array of Icons to add to
+    public $cache_name;   // File name to be used for the current graph in the cache directory
+    public $xgrid=null;   // X Grid object (linear or logarithmic)
+    public $ygrid=null,$y2grid=null; //dito for Y
+    public $doframe,$frame_color, $frame_weight; // Frame around graph
+    public $boxed=false, $box_color='black', $box_weight=1;  // Box around plot area
+    public $doshadow=false,$shadow_width=4,$shadow_color='gray@0.5'; // Shadow for graph
+    public $xaxis=null;   // X-axis (instane of Axis class)
+    public $yaxis=null, $y2axis=null, $ynaxis=array(); // Y axis (instance of Axis class)
+    public $margin_color; // Margin color of graph
+    public $plotarea_color=array(255,255,255); // Plot area color
+    public $title,$subtitle,$subsubtitle;  // Title and subtitle(s) text object
+    public $axtype="linlin";  // Type of axis
+    public $xtick_factor,$ytick_factor; // Factor to determine the maximum number of ticks depending on the plot width
+    public $texts=null, $y2texts=null; // Text object to ge shown in the graph
+    public $lines=null, $y2lines=null;
+    public $bands=null, $y2bands=null;
+    public $text_scale_off=0, $text_scale_abscenteroff=-1; // Text scale in fractions and for centering bars
+    public $background_image='',$background_image_type=-1,$background_image_format="png";
+    public $background_image_bright=0,$background_image_contr=0,$background_image_sat=0;
+    public $background_image_xpos=0,$background_image_ypos=0;
+    public $image_bright=0, $image_contr=0, $image_sat=0;
+    public $inline;
+    public $showcsim=0,$csimcolor="red";//debug stuff, draw the csim boundaris on the image if <>0
+    public $grid_depth=DEPTH_BACK; // Draw grid under all plots as default
+    public $iAxisStyle = AXSTYLE_SIMPLE;
+    public $iCSIMdisplay=false,$iHasStroked = false;
+    public $footer;
+    public $csimcachename = '', $csimcachetimeout = 0, $iCSIMImgAlt='';
+    public $iDoClipping = false;
+    public $y2orderback=true;
+    public $tabtitle;
+    public $bkg_gradtype=-1,$bkg_gradstyle=BGRAD_MARGIN;
+    public $bkg_gradfrom='navy', $bkg_gradto='silver';
+    public $plot_gradtype=-1,$plot_gradstyle=BGRAD_MARGIN;
+    public $plot_gradfrom='silver', $plot_gradto='navy';
+
+    public $titlebackground = false;
+    public $titlebackground_color = 'lightblue',
+           $titlebackground_style = 1,
+           $titlebackground_framecolor,
+           $titlebackground_framestyle,
+           $titlebackground_frameweight,
+           $titlebackground_bevelheight;
+    public $titlebkg_fillstyle=TITLEBKG_FILLSTYLE_SOLID;
+    public $titlebkg_scolor1='black',$titlebkg_scolor2='white';
+    public $framebevel, $framebeveldepth;
+    public $framebevelborder, $framebevelbordercolor;
+    public $framebevelcolor1, $framebevelcolor2;
+    public $background_image_mix=100;
+    public $background_cflag = '';
+    public $background_cflag_type = BGIMG_FILLPLOT;
+    public $background_cflag_mix = 100;
+    public $iImgTrans=false,
+           $iImgTransHorizon = 100,$iImgTransSkewDist=150,
+           $iImgTransDirection = 1, $iImgTransMinSize = true,
+           $iImgTransFillColor='white',$iImgTransHighQ=false,
+           $iImgTransBorder=false,$iImgTransHorizonPos=0.5;
+    public $legend;
+    public $graph_theme;
+    protected $iYAxisDeltaPos=50;
+    protected $iIconDepth=DEPTH_BACK;
+    protected $iAxisLblBgType = 0,
+              $iXAxisLblBgFillColor = 'lightgray', $iXAxisLblBgColor = 'black',
+              $iYAxisLblBgFillColor = 'lightgray', $iYAxisLblBgColor = 'black';
+    protected $iTables=NULL;
+
+    protected $isRunningClear = false;
+    protected $inputValues;
+    protected $isAfterSetScale = false;
+
+    // aWIdth   Width in pixels of image
+    // aHeight   Height in pixels of image
+    // aCachedName Name for image file in cache directory
+    // aTimeOut  Timeout in minutes for image in cache
+    // aInline  If true the image is streamed back in the call to Stroke()
+    //   If false the image is just created in the cache
+    function __construct($aWidth=300,$aHeight=200,$aCachedName='',$aTimeout=0,$aInline=true) {
+
+        if( !is_numeric($aWidth) || !is_numeric($aHeight) ) {
+            JpGraphError::RaiseL(25008);//('Image width/height argument in Graph::Graph() must be numeric');
+        }
+
+        // Initialize frame and margin
+        $this->InitializeFrameAndMargin();
+
+        // Automatically generate the image file name based on the name of the script that
+        // generates the graph
+        if( $aCachedName == 'auto' ) {
+            $aCachedName=GenImgName();
+        }
+
+        // Should the image be streamed back to the browser or only to the cache?
+        $this->inline=$aInline;
+
+        $this->img = new RotImage($aWidth,$aHeight);
+        $this->cache  = new ImgStreamCache();
+
+        // Window doesn't like '?' in the file name so replace it with an '_'
+        $aCachedName = str_replace("?","_",$aCachedName);
+        $this->SetupCache($aCachedName, $aTimeout);
+
+        $this->title = new Text();
+        $this->title->ParagraphAlign('center');
+        $this->title->SetFont(FF_DEFAULT,FS_NORMAL); //FF_FONT2, FS_BOLD
+        $this->title->SetMargin(5);
+        $this->title->SetAlign('center');
+
+        $this->subtitle = new Text();
+        $this->subtitle->ParagraphAlign('center');
+        $this->subtitle->SetMargin(3);
+        $this->subtitle->SetAlign('center');
+
+        $this->subsubtitle = new Text();
+        $this->subsubtitle->ParagraphAlign('center');
+        $this->subsubtitle->SetMargin(3);
+        $this->subsubtitle->SetAlign('center');
+
+        $this->legend = new Legend();
+        $this->footer = new Footer();
+
+        // If the cached version exist just read it directly from the
+        // cache, stream it back to browser and exit
+        if( $aCachedName!='' && READ_CACHE && $aInline ) {
+            if( $this->cache->GetAndStream($this->img,$aCachedName) ) {
+                exit();
+            }
+        }
+
+        $this->SetTickDensity(); // Normal density
+
+        $this->tabtitle = new GraphTabTitle();
+
+        if (!$this->isRunningClear) {
+            $this->inputValues = array();
+            $this->inputValues['aWidth'] = $aWidth;
+            $this->inputValues['aHeight'] = $aHeight;
+            $this->inputValues['aCachedName'] = $aCachedName;
+            $this->inputValues['aTimeout'] = $aTimeout;
+            $this->inputValues['aInline'] = $aInline;
+
+            $theme_class = DEFAULT_THEME_CLASS;
+            if (class_exists($theme_class)) {
+                $this->graph_theme = new $theme_class();
+            }
+        }
+    }
+
+    function InitializeFrameAndMargin() {
+        $this->doframe=true;
+        $this->frame_color='black';
+        $this->frame_weight=1; 
+
+        $this->titlebackground_framecolor = 'blue';
+        $this->titlebackground_framestyle = 2;
+        $this->titlebackground_frameweight = 1;
+        $this->titlebackground_bevelheight = 3;
+        $this->titlebkg_fillstyle=TITLEBKG_FILLSTYLE_SOLID;
+        $this->titlebkg_scolor1='black';
+        $this->titlebkg_scolor2='white';
+        $this->framebevel = false;
+        $this->framebeveldepth = 2;
+        $this->framebevelborder = false;
+        $this->framebevelbordercolor='black';
+        $this->framebevelcolor1='white@0.4';
+        $this->framebevelcolor2='black@0.4';
+
+        $this->margin_color = array(250,250,250);
+    }
+
+    function SetupCache($aFilename,$aTimeout=60) {
+        $this->cache_name = $aFilename;
+        $this->cache->SetTimeOut($aTimeout);
+    }
+
+    // Enable final image perspective transformation
+    function Set3DPerspective($aDir=1,$aHorizon=100,$aSkewDist=120,$aQuality=false,$aFillColor='#FFFFFF',$aBorder=false,$aMinSize=true,$aHorizonPos=0.5) {
+        $this->iImgTrans = true;
+        $this->iImgTransHorizon = $aHorizon;
+        $this->iImgTransSkewDist= $aSkewDist;
+        $this->iImgTransDirection = $aDir;
+        $this->iImgTransMinSize = $aMinSize;
+        $this->iImgTransFillColor=$aFillColor;
+        $this->iImgTransHighQ=$aQuality;
+        $this->iImgTransBorder=$aBorder;
+        $this->iImgTransHorizonPos=$aHorizonPos;
+    }
+
+    function SetUserFont($aNormal,$aBold='',$aItalic='',$aBoldIt='') {
+        $this->img->ttf->SetUserFont($aNormal,$aBold,$aItalic,$aBoldIt);
+    }
+
+    function SetUserFont1($aNormal,$aBold='',$aItalic='',$aBoldIt='') {
+        $this->img->ttf->SetUserFont1($aNormal,$aBold,$aItalic,$aBoldIt);
+    }
+
+    function SetUserFont2($aNormal,$aBold='',$aItalic='',$aBoldIt='') {
+        $this->img->ttf->SetUserFont2($aNormal,$aBold,$aItalic,$aBoldIt);
+    }
+
+    function SetUserFont3($aNormal,$aBold='',$aItalic='',$aBoldIt='') {
+        $this->img->ttf->SetUserFont3($aNormal,$aBold,$aItalic,$aBoldIt);
+    }
+
+    // Set Image format and optional quality
+    function SetImgFormat($aFormat,$aQuality=75) {
+        $this->img->SetImgFormat($aFormat,$aQuality);
+    }
+
+    // Should the grid be in front or back of the plot?
+    function SetGridDepth($aDepth) {
+        $this->grid_depth=$aDepth;
+    }
+
+    function SetIconDepth($aDepth) {
+        $this->iIconDepth=$aDepth;
+    }
+
+    // Specify graph angle 0-360 degrees.
+    function SetAngle($aAngle) {
+        $this->img->SetAngle($aAngle);
+    }
+
+    function SetAlphaBlending($aFlg=true) {
+        $this->img->SetAlphaBlending($aFlg);
+    }
+
+    // Shortcut to image margin
+    function SetMargin($lm,$rm,$tm,$bm) {
+        $this->img->SetMargin($lm,$rm,$tm,$bm);
+    }
+
+    function SetY2OrderBack($aBack=true) {
+        $this->y2orderback = $aBack;
+    }
+
+    // Rotate the graph 90 degrees and set the margin
+    // when we have done a 90 degree rotation
+    function Set90AndMargin($lm=0,$rm=0,$tm=0,$bm=0) {
+        $lm = $lm ==0 ? floor(0.2 * $this->img->width)  : $lm ;
+        $rm = $rm ==0 ? floor(0.1 * $this->img->width)  : $rm ;
+        $tm = $tm ==0 ? floor(0.2 * $this->img->height) : $tm ;
+        $bm = $bm ==0 ? floor(0.1 * $this->img->height) : $bm ;
+
+        $adj = ($this->img->height - $this->img->width)/2;
+        $this->img->SetMargin($tm-$adj,$bm-$adj,$rm+$adj,$lm+$adj);
+        $this->img->SetCenter(floor($this->img->width/2),floor($this->img->height/2));
+        $this->SetAngle(90);
+        if( empty($this->yaxis) || empty($this->xaxis) ) {
+            JpgraphError::RaiseL(25009);//('You must specify what scale to use with a call to Graph::SetScale()');
+        }
+        $this->xaxis->SetLabelAlign('right','center');
+        $this->yaxis->SetLabelAlign('center','bottom');
+    }
+
+    function SetClipping($aFlg=true) {
+        $this->iDoClipping = $aFlg ;
+    }
+
+    // Add a plot object to the graph
+    function Add($aPlot) {
+        if( $aPlot == null ) {
+            JpGraphError::RaiseL(25010);//("Graph::Add() You tried to add a null plot to the graph.");
+        }
+        if( is_array($aPlot) && count($aPlot) > 0 ) {
+            $cl = $aPlot[0];
+        }
+        else {
+            $cl = $aPlot;
+        }
+
+        if( $cl instanceof Text ) $this->AddText($aPlot);
+        elseif( class_exists('PlotLine',false) && ($cl instanceof PlotLine) )  $this->AddLine($aPlot);
+        elseif( class_exists('PlotBand',false) && ($cl instanceof PlotBand) ) $this->AddBand($aPlot);
+        elseif( class_exists('IconPlot',false) && ($cl instanceof IconPlot) ) $this->AddIcon($aPlot);
+        elseif( class_exists('GTextTable',false) && ($cl instanceof GTextTable) ) $this->AddTable($aPlot);
+        else {
+            if( is_array($aPlot) ) {
+                $this->plots = array_merge($this->plots,$aPlot);
+            }
+            else {
+                $this->plots[] = $aPlot;
+            }
+        }
+
+        if ($this->graph_theme) {
+            $this->graph_theme->SetupPlot($aPlot);
+        }
+    }
+
+    function AddTable($aTable) {
+        if( is_array($aTable) ) {
+            for($i=0; $i < count($aTable); ++$i ) {
+                $this->iTables[]=$aTable[$i];
+            }
+        }
+        else {
+            $this->iTables[] = $aTable ;
+        }
+    }
+
+    function AddIcon($aIcon) {
+        if( is_array($aIcon) ) {
+            for($i=0; $i < count($aIcon); ++$i ) {
+                $this->iIcons[]=$aIcon[$i];
+            }
+        }
+        else {
+            $this->iIcons[] = $aIcon ;
+        }
+    }
+
+    // Add plot to second Y-scale
+    function AddY2($aPlot) {
+        if( $aPlot == null ) {
+            JpGraphError::RaiseL(25011);//("Graph::AddY2() You tried to add a null plot to the graph.");
+        }
+
+        if( is_array($aPlot) && count($aPlot) > 0 ) {
+            $cl = $aPlot[0];
+        }
+        else {
+            $cl = $aPlot;
+        }
+
+        if( $cl instanceof Text ) {
+            $this->AddText($aPlot,true);
+        }
+        elseif( class_exists('PlotLine',false) && ($cl instanceof PlotLine) ) {
+            $this->AddLine($aPlot,true);
+        }
+        elseif( class_exists('PlotBand',false) && ($cl instanceof PlotBand) ) {
+            $this->AddBand($aPlot,true);
+        }
+        else {
+            $this->y2plots[] = $aPlot;
+        }
+
+        if ($this->graph_theme) {
+            $this->graph_theme->SetupPlot($aPlot);
+        }
+    }
+
+    // Add plot to the extra Y-axises
+    function AddY($aN,$aPlot) {
+
+        if( $aPlot == null ) {
+            JpGraphError::RaiseL(25012);//("Graph::AddYN() You tried to add a null plot to the graph.");
+        }
+
+        if( is_array($aPlot) && count($aPlot) > 0 ) {
+            $cl = $aPlot[0];
+        }
+        else {
+            $cl = $aPlot;
+        }
+
+        if( ($cl instanceof Text) ||
+            (class_exists('PlotLine',false) && ($cl instanceof PlotLine)) ||
+            (class_exists('PlotBand',false) && ($cl instanceof PlotBand)) ) {
+            JpGraph::RaiseL(25013);//('You can only add standard plots to multiple Y-axis');
+        }
+        else {
+            $this->ynplots[$aN][] = $aPlot;
+        }
+
+        if ($this->graph_theme) {
+            $this->graph_theme->SetupPlot($aPlot);
+        }
+    }
+
+    // Add text object to the graph
+    function AddText($aTxt,$aToY2=false) {
+        if( $aTxt == null ) {
+            JpGraphError::RaiseL(25014);//("Graph::AddText() You tried to add a null text to the graph.");
+        }
+        if( $aToY2 ) {
+            if( is_array($aTxt) ) {
+                for($i=0; $i < count($aTxt); ++$i ) {
+                    $this->y2texts[]=$aTxt[$i];
+                }
+            }
+            else {
+                $this->y2texts[] = $aTxt;
+            }
+        }
+        else {
+            if( is_array($aTxt) ) {
+                for($i=0; $i < count($aTxt); ++$i ) {
+                    $this->texts[]=$aTxt[$i];
+                }
+            }
+            else {
+                $this->texts[] = $aTxt;
+            }
+        }
+    }
+
+    // Add a line object (class PlotLine) to the graph
+    function AddLine($aLine,$aToY2=false) {
+        if( $aLine == null ) {
+            JpGraphError::RaiseL(25015);//("Graph::AddLine() You tried to add a null line to the graph.");
+        }
+
+        if( $aToY2 ) {
+            if( is_array($aLine) ) {
+                for($i=0; $i < count($aLine); ++$i ) {
+                    //$this->y2lines[]=$aLine[$i];
+                    $this->y2plots[]=$aLine[$i];
+                }
+            }
+            else {
+                //$this->y2lines[] = $aLine;
+                $this->y2plots[]=$aLine;
+            }
+        }
+        else {
+            if( is_array($aLine) ) {
+                for($i=0; $i<count($aLine); ++$i ) {
+                    //$this->lines[]=$aLine[$i];
+                    $this->plots[]=$aLine[$i];
+                }
+            }
+            else {
+                //$this->lines[] = $aLine;
+                $this->plots[] = $aLine;
+            }
+        }
+    }
+
+    // Add vertical or horizontal band
+    function AddBand($aBand,$aToY2=false) {
+        if( $aBand == null ) {
+            JpGraphError::RaiseL(25016);//(" Graph::AddBand() You tried to add a null band to the graph.");
+        }
+
+        if( $aToY2 ) {
+            if( is_array($aBand) ) {
+                for($i=0; $i < count($aBand); ++$i ) {
+                    $this->y2bands[] = $aBand[$i];
+                }
+            }
+            else {
+                $this->y2bands[] = $aBand;
+            }
+        }
+        else {
+            if( is_array($aBand) ) {
+                for($i=0; $i < count($aBand); ++$i ) {
+                    $this->bands[] = $aBand[$i];
+                }
+            }
+            else {
+                $this->bands[] = $aBand;
+            }
+        }
+    }
+
+    function SetPlotGradient($aFrom='navy',$aTo='silver',$aGradType=2) {
+        $this->plot_gradtype=$aGradType;
+        $this->plot_gradfrom = $aFrom;
+        $this->plot_gradto = $aTo;
+    }
+
+    function SetBackgroundGradient($aFrom='navy',$aTo='silver',$aGradType=2,$aStyle=BGRAD_FRAME) {
+        $this->bkg_gradtype=$aGradType;
+        $this->bkg_gradstyle=$aStyle;
+        $this->bkg_gradfrom = $aFrom;
+        $this->bkg_gradto = $aTo;
+    }
+
+    // Set a country flag in the background
+    function SetBackgroundCFlag($aName,$aBgType=BGIMG_FILLPLOT,$aMix=100) {
+        $this->background_cflag = $aName;
+        $this->background_cflag_type = $aBgType;
+        $this->background_cflag_mix = $aMix;
+    }
+
+    // Alias for the above method
+    function SetBackgroundCountryFlag($aName,$aBgType=BGIMG_FILLPLOT,$aMix=100) {
+        $this->background_cflag = $aName;
+        $this->background_cflag_type = $aBgType;
+        $this->background_cflag_mix = $aMix;
+    }
+
+
+    // Specify a background image
+    function SetBackgroundImage($aFileName,$aBgType=BGIMG_FILLPLOT,$aImgFormat='auto') {
+
+        // Get extension to determine image type
+        if( $aImgFormat == 'auto' ) {
+            $e = explode('.',$aFileName);
+            if( !$e ) {
+                JpGraphError::RaiseL(25018,$aFileName);//('Incorrect file name for Graph::SetBackgroundImage() : '.$aFileName.' Must have a valid image extension (jpg,gif,png) when using autodetection of image type');
+            }
+
+            $valid_formats = array('png', 'jpg', 'gif');
+            $aImgFormat = strtolower($e[count($e)-1]);
+            if ($aImgFormat == 'jpeg')  {
+                $aImgFormat = 'jpg';
+            }
+            elseif (!in_array($aImgFormat, $valid_formats) )  {
+                JpGraphError::RaiseL(25019,$aImgFormat);//('Unknown file extension ($aImgFormat) in Graph::SetBackgroundImage() for filename: '.$aFileName);
+            }
+        }
+
+        $this->background_image = $aFileName;
+        $this->background_image_type=$aBgType;
+        $this->background_image_format=$aImgFormat;
+    }
+
+    function SetBackgroundImageMix($aMix) {
+        $this->background_image_mix = $aMix ;
+    }
+
+    // Adjust background image position
+    function SetBackgroundImagePos($aXpos,$aYpos) {
+        $this->background_image_xpos = $aXpos ;
+        $this->background_image_ypos = $aYpos ;
+    }
+
+    // Specify axis style (boxed or single)
+    function SetAxisStyle($aStyle) {
+        $this->iAxisStyle = $aStyle ;
+    }
+
+    // Set a frame around the plot area
+    function SetBox($aDrawPlotFrame=true,$aPlotFrameColor=array(0,0,0),$aPlotFrameWeight=1) {
+        $this->boxed = $aDrawPlotFrame;
+        $this->box_weight = $aPlotFrameWeight;
+        $this->box_color = $aPlotFrameColor;
+    }
+
+    // Specify color for the plotarea (not the margins)
+    function SetColor($aColor) {
+        $this->plotarea_color=$aColor;
+    }
+
+    // Specify color for the margins (all areas outside the plotarea)
+    function SetMarginColor($aColor) {
+        $this->margin_color=$aColor;
+    }
+
+    // Set a frame around the entire image
+    function SetFrame($aDrawImgFrame=true,$aImgFrameColor=array(0,0,0),$aImgFrameWeight=1) {
+        $this->doframe = $aDrawImgFrame;
+        $this->frame_color = $aImgFrameColor;
+        $this->frame_weight = $aImgFrameWeight;
+    }
+
+    function SetFrameBevel($aDepth=3,$aBorder=false,$aBorderColor='black',$aColor1='white@0.4',$aColor2='darkgray@0.4',$aFlg=true) {
+        $this->framebevel = $aFlg ;
+        $this->framebeveldepth = $aDepth ;
+        $this->framebevelborder = $aBorder ;
+        $this->framebevelbordercolor = $aBorderColor ;
+        $this->framebevelcolor1 = $aColor1 ;
+        $this->framebevelcolor2 = $aColor2 ;
+
+        $this->doshadow = false ;
+    }
+
+    // Set the shadow around the whole image
+    function SetShadow($aShowShadow=true,$aShadowWidth=5,$aShadowColor='darkgray') {
+        $this->doshadow = $aShowShadow;
+        $this->shadow_color = $aShadowColor;
+        $this->shadow_width = $aShadowWidth;
+        $this->footer->iBottomMargin += $aShadowWidth;
+        $this->footer->iRightMargin += $aShadowWidth;
+    }
+
+    // Specify x,y scale. Note that if you manually specify the scale
+    // you must also specify the tick distance with a call to Ticks::Set()
+    function SetScale($aAxisType,$aYMin=1,$aYMax=1,$aXMin=1,$aXMax=1) {
+        $this->axtype = $aAxisType;
+
+        if( $aYMax < $aYMin || $aXMax < $aXMin ) {
+            JpGraphError::RaiseL(25020);//('Graph::SetScale(): Specified Max value must be larger than the specified Min value.');
+        }
+
+        $yt=substr($aAxisType,-3,3);
+        if( $yt == 'lin' ) {
+            $this->yscale = new LinearScale($aYMin,$aYMax);
+        }
+        elseif( $yt == 'int' ) {
+            $this->yscale = new LinearScale($aYMin,$aYMax);
+            $this->yscale->SetIntScale();
+        }
+        elseif( $yt == 'log' ) {
+            $this->yscale = new LogScale($aYMin,$aYMax);
+        }
+        else {
+            JpGraphError::RaiseL(25021,$aAxisType);//("Unknown scale specification for Y-scale. ($aAxisType)");
+        }
+
+        $xt=substr($aAxisType,0,3);
+        if( $xt == 'lin' || $xt == 'tex' ) {
+            $this->xscale = new LinearScale($aXMin,$aXMax,'x');
+            $this->xscale->textscale = ($xt == 'tex');
+        }
+        elseif( $xt == 'int' ) {
+            $this->xscale = new LinearScale($aXMin,$aXMax,'x');
+            $this->xscale->SetIntScale();
+        }
+        elseif( $xt == 'dat' ) {
+            $this->xscale = new DateScale($aXMin,$aXMax,'x');
+        }
+        elseif( $xt == 'log' ) {
+            $this->xscale = new LogScale($aXMin,$aXMax,'x');
+        }
+        else {
+            JpGraphError::RaiseL(25022,$aAxisType);//(" Unknown scale specification for X-scale. ($aAxisType)");
+        }
+
+        $this->xaxis = new Axis($this->img,$this->xscale);
+        $this->yaxis = new Axis($this->img,$this->yscale);
+        $this->xgrid = new Grid($this->xaxis);
+        $this->ygrid = new Grid($this->yaxis);
+        $this->ygrid->Show();
+
+
+        if (!$this->isRunningClear) {
+            $this->inputValues['aAxisType'] = $aAxisType;
+            $this->inputValues['aYMin'] = $aYMin;
+            $this->inputValues['aYMax'] = $aYMax;
+            $this->inputValues['aXMin'] = $aXMin;
+            $this->inputValues['aXMax'] = $aXMax;
+
+            if ($this->graph_theme) {
+                $this->graph_theme->ApplyGraph($this);
+            }
+        }
+
+        $this->isAfterSetScale = true;
+    }
+
+    // Specify secondary Y scale
+    function SetY2Scale($aAxisType='lin',$aY2Min=1,$aY2Max=1) {
+        if( $aAxisType == 'lin' ) {
+            $this->y2scale = new LinearScale($aY2Min,$aY2Max);
+        }
+        elseif( $aAxisType == 'int' ) {
+            $this->y2scale = new LinearScale($aY2Min,$aY2Max);
+            $this->y2scale->SetIntScale();
+        }
+        elseif( $aAxisType == 'log' ) {
+            $this->y2scale = new LogScale($aY2Min,$aY2Max);
+        }
+        else {
+            JpGraphError::RaiseL(25023,$aAxisType);//("JpGraph: Unsupported Y2 axis type: $aAxisType\nMust be one of (lin,log,int)");
+        }
+
+        $this->y2axis = new Axis($this->img,$this->y2scale);
+        $this->y2axis->scale->ticks->SetDirection(SIDE_LEFT);
+        $this->y2axis->SetLabelSide(SIDE_RIGHT);
+        $this->y2axis->SetPos('max');
+        $this->y2axis->SetTitleSide(SIDE_RIGHT);
+
+        // Deafult position is the max x-value
+        $this->y2grid = new Grid($this->y2axis);
+
+        if ($this->graph_theme) {
+          $this->graph_theme->ApplyGraph($this);
+        }
+    }
+
+    // Set the delta position (in pixels) between the multiple Y-axis
+    function SetYDeltaDist($aDist) {
+        $this->iYAxisDeltaPos = $aDist;
+    }
+
+    // Specify secondary Y scale
+    function SetYScale($aN,$aAxisType="lin",$aYMin=1,$aYMax=1) {
+
+        if( $aAxisType == 'lin' ) {
+            $this->ynscale[$aN] = new LinearScale($aYMin,$aYMax);
+        }
+        elseif( $aAxisType == 'int' ) {
+            $this->ynscale[$aN] = new LinearScale($aYMin,$aYMax);
+            $this->ynscale[$aN]->SetIntScale();
+        }
+        elseif( $aAxisType == 'log' ) {
+            $this->ynscale[$aN] = new LogScale($aYMin,$aYMax);
+        }
+        else {
+            JpGraphError::RaiseL(25024,$aAxisType);//("JpGraph: Unsupported Y axis type: $aAxisType\nMust be one of (lin,log,int)");
+        }
+
+        $this->ynaxis[$aN] = new Axis($this->img,$this->ynscale[$aN]);
+        $this->ynaxis[$aN]->scale->ticks->SetDirection(SIDE_LEFT);
+        $this->ynaxis[$aN]->SetLabelSide(SIDE_RIGHT);
+
+        if ($this->graph_theme) {
+            $this->graph_theme->ApplyGraph($this);
+        }
+    }
+
+    // Specify density of ticks when autoscaling 'normal', 'dense', 'sparse', 'verysparse'
+    // The dividing factor have been determined heuristically according to my aesthetic
+    // sense (or lack off) y.m.m.v !
+    function SetTickDensity($aYDensity=TICKD_NORMAL,$aXDensity=TICKD_NORMAL) {
+        $this->xtick_factor=30;
+        $this->ytick_factor=25;
+        switch( $aYDensity ) {
+            case TICKD_DENSE:
+                $this->ytick_factor=12;
+                break;
+            case TICKD_NORMAL:
+                $this->ytick_factor=25;
+                break;
+            case TICKD_SPARSE:
+                $this->ytick_factor=40;
+                break;
+            case TICKD_VERYSPARSE:
+                $this->ytick_factor=100;
+                break;
+            default:
+                JpGraphError::RaiseL(25025,$densy);//("JpGraph: Unsupported Tick density: $densy");
+        }
+        switch( $aXDensity ) {
+            case TICKD_DENSE:
+                $this->xtick_factor=15;
+                break;
+            case TICKD_NORMAL:
+                $this->xtick_factor=30;
+                break;
+            case TICKD_SPARSE:
+                $this->xtick_factor=45;
+                break;
+            case TICKD_VERYSPARSE:
+                $this->xtick_factor=60;
+                break;
+            default:
+                JpGraphError::RaiseL(25025,$densx);//("JpGraph: Unsupported Tick density: $densx");
+        }
+    }
+
+
+    // Get a string of all image map areas
+    function GetCSIMareas() {
+        if( !$this->iHasStroked ) {
+            $this->Stroke(_CSIM_SPECIALFILE);
+        }
+
+        $csim = $this->title->GetCSIMAreas();
+        $csim .= $this->subtitle->GetCSIMAreas();
+        $csim .= $this->subsubtitle->GetCSIMAreas();
+        $csim .= $this->legend->GetCSIMAreas();
+
+        if( $this->y2axis != NULL ) {
+            $csim .= $this->y2axis->title->GetCSIMAreas();
+        }
+
+        if( $this->texts != null ) {
+            $n = count($this->texts);
+            for($i=0; $i < $n; ++$i ) {
+                $csim .= $this->texts[$i]->GetCSIMAreas();
+            }
+        }
+
+        if( $this->y2texts != null && $this->y2scale != null ) {
+            $n = count($this->y2texts);
+            for($i=0; $i < $n; ++$i ) {
+                $csim .= $this->y2texts[$i]->GetCSIMAreas();
+            }
+        }
+
+        if( $this->yaxis != null && $this->xaxis != null ) {
+            $csim .= $this->yaxis->title->GetCSIMAreas();
+            $csim .= $this->xaxis->title->GetCSIMAreas();
+        }
+
+        $n = count($this->plots);
+        for( $i=0; $i < $n; ++$i ) {
+            $csim .= $this->plots[$i]->GetCSIMareas();
+        }
+
+        $n = count($this->y2plots);
+        for( $i=0; $i < $n; ++$i ) {
+            $csim .= $this->y2plots[$i]->GetCSIMareas();
+        }
+
+        $n = count($this->ynaxis);
+        for( $i=0; $i < $n; ++$i ) {
+            $m = count($this->ynplots[$i]);
+            for($j=0; $j < $m; ++$j ) {
+                $csim .= $this->ynplots[$i][$j]->GetCSIMareas();
+            }
+        }
+
+        $n = count($this->iTables);
+        for( $i=0; $i < $n; ++$i ) {
+            $csim .= $this->iTables[$i]->GetCSIMareas();
+        }
+
+        return $csim;
+    }
+
+    // Get a complete <MAP>..</MAP> tag for the final image map
+    function GetHTMLImageMap($aMapName) {
+        $im = "<map name=\"$aMapName\" id=\"$aMapName\" >\n";
+        $im .= $this->GetCSIMareas();
+        $im .= "</map>";
+        return $im;
+    }
+
+    function CheckCSIMCache($aCacheName,$aTimeOut=60) {
+        global $_SERVER;
+
+        if( $aCacheName=='auto' ) {
+            $aCacheName=basename($_SERVER['PHP_SELF']);
+        }
+
+        $urlarg = $this->GetURLArguments();
+        $this->csimcachename = CSIMCACHE_DIR.$aCacheName.$urlarg;
+        $this->csimcachetimeout = $aTimeOut;
+
+        // First determine if we need to check for a cached version
+        // This differs from the standard cache in the sense that the
+        // image and CSIM map HTML file is written relative to the directory
+        // the script executes in and not the specified cache directory.
+        // The reason for this is that the cache directory is not necessarily
+        // accessible from the HTTP server.
+        if( $this->csimcachename != '' ) {
+            $dir = dirname($this->csimcachename);
+            $base = basename($this->csimcachename);
+            $base = strtok($base,'.');
+            $suffix = strtok('.');
+            $basecsim = $dir.'/'.$base.'?'.$urlarg.'_csim_.html';
+            $baseimg = $dir.'/'.$base.'?'.$urlarg.'.'.$this->img->img_format;
+
+            $timedout=false;
+            // Does it exist at all ?
+
+            if( file_exists($basecsim) && file_exists($baseimg) ) {
+                // Check that it hasn't timed out
+                $diff=time()-filemtime($basecsim);
+                if( $this->csimcachetimeout>0 && ($diff > $this->csimcachetimeout*60) ) {
+                    $timedout=true;
+                    @unlink($basecsim);
+                    @unlink($baseimg);
+                }
+                else {
+                    if ($fh = @fopen($basecsim, "r")) {
+                        fpassthru($fh);
+                        return true;
+                    }
+                    else {
+                        JpGraphError::RaiseL(25027,$basecsim);//(" Can't open cached CSIM \"$basecsim\" for reading.");
+                    }
+                }
+            }
+        }
+        return false;
+    }
+
+    // Build the argument string to be used with the csim images
+    static function GetURLArguments($aAddRecursiveBlocker=false) {
+
+        if( $aAddRecursiveBlocker ) {
+            // This is a JPGRAPH internal defined that prevents
+            // us from recursively coming here again
+            $urlarg = _CSIM_DISPLAY.'=1';
+        }
+
+        // Now reconstruct any user URL argument
+        reset($_GET);
+        while( list($key,$value) = each($_GET) ) {
+            if( is_array($value) ) {
+                foreach ( $value as $k => $v ) {
+                    $urlarg .= '&amp;'.$key.'%5B'.$k.'%5D='.urlencode($v);
+                }
+            }
+            else {
+                $urlarg .= '&amp;'.$key.'='.urlencode($value);
+            }
+        }
+
+        // It's not ideal to convert POST argument to GET arguments
+        // but there is little else we can do. One idea for the
+        // future might be recreate the POST header in case.
+        reset($_POST);
+        while( list($key,$value) = each($_POST) ) {
+            if( is_array($value) ) {
+                foreach ( $value as $k => $v ) {
+                    $urlarg .= '&amp;'.$key.'%5B'.$k.'%5D='.urlencode($v);
+                }
+            }
+            else {
+                $urlarg .= '&amp;'.$key.'='.urlencode($value);
+            }
+        }
+
+        return $urlarg;
+    }
+
+    function SetCSIMImgAlt($aAlt) {
+        $this->iCSIMImgAlt = $aAlt;
+    }
+
+    function StrokeCSIM($aScriptName='auto',$aCSIMName='',$aBorder=0) {
+        if( $aCSIMName=='' ) {
+            // create a random map name
+            srand ((double) microtime() * 1000000);
+            $r = rand(0,100000);
+            $aCSIMName='__mapname'.$r.'__';
+        }
+
+        if( $aScriptName=='auto' ) {
+            $aScriptName=basename($_SERVER['PHP_SELF']);
+        }
+
+        $urlarg = $this->GetURLArguments(true);
+
+        if( empty($_GET[_CSIM_DISPLAY]) ) {
+            // First determine if we need to check for a cached version
+            // This differs from the standard cache in the sense that the
+            // image and CSIM map HTML file is written relative to the directory
+            // the script executes in and not the specified cache directory.
+            // The reason for this is that the cache directory is not necessarily
+            // accessible from the HTTP server.
+            if( $this->csimcachename != '' ) {
+                $dir = dirname($this->csimcachename);
+                $base = basename($this->csimcachename);
+                $base = strtok($base,'.');
+                $suffix = strtok('.');
+                $basecsim = $dir.'/'.$base.'?'.$urlarg.'_csim_.html';
+                $baseimg = $base.'?'.$urlarg.'.'.$this->img->img_format;
+
+                // Check that apache can write to directory specified
+
+                if( file_exists($dir) && !is_writeable($dir) ) {
+                    JpgraphError::RaiseL(25028,$dir);//('Apache/PHP does not have permission to write to the CSIM cache directory ('.$dir.'). Check permissions.');
+                }
+
+                // Make sure directory exists
+                $this->cache->MakeDirs($dir);
+
+                // Write the image file
+                $this->Stroke(CSIMCACHE_DIR.$baseimg);
+
+                // Construct wrapper HTML and write to file and send it back to browser
+
+                // In the src URL we must replace the '?' with its encoding to prevent the arguments
+                // to be converted to real arguments.
+                $tmp = str_replace('?','%3f',$baseimg);
+                $htmlwrap = $this->GetHTMLImageMap($aCSIMName)."\n".
+                            '<img src="'.CSIMCACHE_HTTP_DIR.$tmp.'" ismap="ismap" usemap="#'.$aCSIMName.' width="'.$this->img->width.'" height="'.$this->img->height."\" alt=\"".$this->iCSIMImgAlt."\" />\n";
+
+                if($fh =  @fopen($basecsim,'w') ) {
+                    fwrite($fh,$htmlwrap);
+                    fclose($fh);
+                    echo $htmlwrap;
+                }
+                else {
+                    JpGraphError::RaiseL(25029,$basecsim);//(" Can't write CSIM \"$basecsim\" for writing. Check free space and permissions.");
+                }
+            }
+            else {
+
+                if( $aScriptName=='' ) {
+                    JpGraphError::RaiseL(25030);//('Missing script name in call to StrokeCSIM(). You must specify the name of the actual image script as the first parameter to StrokeCSIM().');
+                }
+                echo $this->GetHTMLImageMap($aCSIMName) . $this->GetCSIMImgHTML($aCSIMName, $aScriptName, $aBorder);
+            }
+        }
+        else {
+            $this->Stroke();
+        }
+    }
+
+    function StrokeCSIMImage() {
+        if( @$_GET[_CSIM_DISPLAY] == 1 ) {
+            $this->Stroke();
+        }
+    }
+
+    function GetCSIMImgHTML($aCSIMName, $aScriptName='auto', $aBorder=0 ) {
+        if( $aScriptName=='auto' ) {
+            $aScriptName=basename($_SERVER['PHP_SELF']);
+        }
+        $urlarg = $this->GetURLArguments(true);
+        return "<img src=\"".$aScriptName.'?'.$urlarg."\" ismap=\"ismap\" usemap=\"#".$aCSIMName.'" height="'.$this->img->height."\" alt=\"".$this->iCSIMImgAlt."\" />\n";
+    }
+
+    function GetTextsYMinMax($aY2=false) {
+        if( $aY2 ) {
+            $txts = $this->y2texts;
+        }
+        else {
+            $txts = $this->texts;
+        }
+        $n = count($txts);
+        $min=null;
+        $max=null;
+        for( $i=0; $i < $n; ++$i ) {
+            if( $txts[$i]->iScalePosY !== null && $txts[$i]->iScalePosX !== null  ) {
+                if( $min === null  ) {
+                    $min = $max = $txts[$i]->iScalePosY ;
+                }
+                else {
+                    $min = min($min,$txts[$i]->iScalePosY);
+                    $max = max($max,$txts[$i]->iScalePosY);
+                }
+            }
+        }
+        if( $min !== null ) {
+            return array($min,$max);
+        }
+        else {
+            return null;
+        }
+    }
+
+    function GetTextsXMinMax($aY2=false) {
+        if( $aY2 ) {
+            $txts = $this->y2texts;
+        }
+        else {
+            $txts = $this->texts;
+        }
+        $n = count($txts);
+        $min=null;
+        $max=null;
+        for( $i=0; $i < $n; ++$i ) {
+            if( $txts[$i]->iScalePosY !== null && $txts[$i]->iScalePosX !== null  ) {
+                if( $min === null  ) {
+                    $min = $max = $txts[$i]->iScalePosX ;
+                }
+                else {
+                    $min = min($min,$txts[$i]->iScalePosX);
+                    $max = max($max,$txts[$i]->iScalePosX);
+                }
+            }
+        }
+        if( $min !== null ) {
+            return array($min,$max);
+        }
+        else {
+            return null;
+        }
+    }
+
+    function GetXMinMax() {
+
+        list($min,$ymin) = $this->plots[0]->Min();
+        list($max,$ymax) = $this->plots[0]->Max();
+
+        $i=0;
+        // Some plots, e.g. PlotLine should not affect the scale
+        // and will return (null,null). We should ignore those
+        // values.
+        while( ($min===null || $max === null) && ($i < count($this->plots)-1) ) {
+            ++$i;
+            list($min,$ymin) = $this->plots[$i]->Min();
+            list($max,$ymax) = $this->plots[$i]->Max();
+        }
+
+        foreach( $this->plots as $p ) {
+            list($xmin,$ymin) = $p->Min();
+            list($xmax,$ymax) = $p->Max();
+
+            if( $xmin !== null && $xmax !== null ) {
+                $min = Min($xmin,$min);
+                $max = Max($xmax,$max);
+            }
+        }
+
+        if( $this->y2axis != null ) {
+            foreach( $this->y2plots as $p ) {
+                list($xmin,$ymin) = $p->Min();
+                list($xmax,$ymax) = $p->Max();
+                $min = Min($xmin,$min);
+                $max = Max($xmax,$max);
+            }
+        }
+
+        $n = count($this->ynaxis);
+        for( $i=0; $i < $n; ++$i ) {
+            if( $this->ynaxis[$i] != null) {
+                foreach( $this->ynplots[$i] as $p ) {
+                    list($xmin,$ymin) = $p->Min();
+                    list($xmax,$ymax) = $p->Max();
+                    $min = Min($xmin,$min);
+                    $max = Max($xmax,$max);
+                }
+            }
+        }
+        return array($min,$max);
+    }
+
+    function AdjustMarginsForTitles() {
+        $totrequired = 
+            ($this->title->t != '' 
+                ? $this->title->GetTextHeight($this->img) + $this->title->margin + 5 * SUPERSAMPLING_SCALE
+                : 0 ) +
+            ($this->subtitle->t != '' 
+                ? $this->subtitle->GetTextHeight($this->img) + $this->subtitle->margin + 5 * SUPERSAMPLING_SCALE
+                : 0 ) +
+            ($this->subsubtitle->t != '' 
+                ? $this->subsubtitle->GetTextHeight($this->img) + $this->subsubtitle->margin + 5 * SUPERSAMPLING_SCALE
+                : 0 ) ;
+
+        $btotrequired = 0;
+        if($this->xaxis != null &&  !$this->xaxis->hide && !$this->xaxis->hide_labels ) {
+            // Minimum bottom margin
+            if( $this->xaxis->title->t != '' ) {
+                if( $this->img->a == 90 ) {
+                    $btotrequired = $this->yaxis->title->GetTextHeight($this->img) + 7 ;
+                }
+                else {
+                    $btotrequired = $this->xaxis->title->GetTextHeight($this->img) + 7 ;
+                }
+            }
+            else {
+                $btotrequired = 0;
+            }
+
+            if( $this->img->a == 90 ) {
+                $this->img->SetFont($this->yaxis->font_family,$this->yaxis->font_style,
+                $this->yaxis->font_size);
+                $lh = $this->img->GetTextHeight('Mg',$this->yaxis->label_angle);
+            }
+            else {
+                $this->img->SetFont($this->xaxis->font_family,$this->xaxis->font_style,
+                $this->xaxis->font_size);
+                $lh = $this->img->GetTextHeight('Mg',$this->xaxis->label_angle);
+            }
+
+            $btotrequired += $lh + 6;
+        }
+
+        if( $this->img->a == 90 ) {
+            // DO Nothing. It gets too messy to do this properly for 90 deg...
+        }
+        else{
+            // need more top margin
+            if( $this->img->top_margin < $totrequired ) {
+                $this->SetMargin(
+                    $this->img->raw_left_margin,
+                    $this->img->raw_right_margin,
+                    $totrequired / SUPERSAMPLING_SCALE, 
+                    $this->img->raw_bottom_margin
+                );
+            }
+
+            // need more bottom margin
+            if( $this->img->bottom_margin < $btotrequired ) {
+                $this->SetMargin(
+                    $this->img->raw_left_margin,
+                    $this->img->raw_right_margin,
+                    $this->img->raw_top_margin,
+                    $btotrequired / SUPERSAMPLING_SCALE
+                );
+            }
+        }
+    }
+
+    function StrokeStore($aStrokeFileName) {
+        // Get the handler to prevent the library from sending the
+        // image to the browser
+        $ih = $this->Stroke(_IMG_HANDLER);
+
+        // Stroke it to a file
+        $this->img->Stream($aStrokeFileName);
+
+        // Send it back to browser
+        $this->img->Headers();
+        $this->img->Stream();
+    }
+
+    function doAutoscaleXAxis() {
+    //Check if we should autoscale x-axis
+        if( !$this->xscale->IsSpecified() ) {
+            if( substr($this->axtype,0,4) == "text" ) {
+                $max=0;
+                $n = count($this->plots);
+                for($i=0; $i < $n; ++$i ) {
+                    $p = $this->plots[$i];
+                    // We need some unfortunate sub class knowledge here in order
+                    // to increase number of data points in case it is a line plot
+                    // which has the barcenter set. If not it could mean that the
+                    // last point of the data is outside the scale since the barcenter
+                    // settings means that we will shift the entire plot half a tick step
+                    // to the right in oder to align with the center of the bars.
+                    if( class_exists('BarPlot',false) ) {
+                        $cl = strtolower(get_class($p));
+                        if( (class_exists('BarPlot',false) && ($p instanceof BarPlot)) || empty($p->barcenter) ) {
+                            $max=max($max,$p->numpoints-1);
+                        }
+                        else {
+                            $max=max($max,$p->numpoints);
+                        }
+                    }
+                    else {
+                        if( empty($p->barcenter) ) {
+                            $max=max($max,$p->numpoints-1);
+                        }
+                        else {
+                            $max=max($max,$p->numpoints);
+                        }
+                    }
+                }
+                $min=0;
+                if( $this->y2axis != null ) {
+                    foreach( $this->y2plots as $p ) {
+                        $max=max($max,$p->numpoints-1);
+                    }
+                }
+                $n = count($this->ynaxis);
+                for( $i=0; $i < $n; ++$i ) {
+                    if( $this->ynaxis[$i] != null) {
+                        foreach( $this->ynplots[$i] as $p ) {
+                            $max=max($max,$p->numpoints-1);
+                        }
+                    }
+                }
+
+                $this->xscale->Update($this->img,$min,$max);
+                $this->xscale->ticks->Set($this->xaxis->tick_step,1);
+                $this->xscale->ticks->SupressMinorTickMarks();
+            }
+            else {
+                list($min,$max) = $this->GetXMinMax();
+
+                $lres = $this->GetLinesXMinMax($this->lines);
+                if( $lres ) {
+                    list($linmin,$linmax) = $lres ;
+                    $min = min($min,$linmin);
+                    $max = max($max,$linmax);
+                }
+
+                $lres = $this->GetLinesXMinMax($this->y2lines);
+                if( $lres ) {
+                    list($linmin,$linmax) = $lres ;
+                    $min = min($min,$linmin);
+                    $max = max($max,$linmax);
+                }
+
+                $tres = $this->GetTextsXMinMax();
+                if( $tres ) {
+                    list($tmin,$tmax) = $tres ;
+                    $min = min($min,$tmin);
+                    $max = max($max,$tmax);
+                }
+
+                $tres = $this->GetTextsXMinMax(true);
+                if( $tres ) {
+                    list($tmin,$tmax) = $tres ;
+                    $min = min($min,$tmin);
+                    $max = max($max,$tmax);
+                }
+
+                $this->xscale->AutoScale($this->img,$min,$max,round($this->img->plotwidth/$this->xtick_factor));
+            }
+
+            //Adjust position of y-axis and y2-axis to minimum/maximum of x-scale
+            if( !is_numeric($this->yaxis->pos) && !is_string($this->yaxis->pos) ) {
+                $this->yaxis->SetPos($this->xscale->GetMinVal());
+            }
+        }
+        elseif( $this->xscale->IsSpecified() &&
+                ( $this->xscale->auto_ticks || !$this->xscale->ticks->IsSpecified()) ) {
+            // The tick calculation will use the user suplied min/max values to determine
+            // the ticks. If auto_ticks is false the exact user specifed min and max
+            // values will be used for the scale.
+            // If auto_ticks is true then the scale might be slightly adjusted
+            // so that the min and max values falls on an even major step.
+            $min = $this->xscale->scale[0];
+            $max = $this->xscale->scale[1];
+            $this->xscale->AutoScale($this->img,$min,$max,round($this->img->plotwidth/$this->xtick_factor),false);
+
+            // Now make sure we show enough precision to accurate display the
+            // labels. If this is not done then the user might end up with
+            // a scale that might actually start with, say 13.5, butdue to rounding
+            // the scale label will ony show 14.
+            if( abs(floor($min)-$min) > 0 ) {
+
+                // If the user has set a format then we bail out
+                if( $this->xscale->ticks->label_formatstr == '' && $this->xscale->ticks->label_dateformatstr == '' ) {
+                    $this->xscale->ticks->precision = abs( floor(log10( abs(floor($min)-$min))) )+1;
+                }
+            }
+        }
+
+        // Position the optional Y2 and Yn axis to the rightmost position of the x-axis
+        if( $this->y2axis != null ) {
+            if( !is_numeric($this->y2axis->pos) && !is_string($this->y2axis->pos) ) {
+                $this->y2axis->SetPos($this->xscale->GetMaxVal());
+            }
+            $this->y2axis->SetTitleSide(SIDE_RIGHT);
+        }
+
+        $n = count($this->ynaxis);
+        $nY2adj = $this->y2axis != null ? $this->iYAxisDeltaPos : 0;
+        for( $i=0; $i < $n; ++$i ) {
+            if( $this->ynaxis[$i] != null ) {
+                if( !is_numeric($this->ynaxis[$i]->pos) && !is_string($this->ynaxis[$i]->pos) ) {
+                    $this->ynaxis[$i]->SetPos($this->xscale->GetMaxVal());
+                    $this->ynaxis[$i]->SetPosAbsDelta($i*$this->iYAxisDeltaPos + $nY2adj);
+                }
+                $this->ynaxis[$i]->SetTitleSide(SIDE_RIGHT);
+            }
+        }
+    }
+
+
+    function doAutoScaleYnAxis() {
+
+        if( $this->y2scale != null) {
+            if( !$this->y2scale->IsSpecified() && count($this->y2plots)>0 ) {
+                list($min,$max) = $this->GetPlotsYMinMax($this->y2plots);
+
+                $lres = $this->GetLinesYMinMax($this->y2lines);
+                if( is_array($lres) ) {
+                    list($linmin,$linmax) = $lres ;
+                    $min = min($min,$linmin);
+                    $max = max($max,$linmax);
+                }
+                $tres = $this->GetTextsYMinMax(true);
+                if( is_array($tres) ) {
+                    list($tmin,$tmax) = $tres ;
+                    $min = min($min,$tmin);
+                    $max = max($max,$tmax);
+                }
+                $this->y2scale->AutoScale($this->img,$min,$max,$this->img->plotheight/$this->ytick_factor);
+            }
+            elseif( $this->y2scale->IsSpecified() && ( $this->y2scale->auto_ticks || !$this->y2scale->ticks->IsSpecified()) ) {
+                // The tick calculation will use the user suplied min/max values to determine
+                // the ticks. If auto_ticks is false the exact user specifed min and max
+                // values will be used for the scale.
+                // If auto_ticks is true then the scale might be slightly adjusted
+                // so that the min and max values falls on an even major step.
+                $min = $this->y2scale->scale[0];
+                $max = $this->y2scale->scale[1];
+                $this->y2scale->AutoScale($this->img,$min,$max,
+                $this->img->plotheight/$this->ytick_factor,
+                $this->y2scale->auto_ticks);
+
+                // Now make sure we show enough precision to accurate display the
+                // labels. If this is not done then the user might end up with
+                // a scale that might actually start with, say 13.5, butdue to rounding
+                // the scale label will ony show 14.
+                if( abs(floor($min)-$min) > 0 ) {
+                    // If the user has set a format then we bail out
+                    if( $this->y2scale->ticks->label_formatstr == '' && $this->y2scale->ticks->label_dateformatstr == '' ) {
+                        $this->y2scale->ticks->precision = abs( floor(log10( abs(floor($min)-$min))) )+1;
+                    }
+                }
+
+            }
+        }
+
+
+        //
+        // Autoscale the extra Y-axises
+        //
+        $n = count($this->ynaxis);
+        for( $i=0; $i < $n; ++$i ) {
+            if( $this->ynscale[$i] != null) {
+                if( !$this->ynscale[$i]->IsSpecified() && count($this->ynplots[$i])>0 ) {
+                    list($min,$max) = $this->GetPlotsYMinMax($this->ynplots[$i]);
+                    $this->ynscale[$i]->AutoScale($this->img,$min,$max,$this->img->plotheight/$this->ytick_factor);
+                }
+                elseif( $this->ynscale[$i]->IsSpecified() && ( $this->ynscale[$i]->auto_ticks || !$this->ynscale[$i]->ticks->IsSpecified()) ) {
+                    // The tick calculation will use the user suplied min/max values to determine
+                    // the ticks. If auto_ticks is false the exact user specifed min and max
+                    // values will be used for the scale.
+                    // If auto_ticks is true then the scale might be slightly adjusted
+                    // so that the min and max values falls on an even major step.
+                    $min = $this->ynscale[$i]->scale[0];
+                    $max = $this->ynscale[$i]->scale[1];
+                    $this->ynscale[$i]->AutoScale($this->img,$min,$max,
+                    $this->img->plotheight/$this->ytick_factor,
+                    $this->ynscale[$i]->auto_ticks);
+
+                    // Now make sure we show enough precision to accurate display the
+                    // labels. If this is not done then the user might end up with
+                    // a scale that might actually start with, say 13.5, butdue to rounding
+                    // the scale label will ony show 14.
+                    if( abs(floor($min)-$min) > 0 ) {
+                        // If the user has set a format then we bail out
+                        if( $this->ynscale[$i]->ticks->label_formatstr == '' && $this->ynscale[$i]->ticks->label_dateformatstr == '' ) {
+                            $this->ynscale[$i]->ticks->precision = abs( floor(log10( abs(floor($min)-$min))) )+1;
+                        }
+                    }
+                }
+            }
+        }
+    }
+
+    function doAutoScaleYAxis() {
+
+        //Check if we should autoscale y-axis
+        if( !$this->yscale->IsSpecified() && count($this->plots)>0 ) {
+            list($min,$max) = $this->GetPlotsYMinMax($this->plots);
+            $lres = $this->GetLinesYMinMax($this->lines);
+            if( is_array($lres) ) {
+                list($linmin,$linmax) = $lres ;
+                $min = min($min,$linmin);
+                $max = max($max,$linmax);
+            }
+            $tres = $this->GetTextsYMinMax();
+            if( is_array($tres) ) {
+                list($tmin,$tmax) = $tres ;
+                $min = min($min,$tmin);
+                $max = max($max,$tmax);
+            }
+            $this->yscale->AutoScale($this->img,$min,$max,
+            $this->img->plotheight/$this->ytick_factor);
+        }
+        elseif( $this->yscale->IsSpecified() && ( $this->yscale->auto_ticks || !$this->yscale->ticks->IsSpecified()) ) {
+            // The tick calculation will use the user suplied min/max values to determine
+            // the ticks. If auto_ticks is false the exact user specifed min and max
+            // values will be used for the scale.
+            // If auto_ticks is true then the scale might be slightly adjusted
+            // so that the min and max values falls on an even major step.
+            $min = $this->yscale->scale[0];
+            $max = $this->yscale->scale[1];
+            $this->yscale->AutoScale($this->img,$min,$max,
+            $this->img->plotheight/$this->ytick_factor,
+            $this->yscale->auto_ticks);
+
+            // Now make sure we show enough precision to accurate display the
+            // labels. If this is not done then the user might end up with
+            // a scale that might actually start with, say 13.5, butdue to rounding
+            // the scale label will ony show 14.
+            if( abs(floor($min)-$min) > 0 ) {
+
+                // If the user has set a format then we bail out
+                if( $this->yscale->ticks->label_formatstr == '' && $this->yscale->ticks->label_dateformatstr == '' ) {
+                    $this->yscale->ticks->precision = abs( floor(log10( abs(floor($min)-$min))) )+1;
+                }
+            }
+        }
+
+    }
+
+    function InitScaleConstants() {
+        // Setup scale constants
+        if( $this->yscale ) $this->yscale->InitConstants($this->img);
+        if( $this->xscale ) $this->xscale->InitConstants($this->img);
+        if( $this->y2scale ) $this->y2scale->InitConstants($this->img);
+
+        $n=count($this->ynscale);
+        for($i=0; $i < $n; ++$i) {
+            if( $this->ynscale[$i] ) {
+                $this->ynscale[$i]->InitConstants($this->img);
+            }
+        }
+    }
+
+    function doPrestrokeAdjustments() {
+
+        // Do any pre-stroke adjustment that is needed by the different plot types
+        // (i.e bar plots want's to add an offset to the x-labels etc)
+        for($i=0; $i < count($this->plots) ; ++$i ) {
+            $this->plots[$i]->PreStrokeAdjust($this);
+            $this->plots[$i]->DoLegend($this);
+        }
+
+        // Any plots on the second Y scale?
+        if( $this->y2scale != null ) {
+            for($i=0; $i<count($this->y2plots) ; ++$i ) {
+                $this->y2plots[$i]->PreStrokeAdjust($this);
+                $this->y2plots[$i]->DoLegend($this);
+            }
+        }
+
+        // Any plots on the extra Y axises?
+        $n = count($this->ynaxis);
+        for($i=0; $i<$n ; ++$i ) {
+            if( $this->ynplots == null || $this->ynplots[$i] == null) {
+                JpGraphError::RaiseL(25032,$i);//("No plots for Y-axis nbr:$i");
+            }
+            $m = count($this->ynplots[$i]);
+            for($j=0; $j < $m; ++$j ) {
+                $this->ynplots[$i][$j]->PreStrokeAdjust($this);
+                $this->ynplots[$i][$j]->DoLegend($this);
+            }
+        }
+    }
+
+    function StrokeBands($aDepth,$aCSIM) {
+    // Stroke bands
+        if( $this->bands != null && !$aCSIM) {
+            for($i=0; $i < count($this->bands); ++$i) {
+            // Stroke all bands that asks to be in the background
+                if( $this->bands[$i]->depth == $aDepth ) {
+                    $this->bands[$i]->Stroke($this->img,$this->xscale,$this->yscale);
+                }
+            }
+        }
+
+        if( $this->y2bands != null && $this->y2scale != null && !$aCSIM ) {
+            for($i=0; $i < count($this->y2bands); ++$i) {
+            // Stroke all bands that asks to be in the foreground
+                if( $this->y2bands[$i]->depth == $aDepth ) {
+                    $this->y2bands[$i]->Stroke($this->img,$this->xscale,$this->y2scale);
+                }
+            }
+        }
+    }
+
+
+    // Stroke the graph
+    // $aStrokeFileName If != "" the image will be written to this file and NOT
+    // streamed back to the browser
+    function Stroke($aStrokeFileName='') {
+        // Fist make a sanity check that user has specified a scale
+        if( empty($this->yscale) ) {
+            JpGraphError::RaiseL(25031);//('You must specify what scale to use with a call to Graph::SetScale().');
+        }
+
+        // Start by adjusting the margin so that potential titles will fit.
+        $this->AdjustMarginsForTitles();
+
+        // Give the plot a chance to do any scale adjuments the individual plots
+        // wants to do. Right now this is only used by the contour plot to set scale
+        // limits
+        for($i=0; $i < count($this->plots) ; ++$i ) {
+            $this->plots[$i]->PreScaleSetup($this);
+        }
+
+        // Init scale constants that are used to calculate the transformation from
+        // world to pixel coordinates
+        $this->InitScaleConstants();
+
+        // If the filename is the predefined value = '_csim_special_'
+        // we assume that the call to stroke only needs to do enough
+        // to correctly generate the CSIM maps.
+        // We use this variable to skip things we don't strictly need
+        // to do to generate the image map to improve performance
+        // a best we can. Therefor you will see a lot of tests !$_csim in the
+        // code below.
+        $_csim = ($aStrokeFileName===_CSIM_SPECIALFILE);
+
+        // If we are called the second time (perhaps the user has called GetHTMLImageMap()
+        // himself then the legends have alsready been populated once in order to get the
+        // CSIM coordinats. Since we do not want the legends to be populated a second time
+        // we clear the legends
+        $this->legend->Clear();
+
+        // We need to know if we have stroked the plot in the
+        // GetCSIMareas. Otherwise the CSIM hasn't been generated
+        // and in the case of GetCSIM called before stroke to generate
+        // CSIM without storing an image to disk GetCSIM must call Stroke.
+        $this->iHasStroked = true;
+
+        // Setup pre-stroked adjustments and Legends
+        $this->doPrestrokeAdjustments();
+
+        if ($this->graph_theme) {
+            $this->graph_theme->PreStrokeApply($this);
+        }
+
+        // Bail out if any of the Y-axis not been specified and
+        // has no plots. (This means it is impossible to do autoscaling and
+        // no other scale was given so we can't possible draw anything). If you use manual
+        // scaling you also have to supply the tick steps as well.
+        if( (!$this->yscale->IsSpecified() && count($this->plots)==0) ||
+            ($this->y2scale!=null && !$this->y2scale->IsSpecified() && count($this->y2plots)==0) ) {
+            //$e = "n=".count($this->y2plots)."\n";
+            // $e = "Can't draw unspecified Y-scale.<br>\nYou have either:<br>\n";
+            // $e .= "1. Specified an Y axis for autoscaling but have not supplied any plots<br>\n";
+            // $e .= "2. Specified a scale manually but have forgot to specify the tick steps";
+            JpGraphError::RaiseL(25026);
+        }
+
+        // Bail out if no plots and no specified X-scale
+        if( (!$this->xscale->IsSpecified() && count($this->plots)==0 && count($this->y2plots)==0) ) {
+            JpGraphError::RaiseL(25034);//("<strong>JpGraph: Can't draw unspecified X-scale.</strong><br>No plots.<br>");
+        }
+
+        // Autoscale the normal Y-axis
+        $this->doAutoScaleYAxis();
+
+        // Autoscale all additiopnal y-axis
+        $this->doAutoScaleYnAxis();
+
+        // Autoscale the regular x-axis and position the y-axis properly
+        $this->doAutoScaleXAxis();
+
+        // If we have a negative values and x-axis position is at 0
+        // we need to supress the first and possible the last tick since
+        // they will be drawn on top of the y-axis (and possible y2 axis)
+        // The test below might seem strange the reasone being that if
+        // the user hasn't specified a value for position this will not
+        // be set until we do the stroke for the axis so as of now it
+        // is undefined.
+        // For X-text scale we ignore all this since the tick are usually
+        // much further in and not close to the Y-axis. Hence the test
+        // for 'text'
+        if( ($this->yaxis->pos==$this->xscale->GetMinVal() || (is_string($this->yaxis->pos) && $this->yaxis->pos=='min')) &&
+            !is_numeric($this->xaxis->pos) && $this->yscale->GetMinVal() < 0 &&
+            substr($this->axtype,0,4) != 'text' && $this->xaxis->pos != 'min' ) {
+
+            //$this->yscale->ticks->SupressZeroLabel(false);
+            $this->xscale->ticks->SupressFirst();
+            if( $this->y2axis != null ) {
+                $this->xscale->ticks->SupressLast();
+            }
+        }
+        elseif( !is_numeric($this->yaxis->pos) && $this->yaxis->pos=='max' ) {
+            $this->xscale->ticks->SupressLast();
+        }
+
+        if( !$_csim ) {
+            $this->StrokePlotArea();
+            if( $this->iIconDepth == DEPTH_BACK ) {
+                $this->StrokeIcons();
+            }
+        }
+        $this->StrokeAxis(false);
+
+        // Stroke colored bands
+        $this->StrokeBands(DEPTH_BACK,$_csim);
+
+        if( $this->grid_depth == DEPTH_BACK && !$_csim) {
+            $this->ygrid->Stroke();
+            $this->xgrid->Stroke();
+        }
+
+        // Stroke Y2-axis
+        if( $this->y2axis != null && !$_csim) {
+            $this->y2axis->Stroke($this->xscale);
+            $this->y2grid->Stroke();
+        }
+
+        // Stroke yn-axis
+        $n = count($this->ynaxis);
+        for( $i=0; $i < $n; ++$i ) {
+            $this->ynaxis[$i]->Stroke($this->xscale);
+        }
+
+        $oldoff=$this->xscale->off;
+        if( substr($this->axtype,0,4) == 'text' ) {
+            if( $this->text_scale_abscenteroff > -1 ) {
+                // For a text scale the scale factor is the number of pixel per step.
+                // Hence we can use the scale factor as a substitute for number of pixels
+                // per major scale step and use that in order to adjust the offset so that
+                // an object of width "abscenteroff" becomes centered.
+                $this->xscale->off += round($this->xscale->scale_factor/2)-round($this->text_scale_abscenteroff/2);
+            }
+            else {
+                $this->xscale->off += ceil($this->xscale->scale_factor*$this->text_scale_off*$this->xscale->ticks->minor_step);
+            }
+        }
+
+        if( $this->iDoClipping ) {
+            $oldimage = $this->img->CloneCanvasH();
+        }
+
+        if( ! $this->y2orderback ) {
+            // Stroke all plots for Y1 axis
+            for($i=0; $i < count($this->plots); ++$i) {
+                $this->plots[$i]->Stroke($this->img,$this->xscale,$this->yscale);
+                $this->plots[$i]->StrokeMargin($this->img);
+            }
+        }
+
+        // Stroke all plots for Y2 axis
+        if( $this->y2scale != null ) {
+            for($i=0; $i< count($this->y2plots); ++$i ) {
+                $this->y2plots[$i]->Stroke($this->img,$this->xscale,$this->y2scale);
+            }
+        }
+
+        if( $this->y2orderback ) {
+            // Stroke all plots for Y1 axis
+            for($i=0; $i < count($this->plots); ++$i) {
+                $this->plots[$i]->Stroke($this->img,$this->xscale,$this->yscale);
+                $this->plots[$i]->StrokeMargin($this->img);
+            }
+        }
+
+        $n = count($this->ynaxis);
+        for( $i=0; $i < $n; ++$i ) {
+            $m = count($this->ynplots[$i]);
+            for( $j=0; $j < $m; ++$j ) {
+                $this->ynplots[$i][$j]->Stroke($this->img,$this->xscale,$this->ynscale[$i]);
+                $this->ynplots[$i][$j]->StrokeMargin($this->img);
+            }
+        }
+
+        if( $this->iIconDepth == DEPTH_FRONT) {
+            $this->StrokeIcons();
+        }
+
+        if( $this->iDoClipping ) {
+            // Clipping only supports graphs at 0 and 90 degrees
+            if( $this->img->a == 0 ) {
+                $this->img->CopyCanvasH($oldimage,$this->img->img,
+                $this->img->left_margin,$this->img->top_margin,
+                $this->img->left_margin,$this->img->top_margin,
+                $this->img->plotwidth+1,$this->img->plotheight);
+            }
+            elseif( $this->img->a == 90 ) {
+                $adj = ($this->img->height - $this->img->width)/2;
+                $this->img->CopyCanvasH($oldimage,$this->img->img,
+                $this->img->bottom_margin-$adj,$this->img->left_margin+$adj,
+                $this->img->bottom_margin-$adj,$this->img->left_margin+$adj,
+                $this->img->plotheight+1,$this->img->plotwidth);
+            }
+            else {
+                JpGraphError::RaiseL(25035,$this->img->a);//('You have enabled clipping. Cliping is only supported for graphs at 0 or 90 degrees rotation. Please adjust you current angle (='.$this->img->a.' degrees) or disable clipping.');
+            }
+            $this->img->Destroy();
+            $this->img->SetCanvasH($oldimage);
+        }
+
+        $this->xscale->off=$oldoff;
+
+        if( $this->grid_depth == DEPTH_FRONT && !$_csim ) {
+            $this->ygrid->Stroke();
+            $this->xgrid->Stroke();
+        }
+
+        // Stroke colored bands
+        $this->StrokeBands(DEPTH_FRONT,$_csim);
+
+        // Finally draw the axis again since some plots may have nagged
+        // the axis in the edges.
+        if( !$_csim ) {
+            $this->StrokeAxis();
+        }
+
+        if( $this->y2scale != null && !$_csim ) {
+            $this->y2axis->Stroke($this->xscale,false);
+        }
+
+        if( !$_csim ) {
+            $this->StrokePlotBox();
+        }
+
+        // The titles and legends never gets rotated so make sure
+        // that the angle is 0 before stroking them
+        $aa = $this->img->SetAngle(0);
+        $this->StrokeTitles();
+        $this->footer->Stroke($this->img);
+        $this->legend->Stroke($this->img);
+        $this->img->SetAngle($aa);
+        $this->StrokeTexts();
+        $this->StrokeTables();
+
+        if( !$_csim ) {
+
+            $this->img->SetAngle($aa);
+
+            // Draw an outline around the image map
+            if(_JPG_DEBUG) {
+                $this->DisplayClientSideaImageMapAreas();
+            }
+
+            // Should we do any final image transformation
+            if( $this->iImgTrans ) {
+                if( !class_exists('ImgTrans',false) ) {
+                    require_once('jpgraph_imgtrans.php');
+                    //JpGraphError::Raise('In order to use image transformation you must include the file jpgraph_imgtrans.php in your script.');
+                }
+
+                $tform = new ImgTrans($this->img->img);
+                $this->img->img = $tform->Skew3D($this->iImgTransHorizon,$this->iImgTransSkewDist,
+                $this->iImgTransDirection,$this->iImgTransHighQ,
+                $this->iImgTransMinSize,$this->iImgTransFillColor,
+                $this->iImgTransBorder);
+            }
+
+            // If the filename is given as the special "__handle"
+            // then the image handler is returned and the image is NOT
+            // streamed back
+            if( $aStrokeFileName == _IMG_HANDLER ) {
+                return $this->img->img;
+            }
+            else {
+                // Finally stream the generated picture
+                $this->cache->PutAndStream($this->img,$this->cache_name,$this->inline,$aStrokeFileName);
+            }
+        }
+    }
+
+    function SetAxisLabelBackground($aType,$aXFColor='lightgray',$aXColor='black',$aYFColor='lightgray',$aYColor='black') {
+        $this->iAxisLblBgType = $aType;
+        $this->iXAxisLblBgFillColor = $aXFColor;
+        $this->iXAxisLblBgColor = $aXColor;
+        $this->iYAxisLblBgFillColor = $aYFColor;
+        $this->iYAxisLblBgColor = $aYColor;
+    }
+
+    function StrokeAxisLabelBackground() {
+        // Types
+        // 0 = No background
+        // 1 = Only X-labels, length of axis
+        // 2 = Only Y-labels, length of axis
+        // 3 = As 1 but extends to width of graph
+        // 4 = As 2 but extends to height of graph
+        // 5 = Combination of 3 & 4
+        // 6 = Combination of 1 & 2
+
+        $t = $this->iAxisLblBgType ;
+        if( $t < 1 ) return;
+
+        // Stroke optional X-axis label background color
+        if( $t == 1 || $t == 3 || $t == 5 || $t == 6 ) {
+            $this->img->PushColor($this->iXAxisLblBgFillColor);
+            if( $t == 1 || $t == 6 ) {
+                $xl = $this->img->left_margin;
+                $yu = $this->img->height - $this->img->bottom_margin + 1;
+                $xr = $this->img->width - $this->img->right_margin ;
+                $yl = $this->img->height-1-$this->frame_weight;
+            }
+            else { // t==3 || t==5
+                $xl = $this->frame_weight;
+                $yu = $this->img->height - $this->img->bottom_margin + 1;
+                $xr = $this->img->width - 1 - $this->frame_weight;
+                $yl = $this->img->height-1-$this->frame_weight;
+            }
+
+            $this->img->FilledRectangle($xl,$yu,$xr,$yl);
+            $this->img->PopColor();
+
+            // Check if we should add the vertical lines at left and right edge
+            if( $this->iXAxisLblBgColor !== '' ) {
+                // Hardcode to one pixel wide
+                $this->img->SetLineWeight(1);
+                $this->img->PushColor($this->iXAxisLblBgColor);
+                if( $t == 1 || $t == 6 ) {
+                    $this->img->Line($xl,$yu,$xl,$yl);
+                    $this->img->Line($xr,$yu,$xr,$yl);
+                }
+                else {
+                    $xl = $this->img->width - $this->img->right_margin ;
+                    $this->img->Line($xl,$yu-1,$xr,$yu-1);
+                }
+                $this->img->PopColor();
+            }
+        }
+
+        if( $t == 2 || $t == 4 || $t == 5 || $t == 6 ) {
+            $this->img->PushColor($this->iYAxisLblBgFillColor);
+            if( $t == 2 || $t == 6 ) {
+                $xl = $this->frame_weight;
+                $yu = $this->frame_weight+$this->img->top_margin;
+                $xr = $this->img->left_margin - 1;
+                $yl = $this->img->height - $this->img->bottom_margin + 1;
+            }
+            else {
+                $xl = $this->frame_weight;
+                $yu = $this->frame_weight;
+                $xr = $this->img->left_margin - 1;
+                $yl = $this->img->height-1-$this->frame_weight;
+            }
+
+            $this->img->FilledRectangle($xl,$yu,$xr,$yl);
+            $this->img->PopColor();
+
+            // Check if we should add the vertical lines at left and right edge
+            if( $this->iXAxisLblBgColor !== '' ) {
+                $this->img->PushColor($this->iXAxisLblBgColor);
+                if( $t == 2 || $t == 6 ) {
+                    $this->img->Line($xl,$yu-1,$xr,$yu-1);
+                    $this->img->Line($xl,$yl-1,$xr,$yl-1);
+                }
+                else {
+                    $this->img->Line($xr+1,$yu,$xr+1,$this->img->top_margin);
+                }
+                $this->img->PopColor();
+            }
+
+        }
+    }
+
+    function StrokeAxis($aStrokeLabels=true) {
+
+        if( $aStrokeLabels ) {
+            $this->StrokeAxisLabelBackground();
+        }
+
+        // Stroke axis
+        if( $this->iAxisStyle != AXSTYLE_SIMPLE ) {
+            switch( $this->iAxisStyle ) {
+                case AXSTYLE_BOXIN :
+                    $toppos = SIDE_DOWN;
+                    $bottompos = SIDE_UP;
+                    $leftpos = SIDE_RIGHT;
+                    $rightpos = SIDE_LEFT;
+                    break;
+                case AXSTYLE_BOXOUT :
+                    $toppos = SIDE_UP;
+                    $bottompos = SIDE_DOWN;
+                    $leftpos = SIDE_LEFT;
+                    $rightpos = SIDE_RIGHT;
+                    break;
+                case AXSTYLE_YBOXIN:
+                    $toppos = FALSE;
+                    $bottompos = SIDE_UP;
+                    $leftpos = SIDE_RIGHT;
+                    $rightpos = SIDE_LEFT;
+                    break;
+                case AXSTYLE_YBOXOUT:
+                    $toppos = FALSE;
+                    $bottompos = SIDE_DOWN;
+                    $leftpos = SIDE_LEFT;
+                    $rightpos = SIDE_RIGHT;
+                    break;
+                default:
+                    JpGRaphError::RaiseL(25036,$this->iAxisStyle); //('Unknown AxisStyle() : '.$this->iAxisStyle);
+                    break;
+            }
+
+            // By default we hide the first label so it doesn't cross the
+            // Y-axis in case the positon hasn't been set by the user.
+            // However, if we use a box we always want the first value
+            // displayed so we make sure it will be displayed.
+            $this->xscale->ticks->SupressFirst(false);
+
+            // Now draw the bottom X-axis
+            $this->xaxis->SetPos('min');
+            $this->xaxis->SetLabelSide(SIDE_DOWN);
+            $this->xaxis->scale->ticks->SetSide($bottompos);
+            $this->xaxis->Stroke($this->yscale,$aStrokeLabels);
+
+            if( $toppos !== FALSE ) {
+                // We also want a top X-axis
+                $this->xaxis = $this->xaxis;
+                $this->xaxis->SetPos('max');
+                $this->xaxis->SetLabelSide(SIDE_UP);
+                // No title for the top X-axis
+                if( $aStrokeLabels ) {
+                    $this->xaxis->title->Set('');
+                }
+                $this->xaxis->scale->ticks->SetSide($toppos);
+                $this->xaxis->Stroke($this->yscale,$aStrokeLabels);
+            }
+
+            // Stroke the left Y-axis
+            $this->yaxis->SetPos('min');
+            $this->yaxis->SetLabelSide(SIDE_LEFT);
+            $this->yaxis->scale->ticks->SetSide($leftpos);
+            $this->yaxis->Stroke($this->xscale,$aStrokeLabels);
+
+            // Stroke the  right Y-axis
+            $this->yaxis->SetPos('max');
+            // No title for the right side
+            if( $aStrokeLabels ) {
+                $this->yaxis->title->Set('');
+            }
+            $this->yaxis->SetLabelSide(SIDE_RIGHT);
+            $this->yaxis->scale->ticks->SetSide($rightpos);
+            $this->yaxis->Stroke($this->xscale,$aStrokeLabels);
+        }
+        else {
+            $this->xaxis->Stroke($this->yscale,$aStrokeLabels);
+            $this->yaxis->Stroke($this->xscale,$aStrokeLabels);
+        }
+    }
+
+
+    // Private helper function for backgound image
+    static function LoadBkgImage($aImgFormat='',$aFile='',$aImgStr='') {
+        if( $aImgStr != '' ) {
+            return Image::CreateFromString($aImgStr);
+        }
+
+        // Remove case sensitivity and setup appropriate function to create image
+        // Get file extension. This should be the LAST '.' separated part of the filename
+        $e = explode('.',$aFile);
+        $ext = strtolower($e[count($e)-1]);
+        if ($ext == "jpeg")  {
+            $ext = "jpg";
+        }
+
+        if( trim($ext) == '' ) {
+            $ext = 'png';  // Assume PNG if no extension specified
+        }
+
+        if( $aImgFormat == '' ) {
+            $imgtag = $ext;
+        }
+        else {
+            $imgtag = $aImgFormat;
+        }
+
+        $supported = imagetypes();
+        if( ( $ext == 'jpg' && !($supported & IMG_JPG) ) ||
+            ( $ext == 'gif' && !($supported & IMG_GIF) ) ||
+            ( $ext == 'png' && !($supported & IMG_PNG) ) ||
+            ( $ext == 'bmp' && !($supported & IMG_WBMP) ) ||
+            ( $ext == 'xpm' && !($supported & IMG_XPM) ) ) {
+
+            JpGraphError::RaiseL(25037,$aFile);//('The image format of your background image ('.$aFile.') is not supported in your system configuration. ');
+        }
+
+
+        if( $imgtag == "jpg" || $imgtag == "jpeg") {
+            $f = "imagecreatefromjpeg";
+            $imgtag = "jpg";
+        }
+        else {
+            $f = "imagecreatefrom".$imgtag;
+        }
+
+        // Compare specified image type and file extension
+        if( $imgtag != $ext ) {
+            //$t = "Background image seems to be of different type (has different file extension) than specified imagetype. Specified: '".$aImgFormat."'File: '".$aFile."'";
+            JpGraphError::RaiseL(25038, $aImgFormat, $aFile);
+        }
+
+        $img = @$f($aFile);
+        if( !$img ) {
+            JpGraphError::RaiseL(25039,$aFile);//(" Can't read background image: '".$aFile."'");
+        }
+        return $img;
+    }
+
+    function StrokePlotGrad() {
+        if( $this->plot_gradtype < 0  )
+            return;
+            
+        $grad = new Gradient($this->img);
+        $xl = $this->img->left_margin;
+        $yt = $this->img->top_margin;
+        $xr = $xl + $this->img->plotwidth+1 ;
+        $yb = $yt + $this->img->plotheight ;
+        $grad->FilledRectangle($xl,$yt,$xr,$yb,$this->plot_gradfrom,$this->plot_gradto,$this->plot_gradtype);
+
+    }
+
+    function StrokeBackgroundGrad() {
+        if( $this->bkg_gradtype < 0  )
+            return;
+
+        $grad = new Gradient($this->img);
+        if( $this->bkg_gradstyle == BGRAD_PLOT ) {
+            $xl = $this->img->left_margin;
+            $yt = $this->img->top_margin;
+            $xr = $xl + $this->img->plotwidth+1 ;
+            $yb = $yt + $this->img->plotheight ;
+            $grad->FilledRectangle($xl,$yt,$xr,$yb,$this->bkg_gradfrom,$this->bkg_gradto,$this->bkg_gradtype);
+        }
+        else {
+            $xl = 0;
+            $yt = 0;
+            $xr = $xl + $this->img->width - 1;
+            $yb = $yt + $this->img->height - 1 ;
+            if( $this->doshadow  ) {
+                $xr -= $this->shadow_width;
+                $yb -= $this->shadow_width;
+            }
+            if( $this->doframe ) {
+                $yt += $this->frame_weight;
+                $yb -= $this->frame_weight;
+                $xl += $this->frame_weight;
+                $xr -= $this->frame_weight;
+            }
+            $aa = $this->img->SetAngle(0);
+            $grad->FilledRectangle($xl,$yt,$xr,$yb,$this->bkg_gradfrom,$this->bkg_gradto,$this->bkg_gradtype);
+            $aa = $this->img->SetAngle($aa);
+        }
+    }
+
+    function StrokeFrameBackground() {
+        if( $this->background_image != '' && $this->background_cflag != '' ) {
+            JpGraphError::RaiseL(25040);//('It is not possible to specify both a background image and a background country flag.');
+        }
+        if( $this->background_image != '' ) {
+            $bkgimg = $this->LoadBkgImage($this->background_image_format,$this->background_image);
+        }
+        elseif( $this->background_cflag != '' ) {
+            if( ! class_exists('FlagImages',false) ) {
+                JpGraphError::RaiseL(25041);//('In order to use Country flags as backgrounds you must include the "jpgraph_flags.php" file.');
+            }
+            $fobj = new FlagImages(FLAGSIZE4);
+            $dummy='';
+            $bkgimg = $fobj->GetImgByName($this->background_cflag,$dummy);
+            $this->background_image_mix = $this->background_cflag_mix;
+            $this->background_image_type = $this->background_cflag_type;
+        }
+        else {
+            return ;
+        }
+
+        $bw = ImageSX($bkgimg);
+        $bh = ImageSY($bkgimg);
+
+        // No matter what the angle is we always stroke the image and frame
+        // assuming it is 0 degree
+        $aa = $this->img->SetAngle(0);
+
+        switch( $this->background_image_type ) {
+            case BGIMG_FILLPLOT: // Resize to just fill the plotarea
+                $this->FillMarginArea();
+                $this->StrokeFrame();
+                // Special case to hande 90 degree rotated graph corectly
+                if( $aa == 90 ) {
+                    $this->img->SetAngle(90);
+                    $this->FillPlotArea();
+                    $aa = $this->img->SetAngle(0);
+                    $adj = ($this->img->height - $this->img->width)/2;
+                    $this->img->CopyMerge($bkgimg,
+                        $this->img->bottom_margin-$adj,$this->img->left_margin+$adj,
+                        0,0,
+                        $this->img->plotheight+1,$this->img->plotwidth,
+                        $bw,$bh,$this->background_image_mix);
+                }
+                else {
+                    $this->FillPlotArea();
+                    $this->img->CopyMerge($bkgimg,
+                        $this->img->left_margin,$this->img->top_margin+1,
+                        0,0,$this->img->plotwidth+1,$this->img->plotheight,
+                        $bw,$bh,$this->background_image_mix);
+                }
+                break;
+            case BGIMG_FILLFRAME: // Fill the whole area from upper left corner, resize to just fit
+                $hadj=0; $vadj=0;
+                if( $this->doshadow ) {
+                    $hadj = $this->shadow_width;
+                    $vadj = $this->shadow_width;
+                }
+                $this->FillMarginArea();
+                $this->FillPlotArea();
+                $this->img->CopyMerge($bkgimg,0,0,0,0,$this->img->width-$hadj,$this->img->height-$vadj,
+                $bw,$bh,$this->background_image_mix);
+                $this->StrokeFrame();
+                break;
+            case BGIMG_COPY: // Just copy the image from left corner, no resizing
+                $this->FillMarginArea();
+                $this->FillPlotArea();
+                $this->img->CopyMerge($bkgimg,0,0,0,0,$bw,$bh,
+                $bw,$bh,$this->background_image_mix);
+                $this->StrokeFrame();
+                break;
+            case BGIMG_CENTER: // Center original image in the plot area
+                $this->FillMarginArea();
+                $this->FillPlotArea();
+                $centerx = round($this->img->plotwidth/2+$this->img->left_margin-$bw/2);
+                $centery = round($this->img->plotheight/2+$this->img->top_margin-$bh/2);
+                $this->img->CopyMerge($bkgimg,$centerx,$centery,0,0,$bw,$bh,
+                $bw,$bh,$this->background_image_mix);
+                $this->StrokeFrame();
+                break;
+            case BGIMG_FREE: // Just copy the image to the specified location
+                $this->img->CopyMerge($bkgimg,
+                $this->background_image_xpos,$this->background_image_ypos,
+                0,0,$bw,$bh,$bw,$bh,$this->background_image_mix);
+                $this->StrokeFrame(); // New
+                break;
+            default:
+                JpGraphError::RaiseL(25042);//(" Unknown background image layout");
+        }
+        $this->img->SetAngle($aa);
+    }
+
+    // Private
+    // Draw a frame around the image
+    function StrokeFrame() {
+        if( !$this->doframe ) return;
+
+        if( $this->background_image_type <= 1 && ($this->bkg_gradtype < 0 || ($this->bkg_gradtype > 0 && $this->bkg_gradstyle==BGRAD_PLOT)) ) {
+            $c = $this->margin_color;
+        }
+        else {
+            $c = false;
+        }
+
+        if( $this->doshadow ) {
+            $this->img->SetColor($this->frame_color);
+            $this->img->ShadowRectangle(0,0,$this->img->width,$this->img->height,
+            $c,$this->shadow_width,$this->shadow_color);
+        }
+        elseif( $this->framebevel ) {
+            if( $c ) {
+                $this->img->SetColor($this->margin_color);
+                $this->img->FilledRectangle(0,0,$this->img->width-1,$this->img->height-1);
+            }
+            $this->img->Bevel(1,1,$this->img->width-2,$this->img->height-2,
+            $this->framebeveldepth,
+            $this->framebevelcolor1,$this->framebevelcolor2);
+            if( $this->framebevelborder ) {
+                $this->img->SetColor($this->framebevelbordercolor);
+                $this->img->Rectangle(0,0,$this->img->width-1,$this->img->height-1);
+            }
+        }
+        else {
+            $this->img->SetLineWeight($this->frame_weight);
+            if( $c ) {
+                $this->img->SetColor($this->margin_color);
+                $this->img->FilledRectangle(0,0,$this->img->width-1,$this->img->height-1);
+            }
+            $this->img->SetColor($this->frame_color);
+            $this->img->Rectangle(0,0,$this->img->width-1,$this->img->height-1);
+        }
+    }
+
+    function FillMarginArea() {
+        $hadj=0; $vadj=0;
+        if( $this->doshadow ) {
+            $hadj = $this->shadow_width;
+            $vadj = $this->shadow_width;
+        }
+
+        $this->img->SetColor($this->margin_color);
+        $this->img->FilledRectangle(0,0,$this->img->width-1-$hadj,$this->img->height-1-$vadj);
+
+        $this->img->FilledRectangle(0,0,$this->img->width-1-$hadj,$this->img->top_margin);
+        $this->img->FilledRectangle(0,$this->img->top_margin,$this->img->left_margin,$this->img->height-1-$hadj);
+        $this->img->FilledRectangle($this->img->left_margin+1,
+        $this->img->height-$this->img->bottom_margin,
+        $this->img->width-1-$hadj,
+        $this->img->height-1-$hadj);
+        $this->img->FilledRectangle($this->img->width-$this->img->right_margin,
+        $this->img->top_margin+1,
+        $this->img->width-1-$hadj,
+        $this->img->height-$this->img->bottom_margin-1);
+    }
+
+    function FillPlotArea() {
+        $this->img->PushColor($this->plotarea_color);
+        $this->img->FilledRectangle($this->img->left_margin,
+        $this->img->top_margin,
+        $this->img->width-$this->img->right_margin,
+        $this->img->height-$this->img->bottom_margin);
+        $this->img->PopColor();
+    }
+
+    // Stroke the plot area with either a solid color or a background image
+    function StrokePlotArea() {
+        // Note: To be consistent we really should take a possible shadow
+        // into account. However, that causes some problem for the LinearScale class
+        // since in the current design it does not have any links to class Graph which
+        // means it has no way of compensating for the adjusted plotarea in case of a
+        // shadow. So, until I redesign LinearScale we can't compensate for this.
+        // So just set the two adjustment parameters to zero for now.
+        $boxadj = 0; //$this->doframe ? $this->frame_weight : 0 ;
+        $adj = 0; //$this->doshadow ? $this->shadow_width : 0 ;
+
+        if( $this->background_image != '' || $this->background_cflag != '' ) {
+            $this->StrokeFrameBackground();
+        }
+        else {
+            $aa = $this->img->SetAngle(0);
+            $this->StrokeFrame();
+            $aa = $this->img->SetAngle($aa);
+            $this->StrokeBackgroundGrad(); 
+            if( $this->bkg_gradtype < 0 || ($this->bkg_gradtype > 0 && $this->bkg_gradstyle==BGRAD_MARGIN) ) {
+                $this->FillPlotArea();
+            }
+            $this->StrokePlotGrad();
+        }
+    }
+
+    function StrokeIcons() {
+        $n = count($this->iIcons);
+        for( $i=0; $i < $n; ++$i ) {
+            $this->iIcons[$i]->StrokeWithScale($this->img,$this->xscale,$this->yscale);
+        }
+    }
+
+    function StrokePlotBox() {
+        // Should we draw a box around the plot area?
+        if( $this->boxed ) {
+            $this->img->SetLineWeight(1);
+            $this->img->SetLineStyle('solid');
+            $this->img->SetColor($this->box_color);
+            for($i=0; $i < $this->box_weight; ++$i ) {
+                $this->img->Rectangle(
+                $this->img->left_margin-$i,$this->img->top_margin-$i,
+                $this->img->width-$this->img->right_margin+$i,
+                $this->img->height-$this->img->bottom_margin+$i);
+            }
+        }
+    }
+
+    function SetTitleBackgroundFillStyle($aStyle,$aColor1='black',$aColor2='white') {
+        $this->titlebkg_fillstyle = $aStyle;
+        $this->titlebkg_scolor1 = $aColor1;
+        $this->titlebkg_scolor2 = $aColor2;
+    }
+
+    function SetTitleBackground($aBackColor='gray', $aStyle=TITLEBKG_STYLE1, $aFrameStyle=TITLEBKG_FRAME_NONE, $aFrameColor='black', $aFrameWeight=1, $aBevelHeight=3, $aEnable=true) {
+        $this->titlebackground = $aEnable;
+        $this->titlebackground_color = $aBackColor;
+        $this->titlebackground_style = $aStyle;
+        $this->titlebackground_framecolor = $aFrameColor;
+        $this->titlebackground_framestyle = $aFrameStyle;
+        $this->titlebackground_frameweight = $aFrameWeight;
+        $this->titlebackground_bevelheight = $aBevelHeight ;
+    }
+
+
+    function StrokeTitles() {
+
+        $margin=3;
+
+        if( $this->titlebackground ) {
+            // Find out height
+            $this->title->margin += 2 ;
+            $h = $this->title->GetTextHeight($this->img)+$this->title->margin+$margin;
+            if( $this->subtitle->t != '' && !$this->subtitle->hide ) {
+                $h += $this->subtitle->GetTextHeight($this->img)+$margin+
+                $this->subtitle->margin;
+                $h += 2;
+            }
+            if( $this->subsubtitle->t != '' && !$this->subsubtitle->hide ) {
+                $h += $this->subsubtitle->GetTextHeight($this->img)+$margin+
+                $this->subsubtitle->margin;
+                $h += 2;
+            }
+            $this->img->PushColor($this->titlebackground_color);
+            if( $this->titlebackground_style === TITLEBKG_STYLE1 ) {
+                // Inside the frame
+                if( $this->framebevel ) {
+                    $x1 = $y1 = $this->framebeveldepth + 1 ;
+                    $x2 = $this->img->width - $this->framebeveldepth - 2 ;
+                    $this->title->margin += $this->framebeveldepth + 1 ;
+                    $h += $y1 ;
+                    $h += 2;
+                }
+                else {
+                    $x1 = $y1 = $this->frame_weight;
+                    $x2 = $this->img->width - $this->frame_weight-1;
+                }
+            }
+            elseif( $this->titlebackground_style === TITLEBKG_STYLE2 ) {
+                // Cover the frame as well
+                $x1 = $y1 = 0;
+                $x2 = $this->img->width - 1 ;
+            }
+            elseif( $this->titlebackground_style === TITLEBKG_STYLE3 ) {
+                // Cover the frame as well (the difference is that
+                // for style==3 a bevel frame border is on top
+                // of the title background)
+                $x1 = $y1 = 0;
+                $x2 = $this->img->width - 1 ;
+                $h += $this->framebeveldepth ;
+                $this->title->margin += $this->framebeveldepth ;
+            }
+            else {
+                JpGraphError::RaiseL(25043);//('Unknown title background style.');
+            }
+
+            if( $this->titlebackground_framestyle === 3 ) {
+                $h += $this->titlebackground_bevelheight*2 + 1  ;
+                $this->title->margin += $this->titlebackground_bevelheight ;
+            }
+
+            if( $this->doshadow ) {
+                $x2 -= $this->shadow_width ;
+            }
+
+            $indent=0;
+            if( $this->titlebackground_framestyle == TITLEBKG_FRAME_BEVEL ) {
+                $indent = $this->titlebackground_bevelheight;
+            }
+
+            if( $this->titlebkg_fillstyle==TITLEBKG_FILLSTYLE_HSTRIPED ) {
+                $this->img->FilledRectangle2($x1+$indent,$y1+$indent,$x2-$indent,$h-$indent,
+                $this->titlebkg_scolor1,
+                $this->titlebkg_scolor2);
+            }
+            elseif( $this->titlebkg_fillstyle==TITLEBKG_FILLSTYLE_VSTRIPED ) {
+                $this->img->FilledRectangle2($x1+$indent,$y1+$indent,$x2-$indent,$h-$indent,
+                $this->titlebkg_scolor1,
+                $this->titlebkg_scolor2,2);
+            }
+            else {
+                // Solid fill
+                $this->img->FilledRectangle($x1,$y1,$x2,$h);
+            }
+            $this->img->PopColor();
+
+            $this->img->PushColor($this->titlebackground_framecolor);
+            $this->img->SetLineWeight($this->titlebackground_frameweight);
+            if( $this->titlebackground_framestyle == TITLEBKG_FRAME_FULL ) {
+                // Frame background
+                $this->img->Rectangle($x1,$y1,$x2,$h);
+            }
+            elseif( $this->titlebackground_framestyle == TITLEBKG_FRAME_BOTTOM ) {
+                // Bottom line only
+                $this->img->Line($x1,$h,$x2,$h);
+            }
+            elseif( $this->titlebackground_framestyle == TITLEBKG_FRAME_BEVEL ) {
+                $this->img->Bevel($x1,$y1,$x2,$h,$this->titlebackground_bevelheight);
+            }
+            $this->img->PopColor();
+
+            // This is clumsy. But we neeed to stroke the whole graph frame if it is
+            // set to bevel to get the bevel shading on top of the text background
+            if( $this->framebevel && $this->doframe && $this->titlebackground_style === 3 ) {
+                $this->img->Bevel(1,1,$this->img->width-2,$this->img->height-2,
+                $this->framebeveldepth,
+                $this->framebevelcolor1,$this->framebevelcolor2);
+                if( $this->framebevelborder ) {
+                    $this->img->SetColor($this->framebevelbordercolor);
+                    $this->img->Rectangle(0,0,$this->img->width-1,$this->img->height-1);
+                }
+            }
+        }
+
+        // Stroke title
+        $y = $this->title->margin;
+        if( $this->title->halign == 'center' ) {
+            $this->title->Center(0,$this->img->width,$y);
+        }
+        elseif( $this->title->halign == 'left' ) {
+            $this->title->SetPos($this->title->margin+2,$y);
+        }
+        elseif( $this->title->halign == 'right' ) {
+            $indent = 0;
+            if( $this->doshadow ) {
+                $indent = $this->shadow_width+2;
+            }
+            $this->title->SetPos($this->img->width-$this->title->margin-$indent,$y,'right');
+        }
+        $this->title->Stroke($this->img);
+
+        // ... and subtitle
+        $y += $this->title->GetTextHeight($this->img) + $margin + $this->subtitle->margin;
+        if( $this->subtitle->halign == 'center' ) {
+            $this->subtitle->Center(0,$this->img->width,$y);
+        }
+        elseif( $this->subtitle->halign == 'left' ) {
+            $this->subtitle->SetPos($this->subtitle->margin+2,$y);
+        }
+        elseif( $this->subtitle->halign == 'right' ) {
+            $indent = 0;
+            if( $this->doshadow )
+            $indent = $this->shadow_width+2;
+            $this->subtitle->SetPos($this->img->width-$this->subtitle->margin-$indent,$y,'right');
+        }
+        $this->subtitle->Stroke($this->img);
+
+        // ... and subsubtitle
+        $y += $this->subtitle->GetTextHeight($this->img) + $margin + $this->subsubtitle->margin;
+        if( $this->subsubtitle->halign == 'center' ) {
+            $this->subsubtitle->Center(0,$this->img->width,$y);
+        }
+        elseif( $this->subsubtitle->halign == 'left' ) {
+            $this->subsubtitle->SetPos($this->subsubtitle->margin+2,$y);
+        }
+        elseif( $this->subsubtitle->halign == 'right' ) {
+            $indent = 0;
+            if( $this->doshadow )
+            $indent = $this->shadow_width+2;
+            $this->subsubtitle->SetPos($this->img->width-$this->subsubtitle->margin-$indent,$y,'right');
+        }
+        $this->subsubtitle->Stroke($this->img);
+
+        // ... and fancy title
+        $this->tabtitle->Stroke($this->img);
+
+    }
+
+    function StrokeTexts() {
+        // Stroke any user added text objects
+        if( $this->texts != null ) {
+            for($i=0; $i < count($this->texts); ++$i) {
+                $this->texts[$i]->StrokeWithScale($this->img,$this->xscale,$this->yscale);
+            }
+        }
+
+        if( $this->y2texts != null && $this->y2scale != null ) {
+            for($i=0; $i < count($this->y2texts); ++$i) {
+                $this->y2texts[$i]->StrokeWithScale($this->img,$this->xscale,$this->y2scale);
+            }
+        }
+
+    }
+
+    function StrokeTables() {
+        if( $this->iTables != null ) {
+            $n = count($this->iTables);
+            for( $i=0; $i < $n; ++$i ) {
+                $this->iTables[$i]->StrokeWithScale($this->img,$this->xscale,$this->yscale);
+            }
+        }
+    }
+
+    function DisplayClientSideaImageMapAreas() {
+        // Debug stuff - display the outline of the image map areas
+        $csim='';
+        foreach ($this->plots as $p) {
+            $csim.= $p->GetCSIMareas();
+        }
+        $csim .= $this->legend->GetCSIMareas();
+        if (preg_match_all("/area shape=\"(\w+)\" coords=\"([0-9\, ]+)\"/", $csim, $coords)) {
+            $this->img->SetColor($this->csimcolor);
+            $n = count($coords[0]);
+            for ($i=0; $i < $n; $i++) {
+                if ( $coords[1][$i] == 'poly' ) {
+                    preg_match_all('/\s*([0-9]+)\s*,\s*([0-9]+)\s*,*/',$coords[2][$i],$pts);
+                    $this->img->SetStartPoint($pts[1][count($pts[0])-1],$pts[2][count($pts[0])-1]);
+                    $m = count($pts[0]);
+                    for ($j=0; $j < $m; $j++) {
+                        $this->img->LineTo($pts[1][$j],$pts[2][$j]);
+                    }
+                } elseif ( $coords[1][$i] == 'rect' ) {
+                    $pts = preg_split('/,/', $coords[2][$i]);
+                    $this->img->SetStartPoint($pts[0],$pts[1]);
+                    $this->img->LineTo($pts[2],$pts[1]);
+                    $this->img->LineTo($pts[2],$pts[3]);
+                    $this->img->LineTo($pts[0],$pts[3]);
+                    $this->img->LineTo($pts[0],$pts[1]);
+                }
+            }
+        }
+    }
+
+    // Text scale offset in world coordinates
+    function SetTextScaleOff($aOff) {
+        $this->text_scale_off = $aOff;
+        $this->xscale->text_scale_off = $aOff;
+    }
+
+    // Text width of bar to be centered in absolute pixels
+    function SetTextScaleAbsCenterOff($aOff) {
+        $this->text_scale_abscenteroff = $aOff;
+    }
+
+    // Get Y min and max values for added lines
+    function GetLinesYMinMax( $aLines ) {
+        $n = count($aLines);
+        if( $n == 0 ) return false;
+        $min = $aLines[0]->scaleposition ;
+        $max = $min ;
+        $flg = false;
+        for( $i=0; $i < $n; ++$i ) {
+            if( $aLines[$i]->direction == HORIZONTAL ) {
+                $flg = true ;
+                $v = $aLines[$i]->scaleposition ;
+                if( $min > $v ) $min = $v ;
+                if( $max < $v ) $max = $v ;
+            }
+        }
+        return $flg ? array($min,$max) : false ;
+    }
+
+    // Get X min and max values for added lines
+    function GetLinesXMinMax( $aLines ) {
+        $n = count($aLines);
+        if( $n == 0 ) return false ;
+        $min = $aLines[0]->scaleposition ;
+        $max = $min ;
+        $flg = false;
+        for( $i=0; $i < $n; ++$i ) {
+            if( $aLines[$i]->direction == VERTICAL ) {
+                $flg = true ;
+                $v = $aLines[$i]->scaleposition ;
+                if( $min > $v ) $min = $v ;
+                if( $max < $v ) $max = $v ;
+            }
+        }
+        return $flg ? array($min,$max) : false ;
+    }
+
+    // Get min and max values for all included plots
+    function GetPlotsYMinMax($aPlots) {
+        $n = count($aPlots);
+        $i=0;
+        do {
+            list($xmax,$max) = $aPlots[$i]->Max();
+        } while( ++$i < $n && !is_numeric($max) );
+
+        $i=0;
+        do {
+            list($xmin,$min) = $aPlots[$i]->Min();
+        } while( ++$i < $n && !is_numeric($min) );
+
+        if( !is_numeric($min) || !is_numeric($max) ) {
+            JpGraphError::RaiseL(25044);//('Cannot use autoscaling since it is impossible to determine a valid min/max value  of the Y-axis (only null values).');
+        }
+
+        for($i=0; $i < $n; ++$i ) {
+            list($xmax,$ymax)=$aPlots[$i]->Max();
+            list($xmin,$ymin)=$aPlots[$i]->Min();
+            if (is_numeric($ymax)) $max=max($max,$ymax);
+            if (is_numeric($ymin)) $min=min($min,$ymin);
+        }
+        if( $min == '' ) $min = 0;
+        if( $max == '' ) $max = 0;
+        if( $min == 0 && $max == 0 ) {
+            // Special case if all values are 0
+            $min=0;$max=1;
+        }
+        return array($min,$max);
+    }
+
+    function hasLinePlotAndBarPlot() {
+        $has_line = false;
+        $has_bar  = false;
+
+        foreach ($this->plots as $plot) {
+            if ($plot instanceof LinePlot) {
+                $has_line = true;
+            }
+            if ($plot instanceof BarPlot) {
+                $has_bar = true;
+            }
+        }
+
+        if ($has_line && $has_bar) {
+            return true;
+        }
+
+        return false;
+    }
+
+    function SetTheme($graph_theme) {
+
+        if (!($this instanceof PieGraph)) {
+            if (!$this->isAfterSetScale) {
+                JpGraphError::RaiseL(25133);//('Use Graph::SetTheme() after Graph::SetScale().');
+            }
+        }
+
+        if ($this->graph_theme) {
+            $this->ClearTheme();
+        }
+        $this->graph_theme = $graph_theme;
+        $this->graph_theme->ApplyGraph($this);
+    }
+
+    function ClearTheme() {
+        $this->graph_theme = null;
+
+        $this->isRunningClear = true;
+
+        $this->__construct(
+                $this->inputValues['aWidth'],
+                $this->inputValues['aHeight'],
+                $this->inputValues['aCachedName'],
+                $this->inputValues['aTimeout'],
+                $this->inputValues['aInline']
+            );
+ 
+        if (!($this instanceof PieGraph)) {
+            if ($this->isAfterSetScale) {
+                $this->SetScale(
+                        $this->inputValues['aAxisType'],
+                        $this->inputValues['aYMin'],
+                        $this->inputValues['aYMax'],
+                        $this->inputValues['aXMin'],
+                        $this->inputValues['aXMax']
+                    );       
+            }
+        }
+
+        $this->isRunningClear = false;
+    }
+
+    function SetSupersampling($do = false, $scale = 2) {
+        if ($do) {
+            define('SUPERSAMPLING_SCALE', $scale);
+           // $this->img->scale = $scale;
+        } else {
+            define('SUPERSAMPLING_SCALE', 1);
+            //$this->img->scale = 0;
+        }
+    }
+
+} // Class
+
+//===================================================
+// CLASS LineProperty
+// Description: Holds properties for a line
+//===================================================
+class LineProperty {
+    public $iWeight=1, $iColor='black', $iStyle='solid', $iShow=false;
+
+    function __construct($aWeight=1,$aColor='black',$aStyle='solid') {
+        $this->iWeight = $aWeight;
+        $this->iColor = $aColor;
+        $this->iStyle = $aStyle;
+    }
+
+    function SetColor($aColor) {
+        $this->iColor = $aColor;
+    }
+
+    function SetWeight($aWeight) {
+        $this->iWeight = $aWeight;
+    }
+
+    function SetStyle($aStyle) {
+        $this->iStyle = $aStyle;
+    }
+
+    function Show($aShow=true) {
+        $this->iShow=$aShow;
+    }
+
+    function Stroke($aImg,$aX1,$aY1,$aX2,$aY2) {
+        if( $this->iShow ) {
+            $aImg->PushColor($this->iColor);
+            $oldls = $aImg->line_style;
+            $oldlw = $aImg->line_weight;
+            $aImg->SetLineWeight($this->iWeight);
+            $aImg->SetLineStyle($this->iStyle);
+            $aImg->StyleLine($aX1,$aY1,$aX2,$aY2);
+            $aImg->PopColor($this->iColor);
+            $aImg->line_style = $oldls;
+            $aImg->line_weight = $oldlw;
+
+        }
+    }
+}
+
+//===================================================
+// CLASS GraphTabTitle
+// Description: Draw "tab" titles on top of graphs
+//===================================================
+class GraphTabTitle extends Text{
+    private $corner = 6 , $posx = 7, $posy = 4;
+    private $fillcolor='lightyellow',$bordercolor='black';
+    private $align = 'left', $width=TABTITLE_WIDTHFIT;
+    function __construct() {
+        $this->t = '';
+        $this->font_style = FS_BOLD;
+        $this->hide = true;
+        $this->color = 'darkred';
+    }
+
+    function SetColor($aTxtColor,$aFillColor='lightyellow',$aBorderColor='black') {
+        $this->color = $aTxtColor;
+        $this->fillcolor = $aFillColor;
+        $this->bordercolor = $aBorderColor;
+    }
+
+    function SetFillColor($aFillColor) {
+        $this->fillcolor = $aFillColor;
+    }
+
+    function SetTabAlign($aAlign) {
+        $this->align = $aAlign;
+    }
+
+    function SetWidth($aWidth) {
+        $this->width = $aWidth ;
+    }
+
+    function Set($t) {
+        $this->t = $t;
+        $this->hide = false;
+    }
+
+    function SetCorner($aD) {
+        $this->corner = $aD ;
+    }
+
+    function Stroke($aImg,$aDummy1=null,$aDummy2=null) {
+        if( $this->hide )
+            return;
+        $this->boxed = false;
+        $w = $this->GetWidth($aImg) + 2*$this->posx;
+        $h = $this->GetTextHeight($aImg) + 2*$this->posy;
+
+        $x = $aImg->left_margin;
+        $y = $aImg->top_margin;
+
+        if( $this->width === TABTITLE_WIDTHFIT ) {
+            if( $this->align == 'left' ) {
+                $p = array($x,                $y,
+                $x,                $y-$h+$this->corner,
+                $x + $this->corner,$y-$h,
+                $x + $w - $this->corner, $y-$h,
+                $x + $w, $y-$h+$this->corner,
+                $x + $w, $y);
+            }
+            elseif( $this->align == 'center' ) {
+                $x += round($aImg->plotwidth/2) - round($w/2);
+                $p = array($x, $y,
+                $x, $y-$h+$this->corner,
+                $x + $this->corner, $y-$h,
+                $x + $w - $this->corner, $y-$h,
+                $x + $w, $y-$h+$this->corner,
+                $x + $w, $y);
+            }
+            else {
+                $x += $aImg->plotwidth -$w;
+                $p = array($x, $y,
+                $x, $y-$h+$this->corner,
+                $x + $this->corner,$y-$h,
+                $x + $w - $this->corner, $y-$h,
+                $x + $w, $y-$h+$this->corner,
+                $x + $w, $y);
+            }
+        }
+        else {
+            if( $this->width === TABTITLE_WIDTHFULL ) {
+                $w = $aImg->plotwidth ;
+            }
+            else {
+                $w = $this->width ;
+            }
+
+            // Make the tab fit the width of the plot area
+            $p = array($x, $y,
+            $x, $y-$h+$this->corner,
+            $x + $this->corner,$y-$h,
+            $x + $w - $this->corner, $y-$h,
+            $x + $w, $y-$h+$this->corner,
+            $x + $w, $y);
+
+        }
+        if( $this->halign == 'left' ) {
+            $aImg->SetTextAlign('left','bottom');
+            $x += $this->posx;
+            $y -= $this->posy;
+        }
+        elseif( $this->halign == 'center' ) {
+            $aImg->SetTextAlign('center','bottom');
+            $x += $w/2;
+            $y -= $this->posy;
+        }
+        else {
+            $aImg->SetTextAlign('right','bottom');
+            $x += $w - $this->posx;
+            $y -= $this->posy;
+        }
+
+        $aImg->SetColor($this->fillcolor);
+        $aImg->FilledPolygon($p);
+
+        $aImg->SetColor($this->bordercolor);
+        $aImg->Polygon($p,true);
+
+        $aImg->SetColor($this->color);
+        $aImg->SetFont($this->font_family,$this->font_style,$this->font_size);
+        $aImg->StrokeText($x,$y,$this->t,0,'center');
+    }
+
+}
+
+//===================================================
+// CLASS SuperScriptText
+// Description: Format a superscript text
+//===================================================
+class SuperScriptText extends Text {
+    private $iSuper='';
+    private $sfont_family='',$sfont_style='',$sfont_size=8;
+    private $iSuperMargin=2,$iVertOverlap=4,$iSuperScale=0.65;
+    private $iSDir=0;
+    private $iSimple=false;
+
+    function __construct($aTxt='',$aSuper='',$aXAbsPos=0,$aYAbsPos=0) {
+        parent::__construct($aTxt,$aXAbsPos,$aYAbsPos);
+        $this->iSuper = $aSuper;
+    }
+
+    function FromReal($aVal,$aPrecision=2) {
+        // Convert a floating point number to scientific notation
+        $neg=1.0;
+        if( $aVal < 0 ) {
+            $neg = -1.0;
+            $aVal = -$aVal;
+        }
+
+        $l = floor(log10($aVal));
+        $a = sprintf("%0.".$aPrecision."f",round($aVal / pow(10,$l),$aPrecision));
+        $a *= $neg;
+        if( $this->iSimple && ($a == 1 || $a==-1) ) $a = '';
+
+        if( $a != '' ) {
+            $this->t = $a.' * 10';
+        }
+        else {
+            if( $neg == 1 ) {
+                $this->t = '10';
+            }
+            else {
+                $this->t = '-10';
+            }
+        }
+        $this->iSuper = $l;
+    }
+
+    function Set($aTxt,$aSuper='') {
+        $this->t = $aTxt;
+        $this->iSuper = $aSuper;
+    }
+
+    function SetSuperFont($aFontFam,$aFontStyle=FS_NORMAL,$aFontSize=8) {
+        $this->sfont_family = $aFontFam;
+        $this->sfont_style = $aFontStyle;
+        $this->sfont_size = $aFontSize;
+    }
+
+    // Total width of text
+    function GetWidth($aImg) {
+        $aImg->SetFont($this->font_family,$this->font_style,$this->font_size);
+        $w = $aImg->GetTextWidth($this->t);
+        $aImg->SetFont($this->sfont_family,$this->sfont_style,$this->sfont_size);
+        $w += $aImg->GetTextWidth($this->iSuper);
+        $w += $this->iSuperMargin;
+        return $w;
+    }
+
+    // Hight of font (approximate the height of the text)
+    function GetFontHeight($aImg) {
+        $aImg->SetFont($this->font_family,$this->font_style,$this->font_size);
+        $h = $aImg->GetFontHeight();
+        $aImg->SetFont($this->sfont_family,$this->sfont_style,$this->sfont_size);
+        $h += $aImg->GetFontHeight();
+        return $h;
+    }
+
+    // Hight of text
+    function GetTextHeight($aImg) {
+        $aImg->SetFont($this->font_family,$this->font_style,$this->font_size);
+        $h = $aImg->GetTextHeight($this->t);
+        $aImg->SetFont($this->sfont_family,$this->sfont_style,$this->sfont_size);
+        $h += $aImg->GetTextHeight($this->iSuper);
+        return $h;
+    }
+
+    function Stroke($aImg,$ax=-1,$ay=-1) {
+
+        // To position the super script correctly we need different
+        // cases to handle the alignmewnt specified since that will
+        // determine how we can interpret the x,y coordinates
+
+        $w = parent::GetWidth($aImg);
+        $h = parent::GetTextHeight($aImg);
+        switch( $this->valign ) {
+            case 'top':
+                $sy = $this->y;
+                break;
+            case 'center':
+                $sy = $this->y - $h/2;
+                break;
+            case 'bottom':
+                $sy = $this->y - $h;
+                break;
+            default:
+                JpGraphError::RaiseL(25052);//('PANIC: Internal error in SuperScript::Stroke(). Unknown vertical alignment for text');
+                break;
+        }
+
+        switch( $this->halign ) {
+            case 'left':
+                $sx = $this->x + $w;
+                break;
+            case 'center':
+                $sx = $this->x + $w/2;
+                break;
+            case 'right':
+                $sx = $this->x;
+                break;
+            default:
+                JpGraphError::RaiseL(25053);//('PANIC: Internal error in SuperScript::Stroke(). Unknown horizontal alignment for text');
+                break;
+        }
+
+        $sx += $this->iSuperMargin;
+        $sy += $this->iVertOverlap;
+
+        // Should we automatically determine the font or
+        // has the user specified it explicetly?
+        if( $this->sfont_family == '' ) {
+            if( $this->font_family <= FF_FONT2 ) {
+                if( $this->font_family == FF_FONT0 ) {
+                    $sff = FF_FONT0;
+                }
+                elseif( $this->font_family == FF_FONT1 ) {
+                    if( $this->font_style == FS_NORMAL ) {
+                        $sff = FF_FONT0;
+                    }
+                    else {
+                        $sff = FF_FONT1;
+                    }
+                }
+                else {
+                    $sff = FF_FONT1;
+                }
+                $sfs = $this->font_style;
+                $sfz = $this->font_size;
+            }
+            else {
+                // TTF fonts
+                $sff = $this->font_family;
+                $sfs = $this->font_style;
+                $sfz = floor($this->font_size*$this->iSuperScale);
+                if( $sfz < 8 ) $sfz = 8;
+            }
+            $this->sfont_family = $sff;
+            $this->sfont_style = $sfs;
+            $this->sfont_size = $sfz;
+        }
+        else {
+            $sff = $this->sfont_family;
+            $sfs = $this->sfont_style;
+            $sfz = $this->sfont_size;
+        }
+
+        parent::Stroke($aImg,$ax,$ay);
+
+        // For the builtin fonts we need to reduce the margins
+        // since the bounding bx reported for the builtin fonts
+        // are much larger than for the TTF fonts.
+        if( $sff <= FF_FONT2 ) {
+            $sx -= 2;
+            $sy += 3;
+        }
+
+        $aImg->SetTextAlign('left','bottom');
+        $aImg->SetFont($sff,$sfs,$sfz);
+        $aImg->PushColor($this->color);
+        $aImg->StrokeText($sx,$sy,$this->iSuper,$this->iSDir,'left');
+        $aImg->PopColor();
+    }
+}
+
+
+//===================================================
+// CLASS Grid
+// Description: responsible for drawing grid lines in graph
+//===================================================
+class Grid {
+    protected $img;
+    protected $scale;
+    protected $majorcolor='#CCCCCC',$minorcolor='#DDDDDD';
+    protected $majortype='solid',$minortype='solid';
+    protected $show=false, $showMinor=false,$majorweight=1,$minorweight=1;
+    protected $fill=false,$fillcolor=array('#EFEFEF','#BBCCFF');
+
+    function __construct($aAxis) {
+        $this->scale = $aAxis->scale;
+        $this->img = $aAxis->img;
+    }
+
+    function SetColor($aMajColor,$aMinColor=false) {
+        $this->majorcolor=$aMajColor;
+        if( $aMinColor === false ) {
+            $aMinColor = $aMajColor ;
+        }
+        $this->minorcolor = $aMinColor;
+    }
+
+    function SetWeight($aMajorWeight,$aMinorWeight=1) {
+        $this->majorweight=$aMajorWeight;
+        $this->minorweight=$aMinorWeight;
+    }
+
+    // Specify if grid should be dashed, dotted or solid
+    function SetLineStyle($aMajorType,$aMinorType='solid') {
+        $this->majortype = $aMajorType;
+        $this->minortype = $aMinorType;
+    }
+
+    function SetStyle($aMajorType,$aMinorType='solid') {
+        $this->SetLineStyle($aMajorType,$aMinorType);
+    }
+
+    // Decide if both major and minor grid should be displayed
+    function Show($aShowMajor=true,$aShowMinor=false) {
+        $this->show=$aShowMajor;
+        $this->showMinor=$aShowMinor;
+    }
+
+    function SetFill($aFlg=true,$aColor1='lightgray',$aColor2='lightblue') {
+        $this->fill = $aFlg;
+        $this->fillcolor = array( $aColor1, $aColor2 );
+    }
+
+    // Display the grid
+    function Stroke() {
+        if( $this->showMinor && !$this->scale->textscale ) {
+            $this->DoStroke($this->scale->ticks->ticks_pos,$this->minortype,$this->minorcolor,$this->minorweight);
+            $this->DoStroke($this->scale->ticks->maj_ticks_pos,$this->majortype,$this->majorcolor,$this->majorweight);
+        }
+        else {
+            $this->DoStroke($this->scale->ticks->maj_ticks_pos,$this->majortype,$this->majorcolor,$this->majorweight);
+        }
+    }
+
+    //--------------
+    // Private methods
+    // Draw the grid
+    function DoStroke($aTicksPos,$aType,$aColor,$aWeight) {
+        if( !$this->show ) return;
+        $nbrgrids = count($aTicksPos);
+
+        if( $this->scale->type == 'y' ) {
+            $xl=$this->img->left_margin;
+            $xr=$this->img->width-$this->img->right_margin;
+
+            if( $this->fill ) {
+                // Draw filled areas
+                $y2 = $aTicksPos[0];
+                $i=1;
+                while( $i < $nbrgrids ) {
+                    $y1 = $y2;
+                    $y2 = $aTicksPos[$i++];
+                    $this->img->SetColor($this->fillcolor[$i & 1]);
+                    $this->img->FilledRectangle($xl,$y1,$xr,$y2);
+                }
+            }
+
+            $this->img->SetColor($aColor);
+            $this->img->SetLineWeight($aWeight);
+
+            // Draw grid lines
+            switch( $aType ) {
+                case 'solid':  $style = LINESTYLE_SOLID; break;
+                case 'dotted': $style = LINESTYLE_DOTTED; break;
+                case 'dashed': $style = LINESTYLE_DASHED; break;
+                case 'longdashed': $style = LINESTYLE_LONGDASH; break;
+                default:
+                    $style = LINESTYLE_SOLID; break;
+            }
+
+            for($i=0; $i < $nbrgrids; ++$i) {
+                $y=$aTicksPos[$i];
+                $this->img->StyleLine($xl,$y,$xr,$y,$style,true);
+            }
+        }
+        elseif( $this->scale->type == 'x' ) {
+            $yu=$this->img->top_margin;
+            $yl=$this->img->height-$this->img->bottom_margin;
+            $limit=$this->img->width-$this->img->right_margin;
+
+            if( $this->fill ) {
+                // Draw filled areas
+                $x2 = $aTicksPos[0];
+                $i=1;
+                while( $i < $nbrgrids ) {
+                    $x1 = $x2;
+                    $x2 = min($aTicksPos[$i++],$limit) ;
+                    $this->img->SetColor($this->fillcolor[$i & 1]);
+                    $this->img->FilledRectangle($x1,$yu,$x2,$yl);
+                }
+            }
+
+            $this->img->SetColor($aColor);
+            $this->img->SetLineWeight($aWeight);
+
+            // We must also test for limit since we might have
+            // an offset and the number of ticks is calculated with
+            // assumption offset==0 so we might end up drawing one
+            // to many gridlines
+            $i=0;
+            $x=$aTicksPos[$i];
+            while( $i<count($aTicksPos) && ($x=$aTicksPos[$i]) <= $limit ) {
+                if    ( $aType == 'solid' )      $this->img->Line($x,$yl,$x,$yu);
+                elseif( $aType == 'dotted' )     $this->img->DashedLineForGrid($x,$yl,$x,$yu,1,6);
+                elseif( $aType == 'dashed' )     $this->img->DashedLineForGrid($x,$yl,$x,$yu,2,4);
+                elseif( $aType == 'longdashed' ) $this->img->DashedLineForGrid($x,$yl,$x,$yu,8,6);
+                ++$i;
+            }
+        }
+        else {
+            JpGraphError::RaiseL(25054,$this->scale->type);//('Internal error: Unknown grid axis ['.$this->scale->type.']');
+        }
+        return true;
+    }
+} // Class
+
+//===================================================
+// CLASS Axis
+// Description: Defines X and Y axis. Notes that at the
+// moment the code is not really good since the axis on
+// several occasion must know wheter it's an X or Y axis.
+// This was a design decision to make the code easier to
+// follow.
+//===================================================
+class AxisPrototype {
+    public $scale=null;
+    public $img=null;
+    public $hide=false,$hide_labels=false;
+    public $title=null;
+    public $font_family=FF_DEFAULT,$font_style=FS_NORMAL,$font_size=8,$label_angle=0;
+    public $tick_step=1;
+    public $pos = false;
+    public $ticks_label = array();
+
+    protected $weight=1;
+    protected $color=array(0,0,0),$label_color=array(0,0,0);
+    protected $ticks_label_colors=null;
+    protected $show_first_label=true,$show_last_label=true;
+    protected $label_step=1; // Used by a text axis to specify what multiple of major steps
+    // should be labeled.
+    protected $labelPos=0;   // Which side of the axis should the labels be?
+    protected $title_adjust,$title_margin,$title_side=SIDE_LEFT;
+    protected $tick_label_margin=5;
+    protected $label_halign = '',$label_valign = '', $label_para_align='left';
+    protected $hide_line=false;
+    protected $iDeltaAbsPos=0;
+
+    function __construct($img,$aScale,$color = array(0,0,0)) {
+        $this->img = $img;
+        $this->scale = $aScale;
+        $this->color = $color;
+        $this->title=new Text('');
+
+        if( $aScale->type == 'y' ) {
+            $this->title_margin = 25;
+            $this->title_adjust = 'middle';
+            $this->title->SetOrientation(90);
+            $this->tick_label_margin=7;
+            $this->labelPos=SIDE_LEFT;
+        }
+        else {
+            $this->title_margin = 5;
+            $this->title_adjust = 'high';
+            $this->title->SetOrientation(0);
+            $this->tick_label_margin=5;
+            $this->labelPos=SIDE_DOWN;
+            $this->title_side=SIDE_DOWN;
+        }
+    }
+
+    function SetLabelFormat($aFormStr) {
+        $this->scale->ticks->SetLabelFormat($aFormStr);
+    }
+
+    function SetLabelFormatString($aFormStr,$aDate=false) {
+        $this->scale->ticks->SetLabelFormat($aFormStr,$aDate);
+    }
+
+    function SetLabelFormatCallback($aFuncName) {
+        $this->scale->ticks->SetFormatCallback($aFuncName);
+    }
+
+    function SetLabelAlign($aHAlign,$aVAlign='top',$aParagraphAlign='left') {
+        $this->label_halign = $aHAlign;
+        $this->label_valign = $aVAlign;
+        $this->label_para_align = $aParagraphAlign;
+    }
+
+    // Don't display the first label
+    function HideFirstTickLabel($aShow=false) {
+        $this->show_first_label=$aShow;
+    }
+
+    function HideLastTickLabel($aShow=false) {
+        $this->show_last_label=$aShow;
+    }
+
+    // Manually specify the major and (optional) minor tick position and labels
+    function SetTickPositions($aMajPos,$aMinPos=NULL,$aLabels=NULL) {
+        $this->scale->ticks->SetTickPositions($aMajPos,$aMinPos,$aLabels);
+    }
+
+    // Manually specify major tick positions and optional labels
+    function SetMajTickPositions($aMajPos,$aLabels=NULL) {
+        $this->scale->ticks->SetTickPositions($aMajPos,NULL,$aLabels);
+    }
+
+    // Hide minor or major tick marks
+    function HideTicks($aHideMinor=true,$aHideMajor=true) {
+        $this->scale->ticks->SupressMinorTickMarks($aHideMinor);
+        $this->scale->ticks->SupressTickMarks($aHideMajor);
+    }
+
+    // Hide zero label
+    function HideZeroLabel($aFlag=true) {
+        $this->scale->ticks->SupressZeroLabel();
+    }
+
+    function HideFirstLastLabel() {
+        // The two first calls to ticks method will supress
+        // automatically generated scale values. However, that
+        // will not affect manually specified value, e.g text-scales.
+        // therefor we also make a kludge here to supress manually
+        // specified scale labels.
+        $this->scale->ticks->SupressLast();
+        $this->scale->ticks->SupressFirst();
+        $this->show_first_label = false;
+        $this->show_last_label = false;
+    }
+
+    // Hide the axis
+    function Hide($aHide=true) {
+        $this->hide=$aHide;
+    }
+
+    // Hide the actual axis-line, but still print the labels
+    function HideLine($aHide=true) {
+        $this->hide_line = $aHide;
+    }
+
+    function HideLabels($aHide=true) {
+        $this->hide_labels = $aHide;
+    }
+
+    // Weight of axis
+    function SetWeight($aWeight) {
+        $this->weight = $aWeight;
+    }
+
+    // Axis color
+    function SetColor($aColor,$aLabelColor=false) {
+        $this->color = $aColor;
+        if( !$aLabelColor ) $this->label_color = $aColor;
+        else $this->label_color = $aLabelColor;
+    }
+
+    // Title on axis
+    function SetTitle($aTitle,$aAdjustAlign='high') {
+        $this->title->Set($aTitle);
+        $this->title_adjust=$aAdjustAlign;
+    }
+
+    // Specify distance from the axis
+    function SetTitleMargin($aMargin) {
+        $this->title_margin=$aMargin;
+    }
+
+    // Which side of the axis should the axis title be?
+    function SetTitleSide($aSideOfAxis) {
+        $this->title_side = $aSideOfAxis;
+    }
+
+    function SetTickSide($aDir) {
+        $this->scale->ticks->SetSide($aDir);
+    }
+
+    function SetTickSize($aMajSize,$aMinSize=3) {
+        $this->scale->ticks->SetSize($aMajSize,$aMinSize=3);
+    }
+
+    // Specify text labels for the ticks. One label for each data point
+    function SetTickLabels($aLabelArray,$aLabelColorArray=null) {
+        $this->ticks_label = $aLabelArray;
+        $this->ticks_label_colors = $aLabelColorArray;
+    }
+
+    function SetLabelMargin($aMargin) {
+        $this->tick_label_margin=$aMargin;
+    }
+
+    // Specify that every $step of the ticks should be displayed starting
+    // at $start
+    function SetTextTickInterval($aStep,$aStart=0) {
+        $this->scale->ticks->SetTextLabelStart($aStart);
+        $this->tick_step=$aStep;
+    }
+
+    // Specify that every $step tick mark should have a label
+    // should be displayed starting
+    function SetTextLabelInterval($aStep) {
+        if( $aStep < 1 ) {
+            JpGraphError::RaiseL(25058);//(" Text label interval must be specified >= 1.");
+        }
+        $this->label_step=$aStep;
+    }
+
+    function SetLabelSide($aSidePos) {
+        $this->labelPos=$aSidePos;
+    }
+
+    // Set the font
+    function SetFont($aFamily,$aStyle=FS_NORMAL,$aSize=10) {
+        $this->font_family = $aFamily;
+        $this->font_style = $aStyle;
+        $this->font_size = $aSize;
+    }
+
+    // Position for axis line on the "other" scale
+    function SetPos($aPosOnOtherScale) {
+        $this->pos=$aPosOnOtherScale;
+    }
+
+    // Set the position of the axis to be X-pixels delta to the right
+    // of the max X-position (used to position the multiple Y-axis)
+    function SetPosAbsDelta($aDelta) {
+        $this->iDeltaAbsPos=$aDelta;
+    }
+
+    // Specify the angle for the tick labels
+    function SetLabelAngle($aAngle) {
+        $this->label_angle = $aAngle;
+    }
+
+} // Class
+
+
+//===================================================
+// CLASS Axis
+// Description: Defines X and Y axis. Notes that at the
+// moment the code is not really good since the axis on
+// several occasion must know wheter it's an X or Y axis.
+// This was a design decision to make the code easier to
+// follow.
+//===================================================
+class Axis extends AxisPrototype {
+
+    function __construct($img,$aScale,$color='black') {
+        parent::__construct($img,$aScale,$color);
+    }
+
+    // Stroke the axis.
+    function Stroke($aOtherAxisScale,$aStrokeLabels=true) {
+        if( $this->hide )
+            return;
+        if( is_numeric($this->pos) ) {
+            $pos=$aOtherAxisScale->Translate($this->pos);
+        }
+        else { // Default to minimum of other scale if pos not set
+            if( ($aOtherAxisScale->GetMinVal() >= 0 && $this->pos==false) || $this->pos == 'min' ) {
+                $pos = $aOtherAxisScale->scale_abs[0];
+            }
+            elseif($this->pos == "max") {
+                $pos = $aOtherAxisScale->scale_abs[1];
+            }
+            else { // If negative set x-axis at 0
+                $this->pos=0;
+                $pos=$aOtherAxisScale->Translate(0);
+            }
+        }
+
+        $pos += $this->iDeltaAbsPos;
+        $this->img->SetLineWeight($this->weight);
+        $this->img->SetColor($this->color);
+        $this->img->SetFont($this->font_family,$this->font_style,$this->font_size);
+
+        if( $this->scale->type == "x" ) {
+            if( !$this->hide_line ) {
+                // Stroke X-axis
+                $this->img->FilledRectangle(
+                    $this->img->left_margin,
+                    $pos,
+                    $this->img->width - $this->img->right_margin,
+                    $pos + $this->weight-1
+                );
+            }
+            if( $this->title_side == SIDE_DOWN ) {
+                $y = $pos + $this->img->GetFontHeight() + $this->title_margin + $this->title->margin;
+                $yalign = 'top';
+            }
+            else {
+                $y = $pos - $this->img->GetFontHeight() - $this->title_margin - $this->title->margin;
+                $yalign = 'bottom';
+            }
+
+            if( $this->title_adjust=='high' ) {
+                $this->title->SetPos($this->img->width-$this->img->right_margin,$y,'right',$yalign);
+            }
+            elseif( $this->title_adjust=='middle' || $this->title_adjust=='center' ) {
+                $this->title->SetPos(($this->img->width-$this->img->left_margin-$this->img->right_margin)/2+$this->img->left_margin,$y,'center',$yalign);
+            }
+            elseif($this->title_adjust=='low') {
+                $this->title->SetPos($this->img->left_margin,$y,'left',$yalign);
+            }
+            else {
+                JpGraphError::RaiseL(25060,$this->title_adjust);//('Unknown alignment specified for X-axis title. ('.$this->title_adjust.')');
+            }
+        }
+        elseif( $this->scale->type == "y" ) {
+            // Add line weight to the height of the axis since
+            // the x-axis could have a width>1 and we want the axis to fit nicely together.
+            if( !$this->hide_line ) {
+                // Stroke Y-axis
+                $this->img->FilledRectangle(
+                    $pos - $this->weight + 1, 
+                    $this->img->top_margin,
+                    $pos,
+                    $this->img->height - $this->img->bottom_margin + $this->weight - 1
+                );
+            }
+
+            $x=$pos ;
+            if( $this->title_side == SIDE_LEFT ) {
+                $x -= $this->title_margin;
+                $x -= $this->title->margin;
+                $halign = 'right';
+            }
+            else {
+                $x += $this->title_margin;
+                $x += $this->title->margin;
+                $halign = 'left';
+            }
+            // If the user has manually specified an hor. align
+            // then we override the automatic settings with this
+            // specifed setting. Since default is 'left' we compare
+            // with that. (This means a manually set 'left' align
+            // will have no effect.)
+            if( $this->title->halign != 'left' ) {
+                $halign = $this->title->halign;
+            }
+            if( $this->title_adjust == 'high' ) {
+                $this->title->SetPos($x,$this->img->top_margin,$halign,'top');
+            }
+            elseif($this->title_adjust=='middle' || $this->title_adjust=='center') {
+                $this->title->SetPos($x,($this->img->height-$this->img->top_margin-$this->img->bottom_margin)/2+$this->img->top_margin,$halign,"center");
+            }
+            elseif($this->title_adjust=='low') {
+                $this->title->SetPos($x,$this->img->height-$this->img->bottom_margin,$halign,'bottom');
+            }
+            else {
+                JpGraphError::RaiseL(25061,$this->title_adjust);//('Unknown alignment specified for Y-axis title. ('.$this->title_adjust.')');
+            }
+        }
+        $this->scale->ticks->Stroke($this->img,$this->scale,$pos);
+        if( $aStrokeLabels ) {
+            if( !$this->hide_labels ) {
+                $this->StrokeLabels($pos);
+            }
+            $this->title->Stroke($this->img);
+        }
+    }
+
+    //---------------
+    // PRIVATE METHODS
+    // Draw all the tick labels on major tick marks
+    function StrokeLabels($aPos,$aMinor=false,$aAbsLabel=false) {
+
+        if( is_array($this->label_color) && count($this->label_color) > 3 ) {
+            $this->ticks_label_colors = $this->label_color;
+            $this->img->SetColor($this->label_color[0]);
+        }
+        else {
+            $this->img->SetColor($this->label_color);
+        }
+        $this->img->SetFont($this->font_family,$this->font_style,$this->font_size);
+        $yoff=$this->img->GetFontHeight()/2;
+
+        // Only draw labels at major tick marks
+        $nbr = count($this->scale->ticks->maj_ticks_label);
+
+        // We have the option to not-display the very first mark
+        // (Usefull when the first label might interfere with another
+        // axis.)
+        $i = $this->show_first_label ? 0 : 1 ;
+        if( !$this->show_last_label ) {
+            --$nbr;
+        }
+        // Now run through all labels making sure we don't overshoot the end
+        // of the scale.
+        $ncolor=0;
+        if( isset($this->ticks_label_colors) ) {
+            $ncolor=count($this->ticks_label_colors);
+        }
+        while( $i < $nbr ) {
+            // $tpos holds the absolute text position for the label
+            $tpos=$this->scale->ticks->maj_ticklabels_pos[$i];
+
+            // Note. the $limit is only used for the x axis since we
+            // might otherwise overshoot if the scale has been centered
+            // This is due to us "loosing" the last tick mark if we center.
+            if( $this->scale->type == 'x' && $tpos > $this->img->width-$this->img->right_margin+1 ) {
+                return;
+            }
+            // we only draw every $label_step label
+            if( ($i % $this->label_step)==0 ) {
+
+                // Set specific label color if specified
+                if( $ncolor > 0 ) {
+                    $this->img->SetColor($this->ticks_label_colors[$i % $ncolor]);
+                }
+
+                // If the label has been specified use that and in other case
+                // just label the mark with the actual scale value
+                $m=$this->scale->ticks->GetMajor();
+
+                // ticks_label has an entry for each data point and is the array
+                // that holds the labels set by the user. If the user hasn't
+                // specified any values we use whats in the automatically asigned
+                // labels in the maj_ticks_label
+                if( isset($this->ticks_label[$i*$m]) ) {
+                    $label=$this->ticks_label[$i*$m];
+                }
+                else {
+                    if( $aAbsLabel ) {
+                        $label=abs($this->scale->ticks->maj_ticks_label[$i]);
+                    }
+                    else {
+                        $label=$this->scale->ticks->maj_ticks_label[$i];
+                    }
+
+                    // We number the scale from 1 and not from 0 so increase by one
+                    if( $this->scale->textscale && 
+                        $this->scale->ticks->label_formfunc == '' &&
+                        ! $this->scale->ticks->HaveManualLabels() ) {
+
+                        ++$label;
+                        
+                    }
+                }
+
+                if( $this->scale->type == "x" ) {
+                    if( $this->labelPos == SIDE_DOWN ) {
+                        if( $this->label_angle==0 || $this->label_angle==90 ) {
+                            if( $this->label_halign=='' && $this->label_valign=='') {
+                                $this->img->SetTextAlign('center','top');
+                            }
+                            else {
+                                $this->img->SetTextAlign($this->label_halign,$this->label_valign);
+                            }
+
+                        }
+                        else {
+                            if( $this->label_halign=='' && $this->label_valign=='') {
+                                $this->img->SetTextAlign("right","top");
+                            }
+                            else {
+                                $this->img->SetTextAlign($this->label_halign,$this->label_valign);
+                            }
+                        }
+                        $this->img->StrokeText($tpos,$aPos+$this->tick_label_margin,$label,
+                        $this->label_angle,$this->label_para_align);
+                    }
+                    else {
+                        if( $this->label_angle==0 || $this->label_angle==90 ) {
+                            if( $this->label_halign=='' && $this->label_valign=='') {
+                                $this->img->SetTextAlign("center","bottom");
+                            }
+                            else {
+                                $this->img->SetTextAlign($this->label_halign,$this->label_valign);
+                            }
+                        }
+                        else {
+                            if( $this->label_halign=='' && $this->label_valign=='') {
+                                $this->img->SetTextAlign("right","bottom");
+                            }
+                            else {
+                                $this->img->SetTextAlign($this->label_halign,$this->label_valign);
+                            }
+                        }
+                        $this->img->StrokeText($tpos,$aPos-$this->tick_label_margin-1,$label,
+                        $this->label_angle,$this->label_para_align);
+                    }
+                }
+                else {
+                    // scale->type == "y"
+                    //if( $this->label_angle!=0 )
+                    //JpGraphError::Raise(" Labels at an angle are not supported on Y-axis");
+                    if( $this->labelPos == SIDE_LEFT ) { // To the left of y-axis
+                        if( $this->label_halign=='' && $this->label_valign=='') {
+                            $this->img->SetTextAlign("right","center");
+                        }
+                        else {
+                            $this->img->SetTextAlign($this->label_halign,$this->label_valign);
+                        }
+                        $this->img->StrokeText($aPos-$this->tick_label_margin,$tpos,$label,$this->label_angle,$this->label_para_align);
+                    }
+                    else { // To the right of the y-axis
+                        if( $this->label_halign=='' && $this->label_valign=='') {
+                            $this->img->SetTextAlign("left","center");
+                        }
+                        else {
+                            $this->img->SetTextAlign($this->label_halign,$this->label_valign);
+                        }
+                        $this->img->StrokeText($aPos+$this->tick_label_margin,$tpos,$label,$this->label_angle,$this->label_para_align);
+                    }
+                }
+            }
+            ++$i;
+        }
+    }
+
+}
+
+
+//===================================================
+// CLASS Ticks
+// Description: Abstract base class for drawing linear and logarithmic
+// tick marks on axis
+//===================================================
+class Ticks {
+    public $label_formatstr='';   // C-style format string to use for labels
+    public $label_formfunc='';
+    public $label_dateformatstr='';
+    public $direction=1; // Should ticks be in(=1) the plot area or outside (=-1)
+    public $supress_last=false,$supress_tickmarks=false,$supress_minor_tickmarks=false;
+    public $maj_ticks_pos = array(), $maj_ticklabels_pos = array(),
+           $ticks_pos = array(), $maj_ticks_label = array();
+    public $precision;
+
+    protected $minor_abs_size=3, $major_abs_size=5;
+    protected $scale;
+    protected $is_set=false;
+    protected $supress_zerolabel=false,$supress_first=false;
+    protected $mincolor='',$majcolor='';
+    protected $weight=1;
+    protected $label_usedateformat=FALSE;
+
+    function __construct($aScale) {
+        $this->scale=$aScale;
+        $this->precision = -1;
+    }
+
+    // Set format string for automatic labels
+    function SetLabelFormat($aFormatString,$aDate=FALSE) {
+        $this->label_formatstr=$aFormatString;
+        $this->label_usedateformat=$aDate;
+    }
+
+    function SetLabelDateFormat($aFormatString) {
+        $this->label_dateformatstr=$aFormatString;
+    }
+
+    function SetFormatCallback($aCallbackFuncName) {
+        $this->label_formfunc = $aCallbackFuncName;
+    }
+
+    // Don't display the first zero label
+    function SupressZeroLabel($aFlag=true) {
+        $this->supress_zerolabel=$aFlag;
+    }
+
+    // Don't display minor tick marks
+    function SupressMinorTickMarks($aHide=true) {
+        $this->supress_minor_tickmarks=$aHide;
+    }
+
+    // Don't display major tick marks
+    function SupressTickMarks($aHide=true) {
+        $this->supress_tickmarks=$aHide;
+    }
+
+    // Hide the first tick mark
+    function SupressFirst($aHide=true) {
+        $this->supress_first=$aHide;
+    }
+
+    // Hide the last tick mark
+    function SupressLast($aHide=true) {
+        $this->supress_last=$aHide;
+    }
+
+    // Size (in pixels) of minor tick marks
+    function GetMinTickAbsSize() {
+        return $this->minor_abs_size;
+    }
+
+    // Size (in pixels) of major tick marks
+    function GetMajTickAbsSize() {
+        return $this->major_abs_size;
+    }
+
+    function SetSize($aMajSize,$aMinSize=3) {
+        $this->major_abs_size = $aMajSize;
+        $this->minor_abs_size = $aMinSize;
+    }
+
+    // Have the ticks been specified
+    function IsSpecified() {
+        return $this->is_set;
+    }
+
+    function SetSide($aSide) {
+        $this->direction=$aSide;
+    }
+
+    // Which side of the axis should the ticks be on
+    function SetDirection($aSide=SIDE_RIGHT) {
+        $this->direction=$aSide;
+    }
+
+    // Set colors for major and minor tick marks
+    function SetMarkColor($aMajorColor,$aMinorColor='') {
+        $this->SetColor($aMajorColor,$aMinorColor);
+    }
+
+    function SetColor($aMajorColor,$aMinorColor='') {
+        $this->majcolor=$aMajorColor;
+
+        // If not specified use same as major
+        if( $aMinorColor == '' ) {
+            $this->mincolor=$aMajorColor;
+        }
+        else {
+            $this->mincolor=$aMinorColor;
+        }
+    }
+
+    function SetWeight($aWeight) {
+        $this->weight=$aWeight;
+    }
+
+} // Class
+
+//===================================================
+// CLASS LinearTicks
+// Description: Draw linear ticks on axis
+//===================================================
+class LinearTicks extends Ticks {
+    public $minor_step=1, $major_step=2;
+    public $xlabel_offset=0,$xtick_offset=0;
+    private $label_offset=0; // What offset should the displayed label have
+    // i.e should we display 0,1,2 or 1,2,3,4 or 2,3,4 etc
+    private $text_label_start=0;
+    private $iManualTickPos = NULL, $iManualMinTickPos = NULL, $iManualTickLabels = NULL;
+    private $iAdjustForDST = false; // If a date falls within the DST period add one hour to the diaplyed time
+
+    function __construct() {
+        $this->precision = -1;
+    }
+
+    // Return major step size in world coordinates
+    function GetMajor() {
+        return $this->major_step;
+    }
+
+    // Return minor step size in world coordinates
+    function GetMinor() {
+        return $this->minor_step;
+    }
+
+    // Set Minor and Major ticks (in world coordinates)
+    function Set($aMajStep,$aMinStep=false) {
+        if( $aMinStep==false ) {
+            $aMinStep=$aMajStep;
+        }
+
+        if( $aMajStep <= 0 || $aMinStep <= 0 ) {
+            JpGraphError::RaiseL(25064);
+            //(" Minor or major step size is 0. Check that you haven't got an accidental SetTextTicks(0) in your code. If this is not the case you might have stumbled upon a bug in JpGraph. Please report this and if possible include the data that caused the problem.");
+        }
+
+        $this->major_step=$aMajStep;
+        $this->minor_step=$aMinStep;
+        $this->is_set = true;
+    }
+
+    function SetMajTickPositions($aMajPos,$aLabels=NULL) {
+        $this->SetTickPositions($aMajPos,NULL,$aLabels);
+    }
+
+    function SetTickPositions($aMajPos,$aMinPos=NULL,$aLabels=NULL) {
+        if( !is_array($aMajPos) || ($aMinPos!==NULL && !is_array($aMinPos)) ) {
+            JpGraphError::RaiseL(25065);//('Tick positions must be specifued as an array()');
+            return;
+        }
+        $n=count($aMajPos);
+        if( is_array($aLabels) && (count($aLabels) != $n) ) {
+            JpGraphError::RaiseL(25066);//('When manually specifying tick positions and labels the number of labels must be the same as the number of specified ticks.');
+        }
+        $this->iManualTickPos = $aMajPos;
+        $this->iManualMinTickPos = $aMinPos;
+        $this->iManualTickLabels = $aLabels;
+    }
+
+    function HaveManualLabels() {
+        return count($this->iManualTickLabels) > 0;
+    }
+
+    // Specify all the tick positions manually and possible also the exact labels
+    function _doManualTickPos($aScale) {
+        $n=count($this->iManualTickPos);
+        $m=count($this->iManualMinTickPos);
+        $doLbl=count($this->iManualTickLabels) > 0;
+
+        $this->maj_ticks_pos = array();
+        $this->maj_ticklabels_pos = array();
+        $this->ticks_pos = array();
+
+        // Now loop through the supplied positions and translate them to screen coordinates
+        // and store them in the maj_label_positions
+        $minScale = $aScale->scale[0];
+        $maxScale = $aScale->scale[1];
+        $j=0;
+        for($i=0; $i < $n ; ++$i ) {
+            // First make sure that the first tick is not lower than the lower scale value
+            if( !isset($this->iManualTickPos[$i]) || $this->iManualTickPos[$i] < $minScale  || $this->iManualTickPos[$i] > $maxScale) {
+                continue;
+            }
+
+            $this->maj_ticks_pos[$j] = $aScale->Translate($this->iManualTickPos[$i]);
+            $this->maj_ticklabels_pos[$j] = $this->maj_ticks_pos[$j];
+
+            // Set the minor tick marks the same as major if not specified
+            if( $m <= 0 ) {
+                $this->ticks_pos[$j] = $this->maj_ticks_pos[$j];
+            }
+            if( $doLbl ) {
+                $this->maj_ticks_label[$j] = $this->iManualTickLabels[$i];
+            }
+            else {
+                $this->maj_ticks_label[$j]=$this->_doLabelFormat($this->iManualTickPos[$i],$i,$n);
+            }
+            ++$j;
+        }
+
+        // Some sanity check
+        if( count($this->maj_ticks_pos) < 2 ) {
+            JpGraphError::RaiseL(25067);//('Your manually specified scale and ticks is not correct. The scale seems to be too small to hold any of the specified tickl marks.');
+        }
+
+        // Setup the minor tick marks
+        $j=0;
+        for($i=0; $i < $m; ++$i ) {
+            if(  empty($this->iManualMinTickPos[$i]) || $this->iManualMinTickPos[$i] < $minScale  || $this->iManualMinTickPos[$i] > $maxScale) {
+                continue;
+            }
+            $this->ticks_pos[$j] = $aScale->Translate($this->iManualMinTickPos[$i]);
+            ++$j;
+        }
+    }
+
+    function _doAutoTickPos($aScale) {
+        $maj_step_abs = $aScale->scale_factor*$this->major_step;
+        $min_step_abs = $aScale->scale_factor*$this->minor_step;
+
+        if( $min_step_abs==0 || $maj_step_abs==0 ) {
+            JpGraphError::RaiseL(25068);//("A plot has an illegal scale. This could for example be that you are trying to use text autoscaling to draw a line plot with only one point or that the plot area is too small. It could also be that no input data value is numeric (perhaps only '-' or 'x')");
+        }
+        // We need to make this an int since comparing it below
+        // with the result from round() can give wrong result, such that
+        // (40 < 40) == TRUE !!!
+        $limit = (int)$aScale->scale_abs[1];
+
+        if( $aScale->textscale ) {
+            // This can only be true for a X-scale (horizontal)
+            // Define ticks for a text scale. This is slightly different from a
+            // normal linear type of scale since the position might be adjusted
+            // and the labels start at on
+            $label = (float)$aScale->GetMinVal()+$this->text_label_start+$this->label_offset;
+            $start_abs=$aScale->scale_factor*$this->text_label_start;
+            $nbrmajticks=round(($aScale->GetMaxVal()-$aScale->GetMinVal()-$this->text_label_start )/$this->major_step)+1;
+
+            $x = $aScale->scale_abs[0]+$start_abs+$this->xlabel_offset*$min_step_abs;
+            for( $i=0; $label <= $aScale->GetMaxVal()+$this->label_offset; ++$i ) {
+                // Apply format to label
+                $this->maj_ticks_label[$i]=$this->_doLabelFormat($label,$i,$nbrmajticks);
+                $label+=$this->major_step;
+
+                // The x-position of the tick marks can be different from the labels.
+                // Note that we record the tick position (not the label) so that the grid
+                // happen upon tick marks and not labels.
+                $xtick=$aScale->scale_abs[0]+$start_abs+$this->xtick_offset*$min_step_abs+$i*$maj_step_abs;
+                $this->maj_ticks_pos[$i]=$xtick;
+                $this->maj_ticklabels_pos[$i] = round($x);
+                $x += $maj_step_abs;
+            }
+        }
+        else {
+            $label = $aScale->GetMinVal();
+            $abs_pos = $aScale->scale_abs[0];
+            $j=0; $i=0;
+            $step = round($maj_step_abs/$min_step_abs);
+            if( $aScale->type == "x" ) {
+                // For a normal linear type of scale the major ticks will always be multiples
+                // of the minor ticks. In order to avoid any rounding issues the major ticks are
+                // defined as every "step" minor ticks and not calculated separately
+                $nbrmajticks=round(($aScale->GetMaxVal()-$aScale->GetMinVal()-$this->text_label_start )/$this->major_step)+1;
+                while( round($abs_pos) <= $limit ) {
+                    $this->ticks_pos[] = round($abs_pos);
+                    $this->ticks_label[] = $label;
+                    if( $step== 0 || $i % $step == 0 && $j < $nbrmajticks ) {
+                        $this->maj_ticks_pos[$j] = round($abs_pos);
+                        $this->maj_ticklabels_pos[$j] = round($abs_pos);
+                        $this->maj_ticks_label[$j]=$this->_doLabelFormat($label,$j,$nbrmajticks);
+                        ++$j;
+                    }
+                    ++$i;
+                    $abs_pos += $min_step_abs;
+                    $label+=$this->minor_step;
+                }
+            }
+            elseif( $aScale->type == "y" ) {
+                //@todo  s=2:20,12  s=1:50,6  $this->major_step:$nbr
+                // abs_point,limit s=1:270,80 s=2:540,160
+             // $this->major_step = 50;
+                $nbrmajticks=round(($aScale->GetMaxVal()-$aScale->GetMinVal())/$this->major_step)+1;
+//                $step = 5;
+                while( round($abs_pos) >= $limit ) {
+                    $this->ticks_pos[$i] = round($abs_pos);
+                    $this->ticks_label[$i]=$label;
+                    if( $step== 0 || $i % $step == 0 && $j < $nbrmajticks) {
+                        $this->maj_ticks_pos[$j] = round($abs_pos);
+                        $this->maj_ticklabels_pos[$j] = round($abs_pos);
+                        $this->maj_ticks_label[$j]=$this->_doLabelFormat($label,$j,$nbrmajticks);
+                        ++$j;
+                    }
+                    ++$i;
+                    $abs_pos += $min_step_abs;
+                    $label += $this->minor_step;
+                }
+            }
+        }
+    }
+
+    function AdjustForDST($aFlg=true) {
+        $this->iAdjustForDST = $aFlg;
+    }
+
+
+    function _doLabelFormat($aVal,$aIdx,$aNbrTicks) {
+
+        // If precision hasn't been specified set it to a sensible value
+        if( $this->precision==-1 ) {
+            $t = log10($this->minor_step);
+            if( $t > 0 ) {
+                $precision = 0;
+            }
+            else {
+                $precision = -floor($t);
+            }
+        }
+        else {
+            $precision = $this->precision;
+        }
+
+        if( $this->label_formfunc != '' ) {
+            $f=$this->label_formfunc;
+            if( $this->label_formatstr == '' ) {
+                $l = call_user_func($f,$aVal);
+            }
+            else {
+                $l = sprintf($this->label_formatstr, call_user_func($f,$aVal));
+            }
+        }
+        elseif( $this->label_formatstr != '' || $this->label_dateformatstr != '' ) {
+            if( $this->label_usedateformat ) {
+                // Adjust the value to take daylight savings into account
+                if (date("I",$aVal)==1 && $this->iAdjustForDST ) {
+                    // DST
+                    $aVal+=3600;
+                }
+
+                $l = date($this->label_formatstr,$aVal);
+                if( $this->label_formatstr == 'W' ) {
+                    // If we use week formatting then add a single 'w' in front of the
+                    // week number to differentiate it from dates
+                    $l = 'w'.$l;
+                }
+            }
+            else {
+                if( $this->label_dateformatstr !== '' ) {
+                    // Adjust the value to take daylight savings into account
+                    if (date("I",$aVal)==1 && $this->iAdjustForDST ) {
+                        // DST
+                        $aVal+=3600;
+                    }
+
+                    $l = date($this->label_dateformatstr,$aVal);
+                    if( $this->label_formatstr == 'W' ) {
+                        // If we use week formatting then add a single 'w' in front of the
+                        // week number to differentiate it from dates
+                        $l = 'w'.$l;
+                    }
+                }
+                else {
+                    $l = sprintf($this->label_formatstr,$aVal);
+                }
+            }
+        }
+        else {
+            $l = sprintf('%01.'.$precision.'f',round($aVal,$precision));
+        }
+
+        if( ($this->supress_zerolabel && $l==0) ||  ($this->supress_first && $aIdx==0) || ($this->supress_last  && $aIdx==$aNbrTicks-1) ) {
+            $l='';
+        }
+        return $l;
+    }
+
+    // Stroke ticks on either X or Y axis
+    function _StrokeTicks($aImg,$aScale,$aPos) {
+        $hor = $aScale->type == 'x';
+        $aImg->SetLineWeight($this->weight);
+
+        // We need to make this an int since comparing it below
+        // with the result from round() can give wrong result, such that
+        // (40 < 40) == TRUE !!!
+        $limit = (int)$aScale->scale_abs[1];
+
+        // A text scale doesn't have any minor ticks
+        if( !$aScale->textscale ) {
+            // Stroke minor ticks
+            $yu = $aPos - $this->direction*$this->GetMinTickAbsSize();
+            $xr = $aPos + $this->direction*$this->GetMinTickAbsSize();
+            $n = count($this->ticks_pos);
+            for($i=0; $i < $n; ++$i ) {
+                if( !$this->supress_tickmarks && !$this->supress_minor_tickmarks) {
+                    if( $this->mincolor != '') {
+                        $aImg->PushColor($this->mincolor);
+                    }
+                    if( $hor ) {
+                        //if( $this->ticks_pos[$i] <= $limit )
+                        $aImg->Line($this->ticks_pos[$i],$aPos,$this->ticks_pos[$i],$yu);
+                    }
+                    else {
+                        //if( $this->ticks_pos[$i] >= $limit )
+                        $aImg->Line($aPos,$this->ticks_pos[$i],$xr,$this->ticks_pos[$i]);
+                    }
+                    if( $this->mincolor != '' ) {
+                        $aImg->PopColor();
+                    }
+                }
+            }
+        }
+
+        // Stroke major ticks
+        $yu = $aPos - $this->direction*$this->GetMajTickAbsSize();
+        $xr = $aPos + $this->direction*$this->GetMajTickAbsSize();
+        $nbrmajticks=round(($aScale->GetMaxVal()-$aScale->GetMinVal()-$this->text_label_start )/$this->major_step)+1;
+        $n = count($this->maj_ticks_pos);
+        for($i=0; $i < $n ; ++$i ) {
+            if(!($this->xtick_offset > 0 && $i==$nbrmajticks-1) && !$this->supress_tickmarks) {
+                if( $this->majcolor != '') {
+                    $aImg->PushColor($this->majcolor);
+                }
+                if( $hor ) {
+                    //if( $this->maj_ticks_pos[$i] <= $limit )
+                    $aImg->Line($this->maj_ticks_pos[$i],$aPos,$this->maj_ticks_pos[$i],$yu);
+                }
+                else {
+                    //if( $this->maj_ticks_pos[$i] >= $limit )
+                    $aImg->Line($aPos,$this->maj_ticks_pos[$i],$xr,$this->maj_ticks_pos[$i]);
+                }
+                if( $this->majcolor != '') {
+                    $aImg->PopColor();
+                }
+            }
+        }
+
+    }
+
+    // Draw linear ticks
+    function Stroke($aImg,$aScale,$aPos) {
+        if( $this->iManualTickPos != NULL ) {
+            $this->_doManualTickPos($aScale);
+        }
+        else {
+            $this->_doAutoTickPos($aScale);
+        }
+        $this->_StrokeTicks($aImg,$aScale,$aPos, $aScale->type == 'x' );
+    }
+
+    //---------------
+    // PRIVATE METHODS
+    // Spoecify the offset of the displayed tick mark with the tick "space"
+    // Legal values for $o is [0,1] used to adjust where the tick marks and label
+    // should be positioned within the major tick-size
+    // $lo specifies the label offset and $to specifies the tick offset
+    // this comes in handy for example in bar graphs where we wont no offset for the
+    // tick but have the labels displayed halfway under the bars.
+    function SetXLabelOffset($aLabelOff,$aTickOff=-1) {
+        $this->xlabel_offset=$aLabelOff;
+        if( $aTickOff==-1 ) {
+            // Same as label offset
+            $this->xtick_offset=$aLabelOff;
+        }
+        else {
+            $this->xtick_offset=$aTickOff;
+        }
+        if( $aLabelOff>0 ) {
+            $this->SupressLast(); // The last tick wont fit
+        }
+    }
+
+    // Which tick label should we start with?
+    function SetTextLabelStart($aTextLabelOff) {
+        $this->text_label_start=$aTextLabelOff;
+    }
+
+} // Class
+
+//===================================================
+// CLASS LinearScale
+// Description: Handle linear scaling between screen and world
+//===================================================
+class LinearScale {
+    public $textscale=false; // Just a flag to let the Plot class find out if
+    // we are a textscale or not. This is a cludge since
+    // this information is available in Graph::axtype but
+    // we don't have access to the graph object in the Plots
+    // stroke method. So we let graph store the status here
+    // when the linear scale is created. A real cludge...
+    public $type; // is this x or y scale ?
+    public $ticks=null; // Store ticks
+    public $text_scale_off = 0;
+    public $scale_abs=array(0,0);
+    public $scale_factor; // Scale factor between world and screen
+    public $off; // Offset between image edge and plot area
+    public $scale=array(0,0);
+    public $name = 'lin';
+    public $auto_ticks=false; // When using manual scale should the ticks be automatically set?
+    public $world_abs_size; // Plot area size in pixels (Needed public in jpgraph_radar.php)
+    public $intscale=false; // Restrict autoscale to integers
+    protected $autoscale_min=false; // Forced minimum value, auto determine max
+    protected $autoscale_max=false; // Forced maximum value, auto determine min
+    private $gracetop=0,$gracebottom=0;
+
+    private $_world_size; // Plot area size in world coordinates
+
+    function __construct($aMin=0,$aMax=0,$aType='y') {
+        assert($aType=='x' || $aType=='y' );
+        assert($aMin<=$aMax);
+
+        $this->type=$aType;
+        $this->scale=array($aMin,$aMax);
+        $this->world_size=$aMax-$aMin;
+        $this->ticks = new LinearTicks();
+    }
+
+    // Check if scale is set or if we should autoscale
+    // We should do this is either scale or ticks has not been set
+    function IsSpecified() {
+        if( $this->GetMinVal()==$this->GetMaxVal() ) {  // Scale not set
+            return false;
+        }
+        return true;
+    }
+
+    // Set the minimum data value when the autoscaling is used.
+    // Usefull if you want a fix minimum (like 0) but have an
+    // automatic maximum
+    function SetAutoMin($aMin) {
+        $this->autoscale_min=$aMin;
+    }
+
+    // Set the minimum data value when the autoscaling is used.
+    // Usefull if you want a fix minimum (like 0) but have an
+    // automatic maximum
+    function SetAutoMax($aMax) {
+        $this->autoscale_max=$aMax;
+    }
+
+    // If the user manually specifies a scale should the ticks
+    // still be set automatically?
+    function SetAutoTicks($aFlag=true) {
+        $this->auto_ticks = $aFlag;
+    }
+
+    // Specify scale "grace" value (top and bottom)
+    function SetGrace($aGraceTop,$aGraceBottom=0) {
+        if( $aGraceTop<0 || $aGraceBottom < 0  ) {
+            JpGraphError::RaiseL(25069);//(" Grace must be larger then 0");
+        }
+        $this->gracetop=$aGraceTop;
+        $this->gracebottom=$aGraceBottom;
+    }
+
+    // Get the minimum value in the scale
+    function GetMinVal() {
+        return $this->scale[0];
+    }
+
+    // get maximum value for scale
+    function GetMaxVal() {
+        return $this->scale[1];
+    }
+
+    // Specify a new min/max value for sclae
+    function Update($aImg,$aMin,$aMax) {
+        $this->scale=array($aMin,$aMax);
+        $this->world_size=$aMax-$aMin;
+        $this->InitConstants($aImg);
+    }
+
+    // Translate between world and screen
+    function Translate($aCoord) {
+        if( !is_numeric($aCoord) ) {
+            if( $aCoord != '' && $aCoord != '-' && $aCoord != 'x' ) {
+                JpGraphError::RaiseL(25070);//('Your data contains non-numeric values.');
+            }
+            return 0;
+        }
+        else {
+            return round($this->off+($aCoord - $this->scale[0]) * $this->scale_factor);
+        }
+    }
+
+    // Relative translate (don't include offset) usefull when we just want
+    // to know the relative position (in pixels) on the axis
+    function RelTranslate($aCoord) {
+        if( !is_numeric($aCoord) ) {
+            if( $aCoord != '' && $aCoord != '-' && $aCoord != 'x'  ) {
+                JpGraphError::RaiseL(25070);//('Your data contains non-numeric values.');
+            }
+            return 0;
+        }
+        else {
+            return ($aCoord - $this->scale[0]) * $this->scale_factor;
+        }
+    }
+
+    // Restrict autoscaling to only use integers
+    function SetIntScale($aIntScale=true) {
+        $this->intscale=$aIntScale;
+    }
+
+    // Calculate an integer autoscale
+    function IntAutoScale($img,$min,$max,$maxsteps,$majend=true) {
+        // Make sure limits are integers
+        $min=floor($min);
+        $max=ceil($max);
+        if( abs($min-$max)==0 ) {
+            --$min; ++$max;
+        }
+        $maxsteps = floor($maxsteps);
+
+        $gracetop=round(($this->gracetop/100.0)*abs($max-$min));
+        $gracebottom=round(($this->gracebottom/100.0)*abs($max-$min));
+        if( is_numeric($this->autoscale_min) ) {
+            $min = ceil($this->autoscale_min);
+            if( $min >= $max ) {
+                JpGraphError::RaiseL(25071);//('You have specified a min value with SetAutoMin() which is larger than the maximum value used for the scale. This is not possible.');
+            }
+        }
+
+        if( is_numeric($this->autoscale_max) ) {
+            $max = ceil($this->autoscale_max);
+            if( $min >= $max ) {
+                JpGraphError::RaiseL(25072);//('You have specified a max value with SetAutoMax() which is smaller than the miminum value used for the scale. This is not possible.');
+            }
+        }
+
+        if( abs($min-$max ) == 0 ) {
+            ++$max;
+            --$min;
+        }
+
+        $min -= $gracebottom;
+        $max += $gracetop;
+
+        // First get tickmarks as multiples of 1, 10, ...
+        if( $majend ) {
+            list($num1steps,$adj1min,$adj1max,$maj1step) = $this->IntCalcTicks($maxsteps,$min,$max,1);
+        }
+        else {
+            $adj1min = $min;
+            $adj1max = $max;
+            list($num1steps,$maj1step) = $this->IntCalcTicksFreeze($maxsteps,$min,$max,1);
+        }
+
+        if( abs($min-$max) > 2 ) {
+            // Then get tick marks as 2:s 2, 20, ...
+            if( $majend ) {
+                list($num2steps,$adj2min,$adj2max,$maj2step) = $this->IntCalcTicks($maxsteps,$min,$max,5);
+            }
+            else {
+                $adj2min = $min;
+                $adj2max = $max;
+                list($num2steps,$maj2step) = $this->IntCalcTicksFreeze($maxsteps,$min,$max,5);
+            }
+        }
+        else {
+            $num2steps = 10000; // Dummy high value so we don't choose this
+        }
+
+        if( abs($min-$max) > 5 ) {
+            // Then get tickmarks as 5:s 5, 50, 500, ...
+            if( $majend ) {
+                list($num5steps,$adj5min,$adj5max,$maj5step) = $this->IntCalcTicks($maxsteps,$min,$max,2);
+            }
+            else {
+                $adj5min = $min;
+                $adj5max = $max;
+                list($num5steps,$maj5step) = $this->IntCalcTicksFreeze($maxsteps,$min,$max,2);
+            }
+        }
+        else {
+            $num5steps = 10000; // Dummy high value so we don't choose this
+        }
+
+        // Check to see whichof 1:s, 2:s or 5:s fit better with
+        // the requested number of major ticks
+        $match1=abs($num1steps-$maxsteps);
+        $match2=abs($num2steps-$maxsteps);
+        if( !empty($maj5step) && $maj5step > 1 ) {
+            $match5=abs($num5steps-$maxsteps);
+        }
+        else {
+            $match5=10000;  // Dummy high value
+        }
+
+        // Compare these three values and see which is the closest match
+        // We use a 0.6 weight to gravitate towards multiple of 5:s
+        if( $match1 < $match2 ) {
+            if( $match1 < $match5 ) $r=1;
+            else  $r=3;
+        }
+        else {
+            if( $match2 < $match5 ) $r=2;
+            else $r=3;
+        }
+        // Minsteps are always the same as maxsteps for integer scale
+        switch( $r ) {
+            case 1:
+                $this->ticks->Set($maj1step,$maj1step);
+                $this->Update($img,$adj1min,$adj1max);
+                break;
+            case 2:
+                $this->ticks->Set($maj2step,$maj2step);
+                $this->Update($img,$adj2min,$adj2max);
+                break;
+            case 3:
+                $this->ticks->Set($maj5step,$maj5step);
+                $this->Update($img,$adj5min,$adj5max);
+                break;
+            default:
+                JpGraphError::RaiseL(25073,$r);//('Internal error. Integer scale algorithm comparison out of bound (r=$r)');
+        }
+    }
+
+
+    // Calculate autoscale. Used if user hasn't given a scale and ticks
+    // $maxsteps is the maximum number of major tickmarks allowed.
+    function AutoScale($img,$min,$max,$maxsteps,$majend=true) {
+
+        if( !is_numeric($min) || !is_numeric($max) ) {
+            JpGraphError::Raise(25044);
+        }
+
+        if( $this->intscale ) {
+            $this->IntAutoScale($img,$min,$max,$maxsteps,$majend);
+            return;
+        }
+        if( abs($min-$max) < 0.00001 ) {
+            // We need some difference to be able to autoscale
+            // make it 5% above and 5% below value
+            if( $min==0 && $max==0 ) {  // Special case
+                $min=-1; $max=1;
+            }
+            else {
+                $delta = (abs($max)+abs($min))*0.005;
+                $min -= $delta;
+                $max += $delta;
+            }
+        }
+
+        $gracetop=($this->gracetop/100.0)*abs($max-$min);
+        $gracebottom=($this->gracebottom/100.0)*abs($max-$min);
+        if( is_numeric($this->autoscale_min) ) {
+            $min = $this->autoscale_min;
+            if( $min >= $max ) {
+                JpGraphError::RaiseL(25071);//('You have specified a min value with SetAutoMin() which is larger than the maximum value used for the scale. This is not possible.');
+            }
+            if( abs($min-$max ) < 0.001 ) {
+                $max *= 1.2;
+            }
+        }
+
+        if( is_numeric($this->autoscale_max) ) {
+            $max = $this->autoscale_max;
+            if( $min >= $max ) {
+                JpGraphError::RaiseL(25072);//('You have specified a max value with SetAutoMax() which is smaller than the miminum value used for the scale. This is not possible.');
+            }
+            if( abs($min-$max ) < 0.001 ) {
+                $min *= 0.8;
+            }
+        }
+
+        $min -= $gracebottom;
+        $max += $gracetop;
+
+        // First get tickmarks as multiples of 0.1, 1, 10, ...
+        if( $majend ) {
+            list($num1steps,$adj1min,$adj1max,$min1step,$maj1step) = $this->CalcTicks($maxsteps,$min,$max,1,2);
+        }
+        else {
+            $adj1min=$min;
+            $adj1max=$max;
+            list($num1steps,$min1step,$maj1step) = $this->CalcTicksFreeze($maxsteps,$min,$max,1,2,false);
+        }
+
+        // Then get tick marks as 2:s 0.2, 2, 20, ...
+        if( $majend ) {
+            list($num2steps,$adj2min,$adj2max,$min2step,$maj2step) = $this->CalcTicks($maxsteps,$min,$max,5,2);
+        }
+        else {
+            $adj2min=$min;
+            $adj2max=$max;
+            list($num2steps,$min2step,$maj2step) = $this->CalcTicksFreeze($maxsteps,$min,$max,5,2,false);
+        }
+
+        // Then get tickmarks as 5:s 0.05, 0.5, 5, 50, ...
+        if( $majend ) {
+            list($num5steps,$adj5min,$adj5max,$min5step,$maj5step) = $this->CalcTicks($maxsteps,$min,$max,2,5);
+        }
+        else {
+            $adj5min=$min;
+            $adj5max=$max;
+            list($num5steps,$min5step,$maj5step) = $this->CalcTicksFreeze($maxsteps,$min,$max,2,5,false);
+        }
+
+        // Check to see whichof 1:s, 2:s or 5:s fit better with
+        // the requested number of major ticks
+        $match1=abs($num1steps-$maxsteps);
+        $match2=abs($num2steps-$maxsteps);
+        $match5=abs($num5steps-$maxsteps);
+
+        // Compare these three values and see which is the closest match
+        // We use a 0.8 weight to gravitate towards multiple of 5:s
+        $r=$this->MatchMin3($match1,$match2,$match5,0.8);
+        switch( $r ) {
+            case 1:
+                $this->Update($img,$adj1min,$adj1max);
+                $this->ticks->Set($maj1step,$min1step);
+                break;
+            case 2:
+                $this->Update($img,$adj2min,$adj2max);
+                $this->ticks->Set($maj2step,$min2step);
+                break;
+            case 3:
+                $this->Update($img,$adj5min,$adj5max);
+                $this->ticks->Set($maj5step,$min5step);
+                break;
+        }
+    }
+
+    //---------------
+    // PRIVATE METHODS
+
+    // This method recalculates all constants that are depending on the
+    // margins in the image. If the margins in the image are changed
+    // this method should be called for every scale that is registred with
+    // that image. Should really be installed as an observer of that image.
+    function InitConstants($img) {
+        if( $this->type=='x' ) {
+            $this->world_abs_size=$img->width - $img->left_margin - $img->right_margin;
+            $this->off=$img->left_margin;
+            $this->scale_factor = 0;
+            if( $this->world_size > 0 ) {
+                $this->scale_factor=$this->world_abs_size/($this->world_size*1.0);
+            }
+        }
+        else { // y scale
+            $this->world_abs_size=$img->height - $img->top_margin - $img->bottom_margin;
+            $this->off=$img->top_margin+$this->world_abs_size;
+            $this->scale_factor = 0;
+            if( $this->world_size > 0 ) {
+                $this->scale_factor=-$this->world_abs_size/($this->world_size*1.0);
+            }
+        }
+        $size = $this->world_size * $this->scale_factor;
+        $this->scale_abs=array($this->off,$this->off + $size);
+    }
+
+    // Initialize the conversion constants for this scale
+    // This tries to pre-calculate as much as possible to speed up the
+    // actual conversion (with Translate()) later on
+    // $start =scale start in absolute pixels (for x-scale this is an y-position
+    //     and for an y-scale this is an x-position
+    // $len   =absolute length in pixels of scale
+    function SetConstants($aStart,$aLen) {
+        $this->world_abs_size=$aLen;
+        $this->off=$aStart;
+
+        if( $this->world_size<=0 ) {
+            // This should never ever happen !!
+            JpGraphError::RaiseL(25074);
+            //("You have unfortunately stumbled upon a bug in JpGraph. It seems like the scale range is ".$this->world_size." [for ".$this->type." scale] <br> Please report Bug #01 to info@jpgraph.net and include the script that gave this error. This problem could potentially be caused by trying to use \"illegal\" values in the input data arrays (like trying to send in strings or only NULL values) which causes the autoscaling to fail.");
+        }
+
+        // scale_factor = number of pixels per world unit
+        $this->scale_factor=$this->world_abs_size/($this->world_size*1.0);
+
+        // scale_abs = start and end points of scale in absolute pixels
+        $this->scale_abs=array($this->off,$this->off+$this->world_size*$this->scale_factor);
+    }
+
+
+    // Calculate number of ticks steps with a specific division
+    // $a is the divisor of 10**x to generate the first maj tick intervall
+    // $a=1, $b=2 give major ticks with multiple of 10, ...,0.1,1,10,...
+    // $a=5, $b=2 give major ticks with multiple of 2:s ...,0.2,2,20,...
+    // $a=2, $b=5 give major ticks with multiple of 5:s ...,0.5,5,50,...
+    // We return a vector of
+    //  [$numsteps,$adjmin,$adjmax,$minstep,$majstep]
+    // If $majend==true then the first and last marks on the axis will be major
+    // labeled tick marks otherwise it will be adjusted to the closest min tick mark
+    function CalcTicks($maxsteps,$min,$max,$a,$b,$majend=true) {
+        $diff=$max-$min;
+        if( $diff==0 ) {
+            $ld=0;
+        }
+        else {
+            $ld=floor(log10($diff));
+        }
+
+        // Gravitate min towards zero if we are close
+        if( $min>0 && $min < pow(10,$ld) ) $min=0;
+
+        //$majstep=pow(10,$ld-1)/$a;
+        $majstep=pow(10,$ld)/$a;
+        $minstep=$majstep/$b;
+
+        $adjmax=ceil($max/$minstep)*$minstep;
+        $adjmin=floor($min/$minstep)*$minstep;
+        $adjdiff = $adjmax-$adjmin;
+        $numsteps=$adjdiff/$majstep;
+
+        while( $numsteps>$maxsteps ) {
+            $majstep=pow(10,$ld)/$a;
+            $numsteps=$adjdiff/$majstep;
+            ++$ld;
+        }
+
+        $minstep=$majstep/$b;
+        $adjmin=floor($min/$minstep)*$minstep;
+        $adjdiff = $adjmax-$adjmin;
+        if( $majend ) {
+            $adjmin = floor($min/$majstep)*$majstep;
+            $adjdiff = $adjmax-$adjmin;
+            $adjmax = ceil($adjdiff/$majstep)*$majstep+$adjmin;
+        }
+        else {
+            $adjmax=ceil($max/$minstep)*$minstep;
+        }
+
+        return array($numsteps,$adjmin,$adjmax,$minstep,$majstep);
+    }
+
+    function CalcTicksFreeze($maxsteps,$min,$max,$a,$b) {
+        // Same as CalcTicks but don't adjust min/max values
+        $diff=$max-$min;
+        if( $diff==0 ) {
+            $ld=0;
+        }
+        else {
+            $ld=floor(log10($diff));
+        }
+
+        //$majstep=pow(10,$ld-1)/$a;
+        $majstep=pow(10,$ld)/$a;
+        $minstep=$majstep/$b;
+        $numsteps=floor($diff/$majstep);
+
+        while( $numsteps > $maxsteps ) {
+            $majstep=pow(10,$ld)/$a;
+            $numsteps=floor($diff/$majstep);
+            ++$ld;
+        }
+        $minstep=$majstep/$b;
+        return array($numsteps,$minstep,$majstep);
+    }
+
+
+    function IntCalcTicks($maxsteps,$min,$max,$a,$majend=true) {
+        $diff=$max-$min;
+        if( $diff==0 ) {
+            JpGraphError::RaiseL(25075);//('Can\'t automatically determine ticks since min==max.');
+        }
+        else {
+            $ld=floor(log10($diff));
+        }
+
+        // Gravitate min towards zero if we are close
+        if( $min>0 && $min < pow(10,$ld) ) {
+            $min=0;
+        }
+        if( $ld == 0 ) {
+            $ld=1;
+        }
+        if( $a == 1 ) {
+            $majstep = 1;
+        }
+        else {
+            $majstep=pow(10,$ld)/$a;
+        }
+        $adjmax=ceil($max/$majstep)*$majstep;
+
+        $adjmin=floor($min/$majstep)*$majstep;
+        $adjdiff = $adjmax-$adjmin;
+        $numsteps=$adjdiff/$majstep;
+        while( $numsteps>$maxsteps ) {
+            $majstep=pow(10,$ld)/$a;
+            $numsteps=$adjdiff/$majstep;
+            ++$ld;
+        }
+
+        $adjmin=floor($min/$majstep)*$majstep;
+        $adjdiff = $adjmax-$adjmin;
+        if( $majend ) {
+            $adjmin = floor($min/$majstep)*$majstep;
+            $adjdiff = $adjmax-$adjmin;
+            $adjmax = ceil($adjdiff/$majstep)*$majstep+$adjmin;
+        }
+        else {
+            $adjmax=ceil($max/$majstep)*$majstep;
+        }
+
+        return array($numsteps,$adjmin,$adjmax,$majstep);
+    }
+
+
+    function IntCalcTicksFreeze($maxsteps,$min,$max,$a) {
+        // Same as IntCalcTick but don't change min/max values
+        $diff=$max-$min;
+        if( $diff==0 ) {
+            JpGraphError::RaiseL(25075);//('Can\'t automatically determine ticks since min==max.');
+        }
+        else {
+            $ld=floor(log10($diff));
+        }
+        if( $ld == 0 ) {
+            $ld=1;
+        }
+        if( $a == 1 ) {
+            $majstep = 1;
+        }
+        else {
+            $majstep=pow(10,$ld)/$a;
+        }
+
+        $numsteps=floor($diff/$majstep);
+        while( $numsteps > $maxsteps ) {
+            $majstep=pow(10,$ld)/$a;
+            $numsteps=floor($diff/$majstep);
+            ++$ld;
+        }
+
+        return array($numsteps,$majstep);
+    }
+
+    // Determine the minimum of three values witha  weight for last value
+    function MatchMin3($a,$b,$c,$weight) {
+        if( $a < $b ) {
+            if( $a < ($c*$weight) ) {
+                return 1; // $a smallest
+            }
+            else {
+                return 3; // $c smallest
+            }
+        }
+        elseif( $b < ($c*$weight) ) {
+            return 2; // $b smallest
+        }
+        return 3; // $c smallest
+    }
+
+    function __get($name) {
+        $variable_name = '_' . $name; 
+
+        if (isset($this->$variable_name)) {
+            return $this->$variable_name * SUPERSAMPLING_SCALE;
+        } else {
+            JpGraphError::RaiseL('25132', $name);
+        } 
+    }
+
+    function __set($name, $value) {
+        $this->{'_'.$name} = $value;
+    }
+} // Class
+
+
+//===================================================
+// CLASS DisplayValue
+// Description: Used to print data values at data points
+//===================================================
+class DisplayValue {
+    public $margin=5;
+    public $show=false;
+    public $valign='',$halign='center';
+    public $format='%.1f',$negformat='';
+    private $ff=FF_DEFAULT,$fs=FS_NORMAL,$fsize=8;
+    private $iFormCallback='';
+    private $angle=0;
+    private $color='navy',$negcolor='';
+    private $iHideZero=false;
+    public $txt=null;
+
+    function __construct() {
+                $this->txt = new Text();
+    }
+
+    function Show($aFlag=true) {
+        $this->show=$aFlag;
+    }
+
+    function SetColor($aColor,$aNegcolor='') {
+        $this->color = $aColor;
+        $this->negcolor = $aNegcolor;
+    }
+
+    function SetFont($aFontFamily,$aFontStyle=FS_NORMAL,$aFontSize=8) {
+        $this->ff=$aFontFamily;
+        $this->fs=$aFontStyle;
+        $this->fsize=$aFontSize;
+    }
+
+    function ApplyFont($aImg) {
+        $aImg->SetFont($this->ff,$this->fs,$this->fsize);
+    }
+
+    function SetMargin($aMargin) {
+        $this->margin = $aMargin;
+    }
+
+    function SetAngle($aAngle) {
+        $this->angle = $aAngle;
+    }
+
+    function SetAlign($aHAlign,$aVAlign='') {
+        $this->halign = $aHAlign;
+        $this->valign = $aVAlign;
+    }
+
+    function SetFormat($aFormat,$aNegFormat='') {
+        $this->format= $aFormat;
+        $this->negformat= $aNegFormat;
+    }
+
+    function SetFormatCallback($aFunc) {
+        $this->iFormCallback = $aFunc;
+    }
+
+    function HideZero($aFlag=true) {
+        $this->iHideZero=$aFlag;
+    }
+
+    function Stroke($img,$aVal,$x,$y) {
+
+        if( $this->show )
+        {
+            if( $this->negformat=='' ) {
+                $this->negformat=$this->format;
+            }
+            if( $this->negcolor=='' ) {
+                $this->negcolor=$this->color;
+            }
+
+            if( $aVal===NULL || (is_string($aVal) && ($aVal=='' || $aVal=='-' || $aVal=='x' ) ) ) {
+                return;
+            }
+
+            if( is_numeric($aVal) && $aVal==0 && $this->iHideZero ) {
+                return;
+            }
+
+            // Since the value is used in different cirumstances we need to check what
+            // kind of formatting we shall use. For example, to display values in a line
+            // graph we simply display the formatted value, but in the case where the user
+            // has already specified a text string we don't fo anything.
+            if( $this->iFormCallback != '' ) {
+                $f = $this->iFormCallback;
+                $sval = call_user_func($f,$aVal);
+            }
+            elseif( is_numeric($aVal) ) {
+                if( $aVal >= 0 ) {
+                    $sval=sprintf($this->format,$aVal);
+                }
+                else {
+                    $sval=sprintf($this->negformat,$aVal);
+                }
+            }
+            else {
+                $sval=$aVal;
+            }
+
+            $y = $y-sign($aVal)*$this->margin;
+
+            $this->txt->Set($sval);
+            $this->txt->SetPos($x,$y);
+            $this->txt->SetFont($this->ff,$this->fs,$this->fsize);
+            if( $this->valign == '' ) {
+                if( $aVal >= 0 ) {
+                    $valign = "bottom";
+                }
+                else {
+                    $valign = "top";
+                }
+            }
+            else {
+                $valign = $this->valign;
+            }
+            $this->txt->Align($this->halign,$valign);
+
+            $this->txt->SetOrientation($this->angle);
+            if( $aVal > 0 ) {
+                $this->txt->SetColor($this->color);
+            }
+            else {
+                $this->txt->SetColor($this->negcolor);
+            }
+            $this->txt->Stroke($img);
+        }
+    }
+}
+
+//===================================================
+// CLASS Plot
+// Description: Abstract base class for all concrete plot classes
+//===================================================
+class Plot {
+    public $numpoints=0;
+    public $value;
+    public $legend='';
+    public $coords=array();
+    public $color='black';
+    public $hidelegend=false;
+    public $line_weight=1;
+    public $csimtargets=array(),$csimwintargets=array(); // Array of targets for CSIM
+    public $csimareas='';   // Resultant CSIM area tags
+    public $csimalts=null;   // ALT:s for corresponding target
+    public $legendcsimtarget='',$legendcsimwintarget='';
+    public $legendcsimalt='';
+    protected $weight=1;
+    protected $center=false;
+
+    protected $inputValues;
+    protected $isRunningClear = false;
+
+    function __construct($aDatay,$aDatax=false) {
+        $this->numpoints = count($aDatay);
+        if( $this->numpoints==0 ) {
+            JpGraphError::RaiseL(25121);//("Empty input data array specified for plot. Must have at least one data point.");
+        }
+
+        if (!$this->isRunningClear) {
+            $this->inputValues = array();
+            $this->inputValues['aDatay'] = $aDatay;
+            $this->inputValues['aDatax'] = $aDatax;
+        }
+
+        $this->coords[0]=$aDatay;
+        if( is_array($aDatax) ) {
+            $this->coords[1]=$aDatax;
+            $n = count($aDatax);
+            for( $i=0; $i < $n; ++$i ) {
+                if( !is_numeric($aDatax[$i]) ) {
+                    JpGraphError::RaiseL(25070);
+                }
+            }
+        }
+        $this->value = new DisplayValue();
+    }
+
+    // Stroke the plot
+    // "virtual" function which must be implemented by
+    // the subclasses
+    function Stroke($aImg,$aXScale,$aYScale) {
+        JpGraphError::RaiseL(25122);//("JpGraph: Stroke() must be implemented by concrete subclass to class Plot");
+    }
+
+    function HideLegend($f=true) {
+        $this->hidelegend = $f;
+    }
+
+    function DoLegend($graph) {
+        if( !$this->hidelegend )
+        $this->Legend($graph);
+    }
+
+    function StrokeDataValue($img,$aVal,$x,$y) {
+        $this->value->Stroke($img,$aVal,$x,$y);
+    }
+
+    // Set href targets for CSIM
+    function SetCSIMTargets($aTargets,$aAlts='',$aWinTargets='') {
+        $this->csimtargets=$aTargets;
+        $this->csimwintargets=$aWinTargets;
+        $this->csimalts=$aAlts;
+    }
+
+    // Get all created areas
+    function GetCSIMareas() {
+        return $this->csimareas;
+    }
+
+    // "Virtual" function which gets called before any scale
+    // or axis are stroked used to do any plot specific adjustment
+    function PreStrokeAdjust($aGraph) {
+        if( substr($aGraph->axtype,0,4) == "text" && (isset($this->coords[1])) ) {
+            JpGraphError::RaiseL(25123);//("JpGraph: You can't use a text X-scale with specified X-coords. Use a \"int\" or \"lin\" scale instead.");
+        }
+        return true;
+    }
+
+    // Virtual function to the the concrete plot class to make any changes to the graph
+    // and scale before the stroke process begins
+    function PreScaleSetup($aGraph) {
+        // Empty
+    }
+
+    // Get minimum values in plot
+    function Min() {
+        if( isset($this->coords[1]) ) {
+            $x=$this->coords[1];
+        }
+        else {
+            $x='';
+        }
+        if( $x != '' && count($x) > 0 ) {
+            $xm=min($x);
+        }
+        else {
+            $xm=0;
+        }
+        $y=$this->coords[0];
+        $cnt = count($y);
+        if( $cnt > 0 ) {
+            $i=0;
+            while( $i<$cnt && !is_numeric($ym=$y[$i]) ) {
+                $i++;
+            }
+            while( $i < $cnt) {
+                if( is_numeric($y[$i]) ) {
+                    $ym=min($ym,$y[$i]);
+                }
+                ++$i;
+            }
+        }
+        else {
+            $ym='';
+        }
+        return array($xm,$ym);
+    }
+
+    // Get maximum value in plot
+    function Max() {
+        if( isset($this->coords[1]) ) {
+            $x=$this->coords[1];
+        }
+        else {
+            $x='';
+        }
+
+        if( $x!='' && count($x) > 0 ) {
+            $xm=max($x);
+        }
+        else {
+            $xm = $this->numpoints-1;
+        }
+        $y=$this->coords[0];
+        if( count($y) > 0 ) {
+            $cnt = count($y);
+            $i=0;
+            while( $i<$cnt && !is_numeric($ym=$y[$i]) ) {
+                $i++;
+            }
+            while( $i < $cnt ) {
+                if( is_numeric($y[$i]) ) {
+                    $ym=max($ym,$y[$i]);
+                }
+                ++$i;
+            }
+        }
+        else {
+            $ym='';
+        }
+        return array($xm,$ym);
+    }
+
+    function SetColor($aColor) {
+        $this->color=$aColor;
+    }
+
+    function SetLegend($aLegend,$aCSIM='',$aCSIMAlt='',$aCSIMWinTarget='') {
+        $this->legend = $aLegend;
+        $this->legendcsimtarget = $aCSIM;
+        $this->legendcsimwintarget = $aCSIMWinTarget;
+        $this->legendcsimalt = $aCSIMAlt;
+    }
+
+    function SetWeight($aWeight) {
+        $this->weight=$aWeight;
+    }
+
+    function SetLineWeight($aWeight=1) {
+        $this->line_weight=$aWeight;
+    }
+
+    function SetCenter($aCenter=true) {
+        $this->center = $aCenter;
+    }
+
+    // This method gets called by Graph class to plot anything that should go
+    // into the margin after the margin color has been set.
+    function StrokeMargin($aImg) {
+        return true;
+    }
+
+    // Framework function the chance for each plot class to set a legend
+    function Legend($aGraph) {
+        if( $this->legend != '' ) {
+            $aGraph->legend->Add($this->legend,$this->color,'',0,$this->legendcsimtarget,$this->legendcsimalt,$this->legendcsimwintarget);
+        }
+    }
+
+    function Clear() {
+        $this->isRunningClear = true;
+        $this->__construct($this->inputValues['aDatay'], $this->inputValues['aDatax']);
+        $this->isRunningClear = false;
+    }
+
+} // Class
+
+
+// Provide a deterministic list of new colors whenever the getColor() method
+// is called. Used to automatically set colors of plots.
+class ColorFactory {
+
+    static private $iIdx = 0;
+    static private $iColorList = array(
+        'black',
+        'blue',
+        'orange',
+        'darkgreen',
+        'red',
+        'AntiqueWhite3',
+        'aquamarine3',
+        'azure4',
+        'brown',
+        'cadetblue3',
+        'chartreuse4',
+        'chocolate',
+        'darkblue',
+        'darkgoldenrod3',
+        'darkorchid3',
+        'darksalmon',
+        'darkseagreen4',
+        'deepskyblue2',
+        'dodgerblue4',
+        'gold3',
+        'hotpink',
+        'lawngreen',
+        'lightcoral',
+        'lightpink3',
+        'lightseagreen',
+        'lightslateblue',
+        'mediumpurple',
+        'olivedrab',
+        'orangered1',
+        'peru',
+        'slategray',
+        'yellow4',
+        'springgreen2');
+    static private $iNum = 33;
+
+    static function getColor() {
+        if( ColorFactory::$iIdx >= ColorFactory::$iNum )
+            ColorFactory::$iIdx = 0;
+        return ColorFactory::$iColorList[ColorFactory::$iIdx++];
+    }
+
+}
+
+// <EOF>
+?>
diff --git a/web/classes/jpgraph/jpgraph_antispam-digits.php b/web/classes/jpgraph/jpgraph_antispam-digits.php
new file mode 100755
index 0000000000000000000000000000000000000000..d9d350ca445ae11e3c1e574a7c00636dceac7d7d
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_antispam-digits.php
@@ -0,0 +1,205 @@
+<?php
+//=======================================================================
+// File:        JPGRAPH_ANTISPAM.PHP
+// Description: Genarate anti-spam challenge
+// Created:     2004-10-07
+// Ver:         $Id: jpgraph_antispam-digits.php 1930 2010-01-22 20:19:27Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+class HandDigits {
+    public $digits = array();
+    public $iHeight=30, $iWidth=30;
+
+    function __construct() {
+        //==========================================================
+        // d6-small.jpg
+        //==========================================================
+        $this->digits['6'][0]= 645 ;
+        $this->digits['6'][1]=
+     '/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+     'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+     'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AEgMBIgACEQEDEQH/xAAZAAEBAAMBAAAAAAAAAAAAAAAABgMEBwX/xAAvEAABAwMC'.
+     'BAQEBwAAAAAAAAABAgMEAAURBiESIjFRBxMUQRUWMmFTYnGRkrHC/8QAFgEBAQEAAAAAAAAAAAAAAAAAAAEC/8QAFhEBAQEAAAAA'.
+     'AAAAAAAAAAAAAAER/9oADAMBAAIRAxEAPwDslwiR3oDku8ONttsAvDiVyMcO/ET7ke5/aoOz6k1Vr5htNjW7a7M1yO3NTQU9JUDu'.
+     'GgrlSn8xyf6p4gXaHJvNps9/mKZtSkGdMjRwpfqAFBLLACRlZUrJONsI2717No1lbZ10kx7XGnRpKWQ/6GVGMfzEJ5VFIVtsOH6e'.
+     'wyKVhYsia0y22pLThSkJK1uniVgdThOM0ol+StIUhpopIyCFq3H8aUVCwnG3PGe4Rp6fLXJtMdyM0ojcIWvIz3HFnAPfrWTXb6GN'.
+     'WaLXDwZjVz8pKEfhuIUFg/bAz9sVJ61nt61mxJFslLtq7e5yPqiBT4UDklKw4MDpt+u+9bFiu9riXNu83R+fcr6tohuQ5HQhmK37'.
+     'paaC8DruScmg6X8KkjZEhbaB9KEyFYSOw26Uqd+e7Qerl5z74DY/1SomP//Z' ; 
+
+        //==========================================================
+        // d2-small.jpg
+        //==========================================================
+        $this->digits['2'][0]= 606 ;
+        $this->digits['2'][1]=
+     '/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+     'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+     'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AEQMBIgACEQEDEQH/xAAYAAEBAQEBAAAAAAAAAAAAAAAFAAQHAv/EACsQAAEDBAEC'.
+     'BAYDAAAAAAAAAAIBAwQABQYRIRIxQVFhcQcTFSJSU5GU0f/EABcBAAMBAAAAAAAAAAAAAAAAAAECAwT/xAAZEQACAwEAAAAAAAAA'.
+     'AAAAAAAAARESUUH/2gAMAwEAAhEDEQA/AOqXm/Q8dxmOL4PPSnCSNFixx6nXnkXgRT3Te17JWbGsveueSyLZdbPItNxOKLzTLjou'.
+     'gYCSoSoY8ISKSbFeUrzkdlnTL1YshskiErkQnFEZaF8kkdBBVdjyi6RNL5+9F486eS/ECVkcBtDt1vZcho5viS8ZCp9C9tAIAm/F'.
+     'VoPRU+HRtJ5JVRP1kP0PfwP+1VKrHBMliXG4Nw8VgE4xGkuqk2S1wTUNEVdIvgpL9iL6KtNxY7WOwo9tt0RCitj0sR2uCbFPPzH1'.
+     '7+6rRuSRcljMBMsUy2tky045KOawZk5xtEFBJEROO3hx61kh2rPCIX3MhsyC4QmfTbC6lH8dq5212qwkiG5H6Y/9R2qm+ofxqqsL'.
+     'DLZ6f//Z' ; 
+
+        //==========================================================
+        // d9-small.jpg
+        //==========================================================
+        $this->digits['9'][0]= 680 ;
+        $this->digits['9'][1]=
+     '/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+     'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+     'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AEgMBIgACEQEDEQH/xAAZAAACAwEAAAAAAAAAAAAAAAAABAUGBwP/xAArEAABAwMD'.
+     'AgYBBQAAAAAAAAABAgMEBQYRABIhE1EUIjEzQUIHMlJhcdH/xAAWAQEBAQAAAAAAAAAAAAAAAAACAQD/xAAYEQEAAwEAAAAAAAAA'.
+     'AAAAAAAAAREhQf/aAAwDAQACEQMRAD8AkK7brF6X7XpMeGoKhFMLEeT4ZUheEhanF4OcZ2pTgDykk92bZpdCsi7aezLjxkIPUZiV'.
+     'RSCy8hah7EkZ27yM7V+iscal5bE22Lon1qNDmSKROd8Sl+Ix1lMOlIS4HGgQpbStoUCnlJz8HmsXtW3Lst2rmBAelLMRRekOwnYz'.
+     'Edls9QKKnOVLyk7UgcbzzrdBthqEJJwZbAI4x1U/7o1TaFa9lG36aXaZTy54VrcXUgrzsGdx+T30aNydweqVw1GS87T6Lb86Q4ha'.
+     'my/IAYjZBx+snKk99oOQMf1AViE65SY348hzFy6hPKnqtKz7DC1lbqyPrvJKUJ7H+M6Wrt3InP7o1brFNp4bCDGhxGAsqz69VSiQ'.
+     'ORwBxrrQ7itm1ac7Hp0WoGTIc3PSn0pccdcP2WorycfA1RaRHjxosZqOyhtDTSAhCf2gDAGjVHTd9sKSCumynFEZK1tIJUe58/ro'.
+     '1V1//9k=' ; 
+
+        //==========================================================
+        // d5-small.jpg
+        //==========================================================
+        $this->digits['5'][0]= 632 ;
+        $this->digits['5'][1]=
+     '/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+     'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+     'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AEgMBIgACEQEDEQH/xAAZAAACAwEAAAAAAAAAAAAAAAAABgIFBwT/xAAoEAABAwME'.
+     'AQQCAwAAAAAAAAABAgMEBQYRABIhIkEUMVFhBxNCgaH/xAAVAQEBAAAAAAAAAAAAAAAAAAAAAv/EABcRAQEBAQAAAAAAAAAAAAAA'.
+     'AAABEUH/2gAMAwEAAhEDEQA/ANGvW4YVOeiRX5b4mv5Sin05IdlupPKdo/j2SO3+6TbPNQvOsTVz33KRT4csR3YUF7Dsh5OSFvug'.
+     'kqG4FPBxnjxpvvi4KZb1pTpU+QwxUi2Y7ZIAefUk5ATxnB9/gbtL/wCH1UpuhPUlZlMVaQ0mS8zJjqZOPfc2TwpIUonI9tw40R1r'.
+     'WNGq/wBdJR1XT3lqHBUnGCfkfWjRWs1ve249erQqQYjOtN1FqPUpCXQ4WIzQSsJwT0UpRwQPG0nzqyuNHobjsl9kBuWqoOoXtT1/'.
+     'WppZcA8lKRj64HxqU+3KpAr6plElRVKef3S4E0K9O8pLXVzKcqSsJAB9wSAca6bSoNXeuA1+5pEV+SGFNU1iKVFqI0Vdx2AJUeoz'.
+     '8DGlTDwG3CAf3q/pI0ah6MDhLz6U+EpXwPoaNMU//9k=' ; 
+
+        //==========================================================
+        // d1-small.jpg
+        //==========================================================
+        $this->digits['1'][0]= 646 ;
+        $this->digits['1'][1]=
+     '/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+     'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+     'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AEwMBIgACEQEDEQH/xAAZAAADAAMAAAAAAAAAAAAAAAAABQYCBAf/xAApEAACAQMD'.
+     'AwQBBQAAAAAAAAABAgMEBREABiESMUEHEyJRkSNCYXGB/8QAFgEBAQEAAAAAAAAAAAAAAAAAAAEC/8QAFxEBAQEBAAAAAAAAAAAA'.
+     'AAAAAAEREv/aAAwDAQACEQMRAD8A6jdd4WLbstILnc4Uq0VoWpkJknb6IjXLHJUePOlez923fcW4r1SxWlqC2UbdKirQif3Xw3yA'.
+     'OFAGT09/kO3OmV3a20MFRf6lIYPcpy7yRRAzgxjIy2M8YwcdiBzpX6d22VNvUlTXsFkuwkrKqNSfnK7F8OTzwrAY+l5zoxKskudN'.
+     'EgQPUT9PBkWF3DH+1GPxo1mLnRoAqF2VRgGOFmX/AAgY/GjRUP6hVMFv2FuFqUvUGrpDFJMBnpdyF5bsAQew7Hxzp6LZNT0yQ1DI'.
+     'wp0QCFBhD0jCsfLZHxbx5xxpTuvb1+v9PV7Ztk9roLPLCjmSSN3mX5ZwqjCgZX7PfWxDQb2in96pv9qq46aTE0bW4x9ceAWAYPwS'.
+     'PsYzoixgmheBGjIVcYCnjp/jHjHbRpe1JLn9OnopE/a0ykvjwDx47aNMXqP/2Q==' ; 
+
+        //==========================================================
+        // d8-small.jpg
+        //==========================================================
+        $this->digits['8'][0]= 694 ;
+        $this->digits['8'][1]=
+     '/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+     'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+     'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AFQMBIgACEQEDEQH/xAAYAAADAQEAAAAAAAAAAAAAAAAABgcEBf/EACsQAAEDAwMD'.
+     'AwMFAAAAAAAAAAECAwQFBhEAEiEUMVEHE0EVYYEiIzJCsf/EABYBAQEBAAAAAAAAAAAAAAAAAAIAAf/EABcRAQEBAQAAAAAAAAAA'.
+     'AAAAAAABERL/2gAMAwEAAhEDEQA/AKL6gVVUa0i1T5QjvTprUJMlxW4R9zgQXe/AH+kaWrntqlWjaq7gpcmotXAw82ht9yY4tch8'.
+     'uAFC0k7VBXPGMY51ruiaue+bThIj+7NbWqS+7HDxajFf6AlB/k44o8ZOABk4xkL0X0tZiojKrlRuGRJjugqldSlKGf6t7BuUQe3J'.
+     '44xxxrA1a4KVJipLidri8uLHgqOcfjOPxo0o2hdDvS1CmV2Yl6fS5ioipIQR1CAlKkLKR2UUqAI8g6NRSwuuyHab6s1ufLI/Zai7'.
+     'UBJOxhTS0+6B32pWSFH4CidOdWU0ukLiN1BLr0zG5Sdm3GRvcPhIT858DvjXNrVsSLnm/VIdTXS6tTnFsxZTSN3jchaTwps+O/z9'.
+     'tcBVq3hIX0tYqlIiQHdy5CqRHKHXEjAOMgBKjnvyRk4xrQa7OiGt1K5biYZL8SoVEpjOqkFsONtJCNwASeCQrn7aNUKnQYtLp7EC'.
+     'EylmLHQltptPZKQOBo1FzH//2Q==' ; 
+
+        //==========================================================
+        // d4-small.jpg
+        //==========================================================
+        $this->digits['4'][0]= 643 ;
+        $this->digits['4'][1]=
+     '/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+     'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+     'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AEgMBIgACEQEDEQH/xAAYAAADAQEAAAAAAAAAAAAAAAAABAYHAv/EAC0QAAIBAwQA'.
+     'BAMJAAAAAAAAAAECAwQFEQAGEiETFDFBUmGBByIjUVNxobHR/8QAFgEBAQEAAAAAAAAAAAAAAAAAAAIB/8QAGBEBAAMBAAAAAAAA'.
+     'AAAAAAAAAAERIVH/2gAMAwEAAhEDEQA/ANjM00Nxmt1xiWW31CZp5uJwoAAaOQ/n7qfcZHqO5my3q5XX7R6ijiqnNut9u4NyJ4yv'.
+     'JJyjYr8Xhrn5g599J7x3ulBNU7Zo7dXXXcLQ8kURYi4epYtkALjOePv1nUvbLvV7P3BZm3DR3eh88Kp7pVzBZI6iUhGWRRGWwE44'.
+     'HX3V+uiL1uHgt+vL/H+aNJQ3CSeCOaFqSaJ1DJKs/TqRkMOvQjvRorHE4pRDLNWLGlRHGUeYIORXs9e5B7OP31E0fmdyb/t0DJ4Q'.
+     '27bfx3YZzPUIoAAz7IpOD6cuxq0uNumqLfVNDOqXBoZEjnZcqhIPXH4c46+WkdoWOltu3IDDLLLVVR83UVcuPEmmcZZ2/rHoAANG'.
+     'GI7KIY1ijoLeEQBVCwIoAHpgY6Hy0aZe7mJ2jeHLKcEhusj6aNKgzr//2Q==' ; 
+
+        //==========================================================
+        // d7-small.jpg
+        //==========================================================
+        $this->digits['7'][0]= 658 ;
+        $this->digits['7'][1]=
+     '/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+     'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+     'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AEgMBIgACEQEDEQH/xAAZAAACAwEAAAAAAAAAAAAAAAAABgEFBwT/xAAuEAABAwIE'.
+     'BAQGAwAAAAAAAAABAgMEBREABiExEhMiQSMyUXEHFBclVJFhk9L/xAAXAQADAQAAAAAAAAAAAAAAAAAAAQID/8QAGREBAQEAAwAA'.
+     'AAAAAAAAAAAAAAEREiFR/9oADAMBAAIRAxEAPwDXq9mCjZeQ05VZ5ZST4bfEpa3VdglCbqUe+g9MZ5Uq7V8415WXoMSdQ6etgSps'.
+     '19wpkCMDZKUpv0FZvbi1NzpYasMDLDUbMVXrtQdbeeU23xLWkj5RlLYK0J7anW9gbAjCzkOtsVSUJUdtc6dVZK51UeaFm4LKbhpC'.
+     'l7EhIFkDW974GbRI2XorUVls1OTdKAOqUpR0Hc3198GITQ6k+hLwrEpoODiDenRfW23bBicg78JXxPpD0mgVOW5PAivNNpahsPW5'.
+     '8xxQaSVkboQnhsnYm5OHqDGp1IpsalMKjMsMIC3+XZKbJFth62/QOEfMOZqZXp9JcKZTcGmTky3meSi7xQklI81vMR+sXIz/AEgp'.
+     'Q0qPNu6ea8Q2jqtbp8+2w9h/OKORc/cpHjt1dDSHOtLZ4ekHW23bBjj+o9H/AB539aP94MG0+L//2Q==' ; 
+
+        //==========================================================
+        // d3-small.jpg
+        //==========================================================
+        $this->digits['3'][0]= 662 ;
+        $this->digits['3'][1]=
+     '/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+     'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+     'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AEgMBIgACEQEDEQH/xAAZAAACAwEAAAAAAAAAAAAAAAAABAUGBwL/xAArEAABBAED'.
+     'AwMDBQEAAAAAAAABAgMEBREABhIhMUEiMmETFZEHFkJDUdH/xAAWAQEBAQAAAAAAAAAAAAAAAAABAAL/xAAYEQEBAQEBAAAAAAAA'.
+     'AAAAAAAAEQExQf/aAAwDAQACEQMRAD8A0vclruBdk3VVLLUNssGRJsZSCtqOjlgJAHvcOD6c4HnOdIbcttw1W5P29cFEhuawqTXS'.
+     'VsJjnCMBxKkJJx7goAde+ceJfdNxU0UNlyymyXHi6kxWUNl1S3EnkAEIHX2nv86qtTuZr9Q9+1VhRsOoYpYcgSVyAE/TdewkJxnK'.
+     'sBCjkdPGpnOtFMd3PqsXgfOAgD8Y0aX+11H9rDDjn8lr9yj5J+dGqsqxaw6Cc9cQZU4Sp7zTJsIrKlcUEKwhSin1JABI45GUjqOu'.
+     'lbOvjbc3Ts9ynjGCy445UuFLYRzbWgrT6fhSCQSMDke+pew2zYVly/d7YchNqkMJZnQpgV9J8IzwWFJyUrAJHYgjvpLbu37G5nR7'.
+     'vck5C3YRKYEOEVJZj8kjKypXqWvirjk9h+dB9i4faa89TDZUfKlIyT8k+To10a6KTkpcJ/0vL/7o0TS//9k=' ; 
+    }
+}
+
+class AntiSpam {
+
+    private $iNumber='';
+
+    function __construct($aNumber='') {
+        $this->iNumber = $aNumber;
+    }
+
+    function Rand($aLen) {
+        $d='';
+        for($i=0; $i < $aLen; ++$i) {
+            $d .= rand(1,9);
+        }
+        $this->iNumber = $d;
+        return $d;
+    }
+
+    function Stroke() {
+
+        $n=strlen($this->iNumber);
+        for($i=0; $i < $n; ++$i ) {
+            if( !is_numeric($this->iNumber[$i]) || $this->iNumber[$i]==0 ) {
+                return false;
+            }
+        }
+
+        $dd = new HandDigits();
+        $n = strlen($this->iNumber);
+        $img = @imagecreatetruecolor($n*$dd->iWidth, $dd->iHeight);
+        if( $img < 1 ) {
+            return false;
+        }
+        $start=0;
+        for($i=0; $i < $n; ++$i ) {
+            $size = $dd->digits[$this->iNumber[$i]][0];
+            $dimg = imagecreatefromstring(base64_decode($dd->digits[$this->iNumber[$i]][1]));
+            imagecopy($img,$dimg,$start,0,0,0,imagesx($dimg), $dd->iHeight);
+            $start += imagesx($dimg);
+        }
+        $resimg = @imagecreatetruecolor($start+4, $dd->iHeight+4);
+        if( $resimg < 1 ) {
+            return false;
+        }
+        imagecopy($resimg,$img,2,2,0,0,$start, $dd->iHeight);
+        header("Content-type: image/jpeg");
+        imagejpeg($resimg);
+        return true;
+    }
+}
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_antispam.php b/web/classes/jpgraph/jpgraph_antispam.php
new file mode 100755
index 0000000000000000000000000000000000000000..7998df28f637d19f118f75b64f29a8ff8132518d
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_antispam.php
@@ -0,0 +1,615 @@
+<?php
+//=======================================================================
+// File:        JPGRAPH_ANTISPAM.PHP
+// Description: Genarate anti-spam challenge
+// Created:     2004-10-07
+// Ver:         $Id: jpgraph_antispam.php 1106 2009-02-22 20:16:35Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+class HandDigits {
+    public $chars = array();
+    public $iHeight=30, $iWidth=30;
+
+    function __construct() {
+
+        //==========================================================
+        // lj-small.jpg
+        //==========================================================
+        $this->chars['j'][0]= 658 ;
+        $this->chars['j'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABUDASIAAhEBAxEB/8QAGAAAAwEBAAAAAAAAAAAAAAAAAAUGBAf/xAAsEAACAQMDAwMBCQAAAAAAAAAB'.
+'AgMEBREAEjEGIUEUUXGBBxMVIiNSYWKC/8QAFgEBAQEAAAAAAAAAAAAAAAAAAwEC/8QAGhEAAwADAQAAAAAAAAAAAAAAAAECERIh'.
+'Mv/aAAwDAQACEQMRAD8A6veK2st8zRWSyV1dUBfvHaGVI4hknsS7AFv4AyM57ayWbqeS+11xtT2etttwo4YqhEqnQs5bcAfyk4AZ'.
+'SOeD441TKRTyingUBG4/ah8j684+dSFzh/BvtaslejMUu9DPQTDnLx4lQ/ONw1TGBm0jdRWqguEMghEisWilgDmNs4Ze+MEEEH40'.
+'aUVFTa7JeLjRXu4GjhmnNbSfqFQVlA3rkckOjH/Q99Glmkl0C/Q06pvsvT9vttXHDF6T1KrWbs5gRgQJM+FDlQxPhjpF1XcVq+qe'.
+'jEoKiOecXBqh2TDDYIXLKuP6549xk8auI6aJqV45oknWdNswkAIkGMYIxjGO2NR1F0LZY5qkWqkS1xrM0M8lMSJpY+TGrnJiQ577'.
+'cEgeNHhi7D3qC3UN69M8tIakRhgrh9o748+eNGtcCiKjjpkQKlMTEg3ZwoxtHHtgfTRpYXArvp//2Q==' ; 
+
+        //==========================================================
+        // lf-small.jpg
+        //==========================================================
+        $this->chars['f'][0]= 633 ;
+        $this->chars['f'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABcDASIAAhEBAxEB/8QAGQAAAgMBAAAAAAAAAAAAAAAAAAQFBgcC/8QAKxAAAgEDAwMCBQUAAAAAAAAA'.
+'AQIDBBEhAAUGEjFBEyIHFFFhoRUzYnGS/8QAFQEBAQAAAAAAAAAAAAAAAAAAAQP/xAAaEQACAwEBAAAAAAAAAAAAAAAAAQIRMRIh'.
+'/9oADAMBAAIRAxEAPwDcnmLoIkiSYsouC3tA++O2lU9WkqVjJ+YdhZLsQI/4/YfQm50kZP0vbmaCSU0SRNIH6sghb9INs3t38dvp'.
+'akUuz8x5DwdN5peS1jV1dSipSiVUigIcdQjQ26lIB/c6r3F86SZpE/zCFJaqsihQNhRgdj3Jyfxo0jDSbXHt9Oph9RAoV3qJGltY'.
+'HDOxyb/nRpV0D3RXle21m48XraOk3IUSemUaV4g4Zc9ShcDtgff+tQfwvjq34Dtku7buamFqeJKemCCMxKFsEJU+/FrX8d76sEHG'.
+'aNItzr4usVNdG3S0rmRYAVwEUmyjyQLZ11x7aF4zs9DQOyzml29I2cLa/pixIHi99DFCtU9dFuLIaijo9qiYPmR2mZmB9thgAHOD'.
+'4+mjUrURyrUNMZFEkkIOFuFAbsP9d/OjVIQ6Vh4tP//Z' ; 
+
+        //==========================================================
+        // lb-small.jpg
+        //==========================================================
+        $this->chars['b'][0]= 645 ;
+        $this->chars['b'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABUDASIAAhEBAxEB/8QAGQAAAgMBAAAAAAAAAAAAAAAAAAYCAwUH/8QAKxAAAQMDAwMDAwUAAAAAAAAA'.
+'AQIDBAAFEQYSIRMxUSJBYQcVI2JxgqHw/8QAFQEBAQAAAAAAAAAAAAAAAAAAAQL/xAAYEQEBAQEBAAAAAAAAAAAAAAAAATERYf/a'.
+'AAwDAQACEQMRAD8A6H95mxNYwLXcX+pCuilSLXJ6YSplaUELjqxwe4IJ5PIPamJ2V0bPcS7+NxCX1cHggAnIP+xSd9RyzHh2m7FQ'.
+'Q1CvMNQWTjCt+HFD+PB/Y1fI1PL1HFFt0zaGblFdJQ9cJjpZiqPJUlBAKnPcEpGB5NNRKdrOl1NlgiQol4R2w4Sc5VtGf7opZteo'.
+'LhdorjUSM5FnQnlR50NeHQysYxtVxlJHIPgjtRRD3xkaghs6juumdHz4+Y7RVPnt59K2mk7W+fcKWsZ7djTXMkW+xMP3GRJjwIEN'.
+'HTG/CWx5wPY8AADx2NYk3SL9wukvUjGobnBkORksIbjdMANozgEqSo8qJPGO/wAVO36IsjUmBIfZfuM7epZk3F9UhSSk5O0K9Kcq'.
+'8AcU3UzFuhUSBFud6nRXoz96mqmJZWg7m2dqUNhWBwdqQSP1UU5c/FFCn//Z' ; 
+
+        //==========================================================
+        // d6-small.jpg
+        //==========================================================
+        $this->chars['6'][0]= 645 ;
+        $this->chars['6'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AEgMBIgACEQEDEQH/xAAZAAEBAAMBAAAAAAAAAAAAAAAABgMEBwX/xAAvEAABAwMC'.
+'BAQEBwAAAAAAAAABAgMEAAURBiESIjFRBxMUQRUWMmFTYnGRkrHC/8QAFgEBAQEAAAAAAAAAAAAAAAAAAAEC/8QAFhEBAQEAAAAA'.
+'AAAAAAAAAAAAAAER/9oADAMBAAIRAxEAPwDslwiR3oDku8ONttsAvDiVyMcO/ET7ke5/aoOz6k1Vr5htNjW7a7M1yO3NTQU9JUDu'.
+'GgrlSn8xyf6p4gXaHJvNps9/mKZtSkGdMjRwpfqAFBLLACRlZUrJONsI2717No1lbZ10kx7XGnRpKWQ/6GVGMfzEJ5VFIVtsOH6e'.
+'wyKVhYsia0y22pLThSkJK1uniVgdThOM0ol+StIUhpopIyCFq3H8aUVCwnG3PGe4Rp6fLXJtMdyM0ojcIWvIz3HFnAPfrWTXb6GN'.
+'WaLXDwZjVz8pKEfhuIUFg/bAz9sVJ61nt61mxJFslLtq7e5yPqiBT4UDklKw4MDpt+u+9bFiu9riXNu83R+fcr6tohuQ5HQhmK37'.
+'paaC8DruScmg6X8KkjZEhbaB9KEyFYSOw26Uqd+e7Qerl5z74DY/1SomP//Z' ; 
+
+        //==========================================================
+        // lx-small.jpg
+        //==========================================================
+        $this->chars['x'][0]= 650 ;
+        $this->chars['x'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABMDASIAAhEBAxEB/8QAGAAAAwEBAAAAAAAAAAAAAAAAAAUHBgj/xAApEAABAwMDAwQCAwAAAAAAAAAB'.
+'AgMEBQYRACFBBxIxFCJRgRNxkcHw/8QAFQEBAQAAAAAAAAAAAAAAAAAAAAH/xAAWEQEBAQAAAAAAAAAAAAAAAAAAEQH/2gAMAwEA'.
+'AhEDEQA/AH9t3pKvO14UykVARa/HfAlxlDKXR24V2p3z7RlPwdtMep91uWdRGHWELjuTFFtLvcC4SNznnH+21O7ttiodOq1BvC0E'.
+'p9I0lSX2kgqCSklK+5PKCMAng6zV2XRO6u3lSIURtbDRShltlZHa0tW7q/0MeTwnjxq1Jiw2xc9xTLbhSVU5iaXUFfqFFILgJOCd'.
+'9Gt3SXabR6REpkL8yo0RpLCFNx1qBCRjOQMHxo0pEr6o3um2LVYpMEpTVqg25lHn08dfcB9kEgfZ1LIFDuawqZRb7aQlLTzqglsg'.
+'9wQdveOEqBIB425xqhQuk8qo9UKlPrlRblw2ZBeCSVKW6CcoSrI2AGOT41SKzT4dYtmdS5bIXDZhNoWgbZJ94x8AYT/GkM03oNUc'.
+'uKgwqtTZDTMOU0FttqRkoHggnPkEEHRrkJ6t1SlSHYUOc6zHaWrsbQrATk5/vRqK/9k=' ; 
+
+        //==========================================================
+        // d2-small.jpg
+        //==========================================================
+        $this->chars['2'][0]= 606 ;
+        $this->chars['2'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AEQMBIgACEQEDEQH/xAAYAAEBAQEBAAAAAAAAAAAAAAAFAAQHAv/EACsQAAEDBAEC'.
+'BAYDAAAAAAAAAAIBAwQABQYRIRIxQVFhcQcTFSJSU5GU0f/EABcBAAMBAAAAAAAAAAAAAAAAAAECAwT/xAAZEQACAwEAAAAAAAAA'.
+'AAAAAAAAARESUUH/2gAMAwEAAhEDEQA/AOqXm/Q8dxmOL4PPSnCSNFixx6nXnkXgRT3Te17JWbGsveueSyLZdbPItNxOKLzTLjou'.
+'gYCSoSoY8ISKSbFeUrzkdlnTL1YshskiErkQnFEZaF8kkdBBVdjyi6RNL5+9F486eS/ECVkcBtDt1vZcho5viS8ZCp9C9tAIAm/F'.
+'VoPRU+HRtJ5JVRP1kP0PfwP+1VKrHBMliXG4Nw8VgE4xGkuqk2S1wTUNEVdIvgpL9iL6KtNxY7WOwo9tt0RCitj0sR2uCbFPPzH1'.
+'7+6rRuSRcljMBMsUy2tky045KOawZk5xtEFBJEROO3hx61kh2rPCIX3MhsyC4QmfTbC6lH8dq5212qwkiG5H6Y/9R2qm+ofxqqsL'.
+'DLZ6f//Z' ; 
+
+        //==========================================================
+        // lm-small.jpg
+        //==========================================================
+        $this->chars['m'][0]= 649 ;
+        $this->chars['m'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABcDASIAAhEBAxEB/8QAGgAAAgMBAQAAAAAAAAAAAAAAAAcDBAUCBv/EAC0QAAICAQMCBAMJAAAAAAAA'.
+'AAECAwQRAAUSBiETMVFhB2KhFSIyQVJxgZHB/8QAFgEBAQEAAAAAAAAAAAAAAAAAAgED/8QAGREBAQEAAwAAAAAAAAAAAAAAAQAR'.
+'EiEx/9oADAMBAAIRAxEAPwB0MI2lIdgI0Cly3kFXLEn2zx1FDdp7rbpbjUtRWKio3hyxOGQllJzkegX66rQ2qW87Zuk9S5FNVmru'.
+'iywyBhjDKTkeXfSr+GRfYtq2KAO32b1BGxAZu0dyJ2DKPTxY1wPddVszycUq2Golq8jRWbcnJWwCVGMjz+VQP50atxMtm2ZUOY4l'.
+'4qfUnBP0x/Z0amy4jJm10Tt2yddWasFmfaRfdrlG3UcgArnxKzJ+Fu4DqCMkcgNem2DoWav8PLfTm+FPEkuSNTnqueS5bnHIv6CG'.
+'LNjJwM99bm67NB1Ht89KSxNXnr2hNDbiUc47K4KyD2GQMfmMjUnS+7vuIktTqPCaaWCqAMMojPFyw8hyYMQBnAwNJHYGXPTsW9VN'.
+'jg2zf50W9zk524GAEihuz+xbIOD82jW5TkjtRPZkTkJ+4VgDhQfuj/f3OjUxl1f/2Q==' ; 
+
+        //==========================================================
+        // lt-small.jpg
+        //==========================================================
+        $this->chars['t'][0]= 648 ;
+        $this->chars['t'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABcDASIAAhEBAxEB/8QAGQAAAgMBAAAAAAAAAAAAAAAAAAQDBQYH/8QAJxAAAQMDAgYDAQEAAAAAAAAA'.
+'AQIDBAUGEQASEyExQVFhIjJxFSP/xAAWAQEBAQAAAAAAAAAAAAAAAAABAAP/xAAZEQADAQEBAAAAAAAAAAAAAAAAAREhMUH/2gAM'.
+'AwEAAhEDEQA/AO4BLEiEy7uG4IGxxs5IOOx76wd2XYidSp1HoD70240gcNNPbDyI6wQQpaz8E9MczkdhqtbsKYLieDk6WLKmZmmL'.
+'Hk7AHVkbkLI+RQc7uRxgkfr1tx2rGu6VbToLVKkhU+kbugGf9WfaknCk5ycaX0zmaa+3JkqvW/CmzojsB9xoF6OoFK0r6HOcEDI0'.
+'aefTuKX5ScMdC14HYq8n12zo1DEUcKTGg1Z+hyBwoPBVIiA/VQyOIgedhUCB4WMfXSV3UufVLcTUIqVf26K6mXDbPVRRzKT54iMg'.
+'+zjtq6mtsyJjclxpKlUhSXEbkgkqWnBx4+J5e/zU0pZemPvJJQzEPDfQOrwwFY9AZ5eeYPLV6FwhoFYZuigxpkJeIjqAeIoAk9wA'.
+'D46EnuD+6Nc1smDNrTlRkxqtMo1vzKhIdYgU9YDqVpISrLhHxSSd21I0aYyqP//Z' ; 
+
+        //==========================================================
+        // li-small.jpg
+        //==========================================================
+        $this->chars['i'][0]= 639 ;
+        $this->chars['i'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABYDASIAAhEBAxEB/8QAFwABAQEBAAAAAAAAAAAAAAAABwAGBP/EACcQAAEEAQMEAgIDAAAAAAAAAAEC'.
+'AwQRBQAGEiExQVEHExSBFWFx/8QAFgEBAQEAAAAAAAAAAAAAAAAAAgMB/8QAGBEBAQEBAQAAAAAAAAAAAAAAAAECMRH/2gAMAwEA'.
+'AhEDEQA/AE7c+5M9BeRG29t1WUfKFFYW+GvrI7WD3B9g140YD5T36rcErDjbUR6dCBdejsKUpxITXI2FUrooCh70yvxzHyIlMvuK'.
+'eVSH7IKEpJoKqu/ahddLryR/aMiO187bsmrWShhp1AZS2XHHrWhNJrzdf7f7GiVcHk3sptmHkJcJ2DIftS2FrKlJPXudWuLGYeQp'.
+'t2fmEIckqIZaaKuSGG0lQ4gduRoFRHQ9AOgs2lOJbk9aSUlpjGvAWeSVH2VKq/2dFPw3IjyJe8s281ct3I9UoHJXGiQkD2STrSZ7'.
+'Yf8AOl7JTdw5eOCz0jw3+LbYCfA9nz71msb8KMxoTGTw+5srjsipAdDqFBQBIuiOl6KrdYyJMyTCshlw2G3Fr/HiNqNNAqJJUoGl'.
+'KND+h47km1bZwsvCbYYjycxIyK1qDv2yEi0hQviK8atKDcy9j//Z' ;
+
+
+        //==========================================================
+        // lp-small.jpg
+        //==========================================================
+        $this->chars['p'][0]= 700 ;
+        $this->chars['p'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABcDASIAAhEBAxEB/8QAGgAAAQUBAAAAAAAAAAAAAAAAAAECBAUGB//EAC8QAAEDAwMCBAMJAAAAAAAA'.
+'AAECAwQFESEABhIiMRMVUWEHFEEWIzIzcYGRocH/xAAWAQEBAQAAAAAAAAAAAAAAAAADAgH/xAAcEQACAgIDAAAAAAAAAAAAAAAA'.
+'AQIxAxESIUH/2gAMAwEAAhEDEQA/AOh703xG21DMeOyqoVNDjSzERiwU6Ep5qtZNycA97HTF13d33KWtmlt9xwkLl1NkXVxIuQgK'.
+'wLj+hqBvel0qmbR8GnR22nJNZiLeeKr8nDIT1OLJucX+uPbWom7iocRpafOac5MX1ALltp/Cbi+cJH++utdh+WVNL3PNdNYpdWgx'.
+'Y0qmLZSrwJJcQoOJ5XKlJFu4HbJOjVbt+V5nu7eopNRivqcdhK+bFnWwA1Y2AOcgjvj9dGlxy0g5y0xd+hNXoG24C4obizq3HZUh'.
+'YHqtRHD06bG/8a0MbbG1mqekxaBSGmgkrcdcitlLfrckZIz7DUatbeFak0tyRLUwzT5vmiGm0cufEkFBJItfkD+59tKmiO12atFa'.
+'eQukO3ejUxgENqTcfnE5WbkHiOnJ76N2IqI1DibabptS+zkZhtp90F2Y0S026EkAFK/qL46cXv65NVZDfxHmVCK4DE2/RX/lRFbA'.
+'C5LwAyq2EtpHZI7mxPYDRqoctdESimz/2Q==' ; 
+
+        //==========================================================
+        // le-small.jpg
+        //==========================================================
+        $this->chars['e'][0]= 700 ;
+        $this->chars['e'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABgDASIAAhEBAxEB/8QAGQAAAgMBAAAAAAAAAAAAAAAAAAYEBQcB/8QAKhAAAQMCBAUEAwEAAAAAAAAA'.
+'AgEDBAURAAYSIQciMTJBE0JRYRQVFoH/xAAXAQEBAQEAAAAAAAAAAAAAAAAAAgED/8QAGREAAwEBAQAAAAAAAAAAAAAAAAERAjFB'.
+'/9oADAMBAAIRAxEAPwDTszvhEYCoS80BTm2bCjQRwdAzVe2yopkpJtpRUVfjEIc4V2oMerByg5Ji30oMyS3GeMunK0upfnu09MdJ'.
+'p2scTmWnnGfx6HThktgLfKj7xEOqyr7QBbL41LhBzpxbcOru0LKDLdSnOHoaltNqSC4qWL0x9xbJYum69caczSaHmGmTmpDUYn4l'.
+'UiqjkynzAVtwV23Ud+X4Ibpa2DCPkjhfUaRO/p8yzpb+YHhUmhbev6ZEll1lvqK3jt2XrbBgp6HVwsK3THpfEubGSoOUyFMpbJmL'.
+'Deh6SgOGKti57EuY6l62JMWdJy7k3hg1LkOozEbVm7suQSkTiKtkEfP1pH664Za/QItccgI4bseTHdNxiXHLQ8yVl7V32XyioqL5'.
+'TGc1ng6eYs0idczXUZscBBABWgEhEtfKNuUezwPnBhEuj8X2M21z9BR6NUX211Kk/UKKAjuhkPhL7XVf8vtgw7UPJlEyrDWFSYLb'.
+'LBNF6qrzG6t0spEu6+fpL7YMXhUndp//2Q==' ; 
+
+        //==========================================================
+        // la-small.jpg
+        //==========================================================
+        $this->chars['a'][0]= 730 ;
+        $this->chars['a'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABoDASIAAhEBAxEB/8QAGAABAAMBAAAAAAAAAAAAAAAABgMEBwX/xAAvEAABAwIFAQcCBwAAAAAAAAAB'.
+'AgMEBREAEiExQQYHFBUiUXGBE2EyQkNSgpHh/8QAFwEBAQEBAAAAAAAAAAAAAAAAAAMBAv/EABkRAAMBAQEAAAAAAAAAAAAAAAAB'.
+'IQIRMf/aAAwDAQACEQMRAD8AfdQ1pxjqZMSn0mRUZRYDaklJCE3OawO2ttTxY4hl07qFMVs1Ku02kpPnRGhsAqz8W9T9wDjozq6o'.
+'Q1lDrcZLGVcmUoZg0obpufxK3Ftt9ccqB1GgBcmLSqtVEqOZcr6ARm/kbXHt7DEtc7WTJKTJqEWvRKfLqL9QplSjuPtGVYOJKBrm'.
+'t+U+n94WGStZzNypmRWqckUKTbixy6jAfxPxHtCgKqFNlU5huK6pLMndSlegG4J45N8aKmTMKQRBsCNMzwB+RbHWHGEAZlPZX2hx'.
+'qZIC34ygZoYUbB50JSkFXFhZR9BrpheR4fIbQ6gvurJ7q02bIQTuAOAN8x40HAxRr3TrNRpBmSHVt1KMlTyJTCsqkKAPlSf28W+c'.
+'UGaD1c9HSR1HFUh9tJU45EBcAtcC9+P9wqbg8IAto9o81yputrVGpiUkgHKkqUTZI32+cKm1z1tIUgPBBAKQ4UBQH3uL3xmXSXep'.
+'HVDtXStE5K5jlPU7PF3Q41+okJFkjgC+3OuNSYiSzHaLtRcW4UDMpLYSCbakDW3thhum5p//2Q==' ;
+
+        //==========================================================
+        // d9-small.jpg
+        //==========================================================
+        $this->chars['9'][0]= 680 ;
+        $this->chars['9'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AEgMBIgACEQEDEQH/xAAZAAACAwEAAAAAAAAAAAAAAAAABAUGBwP/xAArEAABAwMD'.
+'AgYBBQAAAAAAAAABAgMEBQYRABIhE1EUIjEzQUIHMlJhcdH/xAAWAQEBAQAAAAAAAAAAAAAAAAACAQD/xAAYEQEAAwEAAAAAAAAA'.
+'AAAAAAAAAREhQf/aAAwDAQACEQMRAD8AkK7brF6X7XpMeGoKhFMLEeT4ZUheEhanF4OcZ2pTgDykk92bZpdCsi7aezLjxkIPUZiV'.
+'RSCy8hah7EkZ27yM7V+iscal5bE22Lon1qNDmSKROd8Sl+Ix1lMOlIS4HGgQpbStoUCnlJz8HmsXtW3Lst2rmBAelLMRRekOwnYz'.
+'Edls9QKKnOVLyk7UgcbzzrdBthqEJJwZbAI4x1U/7o1TaFa9lG36aXaZTy54VrcXUgrzsGdx+T30aNydweqVw1GS87T6Lb86Q4ha'.
+'my/IAYjZBx+snKk99oOQMf1AViE65SY348hzFy6hPKnqtKz7DC1lbqyPrvJKUJ7H+M6Wrt3InP7o1brFNp4bCDGhxGAsqz69VSiQ'.
+'ORwBxrrQ7itm1ac7Hp0WoGTIc3PSn0pccdcP2WorycfA1RaRHjxosZqOyhtDTSAhCf2gDAGjVHTd9sKSCumynFEZK1tIJUe58/ro'.
+'1V1//9k=' ; 
+
+        //==========================================================
+        // d5-small.jpg
+        //==========================================================
+        $this->chars['5'][0]= 632 ;
+        $this->chars['5'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AEgMBIgACEQEDEQH/xAAZAAACAwEAAAAAAAAAAAAAAAAABgIFBwT/xAAoEAABAwME'.
+'AQQCAwAAAAAAAAABAgMEBQYRABIhIkEUMVFhBxNCgaH/xAAVAQEBAAAAAAAAAAAAAAAAAAAAAv/EABcRAQEBAQAAAAAAAAAAAAAA'.
+'AAABEUH/2gAMAwEAAhEDEQA/ANGvW4YVOeiRX5b4mv5Sin05IdlupPKdo/j2SO3+6TbPNQvOsTVz33KRT4csR3YUF7Dsh5OSFvug'.
+'kqG4FPBxnjxpvvi4KZb1pTpU+QwxUi2Y7ZIAefUk5ATxnB9/gbtL/wCH1UpuhPUlZlMVaQ0mS8zJjqZOPfc2TwpIUonI9tw40R1r'.
+'WNGq/wBdJR1XT3lqHBUnGCfkfWjRWs1ve249erQqQYjOtN1FqPUpCXQ4WIzQSsJwT0UpRwQPG0nzqyuNHobjsl9kBuWqoOoXtT1/'.
+'WppZcA8lKRj64HxqU+3KpAr6plElRVKef3S4E0K9O8pLXVzKcqSsJAB9wSAca6bSoNXeuA1+5pEV+SGFNU1iKVFqI0Vdx2AJUeoz'.
+'8DGlTDwG3CAf3q/pI0ah6MDhLz6U+EpXwPoaNMU//9k=' ; 
+
+        //==========================================================
+        // d1-small.jpg
+        //==========================================================
+        $this->chars['1'][0]= 646 ;
+        $this->chars['1'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AEwMBIgACEQEDEQH/xAAZAAADAAMAAAAAAAAAAAAAAAAABQYCBAf/xAApEAACAQMD'.
+'AwQBBQAAAAAAAAABAgMEBREABiESMUEHEyJRkSNCYXGB/8QAFgEBAQEAAAAAAAAAAAAAAAAAAAEC/8QAFxEBAQEBAAAAAAAAAAAA'.
+'AAAAAAEREv/aAAwDAQACEQMRAD8A6jdd4WLbstILnc4Uq0VoWpkJknb6IjXLHJUePOlez923fcW4r1SxWlqC2UbdKirQif3Xw3yA'.
+'OFAGT09/kO3OmV3a20MFRf6lIYPcpy7yRRAzgxjIy2M8YwcdiBzpX6d22VNvUlTXsFkuwkrKqNSfnK7F8OTzwrAY+l5zoxKskudN'.
+'EgQPUT9PBkWF3DH+1GPxo1mLnRoAqF2VRgGOFmX/AAgY/GjRUP6hVMFv2FuFqUvUGrpDFJMBnpdyF5bsAQew7Hxzp6LZNT0yQ1DI'.
+'wp0QCFBhD0jCsfLZHxbx5xxpTuvb1+v9PV7Ztk9roLPLCjmSSN3mX5ZwqjCgZX7PfWxDQb2in96pv9qq46aTE0bW4x9ceAWAYPwS'.
+'PsYzoixgmheBGjIVcYCnjp/jHjHbRpe1JLn9OnopE/a0ykvjwDx47aNMXqP/2Q==' ; 
+
+        //==========================================================
+        // ll-small.jpg
+        //==========================================================
+        $this->chars['l'][0]= 626 ;
+        $this->chars['l'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABcDASIAAhEBAxEB/8QAGAAAAgMAAAAAAAAAAAAAAAAAAAYEBQf/xAArEAACAQIFAwIGAwAAAAAAAAAB'.
+'AgMEEQAFBhIhFEFREzEHFSIyYcFxgZH/xAAXAQEAAwAAAAAAAAAAAAAAAAACAAED/8QAGhEAAwEAAwAAAAAAAAAAAAAAAAECMREh'.
+'Qf/aAAwDAQACEQMRAD8A15Zfm1VURj1Fp5AqLKv3OARcL4W5Nzx+MLWjdRz5hqXU6TSb6OCr6WghiQbrJ91gOTy1yT5xZ55myZFk'.
+'Gb5ozX6Ondm28XYqpQDwu7jEH4c5S2UaDy4xxrLmlUDWzk8XaQ3O49hbj+RiB85HNg8Ee3aqwIqhDuux7G/HHbvzgxEqaWOvy09R'.
+'O0o3hjdQoUji20g+fY3wYSM6pJ4Ylr7V+Zz5PSaezHTlTRNWzxySSxt6q1MSkH6AOT2Fu3Aw7RfF/T9DEkLUeawuF2mKSgdWQj2/'.
+'q3+fnDZDlqRZzQGaOGcpTOaeR1u8R+ncN3gj94so2jNWHeMNNKzorEX2qp9v3imNPoRE1zpjUtZ09HJmYq5lury0benZeTww23t3'.
+'Ivgw+T0yRRyyxIqNfkLcA8jt7YMKcBWn/9k=' ;
+
+
+        //==========================================================
+        // ls-small.jpg
+        //==========================================================
+        $this->chars['s'][0]= 701 ;
+        $this->chars['s'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABQDASIAAhEBAxEB/8QAGgAAAgMBAQAAAAAAAAAAAAAAAAMCBAUGB//EACwQAAEEAQIFAgUFAAAAAAAA'.
+'AAECAwQFEQAGEhMUITEiYQcjQVFxFRZCUoH/xAAWAQEBAQAAAAAAAAAAAAAAAAADAgH/xAAZEQADAQEBAAAAAAAAAAAAAAAAAQIR'.
+'EiH/2gAMAwEAAhEDEQA/APWZMhmFXSJU+SGmWFiQtAWMJQAnJUr8Z+w/OuQk71uZnMsqnbjy9s8st9UMCQ6kZJdZaIHEkZ/JHceN'.
+'N3HtizuY1JLrG48yLBSC9UTFKQiY4nACir+wAOOMEe2rm2bTbzlqtE1MyBuZAPybpw85KSfDRJ4Cg+Pl/wC61hJeGjV31VuuKqwr'.
+'LGU+whZZK+Rw+oYJAyj3GjS4dZFpZVkqPLktdfMXNcaU2kBC1BIITkdx6c599GlnvPAa3TL2vNvU76n0063acr3YSLCEjpUpUQtW'.
+'Dhf14SMEnOc57aZ8Tegm7dbrEQGZt1PeTDgc1PEW3FeXAvyAkZVkeMDOm2G3f3O7Cl/qEuqkQg4lp6CRxraWfUlRUD24kZA741Ko'.
+'2k1HvlT3ri2sLOCgtsyJz6XEtBwZPAgJAGQMHUNPWKqWItsqh0UCFVyLeKhyLHQ2TMdHNVj+RKlAnJyfto1FW2ahgjrq6LYTFjjf'.
+'lymUOLdWfJyoHA+gA7AAAaNPE3ysJdLT/9k=' ; 
+
+        //==========================================================
+        // lh-small.jpg
+        //==========================================================
+        $this->chars['h'][0]= 677 ;
+        $this->chars['h'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABUDASIAAhEBAxEB/8QAGgAAAQUBAAAAAAAAAAAAAAAAAAIDBAUGB//EACwQAAIBAwMCBQIHAAAAAAAA'.
+'AAECAwQFEQAGEiExExQiQVEVggcyU2GRocH/xAAXAQADAQAAAAAAAAAAAAAAAAAAAwQB/8QAGhEBAQEAAwEAAAAAAAAAAAAAAQAC'.
+'AyEyMf/aAAwDAQACEQMRAD8A6DZb95q9bmpK6ieOCzNHJTxmE+NMhQ5fr1fLq3Ejvkak2e7ipiFsqb3R0m4qkPPJRiRXenU9VjKE'.
+'5JVcA9R7nWc3/BUbfoKTdO3VRXhpjbZ2D8Rwk6RyZH6chB+46m7i2hDYtgA2ePlV2VkuKysoLzzRnlIScZJZeeevvjtrX7LK2rp7'.
+'tTwwJ9WjhILDrTKnIdMEDl2+P80aVdJZb1QW+vgqENLPH4sBCDLIwUgnOf4GjVvDnLgUk79T81voqjb8NnuUx8pVRCiEaYUSuynl'.
+'jHU9mOfnOoOx6hqz8PrbNdfEkMUXg1LSM3rKOUywJ7YAJ1ZTWmSpvdvlaVTDSUzJAhH5ZJBgv0x2RSAPlz21WXqoet3ba9nuW8n4'.
+'Jr6qTPqnUNxSM/f6mPvxA9zqJnExTbR+h0nkhVu1uE8j0UBRQ9PGxBKFjnkAScdsDp10a0lc7z0tI7Y5YYN+5GAf7GjVXF4Icj3f'.
+'/9k=' ; 
+
+
+        //==========================================================
+        // ld-small.jpg
+        //==========================================================
+        $this->chars['d'][0]= 681 ;
+        $this->chars['d'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABcDASIAAhEBAxEB/8QAGAAAAwEBAAAAAAAAAAAAAAAAAAQFBgH/xAAsEAABAwMEAAQFBQAAAAAAAAAB'.
+'AgMEBQYRABIhMQcTI0EUMlFhkRgicaGx/8QAFgEBAQEAAAAAAAAAAAAAAAAAAgEA/8QAGBEBAQEBAQAAAAAAAAAAAAAAAAECETH/'.
+'2gAMAwEAAhEDEQA/ALUhp6h3W/X63UlypbhCY0WMjLqGzwDtPCfv/WtealNpVInuVBBqCogcdbU36YUkAkJWVHG8YPXBxxzxqPcN'.
+'YtWyWnIlUeW05VEOAvrCnnSkftK1H5lKJPHsMDoDUWq+KdrSbIqsalVsImiEtLUZ2MU71bcYJWkhZ/36ayLHhi/IXZVOmzKqp5uU'.
+'688hTyjuGVEFJKvoQesD86NL2jGZp1EoLDSmk+ZAQ8d7oPzp3YGesFWMfxo1YGvSzLsT9QExVX8phTlMaFOExAJIBGQjJwCcL+/e'.
+'rd+W7GuO0Kw05CQ6+ww69Gfdb2kFIKk7DgEkjgnr86rXRa9HuyP8LV4SH0sIBbWFFDiFEgDaocgdkjo8ccay0qw7ut5nyrcviQqC'.
+'slsRKo0HwlODkBRzxj2AGoXTtpzIdQ8MbffUChz4NCPRaClAo9Mn6c7T3o13wytmo0K05VIqkiPJbizFiMWs4CTgnIIHOST796NL'.
+'Ia1JX//Z' ;
+
+        //==========================================================
+        // d8-small.jpg
+        //==========================================================
+        $this->chars['8'][0]= 694 ;
+        $this->chars['8'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AFQMBIgACEQEDEQH/xAAYAAADAQEAAAAAAAAAAAAAAAAABgcEBf/EACsQAAEDAwMD'.
+'AwMFAAAAAAAAAAECAwQFBhEAEiEUMVEHE0EVYYEiIzJCsf/EABYBAQEBAAAAAAAAAAAAAAAAAAIAAf/EABcRAQEBAQAAAAAAAAAA'.
+'AAAAAAABERL/2gAMAwEAAhEDEQA/AKL6gVVUa0i1T5QjvTprUJMlxW4R9zgQXe/AH+kaWrntqlWjaq7gpcmotXAw82ht9yY4tch8'.
+'uAFC0k7VBXPGMY51ruiaue+bThIj+7NbWqS+7HDxajFf6AlB/k44o8ZOABk4xkL0X0tZiojKrlRuGRJjugqldSlKGf6t7BuUQe3J'.
+'44xxxrA1a4KVJipLidri8uLHgqOcfjOPxo0o2hdDvS1CmV2Yl6fS5ioipIQR1CAlKkLKR2UUqAI8g6NRSwuuyHab6s1ufLI/Zai7'.
+'UBJOxhTS0+6B32pWSFH4CidOdWU0ukLiN1BLr0zG5Sdm3GRvcPhIT858DvjXNrVsSLnm/VIdTXS6tTnFsxZTSN3jchaTwps+O/z9'.
+'tcBVq3hIX0tYqlIiQHdy5CqRHKHXEjAOMgBKjnvyRk4xrQa7OiGt1K5biYZL8SoVEpjOqkFsONtJCNwASeCQrn7aNUKnQYtLp7EC'.
+'EylmLHQltptPZKQOBo1FzH//2Q==' ; 
+
+        //==========================================================
+        // lz-small.jpg
+        //==========================================================
+        $this->chars['z'][0]= 690 ;
+        $this->chars['z'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABYDASIAAhEBAxEB/8QAFwABAQEBAAAAAAAAAAAAAAAABgAHA//EACsQAAEDAwQBAwIHAAAAAAAAAAEC'.
+'AwQFESEABhIxBxMiQVFxCCM0UmGRof/EABYBAQEBAAAAAAAAAAAAAAAAAAECAP/EABgRAAMBAQAAAAAAAAAAAAAAAAABEVEC/9oA'.
+'DAMBAAIRAxEAPwBTWfLu1KXXZDbM4uewNvLajlwhaCbBAwDe5uehYd3xm6t6bi3jvulwqc7KgxXZZeYQLNLeF73WRg4HEdgfzrSa'.
+'P45pNEkznITDc9ypLShtyWhJDJyXC2qxJHZvjoZOjyVv1v8AESt6FFS4ijxvTLbawEApSccrYHJf0+OtJMQ2rNXk7GZMufJgJjTH'.
+'Un9M4qzxT7hyCiThIyRnPXWrRvyLElVBUF6vlhl0lwRYCFKcQhAtyWpVhyWTx+w++rUvp4EWjOvbniUOnVatcS43BYDbJSPZyIBw'.
+'ejclIx+3Wa+J63T6DQanuGszI0eZVJJV60p0Jum5GEi6le7l0PjvSjyRsaTvJqI1BqhhR46ksuMrQVJcUSEoUbHNr/7o7C8L7eiz'.
+'4lLlyJk2cEqW+6V+m0AE9ISLnsj5+O9UhsFK92bZZqb9SRu9p2c4A0OCEqDbYAJSlJwAVZv3fBvbFrg/462btlhuS1RG5nL8pYkq'.
+'KrnsKH06I/rVrQKkf//Z' ;
+
+        //==========================================================
+        // d4-small.jpg
+        //==========================================================
+        $this->chars['4'][0]= 643 ;
+        $this->chars['4'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AEgMBIgACEQEDEQH/xAAYAAADAQEAAAAAAAAAAAAAAAAABAYHAv/EAC0QAAIBAwQA'.
+'BAMJAAAAAAAAAAECAwQFEQAGEiETFDFBUmGBByIjUVNxobHR/8QAFgEBAQEAAAAAAAAAAAAAAAAAAAIB/8QAGBEBAAMBAAAAAAAA'.
+'AAAAAAAAAAERIVH/2gAMAwEAAhEDEQA/ANjM00Nxmt1xiWW31CZp5uJwoAAaOQ/n7qfcZHqO5my3q5XX7R6ijiqnNut9u4NyJ4yv'.
+'JJyjYr8Xhrn5g599J7x3ulBNU7Zo7dXXXcLQ8kURYi4epYtkALjOePv1nUvbLvV7P3BZm3DR3eh88Kp7pVzBZI6iUhGWRRGWwE44'.
+'HX3V+uiL1uHgt+vL/H+aNJQ3CSeCOaFqSaJ1DJKs/TqRkMOvQjvRorHE4pRDLNWLGlRHGUeYIORXs9e5B7OP31E0fmdyb/t0DJ4Q'.
+'27bfx3YZzPUIoAAz7IpOD6cuxq0uNumqLfVNDOqXBoZEjnZcqhIPXH4c46+WkdoWOltu3IDDLLLVVR83UVcuPEmmcZZ2/rHoAANG'.
+'GI7KIY1ijoLeEQBVCwIoAHpgY6Hy0aZe7mJ2jeHLKcEhusj6aNKgzr//2Q==' ; 
+
+        //==========================================================
+        // lv-small.jpg
+        //==========================================================
+        $this->chars['v'][0]= 648 ;
+        $this->chars['v'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABQDASIAAhEBAxEB/8QAGQAAAgMBAAAAAAAAAAAAAAAAAAQDBQYH/8QAKBAAAQQBAwMEAgMAAAAAAAAA'.
+'AQIDBBEFAAYhEzFBEhQiYQdRFTKB/8QAFgEBAQEAAAAAAAAAAAAAAAAAAAEC/8QAFxEBAQEBAAAAAAAAAAAAAAAAAAERIf/aAAwD'.
+'AQACEQMRAD8A6Ngt1SZ4yrYgrecgTFsFJA9aGwAUrUaF2D2Avjzq6CIjiBPkB9bwQVIkIYIDae/wq+P9N+dY4SGMf+Txlev7KBmY'.
+'PoadKRy4zxSgRxaTwO/x09u7KPYnasmHjlsyFZZXt4K23ezjvBpNGgLUrvXfVZyLLbWambiwEbKvvxYAkeotNlIJW2FEJWb7WBda'.
+'NSQI0fHYyJjkrjKRDZQwnpQ1vgBIr+w8+a+9GocZr8iKkuY1eXhsKH8U8iZE9BHz6ZHUc48UfSPqzqH3kfeO9kTTDQYGGietpTaO'.
+'shyW6AocpHNIrv8AvWzk9BUSdPdYS4BcRlomkhIV6KP0VE39V+tU2wdlRMHtZUB8NuTQ+51X27+Kr46ZPIAFV540D8zeLsJ5LMHa'.
+'ubmMBCVJdjx0pRyLoWR4I8aNIQ8BvZMNtMTeUcsptKfc4tC1gAkCyFC+K0aJtf/Z' ;
+
+        //==========================================================
+        // lk-small.jpg
+        //==========================================================
+        $this->chars['k'][0]= 680 ;
+        $this->chars['k'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABUDASIAAhEBAxEB/8QAGQAAAwEBAQAAAAAAAAAAAAAAAAUGBAMH/8QALhAAAQMDAwIEBAcAAAAAAAAA'.
+'AQIDBAUREgAGITFBEyIyYQcVUYEUIzNicZHx/8QAFgEBAQEAAAAAAAAAAAAAAAAAAwEE/8QAGxEAAwACAwAAAAAAAAAAAAAAAAEC'.
+'AxESMeH/2gAMAwEAAhEDEQA/APVK/V36dU6NSJDTT8esPLiqfK8S2cCoeTkKvZQ6jm2ldSqKqbu+OgMOvSX3m4UBrLnDlbqiefKl'.
+'Nzz2x1m+IwNP27CkJQ7JkR6rCkMJbP5jp8S2CPfkgD6H+dJ6Ca0nerr+64rTNSqMYrg+C9mmOwhVpDfsuxSbi97DmybaoZeQ5jTl'.
+'PEp18JTIfeW3kq3ly4H26aNZqvTWZsjFcZTsVtSg0G8Rio+vr2vb7g6NLPRnuXy8F+8kl+obUh4KXJdqSJJQnohlkZqJPYBXh3P+'.
+'a4b5Hyp6k1bO7sOotPyXkj9NlwFl0ewstJA9ifrqkVSmET4csoS7UTHXFQ+6SQlskKUMb/tH9ddLVUmS7DqdBqD7U6OsqfS46jzl'.
+'hQ5bXb1K9Scuybdxo2OTu92dwSZkWn0Sb8viQWyn8Qq5D6ifSLd0BIv7q0arTBRSKPToMZbi2GWylsvLK148Wue/XRrRjxOpT2R2'.
+'k9aP/9k=' ; 
+
+        //==========================================================
+        // lr-small.jpg
+        //==========================================================
+        $this->chars['r'][0]= 681 ;
+        $this->chars['r'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABYDASIAAhEBAxEB/8QAGgAAAgIDAAAAAAAAAAAAAAAAAAYCBQMEB//EAC4QAAICAQIFAgMJAQAAAAAA'.
+'AAECAwQRBQYAEiExQQdRFGFxEyIyM0JSYoGC8P/EABYBAQEBAAAAAAAAAAAAAAAAAAEAAv/EABcRAQEBAQAAAAAAAAAAAAAAAAAB'.
+'EUH/2gAMAwEAAhEDEQA/AOs0ZdETU54Gt1INSmlPJEsyo7J+jlXPUYBPY9c+eE/dO9tY0a7ren6BVrW7VJTZtW5kZkjXkBSIKveQ'.
+'gHp0AAJ4w+q2hVdT2Md0h46+saS4mr3EUK0gWTAB+vQj2PboeL/ZVOqmhaZVjkFmxdC6tctt3tM2G5/7bAx4C4+qxiWwd3prWzKe'.
+'r3IBAth5OYxozKsgc8y4GTgnJB9uncdTi6tXq2140rRVM13JMEMAVAg7sMdBjJB/18uDgRO9R2Oo6FX2vShkFzURFUq1whIj+8DI'.
+'7EdAFjXv7MeNb0kuStsFEmIaajZaos2fy2Q4VGH7SGxn+Rzw9yMLOm/FzRhZazmOTkP4grYyD3B8j2PTyeFfZ+z7G3BeSS8lmprl'.
+'2K2qcnK0Z5S8gPjrgAY8cNEWmq7u23pEos6/Zji+Kd0rLLGWwseA3joeZj/w4OET1g0vlmrWV+ydFnkUxSgsvM4V+YYIwfHz6cHB'.
+'ZeKZ1//Z' ; 
+
+        //==========================================================
+        // lg-small.jpg
+        //==========================================================
+        $this->chars['g'][0]= 655 ;
+        $this->chars['g'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABQDASIAAhEBAxEB/8QAGQAAAgMBAAAAAAAAAAAAAAAAAAQCBQYH/8QAJxAAAQQBAwQCAgMAAAAAAAAA'.
+'AQIDBBEFAAYhBxIxQRNhcYEiQlH/xAAYAQACAwAAAAAAAAAAAAAAAAACAwABBP/EABkRAAMBAQEAAAAAAAAAAAAAAAABAhEhIv/a'.
+'AAwDAQACEQMRAD8AayO4t6bq3hmMHtxyLi4OKeKH5jyASiiQCCQeTRNAeB61FrBb+jTGpLO+BMW24EFMhkhpQru8m7B/H70x09Yi'.
+'q3nv/vLfwpnJ7UNkqSRbngf2ofWkpXV7brymC2malLfagurjW0aHk89xPJ9cX9aprURHWbYEaMHHEBfwpv8AnXPk+/8AdGqGJOxO'.
+'4YbOSxK4y4boIStUWysgkEmxY54r60aOI8oTV9MHtjJwunPUbO46WWo0HLlD8KY4goboFVoquOVEVwLT963WdnxYfT6ZJyz0JvHm'.
+'KvtaSkW4tYNVSqKiTwB+fw5n9sY/cuOXCzDDcluyW3Ckd7V+0n0eNZTH9DdouFalHIOJBUhtDki0pNV3UALo81ehG6IdKjPZ6d47'.
+'4ywltanVJvuJI+RQs/sHRqy2r003JhsImEc/CUyhxRZBjKV2oJ8eRXNmufPnRo1WIz3DdNn/2Q==' ;
+
+        //==========================================================
+        // lc-small.jpg
+        //==========================================================
+        $this->chars['c'][0]= 629 ;
+        $this->chars['c'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABcDASIAAhEBAxEB/8QAGQAAAwEBAQAAAAAAAAAAAAAAAAUGBwID/8QALRAAAgICAQIEBAYDAAAAAAAA'.
+'AQIDBAURACExBhIiQRMVUWEHMkJScYFykaH/xAAWAQEBAQAAAAAAAAAAAAAAAAABAgP/xAAXEQEBAQEAAAAAAAAAAAAAAAAAATER'.
+'/9oADAMBAAIRAxEAPwDcoGkmiT4Q8kWvzuPU38D2/v8A1zwrCFayq1qTaFk2H7aJHt05MeMvENzC4upDWkjW9kJXiricAJCigvJN'.
+'IB1IVQT5frrv24twPgunk6a288crbklUSJNNdnSTZ2STHHqOP/Eb17njdZtAoqwEvrEiGVyG117/AG6HhyV8H1sljMldoxXTksGC'.
+'zV7M0oaWGQOVeGQ92I6EMR22D11w4LmEPjaOL51iL8ssc9Z69zHtZkYCGGeQK0ez2UEoU39wCeX1S/LLiEt+mPSbMLxsGVv2kEjR'.
+'305xkaEV/GTULMUT1LD/AAGh8gIZS2jv+vpybb8NMIb0dVLWYWgiiU0vmMphOj6V0TvQI3rfsON1E6dYjGtisa0F1mAWR2NhG0WZ'.
+'3Ls3TqNs5Hc9h23w49NWL9K+Q/VD5T/zhwPH/9k=' ; 
+
+        //==========================================================
+        // d7-small.jpg
+        //==========================================================
+        $this->chars['7'][0]= 658 ;
+        $this->chars['7'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AEgMBIgACEQEDEQH/xAAZAAACAwEAAAAAAAAAAAAAAAAABgEFBwT/xAAuEAABAwIE'.
+'BAQGAwAAAAAAAAABAgMEBREABiExEhMiQSMyUXEHFBclVJFhk9L/xAAXAQADAQAAAAAAAAAAAAAAAAAAAQID/8QAGREBAQEAAwAA'.
+'AAAAAAAAAAAAAAEREiFR/9oADAMBAAIRAxEAPwDXq9mCjZeQ05VZ5ZST4bfEpa3VdglCbqUe+g9MZ5Uq7V8415WXoMSdQ6etgSps'.
+'19wpkCMDZKUpv0FZvbi1NzpYasMDLDUbMVXrtQdbeeU23xLWkj5RlLYK0J7anW9gbAjCzkOtsVSUJUdtc6dVZK51UeaFm4LKbhpC'.
+'l7EhIFkDW974GbRI2XorUVls1OTdKAOqUpR0Hc3198GITQ6k+hLwrEpoODiDenRfW23bBicg78JXxPpD0mgVOW5PAivNNpahsPW5'.
+'8xxQaSVkboQnhsnYm5OHqDGp1IpsalMKjMsMIC3+XZKbJFth62/QOEfMOZqZXp9JcKZTcGmTky3meSi7xQklI81vMR+sXIz/AEgp'.
+'Q0qPNu6ea8Q2jqtbp8+2w9h/OKORc/cpHjt1dDSHOtLZ4ekHW23bBjj+o9H/AB539aP94MG0+L//2Q==' ; 
+
+        //==========================================================
+        // ly-small.jpg
+        //==========================================================
+        $this->chars['y'][0]= 672 ;
+        $this->chars['y'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABQDASIAAhEBAxEB/8QAGAAAAwEBAAAAAAAAAAAAAAAAAAQGBQf/xAArEAABAwMEAQIFBQAAAAAAAAAB'.
+'AgMEBREhAAYSEzEHIhQkQVGxQmFxgaH/xAAWAQEBAQAAAAAAAAAAAAAAAAADAQL/xAAeEQEAAgEEAwAAAAAAAAAAAAABABECAxIh'.
+'MUGR8P/aAAwDAQACEQMRAD8Ar3tys07dVHohemz5dWQ7fk91MsA3IIRY8rkKFySceTqw3JVV0KhyKw+0C1CQp9aUOFSiAk4AIAvn'.
+'76xtz0ioVvbcJ6msx2JtOfZmw1PKI5LQcJNh7UqBKcn6+NRfqPu6s1fYc6GxSJsRfWDUVSGA22ygEckJWSexRNgOP0udXzDKOJ0I'.
+'yo62mHm25Sy80l1Z4lSgpQvZRGLgWwPGjTjbchyLH+Ejx22EtJSgO8kki3kADA/nOjWjGzv73CyQZjUWNVp7bNSrj7qJDqflqUlQ'.
+'DMds24l3HvcNr3Pi9gME6T9WWVsemdYWswwC2lPta4m5WMA3OdUExCmozUJD6g84ntMjrHIFBTdQz5yLDx/WDNytpwW6nAkViqVe'.
+'uvmXdlme6n4dCwlRBKEgA2tj99QG7Ilncp5QqpU31PMsJ6x7A32f6SPxo0hPVCD45oVyKf0MtgeT97/nRrO7UOCFla3tn//Z' ; 
+
+        //==========================================================
+        // d3-small.jpg
+        //==========================================================
+        $this->chars['3'][0]= 662 ;
+        $this->chars['3'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD//gAJSnBHcmFwaP/bAEMACAYGBwYFCAcHBwkJCAoMFA0MCwsMGRITDxQdGh8eHRocHCAkLicg'.
+'IiwjHBwoNyksMDE0NDQfJzk9ODI8LjM0Mv/bAEMBCQkJDAsMGA0NGDIhHCEyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjIyMjIyMjIyMjIyMv/AABEIAB4AEgMBIgACEQEDEQH/xAAZAAACAwEAAAAAAAAAAAAAAAAABAUGBwL/xAArEAABBAED'.
+'AwMDBQEAAAAAAAABAgMEBREABhIhMUEiMmETFZEHFkJDUdH/xAAWAQEBAQAAAAAAAAAAAAAAAAABAAL/xAAYEQEBAQEBAAAAAAAA'.
+'AAAAAAAAEQExQf/aAAwDAQACEQMRAD8A0vclruBdk3VVLLUNssGRJsZSCtqOjlgJAHvcOD6c4HnOdIbcttw1W5P29cFEhuawqTXS'.
+'VsJjnCMBxKkJJx7goAde+ceJfdNxU0UNlyymyXHi6kxWUNl1S3EnkAEIHX2nv86qtTuZr9Q9+1VhRsOoYpYcgSVyAE/TdewkJxnK'.
+'sBCjkdPGpnOtFMd3PqsXgfOAgD8Y0aX+11H9rDDjn8lr9yj5J+dGqsqxaw6Cc9cQZU4Sp7zTJsIrKlcUEKwhSin1JABI45GUjqOu'.
+'lbOvjbc3Ts9ynjGCy445UuFLYRzbWgrT6fhSCQSMDke+pew2zYVly/d7YchNqkMJZnQpgV9J8IzwWFJyUrAJHYgjvpLbu37G5nR7'.
+'vck5C3YRKYEOEVJZj8kjKypXqWvirjk9h+dB9i4faa89TDZUfKlIyT8k+To10a6KTkpcJ/0vL/7o0TS//9k=' ; 
+
+        //==========================================================
+        // ln-small.jpg
+        //==========================================================
+        $this->chars['n'][0]= 643 ;
+        $this->chars['n'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABQDASIAAhEBAxEB/8QAGwAAAgEFAAAAAAAAAAAAAAAAAAYCAQMEBQf/xAAtEAACAQMCBAUCBwAAAAAA'.
+'AAABAgMEBREAIQYSE0EHIjFRcWGRIzIzQoGCwf/EABYBAQEBAAAAAAAAAAAAAAAAAAMEAP/EABkRAQEBAQEBAAAAAAAAAAAAAAEA'.
+'AhEhUf/aAAwDAQACEQMRAD8A6FR3p7v4oV9rlkMQsjL00RyOss0KkFxnDcrc2PbI1NOJKyTjW+W5OmKeA0UEJx5meRZS2/8AUfbS'.
+'LVGS1+K16vCzfiR3GmoqqXGyxz06hWPsFlVMfOmq1iNvE69KjBYo3oJMZ3GKeYYPxg/fW+xzZX1FLQyxwSTcpWNceu4G3+aNSmpY'.
+'qmQzzwh2k8yhv2r2H23/AJ0aoy+EWh7I1ntacR3PxDtEzhjWy0wkkIwYmanU5GO6sNh7rrU8AVdTceNbhDXxNHUQvS0tZ3DzwxVA'.
+'fB7hj59/XJ08cPWaKj4gvlwSQiG7dCboqvLy9NOmQT9SM7ayJrBa6K5V91hjlWorp4JGUOAglRSiMMDb82/vgaBGTpVvtNUVtyJg'.
+'5+WNAh5ZCu/r2+dGrgq0pi0DhmlRsSSAfqMd+b6ZyNu3po1Rk1yNBe3/2Q==' ; 
+
+        //==========================================================
+        // lu-small.jpg
+        //==========================================================
+        $this->chars['u'][0]= 671 ;
+        $this->chars['u'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABcDASIAAhEBAxEB/8QAGQAAAgMBAAAAAAAAAAAAAAAAAAYDBAUH/8QAJRAAAQQBAwQDAQEAAAAAAAAA'.
+'AQIDBBEFAAYhBxMxYRJBURSB/8QAFgEBAQEAAAAAAAAAAAAAAAAAAQAD/8QAGhEBAQEAAwEAAAAAAAAAAAAAAQARITFBAv/aAAwD'.
+'AQACEQMRAD8A6dLkQmJzu3WVtHIqjf0duKFNuBr5UTQ45F1R8/XI1PMmsYoJyjhS9iI7BKHeKjkXZVXqhyLHP+rrHeR1pZlx1W1M'.
+'wTiW0ukkrS28nn5fV2SPPFfurHUKQhzYG7pLYKEfyBhaSOS7dG/YCki/uvWn3LPDOJrwa4kyEzOYeakqkpC3Hk0bNePQHgDRpchY'.
+'leIZwzUWauKtuPctTSUlCAUmrBHIKuAPV/ujQsmHdm7hya43UbbD3ZVElOQJsdTS6IQaQUqBHCk8E2Pocgam6oYwObHy0Zm0oi45'.
+'T1KBPdpV2f0pom/1Ws7cmPazu98Ltvcq3VzRHfehz8a4pirFEKRZo8eQT+eCdWYfS/b+WYnxpbuVcDRMdHcyTqg2fiAfiLoi+Rf+'.
+'jT7Xc74HtOYnHyUOh8yWUvKeHhy0CiPVUAPoDRrm+OeznTva6lzsyMjCYbbaiNJjJSWElagD5tRpNUSALFeNGoOCH7Bv/9k=' ; 
+
+        //==========================================================
+        // lw-small.jpg
+        //==========================================================
+        $this->chars['w'][0]= 673 ;
+        $this->chars['w'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABcDASIAAhEBAxEB/8QAGAAAAgMAAAAAAAAAAAAAAAAAAAYDBAX/xAAtEAACAQMDAgMHBQAAAAAAAAAB'.
+'AgMEBREABhIhMRMUQRUiIzJRYZEWNIGx0f/EABYBAQEBAAAAAAAAAAAAAAAAAAABA//EABoRAAICAwAAAAAAAAAAAAAAAAABERIh'.
+'MVH/2gAMAwEAAhEDEQA/AHXbV13ZLu6t2/uaa1JijWopVp4XUTKSAXRyc+6ehBGeoPbTSlwpql0K3GneqpZViqUhI5JzGMEZJGeh'.
+'GlXfaFILDf7FQzXC426rDLTojs8sLqVkXBGcfKf40twWbdWzZY75R0s90ul3jPtKjVMJDNn4DDp8iEhW+wJ1WZG2KWt3Lv26U1tv'.
+'92o7PaYkgYUbqVepYlmUBlIwqnB++O2jTDt/bBtth9jcpvEWNGqalZQryTlmeR8jPct6+mNGmRC4a1U13htzVFItB5nA/cyOUVfp'.
+'7oz/ALqitJulYJKuqvFsppHALLFb3cp9FBaXr+O51bq0q6i38KK5PDVAAxSzU6SIpz3Kjjn8jUFoS7uFmut1gq17xLFQ+DxOccj8'.
+'Rsn+tVpiyJnqv09YfOXu5AycgZZQEhBZjgDBOOgwO/po0sttWHdNzqLruioa4UwmdaC3kYp4IwSvJlBHKQ4OSe3po0qxM6P/2Q==' ;
+
+        //==========================================================
+        // lq-small.jpg
+        //==========================================================
+        $this->chars['q'][0]= 671 ;
+        $this->chars['q'][1]=
+'/9j/4AAQSkZJRgABAQEASgBKAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwgJC4nICIsIxwcKDcpLDAx'.
+'NDQ0Hyc5PTgyPC4zNDL/2wBDAQkJCQwLDBgNDRgyIRwhMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIyMjIy'.
+'MjIyMjIyMjL/wAARCAAeABQDASIAAhEBAxEB/8QAGQAAAgMBAAAAAAAAAAAAAAAAAAcDBAUG/8QAKRAAAQQBBAICAQQDAAAAAAAA'.
+'AQIDBBEFAAYSIQcxIlETCBQVgSNBYf/EABUBAQEAAAAAAAAAAAAAAAAAAAAB/8QAFhEBAQEAAAAAAAAAAAAAAAAAAAER/9oADAMB'.
+'AAIRAxEAPwDT3H5Qz+O3LN2vtrF/y86NYLzzVlAABJITQPv2a/17vXMboz3lDEYWPuafNx7CFrS03+2jpK2bs0CUkUa7pRvrUu63'.
+'sr438yv7pLEo4XIK5Kcji0uJUkckm+uQUOVH6GsnyJv7A5vaJwuFdkONLmolgONFH4vioKRXYqyCADXvRMh0yspmZ4jyIEtDTK47'.
+'aiA0lQUopBJBI/7X9aNT7amRo228e3a31iO3yUzCcdSPiKAIFdCho0TIswZ7GQlO/hlRxBooih1YXzAoKUkX0LPEBX110dJ7zbuv'.
+'AORpO04cIpmxH23FSEIRwKuNnsdk0o31702XhFMKbuRUZJWP8LTQ6HBCuIB+iVWSR2BXuqK93/hDlvGzEphmG3Ml5JpDi1I7TzNA'.
+'BYFlPafY+/7LBiv1CYDH4iFDOGySlMR22lFP4wCUpANfL11o1r4bxXlWMNEaE/bqlIbCFl/ANPK5Do/M0VDr2Rf3o0TX/9k=' ;
+
+
+
+    }
+}
+
+class AntiSpam {
+
+    private $iData='';
+    private $iDD=null;
+
+    function __construct($aData='') {
+        $this->iData = $aData;
+        $this->iDD = new HandDigits();
+    }
+
+    function Set($aData) {
+        $this->iData = $aData;
+    }
+
+    function Rand($aLen) {
+        $d='';
+        for($i=0; $i < $aLen; ++$i) {
+            if( rand(0,9) < 6 ) {
+                // Digits
+                $d .= chr( ord('1') + rand(0,8) );
+            }
+            else {
+                // Letters
+                do {
+                    $offset = rand(0,25);
+                } while ( $offset==14 );
+                $d .= chr( ord('a') + $offset );
+            }
+        }
+        $this->iData = $d;
+        return $d;
+    }
+
+    function Stroke() {
+
+        $n=strlen($this->iData);
+        if( $n==0 ) {
+            return false;
+        }
+
+        for($i=0; $i < $n; ++$i ) {
+            if( $this->iData[$i]==='0' || strtolower($this->iData[$i])==='o') {
+                return false;
+            }
+        }
+
+        $img = @imagecreatetruecolor($n*$this->iDD->iWidth, $this->iDD->iHeight);
+        if( $img < 1 ) {
+            return false;
+        }
+
+        $start=0;
+        for($i=0; $i < $n; ++$i ) {
+            $dimg = imagecreatefromstring(base64_decode($this->iDD->chars[strtolower($this->iData[$i])][1]));
+            imagecopy($img,$dimg,$start,0,0,0,imagesx($dimg), $this->iDD->iHeight);
+            $start += imagesx($dimg);
+        }
+        $resimg = @imagecreatetruecolor($start+4, $this->iDD->iHeight+4);
+        if( $resimg < 1 ) {
+            return false;
+        }
+
+        imagecopy($resimg,$img,2,2,0,0,$start, $this->iDD->iHeight);
+        header("Content-type: image/jpeg");
+        imagejpeg($resimg);
+        return true;
+    }
+}
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_bar.php b/web/classes/jpgraph/jpgraph_bar.php
new file mode 100755
index 0000000000000000000000000000000000000000..ee016695a0a960b00f9dc84ac70fc6429c4ba97d
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_bar.php
@@ -0,0 +1,1190 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_BAR.PHP
+ // Description: Bar plot extension for JpGraph
+ // Created:     2001-01-08
+ // Ver:         $Id: jpgraph_bar.php 1905 2009-10-06 18:00:21Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+require_once('jpgraph_plotband.php');
+
+// Pattern for Bars
+DEFINE('PATTERN_DIAG1',1);
+DEFINE('PATTERN_DIAG2',2);
+DEFINE('PATTERN_DIAG3',3);
+DEFINE('PATTERN_DIAG4',4);
+DEFINE('PATTERN_CROSS1',5);
+DEFINE('PATTERN_CROSS2',6);
+DEFINE('PATTERN_CROSS3',7);
+DEFINE('PATTERN_CROSS4',8);
+DEFINE('PATTERN_STRIPE1',9);
+DEFINE('PATTERN_STRIPE2',10);
+
+//===================================================
+// CLASS BarPlot
+// Description: Main code to produce a bar plot
+//===================================================
+class BarPlot extends Plot {
+    public $fill=false,$fill_color="lightblue"; // Default is to fill with light blue
+    public $iPattern=-1,$iPatternDensity=80,$iPatternColor='black';
+    public $valuepos='top';
+    public $grad=false,$grad_style=1;
+    public $grad_fromcolor=array(50,50,200),$grad_tocolor=array(255,255,255);
+    public $ymin=0;
+    protected $width=0.4; // in percent of major ticks
+    protected $abswidth=-1; // Width in absolute pixels
+    protected $ybase=0; // Bars start at 0
+    protected $align="center";
+    protected $bar_shadow=false;
+    protected $bar_shadow_color="black";
+    protected $bar_shadow_hsize=3,$bar_shadow_vsize=3;
+    protected $bar_3d=false;
+    protected $bar_3d_hsize=3,$bar_3d_vsize=3;
+
+    //---------------
+    // CONSTRUCTOR
+    function __construct($datay,$datax=false) {
+        parent::__construct($datay,$datax);
+        ++$this->numpoints;
+    }
+
+    //---------------
+    // PUBLIC METHODS
+
+    // Set a drop shadow for the bar (or rather an "up-right" shadow)
+    function SetShadow($aColor="black",$aHSize=3,$aVSize=3,$aShow=true) {
+        $this->bar_shadow=$aShow;
+        $this->bar_shadow_color=$aColor;
+        $this->bar_shadow_vsize=$aVSize;
+        $this->bar_shadow_hsize=$aHSize;
+
+        // Adjust the value margin to compensate for shadow
+        $this->value->margin += $aVSize;
+    }
+
+    function Set3D($aHSize=3,$aVSize=3,$aShow=true) {
+        $this->bar_3d=$aShow;
+        $this->bar_3d_vsize=$aVSize;
+        $this->bar_3d_hsize=$aHSize;
+
+        $this->value->margin += $aVSize;
+    }
+
+    // DEPRECATED use SetYBase instead
+    function SetYMin($aYStartValue) {
+        //die("JpGraph Error: Deprecated function SetYMin. Use SetYBase() instead.");
+        $this->ybase=$aYStartValue;
+    }
+
+    // Specify the base value for the bars
+    function SetYBase($aYStartValue) {
+        $this->ybase=$aYStartValue;
+    }
+
+    // The method will take the specified pattern anre
+    // return a pattern index that corresponds to the original
+    // patterm being rotated 90 degreees. This is needed when plottin
+    // Horizontal bars
+    function RotatePattern($aPat,$aRotate=true) {
+        $rotate = array(1 => 2, 2 => 1, 3 => 3, 4 => 5, 5 => 4, 6 => 6, 7 => 7, 8 => 8);
+        if( $aRotate ) {
+            return $rotate[$aPat];
+        }
+        else {
+            return $aPat;
+        }
+    }
+
+    function Legend($graph) {
+        if( $this->grad && $this->legend!="" && !$this->fill ) {
+            $color=array($this->grad_fromcolor,$this->grad_tocolor);
+            // In order to differentiate between gradients and cooors specified as an RGB triple
+            $graph->legend->Add($this->legend,$color,"",-$this->grad_style,
+            $this->legendcsimtarget,$this->legendcsimalt,$this->legendcsimwintarget);
+        }
+        elseif( $this->legend!="" && ($this->iPattern > -1 || is_array($this->iPattern)) ) {
+            if( is_array($this->iPattern) ) {
+                $p1 = $this->RotatePattern( $this->iPattern[0], $graph->img->a == 90 );
+                $p2 = $this->iPatternColor[0];
+                $p3 = $this->iPatternDensity[0];
+            }
+            else {
+                $p1 = $this->RotatePattern( $this->iPattern, $graph->img->a == 90 );
+                $p2 = $this->iPatternColor;
+                $p3 = $this->iPatternDensity;
+            }
+            if( $p3 < 90 ) $p3 += 5;
+            $color = array($p1,$p2,$p3,$this->fill_color);
+            // A kludge: Too mark that we add a pattern we use a type value of < 100
+            $graph->legend->Add($this->legend,$color,"",-101,
+                                $this->legendcsimtarget,$this->legendcsimalt,$this->legendcsimwintarget);
+        }
+        elseif( $this->fill_color && $this->legend!="" ) {
+            if( is_array($this->fill_color) ) {
+                $graph->legend->Add($this->legend,$this->fill_color[0],"",0,
+                $this->legendcsimtarget,$this->legendcsimalt,$this->legendcsimwintarget);
+            }
+            else {
+                $graph->legend->Add($this->legend,$this->fill_color,"",0,
+                $this->legendcsimtarget,$this->legendcsimalt,$this->legendcsimwintarget);
+            }
+        }
+    }
+
+    // Gets called before any axis are stroked
+    function PreStrokeAdjust($graph) {
+        parent::PreStrokeAdjust($graph);
+
+        // If we are using a log Y-scale we want the base to be at the
+        // minimum Y-value unless the user have specifically set some other
+        // value than the default.
+        if( substr($graph->axtype,-3,3)=="log" && $this->ybase==0 )
+        $this->ybase = $graph->yaxis->scale->GetMinVal();
+
+        // For a "text" X-axis scale we will adjust the
+        // display of the bars a little bit.
+        if( substr($graph->axtype,0,3)=="tex" ) {
+            // Position the ticks between the bars
+            $graph->xaxis->scale->ticks->SetXLabelOffset(0.5,0);
+
+            // Center the bars
+            if( $this->abswidth > -1 ) {
+                $graph->SetTextScaleAbsCenterOff($this->abswidth);
+            }
+            else {
+                if( $this->align == "center" )
+                $graph->SetTextScaleOff(0.5-$this->width/2);
+                elseif( $this->align == "right" )
+                $graph->SetTextScaleOff(1-$this->width);
+            }
+        }
+        elseif( ($this instanceof AccBarPlot) || ($this instanceof GroupBarPlot) ) {
+            // We only set an absolute width for linear and int scale
+            // for text scale the width will be set to a fraction of
+            // the majstep width.
+            if( $this->abswidth == -1 ) {
+                // Not set
+                // set width to a visuable sensible default
+                $this->abswidth = $graph->img->plotwidth/(2*$this->numpoints);
+            }
+        }
+    }
+
+    function Min() {
+        $m = parent::Min();
+        if( $m[1] >= $this->ybase ) $m[1] = $this->ybase;
+        return $m;
+    }
+
+    function Max() {
+        $m = parent::Max();
+        if( $m[1] <= $this->ybase ) $m[1] = $this->ybase;
+        return $m;
+    }
+
+    // Specify width as fractions of the major stepo size
+    function SetWidth($aWidth) {
+        if( $aWidth > 1 ) {
+            // Interpret this as absolute width
+            $this->abswidth=$aWidth;
+        }
+        else {
+            $this->width=$aWidth;
+        }
+    }
+
+    // Specify width in absolute pixels. If specified this
+    // overrides SetWidth()
+    function SetAbsWidth($aWidth) {
+        $this->abswidth=$aWidth;
+    }
+
+    function SetAlign($aAlign) {
+        $this->align=$aAlign;
+    }
+
+    function SetNoFill() {
+        $this->grad = false;
+        $this->fill_color=false;
+        $this->fill=false;
+    }
+
+    function SetFillColor($aColor) {
+        // Do an extra error check if the color is specified as an RGB array triple
+        // In that case convert it to a hex string since it will otherwise be
+        // interpretated as an array of colors for each individual bar.
+
+        $aColor = RGB::tryHexConversion($aColor);
+        $this->fill = true ;
+        $this->fill_color=$aColor;
+
+    }
+
+    function SetFillGradient($aFromColor,$aToColor=null,$aStyle=null) {
+        $this->grad = true;
+        $this->grad_fromcolor = $aFromColor;
+        $this->grad_tocolor   = $aToColor;
+        $this->grad_style     = $aStyle;
+    }
+
+    function SetValuePos($aPos) {
+        $this->valuepos = $aPos;
+    }
+
+    function SetPattern($aPattern, $aColor='black'){
+        if( is_array($aPattern) ) {
+            $n = count($aPattern);
+            $this->iPattern = array();
+            $this->iPatternDensity = array();
+            if( is_array($aColor) ) {
+                $this->iPatternColor = array();
+                if( count($aColor) != $n ) {
+                    JpGraphError::RaiseL(2001);//('NUmber of colors is not the same as the number of patterns in BarPlot::SetPattern()');
+                }
+            }
+            else {
+                $this->iPatternColor = $aColor;
+            }
+            for( $i=0; $i < $n; ++$i ) {
+                $this->_SetPatternHelper($aPattern[$i], $this->iPattern[$i], $this->iPatternDensity[$i]);
+                if( is_array($aColor) ) {
+                    $this->iPatternColor[$i] = $aColor[$i];
+                }
+            }
+        }
+        else {
+            $this->_SetPatternHelper($aPattern, $this->iPattern, $this->iPatternDensity);
+            $this->iPatternColor = $aColor;
+        }
+    }
+
+    function _SetPatternHelper($aPattern, &$aPatternValue, &$aDensity){
+        switch( $aPattern ) {
+            case PATTERN_DIAG1:
+                $aPatternValue= 1;
+                $aDensity = 92;
+                break;
+            case PATTERN_DIAG2:
+                $aPatternValue= 1;
+                $aDensity = 78;
+                break;
+            case PATTERN_DIAG3:
+                $aPatternValue= 2;
+                $aDensity = 92;
+                break;
+            case PATTERN_DIAG4:
+                $aPatternValue= 2;
+                $aDensity = 78;
+                break;
+            case PATTERN_CROSS1:
+                $aPatternValue= 8;
+                $aDensity = 90;
+                break;
+            case PATTERN_CROSS2:
+                $aPatternValue= 8;
+                $aDensity = 78;
+                break;
+            case PATTERN_CROSS3:
+                $aPatternValue= 8;
+                $aDensity = 65;
+                break;
+            case PATTERN_CROSS4:
+                $aPatternValue= 7;
+                $aDensity = 90;
+                break;
+            case PATTERN_STRIPE1:
+                $aPatternValue= 5;
+                $aDensity = 94;
+                break;
+            case PATTERN_STRIPE2:
+                $aPatternValue= 5;
+                $aDensity = 85;
+                break;
+            default:
+                JpGraphError::RaiseL(2002);
+                //('Unknown pattern specified in call to BarPlot::SetPattern()');
+        }
+    }
+
+    function Stroke($img,$xscale,$yscale) {
+
+        $numpoints = count($this->coords[0]);
+        if( isset($this->coords[1]) ) {
+            if( count($this->coords[1])!=$numpoints ) {
+                JpGraphError::RaiseL(2003,count($this->coords[1]),$numpoints);
+            //"Number of X and Y points are not equal. Number of X-points:".count($this->coords[1])."Number of Y-points:$numpoints");
+            }
+            else {
+                $exist_x = true;
+            }
+        }
+        else {
+            $exist_x = false;
+        }
+
+
+        $numbars=count($this->coords[0]);
+
+        // Use GetMinVal() instead of scale[0] directly since in the case
+        // of log scale we get a correct value. Log scales will have negative
+        // values for values < 1 while still not representing negative numbers.
+        if( $yscale->GetMinVal() >= 0 )
+        $zp=$yscale->scale_abs[0];
+        else {
+            $zp=$yscale->Translate(0);
+        }
+
+        if( $this->abswidth > -1 ) {
+            $abswidth=$this->abswidth;
+        }
+        else {
+            $abswidth=round($this->width*$xscale->scale_factor,0);
+        }
+
+        // Count pontetial pattern array to avoid doing the count for each iteration
+        if( is_array($this->iPattern) ) {
+            $np = count($this->iPattern);
+        }
+
+        $grad = null;
+        for($i=0; $i < $numbars; ++$i) {
+
+            // If value is NULL, or 0 then don't draw a bar at all
+            if ($this->coords[0][$i] === null || $this->coords[0][$i] === '' )
+            continue;
+
+            if( $exist_x ) {
+                $x=$this->coords[1][$i];
+            }
+            else {
+                $x=$i;
+            }
+
+            $x=$xscale->Translate($x);
+
+            // Comment Note: This confuses the positioning when using acc together with
+            // grouped bars. Workaround for fixing #191
+            /*
+            if( !$xscale->textscale ) {
+            if($this->align=="center")
+            $x -= $abswidth/2;
+            elseif($this->align=="right")
+            $x -= $abswidth;
+            }
+            */
+            // Stroke fill color and fill gradient
+            $pts=array(
+            $x,$zp,
+            $x,$yscale->Translate($this->coords[0][$i]),
+            $x+$abswidth,$yscale->Translate($this->coords[0][$i]),
+            $x+$abswidth,$zp);
+            if( $this->grad ) {
+                if( $grad === null ) {
+                    $grad = new Gradient($img);
+                }
+                if( is_array($this->grad_fromcolor) ) {
+                    // The first argument (grad_fromcolor) can be either an array or a single color. If it is an array
+                    // then we have two choices. It can either a) be a single color specified as an RGB triple or it can be
+                    // an array to specify both (from, to style) for each individual bar. The way to know the difference is
+                    // to investgate the first element. If this element is an integer [0,255] then we assume it is an RGB
+                    // triple.
+                    $ng = count($this->grad_fromcolor);
+                    if( $ng === 3 ) {
+                        if( is_numeric($this->grad_fromcolor[0]) && $this->grad_fromcolor[0] > 0 && $this->grad_fromcolor[0] < 256 ) {
+                            // RGB Triple
+                            $fromcolor = $this->grad_fromcolor;
+                            $tocolor = $this->grad_tocolor;
+                            $style = $this->grad_style;
+                        }
+                        else {
+                            $fromcolor = $this->grad_fromcolor[$i % $ng][0];
+                            $tocolor = $this->grad_fromcolor[$i % $ng][1];
+                            $style = $this->grad_fromcolor[$i % $ng][2];
+                        }
+                    }
+                    else {
+                        $fromcolor = $this->grad_fromcolor[$i % $ng][0];
+                        $tocolor = $this->grad_fromcolor[$i % $ng][1];
+                        $style = $this->grad_fromcolor[$i % $ng][2];
+                    }
+                    $grad->FilledRectangle($pts[2],$pts[3],
+                                           $pts[6],$pts[7],
+                                           $fromcolor,$tocolor,$style);
+                }
+                else {
+                    $grad->FilledRectangle($pts[2],$pts[3],
+                    $pts[6],$pts[7],
+                    $this->grad_fromcolor,$this->grad_tocolor,$this->grad_style);
+                }
+            }
+            elseif( !empty($this->fill_color) ) {
+                if(is_array($this->fill_color)) {
+                    $img->PushColor($this->fill_color[$i % count($this->fill_color)]);
+                } else {
+                    $img->PushColor($this->fill_color);
+                }
+                $img->FilledPolygon($pts);
+                $img->PopColor();
+            }
+
+/////////////////////////kokorahen rectangle polygon//////////////////////
+
+            // Remember value of this bar
+            $val=$this->coords[0][$i];
+
+            if( !empty($val) && !is_numeric($val) ) {
+                JpGraphError::RaiseL(2004,$i,$val);
+                //'All values for a barplot must be numeric. You have specified value['.$i.'] == \''.$val.'\'');
+            }
+
+            // Determine the shadow
+            if( $this->bar_shadow && $val != 0) {
+
+                $ssh = $this->bar_shadow_hsize;
+                $ssv = $this->bar_shadow_vsize;
+                // Create points to create a "upper-right" shadow
+                if( $val > 0 ) {
+                    $sp[0]=$pts[6];  $sp[1]=$pts[7];
+                    $sp[2]=$pts[4];  $sp[3]=$pts[5];
+                    $sp[4]=$pts[2];  $sp[5]=$pts[3];
+                    $sp[6]=$pts[2]+$ssh; $sp[7]=$pts[3]-$ssv;
+                    $sp[8]=$pts[4]+$ssh; $sp[9]=$pts[5]-$ssv;
+                    $sp[10]=$pts[6]+$ssh; $sp[11]=$pts[7]-$ssv;
+                }
+                elseif( $val < 0 ) {
+                    $sp[0]=$pts[4];  $sp[1]=$pts[5];
+                    $sp[2]=$pts[6];  $sp[3]=$pts[7];
+                    $sp[4]=$pts[0];  $sp[5]=$pts[1];
+                    $sp[6]=$pts[0]+$ssh; $sp[7]=$pts[1]-$ssv;
+                    $sp[8]=$pts[6]+$ssh; $sp[9]=$pts[7]-$ssv;
+                    $sp[10]=$pts[4]+$ssh; $sp[11]=$pts[5]-$ssv;
+                }
+                if( is_array($this->bar_shadow_color) ) {
+                    $numcolors = count($this->bar_shadow_color);
+                    if( $numcolors == 0 ) {
+                        JpGraphError::RaiseL(2005);//('You have specified an empty array for shadow colors in the bar plot.');
+                    }
+                    $img->PushColor($this->bar_shadow_color[$i % $numcolors]);
+                }
+                else {
+                    $img->PushColor($this->bar_shadow_color);
+                }
+                $img->FilledPolygon($sp);
+                $img->PopColor();
+
+            } elseif( $this->bar_3d && $val != 0) {
+              // Determine the 3D
+
+                $ssh = $this->bar_3d_hsize;
+                $ssv = $this->bar_3d_vsize;
+
+                // Create points to create a "upper-right" shadow
+                if( $val > 0 ) {
+                    $sp1[0]=$pts[6];  $sp1[1]=$pts[7];
+                    $sp1[2]=$pts[4];  $sp1[3]=$pts[5];
+                    $sp1[4]=$pts[4]+$ssh; $sp1[5]=$pts[5]-$ssv;
+                    $sp1[6]=$pts[6]+$ssh; $sp1[7]=$pts[7]-$ssv;
+
+                    $sp2[0]=$pts[4];  $sp2[1]=$pts[5];
+                    $sp2[2]=$pts[2];  $sp2[3]=$pts[3];
+                    $sp2[4]=$pts[2]+$ssh; $sp2[5]=$pts[3]-$ssv;
+                    $sp2[6]=$pts[4]+$ssh; $sp2[7]=$pts[5]-$ssv;
+
+                }
+                elseif( $val < 0 ) {
+                    $sp1[0]=$pts[4];  $sp1[1]=$pts[5];
+                    $sp1[2]=$pts[6];  $sp1[3]=$pts[7];
+                    $sp1[4]=$pts[6]+$ssh; $sp1[5]=$pts[7]-$ssv;
+                    $sp1[6]=$pts[4]+$ssh; $sp1[7]=$pts[5]-$ssv;
+
+                    $sp2[0]=$pts[6];  $sp2[1]=$pts[7];
+                    $sp2[2]=$pts[0];  $sp2[3]=$pts[1];
+                    $sp2[4]=$pts[0]+$ssh; $sp2[5]=$pts[1]-$ssv;
+                    $sp2[6]=$pts[6]+$ssh; $sp2[7]=$pts[7]-$ssv;
+                }
+
+                $base_color = $this->fill_color;
+
+                $img->PushColor($base_color . ':0.7');
+                $img->FilledPolygon($sp1);
+                $img->PopColor();
+
+                $img->PushColor($base_color . ':1.1');
+                $img->FilledPolygon($sp2);
+                $img->PopColor();
+            }
+
+            // Stroke the pattern
+            if( is_array($this->iPattern) ) {
+                $f = new RectPatternFactory();
+                if( is_array($this->iPatternColor) ) {
+                    $pcolor = $this->iPatternColor[$i % $np];
+                }
+                else {
+                    $pcolor = $this->iPatternColor;
+                }
+                $prect = $f->Create($this->iPattern[$i % $np],$pcolor,1);
+                $prect->SetDensity($this->iPatternDensity[$i % $np]);
+
+                if( $val < 0 ) {
+                    $rx = $pts[0];
+                    $ry = $pts[1];
+                }
+                else {
+                    $rx = $pts[2];
+                    $ry = $pts[3];
+                }
+                $width = abs($pts[4]-$pts[0])+1;
+                $height = abs($pts[1]-$pts[3])+1;
+                $prect->SetPos(new Rectangle($rx,$ry,$width,$height));
+                $prect->Stroke($img);
+            }
+            else {
+                if( $this->iPattern > -1 ) {
+                    $f = new RectPatternFactory();
+                    $prect = $f->Create($this->iPattern,$this->iPatternColor,1);
+                    $prect->SetDensity($this->iPatternDensity);
+                    if( $val < 0 ) {
+                        $rx = $pts[0];
+                        $ry = $pts[1];
+                    }
+                    else {
+                        $rx = $pts[2];
+                        $ry = $pts[3];
+                    }
+                    $width = abs($pts[4]-$pts[0])+1;
+                    $height = abs($pts[1]-$pts[3])+1;
+                    $prect->SetPos(new Rectangle($rx,$ry,$width,$height));
+                    $prect->Stroke($img);
+                }
+            }
+
+            // Stroke the outline of the bar
+            if( is_array($this->color) ) {
+                $img->SetColor($this->color[$i % count($this->color)]);
+            }
+            else {
+                $img->SetColor($this->color);
+            }
+
+            $pts[] = $pts[0];
+            $pts[] = $pts[1];
+
+            if( $this->weight > 0 ) {
+                $img->SetLineWeight($this->weight);
+                $img->Polygon($pts);
+            }
+
+            // Determine how to best position the values of the individual bars
+            $x=$pts[2]+($pts[4]-$pts[2])/2;
+            $this->value->SetMargin(5);
+
+            if( $this->valuepos=='top' ) {
+                $y=$pts[3];
+                if( $img->a === 90 ) {
+                    if( $val < 0 ) {
+                        $this->value->SetAlign('right','center');
+                    }
+                    else {
+                        $this->value->SetAlign('left','center');
+                    }
+
+                }
+                else {
+                    if( $val < 0 ) {
+                        $this->value->SetMargin(-5);
+                        $y=$pts[1];
+                        $this->value->SetAlign('center','bottom');
+                    }
+                    else {
+                        $this->value->SetAlign('center','bottom');
+                    }
+
+                }
+                $this->value->Stroke($img,$val,$x,$y);
+            }
+            elseif( $this->valuepos=='max' ) {
+                $y=$pts[3];
+                if( $img->a === 90 ) {
+                    if( $val < 0 )
+                    $this->value->SetAlign('left','center');
+                    else
+                    $this->value->SetAlign('right','center');
+                }
+                else {
+                    if( $val < 0 ) {
+                        $this->value->SetAlign('center','bottom');
+                    }
+                    else {
+                        $this->value->SetAlign('center','top');
+                    }
+                }
+                $this->value->SetMargin(-5);
+                $this->value->Stroke($img,$val,$x,$y);
+            }
+            elseif( $this->valuepos=='center' ) {
+                $y = ($pts[3] + $pts[1])/2;
+                $this->value->SetAlign('center','center');
+                $this->value->SetMargin(0);
+                $this->value->Stroke($img,$val,$x,$y);
+            }
+            elseif( $this->valuepos=='bottom' || $this->valuepos=='min' ) {
+                $y=$pts[1];
+                if( $img->a === 90 ) {
+                    if( $val < 0 )
+                    $this->value->SetAlign('right','center');
+                    else
+                    $this->value->SetAlign('left','center');
+                }
+                $this->value->SetMargin(3);
+                $this->value->Stroke($img,$val,$x,$y);
+            }
+            else {
+                JpGraphError::RaiseL(2006,$this->valuepos);
+                //'Unknown position for values on bars :'.$this->valuepos);
+            }
+            // Create the client side image map
+            $rpts = $img->ArrRotate($pts);
+            $csimcoord=round($rpts[0]).", ".round($rpts[1]);
+            for( $j=1; $j < 4; ++$j){
+                $csimcoord .= ", ".round($rpts[2*$j]).", ".round($rpts[2*$j+1]);
+            }
+            if( !empty($this->csimtargets[$i]) ) {
+                $this->csimareas .= '<area shape="poly" coords="'.$csimcoord.'" ';
+                $this->csimareas .= " href=\"".htmlentities($this->csimtargets[$i])."\"";
+
+                if( !empty($this->csimwintargets[$i]) ) {
+                    $this->csimareas .= " target=\"".$this->csimwintargets[$i]."\" ";
+                }
+
+                $sval='';
+                if( !empty($this->csimalts[$i]) ) {
+                    $sval=sprintf($this->csimalts[$i],$this->coords[0][$i]);
+                    $this->csimareas .= " title=\"$sval\" alt=\"$sval\" ";
+                }
+                $this->csimareas .= " />\n";
+            }
+        }
+        return true;
+    }
+} // Class
+
+//===================================================
+// CLASS GroupBarPlot
+// Description: Produce grouped bar plots
+//===================================================
+class GroupBarPlot extends BarPlot {
+    public $plots; 
+    private $nbrplots=0;
+    //---------------
+    // CONSTRUCTOR
+    function GroupBarPlot($plots) {
+        $this->width=0.7;
+        $this->plots = $plots;
+        $this->nbrplots = count($plots);
+        if( $this->nbrplots < 1 ) {
+            JpGraphError::RaiseL(2007);//('Cannot create GroupBarPlot from empty plot array.');
+        }
+        for($i=0; $i < $this->nbrplots; ++$i ) {
+            if( empty($this->plots[$i]) || !isset($this->plots[$i]) ) {
+                JpGraphError::RaiseL(2008,$i);//("Group bar plot element nbr $i is undefined or empty.");
+            }
+        }
+        $this->numpoints = $plots[0]->numpoints;
+        $this->width=0.7;
+    }
+
+    //---------------
+    // PUBLIC METHODS
+    function Legend($graph) {
+        $n = count($this->plots);
+        for($i=0; $i < $n; ++$i) {
+            $c = get_class($this->plots[$i]);
+            if( !($this->plots[$i] instanceof BarPlot) ) {
+                JpGraphError::RaiseL(2009,$c);
+                //('One of the objects submitted to GroupBar is not a BarPlot. Make sure that you create the Group Bar plot from an array of BarPlot or AccBarPlot objects. (Class = '.$c.')');
+            }
+            $this->plots[$i]->DoLegend($graph);
+        }
+    }
+
+    function Min() {
+        list($xmin,$ymin) = $this->plots[0]->Min();
+        $n = count($this->plots);
+        for($i=0; $i < $n; ++$i) {
+            list($xm,$ym) = $this->plots[$i]->Min();
+            $xmin = max($xmin,$xm);
+            $ymin = min($ymin,$ym);
+        }
+        return array($xmin,$ymin);
+    }
+
+    function Max() {
+        list($xmax,$ymax) = $this->plots[0]->Max();
+        $n = count($this->plots);
+        for($i=0; $i < $n; ++$i) {
+            list($xm,$ym) = $this->plots[$i]->Max();
+            $xmax = max($xmax,$xm);
+            $ymax = max($ymax,$ym);
+        }
+        return array($xmax,$ymax);
+    }
+
+    function GetCSIMareas() {
+        $n = count($this->plots);
+        $csimareas='';
+        for($i=0; $i < $n; ++$i) {
+            $csimareas .= $this->plots[$i]->csimareas;
+        }
+        return $csimareas;
+    }
+
+    // Stroke all the bars next to each other
+    function Stroke($img,$xscale,$yscale) {
+        $tmp=$xscale->off;
+        $n = count($this->plots);
+        $subwidth = $this->width/$this->nbrplots ;
+
+        for( $i=0; $i < $n; ++$i ) {
+            $this->plots[$i]->ymin=$this->ybase;
+            $this->plots[$i]->SetWidth($subwidth);
+
+            // If the client have used SetTextTickInterval() then
+            // major_step will be > 1 and the positioning will fail.
+            // If we assume it is always one the positioning will work
+            // fine with a text scale but this will not work with
+            // arbitrary linear scale
+            $xscale->off = $tmp+$i*round($xscale->scale_factor* $subwidth);
+            $this->plots[$i]->Stroke($img,$xscale,$yscale);
+        }
+        $xscale->off=$tmp;
+    }
+} // Class
+
+//===================================================
+// CLASS AccBarPlot
+// Description: Produce accumulated bar plots
+//===================================================
+class AccBarPlot extends BarPlot {
+    public $plots=null;
+    private $nbrplots=0;
+    //---------------
+    // CONSTRUCTOR
+    function __construct($plots) {
+        $this->plots = $plots;
+        $this->nbrplots = count($plots);
+        if( $this->nbrplots < 1 ) {
+            JpGraphError::RaiseL(2010);//('Cannot create AccBarPlot from empty plot array.');
+        }
+        for($i=0; $i < $this->nbrplots; ++$i ) {
+            if( empty($this->plots[$i]) || !isset($this->plots[$i]) ) {
+                JpGraphError::RaiseL(2011,$i);//("Acc bar plot element nbr $i is undefined or empty.");
+            }
+        }
+
+        // We can only allow individual plost which do not have specified X-positions
+        for($i=0; $i < $this->nbrplots; ++$i ) {
+            if( !empty($this->plots[$i]->coords[1]) ) {
+                JpGraphError::RaiseL(2015);
+                //'Individual bar plots in an AccBarPlot or GroupBarPlot can not have specified X-positions.');
+            }
+        }
+
+        // Use 0 weight by default which means that the individual bar
+        // weights will be used per part n the accumulated bar
+        $this->SetWeight(0);
+
+        $this->numpoints = $plots[0]->numpoints;
+        $this->value = new DisplayValue();
+    }
+
+    //---------------
+    // PUBLIC METHODS
+    function Legend($graph) {
+        $n = count($this->plots);
+        for( $i=$n-1; $i >= 0; --$i ) {
+            $c = get_class($this->plots[$i]);
+            if( !($this->plots[$i] instanceof BarPlot) ) {
+                JpGraphError::RaiseL(2012,$c);
+                //('One of the objects submitted to AccBar is not a BarPlot. Make sure that you create the AccBar plot from an array of BarPlot objects.(Class='.$c.')');
+            }
+            $this->plots[$i]->DoLegend($graph);
+        }
+    }
+
+    function Max() {
+        list($xmax) = $this->plots[0]->Max();
+        $nmax=0;
+        for($i=0; $i < count($this->plots); ++$i) {
+            $n = count($this->plots[$i]->coords[0]);
+            $nmax = max($nmax,$n);
+            list($x) = $this->plots[$i]->Max();
+            $xmax = max($xmax,$x);
+        }
+        for( $i = 0; $i < $nmax; $i++ ) {
+            // Get y-value for bar $i by adding the
+            // individual bars from all the plots added.
+            // It would be wrong to just add the
+            // individual plots max y-value since that
+            // would in most cases give to large y-value.
+            $y=0;
+            if( !isset($this->plots[0]->coords[0][$i]) ) {
+                JpGraphError::RaiseL(2014);
+            }
+            if( $this->plots[0]->coords[0][$i] > 0 )
+            $y=$this->plots[0]->coords[0][$i];
+            for( $j = 1; $j < $this->nbrplots; $j++ ) {
+                if( !isset($this->plots[$j]->coords[0][$i]) ) {
+                    JpGraphError::RaiseL(2014);
+                }
+                if( $this->plots[$j]->coords[0][$i] > 0 )
+                $y += $this->plots[$j]->coords[0][$i];
+            }
+            $ymax[$i] = $y;
+        }
+        $ymax = max($ymax);
+
+        // Bar always start at baseline
+        if( $ymax <= $this->ybase )
+        $ymax = $this->ybase;
+        return array($xmax,$ymax);
+    }
+
+    function Min() {
+        $nmax=0;
+        list($xmin,$ysetmin) = $this->plots[0]->Min();
+        for($i=0; $i < count($this->plots); ++$i) {
+            $n = count($this->plots[$i]->coords[0]);
+            $nmax = max($nmax,$n);
+            list($x,$y) = $this->plots[$i]->Min();
+            $xmin = Min($xmin,$x);
+            $ysetmin = Min($y,$ysetmin);
+        }
+        for( $i = 0; $i < $nmax; $i++ ) {
+            // Get y-value for bar $i by adding the
+            // individual bars from all the plots added.
+            // It would be wrong to just add the
+            // individual plots max y-value since that
+            // would in most cases give to large y-value.
+            $y=0;
+            if( $this->plots[0]->coords[0][$i] < 0 )
+            $y=$this->plots[0]->coords[0][$i];
+            for( $j = 1; $j < $this->nbrplots; $j++ ) {
+                if( $this->plots[$j]->coords[0][$i] < 0 )
+                $y += $this->plots[ $j ]->coords[0][$i];
+            }
+            $ymin[$i] = $y;
+        }
+        $ymin = Min($ysetmin,Min($ymin));
+        // Bar always start at baseline
+        if( $ymin >= $this->ybase )
+        $ymin = $this->ybase;
+        return array($xmin,$ymin);
+    }
+
+    // Stroke acc bar plot
+    function Stroke($img,$xscale,$yscale) {
+        $pattern=NULL;
+        $img->SetLineWeight($this->weight);
+        $grad=null;
+        for($i=0; $i < $this->numpoints-1; $i++) {
+            $accy = 0;
+            $accy_neg = 0;
+            for($j=0; $j < $this->nbrplots; ++$j ) {
+                $img->SetColor($this->plots[$j]->color);
+
+                if ( $this->plots[$j]->coords[0][$i] >= 0) {
+                    $yt=$yscale->Translate($this->plots[$j]->coords[0][$i]+$accy);
+                    $accyt=$yscale->Translate($accy);
+                    $accy+=$this->plots[$j]->coords[0][$i];
+                }
+                else {
+                    //if ( $this->plots[$j]->coords[0][$i] < 0 || $accy_neg < 0 ) {
+                    $yt=$yscale->Translate($this->plots[$j]->coords[0][$i]+$accy_neg);
+                    $accyt=$yscale->Translate($accy_neg);
+                    $accy_neg+=$this->plots[$j]->coords[0][$i];
+                }
+
+                $xt=$xscale->Translate($i);
+
+                if( $this->abswidth > -1 ) {
+                    $abswidth=$this->abswidth;
+                }
+                else {
+                    $abswidth=round($this->width*$xscale->scale_factor,0);
+                }
+
+                $pts=array($xt,$accyt,$xt,$yt,$xt+$abswidth,$yt,$xt+$abswidth,$accyt);
+
+                if( $this->bar_shadow ) {
+                    $ssh = $this->bar_shadow_hsize;
+                    $ssv = $this->bar_shadow_vsize;
+
+                    // We must also differ if we are a positive or negative bar.
+                    if( $j === 0 ) {
+                        // This gets extra complicated since we have to
+                        // see all plots to see if we are negative. It could
+                        // for example be that all plots are 0 until the very
+                        // last one. We therefore need to save the initial setup
+                        // for both the negative and positive case
+
+                        // In case the final bar is positive
+                        $sp[0]=$pts[6]+1; $sp[1]=$pts[7];
+                        $sp[2]=$pts[6]+$ssh; $sp[3]=$pts[7]-$ssv;
+
+                        // In case the final bar is negative
+                        $nsp[0]=$pts[0]; $nsp[1]=$pts[1];
+                        $nsp[2]=$pts[0]+$ssh; $nsp[3]=$pts[1]-$ssv;
+                        $nsp[4]=$pts[6]+$ssh; $nsp[5]=$pts[7]-$ssv;
+                        $nsp[10]=$pts[6]+1; $nsp[11]=$pts[7];
+                    }
+
+                    if( $j === $this->nbrplots-1 ) {
+                        // If this is the last plot of the bar and
+                        // the total value is larger than 0 then we
+                        // add the shadow.
+                        if( is_array($this->bar_shadow_color) ) {
+                            $numcolors = count($this->bar_shadow_color);
+                            if( $numcolors == 0 ) {
+                                JpGraphError::RaiseL(2013);//('You have specified an empty array for shadow colors in the bar plot.');
+                            }
+                            $img->PushColor($this->bar_shadow_color[$i % $numcolors]);
+                        }
+                        else {
+                            $img->PushColor($this->bar_shadow_color);
+                        }
+
+                        if( $accy > 0 ) {
+                            $sp[4]=$pts[4]+$ssh; $sp[5]=$pts[5]-$ssv;
+                            $sp[6]=$pts[2]+$ssh; $sp[7]=$pts[3]-$ssv;
+                            $sp[8]=$pts[2]; $sp[9]=$pts[3]-1;
+                            $sp[10]=$pts[4]+1; $sp[11]=$pts[5];
+                            $img->FilledPolygon($sp,4);
+                        }
+                        elseif( $accy_neg < 0 ) {
+                            $nsp[6]=$pts[4]+$ssh; $nsp[7]=$pts[5]-$ssv;
+                            $nsp[8]=$pts[4]+1; $nsp[9]=$pts[5];
+                            $img->FilledPolygon($nsp,4);
+                        }
+                        $img->PopColor();
+                    }
+                }
+
+
+                // If value is NULL or 0, then don't draw a bar at all
+                if ($this->plots[$j]->coords[0][$i] == 0 ) continue;
+
+                if( $this->plots[$j]->grad ) {
+                    if( $grad === null ) {
+                        $grad = new Gradient($img);
+                    }
+                    if( is_array($this->plots[$j]->grad_fromcolor) ) {
+                        // The first argument (grad_fromcolor) can be either an array or a single color. If it is an array
+                        // then we have two choices. It can either a) be a single color specified as an RGB triple or it can be
+                        // an array to specify both (from, to style) for each individual bar. The way to know the difference is
+                        // to investgate the first element. If this element is an integer [0,255] then we assume it is an RGB
+                        // triple.
+                        $ng = count($this->plots[$j]->grad_fromcolor);
+                        if( $ng === 3 ) {
+                            if( is_numeric($this->plots[$j]->grad_fromcolor[0]) && $this->plots[$j]->grad_fromcolor[0] > 0 &&
+                                 $this->plots[$j]->grad_fromcolor[0] < 256 ) {
+                                // RGB Triple
+                                $fromcolor = $this->plots[$j]->grad_fromcolor;
+                                $tocolor = $this->plots[$j]->grad_tocolor;
+                                $style = $this->plots[$j]->grad_style;
+                            }
+                            else {
+                                $fromcolor = $this->plots[$j]->grad_fromcolor[$i % $ng][0];
+                                $tocolor = $this->plots[$j]->grad_fromcolor[$i % $ng][1];
+                                $style = $this->plots[$j]->grad_fromcolor[$i % $ng][2];
+                            }
+                        }
+                        else {
+                            $fromcolor = $this->plots[$j]->grad_fromcolor[$i % $ng][0];
+                            $tocolor = $this->plots[$j]->grad_fromcolor[$i % $ng][1];
+                            $style = $this->plots[$j]->grad_fromcolor[$i % $ng][2];
+                        }
+                        $grad->FilledRectangle($pts[2],$pts[3],
+                                               $pts[6],$pts[7],
+                                               $fromcolor,$tocolor,$style);
+                    }
+                    else {
+                        $grad->FilledRectangle($pts[2],$pts[3],
+                                               $pts[6],$pts[7],
+                                               $this->plots[$j]->grad_fromcolor,
+                                               $this->plots[$j]->grad_tocolor,
+                                               $this->plots[$j]->grad_style);
+                    }
+                } else {
+                    if (is_array($this->plots[$j]->fill_color) ) {
+                        $numcolors = count($this->plots[$j]->fill_color);
+                        $fillcolor = $this->plots[$j]->fill_color[$i % $numcolors];
+                        // If the bar is specified to be non filled then the fill color is false
+                        if( $fillcolor !== false ) {
+                            $img->SetColor($this->plots[$j]->fill_color[$i % $numcolors]);
+                        }
+                    }
+                    else {
+                        $fillcolor = $this->plots[$j]->fill_color;
+                        if( $fillcolor !== false ) {
+                            $img->SetColor($this->plots[$j]->fill_color);
+                        }
+                    }
+                    if( $fillcolor !== false ) {
+                        $img->FilledPolygon($pts);
+                    }
+                }
+
+                $img->SetColor($this->plots[$j]->color);
+
+                // Stroke the pattern
+                if( $this->plots[$j]->iPattern > -1 ) {
+                    if( $pattern===NULL ) {
+                        $pattern = new RectPatternFactory();
+                    }
+
+                    $prect = $pattern->Create($this->plots[$j]->iPattern,$this->plots[$j]->iPatternColor,1);
+                    $prect->SetDensity($this->plots[$j]->iPatternDensity);
+                    if( $this->plots[$j]->coords[0][$i] < 0 ) {
+                        $rx = $pts[0];
+                        $ry = $pts[1];
+                    }
+                    else {
+                        $rx = $pts[2];
+                        $ry = $pts[3];
+                    }
+                    $width = abs($pts[4]-$pts[0])+1;
+                    $height = abs($pts[1]-$pts[3])+1;
+                    $prect->SetPos(new Rectangle($rx,$ry,$width,$height));
+                    $prect->Stroke($img);
+                }
+
+
+                // CSIM array
+
+                if( $i < count($this->plots[$j]->csimtargets) ) {
+                    // Create the client side image map
+                    $rpts = $img->ArrRotate($pts);
+                    $csimcoord=round($rpts[0]).", ".round($rpts[1]);
+                    for( $k=1; $k < 4; ++$k){
+                        $csimcoord .= ", ".round($rpts[2*$k]).", ".round($rpts[2*$k+1]);
+                    }
+                    if( ! empty($this->plots[$j]->csimtargets[$i]) ) {
+                        $this->csimareas.= '<area shape="poly" coords="'.$csimcoord.'" ';
+                        $this->csimareas.= " href=\"".$this->plots[$j]->csimtargets[$i]."\" ";
+
+                        if( ! empty($this->plots[$j]->csimwintargets[$i]) ) {
+                            $this->csimareas.= " target=\"".$this->plots[$j]->csimwintargets[$i]."\" ";
+                        }
+
+                        $sval='';
+                        if( !empty($this->plots[$j]->csimalts[$i]) ) {
+                            $sval=sprintf($this->plots[$j]->csimalts[$i],$this->plots[$j]->coords[0][$i]);
+                            $this->csimareas .= " title=\"$sval\" ";
+                        }
+                        $this->csimareas .= " alt=\"$sval\" />\n";
+                    }
+                }
+
+                $pts[] = $pts[0];
+                $pts[] = $pts[1];
+                $img->SetLineWeight($this->plots[$j]->weight);
+                $img->Polygon($pts);
+                $img->SetLineWeight(1);
+            }
+
+            // Daw potential bar around the entire accbar bar
+            if( $this->weight > 0 ) {
+                $y=$yscale->Translate(0);
+                $img->SetColor($this->color);
+                $img->SetLineWeight($this->weight);
+                $img->Rectangle($pts[0],$y,$pts[6],$pts[5]);
+            }
+
+            // Draw labels for each acc.bar
+
+            $x=$pts[2]+($pts[4]-$pts[2])/2;
+            if($this->bar_shadow) $x += $ssh;
+
+            // First stroke the accumulated value for the entire bar
+            // This value is always placed at the top/bottom of the bars
+            if( $accy_neg < 0 ) {
+                $y=$yscale->Translate($accy_neg);
+                $this->value->Stroke($img,$accy_neg,$x,$y);
+            }
+            else {
+                $y=$yscale->Translate($accy);
+                $this->value->Stroke($img,$accy,$x,$y);
+            }
+
+            $accy = 0;
+            $accy_neg = 0;
+            for($j=0; $j < $this->nbrplots; ++$j ) {
+
+                // We don't print 0 values in an accumulated bar plot
+                if( $this->plots[$j]->coords[0][$i] == 0 ) continue;
+
+                if ($this->plots[$j]->coords[0][$i] > 0) {
+                    $yt=$yscale->Translate($this->plots[$j]->coords[0][$i]+$accy);
+                    $accyt=$yscale->Translate($accy);
+                    if(  $this->plots[$j]->valuepos=='center' ) {
+                        $y = $accyt-($accyt-$yt)/2;
+                    }
+                    elseif( $this->plots[$j]->valuepos=='bottom' ) {
+                        $y = $accyt;
+                    }
+                    else { // top or max
+                        $y = $accyt-($accyt-$yt);
+                    }
+                    $accy+=$this->plots[$j]->coords[0][$i];
+                    if(  $this->plots[$j]->valuepos=='center' ) {
+                        $this->plots[$j]->value->SetAlign("center","center");
+                        $this->plots[$j]->value->SetMargin(0);
+                    }
+                    elseif( $this->plots[$j]->valuepos=='bottom' ) {
+                        $this->plots[$j]->value->SetAlign('center','bottom');
+                        $this->plots[$j]->value->SetMargin(2);
+                    }
+                    else {
+                        $this->plots[$j]->value->SetAlign('center','top');
+                        $this->plots[$j]->value->SetMargin(1);
+                    }
+                } else {
+                    $yt=$yscale->Translate($this->plots[$j]->coords[0][$i]+$accy_neg);
+                    $accyt=$yscale->Translate($accy_neg);
+                    $accy_neg+=$this->plots[$j]->coords[0][$i];
+                    if(  $this->plots[$j]->valuepos=='center' ) {
+                        $y = $accyt-($accyt-$yt)/2;
+                    }
+                    elseif( $this->plots[$j]->valuepos=='bottom' ) {
+                        $y = $accyt;
+                    }
+                    else {
+                        $y = $accyt-($accyt-$yt);
+                    }
+                    if(  $this->plots[$j]->valuepos=='center' ) {
+                        $this->plots[$j]->value->SetAlign("center","center");
+                        $this->plots[$j]->value->SetMargin(0);
+                    }
+                    elseif( $this->plots[$j]->valuepos=='bottom' ) {
+                        $this->plots[$j]->value->SetAlign('center',$j==0 ? 'bottom':'top');
+                        $this->plots[$j]->value->SetMargin(-2);
+                    }
+                    else {
+                        $this->plots[$j]->value->SetAlign('center','bottom');
+                        $this->plots[$j]->value->SetMargin(-1);
+                    }
+                }
+                $this->plots[$j]->value->Stroke($img,$this->plots[$j]->coords[0][$i],$x,$y);
+            }
+
+        }
+        return true;
+    }
+} // Class
+
+/* EOF */
+?>
diff --git a/web/classes/jpgraph/jpgraph_canvas.php b/web/classes/jpgraph/jpgraph_canvas.php
new file mode 100755
index 0000000000000000000000000000000000000000..f94295132c6e76df0d1e36a514fcff49ae26ed37
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_canvas.php
@@ -0,0 +1,95 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_CANVAS.PHP
+ // Description: Canvas drawing extension for JpGraph
+ // Created:     2001-01-08
+ // Ver:         $Id: jpgraph_canvas.php 1923 2010-01-11 13:48:49Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+//===================================================
+// CLASS CanvasGraph
+// Description: Creates a simple canvas graph which
+// might be used together with the basic Image drawing
+// primitives. Useful to auickoly produce some arbitrary
+// graphic which benefits from all the functionality in the
+// graph liek caching for example.
+//===================================================
+class CanvasGraph extends Graph {
+    //---------------
+    // CONSTRUCTOR
+    function __construct($aWidth=300,$aHeight=200,$aCachedName="",$timeout=0,$inline=1) {
+        parent::__construct($aWidth,$aHeight,$aCachedName,$timeout,$inline);
+    }
+
+    //---------------
+    // PUBLIC METHODS
+
+    function InitFrame() {
+        $this->StrokePlotArea();
+    }
+
+    // Method description
+    function Stroke($aStrokeFileName="") {
+        if( $this->texts != null ) {
+            for($i=0; $i < count($this->texts); ++$i) {
+                $this->texts[$i]->Stroke($this->img);
+            }
+        }
+        if( $this->iTables !== null ) {
+            for($i=0; $i < count($this->iTables); ++$i) {
+                $this->iTables[$i]->Stroke($this->img);
+            }
+        }
+        $this->StrokeTitles();
+
+        // If the filename is the predefined value = '_csim_special_'
+        // we assume that the call to stroke only needs to do enough
+        // to correctly generate the CSIM maps.
+        // We use this variable to skip things we don't strictly need
+        // to do to generate the image map to improve performance
+        // a best we can. Therefor you will see a lot of tests !$_csim in the
+        // code below.
+        $_csim = ($aStrokeFileName===_CSIM_SPECIALFILE);
+
+        // We need to know if we have stroked the plot in the
+        // GetCSIMareas. Otherwise the CSIM hasn't been generated
+        // and in the case of GetCSIM called before stroke to generate
+        // CSIM without storing an image to disk GetCSIM must call Stroke.
+        $this->iHasStroked = true;
+
+        if( !$_csim ) {
+
+            // Should we do any final image transformation
+            if( $this->iImgTrans ) {
+                if( !class_exists('ImgTrans',false) ) {
+                    require_once('jpgraph_imgtrans.php');
+                }
+
+                $tform = new ImgTrans($this->img->img);
+                $this->img->img = $tform->Skew3D($this->iImgTransHorizon,$this->iImgTransSkewDist,
+                $this->iImgTransDirection,$this->iImgTransHighQ,
+                $this->iImgTransMinSize,$this->iImgTransFillColor,
+                $this->iImgTransBorder);
+            }
+
+
+            // If the filename is given as the special _IMG_HANDLER
+            // then the image handler is returned and the image is NOT
+            // streamed back
+            if( $aStrokeFileName == _IMG_HANDLER ) {
+                return $this->img->img;
+            }
+            else {
+                // Finally stream the generated picture
+                $this->cache->PutAndStream($this->img,$this->cache_name,$this->inline,$aStrokeFileName);
+                return true;
+            }
+        }
+    }
+} // Class
+
+/* EOF */
+?>
diff --git a/web/classes/jpgraph/jpgraph_canvtools.php b/web/classes/jpgraph/jpgraph_canvtools.php
new file mode 100755
index 0000000000000000000000000000000000000000..2290a5bcd600538b7361e75283a799144e9cc581
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_canvtools.php
@@ -0,0 +1,523 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_CANVTOOLS.PHP
+ // Description: Some utilities for text and shape drawing on a canvas
+ // Created:     2002-08-23
+ // Ver:         $Id: jpgraph_canvtools.php 1857 2009-09-28 14:38:14Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+define('CORNER_TOPLEFT',0);
+define('CORNER_TOPRIGHT',1);
+define('CORNER_BOTTOMRIGHT',2);
+define('CORNER_BOTTOMLEFT',3);
+
+
+//===================================================
+// CLASS CanvasScale
+// Description: Define a scale for canvas so we
+// can abstract away with absolute pixels
+//===================================================
+
+class CanvasScale {
+    private $g;
+    private $w,$h;
+    private $ixmin=0,$ixmax=10,$iymin=0,$iymax=10;
+
+    function __construct($graph,$xmin=0,$xmax=10,$ymin=0,$ymax=10) {
+        $this->g = $graph;
+        $this->w = $graph->img->width;
+        $this->h = $graph->img->height;
+        $this->ixmin = $xmin;
+        $this->ixmax = $xmax;
+        $this->iymin = $ymin;
+        $this->iymax = $ymax;
+    }
+
+    function Set($xmin=0,$xmax=10,$ymin=0,$ymax=10) {
+        $this->ixmin = $xmin;
+        $this->ixmax = $xmax;
+        $this->iymin = $ymin;
+        $this->iymax = $ymax;
+    }
+
+    function Get() {
+        return array($this->ixmin,$this->ixmax,$this->iymin,$this->iymax);
+    }
+
+    function Translate($x,$y) {
+        $xp = round(($x-$this->ixmin)/($this->ixmax - $this->ixmin) * $this->w);
+        $yp = round(($y-$this->iymin)/($this->iymax - $this->iymin) * $this->h);
+        return array($xp,$yp);
+    }
+
+    function TranslateX($x) {
+        $xp = round(($x-$this->ixmin)/($this->ixmax - $this->ixmin) * $this->w);
+        return $xp;
+    }
+
+    function TranslateY($y) {
+        $yp = round(($y-$this->iymin)/($this->iymax - $this->iymin) * $this->h);
+        return $yp;
+    }
+
+}
+
+
+//===================================================
+// CLASS Shape
+// Description: Methods to draw shapes on canvas
+//===================================================
+class Shape {
+    private $img,$scale;
+
+    function __construct($aGraph,$scale) {
+        $this->img = $aGraph->img;
+        $this->img->SetColor('black');
+        $this->scale = $scale;
+    }
+
+    function SetColor($aColor) {
+        $this->img->SetColor($aColor);
+    }
+
+    function Line($x1,$y1,$x2,$y2) {
+        list($x1,$y1) = $this->scale->Translate($x1,$y1);
+        list($x2,$y2) = $this->scale->Translate($x2,$y2);
+        $this->img->Line($x1,$y1,$x2,$y2);
+    }
+
+    function SetLineWeight($aWeight) {
+        $this->img->SetLineWeight($aWeight);
+    }
+
+    function Polygon($p,$aClosed=false) {
+        $n=count($p);
+        for($i=0; $i < $n; $i+=2 ) {
+            $p[$i]   = $this->scale->TranslateX($p[$i]);
+            $p[$i+1] = $this->scale->TranslateY($p[$i+1]);
+        }
+        $this->img->Polygon($p,$aClosed);
+    }
+
+    function FilledPolygon($p) {
+        $n=count($p);
+        for($i=0; $i < $n; $i+=2 ) {
+            $p[$i]   = $this->scale->TranslateX($p[$i]);
+            $p[$i+1] = $this->scale->TranslateY($p[$i+1]);
+        }
+        $this->img->FilledPolygon($p);
+    }
+
+
+    // Draw a bezier curve with defining points in the $aPnts array
+    // using $aSteps steps.
+    // 0=x0, 1=y0
+    // 2=x1, 3=y1
+    // 4=x2, 5=y2
+    // 6=x3, 7=y3
+    function Bezier($p,$aSteps=40) {
+        $x0 = $p[0];
+        $y0 = $p[1];
+        // Calculate coefficients
+        $cx = 3*($p[2]-$p[0]);
+        $bx = 3*($p[4]-$p[2])-$cx;
+        $ax = $p[6]-$p[0]-$cx-$bx;
+        $cy = 3*($p[3]-$p[1]);
+        $by = 3*($p[5]-$p[3])-$cy;
+        $ay = $p[7]-$p[1]-$cy-$by;
+
+        // Step size
+        $delta = 1.0/$aSteps;
+
+        $x_old = $x0;
+        $y_old = $y0;
+        for($t=$delta; $t<=1.0; $t+=$delta) {
+            $tt = $t*$t; $ttt=$tt*$t;
+            $x  = $ax*$ttt + $bx*$tt + $cx*$t + $x0;
+            $y = $ay*$ttt + $by*$tt + $cy*$t + $y0;
+            $this->Line($x_old,$y_old,$x,$y);
+            $x_old = $x;
+            $y_old = $y;
+        }
+        $this->Line($x_old,$y_old,$p[6],$p[7]);
+    }
+
+    function Rectangle($x1,$y1,$x2,$y2) {
+        list($x1,$y1) = $this->scale->Translate($x1,$y1);
+        list($x2,$y2)   = $this->scale->Translate($x2,$y2);
+        $this->img->Rectangle($x1,$y1,$x2,$y2);
+    }
+
+    function FilledRectangle($x1,$y1,$x2,$y2) {
+        list($x1,$y1) = $this->scale->Translate($x1,$y1);
+        list($x2,$y2)   = $this->scale->Translate($x2,$y2);
+        $this->img->FilledRectangle($x1,$y1,$x2,$y2);
+    }
+
+    function Circle($x1,$y1,$r) {
+        list($x1,$y1) = $this->scale->Translate($x1,$y1);
+        if( $r >= 0 )
+        $r   = $this->scale->TranslateX($r);
+        else
+        $r = -$r;
+        $this->img->Circle($x1,$y1,$r);
+    }
+
+    function FilledCircle($x1,$y1,$r) {
+        list($x1,$y1) = $this->scale->Translate($x1,$y1);
+        if( $r >= 0 )
+        $r   = $this->scale->TranslateX($r);
+        else
+        $r = -$r;
+        $this->img->FilledCircle($x1,$y1,$r);
+    }
+
+    function RoundedRectangle($x1,$y1,$x2,$y2,$r=null) {
+        list($x1,$y1) = $this->scale->Translate($x1,$y1);
+        list($x2,$y2)   = $this->scale->Translate($x2,$y2);
+
+        if( $r == null )
+        $r = 5;
+        elseif( $r >= 0 )
+        $r = $this->scale->TranslateX($r);
+        else
+        $r = -$r;
+        $this->img->RoundedRectangle($x1,$y1,$x2,$y2,$r);
+    }
+
+    function FilledRoundedRectangle($x1,$y1,$x2,$y2,$r=null) {
+        list($x1,$y1) = $this->scale->Translate($x1,$y1);
+        list($x2,$y2)   = $this->scale->Translate($x2,$y2);
+
+        if( $r == null )
+        $r = 5;
+        elseif( $r > 0 )
+        $r = $this->scale->TranslateX($r);
+        else
+        $r = -$r;
+        $this->img->FilledRoundedRectangle($x1,$y1,$x2,$y2,$r);
+    }
+
+    function ShadowRectangle($x1,$y1,$x2,$y2,$fcolor=false,$shadow_width=null,$shadow_color=array(102,102,102)) {
+        list($x1,$y1) = $this->scale->Translate($x1,$y1);
+        list($x2,$y2) = $this->scale->Translate($x2,$y2);
+        if( $shadow_width == null )
+        $shadow_width=4;
+        else
+        $shadow_width=$this->scale->TranslateX($shadow_width);
+        $this->img->ShadowRectangle($x1,$y1,$x2,$y2,$fcolor,$shadow_width,$shadow_color);
+    }
+
+    function SetTextAlign($halign,$valign="bottom") {
+        $this->img->SetTextAlign($halign,$valign="bottom");
+    }
+
+    function StrokeText($x1,$y1,$txt,$dir=0,$paragraph_align="left") {
+        list($x1,$y1) = $this->scale->Translate($x1,$y1);
+        $this->img->StrokeText($x1,$y1,$txt,$dir,$paragraph_align);
+    }
+
+    // A rounded rectangle where one of the corner has been moved "into" the
+    // rectangle 'iw' width and 'ih' height. Corners:
+    // 0=Top left, 1=top right, 2=bottom right, 3=bottom left
+    function IndentedRectangle($xt,$yt,$w,$h,$iw=0,$ih=0,$aCorner=3,$aFillColor="",$r=4) {
+
+        list($xt,$yt) = $this->scale->Translate($xt,$yt);
+        list($w,$h)   = $this->scale->Translate($w,$h);
+        list($iw,$ih) = $this->scale->Translate($iw,$ih);
+
+        $xr = $xt + $w - 0;
+        $yl = $yt + $h - 0;
+
+        switch( $aCorner ) {
+            case 0: // Upper left
+                 
+                // Bottom line, left &  right arc
+                $this->img->Line($xt+$r,$yl,$xr-$r,$yl);
+                $this->img->Arc($xt+$r,$yl-$r,$r*2,$r*2,90,180);
+                $this->img->Arc($xr-$r,$yl-$r,$r*2,$r*2,0,90);
+
+                // Right line, Top right arc
+                $this->img->Line($xr,$yt+$r,$xr,$yl-$r);
+                $this->img->Arc($xr-$r,$yt+$r,$r*2,$r*2,270,360);
+
+                // Top line, Top left arc
+                $this->img->Line($xt+$iw+$r,$yt,$xr-$r,$yt);
+                $this->img->Arc($xt+$iw+$r,$yt+$r,$r*2,$r*2,180,270);
+
+                // Left line
+                $this->img->Line($xt,$yt+$ih+$r,$xt,$yl-$r);
+
+                // Indent horizontal, Lower left arc
+                $this->img->Line($xt+$r,$yt+$ih,$xt+$iw-$r,$yt+$ih);
+                $this->img->Arc($xt+$r,$yt+$ih+$r,$r*2,$r*2,180,270);
+
+                // Indent vertical, Indent arc
+                $this->img->Line($xt+$iw,$yt+$r,$xt+$iw,$yt+$ih-$r);
+                $this->img->Arc($xt+$iw-$r,$yt+$ih-$r,$r*2,$r*2,0,90);
+
+                if( $aFillColor != '' ) {
+                    $bc = $this->img->current_color_name;
+                    $this->img->PushColor($aFillColor);
+                    $this->img->FillToBorder($xr-$r,$yl-$r,$bc);
+                    $this->img->PopColor();
+                }
+
+                break;
+
+            case 1: // Upper right
+
+                // Bottom line, left &  right arc
+                $this->img->Line($xt+$r,$yl,$xr-$r,$yl);
+                $this->img->Arc($xt+$r,$yl-$r,$r*2,$r*2,90,180);
+                $this->img->Arc($xr-$r,$yl-$r,$r*2,$r*2,0,90);
+
+                // Left line, Top left arc
+                $this->img->Line($xt,$yt+$r,$xt,$yl-$r);
+                $this->img->Arc($xt+$r,$yt+$r,$r*2,$r*2,180,270);
+
+                // Top line, Top right arc
+                $this->img->Line($xt+$r,$yt,$xr-$iw-$r,$yt);
+                $this->img->Arc($xr-$iw-$r,$yt+$r,$r*2,$r*2,270,360);
+
+                // Right line
+                $this->img->Line($xr,$yt+$ih+$r,$xr,$yl-$r);
+
+                // Indent horizontal, Lower right arc
+                $this->img->Line($xr-$iw+$r,$yt+$ih,$xr-$r,$yt+$ih);
+                $this->img->Arc($xr-$r,$yt+$ih+$r,$r*2,$r*2,270,360);
+
+                // Indent vertical, Indent arc
+                $this->img->Line($xr-$iw,$yt+$r,$xr-$iw,$yt+$ih-$r);
+                $this->img->Arc($xr-$iw+$r,$yt+$ih-$r,$r*2,$r*2,90,180);
+
+                if( $aFillColor != '' ) {
+                    $bc = $this->img->current_color_name;
+                    $this->img->PushColor($aFillColor);
+                    $this->img->FillToBorder($xt+$r,$yl-$r,$bc);
+                    $this->img->PopColor();
+                }
+
+                break;
+
+            case 2: // Lower right
+                // Top line, Top left & Top right arc
+                $this->img->Line($xt+$r,$yt,$xr-$r,$yt);
+                $this->img->Arc($xt+$r,$yt+$r,$r*2,$r*2,180,270);
+                $this->img->Arc($xr-$r,$yt+$r,$r*2,$r*2,270,360);
+
+                // Left line, Bottom left arc
+                $this->img->Line($xt,$yt+$r,$xt,$yl-$r);
+                $this->img->Arc($xt+$r,$yl-$r,$r*2,$r*2,90,180);
+
+                // Bottom line, Bottom right arc
+                $this->img->Line($xt+$r,$yl,$xr-$iw-$r,$yl);
+                $this->img->Arc($xr-$iw-$r,$yl-$r,$r*2,$r*2,0,90);
+
+                // Right line
+                $this->img->Line($xr,$yt+$r,$xr,$yl-$ih-$r);
+                 
+                // Indent horizontal, Lower right arc
+                $this->img->Line($xr-$r,$yl-$ih,$xr-$iw+$r,$yl-$ih);
+                $this->img->Arc($xr-$r,$yl-$ih-$r,$r*2,$r*2,0,90);
+
+                // Indent vertical, Indent arc
+                $this->img->Line($xr-$iw,$yl-$r,$xr-$iw,$yl-$ih+$r);
+                $this->img->Arc($xr-$iw+$r,$yl-$ih+$r,$r*2,$r*2,180,270);
+
+                if( $aFillColor != '' ) {
+                    $bc = $this->img->current_color_name;
+                    $this->img->PushColor($aFillColor);
+                    $this->img->FillToBorder($xt+$r,$yt+$r,$bc);
+                    $this->img->PopColor();
+                }
+
+                break;
+
+            case 3: // Lower left
+                // Top line, Top left & Top right arc
+                $this->img->Line($xt+$r,$yt,$xr-$r,$yt);
+                $this->img->Arc($xt+$r,$yt+$r,$r*2,$r*2,180,270);
+                $this->img->Arc($xr-$r,$yt+$r,$r*2,$r*2,270,360);
+
+                // Right line, Bottom right arc
+                $this->img->Line($xr,$yt+$r,$xr,$yl-$r);
+                $this->img->Arc($xr-$r,$yl-$r,$r*2,$r*2,0,90);
+
+                // Bottom line, Bottom left arc
+                $this->img->Line($xt+$iw+$r,$yl,$xr-$r,$yl);
+                $this->img->Arc($xt+$iw+$r,$yl-$r,$r*2,$r*2,90,180);
+
+                // Left line
+                $this->img->Line($xt,$yt+$r,$xt,$yl-$ih-$r);
+                 
+                // Indent horizontal, Lower left arc
+                $this->img->Line($xt+$r,$yl-$ih,$xt+$iw-$r,$yl-$ih);
+                $this->img->Arc($xt+$r,$yl-$ih-$r,$r*2,$r*2,90,180);
+
+                // Indent vertical, Indent arc
+                $this->img->Line($xt+$iw,$yl-$ih+$r,$xt+$iw,$yl-$r);
+                $this->img->Arc($xt+$iw-$r,$yl-$ih+$r,$r*2,$r*2,270,360);
+
+                if( $aFillColor != '' ) {
+                    $bc = $this->img->current_color_name;
+                    $this->img->PushColor($aFillColor);
+                    $this->img->FillToBorder($xr-$r,$yt+$r,$bc);
+                    $this->img->PopColor();
+                }
+
+                break;
+        }
+    }
+}
+
+
+//===================================================
+// CLASS RectangleText
+// Description: Draws a text paragraph inside a
+// rounded, possible filled, rectangle.
+//===================================================
+class CanvasRectangleText {
+    private $ix,$iy,$iw,$ih,$ir=4;
+    private $iTxt,$iColor='black',$iFillColor='',$iFontColor='black';
+    private $iParaAlign='center';
+    private $iAutoBoxMargin=5;
+    private $iShadowWidth=3,$iShadowColor='';
+
+    function __construct($aTxt='',$xl=0,$yt=0,$w=0,$h=0) {
+        $this->iTxt = new Text($aTxt);
+        $this->ix = $xl;
+        $this->iy = $yt;
+        $this->iw = $w;
+        $this->ih = $h;
+    }
+
+    function SetShadow($aColor='gray',$aWidth=3) {
+        $this->iShadowColor = $aColor;
+        $this->iShadowWidth = $aWidth;
+    }
+
+    function SetFont($FontFam,$aFontStyle,$aFontSize=12) {
+        $this->iTxt->SetFont($FontFam,$aFontStyle,$aFontSize);
+    }
+
+    function SetTxt($aTxt) {
+        $this->iTxt->Set($aTxt);
+    }
+
+    function ParagraphAlign($aParaAlign) {
+        $this->iParaAlign = $aParaAlign;
+    }
+
+    function SetFillColor($aFillColor) {
+        $this->iFillColor = $aFillColor;
+    }
+
+    function SetAutoMargin($aMargin) {
+        $this->iAutoBoxMargin=$aMargin;
+    }
+
+    function SetColor($aColor) {
+        $this->iColor = $aColor;
+    }
+
+    function SetFontColor($aColor) {
+        $this->iFontColor = $aColor;
+    }
+
+    function SetPos($xl=0,$yt=0,$w=0,$h=0) {
+        $this->ix = $xl;
+        $this->iy = $yt;
+        $this->iw = $w;
+        $this->ih = $h;
+    }
+
+    function Pos($xl=0,$yt=0,$w=0,$h=0) {
+        $this->ix = $xl;
+        $this->iy = $yt;
+        $this->iw = $w;
+        $this->ih = $h;
+    }
+
+    function Set($aTxt,$xl,$yt,$w=0,$h=0) {
+        $this->iTxt->Set($aTxt);
+        $this->ix = $xl;
+        $this->iy = $yt;
+        $this->iw = $w;
+        $this->ih = $h;
+    }
+
+    function SetCornerRadius($aRad=5) {
+        $this->ir = $aRad;
+    }
+
+    function Stroke($aImg,$scale) {
+
+        // If coordinates are specifed as negative this means we should
+        // treat them as abolsute (pixels) coordinates
+        if( $this->ix > 0 ) {
+            $this->ix = $scale->TranslateX($this->ix) ;
+        }
+        else {
+            $this->ix = -$this->ix;
+        }
+
+        if( $this->iy > 0 ) {
+            $this->iy = $scale->TranslateY($this->iy) ;
+        }
+        else {
+            $this->iy = -$this->iy;
+        }
+         
+        list($this->iw,$this->ih) = $scale->Translate($this->iw,$this->ih) ;
+
+        if( $this->iw == 0 )
+        $this->iw = round($this->iTxt->GetWidth($aImg) + $this->iAutoBoxMargin);
+        if( $this->ih == 0 ) {
+            $this->ih = round($this->iTxt->GetTextHeight($aImg) + $this->iAutoBoxMargin);
+        }
+
+        if( $this->iShadowColor != '' ) {
+            $aImg->PushColor($this->iShadowColor);
+            $aImg->FilledRoundedRectangle($this->ix+$this->iShadowWidth,
+            $this->iy+$this->iShadowWidth,
+            $this->ix+$this->iw-1+$this->iShadowWidth,
+            $this->iy+$this->ih-1+$this->iShadowWidth,
+            $this->ir);
+            $aImg->PopColor();
+        }
+
+        if( $this->iFillColor != '' ) {
+            $aImg->PushColor($this->iFillColor);
+            $aImg->FilledRoundedRectangle($this->ix,$this->iy,
+            $this->ix+$this->iw-1,
+            $this->iy+$this->ih-1,
+            $this->ir);
+            $aImg->PopColor();
+        }
+
+        if( $this->iColor != '' ) {
+            $aImg->PushColor($this->iColor);
+            $aImg->RoundedRectangle($this->ix,$this->iy,
+            $this->ix+$this->iw-1,
+            $this->iy+$this->ih-1,
+            $this->ir);
+            $aImg->PopColor();
+        }
+
+        $this->iTxt->Align('center','center');
+        $this->iTxt->ParagraphAlign($this->iParaAlign);
+        $this->iTxt->SetColor($this->iFontColor);
+        $this->iTxt->Stroke($aImg, $this->ix+$this->iw/2, $this->iy+$this->ih/2);
+
+        return array($this->iw, $this->ih);
+
+    }
+
+}
+
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_contour.php b/web/classes/jpgraph/jpgraph_contour.php
new file mode 100755
index 0000000000000000000000000000000000000000..760989e5f3a138fa17f55f1c013461447fb98f40
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_contour.php
@@ -0,0 +1,587 @@
+<?php
+/*=======================================================================
+// File:        JPGRAPH_CONTOUR.PHP
+// Description: Contour plot
+// Created:     2009-03-08
+// Ver:         $Id: jpgraph_contour.php 1870 2009-09-29 04:24:18Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+*/
+require_once('jpgraph_meshinterpolate.inc.php');
+define('HORIZ_EDGE',0);
+define('VERT_EDGE',1);
+
+/**
+ * This class encapsulates the core contour plot algorithm. It will find the path
+ * of the specified isobars in the data matrix specified. It is assumed that the
+ * data matrix models an equspaced X-Y mesh of datavalues corresponding to the Z
+ * values.
+ *
+ */
+class Contour {
+
+    private $dataPoints = array();
+    private $nbrCols=0,$nbrRows=0;
+    private $horizEdges = array(), $vertEdges=array();
+    private $isobarValues = array();
+    private $stack = null;
+    private $isobarCoord = array();
+    private $nbrIsobars = 10, $isobarColors = array();
+    private $invert = true;
+    private $highcontrast = false, $highcontrastbw = false;
+
+    /**
+     * Create a new contour level "algorithm machine".
+     * @param $aMatrix    The values to find the contour from
+     * @param $aIsobars Mixed. If integer it determines the number of isobars to be used. The levels are determined
+     * automatically as equdistance between the min and max value of the matrice.
+     * If $aIsobars is an array then this is interpretated as an array of values to be used as isobars in the
+     * contour plot.
+     * @return an instance of the contour algorithm
+     */
+    function __construct($aMatrix,$aIsobars=10, $aColors=null) {
+
+        $this->nbrRows = count($aMatrix);
+        $this->nbrCols = count($aMatrix[0]);
+        $this->dataPoints = $aMatrix;
+
+        if( is_array($aIsobars) ) {
+            // use the isobar values supplied
+            $this->nbrIsobars = count($aIsobars);
+            $this->isobarValues = $aIsobars;
+        }
+        else {
+            // Determine the isobar values automatically
+            $this->nbrIsobars = $aIsobars;
+            list($min,$max) = $this->getMinMaxVal();
+            $stepSize = ($max-$min) / $aIsobars ;
+            $isobar = $min+$stepSize/2;
+            for ($i = 0; $i < $aIsobars; $i++) {
+                $this->isobarValues[$i] = $isobar;
+                $isobar += $stepSize;
+            }
+        }
+
+        if( $aColors !== null && count($aColors) > 0 ) {
+
+            if( !is_array($aColors) ) {
+                JpGraphError::RaiseL(28001);
+                //'Third argument to Contour must be an array of colors.'
+            }
+
+            if( count($aColors) != count($this->isobarValues) ) {
+                JpGraphError::RaiseL(28002);
+                //'Number of colors must equal the number of isobar lines specified';
+            }
+
+            $this->isobarColors = $aColors;
+        }
+    }
+
+    /**
+     * Flip the plot around the Y-coordinate. This has the same affect as flipping the input
+     * data matrice
+     *
+     * @param $aFlg If true the the vertice in input data matrice position (0,0) corresponds to the top left
+     * corner of teh plot otherwise it will correspond to the bottom left corner (a horizontal flip)
+     */
+    function SetInvert($aFlg=true) {
+        $this->invert = $aFlg;
+    }
+
+    /**
+     * Find the min and max values in the data matrice
+     *
+     * @return array(min_value,max_value)
+     */
+    function getMinMaxVal() {
+        $min = $this->dataPoints[0][0];
+        $max = $this->dataPoints[0][0];
+        for ($i = 0; $i < $this->nbrRows; $i++) {
+            if( ($mi=min($this->dataPoints[$i])) < $min )  $min = $mi;
+            if( ($ma=max($this->dataPoints[$i])) > $max )  $max = $ma;
+        }
+        return array($min,$max);
+    }
+
+    /**
+     * Reset the two matrices that keeps track on where the isobars crosses the
+     * horizontal and vertical edges
+     */
+    function resetEdgeMatrices() {
+        for ($k = 0; $k < 2; $k++) {
+            for ($i = 0; $i <= $this->nbrRows; $i++) {
+                for ($j = 0; $j <= $this->nbrCols; $j++) {
+                    $this->edges[$k][$i][$j] = false;
+                }
+            }
+        }
+    }
+
+    /**
+     * Determine if the specified isobar crosses the horizontal edge specified by its row and column
+     *
+     * @param $aRow Row index of edge to be checked
+     * @param $aCol Col index of edge to be checked
+     * @param $aIsobar Isobar value
+     * @return true if the isobar is crossing this edge
+     */
+    function isobarHCrossing($aRow,$aCol,$aIsobar) {
+
+        if( $aCol >= $this->nbrCols-1 ) {
+            JpGraphError::RaiseL(28003,$aCol);
+            //'ContourPlot Internal Error: isobarHCrossing: Coloumn index too large (%d)'
+        }
+        if( $aRow >= $this->nbrRows ) {
+            JpGraphError::RaiseL(28004,$aRow);
+            //'ContourPlot Internal Error: isobarHCrossing: Row index too large (%d)'
+        }
+
+        $v1 = $this->dataPoints[$aRow][$aCol];
+        $v2 = $this->dataPoints[$aRow][$aCol+1];
+
+        return ($aIsobar-$v1)*($aIsobar-$v2) < 0 ;
+
+    }
+
+    /**
+     * Determine if the specified isobar crosses the vertical edge specified by its row and column
+     *
+     * @param $aRow Row index of edge to be checked
+     * @param $aCol Col index of edge to be checked
+     * @param $aIsobar Isobar value
+     * @return true if the isobar is crossing this edge
+     */
+    function isobarVCrossing($aRow,$aCol,$aIsobar) {
+
+        if( $aRow >= $this->nbrRows-1) {
+            JpGraphError::RaiseL(28005,$aRow);
+            //'isobarVCrossing: Row index too large
+        }
+        if( $aCol >= $this->nbrCols ) {
+            JpGraphError::RaiseL(28006,$aCol);
+            //'isobarVCrossing: Col index too large
+        }
+
+        $v1 = $this->dataPoints[$aRow][$aCol];
+        $v2 = $this->dataPoints[$aRow+1][$aCol];
+
+        return ($aIsobar-$v1)*($aIsobar-$v2) < 0 ;
+
+    }
+
+    /**
+     * Determine all edges, horizontal and vertical that the specified isobar crosses. The crossings
+     * are recorded in the two edge matrices.
+     *
+     * @param $aIsobar The value of the isobar to be checked
+     */
+    function determineIsobarEdgeCrossings($aIsobar) {
+
+        $ib = $this->isobarValues[$aIsobar];
+
+        for ($i = 0; $i < $this->nbrRows-1; $i++) {
+            for ($j = 0; $j < $this->nbrCols-1; $j++) {
+                $this->edges[HORIZ_EDGE][$i][$j] = $this->isobarHCrossing($i,$j,$ib);
+                $this->edges[VERT_EDGE][$i][$j] = $this->isobarVCrossing($i,$j,$ib);
+            }
+        }
+
+        // We now have the bottom and rightmost edges unsearched
+        for ($i = 0; $i < $this->nbrRows-1; $i++) {
+            $this->edges[VERT_EDGE][$i][$j] = $this->isobarVCrossing($i,$this->nbrCols-1,$ib);
+        }
+        for ($j = 0; $j < $this->nbrCols-1; $j++) {
+            $this->edges[HORIZ_EDGE][$i][$j] = $this->isobarHCrossing($this->nbrRows-1,$j,$ib);
+        }
+
+    }
+
+    /**
+     * Return the normalized coordinates for the crossing of the specified edge with the specified
+     * isobar- The crossing is simpy detrmined with a linear interpolation between the two vertices
+     * on each side of the edge and the value of the isobar
+     *
+     * @param $aRow Row of edge
+     * @param $aCol Column of edge
+     * @param $aEdgeDir Determine if this is a horizontal or vertical edge
+     * @param $ib The isobar value
+     * @return unknown_type
+     */
+    function getCrossingCoord($aRow,$aCol,$aEdgeDir,$aIsobarVal) {
+
+        // In order to avoid numerical problem when two vertices are very close
+        // we have to check and avoid dividing by close to zero denumerator.
+        if( $aEdgeDir == HORIZ_EDGE ) {
+            $d = abs($this->dataPoints[$aRow][$aCol] - $this->dataPoints[$aRow][$aCol+1]);
+            if( $d > 0.001 ) {
+                $xcoord = $aCol + abs($aIsobarVal - $this->dataPoints[$aRow][$aCol]) / $d;
+            }
+            else {
+                $xcoord = $aCol;
+            }
+            $ycoord = $aRow;
+        }
+        else {
+            $d = abs($this->dataPoints[$aRow][$aCol] - $this->dataPoints[$aRow+1][$aCol]);
+            if( $d > 0.001 ) {
+                $ycoord = $aRow + abs($aIsobarVal - $this->dataPoints[$aRow][$aCol]) / $d;
+            }
+            else {
+                $ycoord = $aRow;
+            }
+            $xcoord = $aCol;
+        }
+        if( $this->invert ) {
+            $ycoord = $this->nbrRows-1 - $ycoord;
+        }
+        return array($xcoord,$ycoord);
+
+    }
+
+    /**
+     * In order to avoid all kinds of unpleasent extra checks and complex boundary
+     * controls for the degenerated case where the contour levels exactly crosses
+     * one of the vertices we add a very small delta (0.1%) to the data point value.
+     * This has no visible affect but it makes the code sooooo much cleaner.
+     *
+     */
+    function adjustDataPointValues() {
+
+        $ni = count($this->isobarValues);
+        for ($k = 0; $k < $ni; $k++) {
+            $ib = $this->isobarValues[$k];
+            for ($row = 0 ; $row < $this->nbrRows-1; ++$row) {
+                for ($col = 0 ; $col < $this->nbrCols-1; ++$col ) {
+                    if( abs($this->dataPoints[$row][$col] - $ib) < 0.0001 ) {
+                        $this->dataPoints[$row][$col] += $this->dataPoints[$row][$col]*0.001;
+                    }
+                }
+            }
+        }
+
+    }
+
+    /**
+     * @param $aFlg
+     * @param $aBW
+     * @return unknown_type
+     */
+    function UseHighContrastColor($aFlg=true,$aBW=false) {
+        $this->highcontrast = $aFlg;
+        $this->highcontrastbw = $aBW;
+    }
+
+    /**
+     * Calculate suitable colors for each defined isobar
+     *
+     */
+    function CalculateColors() {
+        if ( $this->highcontrast ) {
+            if ( $this->highcontrastbw ) {
+                for ($ib = 0; $ib < $this->nbrIsobars; $ib++) {
+                    $this->isobarColors[$ib] = 'black';
+                }
+            }
+            else {
+                // Use only blue/red scale
+                $step = round(255/($this->nbrIsobars-1));
+                for ($ib = 0; $ib < $this->nbrIsobars; $ib++) {
+                    $this->isobarColors[$ib] = array($ib*$step, 50, 255-$ib*$step);
+                }
+            }
+        }
+        else {
+            $n = $this->nbrIsobars;
+            $v = 0; $step = 1 / ($this->nbrIsobars-1);
+            for ($ib = 0; $ib < $this->nbrIsobars; $ib++) {
+                $this->isobarColors[$ib] = RGB::GetSpectrum($v);
+                $v += $step;
+            }
+        }
+    }
+
+    /**
+     * This is where the main work is done. For each isobar the crossing of the edges are determined
+     * and then each cell is analyzed to find the 0, 2 or 4 crossings. Then the normalized coordinate
+     * for the crossings are determined and pushed on to the isobar stack. When the method is finished
+     * the $isobarCoord will hold one arrayfor each isobar where all the line segments that makes
+     * up the contour plot are stored.
+     *
+     * @return array( $isobarCoord, $isobarValues, $isobarColors )
+     */
+    function getIsobars() {
+
+        $this->adjustDataPointValues();
+
+        for ($isobar = 0; $isobar < $this->nbrIsobars; $isobar++) {
+
+            $ib = $this->isobarValues[$isobar];
+            $this->resetEdgeMatrices();
+            $this->determineIsobarEdgeCrossings($isobar);
+            $this->isobarCoord[$isobar] = array();
+
+            $ncoord = 0;
+
+            for ($row = 0 ; $row < $this->nbrRows-1; ++$row) {
+                for ($col = 0 ; $col < $this->nbrCols-1; ++$col ) {
+
+                    // Find out how many crossings around the edges
+                    $n = 0;
+                    if ( $this->edges[HORIZ_EDGE][$row][$col] )   $neigh[$n++] = array($row,  $col,  HORIZ_EDGE);
+                    if ( $this->edges[HORIZ_EDGE][$row+1][$col] ) $neigh[$n++] = array($row+1,$col,  HORIZ_EDGE);
+                    if ( $this->edges[VERT_EDGE][$row][$col] )    $neigh[$n++] = array($row,  $col,  VERT_EDGE);
+                    if ( $this->edges[VERT_EDGE][$row][$col+1] )  $neigh[$n++] = array($row,  $col+1,VERT_EDGE);
+
+                    if ( $n == 2 ) {
+                        $n1=0; $n2=1;
+                        $this->isobarCoord[$isobar][$ncoord++] = array(
+                        $this->getCrossingCoord($neigh[$n1][0],$neigh[$n1][1],$neigh[$n1][2],$ib),
+                        $this->getCrossingCoord($neigh[$n2][0],$neigh[$n2][1],$neigh[$n2][2],$ib) );
+                    }
+                    elseif ( $n == 4 ) {
+                        // We must determine how to connect the edges either northwest->southeast or
+                        // northeast->southwest. We do that by calculating the imaginary middle value of
+                        // the cell by averaging the for corners. This will compared with the value of the
+                        // top left corner will help determine the orientation of the ridge/creek
+                        $midval = ($this->dataPoints[$row][$col]+$this->dataPoints[$row][$col+1]+$this->dataPoints[$row+1][$col]+$this->dataPoints[$row+1][$col+1])/4;
+                        $v = $this->dataPoints[$row][$col];
+                        if( $midval == $ib ) {
+                            // Orientation "+"
+                            $n1=0; $n2=1; $n3=2; $n4=3;
+                        } elseif ( ($midval > $ib && $v > $ib) ||  ($midval < $ib && $v < $ib) ) {
+                            // Orientation of ridge/valley = "\"
+                            $n1=0; $n2=3; $n3=2; $n4=1;
+                        } elseif ( ($midval > $ib && $v < $ib) ||  ($midval < $ib && $v > $ib) ) {
+                            // Orientation of ridge/valley = "/"
+                            $n1=0; $n2=2; $n3=3; $n4=1;
+                        }
+
+                        $this->isobarCoord[$isobar][$ncoord++] = array(
+                        $this->getCrossingCoord($neigh[$n1][0],$neigh[$n1][1],$neigh[$n1][2],$ib),
+                        $this->getCrossingCoord($neigh[$n2][0],$neigh[$n2][1],$neigh[$n2][2],$ib) );
+
+                        $this->isobarCoord[$isobar][$ncoord++] = array(
+                        $this->getCrossingCoord($neigh[$n3][0],$neigh[$n3][1],$neigh[$n3][2],$ib),
+                        $this->getCrossingCoord($neigh[$n4][0],$neigh[$n4][1],$neigh[$n4][2],$ib) );
+
+                    }
+                }
+            }
+        }
+
+        if( count($this->isobarColors) == 0 ) {
+            // No manually specified colors. Calculate them automatically.
+            $this->CalculateColors();
+        }
+        return array( $this->isobarCoord, $this->isobarValues, $this->isobarColors );
+    }
+}
+
+
+/**
+ * This class represent a plotting of a contour outline of data given as a X-Y matrice
+ *
+ */
+class ContourPlot extends Plot {
+
+    private $contour, $contourCoord, $contourVal, $contourColor;
+    private $nbrCountours = 0 ;
+    private $dataMatrix = array();
+    private $invertLegend = false;
+    private $interpFactor = 1;
+    private $flipData = false;
+    private $isobar = 10;
+    private $showLegend = false;
+    private $highcontrast = false, $highcontrastbw = false;
+    private $manualIsobarColors = array();
+
+    /**
+     * Construct a contour plotting algorithm. The end result of the algorithm is a sequence of
+     * line segments for each isobar given as two vertices.
+     *
+     * @param $aDataMatrix    The Z-data to be used
+     * @param $aIsobar A mixed variable, if it is an integer then this specified the number of isobars to use.
+     * The values of the isobars are automatically detrmined to be equ-spaced between the min/max value of the
+     * data. If it is an array then it explicetely gives the isobar values
+     * @param $aInvert By default the matrice with row index 0 corresponds to Y-value 0, i.e. in the bottom of
+     * the plot. If this argument is true then the row with the highest index in the matrice corresponds  to
+     * Y-value 0. In affect flipping the matrice around an imaginary horizontal axis.
+     * @param $aHighContrast Use high contrast colors (blue/red:ish)
+     * @param $aHighContrastBW Use only black colors for contours
+     * @return an instance of the contour plot algorithm
+     */
+    function __construct($aDataMatrix, $aIsobar=10, $aFactor=1, $aInvert=false, $aIsobarColors=array()) {
+
+        $this->dataMatrix = $aDataMatrix;
+        $this->flipData = $aInvert;
+        $this->isobar = $aIsobar;
+        $this->interpFactor = $aFactor;
+
+        if ( $this->interpFactor > 1 ) {
+
+            if( $this->interpFactor > 5 ) {
+                JpGraphError::RaiseL(28007);// ContourPlot interpolation factor is too large (>5)
+            }
+
+            $ip = new MeshInterpolate();
+            $this->dataMatrix = $ip->Linear($this->dataMatrix, $this->interpFactor);
+        }
+
+        $this->contour = new Contour($this->dataMatrix,$this->isobar,$aIsobarColors);
+
+        if( is_array($aIsobar) )
+            $this->nbrContours = count($aIsobar);
+        else
+            $this->nbrContours = $aIsobar;
+    }
+
+
+    /**
+     * Flipe the data around the center
+     *
+     * @param $aFlg
+     *
+     */
+    function SetInvert($aFlg=true) {
+        $this->flipData = $aFlg;
+    }
+
+    /**
+     * Set the colors for the isobar lines
+     *
+     * @param $aColorArray
+     *
+     */
+    function SetIsobarColors($aColorArray) {
+        $this->manualIsobarColors = $aColorArray;
+    }
+
+    /**
+     * Show the legend
+     *
+     * @param $aFlg true if the legend should be shown
+     *
+     */
+    function ShowLegend($aFlg=true) {
+        $this->showLegend = $aFlg;
+    }
+
+
+    /**
+     * @param $aFlg true if the legend should start with the lowest isobar on top
+     * @return unknown_type
+     */
+    function Invertlegend($aFlg=true) {
+        $this->invertLegend = $aFlg;
+    }
+
+    /* Internal method. Give the min value to be used for the scaling
+     *
+     */
+    function Min() {
+        return array(0,0);
+    }
+
+    /* Internal method. Give the max value to be used for the scaling
+     *
+     */
+    function Max() {
+        return array(count($this->dataMatrix[0])-1,count($this->dataMatrix)-1);
+    }
+
+    /**
+     * Internal ramewrok method to setup the legend to be used for this plot.
+     * @param $aGraph The parent graph class
+     */
+    function Legend($aGraph) {
+
+        if( ! $this->showLegend )
+            return;
+
+        if( $this->invertLegend ) {
+            for ($i = 0; $i < $this->nbrContours; $i++) {
+                $aGraph->legend->Add(sprintf('%.1f',$this->contourVal[$i]), $this->contourColor[$i]);
+            }
+        }
+        else {
+            for ($i = $this->nbrContours-1; $i >= 0 ; $i--) {
+                $aGraph->legend->Add(sprintf('%.1f',$this->contourVal[$i]), $this->contourColor[$i]);
+            }
+        }
+    }
+
+
+    /**
+     *  Framework function which gets called before the Stroke() method is called
+     *
+     *  @see Plot#PreScaleSetup($aGraph)
+     *
+     */
+    function PreScaleSetup($aGraph) {
+        $xn = count($this->dataMatrix[0])-1;
+        $yn = count($this->dataMatrix)-1;
+
+        $aGraph->xaxis->scale->Update($aGraph->img,0,$xn);
+        $aGraph->yaxis->scale->Update($aGraph->img,0,$yn);
+
+        $this->contour->SetInvert($this->flipData);
+        list($this->contourCoord,$this->contourVal,$this->contourColor) = $this->contour->getIsobars();
+    }
+
+    /**
+     * Use high contrast color schema
+     *
+     * @param $aFlg True, to use high contrast color
+     * @param $aBW True, Use only black and white color schema
+     */
+    function UseHighContrastColor($aFlg=true,$aBW=false) {
+        $this->highcontrast = $aFlg;
+        $this->highcontrastbw = $aBW;
+        $this->contour->UseHighContrastColor($this->highcontrast,$this->highcontrastbw);
+    }
+
+    /**
+     * Internal method. Stroke the contour plot to the graph
+     *
+     * @param $img Image handler
+     * @param $xscale Instance of the xscale to use
+     * @param $yscale Instance of the yscale to use
+     */
+    function Stroke($img,$xscale,$yscale) {
+
+        if( count($this->manualIsobarColors) > 0 ) {
+            $this->contourColor = $this->manualIsobarColors;
+            if( count($this->manualIsobarColors) != $this->nbrContours ) {
+                JpGraphError::RaiseL(28002);
+            }
+        }
+
+        $img->SetLineWeight($this->line_weight);
+
+        for ($c = 0; $c < $this->nbrContours; $c++) {
+
+            $img->SetColor( $this->contourColor[$c] );
+
+            $n = count($this->contourCoord[$c]);
+            $i = 0;
+            while ( $i < $n ) {
+                list($x1,$y1) = $this->contourCoord[$c][$i][0];
+                $x1t = $xscale->Translate($x1);
+                $y1t = $yscale->Translate($y1);
+
+                list($x2,$y2) = $this->contourCoord[$c][$i++][1];
+                $x2t = $xscale->Translate($x2);
+                $y2t = $yscale->Translate($y2);
+
+                $img->Line($x1t,$y1t,$x2t,$y2t);
+            }
+
+        }
+    }
+
+}
+
+// EOF
+?>
diff --git a/web/classes/jpgraph/jpgraph_date.php b/web/classes/jpgraph/jpgraph_date.php
new file mode 100755
index 0000000000000000000000000000000000000000..db4c441c2eb7a018d64e01b75ba224a15f4d8713
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_date.php
@@ -0,0 +1,499 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_DATE.PHP
+ // Description: Classes to handle Date scaling
+ // Created:     2005-05-02
+ // Ver:         $Id: jpgraph_date.php 1106 2009-02-22 20:16:35Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+define('HOURADJ_1',0+30);
+define('HOURADJ_2',1+30);
+define('HOURADJ_3',2+30);
+define('HOURADJ_4',3+30);
+define('HOURADJ_6',4+30);
+define('HOURADJ_12',5+30);
+
+define('MINADJ_1',0+20);
+define('MINADJ_5',1+20);
+define('MINADJ_10',2+20);
+define('MINADJ_15',3+20);
+define('MINADJ_30',4+20);
+
+define('SECADJ_1',0);
+define('SECADJ_5',1);
+define('SECADJ_10',2);
+define('SECADJ_15',3);
+define('SECADJ_30',4);
+
+
+define('YEARADJ_1',0+30);
+define('YEARADJ_2',1+30);
+define('YEARADJ_5',2+30);
+
+define('MONTHADJ_1',0+20);
+define('MONTHADJ_6',1+20);
+
+define('DAYADJ_1',0);
+define('DAYADJ_WEEK',1);
+define('DAYADJ_7',1);
+
+define('SECPERYEAR',31536000);
+define('SECPERDAY',86400);
+define('SECPERHOUR',3600);
+define('SECPERMIN',60);
+
+
+class DateScale extends LinearScale {
+    private $date_format = '';
+    private $iStartAlign = false, $iEndAlign = false;
+    private $iStartTimeAlign = false, $iEndTimeAlign = false;
+
+    //---------------
+    // CONSTRUCTOR
+    function __construct($aMin=0,$aMax=0,$aType='x') {
+        assert($aType=="x");
+        assert($aMin<=$aMax);
+
+        $this->type=$aType;
+        $this->scale=array($aMin,$aMax);
+        $this->world_size=$aMax-$aMin;
+        $this->ticks = new LinearTicks();
+        $this->intscale=true;
+    }
+
+
+    //------------------------------------------------------------------------------------------
+    // Utility Function AdjDate()
+    // Description: Will round a given time stamp to an even year, month or day
+    // argument.
+    //------------------------------------------------------------------------------------------
+
+    function AdjDate($aTime,$aRound=0,$aYearType=false,$aMonthType=false,$aDayType=false) {
+        $y = (int)date('Y',$aTime); $m = (int)date('m',$aTime); $d = (int)date('d',$aTime);
+        $h=0;$i=0;$s=0;
+        if( $aYearType !== false ) {
+            $yearAdj = array(0=>1, 1=>2, 2=>5);
+            if( $aRound == 0 ) {
+                $y = floor($y/$yearAdj[$aYearType])*$yearAdj[$aYearType];
+            }
+            else {
+                ++$y;
+                $y = ceil($y/$yearAdj[$aYearType])*$yearAdj[$aYearType];
+            }
+            $m=1;$d=1;
+        }
+        elseif( $aMonthType !== false ) {
+            $monthAdj = array(0=>1, 1=>6);
+            if( $aRound == 0 ) {
+                $m = floor($m/$monthAdj[$aMonthType])*$monthAdj[$aMonthType];
+                $d=1;
+            }
+            else {
+                ++$m;
+                $m = ceil($m/$monthAdj[$aMonthType])*$monthAdj[$aMonthType];
+                $d=1;
+            }
+        }
+        elseif( $aDayType !== false ) {
+            if( $aDayType == 0 ) {
+                if( $aRound == 1 ) {
+                    //++$d;
+                    $h=23;$i=59;$s=59;
+                }
+            }
+            else {
+                // Adjust to an even week boundary.
+                $w = (int)date('w',$aTime); // Day of week 0=Sun, 6=Sat
+                if( true ) { // Adjust to start on Mon
+                    if( $w==0 ) $w=6;
+                    else --$w;
+                }
+                if( $aRound == 0 ) {
+                    $d -= $w;
+                }
+                else {
+                    $d += (7-$w);
+                    $h=23;$i=59;$s=59;
+                }
+            }
+        }
+        return mktime($h,$i,$s,$m,$d,$y);
+
+    }
+
+    //------------------------------------------------------------------------------------------
+    // Wrapper for AdjDate that will round a timestamp to an even date rounding
+    // it downwards.
+    //------------------------------------------------------------------------------------------
+    function AdjStartDate($aTime,$aYearType=false,$aMonthType=false,$aDayType=false) {
+        return $this->AdjDate($aTime,0,$aYearType,$aMonthType,$aDayType);
+    }
+
+    //------------------------------------------------------------------------------------------
+    // Wrapper for AdjDate that will round a timestamp to an even date rounding
+    // it upwards
+    //------------------------------------------------------------------------------------------
+    function AdjEndDate($aTime,$aYearType=false,$aMonthType=false,$aDayType=false) {
+        return $this->AdjDate($aTime,1,$aYearType,$aMonthType,$aDayType);
+    }
+
+    //------------------------------------------------------------------------------------------
+    // Utility Function AdjTime()
+    // Description: Will round a given time stamp to an even time according to
+    // argument.
+    //------------------------------------------------------------------------------------------
+
+    function AdjTime($aTime,$aRound=0,$aHourType=false,$aMinType=false,$aSecType=false) {
+        $y = (int)date('Y',$aTime); $m = (int)date('m',$aTime); $d = (int)date('d',$aTime);
+        $h = (int)date('H',$aTime); $i = (int)date('i',$aTime); $s = (int)date('s',$aTime);
+        if( $aHourType !== false ) {
+            $aHourType %= 6;
+            $hourAdj = array(0=>1, 1=>2, 2=>3, 3=>4, 4=>6, 5=>12);
+            if( $aRound == 0 )
+            $h = floor($h/$hourAdj[$aHourType])*$hourAdj[$aHourType];
+            else {
+                if( ($h % $hourAdj[$aHourType]==0) && ($i > 0 || $s > 0) ) {
+                    $h++;
+                }
+                $h = ceil($h/$hourAdj[$aHourType])*$hourAdj[$aHourType];
+                if( $h >= 24 ) {
+                    $aTime += 86400;
+                    $y = (int)date('Y',$aTime); $m = (int)date('m',$aTime); $d = (int)date('d',$aTime);
+                    $h -= 24;
+                }
+            }
+            $i=0;$s=0;
+        }
+        elseif( $aMinType !== false ) {
+            $aMinType %= 5;
+            $minAdj = array(0=>1, 1=>5, 2=>10, 3=>15, 4=>30);
+            if( $aRound == 0 ) {
+                $i = floor($i/$minAdj[$aMinType])*$minAdj[$aMinType];
+            }
+            else {
+                if( ($i % $minAdj[$aMinType]==0) && $s > 0 ) {
+                    $i++;
+                }
+                $i = ceil($i/$minAdj[$aMinType])*$minAdj[$aMinType];
+                if( $i >= 60) {
+                    $aTime += 3600;
+                    $y = (int)date('Y',$aTime); $m = (int)date('m',$aTime); $d = (int)date('d',$aTime);
+                    $h = (int)date('H',$aTime); $i = 0;
+                }
+            }
+            $s=0;
+        }
+        elseif( $aSecType !== false ) {
+            $aSecType %= 5;
+            $secAdj = array(0=>1, 1=>5, 2=>10, 3=>15, 4=>30);
+            if( $aRound == 0 ) {
+                $s = floor($s/$secAdj[$aSecType])*$secAdj[$aSecType];
+            }
+            else {
+                $s = ceil($s/$secAdj[$aSecType]*1.0)*$secAdj[$aSecType];
+                if( $s >= 60) {
+                    $s=0;
+                    $aTime += 60;
+                    $y = (int)date('Y',$aTime); $m = (int)date('m',$aTime); $d = (int)date('d',$aTime);
+                    $h = (int)date('H',$aTime); $i = (int)date('i',$aTime);
+                }
+            }
+        }
+        return mktime($h,$i,$s,$m,$d,$y);
+    }
+
+    //------------------------------------------------------------------------------------------
+    // Wrapper for AdjTime that will round a timestamp to an even time rounding
+    // it downwards.
+    // Example: AdjStartTime(mktime(18,27,13,2,22,2005),false,2) => 18:20
+    //------------------------------------------------------------------------------------------
+    function AdjStartTime($aTime,$aHourType=false,$aMinType=false,$aSecType=false) {
+        return $this->AdjTime($aTime,0,$aHourType,$aMinType,$aSecType);
+    }
+
+    //------------------------------------------------------------------------------------------
+    // Wrapper for AdjTime that will round a timestamp to an even time rounding
+    // it upwards
+    // Example: AdjEndTime(mktime(18,27,13,2,22,2005),false,2) => 18:30
+    //------------------------------------------------------------------------------------------
+    function AdjEndTime($aTime,$aHourType=false,$aMinType=false,$aSecType=false) {
+        return $this->AdjTime($aTime,1,$aHourType,$aMinType,$aSecType);
+    }
+
+    //------------------------------------------------------------------------------------------
+    // DateAutoScale
+    // Autoscale a date axis given start and end time
+    // Returns an array ($start,$end,$major,$minor,$format)
+    //------------------------------------------------------------------------------------------
+    function DoDateAutoScale($aStartTime,$aEndTime,$aDensity=0,$aAdjust=true) {
+        // Format of array
+        // array ( Decision point,  array( array( Major-scale-step-array ),
+        //       array( Minor-scale-step-array ),
+        //       array( 0=date-adjust, 1=time-adjust, adjustment-alignment) )
+        //
+        $scalePoints =
+        array(
+        /* Intervall larger than 10 years */
+        SECPERYEAR*10,array(array(SECPERYEAR*5,SECPERYEAR*2),
+        array(SECPERYEAR),
+        array(0,YEARADJ_1, 0,YEARADJ_1) ),
+
+        /* Intervall larger than 2 years */
+        SECPERYEAR*2,array(array(SECPERYEAR),array(SECPERYEAR),
+        array(0,YEARADJ_1) ),
+
+        /* Intervall larger than 90 days (approx 3 month) */
+        SECPERDAY*90,array(array(SECPERDAY*30,SECPERDAY*14,SECPERDAY*7,SECPERDAY),
+        array(SECPERDAY*5,SECPERDAY*7,SECPERDAY,SECPERDAY),
+        array(0,MONTHADJ_1, 0,DAYADJ_WEEK, 0,DAYADJ_1, 0,DAYADJ_1)),
+
+        /* Intervall larger than 30 days (approx 1 month) */
+        SECPERDAY*30,array(array(SECPERDAY*14,SECPERDAY*7,SECPERDAY*2, SECPERDAY),
+        array(SECPERDAY,SECPERDAY,SECPERDAY,SECPERDAY),
+        array(0,DAYADJ_WEEK, 0,DAYADJ_1, 0,DAYADJ_1, 0,DAYADJ_1)),
+
+        /* Intervall larger than 7 days */
+        SECPERDAY*7,array(array(SECPERDAY,SECPERHOUR*12,SECPERHOUR*6,SECPERHOUR*2),
+        array(SECPERHOUR*6,SECPERHOUR*3,SECPERHOUR,SECPERHOUR),
+        array(0,DAYADJ_1, 1,HOURADJ_12, 1,HOURADJ_6, 1,HOURADJ_1)),
+
+        /* Intervall larger than 1 day */
+        SECPERDAY,array(array(SECPERDAY,SECPERHOUR*12,SECPERHOUR*6,SECPERHOUR*2,SECPERHOUR),
+        array(SECPERHOUR*6,SECPERHOUR*2,SECPERHOUR,SECPERHOUR,SECPERHOUR),
+        array(1,HOURADJ_12, 1,HOURADJ_6, 1,HOURADJ_1, 1,HOURADJ_1)),
+
+        /* Intervall larger than 12 hours */
+        SECPERHOUR*12,array(array(SECPERHOUR*2,SECPERHOUR,SECPERMIN*30,900,600),
+        array(1800,1800,900,300,300),
+        array(1,HOURADJ_1, 1,MINADJ_30, 1,MINADJ_15, 1,MINADJ_10, 1,MINADJ_5) ),
+
+        /* Intervall larger than 2 hours */
+        SECPERHOUR*2,array(array(SECPERHOUR,SECPERMIN*30,900,600,300),
+        array(1800,900,300,120,60),
+        array(1,HOURADJ_1, 1,MINADJ_30, 1,MINADJ_15, 1,MINADJ_10, 1,MINADJ_5) ),
+
+        /* Intervall larger than 1 hours */
+        SECPERHOUR,array(array(SECPERMIN*30,900,600,300),array(900,300,120,60),
+        array(1,MINADJ_30, 1,MINADJ_15, 1,MINADJ_10, 1,MINADJ_5) ),
+
+        /* Intervall larger than 30 min */
+        SECPERMIN*30,array(array(SECPERMIN*15,SECPERMIN*10,SECPERMIN*5,SECPERMIN),
+        array(300,300,60,10),
+        array(1,MINADJ_15, 1,MINADJ_10, 1,MINADJ_5, 1,MINADJ_1)),
+
+        /* Intervall larger than 1 min */
+        SECPERMIN,array(array(SECPERMIN,15,10,5),
+        array(15,5,2,1),
+        array(1,MINADJ_1, 1,SECADJ_15, 1,SECADJ_10, 1,SECADJ_5)),
+
+        /* Intervall larger than 10 sec */
+        10,array(array(5,2),
+        array(1,1),
+        array(1,SECADJ_5, 1,SECADJ_1)),
+
+        /* Intervall larger than 1 sec */
+        1,array(array(1),
+        array(1),
+        array(1,SECADJ_1)),
+        );
+
+        $ns = count($scalePoints);
+        // Establish major and minor scale units for the date scale
+        $diff = $aEndTime - $aStartTime;
+        if( $diff < 1 ) return false;
+        $done=false;
+        $i=0;
+        while( ! $done ) {
+            if( $diff > $scalePoints[2*$i] ) {
+                // Get major and minor scale for this intervall
+                $scaleSteps = $scalePoints[2*$i+1];
+                $major = $scaleSteps[0][min($aDensity,count($scaleSteps[0])-1)];
+                // Try to find out which minor step looks best
+                $minor = $scaleSteps[1][min($aDensity,count($scaleSteps[1])-1)];
+                if( $aAdjust ) {
+                    // Find out how we should align the start and end timestamps
+                    $idx = 2*min($aDensity,floor(count($scaleSteps[2])/2)-1);
+                    if( $scaleSteps[2][$idx] === 0 ) {
+                        // Use date adjustment
+                        $adj = $scaleSteps[2][$idx+1];
+                        if( $adj >= 30 ) {
+                            $start = $this->AdjStartDate($aStartTime,$adj-30);
+                            $end   = $this->AdjEndDate($aEndTime,$adj-30);
+                        }
+                        elseif( $adj >= 20 ) {
+                            $start = $this->AdjStartDate($aStartTime,false,$adj-20);
+                            $end   = $this->AdjEndDate($aEndTime,false,$adj-20);
+                        }
+                        else {
+                            $start = $this->AdjStartDate($aStartTime,false,false,$adj);
+                            $end   = $this->AdjEndDate($aEndTime,false,false,$adj);
+                            // We add 1 second for date adjustment to make sure we end on 00:00 the following day
+                            // This makes the final major tick be srawn when we step day-by-day instead of ending
+                            // on xx:59:59 which would not draw the final major tick
+                            $end++;
+                        }
+                    }
+                    else {
+                        // Use time adjustment
+                        $adj = $scaleSteps[2][$idx+1];
+                        if( $adj >= 30 ) {
+                            $start = $this->AdjStartTime($aStartTime,$adj-30);
+                            $end   = $this->AdjEndTime($aEndTime,$adj-30);
+                        }
+                        elseif( $adj >= 20 ) {
+                            $start = $this->AdjStartTime($aStartTime,false,$adj-20);
+                            $end   = $this->AdjEndTime($aEndTime,false,$adj-20);
+                        }
+                        else {
+                            $start = $this->AdjStartTime($aStartTime,false,false,$adj);
+                            $end   = $this->AdjEndTime($aEndTime,false,false,$adj);
+                        }
+                    }
+                }
+                // If the overall date span is larger than 1 day ten we show date
+                $format = '';
+                if( ($end-$start) > SECPERDAY ) {
+                    $format = 'Y-m-d ';
+                }
+                // If the major step is less than 1 day we need to whow hours + min
+                if( $major < SECPERDAY ) {
+                    $format .= 'H:i';
+                }
+                // If the major step is less than 1 min we need to show sec
+                if( $major < 60 ) {
+                    $format .= ':s';
+                }
+                $done=true;
+            }
+            ++$i;
+        }
+        return array($start,$end,$major,$minor,$format);
+    }
+
+    // Overrides the automatic determined date format. Must be a valid date() format string
+    function SetDateFormat($aFormat) {
+        $this->date_format = $aFormat;
+        $this->ticks->SetLabelDateFormat($this->date_format);
+    }
+
+    function AdjustForDST($aFlg=true) {
+        $this->ticks->AdjustForDST($aFlg);
+    }
+
+
+    function SetDateAlign($aStartAlign,$aEndAlign=false) {
+        if( $aEndAlign === false ) {
+            $aEndAlign=$aStartAlign;
+        }
+        $this->iStartAlign = $aStartAlign;
+        $this->iEndAlign = $aEndAlign;
+    }
+
+    function SetTimeAlign($aStartAlign,$aEndAlign=false) {
+        if( $aEndAlign === false ) {
+            $aEndAlign=$aStartAlign;
+        }
+        $this->iStartTimeAlign = $aStartAlign;
+        $this->iEndTimeAlign = $aEndAlign;
+    }
+
+
+    function AutoScale($img,$aStartTime,$aEndTime,$aNumSteps,$_adummy=false) {
+        // We need to have one dummy argument to make the signature of AutoScale()
+        // identical to LinearScale::AutoScale
+        if( $aStartTime == $aEndTime ) {
+            // Special case when we only have one data point.
+            // Create a small artifical intervall to do the autoscaling
+            $aStartTime -= 10;
+            $aEndTime += 10;
+        }
+        $done=false;
+        $i=0;
+        while( ! $done && $i < 5) {
+            list($adjstart,$adjend,$maj,$min,$format) = $this->DoDateAutoScale($aStartTime,$aEndTime,$i);
+            $n = floor(($adjend-$adjstart)/$maj);
+            if( $n * 1.7 > $aNumSteps ) {
+                $done=true;
+            }
+            $i++;
+        }
+
+        /*
+         if( 0 ) { // DEBUG
+         echo "    Start =".date("Y-m-d H:i:s",$aStartTime)."<br>";
+         echo "    End   =".date("Y-m-d H:i:s",$aEndTime)."<br>";
+         echo "Adj Start =".date("Y-m-d H:i:s",$adjstart)."<br>";
+         echo "Adj End   =".date("Y-m-d H:i:s",$adjend)."<p>";
+         echo "Major = $maj s, ".floor($maj/60)."min, ".floor($maj/3600)."h, ".floor($maj/86400)."day<br>";
+         echo "Min = $min s, ".floor($min/60)."min, ".floor($min/3600)."h, ".floor($min/86400)."day<br>";
+         echo "Format=$format<p>";
+         }
+         */
+
+        if( $this->iStartTimeAlign !== false && $this->iStartAlign !== false ) {
+            JpGraphError::RaiseL(3001);
+            //('It is only possible to use either SetDateAlign() or SetTimeAlign() but not both');
+        }
+
+        if( $this->iStartTimeAlign !== false ) {
+            if( $this->iStartTimeAlign >= 30 ) {
+                $adjstart = $this->AdjStartTime($aStartTime,$this->iStartTimeAlign-30);
+            }
+            elseif(  $this->iStartTimeAlign >= 20 ) {
+                $adjstart = $this->AdjStartTime($aStartTime,false,$this->iStartTimeAlign-20);
+            }
+            else {
+                $adjstart = $this->AdjStartTime($aStartTime,false,false,$this->iStartTimeAlign);
+            }
+        }
+        if( $this->iEndTimeAlign !== false ) {
+            if( $this->iEndTimeAlign >= 30 ) {
+                $adjend = $this->AdjEndTime($aEndTime,$this->iEndTimeAlign-30);
+            }
+            elseif(  $this->iEndTimeAlign >= 20 ) {
+                $adjend = $this->AdjEndTime($aEndTime,false,$this->iEndTimeAlign-20);
+            }
+            else {
+                $adjend = $this->AdjEndTime($aEndTime,false,false,$this->iEndTimeAlign);
+            }
+        }
+
+
+
+        if( $this->iStartAlign !== false ) {
+            if( $this->iStartAlign >= 30 ) {
+                $adjstart = $this->AdjStartDate($aStartTime,$this->iStartAlign-30);
+            }
+            elseif(  $this->iStartAlign >= 20 ) {
+                $adjstart = $this->AdjStartDate($aStartTime,false,$this->iStartAlign-20);
+            }
+            else {
+                $adjstart = $this->AdjStartDate($aStartTime,false,false,$this->iStartAlign);
+            }
+        }
+        if( $this->iEndAlign !== false ) {
+            if( $this->iEndAlign >= 30 ) {
+                $adjend = $this->AdjEndDate($aEndTime,$this->iEndAlign-30);
+            }
+            elseif(  $this->iEndAlign >= 20 ) {
+                $adjend = $this->AdjEndDate($aEndTime,false,$this->iEndAlign-20);
+            }
+            else {
+                $adjend = $this->AdjEndDate($aEndTime,false,false,$this->iEndAlign);
+            }
+        }
+        $this->Update($img,$adjstart,$adjend);
+        if( ! $this->ticks->IsSpecified() )
+        $this->ticks->Set($maj,$min);
+        if( $this->date_format == '' )
+        $this->ticks->SetLabelDateFormat($format);
+        else
+        $this->ticks->SetLabelDateFormat($this->date_format);
+    }
+}
+
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_errhandler.inc.php b/web/classes/jpgraph/jpgraph_errhandler.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..c15361e3fd7491bb1858926bfa8b1d022bc4b1a6
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_errhandler.inc.php
@@ -0,0 +1,369 @@
+<?php
+//=======================================================================
+// File:        JPGRAPH_ERRHANDLER.PHP
+// Description: Error handler class together with handling of localized
+//              error messages. All localized error messages are stored
+//              in a separate file under the "lang/" subdirectory.
+// Created:     2006-09-24
+// Ver:         $Id: jpgraph_errhandler.inc.php 1920 2009-12-08 10:02:26Z ljp $
+//
+// Copyright 2006 (c) Aditus Consulting. All rights reserved.
+//========================================================================
+
+if( !defined('DEFAULT_ERR_LOCALE') ) {
+    define('DEFAULT_ERR_LOCALE','en');
+}
+
+if( !defined('USE_IMAGE_ERROR_HANDLER') ) {
+    define('USE_IMAGE_ERROR_HANDLER',true);
+}
+
+GLOBAL $__jpg_err_locale ;
+$__jpg_err_locale = DEFAULT_ERR_LOCALE;
+
+class ErrMsgText {
+    private $lt=NULL;
+    function __construct() {
+        GLOBAL $__jpg_err_locale;
+        $file = 'lang/'.$__jpg_err_locale.'.inc.php';
+
+        // If the chosen locale doesn't exist try english
+        if( !file_exists(dirname(__FILE__).'/'.$file) ) {
+            $__jpg_err_locale = 'en';
+        }
+
+        $file = 'lang/'.$__jpg_err_locale.'.inc.php';
+        if( !file_exists(dirname(__FILE__).'/'.$file) ) {
+            die('Chosen locale file ("'.$file.'") for error messages does not exist or is not readable for the PHP process. Please make sure that the file exists and that the file permissions are such that the PHP process is allowed to read this file.');
+        }
+        require($file);
+        $this->lt = $_jpg_messages;
+    }
+
+    function Get($errnbr,$a1=null,$a2=null,$a3=null,$a4=null,$a5=null) {
+        GLOBAL $__jpg_err_locale;
+        if( !isset($this->lt[$errnbr]) ) {
+            return 'Internal error: The specified error message ('.$errnbr.') does not exist in the chosen locale ('.$__jpg_err_locale.')';
+        }
+        $ea = $this->lt[$errnbr];
+        $j=0;
+        if( $a1 !== null ) {
+            $argv[$j++] = $a1;
+            if( $a2 !== null ) {
+                $argv[$j++] = $a2;
+                if( $a3 !== null ) {
+                    $argv[$j++] = $a3;
+                    if( $a4 !== null ) {
+                        $argv[$j++] = $a4;
+                        if( $a5 !== null ) {
+                            $argv[$j++] = $a5;
+                        }
+                    }
+                }
+            }
+        }
+        $numargs = $j;
+        if( $ea[1] != $numargs ) {
+            // Error message argument count do not match.
+            // Just return the error message without arguments.
+            return $ea[0];
+        }
+        switch( $numargs ) {
+            case 1:
+                $msg = sprintf($ea[0],$argv[0]);
+                break;
+            case 2:
+                $msg = sprintf($ea[0],$argv[0],$argv[1]);
+                break;
+            case 3:
+                $msg = sprintf($ea[0],$argv[0],$argv[1],$argv[2]);
+                break;
+            case 4:
+                $msg = sprintf($ea[0],$argv[0],$argv[1],$argv[2],$argv[3]);
+                break;
+            case 5:
+                $msg = sprintf($ea[0],$argv[0],$argv[1],$argv[2],$argv[3],$argv[4]);
+                break;
+            case 0:
+            default:
+                $msg = sprintf($ea[0]);
+                break;
+        }
+        return $msg;
+    }
+}
+     
+//
+// A wrapper class that is used to access the specified error object
+// (to hide the global error parameter and avoid having a GLOBAL directive
+// in all methods.
+//
+class JpGraphError {
+    private static $__iImgFlg = true;
+    private static $__iLogFile = '';
+    private static $__iTitle = 'JpGraph Error: ';
+    public static function Raise($aMsg,$aHalt=true){
+        throw new JpGraphException($aMsg);
+    }
+    public static function SetErrLocale($aLoc) {
+        GLOBAL $__jpg_err_locale ;
+        $__jpg_err_locale = $aLoc;
+    }
+    public static function RaiseL($errnbr,$a1=null,$a2=null,$a3=null,$a4=null,$a5=null) {
+        throw new JpGraphExceptionL($errnbr,$a1,$a2,$a3,$a4,$a5);
+    }
+    public static function SetImageFlag($aFlg=true) {
+    	self::$__iImgFlg = $aFlg;
+    }
+    public static function GetImageFlag() {
+    	return self::$__iImgFlg;
+    }
+    public static function SetLogFile($aFile) {
+    	self::$__iLogFile = $aFile;
+    }
+    public static function GetLogFile() {
+    	return self::$__iLogFile;
+    }
+    public static function SetTitle($aTitle) {
+    	self::$__iTitle = $aTitle;
+    }
+    public static function GetTitle() {
+    	return self::$__iTitle;
+    }    
+}
+
+class JpGraphException extends Exception {
+    // Redefine the exception so message isn't optional
+    public function __construct($message, $code = 0) {
+        // make sure everything is assigned properly
+        parent::__construct($message, $code);
+    }
+    // custom string representation of object
+    public function _toString() {
+        return __CLASS__ . ": [{$this->code}]: {$this->message} at " . basename($this->getFile()) . ":" . $this->getLine() . "\n" . $this->getTraceAsString() . "\n";
+    }
+    // custom representation of error as an image
+    public function Stroke() {
+    	if( JpGraphError::GetImageFlag() ) {
+        	$errobj = new JpGraphErrObjectImg();
+        	$errobj->SetTitle(JpGraphError::GetTitle());
+    	}
+    	else {    		
+    		$errobj = new JpGraphErrObject();
+        	$errobj->SetTitle(JpGraphError::GetTitle());    		
+    		$errobj->SetStrokeDest(JpGraphError::GetLogFile());
+    	}
+        $errobj->Raise($this->getMessage());
+    }
+    static public function defaultHandler(Exception $exception) {
+        global $__jpg_OldHandler;
+        if( $exception instanceof JpGraphException ) {
+            $exception->Stroke();
+        }
+        else {
+            // Restore old handler
+            if( $__jpg_OldHandler !== NULL ) {
+                set_exception_handler($__jpg_OldHandler);
+            }
+            throw $exception;
+        }
+    }
+}
+
+class JpGraphExceptionL extends JpGraphException {
+   // Redefine the exception so message isn't optional
+    public function __construct($errcode,$a1=null,$a2=null,$a3=null,$a4=null,$a5=null) {
+        // make sure everything is assigned properly
+        $errtxt = new ErrMsgText();
+        JpGraphError::SetTitle('JpGraph Error: '.$errcode);
+        parent::__construct($errtxt->Get($errcode,$a1,$a2,$a3,$a4,$a5), 0);
+    }
+}
+
+// Setup the default handler
+global $__jpg_OldHandler;
+$__jpg_OldHandler = set_exception_handler(array('JpGraphException','defaultHandler'));
+
+//
+// First of all set up a default error handler
+//
+
+//=============================================================
+// The default trivial text error handler.
+//=============================================================
+class JpGraphErrObject {
+
+    protected $iTitle = "JpGraph error: ";
+    protected $iDest = false;
+
+
+    function __construct() {
+        // Empty. Reserved for future use
+    }
+
+    function SetTitle($aTitle) {
+        $this->iTitle = $aTitle;
+    }
+
+    function SetStrokeDest($aDest) {
+        $this->iDest = $aDest;
+    }
+
+    // If aHalt is true then execution can't continue. Typical used for fatal errors
+    function Raise($aMsg,$aHalt=false) {
+        if( $this->iDest != '' ) {
+        	if( $this->iDest == 'syslog' ) {
+        		error_log($this->iTitle.$aMsg);	
+        	} 
+        	else {
+        		$str = '['.date('r').'] '.$this->iTitle.$aMsg."\n";
+        		$f = @fopen($this->iDest,'a');
+    	        if( $f ) {            	
+        	        @fwrite($f,$str);
+            	    @fclose($f);
+            	}
+        	}
+        }
+        else {
+        	$aMsg = $this->iTitle.$aMsg;        	
+        	// Check SAPI and if we are called from the command line
+        	// send the error to STDERR instead
+        	if( PHP_SAPI == 'cli' ) {
+        		fwrite(STDERR,$aMsg);
+        	}
+        	else {
+            	echo $aMsg;
+        	}
+        }
+        if( $aHalt )
+        	exit(1);
+    }
+}
+
+//==============================================================
+// An image based error handler
+//==============================================================
+class JpGraphErrObjectImg extends JpGraphErrObject {
+    
+    function __construct() {
+        parent::__construct();
+        // Empty. Reserved for future use
+    }
+
+    function Raise($aMsg,$aHalt=true) {
+        $img_iconerror =
+     'iVBORw0KGgoAAAANSUhEUgAAACgAAAAoCAMAAAC7IEhfAAAAaV'.
+     'BMVEX//////2Xy8mLl5V/Z2VvMzFi/v1WyslKlpU+ZmUyMjEh/'.
+     'f0VyckJlZT9YWDxMTDjAwMDy8sLl5bnY2K/MzKW/v5yyspKlpY'.
+     'iYmH+MjHY/PzV/f2xycmJlZVlZWU9MTEXY2Ms/PzwyMjLFTjea'.
+     'AAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACx'.
+     'IAAAsSAdLdfvwAAAAHdElNRQfTBgISOCqusfs5AAABLUlEQVR4'.
+     '2tWV3XKCMBBGWfkranCIVClKLd/7P2Q3QsgCxjDTq+6FE2cPH+'.
+     'xJ0Ogn2lQbsT+Wrs+buAZAV4W5T6Bs0YXBBwpKgEuIu+JERAX6'.
+     'wM2rHjmDdEITmsQEEmWADgZm6rAjhXsoMGY9B/NZBwJzBvn+e3'.
+     'wHntCAJdGu9SviwIwoZVDxPB9+Rc0TSEbQr0j3SA1gwdSn6Db0'.
+     '6Tm1KfV6yzWGQO7zdpvyKLKBDmRFjzeB3LYgK7r6A/noDAfjtS'.
+     'IXaIzbJSv6WgUebTMV4EoRB8a2mQiQjgtF91HdKDKZ1gtFtQjk'.
+     'YcWaR5OKOhkYt+ZsTFdJRfPAApOpQYJTNHvCRSJR6SJngQadfc'.
+     'vd69OLMddVOPCGVnmrFD8bVYd3JXfxXPtLR/+mtv59/ALWiiMx'.
+     'qL72fwAAAABJRU5ErkJggg==' ;
+
+        
+        if( function_exists("imagetypes") ) {
+            $supported = imagetypes();
+        } else {
+            $supported = 0;
+        }
+
+        if( !function_exists('imagecreatefromstring') ) {
+            $supported = 0;
+        }
+        
+        if( ob_get_length() || headers_sent() || !($supported & IMG_PNG) ) {
+            // Special case for headers already sent or that the installation doesn't support
+            // the PNG format (which the error icon is encoded in).
+            // Dont return an image since it can't be displayed
+            die($this->iTitle.' '.$aMsg);
+        }
+
+        $aMsg = wordwrap($aMsg,55);
+        $lines = substr_count($aMsg,"\n");
+
+        // Create the error icon GD
+        $erricon = Image::CreateFromString(base64_decode($img_iconerror));
+
+        // Create an image that contains the error text.
+        $w=400;
+        $h=100 + 15*max(0,$lines-3);
+
+        $img = new Image($w,$h);
+
+
+        // Drop shadow
+        $img->SetColor("gray");
+        $img->FilledRectangle(5,5,$w-1,$h-1,10);
+        $img->SetColor("gray:0.7");
+        $img->FilledRectangle(5,5,$w-3,$h-3,10);
+
+        // Window background
+        $img->SetColor("lightblue");
+        $img->FilledRectangle(1,1,$w-5,$h-5);
+        $img->CopyCanvasH($img->img,$erricon,5,30,0,0,40,40);
+
+        // Window border
+        $img->SetColor("black");
+        $img->Rectangle(1,1,$w-5,$h-5);
+        $img->Rectangle(0,0,$w-4,$h-4);
+
+        // Window top row
+        $img->SetColor("darkred");
+        for($y=3; $y < 18; $y += 2 )
+        $img->Line(1,$y,$w-6,$y);
+
+        // "White shadow"
+        $img->SetColor("white");
+
+        // Left window edge
+        $img->Line(2,2,2,$h-5);
+        $img->Line(2,2,$w-6,2);
+
+        // "Gray button shadow"
+        $img->SetColor("darkgray");
+
+        // Gray window shadow
+        $img->Line(2,$h-6,$w-5,$h-6);
+        $img->Line(3,$h-7,$w-5,$h-7);
+
+        // Window title
+        $m = floor($w/2-5);
+        $l = 110;
+        $img->SetColor("lightgray:1.3");
+        $img->FilledRectangle($m-$l,2,$m+$l,16);
+
+        // Stroke text
+        $img->SetColor("darkred");
+        $img->SetFont(FF_FONT2,FS_BOLD);
+        $img->StrokeText($m-90,15,$this->iTitle);
+        $img->SetColor("black");
+        $img->SetFont(FF_FONT1,FS_NORMAL);
+        $txt = new Text($aMsg,52,25);
+        $txt->SetFont(FF_FONT1);
+        $txt->Align("left","top");
+        $txt->Stroke($img);
+        if ($this->iDest) {
+            $img->Stream($this->iDest);
+        } else {
+            $img->Headers();
+            $img->Stream();
+        }
+        if( $aHalt )
+            die();
+    }
+}
+
+
+
+if( ! USE_IMAGE_ERROR_HANDLER ) {
+	JpGraphError::SetImageFlag(false);
+}
+?>
diff --git a/web/classes/jpgraph/jpgraph_error.php b/web/classes/jpgraph/jpgraph_error.php
new file mode 100755
index 0000000000000000000000000000000000000000..3ef3ca5b77bd1820f106ad8a4267350287460edf
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_error.php
@@ -0,0 +1,157 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_ERROR.PHP
+ // Description: Error plot extension for JpGraph
+ // Created:     2001-01-08
+ // Ver:         $Id: jpgraph_error.php 1106 2009-02-22 20:16:35Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+   
+//===================================================
+// CLASS ErrorPlot
+// Description: Error plot with min/max value for
+// each datapoint
+//===================================================
+class ErrorPlot extends Plot {
+    private $errwidth=2;
+    
+    //---------------
+    // CONSTRUCTOR
+    function __construct($datay,$datax=false) {
+        parent::__construct($datay,$datax);
+        $this->numpoints /= 2;
+    }
+    //---------------
+    // PUBLIC METHODS
+
+    // Gets called before any axis are stroked
+    function PreStrokeAdjust($graph) {
+        if( $this->center ) {
+            $a=0.5; $b=0.5;
+            ++$this->numpoints;
+        } else {
+            $a=0; $b=0;
+        }
+        $graph->xaxis->scale->ticks->SetXLabelOffset($a);
+        $graph->SetTextScaleOff($b);
+        //$graph->xaxis->scale->ticks->SupressMinorTickMarks();
+    }
+
+    // Method description
+    function Stroke($img,$xscale,$yscale) {
+        $numpoints=count($this->coords[0])/2;
+        $img->SetColor($this->color);
+        $img->SetLineWeight($this->weight);
+
+        if( isset($this->coords[1]) ) {
+            if( count($this->coords[1])!=$numpoints )
+            JpGraphError::RaiseL(2003,count($this->coords[1]),$numpoints);
+            //("Number of X and Y points are not equal. Number of X-points:".count($this->coords[1])." Number of Y-points:$numpoints");
+            else
+            $exist_x = true;
+        }
+        else
+        $exist_x = false;
+
+        for( $i=0; $i<$numpoints; ++$i) {
+            if( $exist_x )
+            $x=$this->coords[1][$i];
+            else
+            $x=$i;
+
+            if( !is_numeric($x) ||
+            !is_numeric($this->coords[0][$i*2]) || !is_numeric($this->coords[0][$i*2+1]) ) {
+                continue;
+            }
+
+            $xt = $xscale->Translate($x);
+            $yt1 = $yscale->Translate($this->coords[0][$i*2]);
+            $yt2 = $yscale->Translate($this->coords[0][$i*2+1]);
+            $img->Line($xt,$yt1,$xt,$yt2);
+            $img->Line($xt-$this->errwidth,$yt1,$xt+$this->errwidth,$yt1);
+            $img->Line($xt-$this->errwidth,$yt2,$xt+$this->errwidth,$yt2);
+        }
+        return true;
+    }
+} // Class
+
+
+//===================================================
+// CLASS ErrorLinePlot
+// Description: Combine a line and error plot
+// THIS IS A DEPRECATED PLOT TYPE JUST KEPT FOR
+// BACKWARD COMPATIBILITY
+//===================================================
+class ErrorLinePlot extends ErrorPlot {
+    public $line=null;
+    //---------------
+    // CONSTRUCTOR
+    function __construct($datay,$datax=false) {
+        parent::__construct($datay,$datax);
+        // Calculate line coordinates as the average of the error limits
+        $n = count($datay);
+        for($i=0; $i < $n; $i+=2 ) {
+            $ly[]=($datay[$i]+$datay[$i+1])/2;
+        }
+        $this->line=new LinePlot($ly,$datax);
+    }
+
+    //---------------
+    // PUBLIC METHODS
+    function Legend($graph) {
+        if( $this->legend != "" )
+        $graph->legend->Add($this->legend,$this->color);
+        $this->line->Legend($graph);
+    }
+     
+    function Stroke($img,$xscale,$yscale) {
+        parent::Stroke($img,$xscale,$yscale);
+        $this->line->Stroke($img,$xscale,$yscale);
+    }
+} // Class
+
+
+//===================================================
+// CLASS LineErrorPlot
+// Description: Combine a line and error plot
+//===================================================
+class LineErrorPlot extends ErrorPlot {
+    public $line=null;
+    //---------------
+    // CONSTRUCTOR
+    // Data is (val, errdeltamin, errdeltamax)
+    function __construct($datay,$datax=false) {
+        $ly=array(); $ey=array();
+        $n = count($datay);
+        if( $n % 3 != 0 ) {
+            JpGraphError::RaiseL(4002);
+            //('Error in input data to LineErrorPlot. Number of data points must be a multiple of 3');
+        }
+        for($i=0; $i < $n; $i+=3 ) {
+            $ly[]=$datay[$i];
+            $ey[]=$datay[$i]+$datay[$i+1];
+            $ey[]=$datay[$i]+$datay[$i+2];
+        }
+        parent::__construct($ey,$datax);
+        $this->line=new LinePlot($ly,$datax);
+    }
+
+    //---------------
+    // PUBLIC METHODS
+    function Legend($graph) {
+        if( $this->legend != "" )
+        $graph->legend->Add($this->legend,$this->color);
+        $this->line->Legend($graph);
+    }
+     
+    function Stroke($img,$xscale,$yscale) {
+        parent::Stroke($img,$xscale,$yscale);
+        $this->line->Stroke($img,$xscale,$yscale);
+    }
+} // Class
+
+
+/* EOF */
+?>
diff --git a/web/classes/jpgraph/jpgraph_flags.php b/web/classes/jpgraph/jpgraph_flags.php
new file mode 100755
index 0000000000000000000000000000000000000000..a7e2187795fb1503c4125d85bb19a75f2e35d146
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_flags.php
@@ -0,0 +1,376 @@
+<?php
+//=======================================================================
+// File:        JPGRAPH_FLAGS.PHP
+// Description: Class Jpfile. Handles plotmarks
+// Created:     2003-06-28
+// Ver:         $Id: jpgraph_flags.php 1106 2009-02-22 20:16:35Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+//------------------------------------------------------------
+// Defines for the different basic sizes of flags
+//------------------------------------------------------------
+DEFINE('FLAGSIZE1',1);
+DEFINE('FLAGSIZE2',2);
+DEFINE('FLAGSIZE3',3);
+DEFINE('FLAGSIZE4',4);
+
+class FlagImages {
+
+    public $iCountryNameMap = array(
+    'Afghanistan' => 'afgh',
+    'Republic of Angola' => 'agla',
+    'Republic of Albania' => 'alba',
+    'Alderney' => 'alde',
+    'Democratic and Popular Republic of Algeria' => 'alge',
+    'Territory of American Samoa' => 'amsa',
+    'Principality of Andorra' => 'andr',
+    'British Overseas Territory of Anguilla' => 'angu',
+    'Antarctica' => 'anta',
+    'Argentine Republic' => 'arge',
+    'League of Arab States' => 'arle',
+    'Republic of Armenia' => 'arme',
+    'Aruba' => 'arub',
+    'Commonwealth of Australia' => 'astl',
+    'Republic of Austria' => 'aust',
+    'Azerbaijani Republic' => 'azer',
+    'Bangladesh' => 'bngl',
+    'British Antarctic Territory' => 'bant',
+    'Kingdom of Belgium' => 'belg',
+    'British Overseas Territory of Bermuda' => 'berm',
+    'Commonwealth of the Bahamas' => 'bhms',
+    'Kingdom of Bahrain' => 'bhrn',
+    'Republic of Belarus' => 'blru',
+    'Republic of Bolivia' => 'blva',
+    'Belize' => 'blze',
+    'Republic of Benin' => 'bnin',
+    'Republic of Botswana' => 'bots',
+    'Federative Republic of Brazil' => 'braz',
+    'Barbados' => 'brbd',
+    'British Indian Ocean Territory' => 'brin',
+    'Brunei Darussalam' => 'brun',
+    'Republic of Burkina' => 'bufa',
+    'Republic of Bulgaria' => 'bulg',
+    'Republic of Burundi' => 'buru',
+    'Overseas Territory of the British Virgin Islands' => 'bvis',
+    'Central African Republic' => 'cafr',
+    'Kingdom of Cambodia' => 'camb',
+    'Republic of Cameroon' => 'came',
+    'Dominion of Canada' => 'cana',
+    'Caribbean Community' => 'cari',
+    'Republic of Cape Verde' => 'cave',
+    'Republic of Chad' => 'chad',
+    'Republic of Chile' => 'chil',
+    'Peoples Republic of China' => 'chin',
+    'Territory of Christmas Island' => 'chms',
+    'Commonwealth of Independent States' => 'cins',
+    'Cook Islands' => 'ckis',
+    'Republic of Colombia' => 'clmb',
+    'Territory of Cocos Islands' => 'cois',
+    'Commonwealth' => 'comn',
+    'Union of the Comoros' => 'como',
+    'Republic of the Congo' => 'cong',
+    'Republic of Costa Rica' => 'corc',
+    'Republic of Croatia' => 'croa',
+    'Republic of Cuba' => 'cuba',
+    'British Overseas Territory of the Cayman Islands' => 'cyis',
+    'Republic of Cyprus' => 'cypr',
+    'The Czech Republic' => 'czec',
+    'Kingdom of Denmark' => 'denm',
+    'Republic of Djibouti' => 'djib',
+    'Commonwealth of Dominica' => 'domn',
+    'Dominican Republic' => 'dore',
+    'Republic of Ecuador' => 'ecua',
+    'Arab Republic of Egypt' => 'egyp',
+    'Republic of El Salvador' => 'elsa',
+    'England' => 'engl',
+    'Republic of Equatorial Guinea' => 'eqgu',
+    'State of Eritrea' => 'erit',
+    'Republic of Estonia' => 'estn',
+    'Ethiopia' => 'ethp',
+    'European Union' => 'euun',
+    'British Overseas Territory of the Falkland Islands' => 'fais',
+    'International Federation of Vexillological Associations' => 'fiav',
+    'Republic of Fiji' => 'fiji',
+    'Republic of Finland' => 'finl',
+    'Territory of French Polynesia' => 'fpol',
+    'French Republic' => 'fran',
+    'Overseas Department of French Guiana' => 'frgu',
+    'Gabonese Republic' => 'gabn',
+    'Republic of the Gambia' => 'gamb',
+    'Republic of Georgia' => 'geor',
+    'Federal Republic of Germany' => 'germ',
+    'Republic of Ghana' => 'ghan',
+    'Gibraltar' => 'gibr',
+    'Hellenic Republic' => 'grec',
+    'State of Grenada' => 'gren',
+    'Overseas Department of Guadeloupe' => 'guad',
+    'Territory of Guam' => 'guam',
+    'Republic of Guatemala' => 'guat',
+    'The Bailiwick of Guernsey' => 'guer',
+    'Republic of Guinea' => 'guin',
+    'Republic of Haiti' => 'hait',
+    'Hong Kong Special Administrative Region' => 'hokn',
+    'Republic of Honduras' => 'hond',
+    'Republic of Hungary' => 'hung',
+    'Republic of Iceland' => 'icel',
+    'International Committee of the Red Cross' => 'icrc',
+    'Republic of India' => 'inda',
+    'Republic of Indonesia' => 'indn',
+    'Republic of Iraq' => 'iraq',
+    'Republic of Ireland' => 'irel',
+    'Organization of the Islamic Conference' => 'isco',
+    'Isle of Man' => 'isma',
+    'State of Israel' => 'isra',
+    'Italian Republic' => 'ital',
+    'Jamaica' => 'jama',
+    'Japan' => 'japa',
+    'The Bailiwick of Jersey' => 'jers',
+    'Hashemite Kingdom of Jordan' => 'jord',
+    'Republic of Kazakhstan' => 'kazk',
+    'Republic of Kenya' => 'keny',
+    'Republic of Kiribati' => 'kirb',
+    'State of Kuwait' => 'kuwa',
+    'Kyrgyz Republic' => 'kyrg',
+    'Republic of Latvia' => 'latv',
+    'Lebanese Republic' => 'leba',
+    'Kingdom of Lesotho' => 'lest',
+    'Republic of Liberia' => 'libe',
+    'Principality of Liechtenstein' => 'liec',
+    'Republic of Lithuania' => 'lith',
+    'Grand Duchy of Luxembourg' => 'luxe',
+    'Macao Special Administrative Region' => 'maca',
+    'Republic of Macedonia' => 'mace',
+    'Republic of Madagascar' => 'mada',
+    'Republic of the Marshall Islands' => 'mais',
+    'Republic of Mali' => 'mali',
+    'Federation of Malaysia' => 'mals',
+    'Republic of Malta' => 'malt',
+    'Republic of Malawi' => 'malw',
+    'Overseas Department of Martinique' => 'mart',
+    'Islamic Republic of Mauritania' => 'maur',
+    'Territorial Collectivity of Mayotte' => 'mayt',
+    'United Mexican States' => 'mexc',
+    'Federated States of Micronesia' => 'micr',
+    'Midway Islands' => 'miis',
+    'Republic of Moldova' => 'mold',
+    'Principality of Monaco' => 'mona',
+    'Republic of Mongolia' => 'mong',
+    'British Overseas Territory of Montserrat' => 'mont',
+    'Kingdom of Morocco' => 'morc',
+    'Republic of Mozambique' => 'moza',
+    'Republic of Mauritius' => 'mrts',
+    'Union of Myanmar' => 'myan',
+    'Republic of Namibia' => 'namb',
+    'North Atlantic Treaty Organization' => 'nato',
+    'Republic of Nauru' => 'naur',
+    'Turkish Republic of Northern Cyprus' => 'ncyp',
+    'Netherlands Antilles' => 'nean',
+    'Kingdom of Nepal' => 'nepa',
+    'Kingdom of the Netherlands' => 'neth',
+    'Territory of Norfolk Island' => 'nfis',
+    'Federal Republic of Nigeria' => 'ngra',
+    'Republic of Nicaragua' => 'nica',
+    'Republic of Niger' => 'nigr',
+    'Niue' => 'niue',
+    'Commonwealth of the Northern Mariana Islands' => 'nmar',
+    'Province of Northern Ireland' => 'noir',
+    'Nordic Council' => 'nord',
+    'Kingdom of Norway' => 'norw',
+    'Territory of New Caledonia and Dependencies' => 'nwca',
+    'New Zealand' => 'nwze',
+    'Organization of American States' => 'oast',
+    'Organization of African Unity' => 'oaun',
+    'International Olympic Committee' => 'olym',
+    'Sultanate of Oman' => 'oman',
+    'Islamic Republic of Pakistan' => 'paks',
+    'Republic of Palau' => 'pala',
+    'Independent State of Papua New Guinea' => 'pang',
+    'Republic of Paraguay' => 'para',
+    'Republic of Peru' => 'peru',
+    'Republic of the Philippines' => 'phil',
+    'British Overseas Territory of the Pitcairn Islands' => 'piis',
+    'Republic of Poland' => 'pola',
+    'Republic of Portugal' => 'port',
+    'Commonwealth of Puerto Rico' => 'purc',
+    'State of Qatar' => 'qata',
+    'Russian Federation' => 'russ',
+    'Romania' => 'rmna',
+    'Republic of Rwanda' => 'rwan',
+    'Kingdom of Saudi Arabia' => 'saar',
+    'Republic of San Marino' => 'sama',
+    'Nordic Sami Conference' => 'sami',
+    'Sark' => 'sark',
+    'Scotland' => 'scot',
+    'Principality of Seborga' => 'sebo',
+    'Republic of Serbia' => 'serb',
+    'Republic of Sierra Leone' => 'sile',
+    'Republic of Singapore' => 'sing',
+    'Republic of Korea' => 'skor',
+    'Republic of Slovenia' => 'slva',
+    'Somali Republic' => 'smla',
+    'Republic of Somaliland' => 'smld',
+    'Republic of South Africa' => 'soaf',
+    'Solomon Islands' => 'sois',
+    'Kingdom of Spain' => 'span',
+    'Secretariat of the Pacific Community' => 'spco',
+    'Democratic Socialist Republic of Sri Lanka' => 'srla',
+    'Saint Lucia' => 'stlu',
+    'Republic of the Sudan' => 'suda',
+    'Republic of Suriname' => 'surn',
+    'Slovak Republic' => 'svka',
+    'Kingdom of Sweden' => 'swdn',
+    'Swiss Confederation' => 'swit',
+    'Syrian Arab Republic' => 'syra',
+    'Kingdom of Swaziland' => 'szld',
+    'Republic of China' => 'taiw',
+    'Taiwan' => 'taiw',
+    'Republic of Tajikistan' => 'tajk',
+    'United Republic of Tanzania' => 'tanz',
+    'Kingdom of Thailand' => 'thal',
+    'Autonomous Region of Tibet' => 'tibe',
+    'Turkmenistan' => 'tkst',
+    'Togolese Republic' => 'togo',
+    'Tokelau' => 'toke',
+    'Kingdom of Tonga' => 'tong',
+    'Tristan da Cunha' => 'trdc',
+    'Tromelin' => 'tris',
+    'Republic of Tunisia' => 'tuns',
+    'Republic of Turkey' => 'turk',
+    'Tuvalu' => 'tuva',
+    'United Arab Emirates' => 'uaem',
+    'Republic of Uganda' => 'ugan',
+    'Ukraine' => 'ukrn',
+    'United Kingdom of Great Britain' => 'unkg',
+    'United Nations' => 'unna',
+    'United States of America' => 'unst',
+    'Oriental Republic of Uruguay' => 'urgy',
+    'Virgin Islands of the United States' => 'usvs',
+    'Republic of Uzbekistan' => 'uzbk',
+    'State of the Vatican City' => 'vacy',
+    'Republic of Vanuatu' => 'vant',
+    'Bolivarian Republic of Venezuela' => 'venz',
+    'Republic of Yemen' => 'yemn',
+    'Democratic Republic of Congo' => 'zare',
+    'Republic of Zimbabwe' => 'zbwe' ) ;
+
+
+    private $iFlagCount = -1;
+    private $iFlagSetMap = array(
+    FLAGSIZE1 => 'flags_thumb35x35',
+    FLAGSIZE2 => 'flags_thumb60x60',
+    FLAGSIZE3 => 'flags_thumb100x100',
+    FLAGSIZE4 => 'flags'
+    );
+
+    private $iFlagData ;
+    private $iOrdIdx=array();
+
+    function FlagImages($aSize=FLAGSIZE1) {
+        switch($aSize) {
+            case FLAGSIZE1 :
+            case FLAGSIZE2 :
+            case FLAGSIZE3 :
+            case FLAGSIZE4 :
+                $file = dirname(__FILE__).'/'.$this->iFlagSetMap[$aSize].'.dat';
+                $fp = fopen($file,'rb');
+                $rawdata = fread($fp,filesize($file));
+                $this->iFlagData = unserialize($rawdata);
+                break;
+            default:
+                JpGraphError::RaiseL(5001,$aSize);
+                //('Unknown flag size. ('.$aSize.')');
+        }
+        $this->iFlagCount = count($this->iCountryNameMap);
+    }
+
+    function GetNum() {
+        return $this->iFlagCount;
+    }
+
+    function GetImgByName($aName,&$outFullName) {
+        $idx = $this->GetIdxByName($aName,$outFullName);
+        return $this->GetImgByIdx($idx);
+    }
+
+    function GetImgByIdx($aIdx) {
+        if( array_key_exists($aIdx,$this->iFlagData) ) {
+            $d = $this->iFlagData[$aIdx][1];
+            return Image::CreateFromString($d);
+        }
+        else {
+            JpGraphError::RaiseL(5002,$aIdx);
+            //("Flag index \"�$aIdx\" does not exist.");
+        }
+    }
+
+    function GetIdxByOrdinal($aOrd,&$outFullName) {
+        $aOrd--;
+        $n = count($this->iOrdIdx);
+        if( $n == 0 ) {
+            reset($this->iCountryNameMap);
+            $this->iOrdIdx=array();
+            $i=0;
+            while( list($key,$val) = each($this->iCountryNameMap) ) {
+                $this->iOrdIdx[$i++] = array($val,$key);
+            }
+            $tmp=$this->iOrdIdx[$aOrd];
+            $outFullName = $tmp[1];
+            return $tmp[0];
+             
+        }
+        elseif( $aOrd >= 0 && $aOrd < $n ) {
+            $tmp=$this->iOrdIdx[$aOrd];
+            $outFullName = $tmp[1];
+            return $tmp[0];
+        }
+        else {
+            JpGraphError::RaiseL(5003,$aOrd);
+            //('Invalid ordinal number specified for flag index.');
+        }
+    }
+
+    function GetIdxByName($aName,&$outFullName) {
+
+        if( is_integer($aName) ) {
+            $idx = $this->GetIdxByOrdinal($aName,$outFullName);
+            return $idx;
+        }
+
+        $found=false;
+        $aName = strtolower($aName);
+        $nlen = strlen($aName);
+        reset($this->iCountryNameMap);
+        // Start by trying to match exact index name
+        while( list($key,$val) = each($this->iCountryNameMap) ) {
+            if( $nlen == strlen($val) && $val == $aName )  {
+                $found=true;
+                break;
+            }
+        }
+        if( !$found ) {
+            reset($this->iCountryNameMap);
+            // If the exact index doesn't work try a (partial) full name
+            while( list($key,$val) = each($this->iCountryNameMap) ) {
+                if( strpos(strtolower($key), $aName) !== false ) {
+                    $found=true;
+                    break;
+                }
+            }
+        }
+        if( $found ) {
+            $outFullName = $key;
+            return $val;
+        }
+        else {
+            JpGraphError::RaiseL(5004,$aName);
+            //("The (partial) country name \"$aName\" does not have a cooresponding flag image. The flag may still exist but under another name, e.g. insted of \"usa\" try \"united states\".");
+        }
+    }
+}
+
+
+
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_gantt.php b/web/classes/jpgraph/jpgraph_gantt.php
new file mode 100755
index 0000000000000000000000000000000000000000..d5afa65480a303f1075cedc4fa110f0b69e646be
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_gantt.php
@@ -0,0 +1,3955 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_GANTT.PHP
+ // Description: JpGraph Gantt plot extension
+ // Created:     2001-11-12
+ // Ver:         $Id: jpgraph_gantt.php 1809 2009-09-09 13:07:33Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+require_once('jpgraph_plotband.php');
+require_once('jpgraph_iconplot.php');
+require_once('jpgraph_plotmark.inc.php');
+
+// Maximum size for Automatic Gantt chart
+define('MAX_GANTTIMG_SIZE_W',8000);
+define('MAX_GANTTIMG_SIZE_H',5000);
+
+// Scale Header types
+define("GANTT_HDAY",1);
+define("GANTT_HWEEK",2);
+define("GANTT_HMONTH",4);
+define("GANTT_HYEAR",8);
+define("GANTT_HHOUR",16);
+define("GANTT_HMIN",32);
+
+// Bar patterns
+define("GANTT_RDIAG",BAND_RDIAG); // Right diagonal lines
+define("GANTT_LDIAG",BAND_LDIAG); // Left diagonal lines
+define("GANTT_SOLID",BAND_SOLID); // Solid one color
+define("GANTT_VLINE",BAND_VLINE); // Vertical lines
+define("GANTT_HLINE",BAND_HLINE);  // Horizontal lines
+define("GANTT_3DPLANE",BAND_3DPLANE);  // "3D" Plane
+define("GANTT_HVCROSS",BAND_HVCROSS);  // Vertical/Hor crosses
+define("GANTT_DIAGCROSS",BAND_DIAGCROSS); // Diagonal crosses
+
+// Conversion constant
+define("SECPERDAY",3600*24);
+
+// Locales. ONLY KEPT FOR BACKWARDS COMPATIBILITY
+// You should use the proper locale strings directly
+// from now on.
+define("LOCALE_EN","en_UK");
+define("LOCALE_SV","sv_SE");
+
+// Layout of bars
+define("GANTT_EVEN",1);
+define("GANTT_FROMTOP",2);
+
+// Style for minute header
+define("MINUTESTYLE_MM",0);  // 15
+define("MINUTESTYLE_CUSTOM",2);  // Custom format
+
+
+// Style for hour header
+define("HOURSTYLE_HM24",0);  // 13:10
+define("HOURSTYLE_HMAMPM",1);  // 1:10pm
+define("HOURSTYLE_H24",2);  // 13
+define("HOURSTYLE_HAMPM",3);  // 1pm
+define("HOURSTYLE_CUSTOM",4);  // User defined
+
+// Style for day header
+define("DAYSTYLE_ONELETTER",0);  // "M"
+define("DAYSTYLE_LONG",1);  // "Monday"
+define("DAYSTYLE_LONGDAYDATE1",2); // "Monday 23 Jun"
+define("DAYSTYLE_LONGDAYDATE2",3); // "Monday 23 Jun 2003"
+define("DAYSTYLE_SHORT",4);  // "Mon"
+define("DAYSTYLE_SHORTDAYDATE1",5); // "Mon 23/6"
+define("DAYSTYLE_SHORTDAYDATE2",6); // "Mon 23 Jun"
+define("DAYSTYLE_SHORTDAYDATE3",7); // "Mon 23"
+define("DAYSTYLE_SHORTDATE1",8); // "23/6"
+define("DAYSTYLE_SHORTDATE2",9); // "23 Jun"
+define("DAYSTYLE_SHORTDATE3",10); // "Mon 23"
+define("DAYSTYLE_SHORTDATE4",11); // "23"
+define("DAYSTYLE_CUSTOM",12);  // "M"
+
+// Styles for week header
+define("WEEKSTYLE_WNBR",0);
+define("WEEKSTYLE_FIRSTDAY",1);
+define("WEEKSTYLE_FIRSTDAY2",2);
+define("WEEKSTYLE_FIRSTDAYWNBR",3);
+define("WEEKSTYLE_FIRSTDAY2WNBR",4);
+
+// Styles for month header
+define("MONTHSTYLE_SHORTNAME",0);
+define("MONTHSTYLE_LONGNAME",1);
+define("MONTHSTYLE_LONGNAMEYEAR2",2);
+define("MONTHSTYLE_SHORTNAMEYEAR2",3);
+define("MONTHSTYLE_LONGNAMEYEAR4",4);
+define("MONTHSTYLE_SHORTNAMEYEAR4",5);
+define("MONTHSTYLE_FIRSTLETTER",6);
+
+
+// Types of constrain links
+define('CONSTRAIN_STARTSTART',0);
+define('CONSTRAIN_STARTEND',1);
+define('CONSTRAIN_ENDSTART',2);
+define('CONSTRAIN_ENDEND',3);
+
+// Arrow direction for constrain links
+define('ARROW_DOWN',0);
+define('ARROW_UP',1);
+define('ARROW_LEFT',2);
+define('ARROW_RIGHT',3);
+
+// Arrow type for constrain type
+define('ARROWT_SOLID',0);
+define('ARROWT_OPEN',1);
+
+// Arrow size for constrain lines
+define('ARROW_S1',0);
+define('ARROW_S2',1);
+define('ARROW_S3',2);
+define('ARROW_S4',3);
+define('ARROW_S5',4);
+
+// Activity types for use with utility method CreateSimple()
+define('ACTYPE_NORMAL',0);
+define('ACTYPE_GROUP',1);
+define('ACTYPE_MILESTONE',2);
+
+define('ACTINFO_3D',1);
+define('ACTINFO_2D',0);
+
+
+// Check if array_fill() exists
+if (!function_exists('array_fill')) {
+    function array_fill($iStart, $iLen, $vValue) {
+        $aResult = array();
+        for ($iCount = $iStart; $iCount < $iLen + $iStart; $iCount++) {
+            $aResult[$iCount] = $vValue;
+        }
+        return $aResult;
+    }
+}
+
+//===================================================
+// CLASS GanttActivityInfo
+// Description:
+//===================================================
+class GanttActivityInfo {
+    public $iShow=true;
+    public $iLeftColMargin=4,$iRightColMargin=1,$iTopColMargin=1,$iBottomColMargin=3;
+    public $vgrid = null;
+    private $iColor='black';
+    private $iBackgroundColor='lightgray';
+    private $iFFamily=FF_FONT1,$iFStyle=FS_NORMAL,$iFSize=10,$iFontColor='black';
+    private $iTitles=array();
+    private $iWidth=array(),$iHeight=-1;
+    private $iTopHeaderMargin = 4;
+    private $iStyle=1;
+    private $iHeaderAlign='center';
+
+    function __construct() {
+        $this->vgrid = new LineProperty();
+    }
+
+    function Hide($aF=true) {
+        $this->iShow=!$aF;
+    }
+
+    function Show($aF=true) {
+        $this->iShow=$aF;
+    }
+
+    // Specify font
+    function SetFont($aFFamily,$aFStyle=FS_NORMAL,$aFSize=10) {
+        $this->iFFamily = $aFFamily;
+        $this->iFStyle  = $aFStyle;
+        $this->iFSize  = $aFSize;
+    }
+
+    function SetStyle($aStyle) {
+        $this->iStyle = $aStyle;
+    }
+
+    function SetColumnMargin($aLeft,$aRight) {
+        $this->iLeftColMargin = $aLeft;
+        $this->iRightColMargin = $aRight;
+    }
+
+    function SetFontColor($aFontColor) {
+        $this->iFontColor = $aFontColor;
+    }
+
+    function SetColor($aColor) {
+        $this->iColor = $aColor;
+    }
+
+    function SetBackgroundColor($aColor) {
+        $this->iBackgroundColor = $aColor;
+    }
+
+    function SetColTitles($aTitles,$aWidth=null) {
+        $this->iTitles = $aTitles;
+        $this->iWidth = $aWidth;
+    }
+
+    function SetMinColWidth($aWidths) {
+        $n = min(count($this->iTitles),count($aWidths));
+        for($i=0; $i < $n; ++$i ) {
+            if( !empty($aWidths[$i]) ) {
+                if( empty($this->iWidth[$i]) ) {
+                    $this->iWidth[$i] = $aWidths[$i];
+                }
+                else {
+                    $this->iWidth[$i] = max($this->iWidth[$i],$aWidths[$i]);
+                }
+            }
+        }
+    }
+
+    function GetWidth($aImg) {
+        $txt = new TextProperty();
+        $txt->SetFont($this->iFFamily,$this->iFStyle,$this->iFSize);
+        $n = count($this->iTitles) ;
+        $rm=$this->iRightColMargin;
+        $w = 0;
+        for($h=0, $i=0; $i < $n; ++$i ) {
+            $w += $this->iLeftColMargin;
+            $txt->Set($this->iTitles[$i]);
+            if( !empty($this->iWidth[$i]) ) {
+                $w1 = max($txt->GetWidth($aImg)+$rm,$this->iWidth[$i]);
+            }
+            else {
+                $w1 = $txt->GetWidth($aImg)+$rm;
+            }
+            $this->iWidth[$i] = $w1;
+            $w += $w1;
+            $h = max($h,$txt->GetHeight($aImg));
+        }
+        $this->iHeight = $h+$this->iTopHeaderMargin;
+        $txt='';
+        return $w;
+    }
+
+    function GetColStart($aImg,&$aStart,$aAddLeftMargin=false) {
+        $n = count($this->iTitles) ;
+        $adj = $aAddLeftMargin ? $this->iLeftColMargin : 0;
+        $aStart=array($aImg->left_margin+$adj);
+        for( $i=1; $i < $n; ++$i ) {
+            $aStart[$i] = $aStart[$i-1]+$this->iLeftColMargin+$this->iWidth[$i-1];
+        }
+    }
+
+    // Adjust headers left, right or centered
+    function SetHeaderAlign($aAlign) {
+        $this->iHeaderAlign=$aAlign;
+    }
+
+    function Stroke($aImg,$aXLeft,$aYTop,$aXRight,$aYBottom,$aUseTextHeight=false) {
+
+        if( !$this->iShow ) return;
+
+        $txt = new TextProperty();
+        $txt->SetFont($this->iFFamily,$this->iFStyle,$this->iFSize);
+        $txt->SetColor($this->iFontColor);
+        $txt->SetAlign($this->iHeaderAlign,'top');
+        $n=count($this->iTitles);
+
+        if( $n == 0 )
+        return;
+
+        $x = $aXLeft;
+        $h = $this->iHeight;
+        $yTop = $aUseTextHeight ? $aYBottom-$h-$this->iTopColMargin-$this->iBottomColMargin : $aYTop ;
+
+        if( $h < 0 ) {
+            JpGraphError::RaiseL(6001);
+            //('Internal error. Height for ActivityTitles is < 0');
+        }
+
+        $aImg->SetLineWeight(1);
+        // Set background color
+        $aImg->SetColor($this->iBackgroundColor);
+        $aImg->FilledRectangle($aXLeft,$yTop,$aXRight,$aYBottom-1);
+
+        if( $this->iStyle == 1 ) {
+            // Make a 3D effect
+            $aImg->SetColor('white');
+            $aImg->Line($aXLeft,$yTop+1,$aXRight,$yTop+1);
+        }
+
+        for($i=0; $i < $n; ++$i ) {
+            if( $this->iStyle == 1 ) {
+                // Make a 3D effect
+                $aImg->SetColor('white');
+                $aImg->Line($x+1,$yTop,$x+1,$aYBottom);
+            }
+            $x += $this->iLeftColMargin;
+            $txt->Set($this->iTitles[$i]);
+
+            // Adjust the text anchor position according to the choosen alignment
+            $xp = $x;
+            if( $this->iHeaderAlign == 'center' ) {
+                $xp = (($x-$this->iLeftColMargin)+($x+$this->iWidth[$i]))/2;
+            }
+            elseif( $this->iHeaderAlign == 'right' ) {
+                $xp = $x +$this->iWidth[$i]-$this->iRightColMargin;
+            }
+
+            $txt->Stroke($aImg,$xp,$yTop+$this->iTopHeaderMargin);
+            $x += $this->iWidth[$i];
+            if( $i < $n-1 ) {
+                $aImg->SetColor($this->iColor);
+                $aImg->Line($x,$yTop,$x,$aYBottom);
+            }
+        }
+
+        $aImg->SetColor($this->iColor);
+        $aImg->Line($aXLeft,$yTop, $aXRight,$yTop);
+
+        // Stroke vertical column dividers
+        $cols=array();
+        $this->GetColStart($aImg,$cols);
+        $n=count($cols);
+        for( $i=1; $i < $n; ++$i ) {
+            $this->vgrid->Stroke($aImg,$cols[$i],$aYBottom,$cols[$i],
+            $aImg->height - $aImg->bottom_margin);
+        }
+    }
+}
+
+
+//===================================================
+// CLASS GanttGraph
+// Description: Main class to handle gantt graphs
+//===================================================
+class GanttGraph extends Graph {
+    public $scale;  // Public accessible
+    public $hgrid=null;
+    private $iObj=array();    // Gantt objects
+    private $iLabelHMarginFactor=0.2; // 10% margin on each side of the labels
+    private $iLabelVMarginFactor=0.4; // 40% margin on top and bottom of label
+    private $iLayout=GANTT_FROMTOP; // Could also be GANTT_EVEN
+    private $iSimpleFont = FF_FONT1,$iSimpleFontSize=11;
+    private $iSimpleStyle=GANTT_RDIAG,$iSimpleColor='yellow',$iSimpleBkgColor='red';
+    private $iSimpleProgressBkgColor='gray',$iSimpleProgressColor='darkgreen';
+    private $iSimpleProgressStyle=GANTT_SOLID;
+    private $iZoomFactor = 1.0;
+    //---------------
+    // CONSTRUCTOR
+    // Create a new gantt graph
+    function __construct($aWidth=0,$aHeight=0,$aCachedName="",$aTimeOut=0,$aInline=true) {
+
+        // Backward compatibility
+        if( $aWidth == -1 ) $aWidth=0;
+        if( $aHeight == -1 ) $aHeight=0;
+
+        if( $aWidth<  0 || $aHeight < 0 ) {
+            JpgraphError::RaiseL(6002);
+            //("You can't specify negative sizes for Gantt graph dimensions. Use 0 to indicate that you want the library to automatically determine a dimension.");
+        }
+        parent::__construct($aWidth,$aHeight,$aCachedName,$aTimeOut,$aInline);
+        $this->scale = new GanttScale($this->img);
+
+        // Default margins
+        $this->img->SetMargin(15,17,25,15);
+
+        $this->hgrid = new HorizontalGridLine();
+
+        $this->scale->ShowHeaders(GANTT_HWEEK|GANTT_HDAY);
+        $this->SetBox();
+    }
+
+    //---------------
+    // PUBLIC METHODS
+
+    //
+
+    function SetSimpleFont($aFont,$aSize) {
+        $this->iSimpleFont = $aFont;
+        $this->iSimpleFontSize = $aSize;
+    }
+
+    function SetSimpleStyle($aBand,$aColor,$aBkgColor) {
+        $this->iSimpleStyle = $aBand;
+        $this->iSimpleColor = $aColor;
+        $this->iSimpleBkgColor = $aBkgColor;
+    }
+
+    // A utility function to help create basic Gantt charts
+    function CreateSimple($data,$constrains=array(),$progress=array()) {
+        $num = count($data);
+        for( $i=0; $i < $num; ++$i) {
+            switch( $data[$i][1] ) {
+                case ACTYPE_GROUP:
+                    // Create a slightly smaller height bar since the
+                    // "wings" at the end will make it look taller
+                    $a = new GanttBar($data[$i][0],$data[$i][2],$data[$i][3],$data[$i][4],'',8);
+                    $a->title->SetFont($this->iSimpleFont,FS_BOLD,$this->iSimpleFontSize);
+                    $a->rightMark->Show();
+                    $a->rightMark->SetType(MARK_RIGHTTRIANGLE);
+                    $a->rightMark->SetWidth(8);
+                    $a->rightMark->SetColor('black');
+                    $a->rightMark->SetFillColor('black');
+
+                    $a->leftMark->Show();
+                    $a->leftMark->SetType(MARK_LEFTTRIANGLE);
+                    $a->leftMark->SetWidth(8);
+                    $a->leftMark->SetColor('black');
+                    $a->leftMark->SetFillColor('black');
+
+                    $a->SetPattern(BAND_SOLID,'black');
+                    $csimpos = 6;
+                    break;
+
+                case ACTYPE_NORMAL:
+                    $a = new GanttBar($data[$i][0],$data[$i][2],$data[$i][3],$data[$i][4],'',10);
+                    $a->title->SetFont($this->iSimpleFont,FS_NORMAL,$this->iSimpleFontSize);
+                    $a->SetPattern($this->iSimpleStyle,$this->iSimpleColor);
+                    $a->SetFillColor($this->iSimpleBkgColor);
+                    // Check if this activity should have a constrain line
+                    $n = count($constrains);
+                    for( $j=0; $j < $n; ++$j ) {
+                        if( empty($constrains[$j]) || (count($constrains[$j]) != 3) ) {
+                            JpGraphError::RaiseL(6003,$j);
+                            //("Invalid format for Constrain parameter at index=$j in CreateSimple(). Parameter must start with index 0 and contain arrays of (Row,Constrain-To,Constrain-Type)");
+                        }
+                        if( $constrains[$j][0]==$data[$i][0] ) {
+                            $a->SetConstrain($constrains[$j][1],$constrains[$j][2],'black',ARROW_S2,ARROWT_SOLID);
+                        }
+                    }
+
+                    // Check if this activity have a progress bar
+                    $n = count($progress);
+                    for( $j=0; $j < $n; ++$j ) {
+
+                        if( empty($progress[$j]) || (count($progress[$j]) != 2) ) {
+                            JpGraphError::RaiseL(6004,$j);
+                            //("Invalid format for Progress parameter at index=$j in CreateSimple(). Parameter must start with index 0 and contain arrays of (Row,Progress)");
+                        }
+                        if( $progress[$j][0]==$data[$i][0] ) {
+                            $a->progress->Set($progress[$j][1]);
+                            $a->progress->SetPattern($this->iSimpleProgressStyle,
+                            $this->iSimpleProgressColor);
+                            $a->progress->SetFillColor($this->iSimpleProgressBkgColor);
+                            //$a->progress->SetPattern($progress[$j][2],$progress[$j][3]);
+                            break;
+                        }
+                    }
+                    $csimpos = 6;
+                    break;
+
+                case ACTYPE_MILESTONE:
+                    $a = new MileStone($data[$i][0],$data[$i][2],$data[$i][3]);
+                    $a->title->SetFont($this->iSimpleFont,FS_NORMAL,$this->iSimpleFontSize);
+                    $a->caption->SetFont($this->iSimpleFont,FS_NORMAL,$this->iSimpleFontSize);
+                    $csimpos = 5;
+                    break;
+                default:
+                    die('Unknown activity type');
+                    break;
+            }
+
+            // Setup caption
+            $a->caption->Set($data[$i][$csimpos-1]);
+
+            // Check if this activity should have a CSIM target�?
+            if( !empty($data[$i][$csimpos]) ) {
+                $a->SetCSIMTarget($data[$i][$csimpos]);
+                $a->SetCSIMAlt($data[$i][$csimpos+1]);
+            }
+            if( !empty($data[$i][$csimpos+2]) ) {
+                $a->title->SetCSIMTarget($data[$i][$csimpos+2]);
+                $a->title->SetCSIMAlt($data[$i][$csimpos+3]);
+            }
+
+            $this->Add($a);
+        }
+    }
+
+    // Set user specified scale zoom factor when auto sizing is used
+    function SetZoomFactor($aZoom) {
+    	$this->iZoomFactor = $aZoom;
+    }
+
+
+    // Set what headers should be shown
+    function ShowHeaders($aFlg) {
+        $this->scale->ShowHeaders($aFlg);
+    }
+
+    // Specify the fraction of the font height that should be added
+    // as vertical margin
+    function SetLabelVMarginFactor($aVal) {
+        $this->iLabelVMarginFactor = $aVal;
+    }
+
+    // Synonym to the method above
+    function SetVMarginFactor($aVal) {
+        $this->iLabelVMarginFactor = $aVal;
+    }
+
+
+    // Add a new Gantt object
+    function Add($aObject) {
+        if( is_array($aObject) && count($aObject) > 0 ) {
+            $cl = $aObject[0];
+            if( class_exists('IconPlot',false) && ($cl instanceof IconPlot) ) {
+                $this->AddIcon($aObject);
+            }
+            elseif( class_exists('Text',false) && ($cl instanceof Text) ) {
+            	$this->AddText($aObject);
+            }
+            else {
+                $n = count($aObject);
+                for($i=0; $i < $n; ++$i)
+                $this->iObj[] = $aObject[$i];
+            }
+        }
+        else {
+            if( class_exists('IconPlot',false) && ($aObject instanceof IconPlot) ) {
+                $this->AddIcon($aObject);
+            }
+            elseif( class_exists('Text',false) && ($aObject instanceof Text) ) {
+            	$this->AddText($aObject);
+            }
+            else {
+                $this->iObj[] = $aObject;
+            }
+        }
+    }
+
+	function StrokeTexts() {
+        // Stroke any user added text objects
+        if( $this->texts != null ) {
+        	$n = count($this->texts);
+            for($i=0; $i < $n; ++$i) {
+            	if( $this->texts[$i]->iScalePosX !== null && $this->texts[$i]->iScalePosY !== null ) {
+            		$x = $this->scale->TranslateDate($this->texts[$i]->iScalePosX);
+            		$y = $this->scale->TranslateVertPos($this->texts[$i]->iScalePosY);
+            		$y -= $this->scale->GetVertSpacing()/2;
+            	}
+            	else {
+            		$x = $y = null;
+            	}
+                $this->texts[$i]->Stroke($this->img,$x,$y);
+            }
+        }
+	}
+
+    // Override inherit method from Graph and give a warning message
+    function SetScale($aAxisType,$aYMin=1,$aYMax=1,$aXMin=1,$aXMax=1) {
+        JpGraphError::RaiseL(6005);
+        //("SetScale() is not meaningfull with Gantt charts.");
+    }
+
+    // Specify the date range for Gantt graphs (if this is not set it will be
+    // automtically determined from the input data)
+    function SetDateRange($aStart,$aEnd) {
+        // Adjust the start and end so that the indicate the
+        // begining and end of respective start and end days
+        if( strpos($aStart,':') === false )
+        $aStart = date('Y-m-d 00:00',strtotime($aStart));
+        if( strpos($aEnd,':') === false )
+        $aEnd = date('Y-m-d 23:59',strtotime($aEnd));
+        $this->scale->SetRange($aStart,$aEnd);
+    }
+
+    // Get the maximum width of the activity titles columns for the bars
+    // The name is lightly misleading since we from now on can have
+    // multiple columns in the label section. When this was first written
+    // it only supported a single label, hence the name.
+    function GetMaxLabelWidth() {
+        $m=10;
+        if( $this->iObj != null ) {
+            $marg = $this->scale->actinfo->iLeftColMargin+$this->scale->actinfo->iRightColMargin;
+            $n = count($this->iObj);
+            for($i=0; $i < $n; ++$i) {
+                if( !empty($this->iObj[$i]->title) ) {
+                    if( $this->iObj[$i]->title->HasTabs() ) {
+                        list($tot,$w) = $this->iObj[$i]->title->GetWidth($this->img,true);
+                        $m=max($m,$tot);
+                    }
+                    else
+                    $m=max($m,$this->iObj[$i]->title->GetWidth($this->img));
+                }
+            }
+        }
+        return $m;
+    }
+
+    // Get the maximum height of the titles for the bars
+    function GetMaxLabelHeight() {
+        $m=10;
+        if( $this->iObj != null ) {
+            $n = count($this->iObj);
+            // We can not include the title of GnttVLine since that title is stroked at the bottom
+            // of the Gantt bar and not in the activity title columns
+            for($i=0; $i < $n; ++$i) {
+                if( !empty($this->iObj[$i]->title) && !($this->iObj[$i] instanceof GanttVLine) ) {
+                    $m=max($m,$this->iObj[$i]->title->GetHeight($this->img));
+                }
+            }
+        }
+        return $m;
+    }
+
+    function GetMaxBarAbsHeight() {
+        $m=0;
+        if( $this->iObj != null ) {
+            $m = $this->iObj[0]->GetAbsHeight($this->img);
+            $n = count($this->iObj);
+            for($i=1; $i < $n; ++$i) {
+                $m=max($m,$this->iObj[$i]->GetAbsHeight($this->img));
+            }
+        }
+        return $m;
+    }
+
+    // Get the maximum used line number (vertical position) for bars
+    function GetBarMaxLineNumber() {
+        $m=1;
+        if( $this->iObj != null ) {
+            $m = $this->iObj[0]->GetLineNbr();
+            $n = count($this->iObj);
+            for($i=1; $i < $n; ++$i) {
+                $m=max($m,$this->iObj[$i]->GetLineNbr());
+            }
+        }
+        return $m;
+    }
+
+    // Get the minumum and maximum used dates for all bars
+    function GetBarMinMax() {
+        $start = 0 ;
+        $n = count($this->iObj);
+        while( $start < $n && $this->iObj[$start]->GetMaxDate() === false )
+        ++$start;
+        if( $start >= $n ) {
+            JpgraphError::RaiseL(6006);
+            //('Cannot autoscale Gantt chart. No dated activities exist. [GetBarMinMax() start >= n]');
+        }
+
+        $max=$this->scale->NormalizeDate($this->iObj[$start]->GetMaxDate());
+        $min=$this->scale->NormalizeDate($this->iObj[$start]->GetMinDate());
+
+        for($i=$start+1; $i < $n; ++$i) {
+            $rmax = $this->scale->NormalizeDate($this->iObj[$i]->GetMaxDate());
+            if( $rmax != false )
+            $max=Max($max,$rmax);
+            $rmin = $this->scale->NormalizeDate($this->iObj[$i]->GetMinDate());
+            if( $rmin != false )
+            $min=Min($min,$rmin);
+        }
+        $minDate = date("Y-m-d",$min);
+        $min = strtotime($minDate);
+        $maxDate = date("Y-m-d 23:59",$max);
+        $max = strtotime($maxDate);
+        return array($min,$max);
+    }
+
+    // Create a new auto sized canvas if the user hasn't specified a size
+    // The size is determined by what scale the user has choosen and hence
+    // the minimum width needed to display the headers. Some margins are
+    // also added to make it better looking.
+    function AutoSize() {
+
+        if( $this->img->img == null ) {
+            // The predefined left, right, top, bottom margins.
+            // Note that the top margin might incease depending on
+            // the title.
+           $hadj = $vadj = 0;
+           if( $this->doshadow ) {
+           		$hadj = $this->shadow_width;
+                $vadj = $this->shadow_width+5;
+            }
+
+            $lm = $this->img->left_margin;
+            $rm = $this->img->right_margin +$hadj;
+            $rm += 2 ;
+            $tm = $this->img->top_margin;
+            $bm = $this->img->bottom_margin + $vadj;
+            $bm += 2;
+
+            // If there are any added GanttVLine we must make sure that the
+            // bottom margin is wide enough to hold a title.
+            $n = count($this->iObj);
+        	for($i=0; $i < $n; ++$i) {
+            	if( $this->iObj[$i] instanceof GanttVLine ) {
+					$bm = max($bm,$this->iObj[$i]->title->GetHeight($this->img)+10);
+            	}
+        	}
+
+            // First find out the height
+            $n=$this->GetBarMaxLineNumber()+1;
+            $m=max($this->GetMaxLabelHeight(),$this->GetMaxBarAbsHeight());
+            $height=$n*((1+$this->iLabelVMarginFactor)*$m);
+
+            // Add the height of the scale titles
+            $h=$this->scale->GetHeaderHeight();
+            $height += $h;
+
+            // Calculate the top margin needed for title and subtitle
+            if( $this->title->t != "" ) {
+                $tm += $this->title->GetFontHeight($this->img);
+            }
+            if( $this->subtitle->t != "" ) {
+                $tm += $this->subtitle->GetFontHeight($this->img);
+            }
+
+            // ...and then take the bottom and top plot margins into account
+            $height += $tm + $bm + $this->scale->iTopPlotMargin + $this->scale->iBottomPlotMargin;
+            // Now find the minimum width for the chart required
+
+            // If day scale or smaller is shown then we use the day font width
+            // as the base size unit.
+            // If only weeks or above is displayed we use a modified unit to
+            // get a smaller image.
+            if( $this->scale->IsDisplayHour() || $this->scale->IsDisplayMinute() ) {
+                // Add 2 pixel margin on each side
+                $fw=$this->scale->day->GetFontWidth($this->img)+4;
+            }
+            elseif( $this->scale->IsDisplayWeek() ) {
+                $fw = 8;
+            }
+            elseif( $this->scale->IsDisplayMonth() ) {
+                $fw = 4;
+            }
+            else {
+                $fw = 2;
+            }
+
+            $nd=$this->scale->GetNumberOfDays();
+
+            if( $this->scale->IsDisplayDay() ) {
+                // If the days are displayed we also need to figure out
+                // how much space each day's title will require.
+                switch( $this->scale->day->iStyle ) {
+                    case DAYSTYLE_LONG :
+                        $txt = "Monday";
+                        break;
+                    case DAYSTYLE_LONGDAYDATE1 :
+                        $txt =  "Monday 23 Jun";
+                        break;
+                    case DAYSTYLE_LONGDAYDATE2 :
+                        $txt =  "Monday 23 Jun 2003";
+                        break;
+                    case DAYSTYLE_SHORT :
+                        $txt =  "Mon";
+                        break;
+                    case DAYSTYLE_SHORTDAYDATE1 :
+                        $txt =  "Mon 23/6";
+                        break;
+                    case DAYSTYLE_SHORTDAYDATE2 :
+                        $txt =  "Mon 23 Jun";
+                        break;
+                    case DAYSTYLE_SHORTDAYDATE3 :
+                        $txt =  "Mon 23";
+                        break;
+                    case DAYSTYLE_SHORTDATE1 :
+                        $txt =  "23/6";
+                        break;
+                    case DAYSTYLE_SHORTDATE2 :
+                        $txt =  "23 Jun";
+                        break;
+                    case DAYSTYLE_SHORTDATE3 :
+                        $txt =  "Mon 23";
+                        break;
+                    case DAYSTYLE_SHORTDATE4 :
+                        $txt =  "88";
+                        break;
+                    case DAYSTYLE_CUSTOM :
+                        $txt = date($this->scale->day->iLabelFormStr,strtotime('2003-12-20 18:00'));
+                        break;
+                    case DAYSTYLE_ONELETTER :
+                    default:
+                        $txt = "M";
+                        break;
+                }
+                $fw = $this->scale->day->GetStrWidth($this->img,$txt)+6;
+            }
+
+            // If we have hours enabled we must make sure that each day has enough
+            // space to fit the number of hours to be displayed.
+            if( $this->scale->IsDisplayHour() ) {
+                // Depending on what format the user has choose we need different amount
+                // of space. We therefore create a typical string for the choosen format
+                // and determine the length of that string.
+                switch( $this->scale->hour->iStyle ) {
+                    case HOURSTYLE_HMAMPM:
+                        $txt = '12:00pm';
+                        break;
+                    case HOURSTYLE_H24:
+                        // 13
+                        $txt = '24';
+                        break;
+                    case HOURSTYLE_HAMPM:
+                        $txt = '12pm';
+                        break;
+                    case HOURSTYLE_CUSTOM:
+                        $txt = date($this->scale->hour->iLabelFormStr,strtotime('2003-12-20 18:00'));
+                        break;
+                    case HOURSTYLE_HM24:
+                    default:
+                        $txt = '24:00';
+                        break;
+                }
+
+                $hfw = $this->scale->hour->GetStrWidth($this->img,$txt)+6;
+                $mw = $hfw;
+                if( $this->scale->IsDisplayMinute() ) {
+                    // Depending on what format the user has choose we need different amount
+                    // of space. We therefore create a typical string for the choosen format
+                    // and determine the length of that string.
+                    switch( $this->scale->minute->iStyle ) {
+                        case HOURSTYLE_CUSTOM:
+                            $txt2 = date($this->scale->minute->iLabelFormStr,strtotime('2005-05-15 18:55'));
+                            break;
+                        case MINUTESTYLE_MM:
+                        default:
+                            $txt2 = '15';
+                            break;
+                    }
+
+                    $mfw = $this->scale->minute->GetStrWidth($this->img,$txt2)+6;
+                    $n2 = ceil(60 / $this->scale->minute->GetIntervall() );
+                    $mw = $n2 * $mfw;
+                }
+                $hfw = $hfw < $mw ? $mw : $hfw ;
+                $n = ceil(24*60 / $this->scale->TimeToMinutes($this->scale->hour->GetIntervall()) );
+                $hw = $n * $hfw;
+                $fw = $fw < $hw ? $hw : $fw ;
+            }
+
+            // We need to repeat this code block here as well.
+            // THIS iS NOT A MISTAKE !
+            // We really need it since we need to adjust for minutes both in the case
+            // where hour scale is shown and when it is not shown.
+
+            if( $this->scale->IsDisplayMinute() ) {
+                // Depending on what format the user has choose we need different amount
+                // of space. We therefore create a typical string for the choosen format
+                // and determine the length of that string.
+                switch( $this->scale->minute->iStyle ) {
+                    case HOURSTYLE_CUSTOM:
+                        $txt = date($this->scale->minute->iLabelFormStr,strtotime('2005-05-15 18:55'));
+                        break;
+                    case MINUTESTYLE_MM:
+                    default:
+                        $txt = '15';
+                        break;
+                }
+
+                $mfw = $this->scale->minute->GetStrWidth($this->img,$txt)+6;
+                $n = ceil(60 / $this->scale->TimeToMinutes($this->scale->minute->GetIntervall()) );
+                $mw = $n * $mfw;
+                $fw = $fw < $mw ? $mw : $fw ;
+            }
+
+            // If we display week we must make sure that 7*$fw is enough
+            // to fit up to 10 characters of the week font (if the week is enabled)
+            if( $this->scale->IsDisplayWeek() ) {
+                // Depending on what format the user has choose we need different amount
+                // of space
+                $fsw = strlen($this->scale->week->iLabelFormStr);
+                if( $this->scale->week->iStyle==WEEKSTYLE_FIRSTDAY2WNBR ) {
+                    $fsw += 8;
+                }
+                elseif( $this->scale->week->iStyle==WEEKSTYLE_FIRSTDAYWNBR ) {
+                    $fsw += 7;
+                }
+                else {
+                    $fsw += 4;
+                }
+
+                $ww = $fsw*$this->scale->week->GetFontWidth($this->img);
+                if( 7*$fw < $ww ) {
+                    $fw = ceil($ww/7);
+                }
+            }
+
+            if( !$this->scale->IsDisplayDay() && !$this->scale->IsDisplayHour() &&
+            	!( ($this->scale->week->iStyle==WEEKSTYLE_FIRSTDAYWNBR ||
+            		$this->scale->week->iStyle==WEEKSTYLE_FIRSTDAY2WNBR) && $this->scale->IsDisplayWeek() ) ) {
+                // If we don't display the individual days we can shrink the
+                // scale a little bit. This is a little bit pragmatic at the
+                // moment and should be re-written to take into account
+                // a) What scales exactly are shown and
+                // b) what format do they use so we know how wide we need to
+                // make each scale text space at minimum.
+                $fw /= 2;
+                if( !$this->scale->IsDisplayWeek() ) {
+                    $fw /= 1.8;
+                }
+            }
+
+            $cw = $this->GetMaxActInfoColWidth() ;
+            $this->scale->actinfo->SetMinColWidth($cw);
+            if( $this->img->width <= 0 ) {
+                // Now determine the width for the activity titles column
+
+                // Firdst find out the maximum width of each object column
+                $titlewidth = max(max($this->GetMaxLabelWidth(),
+                $this->scale->tableTitle->GetWidth($this->img)),
+                $this->scale->actinfo->GetWidth($this->img));
+
+                // Add the width of the vertivcal divider line
+                $titlewidth += $this->scale->divider->iWeight*2;
+
+				// Adjust the width by the user specified zoom factor
+				$fw *= $this->iZoomFactor;
+
+                // Now get the total width taking
+                // titlewidth, left and rigt margin, dayfont size
+                // into account
+                $width = $titlewidth + $nd*$fw + $lm+$rm;
+            }
+            else {
+                $width = $this->img->width;
+            }
+
+            $width = round($width);
+            $height = round($height);
+            // Make a sanity check on image size
+            if( $width > MAX_GANTTIMG_SIZE_W || $height > MAX_GANTTIMG_SIZE_H ) {
+                JpgraphError::RaiseL(6007,$width,$height);
+                //("Sanity check for automatic Gantt chart size failed. Either the width (=$width) or height (=$height) is larger than MAX_GANTTIMG_SIZE. This could potentially be caused by a wrong date in one of the activities.");
+            }
+            $this->img->CreateImgCanvas($width,$height);
+            $this->img->SetMargin($lm,$rm,$tm,$bm);
+        }
+    }
+
+    // Return an array width the maximum width for each activity
+    // column. This is used when we autosize the columns where we need
+    // to find out the maximum width of each column. In order to do that we
+    // must walk through all the objects, sigh...
+    function GetMaxActInfoColWidth() {
+        $n = count($this->iObj);
+        if( $n == 0 ) return;
+        $w = array();
+        $m = $this->scale->actinfo->iLeftColMargin + $this->scale->actinfo->iRightColMargin;
+
+        for( $i=0; $i < $n; ++$i ) {
+            $tmp = $this->iObj[$i]->title->GetColWidth($this->img,$m);
+            $nn = count($tmp);
+            for( $j=0; $j < $nn; ++$j ) {
+                if( empty($w[$j]) )
+                $w[$j] = $tmp[$j];
+                else
+                $w[$j] = max($w[$j],$tmp[$j]);
+            }
+        }
+        return $w;
+    }
+
+    // Stroke the gantt chart
+    function Stroke($aStrokeFileName="") {
+
+        // If the filename is the predefined value = '_csim_special_'
+        // we assume that the call to stroke only needs to do enough
+        // to correctly generate the CSIM maps.
+        // We use this variable to skip things we don't strictly need
+        // to do to generate the image map to improve performance
+        // a best we can. Therefor you will see a lot of tests !$_csim in the
+        // code below.
+        $_csim = ($aStrokeFileName===_CSIM_SPECIALFILE);
+
+        // Should we autoscale dates?
+
+        if( !$this->scale->IsRangeSet() ) {
+            list($min,$max) = $this->GetBarMinMax();
+            $this->scale->SetRange($min,$max);
+        }
+
+        $this->scale->AdjustStartEndDay();
+
+        // Check if we should autoscale the image
+        $this->AutoSize();
+
+        // Should we start from the top or just spread the bars out even over the
+        // available height
+        $this->scale->SetVertLayout($this->iLayout);
+        if( $this->iLayout == GANTT_FROMTOP ) {
+            $maxheight=max($this->GetMaxLabelHeight(),$this->GetMaxBarAbsHeight());
+            $this->scale->SetVertSpacing($maxheight*(1+$this->iLabelVMarginFactor));
+        }
+        // If it hasn't been set find out the maximum line number
+        if( $this->scale->iVertLines == -1 )
+        	$this->scale->iVertLines = $this->GetBarMaxLineNumber()+1;
+
+        $maxwidth=max($this->scale->actinfo->GetWidth($this->img),
+        max($this->GetMaxLabelWidth(),
+        $this->scale->tableTitle->GetWidth($this->img)));
+
+        $this->scale->SetLabelWidth($maxwidth+$this->scale->divider->iWeight);//*(1+$this->iLabelHMarginFactor));
+
+        if( !$_csim ) {
+            $this->StrokePlotArea();
+            if( $this->iIconDepth == DEPTH_BACK ) {
+                $this->StrokeIcons();
+            }
+        }
+
+        $this->scale->Stroke();
+
+        if( !$_csim ) {
+            // Due to a minor off by 1 bug we need to temporarily adjust the margin
+            $this->img->right_margin--;
+            $this->StrokePlotBox();
+            $this->img->right_margin++;
+        }
+
+        // Stroke Grid line
+        $this->hgrid->Stroke($this->img,$this->scale);
+
+        $n = count($this->iObj);
+        for($i=0; $i < $n; ++$i) {
+            //$this->iObj[$i]->SetLabelLeftMargin(round($maxwidth*$this->iLabelHMarginFactor/2));
+            $this->iObj[$i]->Stroke($this->img,$this->scale);
+        }
+
+        $this->StrokeTitles();
+
+        if( !$_csim ) {
+            $this->StrokeConstrains();
+            $this->footer->Stroke($this->img);
+
+
+            if( $this->iIconDepth == DEPTH_FRONT) {
+                $this->StrokeIcons();
+            }
+
+            // Stroke all added user texts
+            $this->StrokeTexts();
+
+            // Should we do any final image transformation
+            if( $this->iImgTrans ) {
+                if( !class_exists('ImgTrans',false) ) {
+                    require_once('jpgraph_imgtrans.php');
+                }
+
+                $tform = new ImgTrans($this->img->img);
+                $this->img->img = $tform->Skew3D($this->iImgTransHorizon,$this->iImgTransSkewDist,
+                $this->iImgTransDirection,$this->iImgTransHighQ,
+                $this->iImgTransMinSize,$this->iImgTransFillColor,
+                $this->iImgTransBorder);
+            }
+
+
+            // If the filename is given as the special "__handle"
+            // then the image handler is returned and the image is NOT
+            // streamed back
+            if( $aStrokeFileName == _IMG_HANDLER ) {
+                return $this->img->img;
+            }
+            else {
+                // Finally stream the generated picture
+                $this->cache->PutAndStream($this->img,$this->cache_name,$this->inline,
+                $aStrokeFileName);
+            }
+        }
+    }
+
+    function StrokeConstrains() {
+        $n = count($this->iObj);
+
+        // Stroke all constrains
+        for($i=0; $i < $n; ++$i) {
+
+            // Some gantt objects may not have constraints associated with them
+            // for example we can add IconPlots which doesn't have this property.
+            if( empty($this->iObj[$i]->constraints) ) continue;
+
+            $numConstrains = count($this->iObj[$i]->constraints);
+
+            for( $k = 0; $k < $numConstrains; $k++ ) {
+                $vpos = $this->iObj[$i]->constraints[$k]->iConstrainRow;
+                if( $vpos >= 0 ) {
+                    $c1 = $this->iObj[$i]->iConstrainPos;
+
+                    // Find out which object is on the target row
+                    $targetobj = -1;
+                    for( $j=0; $j < $n && $targetobj == -1; ++$j ) {
+                        if( $this->iObj[$j]->iVPos == $vpos ) {
+                            $targetobj = $j;
+                        }
+                    }
+                    if( $targetobj == -1 ) {
+                        JpGraphError::RaiseL(6008,$this->iObj[$i]->iVPos,$vpos);
+                        //('You have specifed a constrain from row='.$this->iObj[$i]->iVPos.' to row='.$vpos.' which does not have any activity.');
+                    }
+                    $c2 = $this->iObj[$targetobj]->iConstrainPos;
+                    if( count($c1) == 4 && count($c2 ) == 4) {
+                        switch( $this->iObj[$i]->constraints[$k]->iConstrainType ) {
+                            case CONSTRAIN_ENDSTART:
+                                if( $c1[1] < $c2[1] ) {
+                                    $link = new GanttLink($c1[2],$c1[3],$c2[0],$c2[1]);
+                                }
+                                else {
+                                    $link = new GanttLink($c1[2],$c1[1],$c2[0],$c2[3]);
+                                }
+                                $link->SetPath(3);
+                                break;
+                            case CONSTRAIN_STARTEND:
+                                if( $c1[1] < $c2[1] ) {
+                                    $link = new GanttLink($c1[0],$c1[3],$c2[2],$c2[1]);
+                                }
+                                else {
+                                    $link = new GanttLink($c1[0],$c1[1],$c2[2],$c2[3]);
+                                }
+                                $link->SetPath(0);
+                                break;
+                            case CONSTRAIN_ENDEND:
+                                if( $c1[1] < $c2[1] ) {
+                                    $link = new GanttLink($c1[2],$c1[3],$c2[2],$c2[1]);
+                                }
+                                else {
+                                    $link = new GanttLink($c1[2],$c1[1],$c2[2],$c2[3]);
+                                }
+                                $link->SetPath(1);
+                                break;
+                            case CONSTRAIN_STARTSTART:
+                                if( $c1[1] < $c2[1] ) {
+                                    $link = new GanttLink($c1[0],$c1[3],$c2[0],$c2[1]);
+                                }
+                                else {
+                                    $link = new GanttLink($c1[0],$c1[1],$c2[0],$c2[3]);
+                                }
+                                $link->SetPath(3);
+                                break;
+                            default:
+                                JpGraphError::RaiseL(6009,$this->iObj[$i]->iVPos,$vpos);
+                                //('Unknown constrain type specified from row='.$this->iObj[$i]->iVPos.' to row='.$vpos);
+                                break;
+                        }
+
+                        $link->SetColor($this->iObj[$i]->constraints[$k]->iConstrainColor);
+                        $link->SetArrow($this->iObj[$i]->constraints[$k]->iConstrainArrowSize,
+                        $this->iObj[$i]->constraints[$k]->iConstrainArrowType);
+
+                        $link->Stroke($this->img);
+                    }
+                }
+            }
+        }
+    }
+
+    function GetCSIMAreas() {
+        if( !$this->iHasStroked )
+        $this->Stroke(_CSIM_SPECIALFILE);
+
+        $csim = $this->title->GetCSIMAreas();
+        $csim .= $this->subtitle->GetCSIMAreas();
+        $csim .= $this->subsubtitle->GetCSIMAreas();
+
+        $n = count($this->iObj);
+        for( $i=$n-1; $i >= 0; --$i )
+        $csim .= $this->iObj[$i]->GetCSIMArea();
+        return $csim;
+    }
+}
+
+//===================================================
+// CLASS PredefIcons
+// Description: Predefined icons for use with Gantt charts
+//===================================================
+define('GICON_WARNINGRED',0);
+define('GICON_TEXT',1);
+define('GICON_ENDCONS',2);
+define('GICON_MAIL',3);
+define('GICON_STARTCONS',4);
+define('GICON_CALC',5);
+define('GICON_MAGNIFIER',6);
+define('GICON_LOCK',7);
+define('GICON_STOP',8);
+define('GICON_WARNINGYELLOW',9);
+define('GICON_FOLDEROPEN',10);
+define('GICON_FOLDER',11);
+define('GICON_TEXTIMPORTANT',12);
+
+class PredefIcons {
+    private $iBuiltinIcon = null, $iLen = -1 ;
+
+    function GetLen() {
+        return $this->iLen ;
+    }
+
+    function GetImg($aIdx) {
+        if( $aIdx < 0 || $aIdx >= $this->iLen ) {
+            JpGraphError::RaiseL(6010,$aIdx);
+            //('Illegal icon index for Gantt builtin icon ['.$aIdx.']');
+        }
+        return Image::CreateFromString(base64_decode($this->iBuiltinIcon[$aIdx][1]));
+    }
+
+    function __construct() {
+        //==========================================================
+        // warning.png
+        //==========================================================
+        $this->iBuiltinIcon[0][0]= 1043 ;
+        $this->iBuiltinIcon[0][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABmJLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsSAAALEgHS3X78AAAA'.
+     'B3RJTUUH0wgKFSgilWPhUQAAA6BJREFUeNrtl91rHFUYh5/3zMx+Z5JNUoOamCZNaqTZ6IWIkqRiQWmi1IDetHfeiCiltgXBP8AL'.
+     '0SIUxf/AvfRSBS9EKILFFqyIH9CEmFZtPqrBJLs7c+b1YneT3WTTbNsUFPLCcAbmzPt73o9zzgzs2Z793231UOdv3w9k9Z2uzOdA'.
+     '5+2+79yNeL7Hl7hw7oeixRMZ6PJM26W18DNAm/Vh7lR8fqh97NmMF11es1iFpMATqdirwMNA/J4DpIzkr5YsAF1PO6gIMYHRdPwl'.
+     'oO2elmB+qH3sm7XozbkgYvy8SzYnZPtcblyM6I+5z3jQ+0vJfgpEu56BfI9vUkbyi2HZd1QJoeWRiAjBd4SDCW8SSAOy6wBHMzF7'.
+     'YdV2A+ROuvRPLfHoiSU0EMY/cDAIhxJeGngKaN1VgHyPL7NBxI1K9P4QxBzw3K1zJ/zkG8B9uwaQ7/HNsRZv9kohBGD0o7JqMYS/'.
+     '/ynPidQw/LrBiPBcS/yFCT95DvB2BWAy4575PaQbQKW+tPd3GCItu2odKI++YxiKu0d26oWmAD7paZU/rLz37VqIijD2YbnzNBBE'.
+     'IBHf8K8qjL7vYhCGErEU8CTg3xXAeMp96GrJEqkyXkm9Bhui1xfsunjdGhcYLq+IzjsGmBt5YH/cmJkFq6gIqlon3u4LxdKGuCIo'.
+     'Qu41g0E41po+2R33Xt5uz9kRIB2UTle7PnfKrROP1HD4sRjZlq0lzhwoZ6rDNeTi3nEg1si/7FT7kYQbXS6E5E65tA5uRF9tutq0'.
+     'K/VwAF+/FbIYWt6+tjQM/AqUms7A4Wy6d7YSfSNxgMmzi0ycWWworio4QJvj4LpuL5BqugTnXzzqJsJwurrlNhJXFaavW67NRw3F'.
+     'q+aJcCQVe9fzvJGmAY7/dPH0gi0f64OveGxa+usCuQMeZ0+kt8BVrX+qPO9Bzx0MgqBvs+a2PfDdYIf+WAjXU1ub4tqNaPPzRs8A'.
+     'blrli+WVn79cXn0cWKl+tGx7HLc7pu3CSmnfitL+l1UihAhwjFkPQev4K/fSABjBM8JCaFuurJU+rgW41SroA8aNMVNAFtgHJCsn'.
+     'XGy/58QVxAC9MccJtZ5kIzNlW440WrJ2ea4YPA9cAooA7i0A/gS+iqLoOpB1HOegqrYB3UBmJrAtQAJwpwPr1Ry92wVlgZsiYlW1'.
+     'uX1gU36dymgqYxJIJJNJT1W9QqHgNwFQBGYqo94OwHZQUuPD7ACglSvc+5n5T9m/wfJJX4U9qzEAAAAASUVORK5CYII=' ;
+
+        //==========================================================
+        // edit.png
+        //==========================================================
+        $this->iBuiltinIcon[1][0]= 959 ;
+        $this->iBuiltinIcon[1][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABYAAAAWCAYAAADEtGw7AAAABGdBTUEAALGPC/xhBQAAAAZiS0dEAFgAWABY9j+ZuwAAAAlwSFlz'.
+     'AAALEAAACxABrSO9dQAAAAd0SU1FB9AKDAwbIEXOA6AAAAM8SURBVHicpdRPaBxlHMbx76ZvsmOTmm1dsEqQSIIsEmGVBAQjivEQ'.
+     'PAUJngpWsAWlBw8egpQepKwplN4ULEG9CjkEyUFKlSJrWTG0IU51pCsdYW2ncUPjdtp9Z+f3vuNhu8nKbmhaf5cZeGc+PO8zf1Lc'.
+     'm0KhkACICCKCMeaBjiLC0tLSnjNvPmuOHRpH0TZTU1M8zBi9wakzn7OFTs5sw8YYACYmJrre7HkeuVyu69qPF77hlT1XmZ0eQ03O'.
+     'wOLJTvhBx1rLz18VmJ0eY+jVd2FxDkKXnvYLHgb97OgLzE4ON9Hzc1B1QaQzsed5O0Lta3Ec89OnR5h5McfQ+Mw2qgQUnfBOPbZ3'.
+     'bK3l+xOvMT0+3ERLp5FNF6UEjcL32+DdVmGt5WLhDYYPZrbRqreFumXwql0S3w9tnDvLWD5PZigPpdOwuYpSCo3C8wU3UHxQdHbf'.
+     'cZIkNM6dxcnlUM4k1eUFMlUPpUADbpkttFarHe6oYqeOr6yt4RzMQHYUcUsQVtGicHDwKprViuLDkkOtVnsHCHZVRVy/zcj1i5Af'.
+     'h8AjdIts+hUcGcYPK3iBtKM3gD/uAzf/AdY2mmmVgy6X8YNNKmGIvyloPcB8SUin07RQ4EZHFdsdG0wkJEnEaHAJxvKEpSLeaokV'.
+     'r4zWmhUZYLlY4b1D03y5eIEWCtS7vsciAgiIxkQRabWOrlQor66y4pUphoJb1jiO4uO5o0S3q6RSqVbiOmC7VCEgAhLSaDQ48dH7'.
+     'vD46REY0iysegSjKQciRt99ib7qXwX0O+pG4teM6YKHLB9JMq4mTmF9/+AKA4wvLZByH7OgYL7+UY2qvw/7Bfg5kHiXjJFyv3CGO'.
+     'Y1rof+BW4t/XLiPG0DCGr79d4XzRxRnIMn98huXSTYyJ6et1UNYQhRvcinpJq86H3wGPPPM0iBDd+QffD1g4eZjLvuG7S1Wef26E'.
+     'J7L7eSx7gAHVg7V3MSbi6m/r93baBd6qQjerAJg/9Ql/XrvG0ON1+vv7GH3qSfY5fahUnSTpwZgIEQesaVXRPbHRG/xyJSAxMYlp'.
+     'EOm71HUINiY7mGb95l/8jZCyQmJjMDGJjUmsdCROtZ0n/P/Z8v4Fs2MTUUf7vYoAAAAASUVORK5CYII=' ;
+
+        //==========================================================
+        // endconstrain.png
+        //==========================================================
+        $this->iBuiltinIcon[2][0]= 666 ;
+        $this->iBuiltinIcon[2][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABYAAAAWCAYAAADEtGw7AAAABGdBTUEAALGPC/xhBQAAAAZiS0dEAP8A/wD/oL2nkwAAAAlwSFlz'.
+     'AAALDwAACw8BkvkDpQAAAAd0SU1FB9ALEREILkh0+eQAAAIXSURBVHictZU9aFNRFMd/N81HX77aptJUWmp1LHRpIcWhg5sIDlUQ'.
+     'LAXB4t7RRUpwEhy7iQ46CCIoSHcl0CFaoVARU2MFMYktadLXJNok7x2HtCExvuYFmnO4w/3gx+Gc/z1HKRTdMEdXqHbB/sgc/sic'.
+     'nDoYAI8XwDa8o1RMLT+2hAsigtTvbIGVqhX46szUifBGswUeCPgAGB7QeLk0X4Ork+HOxo1VgSqGASjMqkn8W4r4vVtEgI/RRQEL'.
+     'vaoGD85cl5V3nySR/S1mxWxab7f35PnntNyMJeRr9kCMqiHTy09EoeToLwggx6ymiMOD/VwcD7Oa/MHkcIiQx026WGYto5P/U+ZZ'.
+     '7gD0QwDuT5z9N3LrVPi0Xs543eQPKkRzaS54eviJIp4tMFQFMllAWN2qcRZHBnixNM8NYD162xq8u7ePSQ+GX2Pjwxc2dB2cLtB8'.
+     '7GgamCb0anBYBeChMtl8855CarclxU1gvViiUK4w2OMkNDnGeJ8bt9fH90yOnOkCwLFTwhzykhvtYzOWoBBbY//R3dbaNTYhf2RO'.
+     'QpeuUMzv188MlwuHy0H13HnE48UzMcL0WAtUHX8OxZHoG1URiFw7rnLLCswuSPD1ulze/iWjT2PSf+dBXRFtVVGIvzqph0pQL7VE'.
+     'avXYaXXxPwsnt0imdttCocMmZBdK7YU9D8wuNOW0nXc6QWzPsSa5naZ1beb9BbGB6dxGtMnXAAAAAElFTkSuQmCC' ;
+
+        //==========================================================
+        // mail.png
+        //==========================================================
+        $this->iBuiltinIcon[3][0]= 1122 ;
+        $this->iBuiltinIcon[3][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABYAAAAWCAYAAADEtGw7AAAABGdBTUEAALGPC/xhBQAAAAZiS0dEAP8A/wD/oL2nkwAAAAlwSFlz'.
+     'AAALEAAACxABrSO9dQAAAAd0SU1FB9AJHAMfFvL9OU8AAAPfSURBVHictZRdaBRXFMd/987H7tbNx8aYtGCrEexDsOBDaKHFxirb'.
+     'h0qhsiY0ykppKq1osI99C4H2WSiFFMHWUhXBrjRi0uCmtSEUGgP1QWqhWjGkoW7M1kTX3WRn5p4+TJJNGolQ6IXDnDtz+N0z/3PP'.
+     'UWBIpdpYa23b9g09PZ2kUrOrvmUyGVKp1Ao/mUyi56YnVgWfO/P1CihAd/dJMpmaNROIRq8BkM1m0bH6TasC3j6QXgFdXI+DR6PR'.
+     'JX/Pno8B+KLnMKqlpUU8z8MYs2RBEDzWf9J+0RcRbMdxGBsbw/fmCXwPMUEYID4iAVp8wIRmDIHMo4yHSIBSASKC+CWE0C/PF9jU'.
+     '3B6Cp+4M07C5FUtKGNvGwQJctPgIsgD2wRhEIqAMGB+UQYkHJgYYZD7P1HwVlmWhHcfhyk83KeRGUW4t6CgoG5SNUS4KBWgQDUov'.
+     '7AGlwYASBVqH0Bk49dXpCviVV3dw/tI1Bvr7kMIIlh0NYUpjlF0BAYvcxSXmEVLKceHSCJm+PnbueBHbtkNwTXUNBzo6aGpq4sSZ'.
+     'GwT5H7BsF6Wdf1GWHQAoM0upeI9PT1yioS7B7tdaSdSuw7KsUGMAy7HYsmUztTW1nMwM0txssX1rlHjjS5jy/Uq2YkK/eJuLl6/z'.
+     'x+1xkslW6mrixGIODx8EFSlEBC0+tmXT0NhA2763iEUjnLv4C8XpUbSbAB1mKkGJ3J83Od77HW5EszvZSqK2iljMIeJaRGNuJePF'.
+     '6mspY7BJ1DXwQnCd2fxGRq5OUCz8xt72dyhMZcn++Cu3xu9SKhdp2b4ZHWnAtTSxmIWlhcIjlksR3lNBYzlxZsb7+f7ne+xtSzOd'.
+     'u83szH1OnThOPp/n+a0beeP1l4mvq+PU2Qyd+5PY1RuwlAqLYFaBfbTbyPSdfgaH77A//QF4f1O/vpr6RJyq+C5Kc/M8FbFxXItY'.
+     'xOHDrvfo/fxLDnbsJBp5BowBReVWYAzabeTh5ABDw7cWoNNL3YYYNtSv57lnn6Z+Qx01VeuIuBa2DV1HD3H63BAPZu4u1WGpeLHq'.
+     'Rh7+NcjA0O+0p4+CNwXigwnbWlQQdpuEpli+n+PIkcOc//YKuckJJFh2K2anrjFw+QZt6S6kPImIF/b+cqAJD1LihWAxC61twBTo'.
+     'fPcQF/oGsVW5ovHQlavs2/8+uYnRVSOUgHAmmAClBIOBwKC0gPjhIRgEIX2wg7NnwpZW3d3d4vs+vu8TBMGK51rvPM9b8hdteZxd'.
+     'LBbVR8feJDs0Rlv6GFKeXJ21rNRXESxMPR+CBUl0nN7PjtO+dye7Up/8v1I88bf/ixT/AO1/hZsqW+C6AAAAAElFTkSuQmCC' ;
+
+        //==========================================================
+        // startconstrain.png
+        //==========================================================
+        $this->iBuiltinIcon[4][0]= 725 ;
+        $this->iBuiltinIcon[4][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABYAAAAWCAYAAADEtGw7AAAABGdBTUEAALGPC/xhBQAAAAZiS0dEAP8A/wD/oL2nkwAAAAlwSFlz'.
+     'AAALDgAACw4BQL7hQQAAAAd0SU1FB9ALEREICJp5fBkAAAJSSURBVHic3dS9a1NRGMfx77kxtS+xqS9FG6p1ER3qVJpBQUUc3CRU'.
+     'BwURVLB1EAuKIP0THJQiiNRJBK3iJl18AyeltRZa0bbaJMbUNmlNSm5e7s25j0NqpSSmyag/OMM9POdzDuflwn8djz8gClVRrVEV'.
+     'ur4Bl1FTNSzLrSS6vbml0jUUwSXj8Qfk3PkLtLW2AeBIybmrgz3+gFzpucjlE4f4btuFTuWuCF5XDr3a3UPf6cM8GQvxzbsRAJdh'.
+     'ScfxSywml5j7mVypN0eGEJ0tebIre+zxB6Tv7jPReS2hREpOvpmUXU+H5eC913JnNCSRVE60pUVbWoZjprR39Yq70bdqj4pW7PEH'.
+     '5FpvL9e79jOTTHM7ssDL6CJZ08LbvAGnrpZg2mI2Z/MlZfN8IkxuSwu4V9+WIrj7zFlOHfXzKrLIi2SGh5ECKjnNVNxkQEc55vOw'.
+     'rb6O8JLFdHyJ+ayFElUeHvjwkfteL/V7fKTSkFvIQE4DoLI2Mz/muTkTApcBKIwaN8pwIUrKw+ajWwDknAO0d/r4zFaMuRS63sWm'.
+     'RoOdm+vRIriUYjKexrQV+t1o0YEVwfZSVJmD/dIABJuO0LG3lRFx0GOfiAELE9OgCrfU0XnIp5FwGLEy5WEAOxlR5uN+ARhP7GN3'.
+     '5w7Gv4bQI2+xpt4jjv2nWBmIlcExE2vDAHYioszBZXw6CPE4ADoWVHmd/tuwlZR9eXYyoszBfpiNQqaAOU5+TXRN+DeeenADPT9b'.
+     'EVgKVsutKPl0TGWGhwofoquaoKK4apsq/tH/e/kFwBMXLgAEKK4AAAAASUVORK5CYII=' ;
+
+        //==========================================================
+        // calc.png
+        //==========================================================
+        $this->iBuiltinIcon[5][0]= 589 ;
+        $this->iBuiltinIcon[5][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABYAAAAWCAYAAADEtGw7AAAABGdBTUEAALGPC/xhBQAAAAZiS0dEAA4AIwBbgMF12wAAAAlwSFlz'.
+     'AAALEQAACxEBf2RfkQAAAAd0SU1FB9AHBxQeFsqn0wQAAAHKSURBVHicnZWff+RAGIef3U/gcOEgUAgUCgcLhYXCwsHBQeGgUDgs'.
+     'FgMHB4VA/4Bg4XChWFgIFIqBwkJhsRAYeOGF+TQHmWSTTbKd9pU37/x45jvfTDITXEynAbdWKVQB0NazcVm0alcL4rJaRVzm+w/e'.
+     '3iwAkzbYRcnnYgI04GCvsxxSPabYaEdt2Ra6D0atcvvvDmyrMWBX1zPq2ircP/Tk98DiJtjV/fim6ziOCL6dDHZNhxQ3arIMsox4'.
+     'vejleL2Ay9+jaw6A+4OSICG2cacGKhsGxg+CxeqAQS0Y7BYJvowq7iGMOhXHEfzpvpQkA9bLKgOgWKt+4Lo1mM9hs9m17QNsJ70P'.
+     'Fjc/O52joogoX8MZKiBiAFxd9Z1vcj9wfSpUlDRNMcYQxzFpmnJ0FPH8nDe1MQaWSz9woQpWSZKEojDkeaWoKAyr1tlu+s48wfVx'.
+     'u7n5i7jthmGIiEGcT+36PP+gFeJrxWLhb0UA/lb4ggGs1T0rZs0zwM/ZjNfilcIY5tutPxgOW3F6dUX464LrKILLiw+A7WErrl+2'.
+     'rABG1EL/BilZP8DjU2uR4U+2E49P1Z8QJmNXUzl24A9GBT0IruCfi86d9x+D12RGzt+pNAAAAABJRU5ErkJggg==' ;
+
+        //==========================================================
+        // mag.png
+        //==========================================================
+        $this->iBuiltinIcon[6][0]= 1415 ;
+        $this->iBuiltinIcon[6][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABYAAAAWCAYAAADEtGw7AAAABGdBTUEAALGPC/xhBQAAAAZiS0dEAP8A/wD/oL2nkwAAAAlwSFlz'.
+     'AAALDAAACwwBP0AiyAAAAAd0SU1FB9ALDxEWDY6Ul+UAAAUESURBVHicdZVrbFRFGIafsyyF0nalV1R6WiggaAptlzsr1OgEogmC'.
+     '0IgoBAsBgkIrBAPEhBj/AP6xRTCUFEwRI4jcgsitXMrFCJptJWvBNpXYbbXtbtttt6e7e86ec/yxadlCfZPJZDIz73zzzjfvR2VL'.
+     'F7U+hf0HD2JduIzTFy6SlJRkPtkcDgdCCE65OxFC8NPV6wghyM7OptankJ2dzbSC5QghEEIgCSHog9PpNAF27dlN6miZuPgElB4/'.
+     'nmY3O7ZtByA1NVUCkGWZweD1eklJScESTbqxuIjrd+/x6uIl5M19hSy7nfGOeUxf+g7VjU1sKi7C4/GYsiyz7tAJAD4/cRaA1tZW'.
+     'AHIPnECUVGD1+/3U19ebG4uLeHf1akamjsIwoVnVCOvQEdLoVILYYmMo3PIxSBJflpSaDX5FAmju1QAYv/8k/s8+wLVxOU0jR2LZ'.
+     '8sMFAApWrCApbRRDrRZirBYSLBKaoRPQw3SFernf2sav7T0Ubt4KwL4FMwF4Vu8FoHBCKgCzDhwHwLIhZ7y5a89u4m2JhA0wTdDC'.
+     'OrphEjJMNElCHxKDEjaobmvlfo/Krj27CQQCJsCGJW8C0KXqAMxMiosQA8hZWcTFx9OsaniDKh1qmG7VoFsL0x0K06kbeAMhWpRe'.
+     '/KpG+gwHAKUnz7Dz3BUMw6DK18nuw99wt0Nh6VdHI8RJicmETQgFg7SFwjSrGv+oKp6ghldV6dZ0ugJBlF6FmCESQ2w2AIqXLsan'.
+     'BrFYLJTnTCBrdBqveeopWZiPFaBHUegJhegMqGgxEkHDwB/UaQ9rdIV06v0+TD2EEQjQFtAY0dsNgNvt5sialQAIIXh7wQKuVf6J'.
+     'gTsSccPDWlQstClBGjr9eHpVWvUQncEwdYEedF8noQ4vmYmpZMTH0nTvDn25vLbrNmu7bvfnsYEbAMnhcPDgwQPzUo2LJusw/mhp'.
+     'QwlHNO0KBAnoIfxtrcQMT2De1Mm891wyUzNlUlJSpIyMDBobGzlzr5rFM/Koq6vrP8ASGxsLwPmKcvIShjPGZiPOakE3VFB8hHwd'.
+     'vJAxhrk5L7Ly+RQuH/sWgPdXrwFg/6HDFBUsIj09nehfbAWwPWOT9n5RYhqGwarNWxkRM5TRCfF4U1PQsDDJFk9uYhwXvzvKjm3b'.
+     'KSsro3DJInNW5RXp7u2bAKSlpeH1esnPz6eqqgqLpmmcr3Fht9ulfaV7mZk1Bs+lM6T1djM9fhg5egDPpTNMy5TZsW07kydPYdWM'.
+     'aXx96ixOp9O8cfUa80srmDpjOgAulytiQqZpMnvObLbt/JTtHxXj9/tRVdU0DGOAufRpevPDTeac0hJyc3NxOOawfv161lVWS6eX'.
+     'z+9/UOCxu1VWVvaTRGv16NFfjB2bNeAQp9NpTpmSM4DcbrdL0WsGDKLRR+52uwe1yP8jb2lpYfikyY9t80n03UCWZeaXVjw1f+zs'.
+     'Oen+/d+pqanhzp2fKSsrw+l0mi6XiyPl5ZGITdN8fAVJwjRNJEmi1qfw1kw7siyTnJxMe3s71dXV3GpoZO64DG41NPJylvxU5D/e'.
+     'qJKsfWQD9IkaZ2RmUvr9aV4aGYcQgjfO3aWoYBF5eXm4ewIsu/CbdPz1aWb0/p1bNoOrQxlUiuiaFo3c3FyEEOx9+C9CCD6paaTW'.
+     'p/TXyYkTJ0Xe59jf7QOyAKDWp/QXxcFQ61P4pT3ShBBcvnUHIQTjxmX19/8BCeVg+/GPpskAAAAASUVORK5CYII=' ;
+
+        //==========================================================
+        // lock.png
+        //==========================================================
+        $this->iBuiltinIcon[7][0]= 963 ;
+        $this->iBuiltinIcon[7][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABYAAAAWCAYAAADEtGw7AAAABGdBTUEAALGPC/xhBQAAAAZiS0dEAAAAAAAA+UO7fwAAAAlwSFlz'.
+     'AAALCwAACwsBbQSEtwAAAAd0SU1FB9AKAw0XDmwMOwIAAANASURBVHic7ZXfS1t3GMY/3+PprI7aisvo2YU6h6ATA8JW4rrlsF4U'.
+     'qiAsF9mhl0N2cYTRy9G/wptAYWPD9iJtRy5asDe7cYFmyjaXOLaMImOrmkRrjL9yTmIS3120JybWQgfb3R74wuc8Lzw858vLOUpE'.
+     'OK6pqSm2trbY39+nu7tbPHYch7m5OcLhMIA67kWj0aMQEWk6tm17rNm2LSIie3t7ksvlJJ1OSyqVkls3Z8SyLMnlcqTTaVKpFLdu'.
+     'zmBZVj1HeY2VUti2TSQSQSml2bZdi0QirK2tMT09zerqKtlslqGhISYnJ4nHv2N+foFsNquOe9FotLlxOBwmk8lgWRbhcFgymYxY'.
+     'liUi0mqaJoAuIi2macrdO7fFsizx3to0Te7euV1vrXtXEgqFmJmZYWVlhXK5LB4/U9kwDL784kYV0A3DYHd3m4sXRymXywKoRi8U'.
+     'Ch01DgQCJBIJLMsiEAhIIpHw2uLz+eqtYrEYIqKZpimxWEyCwaCMjY01zYPBIJpXqVQqsby8TLVabWKA/v5+RkZGMAyDrq4ulFKH'.
+     'HsfjcWZnZ+ns7KTRqwcnk0mKxSKFQqGJlVKtruuSTCYB6O3trW9UI/v9/iZPB/j8s2HOnX0FgHfeXpeffnzK+fWf+fijvhLs0PtG'.
+     'D/n1OJ9+MsrlSwb3733DwMCAt1EyPj6uACYmJp56168NU6nUqFSE9nZdPE7+WqC/r4NKTagcCJVqDaUUB5VDAA4Pa9x7sMLlSwan'.
+     'WjRmv13D7/erpaWlo604qOp88OF7LC48rPNosMq5Th+Dgxd4/XyA1rbzADi7j8jnf2P++wdcvSr8MJ/i8eomAKlUqn41OsDAQDeD'.
+     'g++yuPCwzm/2vU8+n2a7sMFfj79mp7BBuVzioFSiXHJx3SKuW2Rzy0Up9dxnQVvODALQerqNRn4ZKe0Mvtc6TpzpmqbxalcY9Ato'.
+     '2v06t515C73YQftZB9GLnDrt4LoujuPgOA4Ui+C6yOpXJwZrJ7r/gv4P/u+D9W7fLxTz+1ScQxrZ3atRLaVxdjbY2d184R6/sLHe'.
+     'opHP7/Do90Ua+WWUyezzZHObP/7cfX54/dowE1d66s8TV3oE+Mfn+L/zb4XmHPjRG9YjAAAAAElFTkSuQmCC' ;
+
+        //==========================================================
+        // stop.png
+        //==========================================================
+        $this->iBuiltinIcon[8][0]= 889 ;
+        $this->iBuiltinIcon[8][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAABYAAAAWCAYAAADEtGw7AAAABGdBTUEAALGPC/xhBQAAAAZiS0dEAAAAAAAA+UO7fwAAAAlwSFlz'.
+     'AAALDwAACw8BkvkDpQAAAAd0SU1FB9AJDwEvNyD6M/0AAAL2SURBVHic1ZTLaxVnGIefb2bO5OScHJN4oWrFNqcUJYoUEgU3/Qf6'.
+     'F7gwCkIrvdBLUtqqiLhSg9bgBduFSHZdiG5ctkJ3xRDbUFwUmghNzBDanPGMkzOX79LFJGPMOSd204U/+Bbzvd/78F4H/ieJdoad'.
+     'pZKxRFszAI/DcP0HazXY22v+HB01kee1PA/v3zfnjx4xgGnHcNZe7OvuNj+cOEF1ZATv5nUA4jhBSgmADCVWo8Ge2Of9wb18P/G7'.
+     'oUXmYi30zqlTVEdGWLh1g2D6MYlKkXGE0Vl8aa2GEB149+4xXSzyoOIw/mimiZV/DPb25pFOj13A9gOMEChhUEqhVYqWKUk9QAUp'.
+     'sT/P4s8PmKlUmNhQaIJbkDVqBbpw6wZ2zUc4Nm+ePku5p4eOrgpueQOFUoVCVxcD4+N07dpF9+5tVJeWGPBjhvr7WF1zC8ASgtcP'.
+     'H8a7eZ1odh4sh50nzwCw9ZNh3M4Stutiu0X2nB/LyjZ6lcIbVTpdQU/jWVPzLADM8+ZGBRdtC7wrF/O7bR99iu26VL86iU4SAH4b'.
+     'Po5d6AQhstMSvGyI4wS5FJBKSRwnzF8byx/u+PjzzMF1mfryQ1K/jnCahqp1xEopjFLoNEFJSRJHzF799gWHqa+/QKcSUXBI609f'.
+     'Al5W4teQSiHDOipNUKnMI13RvnOXAIEKQixvGWya98SC560MFwPiqEG86JM8q79Q06lvhnOndy5/B6GPCUOMUu3BQgg8z0M3GmBZ'.
+     'iGJn3v2VmsqnfzNx7FDueODuj8ROCFpjtG5TCmOYv32bJ09msP0ISydMfnAUgF8/O45RAA6WTPjlvXcB+Gn7FuRf/zAnNX6x3ARe'.
+     'PSdmqL+P/YHkwMGDOGWDZTlQcNBRhPEComgB/YeHfq2InF1kLlXUOkpMbio1bd7aATRD/X0M1lPeSlM2vt2X1XBZjZnpLG2tmZO6'.
+     'LbQVOIcP+HG2UauH3xgwBqOz9Cc3l1tC24Fz+MvUDroeGNb5if9H/1dM/wLPCYMw9fryKgAAAABJRU5ErkJggg==' ;
+
+        //==========================================================
+        // error.png
+        //==========================================================
+        $this->iBuiltinIcon[9][0]= 541 ;
+        $this->iBuiltinIcon[9][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAACgAAAAoCAMAAAC7IEhfAAAAaVBMVEX//////2Xy8mLl5V/Z2VvMzFi/v1WyslKlpU+ZmUyMjEh/'.
+     'f0VyckJlZT9YWDxMTDjAwMDy8sLl5bnY2K/MzKW/v5yyspKlpYiYmH+MjHY/PzV/f2xycmJlZVlZWU9MTEXY2Ms/PzwyMjLFTjea'.
+     'AAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfTCAkUMSj9wWSOAAABLUlEQVR4'.
+     '2s2U3ZKCMAxGjfzJanFAXFkUle/9H9JUKA1gKTN7Yy6YMjl+kNPK5rlZVSuxf1ZRnlZxFYAm93NnIKvR+MEHUgqBXx93wZGIUrSe'.
+     'h+ctEgbpiMo3iQ4kioHCGxir/ZYUbr7AgPXs9bX0BCYM8vN/cPe8oQYzom3tVsSBMVHEoOJ5dm5F1RsIe9CtqGgRacCAkUvRtevT'.
+     'e2pd6vOWF+gCuc/brcuhyARakBU9FgK5bUBWdHEH8tHpDsZnRTZQGzdLVvQ3CzyYZiTAmSIODEwzFCAdJopuvbpeZDisJ4pKEcjD'.
+     'ijWPJhU1MjCo9dkYfiUVjQNTDKY6CVbR6A0niUSZjRwFanR0l9i/TyvGnFdqwStq5axMfDbyBksld/FUumvxS/Bd9VyJvQDWiiMx'.
+     'iOsCHgAAAABJRU5ErkJggg==' ;
+
+        //==========================================================
+        // openfolder.png
+        //==========================================================
+        $this->iBuiltinIcon[10][0]= 2040 ;
+        $this->iBuiltinIcon[10][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAAZiS0dEANAAtwClFht71AAAAAlwSFlz'.
+     'AAALEAAACxABrSO9dQAAAAd0SU1FB9AKDQ4RIXMeaLcAAAd1SURBVHicxZd7jBXVHcc/58zcvTNzH8vusqw8FsTsKiCUUh5WBZXG'.
+     'GkOptmqwNWsWLKXFGlEpzZI0AWNKSy0WhDS22gJKtWlTsSRqzYIuLGB2WVvDIwQMZQMsy2OFfdzde+/OnHP6x907vJaFpjb9JZM5'.
+     'c85Mfp/f9/s7Jxn4P4e41gtSyp78WGvtfdEAcqDFYUOH9HS0NhGk9tPb/ilSyp789UUB2AMuqhQy3Uzm7HGkE6W3dTNZMRI3EcWO'.
+     'jf9ClLmWBT3dzW8jUsevWHCG3UpWl+IkHSxnbDh/Mcz12NevBcuWXTmf6TjnXvJ88gDmVB3pw3+nt3UzHa1NqMzBS2zqPLGFjtMN'.
+     'ZNr3XdW+qyqwZcFk76HX/tHWfuQvyO4W7qhaHwL8efkMRlRUpPv7rqD0RrJ+FgAjLy1a20OIxZJEEuNCRfIApj+om4bGM3u2/sYU'.
+     '9J41d8973f3Dhg1pISTV1dXXBRNJxPGFCzhou+DCQrScZOkktNaeDZjamgeZ9MgiYmVDccvHhjAzJw0NTh8/alyZMaVJicp0iTHj'.
+     'JpgNv38tjWUhhGROdbUL9W5/MH5XCkjlcibi+KIop5LVHLKEu8A/f4r286doa9pGrGwYAAsfqbbH3b8MgO/Nqgy6WvdbbXHMkEFJ'.
+     '4xUOMVEvaTZu3BgmvF4Yk4hz9rO/Ulr5cE9owae/rcGxohSOuiWkC2IjcIqKyPZm+OmCH7GhoZEF077EEzVVweAbJ+riEeO0Ey8y'.
+     'UubqOHn0AOgMwvf59txnBrSp9dgxKmf/+kIP1NY8SFk0jh5ajmNHAWg5b2E5EexojGHjbiVRMoRMNs0LC+Yz46vTuH3enN7BI8fr'.
+     'qFdo0BoVZNC9aVSQ4fNjBzEmQJiARxb+/AqYPMAVB5FsPU5v37g9OxgLhe14ZM5/ju052E6MNZvf5pmHHuLmmWOkEysxUtpGAtme'.
+     'dtHTflJkezqQto3jFRnLssyf1jydxiiM7zNnye/c3ZsqLu2BN5fcMfzrv/hby1tPzmRUoihcTJ87CwQI2yLtDcIqsIjYUf51qBlf'.
+     'OnScOSrdQUOMURkiXsLUzJnvbGhoBGDHH5cGyZLhOpYoNl5hqYnYEXOu5fDl9eYAHntx98n8hFHZcPHUuTSxSASAeK/CGIOxJJ0f'.
+     'bOGNPU280dgkq6Y2yu8vfjCIlwwzr+/ZQ/PHO0gOLuO5qsftDQ2NbN+4OCgqG6WTxWVaq6zpF+DiSHWnicdylp3r6aZTWthIOrNp'.
+     'ktHcvBu0sHX1Sm6ozB3B42d90zZA9bQp7PvgPSzXZfnqX/HS4DKKK2+x69Y/HURs26iBAN5ccsfw7774UcumF37C6f07KSt2OHji'.
+     'DEUJD0tISjyPrrSPlAKvN0JP/U4O1NfjuhG2rvklN1SOpfXwftpbTqAyKRrff5fb7rs9V1R7m4wlz2ihA3HpmXflUWyOH2umpLiY'.
+     'ui3v8M+6bWzfsRNbSgqkxaCkiy0simMuEWEhpcRzIhQWOIAh6tiAwS4owInFiTou5dOnMnl2NR++ujBwXEc9terD6M43nrj6LgAB'.
+     'QnDPA9/irtkP8JRS7Hr/3T6YekDQ1pEiEXOwpUVJzCVlZZFS4mZtkpEo9ChAkDp/jtLMBACy6S4RiQghLyv5cgBRPnKUOX6smUGF'.
+     'hSil0MYw9d77mPy1e5mnFE3batm3czvb6nYgEJztSFGU9LCRlMRdUjIH0+lnEMIwPNXD3NumoVJnrMCJaiciMUZfvQnz4QcBSvV1'.
+     'vjE5GK358t0zmXDnDB79saLpo20c+aSRD+t25JTp7GZQwsEWFiVxl6hlUf/WO9z32CxmL1rOe6u/I2KuwGhzLQCB7/sYY9Bah3el'.
+     'FKbvrrVm4vS7GH/7ncx+chEHGz7myCeNbPtoO0JI2jq78WIRLGkzsqs7V5SfFV5EovXACoiqqsfNpk2vo5VCWtYFBfoU0VoTBAFa'.
+     'a7TRaK2p+MoURk+cxMzq+Rzbv49DDbuo27UTW9h0dedssPxuK+kIfN8XxhgDYPVXf2Fh4XKtFIl4AiklAlBKAYRKKK36wHIweTCt'.
+     'NfHiEkaOn8j0+7/BmDFjaT30GbHywSxcuZkpFfFg+m1jjZ/NmnVvNfRvwd69e8WBA/uNFAIh4JVXXmHsmDHE4vEQQgjQ2lxQIm9N'.
+     'nz35q3BEOZOHzaG2thaA4mRU+L29It+IV21CpbRQfeMFC35gRB/M2rVrubnyZmLxWJhECBEmz/eHyo/7lMlH3LFFujsthNFCCGOu'.
+     '+WNyeUgpjSVzMKtWraKyshLPdcPEeYWCIEBdpIxSivr6eta8vI7d6+cGnhdV06pe1QP+F/QXWmuRL+jZZ58LlVmxYgUVFRV4rhtu'.
+     '4TzMxXAA6XRaRAtsYUkx8I/JtSJQOlSwpmZpCLN8+fPcdNNoHMfB9/0QJgRoP295TlR7UVv8xxZcHMuWIZ9/Hn35vG3JEGZpzVJG'.
+     'jx5N1IlitKahsZE1L69j69qHgx+urFX/lQL9JYdLlfnZihUhzOLFi8N3Ml1dthOxVH/f/8/CtqSJ2JaJ2JZ59J7RPsC/AViJsQS/'.
+     'dBntAAAAAElFTkSuQmCC' ;
+
+        //==========================================================
+        // folder.png
+        //==========================================================
+        $this->iBuiltinIcon[11][0]= 1824 ;
+        $this->iBuiltinIcon[11][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAACIAAAAiCAYAAAA6RwvCAAAABGdBTUEAALGPC/xhBQAAAAZiS0dEAAAAAAAA+UO7fwAAAAlwSFlz'.
+     'AAALEAAACxABrSO9dQAAAAd0SU1FB9ECAQgFFyd9cRUAAAadSURBVHiczdhvbBP3Hcfx9/2xfefEOA5JoCNNnIT8AdtZmYBETJsI'.
+     '6+jQOlQihT1AYgytqzZpD1atfyYqlT1h0lRpT7aRJ4NQpRvZGELVuo5Ua9jEJDIETQsNQyPBsUJMWGPnj//e+e72wNg4xElMR6ed'.
+     'ZNln3933dZ/f93f6yfB/sgmrHdDV1WXlPg8NDZUDScD8LFFFEZZlWYZhWMFg0Orq6sq/gDJAfFy1iiZy9OjrVnj4JzQ1rMWqfxm/'.
+     '309jYyNtbW0kEgnu3bvH4cOH88c/jqSKQl4/XGkd+eVtAN46up1LH92ktqYS++ZX8Pv9NDQ0sGnTJlKpFOFwmO7u7vy5IyMjeVRd'.
+     'XV1+WEOh0IrY4pDnq6wXX/sTiCJaMkFZdRNqxefoe7VtCSqXVDqdZnZ2ltraWkzTpKqqijt3JpFlG7dvj7NzZ1f++qFQyA3EClHL'.
+     'Ql743nFkhxPDtJAd5eTaYSVUfX09lZWVlJWVIUnSg7sVQMBCUcu4ceMGe/bsIRQK1QAzOcyykIM9P0KyudAyCWyqG8nhwqa4SkLt'.
+     '3r0bVVVxu924XC40TUOWZUQxe97CwgIdHR2LMHIxSCaVInVvFElxE0vMY1Pd2NUKJMWNTXHlUfF//4vETJCelwbpFm3MjP2dt37x'.
+     'AlN+PzU1NViWRSwW4+7du3g8HjweD4qi5EFAJzAExIpCANbooxhplfB0FJvTg6xWIqsVRVF6MopkU3FXPcnkJxGU0VEAdF2noqKC'.
+     'W3/8DpnqLjzep2lubsblcjE8PExHR8fboVDID9xYFpLBDpJF0jDQIncQpWlkm31FlFLtp9PfyuW/vYQj1kPSuRW/38+lj27S2Q7v'.
+     '/aWXUBVUffVNtm3blivVCEwsC5Eyc5iiApEpDEAXMqQdldhSiWVQHjJagud+8Fuexck/zv+K82dfoSbSCsDe75/km+4GVPd6+l5t'.
+     '4zJHcqVUYN2yEEtZQDCSJCueRAYsPY49HsFIZVG6p25JUumFafT4DKJN4amtT7Nz38sk5+5A70HMtEYyMkFiZhxzjQ/poXrLQrRU'.
+     'DFGEeFpAlkQkm4pRiCpIKodKzk0T/2QMh+piPjxKZPwiSkUtu/b9mNnJEWS7E8nhAmvpM60oJDkXJxqNozxRRUxPIesispBBlsXV'.
+     'UaKEFo8gzoaJhz8s2lOmrpUG+WBhJ9/60g+Z+fDXTAXfxllRjl1VkO0OFATsYhYliiK21ZKKhhHnFveUqSdKgwAEOp7F2v51vvw8'.
+     'XH7/N1wd/BlTweuUV65BdtgfoLTSkipsdD3tRi0VYpommUwGwzDwdT5HYEc3giAwcvH3jLz3BlPB67jWeZBEKYsSBWwpHZtNKo4q'.
+     'aHTDsJeeiGEYWJaFZVmYpommaRiGQdPnv0bb1m8gSRL/vPIOV979aR4lmAJ2p4qCgCxksNuKJ6VNpx4NYhgGpmkuQhmGQTqdxjAM'.
+     'qr2d7HtxEEEQuH1tkKvvvkF44tqDnrIcKJKAPf1g+LAUElq8dIiu60sApmnm93Pfzc7OYhgGrie+wFe++ztcLhcT1wf54PzPCU9c'.
+     'w7XWjWS3IdsdOAUBWZAxrRJnTQ6SG5bce2FCpmkughmGQSqVYm5uDtnj44sH38TtdhP6+Dwf//V4ttHXrkGURZJaic8RgHQ6jWma'.
+     'SJKUL5RLKNfIOczDKF3XSSaTRCIRhLJWntp3nGfWrSMxc5OLf3iNP4+68T9Ub9nF76lTpxgfHycajZJKpdA0LZ9GbjYV7hcDWZaF'.
+     'pmnMz88Ti8UYunSLmu1HFi2aVkxkaGjINTY2ttDb24vX6+XQoUNs3ryZ8vJyIDu1BUFYkkxhgxeiWlpaOHPmDE1NTdTX1xe98eWG'.
+     'JnF/9dQZCoXUYDA4AOD1ejlw4ACtra2Ul5fniwmCkEcUJiUIAoFAgL6+Pnw+H21tbfT39z8SxCS7hHsfWH9/8dL4MKqnp4eWlhac'.
+     'TmcekEvMNE2am5s5ceIEgUCA9vZ2Tp48ic/nY3j4UsmQHCYOjJHtpeBKqL1799Lc3IzT6UTXdRobGxkYGKC9vZ3W1tZ8Ko86NJ8a'.
+     'tXHjRo4dO8bp06fZsmULGzZsoL+/n0AggNfr5ezZs/8VpGTU5OSkc//+/acBfD4f1dXV7Nq1i4aGBs6dO4fP5+Pq1SuPBbIiyjTN'.
+     'RUnV1dUNXLhwAa/Xy44dO4jFYgBEo9FFF1r134BPuYlk16LrAYXsAlmtq6sbKDwoFAp9m+ykuP5ZQVZF3f8tCdwCov8LyHIoAANI'.
+     'AXf/A1TI0XCDh7OWAAAAAElFTkSuQmCC' ;
+
+        //==========================================================
+        // file_important.png
+        //==========================================================
+        $this->iBuiltinIcon[12][0]= 1785 ;
+        $this->iBuiltinIcon[12][1]=
+     'iVBORw0KGgoAAAANSUhEUgAAACIAAAAiCAYAAAA6RwvCAAAABGdBTUEAALGPC/xhBQAAAAZiS0dEAAAAAAAA+UO7fwAAAAlwSFlz'.
+     'AAALDwAACw8BkvkDpQAAAAd0SU1FB9ECDAcjDeD3lKsAAAZ2SURBVHicrZhPaFzHHcc/897s7lutJCsr2VHsOHWMk0MPbsBUrcnF'.
+     'OFRdSo6FNhdB6SGHlpDmYtJCDyoxyKe6EBxKQkt7KKL0T6ABo0NbciqigtC6PhWKI2NFqqxdSd7V2/dmftPDvPd212t55dCBYfbN'.
+     'zpvfZ77z+/1mdhUjytWrV93Hf/24eD5z9gwiMlDjOKbb7dLtdhER2u02u7u73Lp1CxEZBw4AeZwdNQqkMd9wbziFGINJUt6rRbz5'.
+     '1ptUq1XK5TJBEAAUMHt7e+zu7gKwvLzMysoKwAng/uNg9CgQgFKlgg1DUJ67Vqtx6tQpZmdniaIIpRTOOZRSdDoddnZ2aLfbLC8v'.
+     's7S0xJUrV7ZGwQSj1PhhfRodVdDlMrpc5vup5Z2fvMPdu3fZ29vDWjvwztjYGPV6nVqtRqVS4dKlSywtLQFsAdOH2XwsCEApg3jl'.
+     'w98Rak2gvYjNZpNms0mSJDjnHgkDMDc3dySYQ0Ea8w139YUX0OUKulzyg7UmCEO+l1huvHuDra0t9vf3h1TJYSqVypFhHquIrlQI'.
+     'S5qv/uIDAC7/4bcEQYAKvK+0Wq1DVQGIoog7d+4cCeaRII35hrt+8SsEOkRlUaEyR0UpFIrXHxyMVKVUKnHv3r0jwRwaNelBjBjL'.
+     'Sz/7KYuLiwAsLi7y4z/9kY9e+TpkCuSqjI+Po7XuAWeKXLt2DWNMUZMkwRjDhQsXWFtbK6JpCCT3jfQgxomPtPX19YHWicM5x3c2'.
+     '73Pj3Ru8/aO3mZqaolKpoHVvyuvXr/Ppnf/Q7uzz380NPtu4y/qnG+ztd1hfX2dtbQ3gIvDnRyqSxl1UoPjyz98D4PTp0wPtq39Z'.
+     '4fdzLxegrVaLVqvF5OQkYRgWqpRKJZ77wvNsbW1RG5tgfKLOTH2G7Z1twqBQrgrMDvhInjfSOCY5iIv+hYWFgRZArEWsZWF941Bf'.
+     'SdMUgMnJCWpjVU4cn+HUyePM1Gc4+fRUPkzBI5w1jbukcczLv/5l0XfmzJmBFuCba38r/CRXpT+CrDUoZ0jjB4RYonJAOYRobJKT'.
+     'z5zgqfqxAbsFSH6mpHFM2qdGXh4VnoViD6mSJF2cTQeqDqBaKVHWmonJCWpZjhkC6anR5WsffTgwaHV1FaUUq6urA/2v3f5k4LnV'.
+     'arG9tUn3oI2YBCcWHYAxMVYs1qZEZY2SFB2aYZDGfMN9d7uJiWPSeFiNo5Rclc3NTXZbO6RpF7EJVixYA9agwwDnUiqlEPdQ3imi'.
+     'Jo27BGHIt/7x9yEjc3Nzh27Na7c/4TdffKl4bja3ae5MUIu0T/HOEIaOpJt4gwoSsVTK4SBIY77hFtY3ABBjBiZ90rKwvsH77/+K'.
+     't37wOhO1iPpTk4SBw1mLsz6CnKQ4l3qV+kE+t9XHlNZOk+bUJLVIE1VCcIJWQmJ6qjj30NbcXLkZMt8YPig+Z3n1G5fZ39/j/vY2'.
+     '9ckqZT2Ochbn0p4qNkU/dDfUADdXbh4HXgRO4zNdEU0XL1784PLly5w9e7Z4SazFOfGrEotDcOKrcoJPmrYIXf/Zop3QNd1skuGt'.
+     'cUAb2MgAxvHZTgFUq1Wmp6eZnZ0F8JlTjDduDThBnDeECEoJtbGIp6enqEblzCcEZ1PECU4yVRiOGgd0gc+AB0CZvkv1sWPHOHfu'.
+     'HOfPn8da41cpkkltEBEPJhYnBkTQJcdYVKGkgRxCfBsq5xXNgAa2Bn+hjTOgHEKBP8pzRUxykIH4ifLJRTJAl+UMBJzPHQ6bfe/f'.
+     'cWIzPxlUpD+zugzIZtVk1d8znBAqRxgoQuVQgSJQ3h9C5QhDRYgjUILCAzlnEdsHYTKfMTEBcP7F54YUGVmc2GLlIn6ve6v0ahSt'.
+     '8X25TzjJ+rIx1grKpQPWR4LkGVVsMgghvS0qjPdvm5OeceOTWA5Evo2mFzkjQfL7hZPUy5yvvF/uPFQL3+nbDmsLCEmT3sTmCTNr'.
+     'rogT6yFsOix3ftw7OwQhkvSU6CuinhCk0+kAkFoBazEEICHaHHiPVmU0gnUp4EAc1mYrF0EBVpwPi34VrBkwPxKk3W5ju/e5/c+d'.
+     'bGUHIAIuydTIE5zfc5Wr4lJcahHnHTP3CVGm78DrgY38N+DEibp7dmYKdAQmBh1hjEFjis+9CTWYGK21H6PxPyOI0DobYwzZF/z7'.
+     '7jadTvJtYG0kCD7lfwl49ijgT1gc0AH+dZSJA/xB+Mz/GSIvFoj/B7H1mAd8CO/zAAAAAElFTkSuQmCC' ;
+
+        $this->iLen = count($this->iBuiltinIcon);
+    }
+}
+
+//===================================================
+// Global cache for builtin images
+//===================================================
+$_gPredefIcons = new PredefIcons();
+
+//===================================================
+// CLASS IconImage
+// Description: Holds properties for an icon image
+//===================================================
+class IconImage {
+    private $iGDImage=null;
+    private $iWidth,$iHeight;
+    private $ixalign='left',$iyalign='center';
+    private $iScale=1.0;
+
+    function __construct($aIcon,$aScale=1) {
+        GLOBAL $_gPredefIcons ;
+        if( is_string($aIcon) ) {
+            $this->iGDImage = Graph::LoadBkgImage('',$aIcon);
+        }
+        elseif( is_integer($aIcon) ) {
+            // Builtin image
+            $this->iGDImage = $_gPredefIcons->GetImg($aIcon);
+        }
+        else {
+            JpGraphError::RaiseL(6011);
+            //('Argument to IconImage must be string or integer');
+        }
+        $this->iScale = $aScale;
+        $this->iWidth = Image::GetWidth($this->iGDImage);
+        $this->iHeight = Image::GetHeight($this->iGDImage);
+    }
+
+    function GetWidth() {
+        return round($this->iScale*$this->iWidth);
+    }
+
+    function GetHeight() {
+        return round($this->iScale*$this->iHeight);
+    }
+
+    function SetAlign($aX='left',$aY='center') {
+        $this->ixalign = $aX;
+        $this->iyalign = $aY;
+    }
+
+    function Stroke($aImg,$x,$y) {
+
+        if( $this->ixalign == 'right' ) {
+            $x -= $this->iWidth;
+        }
+        elseif( $this->ixalign == 'center' ) {
+            $x -= round($this->iWidth/2*$this->iScale);
+        }
+
+        if( $this->iyalign == 'bottom' ) {
+            $y -= $this->iHeight;
+        }
+        elseif( $this->iyalign == 'center' ) {
+            $y -= round($this->iHeight/2*$this->iScale);
+        }
+
+        $aImg->Copy($this->iGDImage,
+        			$x,$y,0,0,
+        			round($this->iWidth*$this->iScale),round($this->iHeight*$this->iScale),
+        			$this->iWidth,$this->iHeight);
+    }
+}
+
+
+//===================================================
+// CLASS TextProperty
+// Description: Holds properties for a text
+//===================================================
+class TextProperty {
+    public $iShow=true;
+    public $csimtarget='',$csimwintarget='',$csimalt='';
+    private $iFFamily=FF_FONT1,$iFStyle=FS_NORMAL,$iFSize=10;
+    private $iFontArray=array();
+    private $iColor="black";
+    private $iText="";
+    private $iHAlign="left",$iVAlign="bottom";
+
+    //---------------
+    // CONSTRUCTOR
+    function __construct($aTxt='') {
+        $this->iText = $aTxt;
+    }
+
+    //---------------
+    // PUBLIC METHODS
+    function Set($aTxt) {
+        $this->iText = $aTxt;
+    }
+
+    function SetCSIMTarget($aTarget,$aAltText='',$aWinTarget='') {
+        if( is_string($aTarget) )
+        $aTarget = array($aTarget);
+        $this->csimtarget=$aTarget;
+
+        if( is_string($aWinTarget) )
+        $aWinTarget = array($aWinTarget);
+        $this->csimwintarget=$aWinTarget;
+
+        if( is_string($aAltText) )
+        $aAltText = array($aAltText);
+        $this->csimalt=$aAltText;
+
+    }
+
+    function SetCSIMAlt($aAltText) {
+        if( is_string($aAltText) )
+        $aAltText = array($aAltText);
+        $this->csimalt=$aAltText;
+    }
+
+    // Set text color
+    function SetColor($aColor) {
+        $this->iColor = $aColor;
+    }
+
+    function HasTabs() {
+        if( is_string($this->iText) ) {
+            return substr_count($this->iText,"\t") > 0;
+        }
+        elseif( is_array($this->iText) ) {
+            return false;
+        }
+    }
+
+    // Get number of tabs in string
+    function GetNbrTabs() {
+        if( is_string($this->iText) ) {
+            return substr_count($this->iText,"\t") ;
+        }
+        else{
+            return 0;
+        }
+    }
+
+    // Set alignment
+    function Align($aHAlign,$aVAlign="bottom") {
+        $this->iHAlign=$aHAlign;
+        $this->iVAlign=$aVAlign;
+    }
+
+    // Synonym
+    function SetAlign($aHAlign,$aVAlign="bottom") {
+        $this->iHAlign=$aHAlign;
+        $this->iVAlign=$aVAlign;
+    }
+
+    // Specify font
+    function SetFont($aFFamily,$aFStyle=FS_NORMAL,$aFSize=10) {
+        $this->iFFamily = $aFFamily;
+        $this->iFStyle  = $aFStyle;
+        $this->iFSize  = $aFSize;
+    }
+
+    function SetColumnFonts($aFontArray) {
+        if( !is_array($aFontArray) || count($aFontArray[0]) != 3 ) {
+            JpGraphError::RaiseL(6033);
+            // 'Array of fonts must contain arrays with 3 elements, i.e. (Family, Style, Size)'
+        }
+        $this->iFontArray = $aFontArray;
+    }
+
+
+    function IsColumns() {
+        return is_array($this->iText) ;
+    }
+
+    // Get width of text. If text contains several columns separated by
+    // tabs then return both the total width as well as an array with a
+    // width for each column.
+    function GetWidth($aImg,$aUseTabs=false,$aTabExtraMargin=1.1) {
+        $extra_margin=4;
+        $aImg->SetFont($this->iFFamily,$this->iFStyle,$this->iFSize);
+        if( is_string($this->iText) ) {
+            if( strlen($this->iText) == 0 ) return 0;
+            $tmp = preg_split('/\t/',$this->iText);
+            if( count($tmp) <= 1 || !$aUseTabs ) {
+                $w = $aImg->GetTextWidth($this->iText);
+                return $w + 2*$extra_margin;
+            }
+            else {
+                $tot=0;
+                $n = count($tmp);
+                for($i=0; $i < $n; ++$i) {
+                    $res[$i] = $aImg->GetTextWidth($tmp[$i]);
+                    $tot += $res[$i]*$aTabExtraMargin;
+                }
+                return array(round($tot),$res);
+            }
+        }
+        elseif( is_object($this->iText) ) {
+            // A single icon
+            return $this->iText->GetWidth()+2*$extra_margin;
+        }
+        elseif( is_array($this->iText) ) {
+            // Must be an array of texts. In this case we return the sum of the
+            // length + a fixed margin of 4 pixels on each text string
+            $n = count($this->iText);
+            $nf = count($this->iFontArray);
+            for( $i=0, $w=0; $i < $n; ++$i ) {
+                if( $i < $nf ) {
+                    $aImg->SetFont($this->iFontArray[$i][0],$this->iFontArray[$i][1],$this->iFontArray[$i][2]);
+                }
+                else {
+                    $aImg->SetFont($this->iFFamily,$this->iFStyle,$this->iFSize);
+                }
+                $tmp = $this->iText[$i];
+                if( is_string($tmp) ) {
+                    $w += $aImg->GetTextWidth($tmp)+$extra_margin;
+                }
+                else {
+                    if( is_object($tmp) === false ) {
+                        JpGraphError::RaiseL(6012);
+                    }
+                    $w += $tmp->GetWidth()+$extra_margin;
+                }
+            }
+            return $w;
+        }
+        else {
+            JpGraphError::RaiseL(6012);
+        }
+    }
+
+    // for the case where we have multiple columns this function returns the width of each
+    // column individually. If there is no columns just return the width of the single
+    // column as an array of one
+    function GetColWidth($aImg,$aMargin=0) {
+        $aImg->SetFont($this->iFFamily,$this->iFStyle,$this->iFSize);
+        if( is_array($this->iText) ) {
+            $n = count($this->iText);
+            $nf = count($this->iFontArray);
+            for( $i=0, $w=array(); $i < $n; ++$i ) {
+                $tmp = $this->iText[$i];
+                if( is_string($tmp) ) {
+                    if( $i < $nf ) {
+                        $aImg->SetFont($this->iFontArray[$i][0],$this->iFontArray[$i][1],$this->iFontArray[$i][2]);
+                    }
+                    else {
+                        $aImg->SetFont($this->iFFamily,$this->iFStyle,$this->iFSize);
+                    }
+                    $w[$i] = $aImg->GetTextWidth($tmp)+$aMargin;
+                }
+                else {
+                    if( is_object($tmp) === false ) {
+                        JpGraphError::RaiseL(6012);
+                    }
+                    $w[$i] = $tmp->GetWidth()+$aMargin;
+                }
+            }
+            return $w;
+        }
+        else {
+            return array($this->GetWidth($aImg));
+        }
+    }
+
+    // Get total height of text
+    function GetHeight($aImg) {
+        $nf = count($this->iFontArray);
+        $maxheight = -1;
+
+        if( $nf > 0 ) {
+            // We have to find out the largest font and take that one as the
+            // height of the row
+            for($i=0; $i < $nf; ++$i ) {
+                $aImg->SetFont($this->iFontArray[$i][0],$this->iFontArray[$i][1],$this->iFontArray[$i][2]);
+                $height = $aImg->GetFontHeight();
+                $maxheight = max($height,$maxheight);
+            }
+        }
+
+        $aImg->SetFont($this->iFFamily,$this->iFStyle,$this->iFSize);
+        $height = $aImg->GetFontHeight();
+        $maxheight = max($height,$maxheight);
+        return $maxheight;
+    }
+
+    // Unhide/hide the text
+    function Show($aShow=true) {
+        $this->iShow=$aShow;
+    }
+
+    // Stroke text at (x,y) coordinates. If the text contains tabs then the
+    // x parameter should be an array of positions to be used for each successive
+    // tab mark. If no array is supplied then the tabs will be ignored.
+    function Stroke($aImg,$aX,$aY) {
+        if( $this->iShow ) {
+            $aImg->SetColor($this->iColor);
+            $aImg->SetFont($this->iFFamily,$this->iFStyle,$this->iFSize);
+            $aImg->SetTextAlign($this->iHAlign,$this->iVAlign);
+            if( $this->GetNbrTabs() < 1 ) {
+                if( is_string($this->iText) ) {
+                    if( is_array($aX) ) $aX=$aX[0];
+                    if( is_array($aY) ) $aY=$aY[0];
+                    $aImg->StrokeText($aX,$aY,$this->iText);
+                }
+                elseif( is_array($this->iText) && ($n = count($this->iText)) > 0 ) {
+                    $ax = is_array($aX) ;
+                    $ay = is_array($aY) ;
+                    if( $ax && $ay ) {
+                        // Nothing; both are already arrays
+                    }
+                    elseif( $ax ) {
+                        $aY = array_fill(0,$n,$aY);
+                    }
+                    elseif( $ay ) {
+                        $aX = array_fill(0,$n,$aX);
+                    }
+                    else {
+                        $aX = array_fill(0,$n,$aX);
+                        $aY = array_fill(0,$n,$aY);
+                    }
+                    $n = min($n, count($aX) ) ;
+                    $n = min($n, count($aY) ) ;
+                    for($i=0; $i < $n; ++$i ) {
+                        $tmp = $this->iText[$i];
+                        if( is_object($tmp) ) {
+                            $tmp->Stroke($aImg,$aX[$i],$aY[$i]);
+                        }
+                        else {
+                            if( $i < count($this->iFontArray) ) {
+                                $font = $this->iFontArray[$i];
+                                $aImg->SetFont($font[0],$font[1],$font[2]);
+                            }
+                            else {
+                                $aImg->SetFont($this->iFFamily,$this->iFStyle,$this->iFSize);
+                            }
+                        	$aImg->StrokeText($aX[$i],$aY[$i],str_replace("\t"," ",$tmp));
+                        }
+                    }
+                }
+            }
+            else {
+                $tmp = preg_split('/\t/',$this->iText);
+                $n = min(count($tmp),count($aX));
+                for($i=0; $i < $n; ++$i) {
+                    if( $i < count($this->iFontArray) ) {
+                        $font = $this->iFontArray[$i];
+                        $aImg->SetFont($font[0],$font[1],$font[2]);
+                    }
+                    else {
+                        $aImg->SetFont($this->iFFamily,$this->iFStyle,$this->iFSize);
+                    }
+                    $aImg->StrokeText($aX[$i],$aY,$tmp[$i]);
+                }
+            }
+        }
+    }
+}
+
+//===================================================
+// CLASS HeaderProperty
+// Description: Data encapsulating class to hold property
+// for each type of the scale headers
+//===================================================
+class HeaderProperty {
+    public $grid;
+    public $iShowLabels=true,$iShowGrid=true;
+    public $iTitleVertMargin=3,$iFFamily=FF_FONT0,$iFStyle=FS_NORMAL,$iFSize=8;
+    public $iStyle=0;
+    public $iFrameColor="black",$iFrameWeight=1;
+    public $iBackgroundColor="white";
+    public $iWeekendBackgroundColor="lightgray",$iSundayTextColor="red"; // these are only used with day scale
+    public $iTextColor="black";
+    public $iLabelFormStr="%d";
+    public $iIntervall = 1;
+
+    //---------------
+    // CONSTRUCTOR
+    function __construct() {
+        $this->grid = new LineProperty();
+    }
+
+    //---------------
+    // PUBLIC METHODS
+    function Show($aShow=true) {
+        $this->iShowLabels = $aShow;
+    }
+
+    function SetIntervall($aInt) {
+    	$this->iIntervall = $aInt;
+    }
+
+    function SetInterval($aInt) {
+        $this->iIntervall = $aInt;
+    }
+
+    function GetIntervall() {
+        return $this->iIntervall ;
+    }
+
+    function SetFont($aFFamily,$aFStyle=FS_NORMAL,$aFSize=10) {
+        $this->iFFamily = $aFFamily;
+        $this->iFStyle  = $aFStyle;
+        $this->iFSize  = $aFSize;
+    }
+
+    function SetFontColor($aColor) {
+        $this->iTextColor = $aColor;
+    }
+
+    function GetFontHeight($aImg) {
+        $aImg->SetFont($this->iFFamily,$this->iFStyle,$this->iFSize);
+        return $aImg->GetFontHeight();
+    }
+
+    function GetFontWidth($aImg) {
+        $aImg->SetFont($this->iFFamily,$this->iFStyle,$this->iFSize);
+        return $aImg->GetFontWidth();
+    }
+
+    function GetStrWidth($aImg,$aStr) {
+        $aImg->SetFont($this->iFFamily,$this->iFStyle,$this->iFSize);
+        return $aImg->GetTextWidth($aStr);
+    }
+
+    function SetStyle($aStyle) {
+        $this->iStyle = $aStyle;
+    }
+
+    function SetBackgroundColor($aColor) {
+        $this->iBackgroundColor=$aColor;
+    }
+
+    function SetFrameWeight($aWeight) {
+        $this->iFrameWeight=$aWeight;
+    }
+
+    function SetFrameColor($aColor) {
+        $this->iFrameColor=$aColor;
+    }
+
+    // Only used by day scale
+    function SetWeekendColor($aColor) {
+        $this->iWeekendBackgroundColor=$aColor;
+    }
+
+    // Only used by day scale
+    function SetSundayFontColor($aColor) {
+        $this->iSundayTextColor=$aColor;
+    }
+
+    function SetTitleVertMargin($aMargin) {
+        $this->iTitleVertMargin=$aMargin;
+    }
+
+    function SetLabelFormatString($aStr) {
+        $this->iLabelFormStr=$aStr;
+    }
+
+    function SetFormatString($aStr) {
+        $this->SetLabelFormatString($aStr);
+    }
+
+
+}
+
+//===================================================
+// CLASS GanttScale
+// Description: Responsible for calculating and showing
+// the scale in a gantt chart. This includes providing methods for
+// converting dates to position in the chart as well as stroking the
+// date headers (days, week, etc).
+//===================================================
+class GanttScale {
+    public $minute,$hour,$day,$week,$month,$year;
+    public $divider,$dividerh,$tableTitle;
+    public $iStartDate=-1,$iEndDate=-1;
+    // Number of gantt bar position (n.b not necessariliy the same as the number of bars)
+    // we could have on bar in position 1, and one bar in position 5 then there are two
+    // bars but the number of bar positions is 5
+    public $actinfo;
+    public $iTopPlotMargin=10,$iBottomPlotMargin=15;
+    public $iVertLines=-1;
+    public $iVertHeaderSize=-1;
+    // The width of the labels (defaults to the widest of all labels)
+    private $iLabelWidth;
+    // Out image to stroke the scale to
+    private $iImg;
+    private $iTableHeaderBackgroundColor="white",$iTableHeaderFrameColor="black";
+    private $iTableHeaderFrameWeight=1;
+    private $iAvailableHeight=-1,$iVertSpacing=-1;
+    private $iDateLocale;
+    private $iVertLayout=GANTT_EVEN;
+    private $iUsePlotWeekendBackground=true;
+    private $iWeekStart = 1; // Default to have weekends start on Monday
+
+    //---------------
+    // CONSTRUCTOR
+    function __construct($aImg) {
+        $this->iImg = $aImg;
+        $this->iDateLocale = new DateLocale();
+
+        $this->minute = new HeaderProperty();
+        $this->minute->SetIntervall(15);
+        $this->minute->SetLabelFormatString('i');
+        $this->minute->SetFont(FF_FONT0);
+        $this->minute->grid->SetColor("gray");
+
+        $this->hour = new HeaderProperty();
+        $this->hour->SetFont(FF_FONT0);
+        $this->hour->SetIntervall(6);
+        $this->hour->SetStyle(HOURSTYLE_HM24);
+        $this->hour->SetLabelFormatString('H:i');
+        $this->hour->grid->SetColor("gray");
+
+        $this->day = new HeaderProperty();
+        $this->day->grid->SetColor("gray");
+        $this->day->SetLabelFormatString('l');
+
+        $this->week = new HeaderProperty();
+        $this->week->SetLabelFormatString("w%d");
+        $this->week->SetFont(FF_FONT1);
+
+        $this->month = new HeaderProperty();
+        $this->month->SetFont(FF_FONT1,FS_BOLD);
+
+        $this->year = new HeaderProperty();
+        $this->year->SetFont(FF_FONT1,FS_BOLD);
+
+        $this->divider=new LineProperty();
+        $this->dividerh=new LineProperty();
+        $this->dividerh->SetWeight(2);
+        $this->divider->SetWeight(6);
+        $this->divider->SetColor('gray');
+        $this->divider->SetStyle('fancy');
+
+        $this->tableTitle=new TextProperty();
+        $this->tableTitle->Show(false);
+        $this->actinfo = new GanttActivityInfo();
+    }
+
+    //---------------
+    // PUBLIC METHODS
+    // Specify what headers should be visible
+    function ShowHeaders($aFlg) {
+        $this->day->Show($aFlg & GANTT_HDAY);
+        $this->week->Show($aFlg & GANTT_HWEEK);
+        $this->month->Show($aFlg & GANTT_HMONTH);
+        $this->year->Show($aFlg & GANTT_HYEAR);
+        $this->hour->Show($aFlg & GANTT_HHOUR);
+        $this->minute->Show($aFlg & GANTT_HMIN);
+
+        // Make some default settings of gridlines whihc makes sense
+        if( $aFlg & GANTT_HWEEK ) {
+            $this->month->grid->Show(false);
+            $this->year->grid->Show(false);
+        }
+        if( $aFlg & GANTT_HHOUR ) {
+            $this->day->grid->SetColor("black");
+        }
+    }
+
+    // Should the weekend background stretch all the way down in the plotarea
+    function UseWeekendBackground($aShow) {
+        $this->iUsePlotWeekendBackground = $aShow;
+    }
+
+    // Have a range been specified?
+    function IsRangeSet() {
+        return $this->iStartDate!=-1 && $this->iEndDate!=-1;
+    }
+
+    // Should the layout be from top or even?
+    function SetVertLayout($aLayout) {
+        $this->iVertLayout = $aLayout;
+    }
+
+    // Which locale should be used?
+    function SetDateLocale($aLocale) {
+        $this->iDateLocale->Set($aLocale);
+    }
+
+    // Number of days we are showing
+    function GetNumberOfDays() {
+        return round(($this->iEndDate-$this->iStartDate)/SECPERDAY);
+    }
+
+    // The width of the actual plot area
+    function GetPlotWidth() {
+        $img=$this->iImg;
+        return $img->width - $img->left_margin - $img->right_margin;
+    }
+
+    // Specify the width of the titles(labels) for the activities
+    // (This is by default set to the minimum width enought for the
+    // widest title)
+    function SetLabelWidth($aLabelWidth) {
+        $this->iLabelWidth=$aLabelWidth;
+    }
+
+    // Which day should the week start?
+    // 0==Sun, 1==Monday, 2==Tuesday etc
+    function SetWeekStart($aStartDay) {
+        $this->iWeekStart = $aStartDay % 7;
+
+        //Recalculate the startday since this will change the week start
+        $this->SetRange($this->iStartDate,$this->iEndDate);
+    }
+
+    // Do we show min scale?
+    function IsDisplayMinute() {
+        return $this->minute->iShowLabels;
+    }
+
+    // Do we show day scale?
+    function IsDisplayHour() {
+        return $this->hour->iShowLabels;
+    }
+
+
+    // Do we show day scale?
+    function IsDisplayDay() {
+        return $this->day->iShowLabels;
+    }
+
+    // Do we show week scale?
+    function IsDisplayWeek() {
+        return $this->week->iShowLabels;
+    }
+
+    // Do we show month scale?
+    function IsDisplayMonth() {
+        return $this->month->iShowLabels;
+    }
+
+    // Do we show year scale?
+    function IsDisplayYear() {
+        return $this->year->iShowLabels;
+    }
+
+    // Specify spacing (in percent of bar height) between activity bars
+    function SetVertSpacing($aSpacing) {
+        $this->iVertSpacing = $aSpacing;
+    }
+
+    // Specify scale min and max date either as timestamp or as date strings
+    // Always round to the nearest week boundary
+    function SetRange($aMin,$aMax) {
+        $this->iStartDate = $this->NormalizeDate($aMin);
+        $this->iEndDate = $this->NormalizeDate($aMax);
+    }
+
+
+    // Adjust the start and end date so they fit to beginning/ending
+    // of the week taking the specified week start day into account.
+    function AdjustStartEndDay() {
+
+        if( !($this->IsDisplayYear() ||$this->IsDisplayMonth() || $this->IsDisplayWeek()) ) {
+            // Don't adjust
+            return;
+        }
+
+        // Get day in week for start and ending date (Sun==0)
+        $ds=strftime("%w",$this->iStartDate);
+        $de=strftime("%w",$this->iEndDate);
+
+        // We want to start on iWeekStart day. But first we subtract a week
+        // if the startdate is "behind" the day the week start at.
+        // This way we ensure that the given start date is always included
+        // in the range. If we don't do this the nearest correct weekday in the week
+        // to start at might be later than the start date.
+        if( $ds < $this->iWeekStart )
+        $d = strtotime('-7 day',$this->iStartDate);
+        else
+        $d = $this->iStartDate;
+        $adjdate = strtotime(($this->iWeekStart-$ds).' day',$d /*$this->iStartDate*/ );
+        $this->iStartDate = $adjdate;
+
+        // We want to end on the last day of the week
+        $preferredEndDay = ($this->iWeekStart+6)%7;
+        if( $preferredEndDay != $de ) {
+            // Solve equivalence eq:    $de + x ~ $preferredDay (mod 7)
+            $adj = (7+($preferredEndDay - $de)) % 7;
+            $adjdate = strtotime("+$adj day",$this->iEndDate);
+            $this->iEndDate = $adjdate;
+        }
+    }
+
+    // Specify background for the table title area (upper left corner of the table)
+    function SetTableTitleBackground($aColor) {
+        $this->iTableHeaderBackgroundColor = $aColor;
+    }
+
+    ///////////////////////////////////////
+    // PRIVATE Methods
+
+    // Determine the height of all the scale headers combined
+    function GetHeaderHeight() {
+        $img=$this->iImg;
+        $height=1;
+        if( $this->minute->iShowLabels ) {
+            $height += $this->minute->GetFontHeight($img);
+            $height += $this->minute->iTitleVertMargin;
+        }
+        if( $this->hour->iShowLabels ) {
+            $height += $this->hour->GetFontHeight($img);
+            $height += $this->hour->iTitleVertMargin;
+        }
+        if( $this->day->iShowLabels ) {
+            $height += $this->day->GetFontHeight($img);
+            $height += $this->day->iTitleVertMargin;
+        }
+        if( $this->week->iShowLabels ) {
+            $height += $this->week->GetFontHeight($img);
+            $height += $this->week->iTitleVertMargin;
+        }
+        if( $this->month->iShowLabels ) {
+            $height += $this->month->GetFontHeight($img);
+            $height += $this->month->iTitleVertMargin;
+        }
+        if( $this->year->iShowLabels ) {
+            $height += $this->year->GetFontHeight($img);
+            $height += $this->year->iTitleVertMargin;
+        }
+        return $height;
+    }
+
+    // Get width (in pixels) for a single day
+    function GetDayWidth() {
+        return ($this->GetPlotWidth()-$this->iLabelWidth+1)/$this->GetNumberOfDays();
+    }
+
+    // Get width (in pixels) for a single hour
+    function GetHourWidth() {
+        return $this->GetDayWidth() / 24 ;
+    }
+
+    function GetMinuteWidth() {
+        return $this->GetHourWidth() / 60 ;
+    }
+
+    // Nuber of days in a year
+    function GetNumDaysInYear($aYear) {
+        if( $this->IsLeap($aYear) )
+        return 366;
+        else
+        return 365;
+    }
+
+    // Get week number
+    function GetWeekNbr($aDate,$aSunStart=true) {
+        // We can't use the internal strftime() since it gets the weeknumber
+        // wrong since it doesn't follow ISO on all systems since this is
+        // system linrary dependent.
+        // Even worse is that this works differently if we are on a Windows
+        // or UNIX box (it even differs between UNIX boxes how strftime()
+        // is natively implemented)
+        //
+        // Credit to Nicolas Hoizey <nhoizey@phpheaven.net> for this elegant
+        // version of Week Nbr calculation.
+
+        $day = $this->NormalizeDate($aDate);
+        if( $aSunStart )
+        $day += 60*60*24;
+
+        /*-------------------------------------------------------------------------
+         According to ISO-8601 :
+         "Week 01 of a year is per definition the first week that has the Thursday in this year,
+         which is equivalent to the week that contains the fourth day of January.
+         In other words, the first week of a new year is the week that has the majority of its
+         days in the new year."
+
+         Be carefull, with PHP, -3 % 7 = -3, instead of 4 !!!
+
+         day of year             = date("z", $day) + 1
+         offset to thursday      = 3 - (date("w", $day) + 6) % 7
+         first thursday of year  = 1 + (11 - date("w", mktime(0, 0, 0, 1, 1, date("Y", $day)))) % 7
+         week number             = (thursday's day of year - first thursday's day of year) / 7 + 1
+         ---------------------------------------------------------------------------*/
+
+        $thursday = $day + 60 * 60 * 24 * (3 - (date("w", $day) + 6) % 7);              // take week's thursday
+        $week = 1 + (date("z", $thursday) - (11 - date("w", mktime(0, 0, 0, 1, 1, date("Y", $thursday)))) % 7) / 7;
+
+        return $week;
+    }
+
+    // Is year a leap year?
+    function IsLeap($aYear) {
+        // Is the year a leap year?
+        //$year = 0+date("Y",$aDate);
+        if( $aYear % 4 == 0)
+        if( !($aYear % 100 == 0) || ($aYear % 400 == 0) )
+        return true;
+        return false;
+    }
+
+    // Get current year
+    function GetYear($aDate) {
+        return 0+Date("Y",$aDate);
+    }
+
+    // Return number of days in a year
+    function GetNumDaysInMonth($aMonth,$aYear) {
+        $days=array(31,28,31,30,31,30,31,31,30,31,30,31);
+        $daysl=array(31,29,31,30,31,30,31,31,30,31,30,31);
+        if( $this->IsLeap($aYear))
+        return $daysl[$aMonth];
+        else
+        return $days[$aMonth];
+    }
+
+    // Get day in month
+    function GetMonthDayNbr($aDate) {
+        return 0+strftime("%d",$aDate);
+    }
+
+    // Get day in year
+    function GetYearDayNbr($aDate) {
+        return 0+strftime("%j",$aDate);
+    }
+
+    // Get month number
+    function GetMonthNbr($aDate) {
+        return 0+strftime("%m",$aDate);
+    }
+
+    // Translate a date to screen coordinates (horizontal scale)
+    function TranslateDate($aDate) {
+        //
+        // In order to handle the problem with Daylight savings time
+        // the scale written with equal number of seconds per day beginning
+        // with the start date. This means that we "cement" the state of
+        // DST as it is in the start date. If later the scale includes the
+        // switchover date (depends on the locale) we need to adjust back
+        // if the date we try to translate has a different DST status since
+        // we would otherwise be off by one hour.
+        $aDate = $this->NormalizeDate($aDate);
+        $tmp = localtime($aDate);
+        $cloc = $tmp[8];
+        $tmp = localtime($this->iStartDate);
+        $sloc = $tmp[8];
+        $offset = 0;
+        if( $sloc != $cloc) {
+            if( $sloc )
+            $offset = 3600;
+            else
+            $offset = -3600;
+        }
+        $img=$this->iImg;
+        return ($aDate-$this->iStartDate-$offset)/SECPERDAY*$this->GetDayWidth()+$img->left_margin+$this->iLabelWidth;;
+    }
+
+    // Get screen coordinatesz for the vertical position for a bar
+    function TranslateVertPos($aPos,$atTop=false) {
+        $img=$this->iImg;
+        if( $aPos > $this->iVertLines )
+        	JpGraphError::RaiseL(6015,$aPos);
+        // 'Illegal vertical position %d'
+        if( $this->iVertLayout == GANTT_EVEN ) {
+            // Position the top bar at 1 vert spacing from the scale
+            $pos =  round($img->top_margin + $this->iVertHeaderSize +  ($aPos+1)*$this->iVertSpacing);
+        }
+        else {
+            // position the top bar at 1/2 a vert spacing from the scale
+            $pos = round($img->top_margin + $this->iVertHeaderSize  + $this->iTopPlotMargin + ($aPos+1)*$this->iVertSpacing);
+        }
+
+        if( $atTop )
+            $pos -= $this->iVertSpacing;
+
+        return $pos;
+    }
+
+    // What is the vertical spacing?
+    function GetVertSpacing() {
+        return $this->iVertSpacing;
+    }
+
+    // Convert a date to timestamp
+    function NormalizeDate($aDate) {
+        if( $aDate === false ) return false;
+        if( is_string($aDate) ) {
+            $t = strtotime($aDate);
+            if( $t === FALSE || $t === -1 ) {
+                JpGraphError::RaiseL(6016,$aDate);
+                //("Date string ($aDate) specified for Gantt activity can not be interpretated. Please make sure it is a valid time string, e.g. 2005-04-23 13:30");
+            }
+            return $t;
+        }
+        elseif( is_int($aDate) || is_float($aDate) )
+            return $aDate;
+        else
+            JpGraphError::RaiseL(6017,$aDate);
+        //Unknown date format in GanttScale ($aDate).");
+    }
+
+
+    // Convert a time string to minutes
+
+    function TimeToMinutes($aTimeString) {
+        // Split in hours and minutes
+        $pos=strpos($aTimeString,':');
+        $minint=60;
+        if( $pos === false ) {
+            $hourint = $aTimeString;
+            $minint = 0;
+        }
+        else {
+            $hourint = floor(substr($aTimeString,0,$pos));
+            $minint = floor(substr($aTimeString,$pos+1));
+        }
+        $minint += 60 * $hourint;
+        return $minint;
+    }
+
+    // Stroke the day scale (including gridlines)
+    function StrokeMinutes($aYCoord,$getHeight=false) {
+        $img=$this->iImg;
+        $xt=$img->left_margin+$this->iLabelWidth;
+        $yt=$aYCoord+$img->top_margin;
+        if( $this->minute->iShowLabels ) {
+            $img->SetFont($this->minute->iFFamily,$this->minute->iFStyle,$this->minute->iFSize);
+            $yb = $yt + $img->GetFontHeight() +
+            $this->minute->iTitleVertMargin + $this->minute->iFrameWeight;
+            if( $getHeight ) {
+                return $yb - $img->top_margin;
+            }
+            $xb = $img->width-$img->right_margin+1;
+            $img->SetColor($this->minute->iBackgroundColor);
+            $img->FilledRectangle($xt,$yt,$xb,$yb);
+
+            $x = $xt;
+            $img->SetTextAlign("center");
+            $day = date('w',$this->iStartDate);
+            $minint = $this->minute->GetIntervall() ;
+
+            if( 60 % $minint !== 0 ) {
+                JpGraphError::RaiseL(6018,$minint);
+                //'Intervall for minutes must divide the hour evenly, e.g. 1,5,10,12,15,20,30 etc You have specified an intervall of '.$minint.' minutes.');
+            }
+
+
+            $n = 60 / $minint;
+            $datestamp = $this->iStartDate;
+            $width = $this->GetHourWidth() / $n ;
+            if( $width < 8 ) {
+                // TO small width to draw minute scale
+                JpGraphError::RaiseL(6019,$width);
+                //('The available width ('.$width.') for minutes are to small for this scale to be displayed. Please use auto-sizing or increase the width of the graph.');
+            }
+
+            $nh = ceil(24*60 / $this->TimeToMinutes($this->hour->GetIntervall()) );
+            $nd = $this->GetNumberOfDays();
+            // Convert to intervall to seconds
+            $minint *= 60;
+            for($j=0; $j < $nd; ++$j, $day += 1, $day %= 7) {
+                for( $k=0; $k < $nh; ++$k ) {
+                    for($i=0; $i < $n ;++$i, $x+=$width, $datestamp += $minint ) {
+                        if( $day==6 || $day==0 ) {
+
+                            $img->PushColor($this->day->iWeekendBackgroundColor);
+                            if( $this->iUsePlotWeekendBackground )
+                            $img->FilledRectangle($x,$yt+$this->day->iFrameWeight,$x+$width,$img->height-$img->bottom_margin);
+                            else
+                            $img->FilledRectangle($x,$yt+$this->day->iFrameWeight,$x+$width,$yb-$this->day->iFrameWeight);
+                            $img->PopColor();
+
+                        }
+
+                        if( $day==0 )
+                        $img->SetColor($this->day->iSundayTextColor);
+                        else
+                        $img->SetColor($this->day->iTextColor);
+
+                        switch( $this->minute->iStyle ) {
+                            case MINUTESTYLE_CUSTOM:
+                                $txt = date($this->minute->iLabelFormStr,$datestamp);
+                                break;
+                            case MINUTESTYLE_MM:
+                            default:
+                                // 15
+                                $txt = date('i',$datestamp);
+                                break;
+                        }
+                        $img->StrokeText(round($x+$width/2),round($yb-$this->minute->iTitleVertMargin),$txt);
+
+                        // Fix a rounding problem the wrong way ..
+                        // If we also have hour scale then don't draw the firsta or last
+                        // gridline since that will be overwritten by the hour scale gridline if such exists.
+                        // However, due to the propagation of rounding of the 'x+=width' term in the loop
+                        // this might sometimes be one pixel of so we fix this by not drawing it.
+                        // The proper way to fix it would be to re-calculate the scale for each step and
+                        // not using the additive term.
+                        if( !(($i == $n || $i==0) && $this->hour->iShowLabels && $this->hour->grid->iShow) ) {
+                            $img->SetColor($this->minute->grid->iColor);
+                            $img->SetLineWeight($this->minute->grid->iWeight);
+                            $img->Line($x,$yt,$x,$yb);
+                            $this->minute->grid->Stroke($img,$x,$yb,$x,$img->height-$img->bottom_margin);
+                        }
+                    }
+                }
+            }
+            $img->SetColor($this->minute->iFrameColor);
+            $img->SetLineWeight($this->minute->iFrameWeight);
+            $img->Rectangle($xt,$yt,$xb,$yb);
+            return $yb - $img->top_margin;
+        }
+        return $aYCoord;
+    }
+
+    // Stroke the day scale (including gridlines)
+    function StrokeHours($aYCoord,$getHeight=false) {
+        $img=$this->iImg;
+        $xt=$img->left_margin+$this->iLabelWidth;
+        $yt=$aYCoord+$img->top_margin;
+        if( $this->hour->iShowLabels ) {
+            $img->SetFont($this->hour->iFFamily,$this->hour->iFStyle,$this->hour->iFSize);
+            $yb = $yt + $img->GetFontHeight() +
+            $this->hour->iTitleVertMargin + $this->hour->iFrameWeight;
+            if( $getHeight ) {
+                return $yb - $img->top_margin;
+            }
+            $xb = $img->width-$img->right_margin+1;
+            $img->SetColor($this->hour->iBackgroundColor);
+            $img->FilledRectangle($xt,$yt,$xb,$yb);
+
+            $x = $xt;
+            $img->SetTextAlign("center");
+            $tmp = $this->hour->GetIntervall() ;
+            $minint = $this->TimeToMinutes($tmp);
+            if( 1440 % $minint !== 0 ) {
+                JpGraphError::RaiseL(6020,$tmp);
+                //('Intervall for hours must divide the day evenly, e.g. 0:30, 1:00, 1:30, 4:00 etc. You have specified an intervall of '.$tmp);
+            }
+
+            $n = ceil(24*60 / $minint );
+            $datestamp = $this->iStartDate;
+            $day = date('w',$this->iStartDate);
+            $doback = !$this->minute->iShowLabels;
+            $width = $this->GetDayWidth() / $n ;
+            for($j=0; $j < $this->GetNumberOfDays(); ++$j, $day += 1,$day %= 7) {
+                for($i=0; $i < $n ;++$i, $x+=$width) {
+                    if( $day==6 || $day==0 ) {
+
+                        $img->PushColor($this->day->iWeekendBackgroundColor);
+                        if( $this->iUsePlotWeekendBackground && $doback )
+                        $img->FilledRectangle($x,$yt+$this->day->iFrameWeight,$x+$width,$img->height-$img->bottom_margin);
+                        else
+                        $img->FilledRectangle($x,$yt+$this->day->iFrameWeight,$x+$width,$yb-$this->day->iFrameWeight);
+                        $img->PopColor();
+
+                    }
+
+                    if( $day==0 )
+                    $img->SetColor($this->day->iSundayTextColor);
+                    else
+                    $img->SetColor($this->day->iTextColor);
+
+                    switch( $this->hour->iStyle ) {
+                        case HOURSTYLE_HMAMPM:
+                            // 1:35pm
+                            $txt = date('g:ia',$datestamp);
+                            break;
+                        case HOURSTYLE_H24:
+                            // 13
+                            $txt = date('H',$datestamp);
+                            break;
+                        case HOURSTYLE_HAMPM:
+                            $txt = date('ga',$datestamp);
+                            break;
+                        case HOURSTYLE_CUSTOM:
+                            $txt = date($this->hour->iLabelFormStr,$datestamp);
+                            break;
+                        case HOURSTYLE_HM24:
+                        default:
+                            $txt = date('H:i',$datestamp);
+                            break;
+                    }
+                    $img->StrokeText(round($x+$width/2),round($yb-$this->hour->iTitleVertMargin),$txt);
+                    $img->SetColor($this->hour->grid->iColor);
+                    $img->SetLineWeight($this->hour->grid->iWeight);
+                    $img->Line($x,$yt,$x,$yb);
+                    $this->hour->grid->Stroke($img,$x,$yb,$x,$img->height-$img->bottom_margin);
+                    //$datestamp += $minint*60
+                    $datestamp = mktime(date('H',$datestamp),date('i',$datestamp)+$minint,0,
+                    date("m",$datestamp),date("d",$datestamp)+1,date("Y",$datestamp));
+
+                }
+            }
+            $img->SetColor($this->hour->iFrameColor);
+            $img->SetLineWeight($this->hour->iFrameWeight);
+            $img->Rectangle($xt,$yt,$xb,$yb);
+            return $yb - $img->top_margin;
+        }
+        return $aYCoord;
+    }
+
+
+    // Stroke the day scale (including gridlines)
+    function StrokeDays($aYCoord,$getHeight=false) {
+        $img=$this->iImg;
+        $daywidth=$this->GetDayWidth();
+        $xt=$img->left_margin+$this->iLabelWidth;
+        $yt=$aYCoord+$img->top_margin;
+        if( $this->day->iShowLabels ) {
+            $img->SetFont($this->day->iFFamily,$this->day->iFStyle,$this->day->iFSize);
+            $yb=$yt + $img->GetFontHeight() + $this->day->iTitleVertMargin + $this->day->iFrameWeight;
+            if( $getHeight ) {
+                return $yb - $img->top_margin;
+            }
+            $xb=$img->width-$img->right_margin+1;
+            $img->SetColor($this->day->iBackgroundColor);
+            $img->FilledRectangle($xt,$yt,$xb,$yb);
+
+            $x = $xt;
+            $img->SetTextAlign("center");
+            $day = date('w',$this->iStartDate);
+            $datestamp = $this->iStartDate;
+
+            $doback = !($this->hour->iShowLabels || $this->minute->iShowLabels);
+
+            setlocale(LC_TIME,$this->iDateLocale->iLocale);
+
+            for($i=0; $i < $this->GetNumberOfDays(); ++$i, $x+=$daywidth, $day += 1,$day %= 7) {
+                if( $day==6 || $day==0 ) {
+                    $img->SetColor($this->day->iWeekendBackgroundColor);
+                    if( $this->iUsePlotWeekendBackground && $doback)
+                        $img->FilledRectangle($x,$yt+$this->day->iFrameWeight,
+                                              $x+$daywidth,$img->height-$img->bottom_margin);
+                    else
+                        $img->FilledRectangle($x,$yt+$this->day->iFrameWeight,
+                    $x+$daywidth,$yb-$this->day->iFrameWeight);
+                }
+
+                $mn = strftime('%m',$datestamp);
+                if( $mn[0]=='0' )
+                    $mn = $mn[1];
+
+                switch( $this->day->iStyle ) {
+                    case DAYSTYLE_LONG:
+                        // "Monday"
+                        $txt = strftime('%A',$datestamp);
+                        break;
+                    case DAYSTYLE_SHORT:
+                        // "Mon"
+                        $txt = strftime('%a',$datestamp);
+                        break;
+                    case DAYSTYLE_SHORTDAYDATE1:
+                        // "Mon 23/6"
+                        $txt = strftime('%a %d/'.$mn,$datestamp);
+                        break;
+                    case DAYSTYLE_SHORTDAYDATE2:
+                        // "Mon 23 Jun"
+                        $txt = strftime('%a %d %b',$datestamp);
+                        break;
+                    case DAYSTYLE_SHORTDAYDATE3:
+                        // "Mon 23 Jun 2003"
+                        $txt = strftime('%a %d %b %Y',$datestamp);
+                        break;
+                    case DAYSTYLE_LONGDAYDATE1:
+                        // "Monday 23 Jun"
+                        $txt = strftime('%A %d %b',$datestamp);
+                        break;
+                    case DAYSTYLE_LONGDAYDATE2:
+                        // "Monday 23 Jun 2003"
+                        $txt = strftime('%A %d %b %Y',$datestamp);
+                        break;
+                    case DAYSTYLE_SHORTDATE1:
+                        // "23/6"
+                        $txt = strftime('%d/'.$mn,$datestamp);
+                        break;
+                    case DAYSTYLE_SHORTDATE2:
+                        // "23 Jun"
+                        $txt = strftime('%d %b',$datestamp);
+                        break;
+                    case DAYSTYLE_SHORTDATE3:
+                        // "Mon 23"
+                        $txt = strftime('%a %d',$datestamp);
+                        break;
+                    case DAYSTYLE_SHORTDATE4:
+                        // "23"
+                        $txt = strftime('%d',$datestamp);
+                        break;
+                    case DAYSTYLE_CUSTOM:
+                        // Custom format
+                        $txt = strftime($this->day->iLabelFormStr,$datestamp);
+                        break;
+                    case DAYSTYLE_ONELETTER:
+                    default:
+                        // "M"
+                        $txt = strftime('%A',$datestamp);
+                        $txt = strtoupper($txt[0]);
+                        break;
+                }
+
+                if( $day==0 )
+                    $img->SetColor($this->day->iSundayTextColor);
+                else
+                    $img->SetColor($this->day->iTextColor);
+                $img->StrokeText(round($x+$daywidth/2+1),
+                round($yb-$this->day->iTitleVertMargin),$txt);
+                $img->SetColor($this->day->grid->iColor);
+                $img->SetLineWeight($this->day->grid->iWeight);
+                $img->Line($x,$yt,$x,$yb);
+                $this->day->grid->Stroke($img,$x,$yb,$x,$img->height-$img->bottom_margin);
+                $datestamp = mktime(0,0,0,date("m",$datestamp),date("d",$datestamp)+1,date("Y",$datestamp));
+                //$datestamp += SECPERDAY;
+
+            }
+            $img->SetColor($this->day->iFrameColor);
+            $img->SetLineWeight($this->day->iFrameWeight);
+            $img->Rectangle($xt,$yt,$xb,$yb);
+            return $yb - $img->top_margin;
+        }
+        return $aYCoord;
+    }
+
+    // Stroke week header and grid
+    function StrokeWeeks($aYCoord,$getHeight=false) {
+        if( $this->week->iShowLabels ) {
+            $img=$this->iImg;
+            $yt=$aYCoord+$img->top_margin;
+            $img->SetFont($this->week->iFFamily,$this->week->iFStyle,$this->week->iFSize);
+            $yb=$yt + $img->GetFontHeight() + $this->week->iTitleVertMargin + $this->week->iFrameWeight;
+
+            if( $getHeight ) {
+                return $yb - $img->top_margin;
+            }
+
+            $xt=$img->left_margin+$this->iLabelWidth;
+            $weekwidth=$this->GetDayWidth()*7;
+            $wdays=$this->iDateLocale->GetDayAbb();
+            $xb=$img->width-$img->right_margin+1;
+            $week = $this->iStartDate;
+            $weeknbr=$this->GetWeekNbr($week);
+            $img->SetColor($this->week->iBackgroundColor);
+            $img->FilledRectangle($xt,$yt,$xb,$yb);
+            $img->SetColor($this->week->grid->iColor);
+            $x = $xt;
+            if( $this->week->iStyle==WEEKSTYLE_WNBR ) {
+                $img->SetTextAlign("center");
+                $txtOffset = $weekwidth/2+1;
+            }
+            elseif( $this->week->iStyle==WEEKSTYLE_FIRSTDAY  ||
+                    $this->week->iStyle==WEEKSTYLE_FIRSTDAY2 ||
+                    $this->week->iStyle==WEEKSTYLE_FIRSTDAYWNBR ||
+                    $this->week->iStyle==WEEKSTYLE_FIRSTDAY2WNBR ) {
+                $img->SetTextAlign("left");
+                $txtOffset = 3;
+            }
+            else {
+                JpGraphError::RaiseL(6021);
+                //("Unknown formatting style for week.");
+            }
+
+            for($i=0; $i<$this->GetNumberOfDays()/7; ++$i, $x+=$weekwidth) {
+                $img->PushColor($this->week->iTextColor);
+
+                if( $this->week->iStyle==WEEKSTYLE_WNBR )
+                    $txt = sprintf($this->week->iLabelFormStr,$weeknbr);
+                elseif( $this->week->iStyle==WEEKSTYLE_FIRSTDAY ||
+                        $this->week->iStyle==WEEKSTYLE_FIRSTDAYWNBR )
+                    $txt = date("j/n",$week);
+                elseif( $this->week->iStyle==WEEKSTYLE_FIRSTDAY2 ||
+                        $this->week->iStyle==WEEKSTYLE_FIRSTDAY2WNBR ) {
+                    $monthnbr = date("n",$week)-1;
+                    $shortmonth = $this->iDateLocale->GetShortMonthName($monthnbr);
+                    $txt = Date("j",$week)." ".$shortmonth;
+                }
+
+                if( $this->week->iStyle==WEEKSTYLE_FIRSTDAYWNBR ||
+                $this->week->iStyle==WEEKSTYLE_FIRSTDAY2WNBR ) {
+                    $w = sprintf($this->week->iLabelFormStr,$weeknbr);
+                    $txt .= ' '.$w;
+                }
+
+                $img->StrokeText(round($x+$txtOffset),
+                round($yb-$this->week->iTitleVertMargin),$txt);
+
+                $week = strtotime('+7 day',$week);
+                $weeknbr = $this->GetWeekNbr($week);
+                $img->PopColor();
+                $img->SetLineWeight($this->week->grid->iWeight);
+                $img->Line($x,$yt,$x,$yb);
+                $this->week->grid->Stroke($img,$x,$yb,$x,$img->height-$img->bottom_margin);
+            }
+            $img->SetColor($this->week->iFrameColor);
+            $img->SetLineWeight($this->week->iFrameWeight);
+            $img->Rectangle($xt,$yt,$xb,$yb);
+            return $yb-$img->top_margin;
+        }
+        return $aYCoord;
+    }
+
+    // Format the mont scale header string
+    function GetMonthLabel($aMonthNbr,$year) {
+        $sn = $this->iDateLocale->GetShortMonthName($aMonthNbr);
+        $ln = $this->iDateLocale->GetLongMonthName($aMonthNbr);
+        switch($this->month->iStyle) {
+            case MONTHSTYLE_SHORTNAME:
+                $m=$sn;
+                break;
+            case MONTHSTYLE_LONGNAME:
+                $m=$ln;
+                break;
+            case MONTHSTYLE_SHORTNAMEYEAR2:
+                $m=$sn." '".substr("".$year,2);
+                break;
+            case MONTHSTYLE_SHORTNAMEYEAR4:
+                $m=$sn." ".$year;
+                break;
+            case MONTHSTYLE_LONGNAMEYEAR2:
+                $m=$ln." '".substr("".$year,2);
+                break;
+            case MONTHSTYLE_LONGNAMEYEAR4:
+                $m=$ln." ".$year;
+                break;
+            case MONTHSTYLE_FIRSTLETTER:
+                $m=$sn[0];
+                break;
+        }
+        return $m;
+    }
+
+    // Stroke month scale and gridlines
+    function StrokeMonths($aYCoord,$getHeight=false) {
+        if( $this->month->iShowLabels ) {
+            $img=$this->iImg;
+            $img->SetFont($this->month->iFFamily,$this->month->iFStyle,$this->month->iFSize);
+            $yt=$aYCoord+$img->top_margin;
+            $yb=$yt + $img->GetFontHeight() + $this->month->iTitleVertMargin + $this->month->iFrameWeight;
+            if( $getHeight ) {
+                return $yb - $img->top_margin;
+            }
+            $monthnbr = $this->GetMonthNbr($this->iStartDate)-1;
+            $xt=$img->left_margin+$this->iLabelWidth;
+            $xb=$img->width-$img->right_margin+1;
+
+            $img->SetColor($this->month->iBackgroundColor);
+            $img->FilledRectangle($xt,$yt,$xb,$yb);
+
+            $img->SetLineWeight($this->month->grid->iWeight);
+            $img->SetColor($this->month->iTextColor);
+            $year = 0+strftime("%Y",$this->iStartDate);
+            $img->SetTextAlign("center");
+            if( $this->GetMonthNbr($this->iStartDate) == $this->GetMonthNbr($this->iEndDate)
+                && $this->GetYear($this->iStartDate)==$this->GetYear($this->iEndDate) ) {
+                $monthwidth=$this->GetDayWidth()*($this->GetMonthDayNbr($this->iEndDate) - $this->GetMonthDayNbr($this->iStartDate) + 1);
+            }
+            else {
+                $monthwidth=$this->GetDayWidth()*($this->GetNumDaysInMonth($monthnbr,$year)-$this->GetMonthDayNbr($this->iStartDate)+1);
+            }
+            // Is it enough space to stroke the first month?
+            $monthName = $this->GetMonthLabel($monthnbr,$year);
+            if( $monthwidth >= 1.2*$img->GetTextWidth($monthName) ) {
+                $img->SetColor($this->month->iTextColor);
+                $img->StrokeText(round($xt+$monthwidth/2+1),
+                round($yb-$this->month->iTitleVertMargin),
+                $monthName);
+            }
+            $x = $xt + $monthwidth;
+            while( $x < $xb ) {
+                $img->SetColor($this->month->grid->iColor);
+                $img->Line($x,$yt,$x,$yb);
+                $this->month->grid->Stroke($img,$x,$yb,$x,$img->height-$img->bottom_margin);
+                $monthnbr++;
+                if( $monthnbr==12 ) {
+                    $monthnbr=0;
+                    $year++;
+                }
+                $monthName = $this->GetMonthLabel($monthnbr,$year);
+                $monthwidth=$this->GetDayWidth()*$this->GetNumDaysInMonth($monthnbr,$year);
+                if( $x + $monthwidth < $xb )
+                    $w = $monthwidth;
+                else
+                    $w = $xb-$x;
+                if( $w >= 1.2*$img->GetTextWidth($monthName) ) {
+                    $img->SetColor($this->month->iTextColor);
+                    $img->StrokeText(round($x+$w/2+1),
+                    round($yb-$this->month->iTitleVertMargin),$monthName);
+                }
+                $x += $monthwidth;
+            }
+            $img->SetColor($this->month->iFrameColor);
+            $img->SetLineWeight($this->month->iFrameWeight);
+            $img->Rectangle($xt,$yt,$xb,$yb);
+            return $yb-$img->top_margin;
+        }
+        return $aYCoord;
+    }
+
+    // Stroke year scale and gridlines
+    function StrokeYears($aYCoord,$getHeight=false) {
+        if( $this->year->iShowLabels ) {
+            $img=$this->iImg;
+            $yt=$aYCoord+$img->top_margin;
+            $img->SetFont($this->year->iFFamily,$this->year->iFStyle,$this->year->iFSize);
+            $yb=$yt + $img->GetFontHeight() + $this->year->iTitleVertMargin + $this->year->iFrameWeight;
+
+            if( $getHeight ) {
+                return $yb - $img->top_margin;
+            }
+
+            $xb=$img->width-$img->right_margin+1;
+            $xt=$img->left_margin+$this->iLabelWidth;
+            $year = $this->GetYear($this->iStartDate);
+            $img->SetColor($this->year->iBackgroundColor);
+            $img->FilledRectangle($xt,$yt,$xb,$yb);
+            $img->SetLineWeight($this->year->grid->iWeight);
+            $img->SetTextAlign("center");
+            if( $year == $this->GetYear($this->iEndDate) )
+                $yearwidth=$this->GetDayWidth()*($this->GetYearDayNbr($this->iEndDate)-$this->GetYearDayNbr($this->iStartDate)+1);
+            else
+                $yearwidth=$this->GetDayWidth()*($this->GetNumDaysInYear($year)-$this->GetYearDayNbr($this->iStartDate)+1);
+
+            // The space for a year must be at least 20% bigger than the actual text
+            // so we allow 10% margin on each side
+            if( $yearwidth >= 1.20*$img->GetTextWidth("".$year) ) {
+                $img->SetColor($this->year->iTextColor);
+                $img->StrokeText(round($xt+$yearwidth/2+1),
+                                 round($yb-$this->year->iTitleVertMargin),
+                                 $year);
+            }
+            $x = $xt + $yearwidth;
+            while( $x < $xb ) {
+                $img->SetColor($this->year->grid->iColor);
+                $img->Line($x,$yt,$x,$yb);
+                $this->year->grid->Stroke($img,$x,$yb,$x,$img->height-$img->bottom_margin);
+                $year += 1;
+                $yearwidth=$this->GetDayWidth()*$this->GetNumDaysInYear($year);
+                if( $x + $yearwidth < $xb )
+                    $w = $yearwidth;
+                else
+                    $w = $xb-$x;
+                if( $w >= 1.2*$img->GetTextWidth("".$year) ) {
+                    $img->SetColor($this->year->iTextColor);
+                    $img->StrokeText(round($x+$w/2+1),
+                                     round($yb-$this->year->iTitleVertMargin),
+                                     $year);
+                }
+                $x += $yearwidth;
+            }
+            $img->SetColor($this->year->iFrameColor);
+            $img->SetLineWeight($this->year->iFrameWeight);
+            $img->Rectangle($xt,$yt,$xb,$yb);
+            return $yb-$img->top_margin;
+        }
+        return $aYCoord;
+    }
+
+    // Stroke table title (upper left corner)
+    function StrokeTableHeaders($aYBottom) {
+        $img=$this->iImg;
+        $xt=$img->left_margin;
+        $yt=$img->top_margin;
+        $xb=$xt+$this->iLabelWidth;
+        $yb=$aYBottom+$img->top_margin;
+
+        if( $this->tableTitle->iShow ) {
+            $img->SetColor($this->iTableHeaderBackgroundColor);
+            $img->FilledRectangle($xt,$yt,$xb,$yb);
+            $this->tableTitle->Align("center","top");
+            $this->tableTitle->Stroke($img,$xt+($xb-$xt)/2+1,$yt+2);
+            $img->SetColor($this->iTableHeaderFrameColor);
+            $img->SetLineWeight($this->iTableHeaderFrameWeight);
+            $img->Rectangle($xt,$yt,$xb,$yb);
+        }
+
+        $this->actinfo->Stroke($img,$xt,$yt,$xb,$yb,$this->tableTitle->iShow);
+
+
+        // Draw the horizontal dividing line
+        $this->dividerh->Stroke($img,$xt,$yb,$img->width-$img->right_margin,$yb);
+
+        // Draw the vertical dividing line
+        // We do the width "manually" since we want the line only to grow
+        // to the left
+        $fancy = $this->divider->iStyle == 'fancy' ;
+        if( $fancy ) {
+            $this->divider->iStyle = 'solid';
+        }
+
+        $tmp = $this->divider->iWeight;
+        $this->divider->iWeight=1;
+        $y = $img->height-$img->bottom_margin;
+        for($i=0; $i < $tmp; ++$i ) {
+            $this->divider->Stroke($img,$xb-$i,$yt,$xb-$i,$y);
+        }
+
+        // Should we draw "fancy" divider
+        if( $fancy ) {
+            $img->SetLineWeight(1);
+            $img->SetColor($this->iTableHeaderFrameColor);
+            $img->Line($xb,$yt,$xb,$y);
+            $img->Line($xb-$tmp+1,$yt,$xb-$tmp+1,$y);
+            $img->SetColor('white');
+            $img->Line($xb-$tmp+2,$yt,$xb-$tmp+2,$y);
+        }
+    }
+
+    // Main entry point to stroke scale
+    function Stroke() {
+        if( !$this->IsRangeSet() ) {
+        	JpGraphError::RaiseL(6022);
+        	//("Gantt scale has not been specified.");
+        }
+        $img=$this->iImg;
+
+        // If minutes are displayed then hour interval must be 1
+        if( $this->IsDisplayMinute() && $this->hour->GetIntervall() > 1 ) {
+            JpGraphError::RaiseL(6023);
+            //('If you display both hour and minutes the hour intervall must be 1 (Otherwise it doesn\' make sense to display minutes).');
+        }
+
+        // Stroke all headers. As argument we supply the offset from the
+        // top which depends on any previous headers
+
+        // First find out the height of each header
+        $offy=$this->StrokeYears(0,true);
+        $offm=$this->StrokeMonths($offy,true);
+        $offw=$this->StrokeWeeks($offm,true);
+        $offd=$this->StrokeDays($offw,true);
+        $offh=$this->StrokeHours($offd,true);
+        $offmin=$this->StrokeMinutes($offh,true);
+
+
+        // ... then we can stroke them in the "backwards order to ensure that
+        // the larger scale gridlines is stroked over the smaller scale gridline
+        $this->StrokeMinutes($offh);
+        $this->StrokeHours($offd);
+        $this->StrokeDays($offw);
+        $this->StrokeWeeks($offm);
+        $this->StrokeMonths($offy);
+        $this->StrokeYears(0);
+
+        // Now when we now the oaverall size of the scale headers
+        // we can stroke the overall table headers
+        $this->StrokeTableHeaders($offmin);
+
+        // Now we can calculate the correct scaling factor for each vertical position
+        $this->iAvailableHeight = $img->height - $img->top_margin - $img->bottom_margin - $offd;
+
+        $this->iVertHeaderSize = $offmin;
+        if( $this->iVertSpacing == -1 )
+        	$this->iVertSpacing = $this->iAvailableHeight / $this->iVertLines;
+    }
+}
+
+
+//===================================================
+// CLASS GanttConstraint
+// Just a structure to store all the values for a constraint
+//===================================================
+class GanttConstraint {
+    public $iConstrainRow;
+    public $iConstrainType;
+    public $iConstrainColor;
+    public $iConstrainArrowSize;
+    public $iConstrainArrowType;
+
+    //---------------
+    // CONSTRUCTOR
+    function __construct($aRow,$aType,$aColor,$aArrowSize,$aArrowType){
+        $this->iConstrainType = $aType;
+        $this->iConstrainRow = $aRow;
+        $this->iConstrainColor=$aColor;
+        $this->iConstrainArrowSize=$aArrowSize;
+        $this->iConstrainArrowType=$aArrowType;
+    }
+}
+
+
+//===================================================
+// CLASS GanttPlotObject
+// The common signature for a Gantt object
+//===================================================
+class GanttPlotObject {
+    public $title,$caption;
+    public $csimarea='',$csimtarget='',$csimwintarget='',$csimalt='';
+    public $constraints = array();
+    public $iCaptionMargin=5;
+    public $iConstrainPos=array();
+    protected $iStart="";    // Start date
+    public $iVPos=0;     // Vertical position
+    protected $iLabelLeftMargin=2; // Title margin
+
+    function __construct() {
+        $this->title = new TextProperty();
+        $this->title->Align('left','center');
+        $this->caption = new TextProperty();
+    }
+
+    function GetCSIMArea() {
+        return $this->csimarea;
+    }
+
+    function SetCSIMTarget($aTarget,$aAlt='',$aWinTarget='') {
+        if( !is_string($aTarget) ) {
+            $tv = substr(var_export($aTarget,true),0,40);
+            JpGraphError::RaiseL(6024,$tv);
+            //('CSIM Target must be specified as a string.'."\nStart of target is:\n$tv");
+        }
+        if( !is_string($aAlt) ) {
+            $tv = substr(var_export($aAlt,true),0,40);
+            JpGraphError::RaiseL(6025,$tv);
+            //('CSIM Alt text must be specified as a string.'."\nStart of alt text is:\n$tv");
+        }
+
+        $this->csimtarget=$aTarget;
+        $this->csimwintarget=$aWinTarget;
+        $this->csimalt=$aAlt;
+    }
+
+    function SetCSIMAlt($aAlt) {
+        if( !is_string($aAlt) ) {
+            $tv = substr(var_export($aAlt,true),0,40);
+            JpGraphError::RaiseL(6025,$tv);
+            //('CSIM Alt text must be specified as a string.'."\nStart of alt text is:\n$tv");
+        }
+        $this->csimalt=$aAlt;
+    }
+
+    function SetConstrain($aRow,$aType,$aColor='black',$aArrowSize=ARROW_S2,$aArrowType=ARROWT_SOLID) {
+        $this->constraints[] = new GanttConstraint($aRow, $aType, $aColor, $aArrowSize, $aArrowType);
+    }
+
+    function SetConstrainPos($xt,$yt,$xb,$yb) {
+        $this->iConstrainPos = array($xt,$yt,$xb,$yb);
+    }
+
+    function GetMinDate() {
+        return $this->iStart;
+    }
+
+    function GetMaxDate() {
+        return $this->iStart;
+    }
+
+    function SetCaptionMargin($aMarg) {
+        $this->iCaptionMargin=$aMarg;
+    }
+
+    function GetAbsHeight($aImg) {
+        return 0;
+    }
+
+    function GetLineNbr() {
+        return $this->iVPos;
+    }
+
+    function SetLabelLeftMargin($aOff) {
+        $this->iLabelLeftMargin=$aOff;
+    }
+
+    function StrokeActInfo($aImg,$aScale,$aYPos) {
+        $cols=array();
+        $aScale->actinfo->GetColStart($aImg,$cols,true);
+        $this->title->Stroke($aImg,$cols,$aYPos);
+    }
+}
+
+//===================================================
+// CLASS Progress
+// Holds parameters for the progress indicator
+// displyed within a bar
+//===================================================
+class Progress {
+    public $iProgress=-1;
+    public $iPattern=GANTT_SOLID;
+    public $iColor="black", $iFillColor='black';
+    public $iDensity=98, $iHeight=0.65;
+
+    function Set($aProg) {
+        if( $aProg < 0.0 || $aProg > 1.0 ) {
+        	JpGraphError::RaiseL(6027);
+        	//("Progress value must in range [0, 1]");
+        }
+        $this->iProgress = $aProg;
+    }
+
+    function SetPattern($aPattern,$aColor="blue",$aDensity=98) {
+        $this->iPattern = $aPattern;
+        $this->iColor = $aColor;
+        $this->iDensity = $aDensity;
+    }
+
+    function SetFillColor($aColor) {
+        $this->iFillColor = $aColor;
+    }
+
+    function SetHeight($aHeight) {
+        $this->iHeight = $aHeight;
+    }
+}
+
+define('GANTT_HGRID1',0);
+define('GANTT_HGRID2',1);
+
+//===================================================
+// CLASS HorizontalGridLine
+// Responsible for drawinf horizontal gridlines and filled alternatibg rows
+//===================================================
+class HorizontalGridLine {
+    private $iGraph=NULL;
+    private $iRowColor1 = '', $iRowColor2 = '';
+    private $iShow=false;
+    private $line=null;
+    private $iStart=0; // 0=from left margin, 1=just along header
+
+    function __construct() {
+        $this->line = new LineProperty();
+        $this->line->SetColor('gray@0.4');
+        $this->line->SetStyle('dashed');
+    }
+
+    function Show($aShow=true) {
+        $this->iShow = $aShow;
+    }
+
+    function SetRowFillColor($aColor1,$aColor2='') {
+        $this->iRowColor1 = $aColor1;
+        $this->iRowColor2 = $aColor2;
+    }
+
+    function SetStart($aStart) {
+        $this->iStart = $aStart;
+    }
+
+    function Stroke($aImg,$aScale) {
+
+        if( ! $this->iShow ) return;
+
+        // Get horizontal width of line
+        /*
+        $limst = $aScale->iStartDate;
+        $limen = $aScale->iEndDate;
+        $xt = round($aScale->TranslateDate($aScale->iStartDate));
+        $xb = round($aScale->TranslateDate($limen));
+        */
+
+        if( $this->iStart === 0 ) {
+            $xt = $aImg->left_margin-1;
+        }
+        else {
+            $xt = round($aScale->TranslateDate($aScale->iStartDate))+1;
+        }
+
+        $xb = $aImg->width-$aImg->right_margin;
+
+        $yt = round($aScale->TranslateVertPos(0));
+        $yb = round($aScale->TranslateVertPos(1));
+        $height = $yb - $yt;
+
+        // Loop around for all lines in the chart
+        for($i=0; $i < $aScale->iVertLines; ++$i ) {
+            $yb = $yt - $height;
+            $this->line->Stroke($aImg,$xt,$yb,$xb,$yb);
+            if( $this->iRowColor1 !== '' ) {
+                if( $i % 2 == 0 ) {
+                    $aImg->PushColor($this->iRowColor1);
+                    $aImg->FilledRectangle($xt,$yt,$xb,$yb);
+                    $aImg->PopColor();
+                }
+                elseif( $this->iRowColor2 !== '' ) {
+                    $aImg->PushColor($this->iRowColor2);
+                    $aImg->FilledRectangle($xt,$yt,$xb,$yb);
+                    $aImg->PopColor();
+                }
+            }
+            $yt = round($aScale->TranslateVertPos($i+1));
+        }
+        $yb = $yt - $height;
+        $this->line->Stroke($aImg,$xt,$yb,$xb,$yb);
+    }
+}
+
+
+//===================================================
+// CLASS GanttBar
+// Responsible for formatting individual gantt bars
+//===================================================
+class GanttBar extends GanttPlotObject {
+    public $progress;
+    public $leftMark,$rightMark;
+    private $iEnd;
+    private $iHeightFactor=0.5;
+    private $iFillColor="white",$iFrameColor="black";
+    private $iShadow=false,$iShadowColor="darkgray",$iShadowWidth=1,$iShadowFrame="black";
+    private $iPattern=GANTT_RDIAG,$iPatternColor="blue",$iPatternDensity=95;
+    private $iBreakStyle=false, $iBreakLineStyle='dotted',$iBreakLineWeight=1;
+    //---------------
+    // CONSTRUCTOR
+    function __construct($aPos,$aLabel,$aStart,$aEnd,$aCaption="",$aHeightFactor=0.6) {
+        parent::__construct();
+        $this->iStart = $aStart;
+        // Is the end date given as a date or as number of days added to start date?
+        if( is_string($aEnd) ) {
+            // If end date has been specified without a time we will asssume
+            // end date is at the end of that date
+            if( strpos($aEnd,':') === false ) {
+            	$this->iEnd = strtotime($aEnd)+SECPERDAY-1;
+            }
+            else {
+            	$this->iEnd = $aEnd;
+            }
+        }
+        elseif(is_int($aEnd) || is_float($aEnd) ) {
+        	$this->iEnd = strtotime($aStart)+round($aEnd*SECPERDAY);
+        }
+        $this->iVPos = $aPos;
+        $this->iHeightFactor = $aHeightFactor;
+        $this->title->Set($aLabel);
+        $this->caption = new TextProperty($aCaption);
+        $this->caption->Align("left","center");
+        $this->leftMark =new PlotMark();
+        $this->leftMark->Hide();
+        $this->rightMark=new PlotMark();
+        $this->rightMark->Hide();
+        $this->progress = new Progress();
+    }
+
+    //---------------
+    // PUBLIC METHODS
+    function SetShadow($aShadow=true,$aColor="gray") {
+        $this->iShadow=$aShadow;
+        $this->iShadowColor=$aColor;
+    }
+
+    function SetBreakStyle($aFlg=true,$aLineStyle='dotted',$aLineWeight=1) {
+    	$this->iBreakStyle = $aFlg;
+    	$this->iBreakLineStyle = $aLineStyle;
+    	$this->iBreakLineWeight = $aLineWeight;
+    }
+
+    function GetMaxDate() {
+        return $this->iEnd;
+    }
+
+    function SetHeight($aHeight) {
+        $this->iHeightFactor = $aHeight;
+    }
+
+    function SetColor($aColor) {
+        $this->iFrameColor = $aColor;
+    }
+
+    function SetFillColor($aColor) {
+        $this->iFillColor = $aColor;
+    }
+
+    function GetAbsHeight($aImg) {
+        if( is_int($this->iHeightFactor) || $this->leftMark->show || $this->rightMark->show ) {
+            $m=-1;
+            if( is_int($this->iHeightFactor) )
+            	$m = $this->iHeightFactor;
+            if( $this->leftMark->show )
+            	$m = max($m,$this->leftMark->width*2);
+            if( $this->rightMark->show )
+            	$m = max($m,$this->rightMark->width*2);
+            return $m;
+        }
+        else
+        	return -1;
+    }
+
+    function SetPattern($aPattern,$aColor="blue",$aDensity=95) {
+        $this->iPattern = $aPattern;
+        $this->iPatternColor = $aColor;
+        $this->iPatternDensity = $aDensity;
+    }
+
+    function Stroke($aImg,$aScale) {
+        $factory = new RectPatternFactory();
+        $prect = $factory->Create($this->iPattern,$this->iPatternColor);
+        $prect->SetDensity($this->iPatternDensity);
+
+        // If height factor is specified as a float between 0,1 then we take it as meaning
+        // percetage of the scale width between horizontal line.
+        // If it is an integer > 1 we take it to mean the absolute height in pixels
+        if( $this->iHeightFactor > -0.0 && $this->iHeightFactor <= 1.1)
+        	$vs = $aScale->GetVertSpacing()*$this->iHeightFactor;
+        elseif(is_int($this->iHeightFactor) && $this->iHeightFactor>2 && $this->iHeightFactor < 200 )
+        	$vs = $this->iHeightFactor;
+        else {
+        	JpGraphError::RaiseL(6028,$this->iHeightFactor);
+        	//	("Specified height (".$this->iHeightFactor.") for gantt bar is out of range.");
+        }
+
+        // Clip date to min max dates to show
+        $st = $aScale->NormalizeDate($this->iStart);
+        $en = $aScale->NormalizeDate($this->iEnd);
+
+        $limst = max($st,$aScale->iStartDate);
+        $limen = min($en,$aScale->iEndDate);
+
+        $xt = round($aScale->TranslateDate($limst));
+        $xb = round($aScale->TranslateDate($limen));
+        $yt = round($aScale->TranslateVertPos($this->iVPos)-$vs-($aScale->GetVertSpacing()/2-$vs/2));
+        $yb = round($aScale->TranslateVertPos($this->iVPos)-($aScale->GetVertSpacing()/2-$vs/2));
+        $middle = round($yt+($yb-$yt)/2);
+        $this->StrokeActInfo($aImg,$aScale,$middle);
+
+        // CSIM for title
+        if( ! empty($this->title->csimtarget) ) {
+            $colwidth = $this->title->GetColWidth($aImg);
+            $colstarts=array();
+            $aScale->actinfo->GetColStart($aImg,$colstarts,true);
+            $n = min(count($colwidth),count($this->title->csimtarget));
+            for( $i=0; $i < $n; ++$i ) {
+                $title_xt = $colstarts[$i];
+                $title_xb = $title_xt + $colwidth[$i];
+                $coords = "$title_xt,$yt,$title_xb,$yt,$title_xb,$yb,$title_xt,$yb";
+
+                if( ! empty($this->title->csimtarget[$i]) ) {
+                    $this->csimarea .= "<area shape=\"poly\" coords=\"$coords\" href=\"".$this->title->csimtarget[$i]."\"";
+
+                    if( ! empty($this->title->csimwintarget[$i]) ) {
+                        $this->csimarea .= "target=\"".$this->title->csimwintarget[$i]."\" ";
+                    }
+
+                    if( ! empty($this->title->csimalt[$i]) ) {
+                        $tmp = $this->title->csimalt[$i];
+                        $this->csimarea .= " title=\"$tmp\" alt=\"$tmp\" ";
+                    }
+                    $this->csimarea .= " />\n";
+                }
+            }
+        }
+
+        // Check if the bar is totally outside the current scale range
+        if( $en <  $aScale->iStartDate || $st > $aScale->iEndDate )
+        	return;
+
+
+        // Remember the positions for the bar
+        $this->SetConstrainPos($xt,$yt,$xb,$yb);
+
+
+
+        $prect->ShowFrame(false);
+        $prect->SetBackground($this->iFillColor);
+        if( $this->iBreakStyle ) {
+        	$aImg->SetColor($this->iFrameColor);
+        	$olds = $aImg->SetLineStyle($this->iBreakLineStyle);
+        	$oldw = $aImg->SetLineWeight($this->iBreakLineWeight);
+        	$aImg->StyleLine($xt,$yt,$xb,$yt);
+        	$aImg->StyleLine($xt,$yb,$xb,$yb);
+        	$aImg->SetLineStyle($olds);
+        	$aImg->SetLineWeight($oldw);
+        }
+        else {
+	        if( $this->iShadow ) {
+	            $aImg->SetColor($this->iFrameColor);
+	            $aImg->ShadowRectangle($xt,$yt,$xb,$yb,$this->iFillColor,$this->iShadowWidth,$this->iShadowColor);
+	            $prect->SetPos(new Rectangle($xt+1,$yt+1,$xb-$xt-$this->iShadowWidth-2,$yb-$yt-$this->iShadowWidth-2));
+	            $prect->Stroke($aImg);
+	        }
+	        else {
+	            $prect->SetPos(new Rectangle($xt,$yt,$xb-$xt+1,$yb-$yt+1));
+	            $prect->Stroke($aImg);
+	            $aImg->SetColor($this->iFrameColor);
+	            $aImg->Rectangle($xt,$yt,$xb,$yb);
+	        }
+        }
+        // CSIM for bar
+        if( ! empty($this->csimtarget) ) {
+
+            $coords = "$xt,$yt,$xb,$yt,$xb,$yb,$xt,$yb";
+            $this->csimarea .= "<area shape=\"poly\" coords=\"$coords\" href=\"".$this->csimtarget."\"";
+
+            if( !empty($this->csimwintarget) ) {
+                $this->csimarea .= " target=\"".$this->csimwintarget."\" ";
+            }
+
+            if( $this->csimalt != '' ) {
+                $tmp = $this->csimalt;
+                $this->csimarea .= " title=\"$tmp\" alt=\"$tmp\" ";
+            }
+            $this->csimarea .= " />\n";
+        }
+
+        // Draw progress bar inside activity bar
+        if( $this->progress->iProgress > 0 ) {
+
+            $xtp = $aScale->TranslateDate($st);
+            $xbp = $aScale->TranslateDate($en);
+            $len = ($xbp-$xtp)*$this->progress->iProgress;
+
+            $endpos = $xtp+$len;
+            if( $endpos > $xt ) {
+
+                // Take away the length of the progress that is not visible (before the start date)
+                $len -= ($xt-$xtp);
+
+                // Is the the progress bar visible after the start date?
+                if( $xtp < $xt )
+                $xtp = $xt;
+
+                // Make sure that the progess bar doesn't extend over the end date
+                if( $xtp+$len-1 > $xb )
+                $len = $xb - $xtp ;
+
+                $prog = $factory->Create($this->progress->iPattern,$this->progress->iColor);
+                $prog->SetDensity($this->progress->iDensity);
+                $prog->SetBackground($this->progress->iFillColor);
+                $barheight = ($yb-$yt+1);
+                if( $this->iShadow )
+                	$barheight -= $this->iShadowWidth;
+                $progressheight = floor($barheight*$this->progress->iHeight);
+                $marg = ceil(($barheight-$progressheight)/2);
+                $pos = new Rectangle($xtp,$yt + $marg, $len,$barheight-2*$marg);
+                $prog->SetPos($pos);
+                $prog->Stroke($aImg);
+            }
+        }
+
+        // We don't plot the end mark if the bar has been capped
+        if( $limst == $st ) {
+            $y = $middle;
+            // We treat the RIGHT and LEFT triangle mark a little bi
+            // special so that these marks are placed right under the
+            // bar.
+            if( $this->leftMark->GetType() == MARK_LEFTTRIANGLE ) {
+                $y = $yb ;
+            }
+            $this->leftMark->Stroke($aImg,$xt,$y);
+        }
+        if( $limen == $en ) {
+            $y = $middle;
+            // We treat the RIGHT and LEFT triangle mark a little bi
+            // special so that these marks are placed right under the
+            // bar.
+            if( $this->rightMark->GetType() == MARK_RIGHTTRIANGLE ) {
+                $y = $yb ;
+            }
+            $this->rightMark->Stroke($aImg,$xb,$y);
+
+            $margin = $this->iCaptionMargin;
+            if( $this->rightMark->show )
+            	$margin += $this->rightMark->GetWidth();
+            $this->caption->Stroke($aImg,$xb+$margin,$middle);
+        }
+    }
+}
+
+//===================================================
+// CLASS MileStone
+// Responsible for formatting individual milestones
+//===================================================
+class MileStone extends GanttPlotObject {
+    public $mark;
+
+    //---------------
+    // CONSTRUCTOR
+    function __construct($aVPos,$aLabel,$aDate,$aCaption="") {
+        GanttPlotObject::__construct();
+        $this->caption->Set($aCaption);
+        $this->caption->Align("left","center");
+        $this->caption->SetFont(FF_FONT1,FS_BOLD);
+        $this->title->Set($aLabel);
+        $this->title->SetColor("darkred");
+        $this->mark = new PlotMark();
+        $this->mark->SetWidth(10);
+        $this->mark->SetType(MARK_DIAMOND);
+        $this->mark->SetColor("darkred");
+        $this->mark->SetFillColor("darkred");
+        $this->iVPos = $aVPos;
+        $this->iStart = $aDate;
+    }
+
+    //---------------
+    // PUBLIC METHODS
+
+    function GetAbsHeight($aImg) {
+        return max($this->title->GetHeight($aImg),$this->mark->GetWidth());
+    }
+
+    function Stroke($aImg,$aScale) {
+        // Put the mark in the middle at the middle of the day
+        $d = $aScale->NormalizeDate($this->iStart)+SECPERDAY/2;
+        $x = $aScale->TranslateDate($d);
+        $y = $aScale->TranslateVertPos($this->iVPos)-($aScale->GetVertSpacing()/2);
+
+        $this->StrokeActInfo($aImg,$aScale,$y);
+
+        // CSIM for title
+        if( ! empty($this->title->csimtarget) ) {
+
+            $yt = round($y - $this->title->GetHeight($aImg)/2);
+            $yb = round($y + $this->title->GetHeight($aImg)/2);
+
+            $colwidth = $this->title->GetColWidth($aImg);
+            $colstarts=array();
+            $aScale->actinfo->GetColStart($aImg,$colstarts,true);
+            $n = min(count($colwidth),count($this->title->csimtarget));
+            for( $i=0; $i < $n; ++$i ) {
+                $title_xt = $colstarts[$i];
+                $title_xb = $title_xt + $colwidth[$i];
+                $coords = "$title_xt,$yt,$title_xb,$yt,$title_xb,$yb,$title_xt,$yb";
+
+                if( !empty($this->title->csimtarget[$i]) ) {
+
+                    $this->csimarea .= "<area shape=\"poly\" coords=\"$coords\" href=\"".$this->title->csimtarget[$i]."\"";
+
+                    if( !empty($this->title->csimwintarget[$i]) ) {
+                        $this->csimarea .= "target=\"".$this->title->csimwintarget[$i]."\"";
+                    }
+
+                    if( ! empty($this->title->csimalt[$i]) ) {
+                        $tmp = $this->title->csimalt[$i];
+                        $this->csimarea .= " title=\"$tmp\" alt=\"$tmp\" ";
+                    }
+                    $this->csimarea .= " />\n";
+                }
+            }
+        }
+
+        if( $d <  $aScale->iStartDate || $d > $aScale->iEndDate )
+        	return;
+
+        // Remember the coordinates for any constrains linking to
+        // this milestone
+        $w = $this->mark->GetWidth()/2;
+        $this->SetConstrainPos($x,round($y-$w),$x,round($y+$w));
+
+        // Setup CSIM
+        if( $this->csimtarget != '' ) {
+            $this->mark->SetCSIMTarget( $this->csimtarget );
+            $this->mark->SetCSIMAlt( $this->csimalt );
+        }
+
+        $this->mark->Stroke($aImg,$x,$y);
+        $this->caption->Stroke($aImg,$x+$this->mark->width/2+$this->iCaptionMargin,$y);
+
+        $this->csimarea .= $this->mark->GetCSIMAreas();
+    }
+}
+
+
+//===================================================
+// CLASS GanttVLine
+// Responsible for formatting individual milestones
+//===================================================
+
+class TextPropertyBelow extends TextProperty {
+    function __construct($aTxt='') {
+        parent::__construct($aTxt);
+    }
+
+    function GetColWidth($aImg,$aMargin=0) {
+        // Since we are not stroking the title in the columns
+        // but rather under the graph we want this to return 0.
+        return array(0);
+    }
+}
+
+class GanttVLine extends GanttPlotObject {
+
+    private $iLine,$title_margin=3, $iDayOffset=0.5;
+    private $iStartRow = -1, $iEndRow = -1;
+
+    //---------------
+    // CONSTRUCTOR
+    function __construct($aDate,$aTitle="",$aColor="darkred",$aWeight=2,$aStyle="solid") {
+        GanttPlotObject::__construct();
+        $this->iLine = new LineProperty();
+        $this->iLine->SetColor($aColor);
+        $this->iLine->SetWeight($aWeight);
+        $this->iLine->SetStyle($aStyle);
+        $this->iStart = $aDate;
+        $this->title = new TextPropertyBelow();
+        $this->title->Set($aTitle);
+    }
+
+    //---------------
+    // PUBLIC METHODS
+
+    // Set start and end rows for the VLine. By default the entire heigh of the
+    // Gantt chart is used
+    function SetRowSpan($aStart, $aEnd=-1) {
+        $this->iStartRow = $aStart;
+        $this->iEndRow = $aEnd;
+    }
+
+    function SetDayOffset($aOff=0.5) {
+        if( $aOff < 0.0 || $aOff > 1.0 ) {
+        	JpGraphError::RaiseL(6029);
+        	//("Offset for vertical line must be in range [0,1]");
+        }
+        $this->iDayOffset = $aOff;
+    }
+
+    function SetTitleMargin($aMarg) {
+        $this->title_margin = $aMarg;
+    }
+
+    function SetWeight($aWeight) {
+        $this->iLine->SetWeight($aWeight);
+    }
+
+    function Stroke($aImg,$aScale) {
+        $d = $aScale->NormalizeDate($this->iStart);
+        if( $d <  $aScale->iStartDate || $d > $aScale->iEndDate )
+            return;
+        if($this->iDayOffset != 0.0)
+            $d += 24*60*60*$this->iDayOffset;
+        $x = $aScale->TranslateDate($d);//d=1006858800,
+
+        if( $this->iStartRow > -1 ) {
+            $y1 = $aScale->TranslateVertPos($this->iStartRow,true) ;
+        }
+        else {
+            $y1 = $aScale->iVertHeaderSize+$aImg->top_margin;
+        }
+
+        if( $this->iEndRow > -1 ) {
+            $y2 = $aScale->TranslateVertPos($this->iEndRow);
+        }
+        else {
+            $y2 = $aImg->height - $aImg->bottom_margin;
+        }
+
+        $this->iLine->Stroke($aImg,$x,$y1,$x,$y2);
+        $this->title->Align("center","top");
+        $this->title->Stroke($aImg,$x,$y2+$this->title_margin);
+    }
+}
+
+//===================================================
+// CLASS LinkArrow
+// Handles the drawing of a an arrow
+//===================================================
+class LinkArrow {
+    private $ix,$iy;
+    private $isizespec = array(
+    array(2,3),array(3,5),array(3,8),array(6,15),array(8,22));
+    private $iDirection=ARROW_DOWN,$iType=ARROWT_SOLID,$iSize=ARROW_S2;
+    private $iColor='black';
+
+    function __construct($x,$y,$aDirection,$aType=ARROWT_SOLID,$aSize=ARROW_S2) {
+        $this->iDirection = $aDirection;
+        $this->iType = $aType;
+        $this->iSize = $aSize;
+        $this->ix = $x;
+        $this->iy = $y;
+    }
+
+    function SetColor($aColor) {
+        $this->iColor = $aColor;
+    }
+
+    function SetSize($aSize) {
+        $this->iSize = $aSize;
+    }
+
+    function SetType($aType) {
+        $this->iType = $aType;
+    }
+
+    function Stroke($aImg) {
+        list($dx,$dy) = $this->isizespec[$this->iSize];
+        $x = $this->ix;
+        $y = $this->iy;
+        switch ( $this->iDirection ) {
+            case ARROW_DOWN:
+                $c = array($x,$y,$x-$dx,$y-$dy,$x+$dx,$y-$dy,$x,$y);
+                break;
+            case ARROW_UP:
+                $c = array($x,$y,$x-$dx,$y+$dy,$x+$dx,$y+$dy,$x,$y);
+                break;
+            case ARROW_LEFT:
+                $c = array($x,$y,$x+$dy,$y-$dx,$x+$dy,$y+$dx,$x,$y);
+                break;
+            case ARROW_RIGHT:
+                $c = array($x,$y,$x-$dy,$y-$dx,$x-$dy,$y+$dx,$x,$y);
+                break;
+            default:
+                JpGraphError::RaiseL(6030);
+                //('Unknown arrow direction for link.');
+                die();
+                break;
+        }
+        $aImg->SetColor($this->iColor);
+        switch( $this->iType ) {
+            case ARROWT_SOLID:
+                $aImg->FilledPolygon($c);
+                break;
+            case ARROWT_OPEN:
+                $aImg->Polygon($c);
+                break;
+            default:
+                JpGraphError::RaiseL(6031);
+                //('Unknown arrow type for link.');
+                die();
+                break;
+        }
+    }
+}
+
+//===================================================
+// CLASS GanttLink
+// Handles the drawing of a link line between 2 points
+//===================================================
+
+class GanttLink {
+    private $ix1,$ix2,$iy1,$iy2;
+    private $iPathType=2,$iPathExtend=15;
+    private $iColor='black',$iWeight=1;
+    private $iArrowSize=ARROW_S2,$iArrowType=ARROWT_SOLID;
+
+    function __construct($x1=0,$y1=0,$x2=0,$y2=0) {
+        $this->ix1 = $x1;
+        $this->ix2 = $x2;
+        $this->iy1 = $y1;
+        $this->iy2 = $y2;
+    }
+
+    function SetPos($x1,$y1,$x2,$y2) {
+        $this->ix1 = $x1;
+        $this->ix2 = $x2;
+        $this->iy1 = $y1;
+        $this->iy2 = $y2;
+    }
+
+    function SetPath($aPath) {
+        $this->iPathType = $aPath;
+    }
+
+    function SetColor($aColor) {
+        $this->iColor = $aColor;
+    }
+
+    function SetArrow($aSize,$aType=ARROWT_SOLID) {
+        $this->iArrowSize = $aSize;
+        $this->iArrowType = $aType;
+    }
+
+    function SetWeight($aWeight) {
+        $this->iWeight = $aWeight;
+    }
+
+    function Stroke($aImg) {
+        // The way the path for the arrow is constructed is partly based
+        // on some heuristics. This is not an exact science but draws the
+        // path in a way that, for me, makes esthetic sence. For example
+        // if the start and end activities are very close we make a small
+        // detour to endter the target horixontally. If there are more
+        // space between axctivities then no suh detour is made and the
+        // target is "hit" directly vertical. I have tried to keep this
+        // simple. no doubt this could become almost infinitive complex
+        // and have some real AI. Feel free to modify this.
+        // This will no-doubt be tweaked as times go by. One design aim
+        // is to avoid having the user choose what types of arrow
+        // he wants.
+
+        // The arrow is drawn between (x1,y1) to (x2,y2)
+        $x1 = $this->ix1 ;
+        $x2 = $this->ix2 ;
+        $y1 = $this->iy1 ;
+        $y2 = $this->iy2 ;
+
+        // Depending on if the target is below or above we have to
+        // handle thi different.
+        if( $y2 > $y1 ) {
+            $arrowtype = ARROW_DOWN;
+            $midy = round(($y2-$y1)/2+$y1);
+            if( $x2 > $x1 ) {
+                switch ( $this->iPathType  ) {
+                    case 0:
+                        $c = array($x1,$y1,$x1,$midy,$x2,$midy,$x2,$y2);
+                        break;
+                    case 1:
+                    case 2:
+                    case 3:
+                        $c = array($x1,$y1,$x2,$y1,$x2,$y2);
+                        break;
+                    default:
+                        JpGraphError::RaiseL(6032,$this->iPathType);
+                        //('Internal error: Unknown path type (='.$this->iPathType .') specified for link.');
+                        exit(1);
+                        break;
+                }
+            }
+            else {
+                switch ( $this->iPathType  ) {
+                    case 0:
+                    case 1:
+                        $c = array($x1,$y1,$x1,$midy,$x2,$midy,$x2,$y2);
+                        break;
+                    case 2:
+                        // Always extend out horizontally a bit from the first point
+                        // If we draw a link back in time (end to start) and the bars
+                        // are very close we also change the path so it comes in from
+                        // the left on the activity
+                        $c = array($x1,$y1,$x1+$this->iPathExtend,$y1,
+                        $x1+$this->iPathExtend,$midy,
+                        $x2,$midy,$x2,$y2);
+                        break;
+                    case 3:
+                        if( $y2-$midy < 6 ) {
+                            $c = array($x1,$y1,$x1,$midy,
+                            $x2-$this->iPathExtend,$midy,
+                            $x2-$this->iPathExtend,$y2,
+                            $x2,$y2);
+                            $arrowtype = ARROW_RIGHT;
+                        }
+                        else {
+                            $c = array($x1,$y1,$x1,$midy,$x2,$midy,$x2,$y2);
+                        }
+                        break;
+                    default:
+                        JpGraphError::RaiseL(6032,$this->iPathType);
+                        //('Internal error: Unknown path type specified for link.');
+                        exit(1);
+                        break;
+                }
+            }
+            $arrow = new LinkArrow($x2,$y2,$arrowtype);
+        }
+        else {
+            // Y2 < Y1
+            $arrowtype = ARROW_UP;
+            $midy = round(($y1-$y2)/2+$y2);
+            if( $x2 > $x1 ) {
+                switch ( $this->iPathType  ) {
+                    case 0:
+                    case 1:
+                        $c = array($x1,$y1,$x1,$midy,$x2,$midy,$x2,$y2);
+                        break;
+                    case 3:
+                        if( $midy-$y2 < 8 ) {
+                            $arrowtype = ARROW_RIGHT;
+                            $c = array($x1,$y1,$x1,$y2,$x2,$y2);
+                        }
+                        else {
+                            $c = array($x1,$y1,$x1,$midy,$x2,$midy,$x2,$y2);
+                        }
+                        break;
+                    default:
+                        JpGraphError::RaiseL(6032,$this->iPathType);
+                        //('Internal error: Unknown path type specified for link.');
+                        break;
+                }
+            }
+            else {
+                switch ( $this->iPathType  ) {
+                    case 0:
+                    case 1:
+                        $c = array($x1,$y1,$x1,$midy,$x2,$midy,$x2,$y2);
+                        break;
+                    case 2:
+                        // Always extend out horizontally a bit from the first point
+                        $c = array($x1,$y1,$x1+$this->iPathExtend,$y1,
+                        $x1+$this->iPathExtend,$midy,
+                        $x2,$midy,$x2,$y2);
+                        break;
+                    case 3:
+                        if( $midy-$y2 < 16 ) {
+                            $arrowtype = ARROW_RIGHT;
+                            $c = array($x1,$y1,$x1,$midy,$x2-$this->iPathExtend,$midy,
+                            $x2-$this->iPathExtend,$y2,
+                            $x2,$y2);
+                        }
+                        else {
+                            $c = array($x1,$y1,$x1,$midy,$x2,$midy,$x2,$y2);
+                        }
+                        break;
+                    default:
+                        JpGraphError::RaiseL(6032,$this->iPathType);
+                        //('Internal error: Unknown path type specified for link.');
+                        break;
+                }
+            }
+            $arrow = new LinkArrow($x2,$y2,$arrowtype);
+        }
+        $aImg->SetColor($this->iColor);
+        $aImg->SetLineWeight($this->iWeight);
+        $aImg->Polygon($c);
+        $aImg->SetLineWeight(1);
+        $arrow->SetColor($this->iColor);
+        $arrow->SetSize($this->iArrowSize);
+        $arrow->SetType($this->iArrowType);
+        $arrow->Stroke($aImg);
+    }
+}
+
+// <EOF>
+?>
diff --git a/web/classes/jpgraph/jpgraph_gb2312.php b/web/classes/jpgraph/jpgraph_gb2312.php
new file mode 100755
index 0000000000000000000000000000000000000000..eff07cbc57f0e90f5dba0e9e757b81be4ec020ad
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_gb2312.php
@@ -0,0 +1,1552 @@
+<?php
+//=======================================================================
+// File:        JPGRAPH_GB2312.PHP
+// Description: Chinese font conversions
+// Created:     2003-05-30
+// Ver:         $Id: jpgraph_gb2312.php 1106 2009-02-22 20:16:35Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+
+class GB2312toUTF8 {
+    // --------------------------------------------------------------------
+    // This code table is used to translate GB2312 code (key) to
+    // it's corresponding Unicode value (data)
+    // --------------------------------------------------------------------
+    private $codetable = array(
+    8481 => 12288, 8482 => 12289, 8483 => 12290, 8484 => 12539, 8485 => 713,
+    8486 => 711, 8487 => 168, 8488 => 12291, 8489 => 12293, 8490 => 8213,
+    8491 => 65374, 8492 => 8214, 8493 => 8230, 8494 => 8216, 8495 => 8217,
+    8496 => 8220, 8497 => 8221, 8498 => 12308, 8499 => 12309, 8500 => 12296,
+    8501 => 12297, 8502 => 12298, 8503 => 12299, 8504 => 12300, 8505 => 12301,
+    8506 => 12302, 8507 => 12303, 8508 => 12310, 8509 => 12311, 8510 => 12304,
+    8511 => 12305, 8512 => 177, 8513 => 215, 8514 => 247, 8515 => 8758,
+    8516 => 8743, 8517 => 8744, 8518 => 8721, 8519 => 8719, 8520 => 8746,
+    8521 => 8745, 8522 => 8712, 8523 => 8759, 8524 => 8730, 8525 => 8869,
+    8526 => 8741, 8527 => 8736, 8528 => 8978, 8529 => 8857, 8530 => 8747,
+    8531 => 8750, 8532 => 8801, 8533 => 8780, 8534 => 8776, 8535 => 8765,
+    8536 => 8733, 8537 => 8800, 8538 => 8814, 8539 => 8815, 8540 => 8804,
+    8541 => 8805, 8542 => 8734, 8543 => 8757, 8544 => 8756, 8545 => 9794,
+    8546 => 9792, 8547 => 176, 8548 => 8242, 8549 => 8243, 8550 => 8451,
+    8551 => 65284, 8552 => 164, 8553 => 65504, 8554 => 65505, 8555 => 8240,
+    8556 => 167, 8557 => 8470, 8558 => 9734, 8559 => 9733, 8560 => 9675,
+    8561 => 9679, 8562 => 9678, 8563 => 9671, 8564 => 9670, 8565 => 9633,
+    8566 => 9632, 8567 => 9651, 8568 => 9650, 8569 => 8251, 8570 => 8594,
+    8571 => 8592, 8572 => 8593, 8573 => 8595, 8574 => 12307, 8753 => 9352,
+    8754 => 9353, 8755 => 9354, 8756 => 9355, 8757 => 9356, 8758 => 9357,
+    8759 => 9358, 8760 => 9359, 8761 => 9360, 8762 => 9361, 8763 => 9362,
+    8764 => 9363, 8765 => 9364, 8766 => 9365, 8767 => 9366, 8768 => 9367,
+    8769 => 9368, 8770 => 9369, 8771 => 9370, 8772 => 9371, 8773 => 9332,
+    8774 => 9333, 8775 => 9334, 8776 => 9335, 8777 => 9336, 8778 => 9337,
+    8779 => 9338, 8780 => 9339, 8781 => 9340, 8782 => 9341, 8783 => 9342,
+    8784 => 9343, 8785 => 9344, 8786 => 9345, 8787 => 9346, 8788 => 9347,
+    8789 => 9348, 8790 => 9349, 8791 => 9350, 8792 => 9351, 8793 => 9312,
+    8794 => 9313, 8795 => 9314, 8796 => 9315, 8797 => 9316, 8798 => 9317,
+    8799 => 9318, 8800 => 9319, 8801 => 9320, 8802 => 9321, 8805 => 12832,
+    8806 => 12833, 8807 => 12834, 8808 => 12835, 8809 => 12836, 8810 => 12837,
+    8811 => 12838, 8812 => 12839, 8813 => 12840, 8814 => 12841, 8817 => 8544,
+    8818 => 8545, 8819 => 8546, 8820 => 8547, 8821 => 8548, 8822 => 8549,
+    8823 => 8550, 8824 => 8551, 8825 => 8552, 8826 => 8553, 8827 => 8554,
+    8828 => 8555, 8993 => 65281, 8994 => 65282, 8995 => 65283, 8996 => 65509,
+    8997 => 65285, 8998 => 65286, 8999 => 65287, 9000 => 65288, 9001 => 65289,
+    9002 => 65290, 9003 => 65291, 9004 => 65292, 9005 => 65293, 9006 => 65294,
+    9007 => 65295, 9008 => 65296, 9009 => 65297, 9010 => 65298, 9011 => 65299,
+    9012 => 65300, 9013 => 65301, 9014 => 65302, 9015 => 65303, 9016 => 65304,
+    9017 => 65305, 9018 => 65306, 9019 => 65307, 9020 => 65308, 9021 => 65309,
+    9022 => 65310, 9023 => 65311, 9024 => 65312, 9025 => 65313, 9026 => 65314,
+    9027 => 65315, 9028 => 65316, 9029 => 65317, 9030 => 65318, 9031 => 65319,
+    9032 => 65320, 9033 => 65321, 9034 => 65322, 9035 => 65323, 9036 => 65324,
+    9037 => 65325, 9038 => 65326, 9039 => 65327, 9040 => 65328, 9041 => 65329,
+    9042 => 65330, 9043 => 65331, 9044 => 65332, 9045 => 65333, 9046 => 65334,
+    9047 => 65335, 9048 => 65336, 9049 => 65337, 9050 => 65338, 9051 => 65339,
+    9052 => 65340, 9053 => 65341, 9054 => 65342, 9055 => 65343, 9056 => 65344,
+    9057 => 65345, 9058 => 65346, 9059 => 65347, 9060 => 65348, 9061 => 65349,
+    9062 => 65350, 9063 => 65351, 9064 => 65352, 9065 => 65353, 9066 => 65354,
+    9067 => 65355, 9068 => 65356, 9069 => 65357, 9070 => 65358, 9071 => 65359,
+    9072 => 65360, 9073 => 65361, 9074 => 65362, 9075 => 65363, 9076 => 65364,
+    9077 => 65365, 9078 => 65366, 9079 => 65367, 9080 => 65368, 9081 => 65369,
+    9082 => 65370, 9083 => 65371, 9084 => 65372, 9085 => 65373, 9086 => 65507,
+    9249 => 12353, 9250 => 12354, 9251 => 12355, 9252 => 12356, 9253 => 12357,
+    9254 => 12358, 9255 => 12359, 9256 => 12360, 9257 => 12361, 9258 => 12362,
+    9259 => 12363, 9260 => 12364, 9261 => 12365, 9262 => 12366, 9263 => 12367,
+    9264 => 12368, 9265 => 12369, 9266 => 12370, 9267 => 12371, 9268 => 12372,
+    9269 => 12373, 9270 => 12374, 9271 => 12375, 9272 => 12376, 9273 => 12377,
+    9274 => 12378, 9275 => 12379, 9276 => 12380, 9277 => 12381, 9278 => 12382,
+    9279 => 12383, 9280 => 12384, 9281 => 12385, 9282 => 12386, 9283 => 12387,
+    9284 => 12388, 9285 => 12389, 9286 => 12390, 9287 => 12391, 9288 => 12392,
+    9289 => 12393, 9290 => 12394, 9291 => 12395, 9292 => 12396, 9293 => 12397,
+    9294 => 12398, 9295 => 12399, 9296 => 12400, 9297 => 12401, 9298 => 12402,
+    9299 => 12403, 9300 => 12404, 9301 => 12405, 9302 => 12406, 9303 => 12407,
+    9304 => 12408, 9305 => 12409, 9306 => 12410, 9307 => 12411, 9308 => 12412,
+    9309 => 12413, 9310 => 12414, 9311 => 12415, 9312 => 12416, 9313 => 12417,
+    9314 => 12418, 9315 => 12419, 9316 => 12420, 9317 => 12421, 9318 => 12422,
+    9319 => 12423, 9320 => 12424, 9321 => 12425, 9322 => 12426, 9323 => 12427,
+    9324 => 12428, 9325 => 12429, 9326 => 12430, 9327 => 12431, 9328 => 12432,
+    9329 => 12433, 9330 => 12434, 9331 => 12435, 9505 => 12449, 9506 => 12450,
+    9507 => 12451, 9508 => 12452, 9509 => 12453, 9510 => 12454, 9511 => 12455,
+    9512 => 12456, 9513 => 12457, 9514 => 12458, 9515 => 12459, 9516 => 12460,
+    9517 => 12461, 9518 => 12462, 9519 => 12463, 9520 => 12464, 9521 => 12465,
+    9522 => 12466, 9523 => 12467, 9524 => 12468, 9525 => 12469, 9526 => 12470,
+    9527 => 12471, 9528 => 12472, 9529 => 12473, 9530 => 12474, 9531 => 12475,
+    9532 => 12476, 9533 => 12477, 9534 => 12478, 9535 => 12479, 9536 => 12480,
+    9537 => 12481, 9538 => 12482, 9539 => 12483, 9540 => 12484, 9541 => 12485,
+    9542 => 12486, 9543 => 12487, 9544 => 12488, 9545 => 12489, 9546 => 12490,
+    9547 => 12491, 9548 => 12492, 9549 => 12493, 9550 => 12494, 9551 => 12495,
+    9552 => 12496, 9553 => 12497, 9554 => 12498, 9555 => 12499, 9556 => 12500,
+    9557 => 12501, 9558 => 12502, 9559 => 12503, 9560 => 12504, 9561 => 12505,
+    9562 => 12506, 9563 => 12507, 9564 => 12508, 9565 => 12509, 9566 => 12510,
+    9567 => 12511, 9568 => 12512, 9569 => 12513, 9570 => 12514, 9571 => 12515,
+    9572 => 12516, 9573 => 12517, 9574 => 12518, 9575 => 12519, 9576 => 12520,
+    9577 => 12521, 9578 => 12522, 9579 => 12523, 9580 => 12524, 9581 => 12525,
+    9582 => 12526, 9583 => 12527, 9584 => 12528, 9585 => 12529, 9586 => 12530,
+    9587 => 12531, 9588 => 12532, 9589 => 12533, 9590 => 12534, 9761 => 913,
+    9762 => 914, 9763 => 915, 9764 => 916, 9765 => 917, 9766 => 918,
+    9767 => 919, 9768 => 920, 9769 => 921, 9770 => 922, 9771 => 923,
+    9772 => 924, 9773 => 925, 9774 => 926, 9775 => 927, 9776 => 928,
+    9777 => 929, 9778 => 931, 9779 => 932, 9780 => 933, 9781 => 934,
+    9782 => 935, 9783 => 936, 9784 => 937, 9793 => 945, 9794 => 946,
+    9795 => 947, 9796 => 948, 9797 => 949, 9798 => 950, 9799 => 951,
+    9800 => 952, 9801 => 953, 9802 => 954, 9803 => 955, 9804 => 956,
+    9805 => 957, 9806 => 958, 9807 => 959, 9808 => 960, 9809 => 961,
+    9810 => 963, 9811 => 964, 9812 => 965, 9813 => 966, 9814 => 967,
+    9815 => 968, 9816 => 969, 10017 => 1040, 10018 => 1041, 10019 => 1042,
+    10020 => 1043, 10021 => 1044, 10022 => 1045, 10023 => 1025, 10024 => 1046,
+    10025 => 1047, 10026 => 1048, 10027 => 1049, 10028 => 1050, 10029 => 1051,
+    10030 => 1052, 10031 => 1053, 10032 => 1054, 10033 => 1055, 10034 => 1056,
+    10035 => 1057, 10036 => 1058, 10037 => 1059, 10038 => 1060, 10039 => 1061,
+    10040 => 1062, 10041 => 1063, 10042 => 1064, 10043 => 1065, 10044 => 1066,
+    10045 => 1067, 10046 => 1068, 10047 => 1069, 10048 => 1070, 10049 => 1071,
+    10065 => 1072, 10066 => 1073, 10067 => 1074, 10068 => 1075, 10069 => 1076,
+    10070 => 1077, 10071 => 1105, 10072 => 1078, 10073 => 1079, 10074 => 1080,
+    10075 => 1081, 10076 => 1082, 10077 => 1083, 10078 => 1084, 10079 => 1085,
+    10080 => 1086, 10081 => 1087, 10082 => 1088, 10083 => 1089, 10084 => 1090,
+    10085 => 1091, 10086 => 1092, 10087 => 1093, 10088 => 1094, 10089 => 1095,
+    10090 => 1096, 10091 => 1097, 10092 => 1098, 10093 => 1099, 10094 => 1100,
+    10095 => 1101, 10096 => 1102, 10097 => 1103, 10273 => 257, 10274 => 225,
+    10275 => 462, 10276 => 224, 10277 => 275, 10278 => 233, 10279 => 283,
+    10280 => 232, 10281 => 299, 10282 => 237, 10283 => 464, 10284 => 236,
+    10285 => 333, 10286 => 243, 10287 => 466, 10288 => 242, 10289 => 363,
+    10290 => 250, 10291 => 468, 10292 => 249, 10293 => 470, 10294 => 472,
+    10295 => 474, 10296 => 476, 10297 => 252, 10298 => 234, 10309 => 12549,
+    10310 => 12550, 10311 => 12551, 10312 => 12552, 10313 => 12553, 10314 => 12554,
+    10315 => 12555, 10316 => 12556, 10317 => 12557, 10318 => 12558, 10319 => 12559,
+    10320 => 12560, 10321 => 12561, 10322 => 12562, 10323 => 12563, 10324 => 12564,
+    10325 => 12565, 10326 => 12566, 10327 => 12567, 10328 => 12568, 10329 => 12569,
+    10330 => 12570, 10331 => 12571, 10332 => 12572, 10333 => 12573, 10334 => 12574,
+    10335 => 12575, 10336 => 12576, 10337 => 12577, 10338 => 12578, 10339 => 12579,
+    10340 => 12580, 10341 => 12581, 10342 => 12582, 10343 => 12583, 10344 => 12584,
+    10345 => 12585, 10532 => 9472, 10533 => 9473, 10534 => 9474, 10535 => 9475,
+    10536 => 9476, 10537 => 9477, 10538 => 9478, 10539 => 9479, 10540 => 9480,
+    10541 => 9481, 10542 => 9482, 10543 => 9483, 10544 => 9484, 10545 => 9485,
+    10546 => 9486, 10547 => 9487, 10548 => 9488, 10549 => 9489, 10550 => 9490,
+    10551 => 9491, 10552 => 9492, 10553 => 9493, 10554 => 9494, 10555 => 9495,
+    10556 => 9496, 10557 => 9497, 10558 => 9498, 10559 => 9499, 10560 => 9500,
+    10561 => 9501, 10562 => 9502, 10563 => 9503, 10564 => 9504, 10565 => 9505,
+    10566 => 9506, 10567 => 9507, 10568 => 9508, 10569 => 9509, 10570 => 9510,
+    10571 => 9511, 10572 => 9512, 10573 => 9513, 10574 => 9514, 10575 => 9515,
+    10576 => 9516, 10577 => 9517, 10578 => 9518, 10579 => 9519, 10580 => 9520,
+    10581 => 9521, 10582 => 9522, 10583 => 9523, 10584 => 9524, 10585 => 9525,
+    10586 => 9526, 10587 => 9527, 10588 => 9528, 10589 => 9529, 10590 => 9530,
+    10591 => 9531, 10592 => 9532, 10593 => 9533, 10594 => 9534, 10595 => 9535,
+    10596 => 9536, 10597 => 9537, 10598 => 9538, 10599 => 9539, 10600 => 9540,
+    10601 => 9541, 10602 => 9542, 10603 => 9543, 10604 => 9544, 10605 => 9545,
+    10606 => 9546, 10607 => 9547, 12321 => 21834, 12322 => 38463, 12323 => 22467,
+    12324 => 25384, 12325 => 21710, 12326 => 21769, 12327 => 21696, 12328 => 30353,
+    12329 => 30284, 12330 => 34108, 12331 => 30702, 12332 => 33406, 12333 => 30861,
+    12334 => 29233, 12335 => 38552, 12336 => 38797, 12337 => 27688, 12338 => 23433,
+    12339 => 20474, 12340 => 25353, 12341 => 26263, 12342 => 23736, 12343 => 33018,
+    12344 => 26696, 12345 => 32942, 12346 => 26114, 12347 => 30414, 12348 => 20985,
+    12349 => 25942, 12350 => 29100, 12351 => 32753, 12352 => 34948, 12353 => 20658,
+    12354 => 22885, 12355 => 25034, 12356 => 28595, 12357 => 33453, 12358 => 25420,
+    12359 => 25170, 12360 => 21485, 12361 => 21543, 12362 => 31494, 12363 => 20843,
+    12364 => 30116, 12365 => 24052, 12366 => 25300, 12367 => 36299, 12368 => 38774,
+    12369 => 25226, 12370 => 32793, 12371 => 22365, 12372 => 38712, 12373 => 32610,
+    12374 => 29240, 12375 => 30333, 12376 => 26575, 12377 => 30334, 12378 => 25670,
+    12379 => 20336, 12380 => 36133, 12381 => 25308, 12382 => 31255, 12383 => 26001,
+    12384 => 29677, 12385 => 25644, 12386 => 25203, 12387 => 33324, 12388 => 39041,
+    12389 => 26495, 12390 => 29256, 12391 => 25198, 12392 => 25292, 12393 => 20276,
+    12394 => 29923, 12395 => 21322, 12396 => 21150, 12397 => 32458, 12398 => 37030,
+    12399 => 24110, 12400 => 26758, 12401 => 27036, 12402 => 33152, 12403 => 32465,
+    12404 => 26834, 12405 => 30917, 12406 => 34444, 12407 => 38225, 12408 => 20621,
+    12409 => 35876, 12410 => 33502, 12411 => 32990, 12412 => 21253, 12413 => 35090,
+    12414 => 21093, 12577 => 34180, 12578 => 38649, 12579 => 20445, 12580 => 22561,
+    12581 => 39281, 12582 => 23453, 12583 => 25265, 12584 => 25253, 12585 => 26292,
+    12586 => 35961, 12587 => 40077, 12588 => 29190, 12589 => 26479, 12590 => 30865,
+    12591 => 24754, 12592 => 21329, 12593 => 21271, 12594 => 36744, 12595 => 32972,
+    12596 => 36125, 12597 => 38049, 12598 => 20493, 12599 => 29384, 12600 => 22791,
+    12601 => 24811, 12602 => 28953, 12603 => 34987, 12604 => 22868, 12605 => 33519,
+    12606 => 26412, 12607 => 31528, 12608 => 23849, 12609 => 32503, 12610 => 29997,
+    12611 => 27893, 12612 => 36454, 12613 => 36856, 12614 => 36924, 12615 => 40763,
+    12616 => 27604, 12617 => 37145, 12618 => 31508, 12619 => 24444, 12620 => 30887,
+    12621 => 34006, 12622 => 34109, 12623 => 27605, 12624 => 27609, 12625 => 27606,
+    12626 => 24065, 12627 => 24199, 12628 => 30201, 12629 => 38381, 12630 => 25949,
+    12631 => 24330, 12632 => 24517, 12633 => 36767, 12634 => 22721, 12635 => 33218,
+    12636 => 36991, 12637 => 38491, 12638 => 38829, 12639 => 36793, 12640 => 32534,
+    12641 => 36140, 12642 => 25153, 12643 => 20415, 12644 => 21464, 12645 => 21342,
+    12646 => 36776, 12647 => 36777, 12648 => 36779, 12649 => 36941, 12650 => 26631,
+    12651 => 24426, 12652 => 33176, 12653 => 34920, 12654 => 40150, 12655 => 24971,
+    12656 => 21035, 12657 => 30250, 12658 => 24428, 12659 => 25996, 12660 => 28626,
+    12661 => 28392, 12662 => 23486, 12663 => 25672, 12664 => 20853, 12665 => 20912,
+    12666 => 26564, 12667 => 19993, 12668 => 31177, 12669 => 39292, 12670 => 28851,
+    12833 => 30149, 12834 => 24182, 12835 => 29627, 12836 => 33760, 12837 => 25773,
+    12838 => 25320, 12839 => 38069, 12840 => 27874, 12841 => 21338, 12842 => 21187,
+    12843 => 25615, 12844 => 38082, 12845 => 31636, 12846 => 20271, 12847 => 24091,
+    12848 => 33334, 12849 => 33046, 12850 => 33162, 12851 => 28196, 12852 => 27850,
+    12853 => 39539, 12854 => 25429, 12855 => 21340, 12856 => 21754, 12857 => 34917,
+    12858 => 22496, 12859 => 19981, 12860 => 24067, 12861 => 27493, 12862 => 31807,
+    12863 => 37096, 12864 => 24598, 12865 => 25830, 12866 => 29468, 12867 => 35009,
+    12868 => 26448, 12869 => 25165, 12870 => 36130, 12871 => 30572, 12872 => 36393,
+    12873 => 37319, 12874 => 24425, 12875 => 33756, 12876 => 34081, 12877 => 39184,
+    12878 => 21442, 12879 => 34453, 12880 => 27531, 12881 => 24813, 12882 => 24808,
+    12883 => 28799, 12884 => 33485, 12885 => 33329, 12886 => 20179, 12887 => 27815,
+    12888 => 34255, 12889 => 25805, 12890 => 31961, 12891 => 27133, 12892 => 26361,
+    12893 => 33609, 12894 => 21397, 12895 => 31574, 12896 => 20391, 12897 => 20876,
+    12898 => 27979, 12899 => 23618, 12900 => 36461, 12901 => 25554, 12902 => 21449,
+    12903 => 33580, 12904 => 33590, 12905 => 26597, 12906 => 30900, 12907 => 25661,
+    12908 => 23519, 12909 => 23700, 12910 => 24046, 12911 => 35815, 12912 => 25286,
+    12913 => 26612, 12914 => 35962, 12915 => 25600, 12916 => 25530, 12917 => 34633,
+    12918 => 39307, 12919 => 35863, 12920 => 32544, 12921 => 38130, 12922 => 20135,
+    12923 => 38416, 12924 => 39076, 12925 => 26124, 12926 => 29462, 13089 => 22330,
+    13090 => 23581, 13091 => 24120, 13092 => 38271, 13093 => 20607, 13094 => 32928,
+    13095 => 21378, 13096 => 25950, 13097 => 30021, 13098 => 21809, 13099 => 20513,
+    13100 => 36229, 13101 => 25220, 13102 => 38046, 13103 => 26397, 13104 => 22066,
+    13105 => 28526, 13106 => 24034, 13107 => 21557, 13108 => 28818, 13109 => 36710,
+    13110 => 25199, 13111 => 25764, 13112 => 25507, 13113 => 24443, 13114 => 28552,
+    13115 => 37108, 13116 => 33251, 13117 => 36784, 13118 => 23576, 13119 => 26216,
+    13120 => 24561, 13121 => 27785, 13122 => 38472, 13123 => 36225, 13124 => 34924,
+    13125 => 25745, 13126 => 31216, 13127 => 22478, 13128 => 27225, 13129 => 25104,
+    13130 => 21576, 13131 => 20056, 13132 => 31243, 13133 => 24809, 13134 => 28548,
+    13135 => 35802, 13136 => 25215, 13137 => 36894, 13138 => 39563, 13139 => 31204,
+    13140 => 21507, 13141 => 30196, 13142 => 25345, 13143 => 21273, 13144 => 27744,
+    13145 => 36831, 13146 => 24347, 13147 => 39536, 13148 => 32827, 13149 => 40831,
+    13150 => 20360, 13151 => 23610, 13152 => 36196, 13153 => 32709, 13154 => 26021,
+    13155 => 28861, 13156 => 20805, 13157 => 20914, 13158 => 34411, 13159 => 23815,
+    13160 => 23456, 13161 => 25277, 13162 => 37228, 13163 => 30068, 13164 => 36364,
+    13165 => 31264, 13166 => 24833, 13167 => 31609, 13168 => 20167, 13169 => 32504,
+    13170 => 30597, 13171 => 19985, 13172 => 33261, 13173 => 21021, 13174 => 20986,
+    13175 => 27249, 13176 => 21416, 13177 => 36487, 13178 => 38148, 13179 => 38607,
+    13180 => 28353, 13181 => 38500, 13182 => 26970, 13345 => 30784, 13346 => 20648,
+    13347 => 30679, 13348 => 25616, 13349 => 35302, 13350 => 22788, 13351 => 25571,
+    13352 => 24029, 13353 => 31359, 13354 => 26941, 13355 => 20256, 13356 => 33337,
+    13357 => 21912, 13358 => 20018, 13359 => 30126, 13360 => 31383, 13361 => 24162,
+    13362 => 24202, 13363 => 38383, 13364 => 21019, 13365 => 21561, 13366 => 28810,
+    13367 => 25462, 13368 => 38180, 13369 => 22402, 13370 => 26149, 13371 => 26943,
+    13372 => 37255, 13373 => 21767, 13374 => 28147, 13375 => 32431, 13376 => 34850,
+    13377 => 25139, 13378 => 32496, 13379 => 30133, 13380 => 33576, 13381 => 30913,
+    13382 => 38604, 13383 => 36766, 13384 => 24904, 13385 => 29943, 13386 => 35789,
+    13387 => 27492, 13388 => 21050, 13389 => 36176, 13390 => 27425, 13391 => 32874,
+    13392 => 33905, 13393 => 22257, 13394 => 21254, 13395 => 20174, 13396 => 19995,
+    13397 => 20945, 13398 => 31895, 13399 => 37259, 13400 => 31751, 13401 => 20419,
+    13402 => 36479, 13403 => 31713, 13404 => 31388, 13405 => 25703, 13406 => 23828,
+    13407 => 20652, 13408 => 33030, 13409 => 30209, 13410 => 31929, 13411 => 28140,
+    13412 => 32736, 13413 => 26449, 13414 => 23384, 13415 => 23544, 13416 => 30923,
+    13417 => 25774, 13418 => 25619, 13419 => 25514, 13420 => 25387, 13421 => 38169,
+    13422 => 25645, 13423 => 36798, 13424 => 31572, 13425 => 30249, 13426 => 25171,
+    13427 => 22823, 13428 => 21574, 13429 => 27513, 13430 => 20643, 13431 => 25140,
+    13432 => 24102, 13433 => 27526, 13434 => 20195, 13435 => 36151, 13436 => 34955,
+    13437 => 24453, 13438 => 36910, 13601 => 24608, 13602 => 32829, 13603 => 25285,
+    13604 => 20025, 13605 => 21333, 13606 => 37112, 13607 => 25528, 13608 => 32966,
+    13609 => 26086, 13610 => 27694, 13611 => 20294, 13612 => 24814, 13613 => 28129,
+    13614 => 35806, 13615 => 24377, 13616 => 34507, 13617 => 24403, 13618 => 25377,
+    13619 => 20826, 13620 => 33633, 13621 => 26723, 13622 => 20992, 13623 => 25443,
+    13624 => 36424, 13625 => 20498, 13626 => 23707, 13627 => 31095, 13628 => 23548,
+    13629 => 21040, 13630 => 31291, 13631 => 24764, 13632 => 36947, 13633 => 30423,
+    13634 => 24503, 13635 => 24471, 13636 => 30340, 13637 => 36460, 13638 => 28783,
+    13639 => 30331, 13640 => 31561, 13641 => 30634, 13642 => 20979, 13643 => 37011,
+    13644 => 22564, 13645 => 20302, 13646 => 28404, 13647 => 36842, 13648 => 25932,
+    13649 => 31515, 13650 => 29380, 13651 => 28068, 13652 => 32735, 13653 => 23265,
+    13654 => 25269, 13655 => 24213, 13656 => 22320, 13657 => 33922, 13658 => 31532,
+    13659 => 24093, 13660 => 24351, 13661 => 36882, 13662 => 32532, 13663 => 39072,
+    13664 => 25474, 13665 => 28359, 13666 => 30872, 13667 => 28857, 13668 => 20856,
+    13669 => 38747, 13670 => 22443, 13671 => 30005, 13672 => 20291, 13673 => 30008,
+    13674 => 24215, 13675 => 24806, 13676 => 22880, 13677 => 28096, 13678 => 27583,
+    13679 => 30857, 13680 => 21500, 13681 => 38613, 13682 => 20939, 13683 => 20993,
+    13684 => 25481, 13685 => 21514, 13686 => 38035, 13687 => 35843, 13688 => 36300,
+    13689 => 29241, 13690 => 30879, 13691 => 34678, 13692 => 36845, 13693 => 35853,
+    13694 => 21472, 13857 => 19969, 13858 => 30447, 13859 => 21486, 13860 => 38025,
+    13861 => 39030, 13862 => 40718, 13863 => 38189, 13864 => 23450, 13865 => 35746,
+    13866 => 20002, 13867 => 19996, 13868 => 20908, 13869 => 33891, 13870 => 25026,
+    13871 => 21160, 13872 => 26635, 13873 => 20375, 13874 => 24683, 13875 => 20923,
+    13876 => 27934, 13877 => 20828, 13878 => 25238, 13879 => 26007, 13880 => 38497,
+    13881 => 35910, 13882 => 36887, 13883 => 30168, 13884 => 37117, 13885 => 30563,
+    13886 => 27602, 13887 => 29322, 13888 => 29420, 13889 => 35835, 13890 => 22581,
+    13891 => 30585, 13892 => 36172, 13893 => 26460, 13894 => 38208, 13895 => 32922,
+    13896 => 24230, 13897 => 28193, 13898 => 22930, 13899 => 31471, 13900 => 30701,
+    13901 => 38203, 13902 => 27573, 13903 => 26029, 13904 => 32526, 13905 => 22534,
+    13906 => 20817, 13907 => 38431, 13908 => 23545, 13909 => 22697, 13910 => 21544,
+    13911 => 36466, 13912 => 25958, 13913 => 39039, 13914 => 22244, 13915 => 38045,
+    13916 => 30462, 13917 => 36929, 13918 => 25479, 13919 => 21702, 13920 => 22810,
+    13921 => 22842, 13922 => 22427, 13923 => 36530, 13924 => 26421, 13925 => 36346,
+    13926 => 33333, 13927 => 21057, 13928 => 24816, 13929 => 22549, 13930 => 34558,
+    13931 => 23784, 13932 => 40517, 13933 => 20420, 13934 => 39069, 13935 => 35769,
+    13936 => 23077, 13937 => 24694, 13938 => 21380, 13939 => 25212, 13940 => 36943,
+    13941 => 37122, 13942 => 39295, 13943 => 24681, 13944 => 32780, 13945 => 20799,
+    13946 => 32819, 13947 => 23572, 13948 => 39285, 13949 => 27953, 13950 => 20108,
+    14113 => 36144, 14114 => 21457, 14115 => 32602, 14116 => 31567, 14117 => 20240,
+    14118 => 20047, 14119 => 38400, 14120 => 27861, 14121 => 29648, 14122 => 34281,
+    14123 => 24070, 14124 => 30058, 14125 => 32763, 14126 => 27146, 14127 => 30718,
+    14128 => 38034, 14129 => 32321, 14130 => 20961, 14131 => 28902, 14132 => 21453,
+    14133 => 36820, 14134 => 33539, 14135 => 36137, 14136 => 29359, 14137 => 39277,
+    14138 => 27867, 14139 => 22346, 14140 => 33459, 14141 => 26041, 14142 => 32938,
+    14143 => 25151, 14144 => 38450, 14145 => 22952, 14146 => 20223, 14147 => 35775,
+    14148 => 32442, 14149 => 25918, 14150 => 33778, 14151 => 38750, 14152 => 21857,
+    14153 => 39134, 14154 => 32933, 14155 => 21290, 14156 => 35837, 14157 => 21536,
+    14158 => 32954, 14159 => 24223, 14160 => 27832, 14161 => 36153, 14162 => 33452,
+    14163 => 37210, 14164 => 21545, 14165 => 27675, 14166 => 20998, 14167 => 32439,
+    14168 => 22367, 14169 => 28954, 14170 => 27774, 14171 => 31881, 14172 => 22859,
+    14173 => 20221, 14174 => 24575, 14175 => 24868, 14176 => 31914, 14177 => 20016,
+    14178 => 23553, 14179 => 26539, 14180 => 34562, 14181 => 23792, 14182 => 38155,
+    14183 => 39118, 14184 => 30127, 14185 => 28925, 14186 => 36898, 14187 => 20911,
+    14188 => 32541, 14189 => 35773, 14190 => 22857, 14191 => 20964, 14192 => 20315,
+    14193 => 21542, 14194 => 22827, 14195 => 25975, 14196 => 32932, 14197 => 23413,
+    14198 => 25206, 14199 => 25282, 14200 => 36752, 14201 => 24133, 14202 => 27679,
+    14203 => 31526, 14204 => 20239, 14205 => 20440, 14206 => 26381, 14369 => 28014,
+    14370 => 28074, 14371 => 31119, 14372 => 34993, 14373 => 24343, 14374 => 29995,
+    14375 => 25242, 14376 => 36741, 14377 => 20463, 14378 => 37340, 14379 => 26023,
+    14380 => 33071, 14381 => 33105, 14382 => 24220, 14383 => 33104, 14384 => 36212,
+    14385 => 21103, 14386 => 35206, 14387 => 36171, 14388 => 22797, 14389 => 20613,
+    14390 => 20184, 14391 => 38428, 14392 => 29238, 14393 => 33145, 14394 => 36127,
+    14395 => 23500, 14396 => 35747, 14397 => 38468, 14398 => 22919, 14399 => 32538,
+    14400 => 21648, 14401 => 22134, 14402 => 22030, 14403 => 35813, 14404 => 25913,
+    14405 => 27010, 14406 => 38041, 14407 => 30422, 14408 => 28297, 14409 => 24178,
+    14410 => 29976, 14411 => 26438, 14412 => 26577, 14413 => 31487, 14414 => 32925,
+    14415 => 36214, 14416 => 24863, 14417 => 31174, 14418 => 25954, 14419 => 36195,
+    14420 => 20872, 14421 => 21018, 14422 => 38050, 14423 => 32568, 14424 => 32923,
+    14425 => 32434, 14426 => 23703, 14427 => 28207, 14428 => 26464, 14429 => 31705,
+    14430 => 30347, 14431 => 39640, 14432 => 33167, 14433 => 32660, 14434 => 31957,
+    14435 => 25630, 14436 => 38224, 14437 => 31295, 14438 => 21578, 14439 => 21733,
+    14440 => 27468, 14441 => 25601, 14442 => 25096, 14443 => 40509, 14444 => 33011,
+    14445 => 30105, 14446 => 21106, 14447 => 38761, 14448 => 33883, 14449 => 26684,
+    14450 => 34532, 14451 => 38401, 14452 => 38548, 14453 => 38124, 14454 => 20010,
+    14455 => 21508, 14456 => 32473, 14457 => 26681, 14458 => 36319, 14459 => 32789,
+    14460 => 26356, 14461 => 24218, 14462 => 32697, 14625 => 22466, 14626 => 32831,
+    14627 => 26775, 14628 => 24037, 14629 => 25915, 14630 => 21151, 14631 => 24685,
+    14632 => 40858, 14633 => 20379, 14634 => 36524, 14635 => 20844, 14636 => 23467,
+    14637 => 24339, 14638 => 24041, 14639 => 27742, 14640 => 25329, 14641 => 36129,
+    14642 => 20849, 14643 => 38057, 14644 => 21246, 14645 => 27807, 14646 => 33503,
+    14647 => 29399, 14648 => 22434, 14649 => 26500, 14650 => 36141, 14651 => 22815,
+    14652 => 36764, 14653 => 33735, 14654 => 21653, 14655 => 31629, 14656 => 20272,
+    14657 => 27837, 14658 => 23396, 14659 => 22993, 14660 => 40723, 14661 => 21476,
+    14662 => 34506, 14663 => 39592, 14664 => 35895, 14665 => 32929, 14666 => 25925,
+    14667 => 39038, 14668 => 22266, 14669 => 38599, 14670 => 21038, 14671 => 29916,
+    14672 => 21072, 14673 => 23521, 14674 => 25346, 14675 => 35074, 14676 => 20054,
+    14677 => 25296, 14678 => 24618, 14679 => 26874, 14680 => 20851, 14681 => 23448,
+    14682 => 20896, 14683 => 35266, 14684 => 31649, 14685 => 39302, 14686 => 32592,
+    14687 => 24815, 14688 => 28748, 14689 => 36143, 14690 => 20809, 14691 => 24191,
+    14692 => 36891, 14693 => 29808, 14694 => 35268, 14695 => 22317, 14696 => 30789,
+    14697 => 24402, 14698 => 40863, 14699 => 38394, 14700 => 36712, 14701 => 39740,
+    14702 => 35809, 14703 => 30328, 14704 => 26690, 14705 => 26588, 14706 => 36330,
+    14707 => 36149, 14708 => 21053, 14709 => 36746, 14710 => 28378, 14711 => 26829,
+    14712 => 38149, 14713 => 37101, 14714 => 22269, 14715 => 26524, 14716 => 35065,
+    14717 => 36807, 14718 => 21704, 14881 => 39608, 14882 => 23401, 14883 => 28023,
+    14884 => 27686, 14885 => 20133, 14886 => 23475, 14887 => 39559, 14888 => 37219,
+    14889 => 25000, 14890 => 37039, 14891 => 38889, 14892 => 21547, 14893 => 28085,
+    14894 => 23506, 14895 => 20989, 14896 => 21898, 14897 => 32597, 14898 => 32752,
+    14899 => 25788, 14900 => 25421, 14901 => 26097, 14902 => 25022, 14903 => 24717,
+    14904 => 28938, 14905 => 27735, 14906 => 27721, 14907 => 22831, 14908 => 26477,
+    14909 => 33322, 14910 => 22741, 14911 => 22158, 14912 => 35946, 14913 => 27627,
+    14914 => 37085, 14915 => 22909, 14916 => 32791, 14917 => 21495, 14918 => 28009,
+    14919 => 21621, 14920 => 21917, 14921 => 33655, 14922 => 33743, 14923 => 26680,
+    14924 => 31166, 14925 => 21644, 14926 => 20309, 14927 => 21512, 14928 => 30418,
+    14929 => 35977, 14930 => 38402, 14931 => 27827, 14932 => 28088, 14933 => 36203,
+    14934 => 35088, 14935 => 40548, 14936 => 36154, 14937 => 22079, 14938 => 40657,
+    14939 => 30165, 14940 => 24456, 14941 => 29408, 14942 => 24680, 14943 => 21756,
+    14944 => 20136, 14945 => 27178, 14946 => 34913, 14947 => 24658, 14948 => 36720,
+    14949 => 21700, 14950 => 28888, 14951 => 34425, 14952 => 40511, 14953 => 27946,
+    14954 => 23439, 14955 => 24344, 14956 => 32418, 14957 => 21897, 14958 => 20399,
+    14959 => 29492, 14960 => 21564, 14961 => 21402, 14962 => 20505, 14963 => 21518,
+    14964 => 21628, 14965 => 20046, 14966 => 24573, 14967 => 29786, 14968 => 22774,
+    14969 => 33899, 14970 => 32993, 14971 => 34676, 14972 => 29392, 14973 => 31946,
+    14974 => 28246, 15137 => 24359, 15138 => 34382, 15139 => 21804, 15140 => 25252,
+    15141 => 20114, 15142 => 27818, 15143 => 25143, 15144 => 33457, 15145 => 21719,
+    15146 => 21326, 15147 => 29502, 15148 => 28369, 15149 => 30011, 15150 => 21010,
+    15151 => 21270, 15152 => 35805, 15153 => 27088, 15154 => 24458, 15155 => 24576,
+    15156 => 28142, 15157 => 22351, 15158 => 27426, 15159 => 29615, 15160 => 26707,
+    15161 => 36824, 15162 => 32531, 15163 => 25442, 15164 => 24739, 15165 => 21796,
+    15166 => 30186, 15167 => 35938, 15168 => 28949, 15169 => 28067, 15170 => 23462,
+    15171 => 24187, 15172 => 33618, 15173 => 24908, 15174 => 40644, 15175 => 30970,
+    15176 => 34647, 15177 => 31783, 15178 => 30343, 15179 => 20976, 15180 => 24822,
+    15181 => 29004, 15182 => 26179, 15183 => 24140, 15184 => 24653, 15185 => 35854,
+    15186 => 28784, 15187 => 25381, 15188 => 36745, 15189 => 24509, 15190 => 24674,
+    15191 => 34516, 15192 => 22238, 15193 => 27585, 15194 => 24724, 15195 => 24935,
+    15196 => 21321, 15197 => 24800, 15198 => 26214, 15199 => 36159, 15200 => 31229,
+    15201 => 20250, 15202 => 28905, 15203 => 27719, 15204 => 35763, 15205 => 35826,
+    15206 => 32472, 15207 => 33636, 15208 => 26127, 15209 => 23130, 15210 => 39746,
+    15211 => 27985, 15212 => 28151, 15213 => 35905, 15214 => 27963, 15215 => 20249,
+    15216 => 28779, 15217 => 33719, 15218 => 25110, 15219 => 24785, 15220 => 38669,
+    15221 => 36135, 15222 => 31096, 15223 => 20987, 15224 => 22334, 15225 => 22522,
+    15226 => 26426, 15227 => 30072, 15228 => 31293, 15229 => 31215, 15230 => 31637,
+    15393 => 32908, 15394 => 39269, 15395 => 36857, 15396 => 28608, 15397 => 35749,
+    15398 => 40481, 15399 => 23020, 15400 => 32489, 15401 => 32521, 15402 => 21513,
+    15403 => 26497, 15404 => 26840, 15405 => 36753, 15406 => 31821, 15407 => 38598,
+    15408 => 21450, 15409 => 24613, 15410 => 30142, 15411 => 27762, 15412 => 21363,
+    15413 => 23241, 15414 => 32423, 15415 => 25380, 15416 => 20960, 15417 => 33034,
+    15418 => 24049, 15419 => 34015, 15420 => 25216, 15421 => 20864, 15422 => 23395,
+    15423 => 20238, 15424 => 31085, 15425 => 21058, 15426 => 24760, 15427 => 27982,
+    15428 => 23492, 15429 => 23490, 15430 => 35745, 15431 => 35760, 15432 => 26082,
+    15433 => 24524, 15434 => 38469, 15435 => 22931, 15436 => 32487, 15437 => 32426,
+    15438 => 22025, 15439 => 26551, 15440 => 22841, 15441 => 20339, 15442 => 23478,
+    15443 => 21152, 15444 => 33626, 15445 => 39050, 15446 => 36158, 15447 => 30002,
+    15448 => 38078, 15449 => 20551, 15450 => 31292, 15451 => 20215, 15452 => 26550,
+    15453 => 39550, 15454 => 23233, 15455 => 27516, 15456 => 30417, 15457 => 22362,
+    15458 => 23574, 15459 => 31546, 15460 => 38388, 15461 => 29006, 15462 => 20860,
+    15463 => 32937, 15464 => 33392, 15465 => 22904, 15466 => 32516, 15467 => 33575,
+    15468 => 26816, 15469 => 26604, 15470 => 30897, 15471 => 30839, 15472 => 25315,
+    15473 => 25441, 15474 => 31616, 15475 => 20461, 15476 => 21098, 15477 => 20943,
+    15478 => 33616, 15479 => 27099, 15480 => 37492, 15481 => 36341, 15482 => 36145,
+    15483 => 35265, 15484 => 38190, 15485 => 31661, 15486 => 20214, 15649 => 20581,
+    15650 => 33328, 15651 => 21073, 15652 => 39279, 15653 => 28176, 15654 => 28293,
+    15655 => 28071, 15656 => 24314, 15657 => 20725, 15658 => 23004, 15659 => 23558,
+    15660 => 27974, 15661 => 27743, 15662 => 30086, 15663 => 33931, 15664 => 26728,
+    15665 => 22870, 15666 => 35762, 15667 => 21280, 15668 => 37233, 15669 => 38477,
+    15670 => 34121, 15671 => 26898, 15672 => 30977, 15673 => 28966, 15674 => 33014,
+    15675 => 20132, 15676 => 37066, 15677 => 27975, 15678 => 39556, 15679 => 23047,
+    15680 => 22204, 15681 => 25605, 15682 => 38128, 15683 => 30699, 15684 => 20389,
+    15685 => 33050, 15686 => 29409, 15687 => 35282, 15688 => 39290, 15689 => 32564,
+    15690 => 32478, 15691 => 21119, 15692 => 25945, 15693 => 37237, 15694 => 36735,
+    15695 => 36739, 15696 => 21483, 15697 => 31382, 15698 => 25581, 15699 => 25509,
+    15700 => 30342, 15701 => 31224, 15702 => 34903, 15703 => 38454, 15704 => 25130,
+    15705 => 21163, 15706 => 33410, 15707 => 26708, 15708 => 26480, 15709 => 25463,
+    15710 => 30571, 15711 => 31469, 15712 => 27905, 15713 => 32467, 15714 => 35299,
+    15715 => 22992, 15716 => 25106, 15717 => 34249, 15718 => 33445, 15719 => 30028,
+    15720 => 20511, 15721 => 20171, 15722 => 30117, 15723 => 35819, 15724 => 23626,
+    15725 => 24062, 15726 => 31563, 15727 => 26020, 15728 => 37329, 15729 => 20170,
+    15730 => 27941, 15731 => 35167, 15732 => 32039, 15733 => 38182, 15734 => 20165,
+    15735 => 35880, 15736 => 36827, 15737 => 38771, 15738 => 26187, 15739 => 31105,
+    15740 => 36817, 15741 => 28908, 15742 => 28024, 15905 => 23613, 15906 => 21170,
+    15907 => 33606, 15908 => 20834, 15909 => 33550, 15910 => 30555, 15911 => 26230,
+    15912 => 40120, 15913 => 20140, 15914 => 24778, 15915 => 31934, 15916 => 31923,
+    15917 => 32463, 15918 => 20117, 15919 => 35686, 15920 => 26223, 15921 => 39048,
+    15922 => 38745, 15923 => 22659, 15924 => 25964, 15925 => 38236, 15926 => 24452,
+    15927 => 30153, 15928 => 38742, 15929 => 31455, 15930 => 31454, 15931 => 20928,
+    15932 => 28847, 15933 => 31384, 15934 => 25578, 15935 => 31350, 15936 => 32416,
+    15937 => 29590, 15938 => 38893, 15939 => 20037, 15940 => 28792, 15941 => 20061,
+    15942 => 37202, 15943 => 21417, 15944 => 25937, 15945 => 26087, 15946 => 33276,
+    15947 => 33285, 15948 => 21646, 15949 => 23601, 15950 => 30106, 15951 => 38816,
+    15952 => 25304, 15953 => 29401, 15954 => 30141, 15955 => 23621, 15956 => 39545,
+    15957 => 33738, 15958 => 23616, 15959 => 21632, 15960 => 30697, 15961 => 20030,
+    15962 => 27822, 15963 => 32858, 15964 => 25298, 15965 => 25454, 15966 => 24040,
+    15967 => 20855, 15968 => 36317, 15969 => 36382, 15970 => 38191, 15971 => 20465,
+    15972 => 21477, 15973 => 24807, 15974 => 28844, 15975 => 21095, 15976 => 25424,
+    15977 => 40515, 15978 => 23071, 15979 => 20518, 15980 => 30519, 15981 => 21367,
+    15982 => 32482, 15983 => 25733, 15984 => 25899, 15985 => 25225, 15986 => 25496,
+    15987 => 20500, 15988 => 29237, 15989 => 35273, 15990 => 20915, 15991 => 35776,
+    15992 => 32477, 15993 => 22343, 15994 => 33740, 15995 => 38055, 15996 => 20891,
+    15997 => 21531, 15998 => 23803, 16161 => 20426, 16162 => 31459, 16163 => 27994,
+    16164 => 37089, 16165 => 39567, 16166 => 21888, 16167 => 21654, 16168 => 21345,
+    16169 => 21679, 16170 => 24320, 16171 => 25577, 16172 => 26999, 16173 => 20975,
+    16174 => 24936, 16175 => 21002, 16176 => 22570, 16177 => 21208, 16178 => 22350,
+    16179 => 30733, 16180 => 30475, 16181 => 24247, 16182 => 24951, 16183 => 31968,
+    16184 => 25179, 16185 => 25239, 16186 => 20130, 16187 => 28821, 16188 => 32771,
+    16189 => 25335, 16190 => 28900, 16191 => 38752, 16192 => 22391, 16193 => 33499,
+    16194 => 26607, 16195 => 26869, 16196 => 30933, 16197 => 39063, 16198 => 31185,
+    16199 => 22771, 16200 => 21683, 16201 => 21487, 16202 => 28212, 16203 => 20811,
+    16204 => 21051, 16205 => 23458, 16206 => 35838, 16207 => 32943, 16208 => 21827,
+    16209 => 22438, 16210 => 24691, 16211 => 22353, 16212 => 21549, 16213 => 31354,
+    16214 => 24656, 16215 => 23380, 16216 => 25511, 16217 => 25248, 16218 => 21475,
+    16219 => 25187, 16220 => 23495, 16221 => 26543, 16222 => 21741, 16223 => 31391,
+    16224 => 33510, 16225 => 37239, 16226 => 24211, 16227 => 35044, 16228 => 22840,
+    16229 => 22446, 16230 => 25358, 16231 => 36328, 16232 => 33007, 16233 => 22359,
+    16234 => 31607, 16235 => 20393, 16236 => 24555, 16237 => 23485, 16238 => 27454,
+    16239 => 21281, 16240 => 31568, 16241 => 29378, 16242 => 26694, 16243 => 30719,
+    16244 => 30518, 16245 => 26103, 16246 => 20917, 16247 => 20111, 16248 => 30420,
+    16249 => 23743, 16250 => 31397, 16251 => 33909, 16252 => 22862, 16253 => 39745,
+    16254 => 20608, 16417 => 39304, 16418 => 24871, 16419 => 28291, 16420 => 22372,
+    16421 => 26118, 16422 => 25414, 16423 => 22256, 16424 => 25324, 16425 => 25193,
+    16426 => 24275, 16427 => 38420, 16428 => 22403, 16429 => 25289, 16430 => 21895,
+    16431 => 34593, 16432 => 33098, 16433 => 36771, 16434 => 21862, 16435 => 33713,
+    16436 => 26469, 16437 => 36182, 16438 => 34013, 16439 => 23146, 16440 => 26639,
+    16441 => 25318, 16442 => 31726, 16443 => 38417, 16444 => 20848, 16445 => 28572,
+    16446 => 35888, 16447 => 25597, 16448 => 35272, 16449 => 25042, 16450 => 32518,
+    16451 => 28866, 16452 => 28389, 16453 => 29701, 16454 => 27028, 16455 => 29436,
+    16456 => 24266, 16457 => 37070, 16458 => 26391, 16459 => 28010, 16460 => 25438,
+    16461 => 21171, 16462 => 29282, 16463 => 32769, 16464 => 20332, 16465 => 23013,
+    16466 => 37226, 16467 => 28889, 16468 => 28061, 16469 => 21202, 16470 => 20048,
+    16471 => 38647, 16472 => 38253, 16473 => 34174, 16474 => 30922, 16475 => 32047,
+    16476 => 20769, 16477 => 22418, 16478 => 25794, 16479 => 32907, 16480 => 31867,
+    16481 => 27882, 16482 => 26865, 16483 => 26974, 16484 => 20919, 16485 => 21400,
+    16486 => 26792, 16487 => 29313, 16488 => 40654, 16489 => 31729, 16490 => 29432,
+    16491 => 31163, 16492 => 28435, 16493 => 29702, 16494 => 26446, 16495 => 37324,
+    16496 => 40100, 16497 => 31036, 16498 => 33673, 16499 => 33620, 16500 => 21519,
+    16501 => 26647, 16502 => 20029, 16503 => 21385, 16504 => 21169, 16505 => 30782,
+    16506 => 21382, 16507 => 21033, 16508 => 20616, 16509 => 20363, 16510 => 20432,
+    16673 => 30178, 16674 => 31435, 16675 => 31890, 16676 => 27813, 16677 => 38582,
+    16678 => 21147, 16679 => 29827, 16680 => 21737, 16681 => 20457, 16682 => 32852,
+    16683 => 33714, 16684 => 36830, 16685 => 38256, 16686 => 24265, 16687 => 24604,
+    16688 => 28063, 16689 => 24088, 16690 => 25947, 16691 => 33080, 16692 => 38142,
+    16693 => 24651, 16694 => 28860, 16695 => 32451, 16696 => 31918, 16697 => 20937,
+    16698 => 26753, 16699 => 31921, 16700 => 33391, 16701 => 20004, 16702 => 36742,
+    16703 => 37327, 16704 => 26238, 16705 => 20142, 16706 => 35845, 16707 => 25769,
+    16708 => 32842, 16709 => 20698, 16710 => 30103, 16711 => 29134, 16712 => 23525,
+    16713 => 36797, 16714 => 28518, 16715 => 20102, 16716 => 25730, 16717 => 38243,
+    16718 => 24278, 16719 => 26009, 16720 => 21015, 16721 => 35010, 16722 => 28872,
+    16723 => 21155, 16724 => 29454, 16725 => 29747, 16726 => 26519, 16727 => 30967,
+    16728 => 38678, 16729 => 20020, 16730 => 37051, 16731 => 40158, 16732 => 28107,
+    16733 => 20955, 16734 => 36161, 16735 => 21533, 16736 => 25294, 16737 => 29618,
+    16738 => 33777, 16739 => 38646, 16740 => 40836, 16741 => 38083, 16742 => 20278,
+    16743 => 32666, 16744 => 20940, 16745 => 28789, 16746 => 38517, 16747 => 23725,
+    16748 => 39046, 16749 => 21478, 16750 => 20196, 16751 => 28316, 16752 => 29705,
+    16753 => 27060, 16754 => 30827, 16755 => 39311, 16756 => 30041, 16757 => 21016,
+    16758 => 30244, 16759 => 27969, 16760 => 26611, 16761 => 20845, 16762 => 40857,
+    16763 => 32843, 16764 => 21657, 16765 => 31548, 16766 => 31423, 16929 => 38534,
+    16930 => 22404, 16931 => 25314, 16932 => 38471, 16933 => 27004, 16934 => 23044,
+    16935 => 25602, 16936 => 31699, 16937 => 28431, 16938 => 38475, 16939 => 33446,
+    16940 => 21346, 16941 => 39045, 16942 => 24208, 16943 => 28809, 16944 => 25523,
+    16945 => 21348, 16946 => 34383, 16947 => 40065, 16948 => 40595, 16949 => 30860,
+    16950 => 38706, 16951 => 36335, 16952 => 36162, 16953 => 40575, 16954 => 28510,
+    16955 => 31108, 16956 => 24405, 16957 => 38470, 16958 => 25134, 16959 => 39540,
+    16960 => 21525, 16961 => 38109, 16962 => 20387, 16963 => 26053, 16964 => 23653,
+    16965 => 23649, 16966 => 32533, 16967 => 34385, 16968 => 27695, 16969 => 24459,
+    16970 => 29575, 16971 => 28388, 16972 => 32511, 16973 => 23782, 16974 => 25371,
+    16975 => 23402, 16976 => 28390, 16977 => 21365, 16978 => 20081, 16979 => 25504,
+    16980 => 30053, 16981 => 25249, 16982 => 36718, 16983 => 20262, 16984 => 20177,
+    16985 => 27814, 16986 => 32438, 16987 => 35770, 16988 => 33821, 16989 => 34746,
+    16990 => 32599, 16991 => 36923, 16992 => 38179, 16993 => 31657, 16994 => 39585,
+    16995 => 35064, 16996 => 33853, 16997 => 27931, 16998 => 39558, 16999 => 32476,
+    17000 => 22920, 17001 => 40635, 17002 => 29595, 17003 => 30721, 17004 => 34434,
+    17005 => 39532, 17006 => 39554, 17007 => 22043, 17008 => 21527, 17009 => 22475,
+    17010 => 20080, 17011 => 40614, 17012 => 21334, 17013 => 36808, 17014 => 33033,
+    17015 => 30610, 17016 => 39314, 17017 => 34542, 17018 => 28385, 17019 => 34067,
+    17020 => 26364, 17021 => 24930, 17022 => 28459, 17185 => 35881, 17186 => 33426,
+    17187 => 33579, 17188 => 30450, 17189 => 27667, 17190 => 24537, 17191 => 33725,
+    17192 => 29483, 17193 => 33541, 17194 => 38170, 17195 => 27611, 17196 => 30683,
+    17197 => 38086, 17198 => 21359, 17199 => 33538, 17200 => 20882, 17201 => 24125,
+    17202 => 35980, 17203 => 36152, 17204 => 20040, 17205 => 29611, 17206 => 26522,
+    17207 => 26757, 17208 => 37238, 17209 => 38665, 17210 => 29028, 17211 => 27809,
+    17212 => 30473, 17213 => 23186, 17214 => 38209, 17215 => 27599, 17216 => 32654,
+    17217 => 26151, 17218 => 23504, 17219 => 22969, 17220 => 23194, 17221 => 38376,
+    17222 => 38391, 17223 => 20204, 17224 => 33804, 17225 => 33945, 17226 => 27308,
+    17227 => 30431, 17228 => 38192, 17229 => 29467, 17230 => 26790, 17231 => 23391,
+    17232 => 30511, 17233 => 37274, 17234 => 38753, 17235 => 31964, 17236 => 36855,
+    17237 => 35868, 17238 => 24357, 17239 => 31859, 17240 => 31192, 17241 => 35269,
+    17242 => 27852, 17243 => 34588, 17244 => 23494, 17245 => 24130, 17246 => 26825,
+    17247 => 30496, 17248 => 32501, 17249 => 20885, 17250 => 20813, 17251 => 21193,
+    17252 => 23081, 17253 => 32517, 17254 => 38754, 17255 => 33495, 17256 => 25551,
+    17257 => 30596, 17258 => 34256, 17259 => 31186, 17260 => 28218, 17261 => 24217,
+    17262 => 22937, 17263 => 34065, 17264 => 28781, 17265 => 27665, 17266 => 25279,
+    17267 => 30399, 17268 => 25935, 17269 => 24751, 17270 => 38397, 17271 => 26126,
+    17272 => 34719, 17273 => 40483, 17274 => 38125, 17275 => 21517, 17276 => 21629,
+    17277 => 35884, 17278 => 25720, 17441 => 25721, 17442 => 34321, 17443 => 27169,
+    17444 => 33180, 17445 => 30952, 17446 => 25705, 17447 => 39764, 17448 => 25273,
+    17449 => 26411, 17450 => 33707, 17451 => 22696, 17452 => 40664, 17453 => 27819,
+    17454 => 28448, 17455 => 23518, 17456 => 38476, 17457 => 35851, 17458 => 29279,
+    17459 => 26576, 17460 => 25287, 17461 => 29281, 17462 => 20137, 17463 => 22982,
+    17464 => 27597, 17465 => 22675, 17466 => 26286, 17467 => 24149, 17468 => 21215,
+    17469 => 24917, 17470 => 26408, 17471 => 30446, 17472 => 30566, 17473 => 29287,
+    17474 => 31302, 17475 => 25343, 17476 => 21738, 17477 => 21584, 17478 => 38048,
+    17479 => 37027, 17480 => 23068, 17481 => 32435, 17482 => 27670, 17483 => 20035,
+    17484 => 22902, 17485 => 32784, 17486 => 22856, 17487 => 21335, 17488 => 30007,
+    17489 => 38590, 17490 => 22218, 17491 => 25376, 17492 => 33041, 17493 => 24700,
+    17494 => 38393, 17495 => 28118, 17496 => 21602, 17497 => 39297, 17498 => 20869,
+    17499 => 23273, 17500 => 33021, 17501 => 22958, 17502 => 38675, 17503 => 20522,
+    17504 => 27877, 17505 => 23612, 17506 => 25311, 17507 => 20320, 17508 => 21311,
+    17509 => 33147, 17510 => 36870, 17511 => 28346, 17512 => 34091, 17513 => 25288,
+    17514 => 24180, 17515 => 30910, 17516 => 25781, 17517 => 25467, 17518 => 24565,
+    17519 => 23064, 17520 => 37247, 17521 => 40479, 17522 => 23615, 17523 => 25423,
+    17524 => 32834, 17525 => 23421, 17526 => 21870, 17527 => 38218, 17528 => 38221,
+    17529 => 28037, 17530 => 24744, 17531 => 26592, 17532 => 29406, 17533 => 20957,
+    17534 => 23425, 17697 => 25319, 17698 => 27870, 17699 => 29275, 17700 => 25197,
+    17701 => 38062, 17702 => 32445, 17703 => 33043, 17704 => 27987, 17705 => 20892,
+    17706 => 24324, 17707 => 22900, 17708 => 21162, 17709 => 24594, 17710 => 22899,
+    17711 => 26262, 17712 => 34384, 17713 => 30111, 17714 => 25386, 17715 => 25062,
+    17716 => 31983, 17717 => 35834, 17718 => 21734, 17719 => 27431, 17720 => 40485,
+    17721 => 27572, 17722 => 34261, 17723 => 21589, 17724 => 20598, 17725 => 27812,
+    17726 => 21866, 17727 => 36276, 17728 => 29228, 17729 => 24085, 17730 => 24597,
+    17731 => 29750, 17732 => 25293, 17733 => 25490, 17734 => 29260, 17735 => 24472,
+    17736 => 28227, 17737 => 27966, 17738 => 25856, 17739 => 28504, 17740 => 30424,
+    17741 => 30928, 17742 => 30460, 17743 => 30036, 17744 => 21028, 17745 => 21467,
+    17746 => 20051, 17747 => 24222, 17748 => 26049, 17749 => 32810, 17750 => 32982,
+    17751 => 25243, 17752 => 21638, 17753 => 21032, 17754 => 28846, 17755 => 34957,
+    17756 => 36305, 17757 => 27873, 17758 => 21624, 17759 => 32986, 17760 => 22521,
+    17761 => 35060, 17762 => 36180, 17763 => 38506, 17764 => 37197, 17765 => 20329,
+    17766 => 27803, 17767 => 21943, 17768 => 30406, 17769 => 30768, 17770 => 25256,
+    17771 => 28921, 17772 => 28558, 17773 => 24429, 17774 => 34028, 17775 => 26842,
+    17776 => 30844, 17777 => 31735, 17778 => 33192, 17779 => 26379, 17780 => 40527,
+    17781 => 25447, 17782 => 30896, 17783 => 22383, 17784 => 30738, 17785 => 38713,
+    17786 => 25209, 17787 => 25259, 17788 => 21128, 17789 => 29749, 17790 => 27607,
+    17953 => 21860, 17954 => 33086, 17955 => 30130, 17956 => 30382, 17957 => 21305,
+    17958 => 30174, 17959 => 20731, 17960 => 23617, 17961 => 35692, 17962 => 31687,
+    17963 => 20559, 17964 => 29255, 17965 => 39575, 17966 => 39128, 17967 => 28418,
+    17968 => 29922, 17969 => 31080, 17970 => 25735, 17971 => 30629, 17972 => 25340,
+    17973 => 39057, 17974 => 36139, 17975 => 21697, 17976 => 32856, 17977 => 20050,
+    17978 => 22378, 17979 => 33529, 17980 => 33805, 17981 => 24179, 17982 => 20973,
+    17983 => 29942, 17984 => 35780, 17985 => 23631, 17986 => 22369, 17987 => 27900,
+    17988 => 39047, 17989 => 23110, 17990 => 30772, 17991 => 39748, 17992 => 36843,
+    17993 => 31893, 17994 => 21078, 17995 => 25169, 17996 => 38138, 17997 => 20166,
+    17998 => 33670, 17999 => 33889, 18000 => 33769, 18001 => 33970, 18002 => 22484,
+    18003 => 26420, 18004 => 22275, 18005 => 26222, 18006 => 28006, 18007 => 35889,
+    18008 => 26333, 18009 => 28689, 18010 => 26399, 18011 => 27450, 18012 => 26646,
+    18013 => 25114, 18014 => 22971, 18015 => 19971, 18016 => 20932, 18017 => 28422,
+    18018 => 26578, 18019 => 27791, 18020 => 20854, 18021 => 26827, 18022 => 22855,
+    18023 => 27495, 18024 => 30054, 18025 => 23822, 18026 => 33040, 18027 => 40784,
+    18028 => 26071, 18029 => 31048, 18030 => 31041, 18031 => 39569, 18032 => 36215,
+    18033 => 23682, 18034 => 20062, 18035 => 20225, 18036 => 21551, 18037 => 22865,
+    18038 => 30732, 18039 => 22120, 18040 => 27668, 18041 => 36804, 18042 => 24323,
+    18043 => 27773, 18044 => 27875, 18045 => 35755, 18046 => 25488, 18209 => 24688,
+    18210 => 27965, 18211 => 29301, 18212 => 25190, 18213 => 38030, 18214 => 38085,
+    18215 => 21315, 18216 => 36801, 18217 => 31614, 18218 => 20191, 18219 => 35878,
+    18220 => 20094, 18221 => 40660, 18222 => 38065, 18223 => 38067, 18224 => 21069,
+    18225 => 28508, 18226 => 36963, 18227 => 27973, 18228 => 35892, 18229 => 22545,
+    18230 => 23884, 18231 => 27424, 18232 => 27465, 18233 => 26538, 18234 => 21595,
+    18235 => 33108, 18236 => 32652, 18237 => 22681, 18238 => 34103, 18239 => 24378,
+    18240 => 25250, 18241 => 27207, 18242 => 38201, 18243 => 25970, 18244 => 24708,
+    18245 => 26725, 18246 => 30631, 18247 => 20052, 18248 => 20392, 18249 => 24039,
+    18250 => 38808, 18251 => 25772, 18252 => 32728, 18253 => 23789, 18254 => 20431,
+    18255 => 31373, 18256 => 20999, 18257 => 33540, 18258 => 19988, 18259 => 24623,
+    18260 => 31363, 18261 => 38054, 18262 => 20405, 18263 => 20146, 18264 => 31206,
+    18265 => 29748, 18266 => 21220, 18267 => 33465, 18268 => 25810, 18269 => 31165,
+    18270 => 23517, 18271 => 27777, 18272 => 38738, 18273 => 36731, 18274 => 27682,
+    18275 => 20542, 18276 => 21375, 18277 => 28165, 18278 => 25806, 18279 => 26228,
+    18280 => 27696, 18281 => 24773, 18282 => 39031, 18283 => 35831, 18284 => 24198,
+    18285 => 29756, 18286 => 31351, 18287 => 31179, 18288 => 19992, 18289 => 37041,
+    18290 => 29699, 18291 => 27714, 18292 => 22234, 18293 => 37195, 18294 => 27845,
+    18295 => 36235, 18296 => 21306, 18297 => 34502, 18298 => 26354, 18299 => 36527,
+    18300 => 23624, 18301 => 39537, 18302 => 28192, 18465 => 21462, 18466 => 23094,
+    18467 => 40843, 18468 => 36259, 18469 => 21435, 18470 => 22280, 18471 => 39079,
+    18472 => 26435, 18473 => 37275, 18474 => 27849, 18475 => 20840, 18476 => 30154,
+    18477 => 25331, 18478 => 29356, 18479 => 21048, 18480 => 21149, 18481 => 32570,
+    18482 => 28820, 18483 => 30264, 18484 => 21364, 18485 => 40522, 18486 => 27063,
+    18487 => 30830, 18488 => 38592, 18489 => 35033, 18490 => 32676, 18491 => 28982,
+    18492 => 29123, 18493 => 20873, 18494 => 26579, 18495 => 29924, 18496 => 22756,
+    18497 => 25880, 18498 => 22199, 18499 => 35753, 18500 => 39286, 18501 => 25200,
+    18502 => 32469, 18503 => 24825, 18504 => 28909, 18505 => 22764, 18506 => 20161,
+    18507 => 20154, 18508 => 24525, 18509 => 38887, 18510 => 20219, 18511 => 35748,
+    18512 => 20995, 18513 => 22922, 18514 => 32427, 18515 => 25172, 18516 => 20173,
+    18517 => 26085, 18518 => 25102, 18519 => 33592, 18520 => 33993, 18521 => 33635,
+    18522 => 34701, 18523 => 29076, 18524 => 28342, 18525 => 23481, 18526 => 32466,
+    18527 => 20887, 18528 => 25545, 18529 => 26580, 18530 => 32905, 18531 => 33593,
+    18532 => 34837, 18533 => 20754, 18534 => 23418, 18535 => 22914, 18536 => 36785,
+    18537 => 20083, 18538 => 27741, 18539 => 20837, 18540 => 35109, 18541 => 36719,
+    18542 => 38446, 18543 => 34122, 18544 => 29790, 18545 => 38160, 18546 => 38384,
+    18547 => 28070, 18548 => 33509, 18549 => 24369, 18550 => 25746, 18551 => 27922,
+    18552 => 33832, 18553 => 33134, 18554 => 40131, 18555 => 22622, 18556 => 36187,
+    18557 => 19977, 18558 => 21441, 18721 => 20254, 18722 => 25955, 18723 => 26705,
+    18724 => 21971, 18725 => 20007, 18726 => 25620, 18727 => 39578, 18728 => 25195,
+    18729 => 23234, 18730 => 29791, 18731 => 33394, 18732 => 28073, 18733 => 26862,
+    18734 => 20711, 18735 => 33678, 18736 => 30722, 18737 => 26432, 18738 => 21049,
+    18739 => 27801, 18740 => 32433, 18741 => 20667, 18742 => 21861, 18743 => 29022,
+    18744 => 31579, 18745 => 26194, 18746 => 29642, 18747 => 33515, 18748 => 26441,
+    18749 => 23665, 18750 => 21024, 18751 => 29053, 18752 => 34923, 18753 => 38378,
+    18754 => 38485, 18755 => 25797, 18756 => 36193, 18757 => 33203, 18758 => 21892,
+    18759 => 27733, 18760 => 25159, 18761 => 32558, 18762 => 22674, 18763 => 20260,
+    18764 => 21830, 18765 => 36175, 18766 => 26188, 18767 => 19978, 18768 => 23578,
+    18769 => 35059, 18770 => 26786, 18771 => 25422, 18772 => 31245, 18773 => 28903,
+    18774 => 33421, 18775 => 21242, 18776 => 38902, 18777 => 23569, 18778 => 21736,
+    18779 => 37045, 18780 => 32461, 18781 => 22882, 18782 => 36170, 18783 => 34503,
+    18784 => 33292, 18785 => 33293, 18786 => 36198, 18787 => 25668, 18788 => 23556,
+    18789 => 24913, 18790 => 28041, 18791 => 31038, 18792 => 35774, 18793 => 30775,
+    18794 => 30003, 18795 => 21627, 18796 => 20280, 18797 => 36523, 18798 => 28145,
+    18799 => 23072, 18800 => 32453, 18801 => 31070, 18802 => 27784, 18803 => 23457,
+    18804 => 23158, 18805 => 29978, 18806 => 32958, 18807 => 24910, 18808 => 28183,
+    18809 => 22768, 18810 => 29983, 18811 => 29989, 18812 => 29298, 18813 => 21319,
+    18814 => 32499, 18977 => 30465, 18978 => 30427, 18979 => 21097, 18980 => 32988,
+    18981 => 22307, 18982 => 24072, 18983 => 22833, 18984 => 29422, 18985 => 26045,
+    18986 => 28287, 18987 => 35799, 18988 => 23608, 18989 => 34417, 18990 => 21313,
+    18991 => 30707, 18992 => 25342, 18993 => 26102, 18994 => 20160, 18995 => 39135,
+    18996 => 34432, 18997 => 23454, 18998 => 35782, 18999 => 21490, 19000 => 30690,
+    19001 => 20351, 19002 => 23630, 19003 => 39542, 19004 => 22987, 19005 => 24335,
+    19006 => 31034, 19007 => 22763, 19008 => 19990, 19009 => 26623, 19010 => 20107,
+    19011 => 25325, 19012 => 35475, 19013 => 36893, 19014 => 21183, 19015 => 26159,
+    19016 => 21980, 19017 => 22124, 19018 => 36866, 19019 => 20181, 19020 => 20365,
+    19021 => 37322, 19022 => 39280, 19023 => 27663, 19024 => 24066, 19025 => 24643,
+    19026 => 23460, 19027 => 35270, 19028 => 35797, 19029 => 25910, 19030 => 25163,
+    19031 => 39318, 19032 => 23432, 19033 => 23551, 19034 => 25480, 19035 => 21806,
+    19036 => 21463, 19037 => 30246, 19038 => 20861, 19039 => 34092, 19040 => 26530,
+    19041 => 26803, 19042 => 27530, 19043 => 25234, 19044 => 36755, 19045 => 21460,
+    19046 => 33298, 19047 => 28113, 19048 => 30095, 19049 => 20070, 19050 => 36174,
+    19051 => 23408, 19052 => 29087, 19053 => 34223, 19054 => 26257, 19055 => 26329,
+    19056 => 32626, 19057 => 34560, 19058 => 40653, 19059 => 40736, 19060 => 23646,
+    19061 => 26415, 19062 => 36848, 19063 => 26641, 19064 => 26463, 19065 => 25101,
+    19066 => 31446, 19067 => 22661, 19068 => 24246, 19069 => 25968, 19070 => 28465,
+    19233 => 24661, 19234 => 21047, 19235 => 32781, 19236 => 25684, 19237 => 34928,
+    19238 => 29993, 19239 => 24069, 19240 => 26643, 19241 => 25332, 19242 => 38684,
+    19243 => 21452, 19244 => 29245, 19245 => 35841, 19246 => 27700, 19247 => 30561,
+    19248 => 31246, 19249 => 21550, 19250 => 30636, 19251 => 39034, 19252 => 33308,
+    19253 => 35828, 19254 => 30805, 19255 => 26388, 19256 => 28865, 19257 => 26031,
+    19258 => 25749, 19259 => 22070, 19260 => 24605, 19261 => 31169, 19262 => 21496,
+    19263 => 19997, 19264 => 27515, 19265 => 32902, 19266 => 23546, 19267 => 21987,
+    19268 => 22235, 19269 => 20282, 19270 => 20284, 19271 => 39282, 19272 => 24051,
+    19273 => 26494, 19274 => 32824, 19275 => 24578, 19276 => 39042, 19277 => 36865,
+    19278 => 23435, 19279 => 35772, 19280 => 35829, 19281 => 25628, 19282 => 33368,
+    19283 => 25822, 19284 => 22013, 19285 => 33487, 19286 => 37221, 19287 => 20439,
+    19288 => 32032, 19289 => 36895, 19290 => 31903, 19291 => 20723, 19292 => 22609,
+    19293 => 28335, 19294 => 23487, 19295 => 35785, 19296 => 32899, 19297 => 37240,
+    19298 => 33948, 19299 => 31639, 19300 => 34429, 19301 => 38539, 19302 => 38543,
+    19303 => 32485, 19304 => 39635, 19305 => 30862, 19306 => 23681, 19307 => 31319,
+    19308 => 36930, 19309 => 38567, 19310 => 31071, 19311 => 23385, 19312 => 25439,
+    19313 => 31499, 19314 => 34001, 19315 => 26797, 19316 => 21766, 19317 => 32553,
+    19318 => 29712, 19319 => 32034, 19320 => 38145, 19321 => 25152, 19322 => 22604,
+    19323 => 20182, 19324 => 23427, 19325 => 22905, 19326 => 22612, 19489 => 29549,
+    19490 => 25374, 19491 => 36427, 19492 => 36367, 19493 => 32974, 19494 => 33492,
+    19495 => 25260, 19496 => 21488, 19497 => 27888, 19498 => 37214, 19499 => 22826,
+    19500 => 24577, 19501 => 27760, 19502 => 22349, 19503 => 25674, 19504 => 36138,
+    19505 => 30251, 19506 => 28393, 19507 => 22363, 19508 => 27264, 19509 => 30192,
+    19510 => 28525, 19511 => 35885, 19512 => 35848, 19513 => 22374, 19514 => 27631,
+    19515 => 34962, 19516 => 30899, 19517 => 25506, 19518 => 21497, 19519 => 28845,
+    19520 => 27748, 19521 => 22616, 19522 => 25642, 19523 => 22530, 19524 => 26848,
+    19525 => 33179, 19526 => 21776, 19527 => 31958, 19528 => 20504, 19529 => 36538,
+    19530 => 28108, 19531 => 36255, 19532 => 28907, 19533 => 25487, 19534 => 28059,
+    19535 => 28372, 19536 => 32486, 19537 => 33796, 19538 => 26691, 19539 => 36867,
+    19540 => 28120, 19541 => 38518, 19542 => 35752, 19543 => 22871, 19544 => 29305,
+    19545 => 34276, 19546 => 33150, 19547 => 30140, 19548 => 35466, 19549 => 26799,
+    19550 => 21076, 19551 => 36386, 19552 => 38161, 19553 => 25552, 19554 => 39064,
+    19555 => 36420, 19556 => 21884, 19557 => 20307, 19558 => 26367, 19559 => 22159,
+    19560 => 24789, 19561 => 28053, 19562 => 21059, 19563 => 23625, 19564 => 22825,
+    19565 => 28155, 19566 => 22635, 19567 => 30000, 19568 => 29980, 19569 => 24684,
+    19570 => 33300, 19571 => 33094, 19572 => 25361, 19573 => 26465, 19574 => 36834,
+    19575 => 30522, 19576 => 36339, 19577 => 36148, 19578 => 38081, 19579 => 24086,
+    19580 => 21381, 19581 => 21548, 19582 => 28867, 19745 => 27712, 19746 => 24311,
+    19747 => 20572, 19748 => 20141, 19749 => 24237, 19750 => 25402, 19751 => 33351,
+    19752 => 36890, 19753 => 26704, 19754 => 37230, 19755 => 30643, 19756 => 21516,
+    19757 => 38108, 19758 => 24420, 19759 => 31461, 19760 => 26742, 19761 => 25413,
+    19762 => 31570, 19763 => 32479, 19764 => 30171, 19765 => 20599, 19766 => 25237,
+    19767 => 22836, 19768 => 36879, 19769 => 20984, 19770 => 31171, 19771 => 31361,
+    19772 => 22270, 19773 => 24466, 19774 => 36884, 19775 => 28034, 19776 => 23648,
+    19777 => 22303, 19778 => 21520, 19779 => 20820, 19780 => 28237, 19781 => 22242,
+    19782 => 25512, 19783 => 39059, 19784 => 33151, 19785 => 34581, 19786 => 35114,
+    19787 => 36864, 19788 => 21534, 19789 => 23663, 19790 => 33216, 19791 => 25302,
+    19792 => 25176, 19793 => 33073, 19794 => 40501, 19795 => 38464, 19796 => 39534,
+    19797 => 39548, 19798 => 26925, 19799 => 22949, 19800 => 25299, 19801 => 21822,
+    19802 => 25366, 19803 => 21703, 19804 => 34521, 19805 => 27964, 19806 => 23043,
+    19807 => 29926, 19808 => 34972, 19809 => 27498, 19810 => 22806, 19811 => 35916,
+    19812 => 24367, 19813 => 28286, 19814 => 29609, 19815 => 39037, 19816 => 20024,
+    19817 => 28919, 19818 => 23436, 19819 => 30871, 19820 => 25405, 19821 => 26202,
+    19822 => 30358, 19823 => 24779, 19824 => 23451, 19825 => 23113, 19826 => 19975,
+    19827 => 33109, 19828 => 27754, 19829 => 29579, 19830 => 20129, 19831 => 26505,
+    19832 => 32593, 19833 => 24448, 19834 => 26106, 19835 => 26395, 19836 => 24536,
+    19837 => 22916, 19838 => 23041, 20001 => 24013, 20002 => 24494, 20003 => 21361,
+    20004 => 38886, 20005 => 36829, 20006 => 26693, 20007 => 22260, 20008 => 21807,
+    20009 => 24799, 20010 => 20026, 20011 => 28493, 20012 => 32500, 20013 => 33479,
+    20014 => 33806, 20015 => 22996, 20016 => 20255, 20017 => 20266, 20018 => 23614,
+    20019 => 32428, 20020 => 26410, 20021 => 34074, 20022 => 21619, 20023 => 30031,
+    20024 => 32963, 20025 => 21890, 20026 => 39759, 20027 => 20301, 20028 => 28205,
+    20029 => 35859, 20030 => 23561, 20031 => 24944, 20032 => 21355, 20033 => 30239,
+    20034 => 28201, 20035 => 34442, 20036 => 25991, 20037 => 38395, 20038 => 32441,
+    20039 => 21563, 20040 => 31283, 20041 => 32010, 20042 => 38382, 20043 => 21985,
+    20044 => 32705, 20045 => 29934, 20046 => 25373, 20047 => 34583, 20048 => 28065,
+    20049 => 31389, 20050 => 25105, 20051 => 26017, 20052 => 21351, 20053 => 25569,
+    20054 => 27779, 20055 => 24043, 20056 => 21596, 20057 => 38056, 20058 => 20044,
+    20059 => 27745, 20060 => 35820, 20061 => 23627, 20062 => 26080, 20063 => 33436,
+    20064 => 26791, 20065 => 21566, 20066 => 21556, 20067 => 27595, 20068 => 27494,
+    20069 => 20116, 20070 => 25410, 20071 => 21320, 20072 => 33310, 20073 => 20237,
+    20074 => 20398, 20075 => 22366, 20076 => 25098, 20077 => 38654, 20078 => 26212,
+    20079 => 29289, 20080 => 21247, 20081 => 21153, 20082 => 24735, 20083 => 35823,
+    20084 => 26132, 20085 => 29081, 20086 => 26512, 20087 => 35199, 20088 => 30802,
+    20089 => 30717, 20090 => 26224, 20091 => 22075, 20092 => 21560, 20093 => 38177,
+    20094 => 29306, 20257 => 31232, 20258 => 24687, 20259 => 24076, 20260 => 24713,
+    20261 => 33181, 20262 => 22805, 20263 => 24796, 20264 => 29060, 20265 => 28911,
+    20266 => 28330, 20267 => 27728, 20268 => 29312, 20269 => 27268, 20270 => 34989,
+    20271 => 24109, 20272 => 20064, 20273 => 23219, 20274 => 21916, 20275 => 38115,
+    20276 => 27927, 20277 => 31995, 20278 => 38553, 20279 => 25103, 20280 => 32454,
+    20281 => 30606, 20282 => 34430, 20283 => 21283, 20284 => 38686, 20285 => 36758,
+    20286 => 26247, 20287 => 23777, 20288 => 20384, 20289 => 29421, 20290 => 19979,
+    20291 => 21414, 20292 => 22799, 20293 => 21523, 20294 => 25472, 20295 => 38184,
+    20296 => 20808, 20297 => 20185, 20298 => 40092, 20299 => 32420, 20300 => 21688,
+    20301 => 36132, 20302 => 34900, 20303 => 33335, 20304 => 38386, 20305 => 28046,
+    20306 => 24358, 20307 => 23244, 20308 => 26174, 20309 => 38505, 20310 => 29616,
+    20311 => 29486, 20312 => 21439, 20313 => 33146, 20314 => 39301, 20315 => 32673,
+    20316 => 23466, 20317 => 38519, 20318 => 38480, 20319 => 32447, 20320 => 30456,
+    20321 => 21410, 20322 => 38262, 20323 => 39321, 20324 => 31665, 20325 => 35140,
+    20326 => 28248, 20327 => 20065, 20328 => 32724, 20329 => 31077, 20330 => 35814,
+    20331 => 24819, 20332 => 21709, 20333 => 20139, 20334 => 39033, 20335 => 24055,
+    20336 => 27233, 20337 => 20687, 20338 => 21521, 20339 => 35937, 20340 => 33831,
+    20341 => 30813, 20342 => 38660, 20343 => 21066, 20344 => 21742, 20345 => 22179,
+    20346 => 38144, 20347 => 28040, 20348 => 23477, 20349 => 28102, 20350 => 26195,
+    20513 => 23567, 20514 => 23389, 20515 => 26657, 20516 => 32918, 20517 => 21880,
+    20518 => 31505, 20519 => 25928, 20520 => 26964, 20521 => 20123, 20522 => 27463,
+    20523 => 34638, 20524 => 38795, 20525 => 21327, 20526 => 25375, 20527 => 25658,
+    20528 => 37034, 20529 => 26012, 20530 => 32961, 20531 => 35856, 20532 => 20889,
+    20533 => 26800, 20534 => 21368, 20535 => 34809, 20536 => 25032, 20537 => 27844,
+    20538 => 27899, 20539 => 35874, 20540 => 23633, 20541 => 34218, 20542 => 33455,
+    20543 => 38156, 20544 => 27427, 20545 => 36763, 20546 => 26032, 20547 => 24571,
+    20548 => 24515, 20549 => 20449, 20550 => 34885, 20551 => 26143, 20552 => 33125,
+    20553 => 29481, 20554 => 24826, 20555 => 20852, 20556 => 21009, 20557 => 22411,
+    20558 => 24418, 20559 => 37026, 20560 => 34892, 20561 => 37266, 20562 => 24184,
+    20563 => 26447, 20564 => 24615, 20565 => 22995, 20566 => 20804, 20567 => 20982,
+    20568 => 33016, 20569 => 21256, 20570 => 27769, 20571 => 38596, 20572 => 29066,
+    20573 => 20241, 20574 => 20462, 20575 => 32670, 20576 => 26429, 20577 => 21957,
+    20578 => 38152, 20579 => 31168, 20580 => 34966, 20581 => 32483, 20582 => 22687,
+    20583 => 25100, 20584 => 38656, 20585 => 34394, 20586 => 22040, 20587 => 39035,
+    20588 => 24464, 20589 => 35768, 20590 => 33988, 20591 => 37207, 20592 => 21465,
+    20593 => 26093, 20594 => 24207, 20595 => 30044, 20596 => 24676, 20597 => 32110,
+    20598 => 23167, 20599 => 32490, 20600 => 32493, 20601 => 36713, 20602 => 21927,
+    20603 => 23459, 20604 => 24748, 20605 => 26059, 20606 => 29572, 20769 => 36873,
+    20770 => 30307, 20771 => 30505, 20772 => 32474, 20773 => 38772, 20774 => 34203,
+    20775 => 23398, 20776 => 31348, 20777 => 38634, 20778 => 34880, 20779 => 21195,
+    20780 => 29071, 20781 => 24490, 20782 => 26092, 20783 => 35810, 20784 => 23547,
+    20785 => 39535, 20786 => 24033, 20787 => 27529, 20788 => 27739, 20789 => 35757,
+    20790 => 35759, 20791 => 36874, 20792 => 36805, 20793 => 21387, 20794 => 25276,
+    20795 => 40486, 20796 => 40493, 20797 => 21568, 20798 => 20011, 20799 => 33469,
+    20800 => 29273, 20801 => 34460, 20802 => 23830, 20803 => 34905, 20804 => 28079,
+    20805 => 38597, 20806 => 21713, 20807 => 20122, 20808 => 35766, 20809 => 28937,
+    20810 => 21693, 20811 => 38409, 20812 => 28895, 20813 => 28153, 20814 => 30416,
+    20815 => 20005, 20816 => 30740, 20817 => 34578, 20818 => 23721, 20819 => 24310,
+    20820 => 35328, 20821 => 39068, 20822 => 38414, 20823 => 28814, 20824 => 27839,
+    20825 => 22852, 20826 => 25513, 20827 => 30524, 20828 => 34893, 20829 => 28436,
+    20830 => 33395, 20831 => 22576, 20832 => 29141, 20833 => 21388, 20834 => 30746,
+    20835 => 38593, 20836 => 21761, 20837 => 24422, 20838 => 28976, 20839 => 23476,
+    20840 => 35866, 20841 => 39564, 20842 => 27523, 20843 => 22830, 20844 => 40495,
+    20845 => 31207, 20846 => 26472, 20847 => 25196, 20848 => 20335, 20849 => 30113,
+    20850 => 32650, 20851 => 27915, 20852 => 38451, 20853 => 27687, 20854 => 20208,
+    20855 => 30162, 20856 => 20859, 20857 => 26679, 20858 => 28478, 20859 => 36992,
+    20860 => 33136, 20861 => 22934, 20862 => 29814, 21025 => 25671, 21026 => 23591,
+    21027 => 36965, 21028 => 31377, 21029 => 35875, 21030 => 23002, 21031 => 21676,
+    21032 => 33280, 21033 => 33647, 21034 => 35201, 21035 => 32768, 21036 => 26928,
+    21037 => 22094, 21038 => 32822, 21039 => 29239, 21040 => 37326, 21041 => 20918,
+    21042 => 20063, 21043 => 39029, 21044 => 25494, 21045 => 19994, 21046 => 21494,
+    21047 => 26355, 21048 => 33099, 21049 => 22812, 21050 => 28082, 21051 => 19968,
+    21052 => 22777, 21053 => 21307, 21054 => 25558, 21055 => 38129, 21056 => 20381,
+    21057 => 20234, 21058 => 34915, 21059 => 39056, 21060 => 22839, 21061 => 36951,
+    21062 => 31227, 21063 => 20202, 21064 => 33008, 21065 => 30097, 21066 => 27778,
+    21067 => 23452, 21068 => 23016, 21069 => 24413, 21070 => 26885, 21071 => 34433,
+    21072 => 20506, 21073 => 24050, 21074 => 20057, 21075 => 30691, 21076 => 20197,
+    21077 => 33402, 21078 => 25233, 21079 => 26131, 21080 => 37009, 21081 => 23673,
+    21082 => 20159, 21083 => 24441, 21084 => 33222, 21085 => 36920, 21086 => 32900,
+    21087 => 30123, 21088 => 20134, 21089 => 35028, 21090 => 24847, 21091 => 27589,
+    21092 => 24518, 21093 => 20041, 21094 => 30410, 21095 => 28322, 21096 => 35811,
+    21097 => 35758, 21098 => 35850, 21099 => 35793, 21100 => 24322, 21101 => 32764,
+    21102 => 32716, 21103 => 32462, 21104 => 33589, 21105 => 33643, 21106 => 22240,
+    21107 => 27575, 21108 => 38899, 21109 => 38452, 21110 => 23035, 21111 => 21535,
+    21112 => 38134, 21113 => 28139, 21114 => 23493, 21115 => 39278, 21116 => 23609,
+    21117 => 24341, 21118 => 38544, 21281 => 21360, 21282 => 33521, 21283 => 27185,
+    21284 => 23156, 21285 => 40560, 21286 => 24212, 21287 => 32552, 21288 => 33721,
+    21289 => 33828, 21290 => 33829, 21291 => 33639, 21292 => 34631, 21293 => 36814,
+    21294 => 36194, 21295 => 30408, 21296 => 24433, 21297 => 39062, 21298 => 30828,
+    21299 => 26144, 21300 => 21727, 21301 => 25317, 21302 => 20323, 21303 => 33219,
+    21304 => 30152, 21305 => 24248, 21306 => 38605, 21307 => 36362, 21308 => 34553,
+    21309 => 21647, 21310 => 27891, 21311 => 28044, 21312 => 27704, 21313 => 24703,
+    21314 => 21191, 21315 => 29992, 21316 => 24189, 21317 => 20248, 21318 => 24736,
+    21319 => 24551, 21320 => 23588, 21321 => 30001, 21322 => 37038, 21323 => 38080,
+    21324 => 29369, 21325 => 27833, 21326 => 28216, 21327 => 37193, 21328 => 26377,
+    21329 => 21451, 21330 => 21491, 21331 => 20305, 21332 => 37321, 21333 => 35825,
+    21334 => 21448, 21335 => 24188, 21336 => 36802, 21337 => 28132, 21338 => 20110,
+    21339 => 30402, 21340 => 27014, 21341 => 34398, 21342 => 24858, 21343 => 33286,
+    21344 => 20313, 21345 => 20446, 21346 => 36926, 21347 => 40060, 21348 => 24841,
+    21349 => 28189, 21350 => 28180, 21351 => 38533, 21352 => 20104, 21353 => 23089,
+    21354 => 38632, 21355 => 19982, 21356 => 23679, 21357 => 31161, 21358 => 23431,
+    21359 => 35821, 21360 => 32701, 21361 => 29577, 21362 => 22495, 21363 => 33419,
+    21364 => 37057, 21365 => 21505, 21366 => 36935, 21367 => 21947, 21368 => 23786,
+    21369 => 24481, 21370 => 24840, 21371 => 27442, 21372 => 29425, 21373 => 32946,
+    21374 => 35465, 21537 => 28020, 21538 => 23507, 21539 => 35029, 21540 => 39044,
+    21541 => 35947, 21542 => 39533, 21543 => 40499, 21544 => 28170, 21545 => 20900,
+    21546 => 20803, 21547 => 22435, 21548 => 34945, 21549 => 21407, 21550 => 25588,
+    21551 => 36757, 21552 => 22253, 21553 => 21592, 21554 => 22278, 21555 => 29503,
+    21556 => 28304, 21557 => 32536, 21558 => 36828, 21559 => 33489, 21560 => 24895,
+    21561 => 24616, 21562 => 38498, 21563 => 26352, 21564 => 32422, 21565 => 36234,
+    21566 => 36291, 21567 => 38053, 21568 => 23731, 21569 => 31908, 21570 => 26376,
+    21571 => 24742, 21572 => 38405, 21573 => 32792, 21574 => 20113, 21575 => 37095,
+    21576 => 21248, 21577 => 38504, 21578 => 20801, 21579 => 36816, 21580 => 34164,
+    21581 => 37213, 21582 => 26197, 21583 => 38901, 21584 => 23381, 21585 => 21277,
+    21586 => 30776, 21587 => 26434, 21588 => 26685, 21589 => 21705, 21590 => 28798,
+    21591 => 23472, 21592 => 36733, 21593 => 20877, 21594 => 22312, 21595 => 21681,
+    21596 => 25874, 21597 => 26242, 21598 => 36190, 21599 => 36163, 21600 => 33039,
+    21601 => 33900, 21602 => 36973, 21603 => 31967, 21604 => 20991, 21605 => 34299,
+    21606 => 26531, 21607 => 26089, 21608 => 28577, 21609 => 34468, 21610 => 36481,
+    21611 => 22122, 21612 => 36896, 21613 => 30338, 21614 => 28790, 21615 => 29157,
+    21616 => 36131, 21617 => 25321, 21618 => 21017, 21619 => 27901, 21620 => 36156,
+    21621 => 24590, 21622 => 22686, 21623 => 24974, 21624 => 26366, 21625 => 36192,
+    21626 => 25166, 21627 => 21939, 21628 => 28195, 21629 => 26413, 21630 => 36711,
+    21793 => 38113, 21794 => 38392, 21795 => 30504, 21796 => 26629, 21797 => 27048,
+    21798 => 21643, 21799 => 20045, 21800 => 28856, 21801 => 35784, 21802 => 25688,
+    21803 => 25995, 21804 => 23429, 21805 => 31364, 21806 => 20538, 21807 => 23528,
+    21808 => 30651, 21809 => 27617, 21810 => 35449, 21811 => 31896, 21812 => 27838,
+    21813 => 30415, 21814 => 26025, 21815 => 36759, 21816 => 23853, 21817 => 23637,
+    21818 => 34360, 21819 => 26632, 21820 => 21344, 21821 => 25112, 21822 => 31449,
+    21823 => 28251, 21824 => 32509, 21825 => 27167, 21826 => 31456, 21827 => 24432,
+    21828 => 28467, 21829 => 24352, 21830 => 25484, 21831 => 28072, 21832 => 26454,
+    21833 => 19976, 21834 => 24080, 21835 => 36134, 21836 => 20183, 21837 => 32960,
+    21838 => 30260, 21839 => 38556, 21840 => 25307, 21841 => 26157, 21842 => 25214,
+    21843 => 27836, 21844 => 36213, 21845 => 29031, 21846 => 32617, 21847 => 20806,
+    21848 => 32903, 21849 => 21484, 21850 => 36974, 21851 => 25240, 21852 => 21746,
+    21853 => 34544, 21854 => 36761, 21855 => 32773, 21856 => 38167, 21857 => 34071,
+    21858 => 36825, 21859 => 27993, 21860 => 29645, 21861 => 26015, 21862 => 30495,
+    21863 => 29956, 21864 => 30759, 21865 => 33275, 21866 => 36126, 21867 => 38024,
+    21868 => 20390, 21869 => 26517, 21870 => 30137, 21871 => 35786, 21872 => 38663,
+    21873 => 25391, 21874 => 38215, 21875 => 38453, 21876 => 33976, 21877 => 25379,
+    21878 => 30529, 21879 => 24449, 21880 => 29424, 21881 => 20105, 21882 => 24596,
+    21883 => 25972, 21884 => 25327, 21885 => 27491, 21886 => 25919, 22049 => 24103,
+    22050 => 30151, 22051 => 37073, 22052 => 35777, 22053 => 33437, 22054 => 26525,
+    22055 => 25903, 22056 => 21553, 22057 => 34584, 22058 => 30693, 22059 => 32930,
+    22060 => 33026, 22061 => 27713, 22062 => 20043, 22063 => 32455, 22064 => 32844,
+    22065 => 30452, 22066 => 26893, 22067 => 27542, 22068 => 25191, 22069 => 20540,
+    22070 => 20356, 22071 => 22336, 22072 => 25351, 22073 => 27490, 22074 => 36286,
+    22075 => 21482, 22076 => 26088, 22077 => 32440, 22078 => 24535, 22079 => 25370,
+    22080 => 25527, 22081 => 33267, 22082 => 33268, 22083 => 32622, 22084 => 24092,
+    22085 => 23769, 22086 => 21046, 22087 => 26234, 22088 => 31209, 22089 => 31258,
+    22090 => 36136, 22091 => 28825, 22092 => 30164, 22093 => 28382, 22094 => 27835,
+    22095 => 31378, 22096 => 20013, 22097 => 30405, 22098 => 24544, 22099 => 38047,
+    22100 => 34935, 22101 => 32456, 22102 => 31181, 22103 => 32959, 22104 => 37325,
+    22105 => 20210, 22106 => 20247, 22107 => 33311, 22108 => 21608, 22109 => 24030,
+    22110 => 27954, 22111 => 35788, 22112 => 31909, 22113 => 36724, 22114 => 32920,
+    22115 => 24090, 22116 => 21650, 22117 => 30385, 22118 => 23449, 22119 => 26172,
+    22120 => 39588, 22121 => 29664, 22122 => 26666, 22123 => 34523, 22124 => 26417,
+    22125 => 29482, 22126 => 35832, 22127 => 35803, 22128 => 36880, 22129 => 31481,
+    22130 => 28891, 22131 => 29038, 22132 => 25284, 22133 => 30633, 22134 => 22065,
+    22135 => 20027, 22136 => 33879, 22137 => 26609, 22138 => 21161, 22139 => 34496,
+    22140 => 36142, 22141 => 38136, 22142 => 31569, 22305 => 20303, 22306 => 27880,
+    22307 => 31069, 22308 => 39547, 22309 => 25235, 22310 => 29226, 22311 => 25341,
+    22312 => 19987, 22313 => 30742, 22314 => 36716, 22315 => 25776, 22316 => 36186,
+    22317 => 31686, 22318 => 26729, 22319 => 24196, 22320 => 35013, 22321 => 22918,
+    22322 => 25758, 22323 => 22766, 22324 => 29366, 22325 => 26894, 22326 => 38181,
+    22327 => 36861, 22328 => 36184, 22329 => 22368, 22330 => 32512, 22331 => 35846,
+    22332 => 20934, 22333 => 25417, 22334 => 25305, 22335 => 21331, 22336 => 26700,
+    22337 => 29730, 22338 => 33537, 22339 => 37196, 22340 => 21828, 22341 => 30528,
+    22342 => 28796, 22343 => 27978, 22344 => 20857, 22345 => 21672, 22346 => 36164,
+    22347 => 23039, 22348 => 28363, 22349 => 28100, 22350 => 23388, 22351 => 32043,
+    22352 => 20180, 22353 => 31869, 22354 => 28371, 22355 => 23376, 22356 => 33258,
+    22357 => 28173, 22358 => 23383, 22359 => 39683, 22360 => 26837, 22361 => 36394,
+    22362 => 23447, 22363 => 32508, 22364 => 24635, 22365 => 32437, 22366 => 37049,
+    22367 => 36208, 22368 => 22863, 22369 => 25549, 22370 => 31199, 22371 => 36275,
+    22372 => 21330, 22373 => 26063, 22374 => 31062, 22375 => 35781, 22376 => 38459,
+    22377 => 32452, 22378 => 38075, 22379 => 32386, 22380 => 22068, 22381 => 37257,
+    22382 => 26368, 22383 => 32618, 22384 => 23562, 22385 => 36981, 22386 => 26152,
+    22387 => 24038, 22388 => 20304, 22389 => 26590, 22390 => 20570, 22391 => 20316,
+    22392 => 22352, 22393 => 24231, 22561 => 20109, 22562 => 19980, 22563 => 20800,
+    22564 => 19984, 22565 => 24319, 22566 => 21317, 22567 => 19989, 22568 => 20120,
+    22569 => 19998, 22570 => 39730, 22571 => 23404, 22572 => 22121, 22573 => 20008,
+    22574 => 31162, 22575 => 20031, 22576 => 21269, 22577 => 20039, 22578 => 22829,
+    22579 => 29243, 22580 => 21358, 22581 => 27664, 22582 => 22239, 22583 => 32996,
+    22584 => 39319, 22585 => 27603, 22586 => 30590, 22587 => 40727, 22588 => 20022,
+    22589 => 20127, 22590 => 40720, 22591 => 20060, 22592 => 20073, 22593 => 20115,
+    22594 => 33416, 22595 => 23387, 22596 => 21868, 22597 => 22031, 22598 => 20164,
+    22599 => 21389, 22600 => 21405, 22601 => 21411, 22602 => 21413, 22603 => 21422,
+    22604 => 38757, 22605 => 36189, 22606 => 21274, 22607 => 21493, 22608 => 21286,
+    22609 => 21294, 22610 => 21310, 22611 => 36188, 22612 => 21350, 22613 => 21347,
+    22614 => 20994, 22615 => 21000, 22616 => 21006, 22617 => 21037, 22618 => 21043,
+    22619 => 21055, 22620 => 21056, 22621 => 21068, 22622 => 21086, 22623 => 21089,
+    22624 => 21084, 22625 => 33967, 22626 => 21117, 22627 => 21122, 22628 => 21121,
+    22629 => 21136, 22630 => 21139, 22631 => 20866, 22632 => 32596, 22633 => 20155,
+    22634 => 20163, 22635 => 20169, 22636 => 20162, 22637 => 20200, 22638 => 20193,
+    22639 => 20203, 22640 => 20190, 22641 => 20251, 22642 => 20211, 22643 => 20258,
+    22644 => 20324, 22645 => 20213, 22646 => 20261, 22647 => 20263, 22648 => 20233,
+    22649 => 20267, 22650 => 20318, 22651 => 20327, 22652 => 25912, 22653 => 20314,
+    22654 => 20317, 22817 => 20319, 22818 => 20311, 22819 => 20274, 22820 => 20285,
+    22821 => 20342, 22822 => 20340, 22823 => 20369, 22824 => 20361, 22825 => 20355,
+    22826 => 20367, 22827 => 20350, 22828 => 20347, 22829 => 20394, 22830 => 20348,
+    22831 => 20396, 22832 => 20372, 22833 => 20454, 22834 => 20456, 22835 => 20458,
+    22836 => 20421, 22837 => 20442, 22838 => 20451, 22839 => 20444, 22840 => 20433,
+    22841 => 20447, 22842 => 20472, 22843 => 20521, 22844 => 20556, 22845 => 20467,
+    22846 => 20524, 22847 => 20495, 22848 => 20526, 22849 => 20525, 22850 => 20478,
+    22851 => 20508, 22852 => 20492, 22853 => 20517, 22854 => 20520, 22855 => 20606,
+    22856 => 20547, 22857 => 20565, 22858 => 20552, 22859 => 20558, 22860 => 20588,
+    22861 => 20603, 22862 => 20645, 22863 => 20647, 22864 => 20649, 22865 => 20666,
+    22866 => 20694, 22867 => 20742, 22868 => 20717, 22869 => 20716, 22870 => 20710,
+    22871 => 20718, 22872 => 20743, 22873 => 20747, 22874 => 20189, 22875 => 27709,
+    22876 => 20312, 22877 => 20325, 22878 => 20430, 22879 => 40864, 22880 => 27718,
+    22881 => 31860, 22882 => 20846, 22883 => 24061, 22884 => 40649, 22885 => 39320,
+    22886 => 20865, 22887 => 22804, 22888 => 21241, 22889 => 21261, 22890 => 35335,
+    22891 => 21264, 22892 => 20971, 22893 => 22809, 22894 => 20821, 22895 => 20128,
+    22896 => 20822, 22897 => 20147, 22898 => 34926, 22899 => 34980, 22900 => 20149,
+    22901 => 33044, 22902 => 35026, 22903 => 31104, 22904 => 23348, 22905 => 34819,
+    22906 => 32696, 22907 => 20907, 22908 => 20913, 22909 => 20925, 22910 => 20924,
+    23073 => 20935, 23074 => 20886, 23075 => 20898, 23076 => 20901, 23077 => 35744,
+    23078 => 35750, 23079 => 35751, 23080 => 35754, 23081 => 35764, 23082 => 35765,
+    23083 => 35767, 23084 => 35778, 23085 => 35779, 23086 => 35787, 23087 => 35791,
+    23088 => 35790, 23089 => 35794, 23090 => 35795, 23091 => 35796, 23092 => 35798,
+    23093 => 35800, 23094 => 35801, 23095 => 35804, 23096 => 35807, 23097 => 35808,
+    23098 => 35812, 23099 => 35816, 23100 => 35817, 23101 => 35822, 23102 => 35824,
+    23103 => 35827, 23104 => 35830, 23105 => 35833, 23106 => 35836, 23107 => 35839,
+    23108 => 35840, 23109 => 35842, 23110 => 35844, 23111 => 35847, 23112 => 35852,
+    23113 => 35855, 23114 => 35857, 23115 => 35858, 23116 => 35860, 23117 => 35861,
+    23118 => 35862, 23119 => 35865, 23120 => 35867, 23121 => 35864, 23122 => 35869,
+    23123 => 35871, 23124 => 35872, 23125 => 35873, 23126 => 35877, 23127 => 35879,
+    23128 => 35882, 23129 => 35883, 23130 => 35886, 23131 => 35887, 23132 => 35890,
+    23133 => 35891, 23134 => 35893, 23135 => 35894, 23136 => 21353, 23137 => 21370,
+    23138 => 38429, 23139 => 38434, 23140 => 38433, 23141 => 38449, 23142 => 38442,
+    23143 => 38461, 23144 => 38460, 23145 => 38466, 23146 => 38473, 23147 => 38484,
+    23148 => 38495, 23149 => 38503, 23150 => 38508, 23151 => 38514, 23152 => 38516,
+    23153 => 38536, 23154 => 38541, 23155 => 38551, 23156 => 38576, 23157 => 37015,
+    23158 => 37019, 23159 => 37021, 23160 => 37017, 23161 => 37036, 23162 => 37025,
+    23163 => 37044, 23164 => 37043, 23165 => 37046, 23166 => 37050, 23329 => 37048,
+    23330 => 37040, 23331 => 37071, 23332 => 37061, 23333 => 37054, 23334 => 37072,
+    23335 => 37060, 23336 => 37063, 23337 => 37075, 23338 => 37094, 23339 => 37090,
+    23340 => 37084, 23341 => 37079, 23342 => 37083, 23343 => 37099, 23344 => 37103,
+    23345 => 37118, 23346 => 37124, 23347 => 37154, 23348 => 37150, 23349 => 37155,
+    23350 => 37169, 23351 => 37167, 23352 => 37177, 23353 => 37187, 23354 => 37190,
+    23355 => 21005, 23356 => 22850, 23357 => 21154, 23358 => 21164, 23359 => 21165,
+    23360 => 21182, 23361 => 21759, 23362 => 21200, 23363 => 21206, 23364 => 21232,
+    23365 => 21471, 23366 => 29166, 23367 => 30669, 23368 => 24308, 23369 => 20981,
+    23370 => 20988, 23371 => 39727, 23372 => 21430, 23373 => 24321, 23374 => 30042,
+    23375 => 24047, 23376 => 22348, 23377 => 22441, 23378 => 22433, 23379 => 22654,
+    23380 => 22716, 23381 => 22725, 23382 => 22737, 23383 => 22313, 23384 => 22316,
+    23385 => 22314, 23386 => 22323, 23387 => 22329, 23388 => 22318, 23389 => 22319,
+    23390 => 22364, 23391 => 22331, 23392 => 22338, 23393 => 22377, 23394 => 22405,
+    23395 => 22379, 23396 => 22406, 23397 => 22396, 23398 => 22395, 23399 => 22376,
+    23400 => 22381, 23401 => 22390, 23402 => 22387, 23403 => 22445, 23404 => 22436,
+    23405 => 22412, 23406 => 22450, 23407 => 22479, 23408 => 22439, 23409 => 22452,
+    23410 => 22419, 23411 => 22432, 23412 => 22485, 23413 => 22488, 23414 => 22490,
+    23415 => 22489, 23416 => 22482, 23417 => 22456, 23418 => 22516, 23419 => 22511,
+    23420 => 22520, 23421 => 22500, 23422 => 22493, 23585 => 22539, 23586 => 22541,
+    23587 => 22525, 23588 => 22509, 23589 => 22528, 23590 => 22558, 23591 => 22553,
+    23592 => 22596, 23593 => 22560, 23594 => 22629, 23595 => 22636, 23596 => 22657,
+    23597 => 22665, 23598 => 22682, 23599 => 22656, 23600 => 39336, 23601 => 40729,
+    23602 => 25087, 23603 => 33401, 23604 => 33405, 23605 => 33407, 23606 => 33423,
+    23607 => 33418, 23608 => 33448, 23609 => 33412, 23610 => 33422, 23611 => 33425,
+    23612 => 33431, 23613 => 33433, 23614 => 33451, 23615 => 33464, 23616 => 33470,
+    23617 => 33456, 23618 => 33480, 23619 => 33482, 23620 => 33507, 23621 => 33432,
+    23622 => 33463, 23623 => 33454, 23624 => 33483, 23625 => 33484, 23626 => 33473,
+    23627 => 33449, 23628 => 33460, 23629 => 33441, 23630 => 33450, 23631 => 33439,
+    23632 => 33476, 23633 => 33486, 23634 => 33444, 23635 => 33505, 23636 => 33545,
+    23637 => 33527, 23638 => 33508, 23639 => 33551, 23640 => 33543, 23641 => 33500,
+    23642 => 33524, 23643 => 33490, 23644 => 33496, 23645 => 33548, 23646 => 33531,
+    23647 => 33491, 23648 => 33553, 23649 => 33562, 23650 => 33542, 23651 => 33556,
+    23652 => 33557, 23653 => 33504, 23654 => 33493, 23655 => 33564, 23656 => 33617,
+    23657 => 33627, 23658 => 33628, 23659 => 33544, 23660 => 33682, 23661 => 33596,
+    23662 => 33588, 23663 => 33585, 23664 => 33691, 23665 => 33630, 23666 => 33583,
+    23667 => 33615, 23668 => 33607, 23669 => 33603, 23670 => 33631, 23671 => 33600,
+    23672 => 33559, 23673 => 33632, 23674 => 33581, 23675 => 33594, 23676 => 33587,
+    23677 => 33638, 23678 => 33637, 23841 => 33640, 23842 => 33563, 23843 => 33641,
+    23844 => 33644, 23845 => 33642, 23846 => 33645, 23847 => 33646, 23848 => 33712,
+    23849 => 33656, 23850 => 33715, 23851 => 33716, 23852 => 33696, 23853 => 33706,
+    23854 => 33683, 23855 => 33692, 23856 => 33669, 23857 => 33660, 23858 => 33718,
+    23859 => 33705, 23860 => 33661, 23861 => 33720, 23862 => 33659, 23863 => 33688,
+    23864 => 33694, 23865 => 33704, 23866 => 33722, 23867 => 33724, 23868 => 33729,
+    23869 => 33793, 23870 => 33765, 23871 => 33752, 23872 => 22535, 23873 => 33816,
+    23874 => 33803, 23875 => 33757, 23876 => 33789, 23877 => 33750, 23878 => 33820,
+    23879 => 33848, 23880 => 33809, 23881 => 33798, 23882 => 33748, 23883 => 33759,
+    23884 => 33807, 23885 => 33795, 23886 => 33784, 23887 => 33785, 23888 => 33770,
+    23889 => 33733, 23890 => 33728, 23891 => 33830, 23892 => 33776, 23893 => 33761,
+    23894 => 33884, 23895 => 33873, 23896 => 33882, 23897 => 33881, 23898 => 33907,
+    23899 => 33927, 23900 => 33928, 23901 => 33914, 23902 => 33929, 23903 => 33912,
+    23904 => 33852, 23905 => 33862, 23906 => 33897, 23907 => 33910, 23908 => 33932,
+    23909 => 33934, 23910 => 33841, 23911 => 33901, 23912 => 33985, 23913 => 33997,
+    23914 => 34000, 23915 => 34022, 23916 => 33981, 23917 => 34003, 23918 => 33994,
+    23919 => 33983, 23920 => 33978, 23921 => 34016, 23922 => 33953, 23923 => 33977,
+    23924 => 33972, 23925 => 33943, 23926 => 34021, 23927 => 34019, 23928 => 34060,
+    23929 => 29965, 23930 => 34104, 23931 => 34032, 23932 => 34105, 23933 => 34079,
+    23934 => 34106, 24097 => 34134, 24098 => 34107, 24099 => 34047, 24100 => 34044,
+    24101 => 34137, 24102 => 34120, 24103 => 34152, 24104 => 34148, 24105 => 34142,
+    24106 => 34170, 24107 => 30626, 24108 => 34115, 24109 => 34162, 24110 => 34171,
+    24111 => 34212, 24112 => 34216, 24113 => 34183, 24114 => 34191, 24115 => 34169,
+    24116 => 34222, 24117 => 34204, 24118 => 34181, 24119 => 34233, 24120 => 34231,
+    24121 => 34224, 24122 => 34259, 24123 => 34241, 24124 => 34268, 24125 => 34303,
+    24126 => 34343, 24127 => 34309, 24128 => 34345, 24129 => 34326, 24130 => 34364,
+    24131 => 24318, 24132 => 24328, 24133 => 22844, 24134 => 22849, 24135 => 32823,
+    24136 => 22869, 24137 => 22874, 24138 => 22872, 24139 => 21263, 24140 => 23586,
+    24141 => 23589, 24142 => 23596, 24143 => 23604, 24144 => 25164, 24145 => 25194,
+    24146 => 25247, 24147 => 25275, 24148 => 25290, 24149 => 25306, 24150 => 25303,
+    24151 => 25326, 24152 => 25378, 24153 => 25334, 24154 => 25401, 24155 => 25419,
+    24156 => 25411, 24157 => 25517, 24158 => 25590, 24159 => 25457, 24160 => 25466,
+    24161 => 25486, 24162 => 25524, 24163 => 25453, 24164 => 25516, 24165 => 25482,
+    24166 => 25449, 24167 => 25518, 24168 => 25532, 24169 => 25586, 24170 => 25592,
+    24171 => 25568, 24172 => 25599, 24173 => 25540, 24174 => 25566, 24175 => 25550,
+    24176 => 25682, 24177 => 25542, 24178 => 25534, 24179 => 25669, 24180 => 25665,
+    24181 => 25611, 24182 => 25627, 24183 => 25632, 24184 => 25612, 24185 => 25638,
+    24186 => 25633, 24187 => 25694, 24188 => 25732, 24189 => 25709, 24190 => 25750,
+    24353 => 25722, 24354 => 25783, 24355 => 25784, 24356 => 25753, 24357 => 25786,
+    24358 => 25792, 24359 => 25808, 24360 => 25815, 24361 => 25828, 24362 => 25826,
+    24363 => 25865, 24364 => 25893, 24365 => 25902, 24366 => 24331, 24367 => 24530,
+    24368 => 29977, 24369 => 24337, 24370 => 21343, 24371 => 21489, 24372 => 21501,
+    24373 => 21481, 24374 => 21480, 24375 => 21499, 24376 => 21522, 24377 => 21526,
+    24378 => 21510, 24379 => 21579, 24380 => 21586, 24381 => 21587, 24382 => 21588,
+    24383 => 21590, 24384 => 21571, 24385 => 21537, 24386 => 21591, 24387 => 21593,
+    24388 => 21539, 24389 => 21554, 24390 => 21634, 24391 => 21652, 24392 => 21623,
+    24393 => 21617, 24394 => 21604, 24395 => 21658, 24396 => 21659, 24397 => 21636,
+    24398 => 21622, 24399 => 21606, 24400 => 21661, 24401 => 21712, 24402 => 21677,
+    24403 => 21698, 24404 => 21684, 24405 => 21714, 24406 => 21671, 24407 => 21670,
+    24408 => 21715, 24409 => 21716, 24410 => 21618, 24411 => 21667, 24412 => 21717,
+    24413 => 21691, 24414 => 21695, 24415 => 21708, 24416 => 21721, 24417 => 21722,
+    24418 => 21724, 24419 => 21673, 24420 => 21674, 24421 => 21668, 24422 => 21725,
+    24423 => 21711, 24424 => 21726, 24425 => 21787, 24426 => 21735, 24427 => 21792,
+    24428 => 21757, 24429 => 21780, 24430 => 21747, 24431 => 21794, 24432 => 21795,
+    24433 => 21775, 24434 => 21777, 24435 => 21799, 24436 => 21802, 24437 => 21863,
+    24438 => 21903, 24439 => 21941, 24440 => 21833, 24441 => 21869, 24442 => 21825,
+    24443 => 21845, 24444 => 21823, 24445 => 21840, 24446 => 21820, 24609 => 21815,
+    24610 => 21846, 24611 => 21877, 24612 => 21878, 24613 => 21879, 24614 => 21811,
+    24615 => 21808, 24616 => 21852, 24617 => 21899, 24618 => 21970, 24619 => 21891,
+    24620 => 21937, 24621 => 21945, 24622 => 21896, 24623 => 21889, 24624 => 21919,
+    24625 => 21886, 24626 => 21974, 24627 => 21905, 24628 => 21883, 24629 => 21983,
+    24630 => 21949, 24631 => 21950, 24632 => 21908, 24633 => 21913, 24634 => 21994,
+    24635 => 22007, 24636 => 21961, 24637 => 22047, 24638 => 21969, 24639 => 21995,
+    24640 => 21996, 24641 => 21972, 24642 => 21990, 24643 => 21981, 24644 => 21956,
+    24645 => 21999, 24646 => 21989, 24647 => 22002, 24648 => 22003, 24649 => 21964,
+    24650 => 21965, 24651 => 21992, 24652 => 22005, 24653 => 21988, 24654 => 36756,
+    24655 => 22046, 24656 => 22024, 24657 => 22028, 24658 => 22017, 24659 => 22052,
+    24660 => 22051, 24661 => 22014, 24662 => 22016, 24663 => 22055, 24664 => 22061,
+    24665 => 22104, 24666 => 22073, 24667 => 22103, 24668 => 22060, 24669 => 22093,
+    24670 => 22114, 24671 => 22105, 24672 => 22108, 24673 => 22092, 24674 => 22100,
+    24675 => 22150, 24676 => 22116, 24677 => 22129, 24678 => 22123, 24679 => 22139,
+    24680 => 22140, 24681 => 22149, 24682 => 22163, 24683 => 22191, 24684 => 22228,
+    24685 => 22231, 24686 => 22237, 24687 => 22241, 24688 => 22261, 24689 => 22251,
+    24690 => 22265, 24691 => 22271, 24692 => 22276, 24693 => 22282, 24694 => 22281,
+    24695 => 22300, 24696 => 24079, 24697 => 24089, 24698 => 24084, 24699 => 24081,
+    24700 => 24113, 24701 => 24123, 24702 => 24124, 24865 => 24119, 24866 => 24132,
+    24867 => 24148, 24868 => 24155, 24869 => 24158, 24870 => 24161, 24871 => 23692,
+    24872 => 23674, 24873 => 23693, 24874 => 23696, 24875 => 23702, 24876 => 23688,
+    24877 => 23704, 24878 => 23705, 24879 => 23697, 24880 => 23706, 24881 => 23708,
+    24882 => 23733, 24883 => 23714, 24884 => 23741, 24885 => 23724, 24886 => 23723,
+    24887 => 23729, 24888 => 23715, 24889 => 23745, 24890 => 23735, 24891 => 23748,
+    24892 => 23762, 24893 => 23780, 24894 => 23755, 24895 => 23781, 24896 => 23810,
+    24897 => 23811, 24898 => 23847, 24899 => 23846, 24900 => 23854, 24901 => 23844,
+    24902 => 23838, 24903 => 23814, 24904 => 23835, 24905 => 23896, 24906 => 23870,
+    24907 => 23860, 24908 => 23869, 24909 => 23916, 24910 => 23899, 24911 => 23919,
+    24912 => 23901, 24913 => 23915, 24914 => 23883, 24915 => 23882, 24916 => 23913,
+    24917 => 23924, 24918 => 23938, 24919 => 23961, 24920 => 23965, 24921 => 35955,
+    24922 => 23991, 24923 => 24005, 24924 => 24435, 24925 => 24439, 24926 => 24450,
+    24927 => 24455, 24928 => 24457, 24929 => 24460, 24930 => 24469, 24931 => 24473,
+    24932 => 24476, 24933 => 24488, 24934 => 24493, 24935 => 24501, 24936 => 24508,
+    24937 => 34914, 24938 => 24417, 24939 => 29357, 24940 => 29360, 24941 => 29364,
+    24942 => 29367, 24943 => 29368, 24944 => 29379, 24945 => 29377, 24946 => 29390,
+    24947 => 29389, 24948 => 29394, 24949 => 29416, 24950 => 29423, 24951 => 29417,
+    24952 => 29426, 24953 => 29428, 24954 => 29431, 24955 => 29441, 24956 => 29427,
+    24957 => 29443, 24958 => 29434, 25121 => 29435, 25122 => 29463, 25123 => 29459,
+    25124 => 29473, 25125 => 29450, 25126 => 29470, 25127 => 29469, 25128 => 29461,
+    25129 => 29474, 25130 => 29497, 25131 => 29477, 25132 => 29484, 25133 => 29496,
+    25134 => 29489, 25135 => 29520, 25136 => 29517, 25137 => 29527, 25138 => 29536,
+    25139 => 29548, 25140 => 29551, 25141 => 29566, 25142 => 33307, 25143 => 22821,
+    25144 => 39143, 25145 => 22820, 25146 => 22786, 25147 => 39267, 25148 => 39271,
+    25149 => 39272, 25150 => 39273, 25151 => 39274, 25152 => 39275, 25153 => 39276,
+    25154 => 39284, 25155 => 39287, 25156 => 39293, 25157 => 39296, 25158 => 39300,
+    25159 => 39303, 25160 => 39306, 25161 => 39309, 25162 => 39312, 25163 => 39313,
+    25164 => 39315, 25165 => 39316, 25166 => 39317, 25167 => 24192, 25168 => 24209,
+    25169 => 24203, 25170 => 24214, 25171 => 24229, 25172 => 24224, 25173 => 24249,
+    25174 => 24245, 25175 => 24254, 25176 => 24243, 25177 => 36179, 25178 => 24274,
+    25179 => 24273, 25180 => 24283, 25181 => 24296, 25182 => 24298, 25183 => 33210,
+    25184 => 24516, 25185 => 24521, 25186 => 24534, 25187 => 24527, 25188 => 24579,
+    25189 => 24558, 25190 => 24580, 25191 => 24545, 25192 => 24548, 25193 => 24574,
+    25194 => 24581, 25195 => 24582, 25196 => 24554, 25197 => 24557, 25198 => 24568,
+    25199 => 24601, 25200 => 24629, 25201 => 24614, 25202 => 24603, 25203 => 24591,
+    25204 => 24589, 25205 => 24617, 25206 => 24619, 25207 => 24586, 25208 => 24639,
+    25209 => 24609, 25210 => 24696, 25211 => 24697, 25212 => 24699, 25213 => 24698,
+    25214 => 24642, 25377 => 24682, 25378 => 24701, 25379 => 24726, 25380 => 24730,
+    25381 => 24749, 25382 => 24733, 25383 => 24707, 25384 => 24722, 25385 => 24716,
+    25386 => 24731, 25387 => 24812, 25388 => 24763, 25389 => 24753, 25390 => 24797,
+    25391 => 24792, 25392 => 24774, 25393 => 24794, 25394 => 24756, 25395 => 24864,
+    25396 => 24870, 25397 => 24853, 25398 => 24867, 25399 => 24820, 25400 => 24832,
+    25401 => 24846, 25402 => 24875, 25403 => 24906, 25404 => 24949, 25405 => 25004,
+    25406 => 24980, 25407 => 24999, 25408 => 25015, 25409 => 25044, 25410 => 25077,
+    25411 => 24541, 25412 => 38579, 25413 => 38377, 25414 => 38379, 25415 => 38385,
+    25416 => 38387, 25417 => 38389, 25418 => 38390, 25419 => 38396, 25420 => 38398,
+    25421 => 38403, 25422 => 38404, 25423 => 38406, 25424 => 38408, 25425 => 38410,
+    25426 => 38411, 25427 => 38412, 25428 => 38413, 25429 => 38415, 25430 => 38418,
+    25431 => 38421, 25432 => 38422, 25433 => 38423, 25434 => 38425, 25435 => 38426,
+    25436 => 20012, 25437 => 29247, 25438 => 25109, 25439 => 27701, 25440 => 27732,
+    25441 => 27740, 25442 => 27722, 25443 => 27811, 25444 => 27781, 25445 => 27792,
+    25446 => 27796, 25447 => 27788, 25448 => 27752, 25449 => 27753, 25450 => 27764,
+    25451 => 27766, 25452 => 27782, 25453 => 27817, 25454 => 27856, 25455 => 27860,
+    25456 => 27821, 25457 => 27895, 25458 => 27896, 25459 => 27889, 25460 => 27863,
+    25461 => 27826, 25462 => 27872, 25463 => 27862, 25464 => 27898, 25465 => 27883,
+    25466 => 27886, 25467 => 27825, 25468 => 27859, 25469 => 27887, 25470 => 27902,
+    25633 => 27961, 25634 => 27943, 25635 => 27916, 25636 => 27971, 25637 => 27976,
+    25638 => 27911, 25639 => 27908, 25640 => 27929, 25641 => 27918, 25642 => 27947,
+    25643 => 27981, 25644 => 27950, 25645 => 27957, 25646 => 27930, 25647 => 27983,
+    25648 => 27986, 25649 => 27988, 25650 => 27955, 25651 => 28049, 25652 => 28015,
+    25653 => 28062, 25654 => 28064, 25655 => 27998, 25656 => 28051, 25657 => 28052,
+    25658 => 27996, 25659 => 28000, 25660 => 28028, 25661 => 28003, 25662 => 28186,
+    25663 => 28103, 25664 => 28101, 25665 => 28126, 25666 => 28174, 25667 => 28095,
+    25668 => 28128, 25669 => 28177, 25670 => 28134, 25671 => 28125, 25672 => 28121,
+    25673 => 28182, 25674 => 28075, 25675 => 28172, 25676 => 28078, 25677 => 28203,
+    25678 => 28270, 25679 => 28238, 25680 => 28267, 25681 => 28338, 25682 => 28255,
+    25683 => 28294, 25684 => 28243, 25685 => 28244, 25686 => 28210, 25687 => 28197,
+    25688 => 28228, 25689 => 28383, 25690 => 28337, 25691 => 28312, 25692 => 28384,
+    25693 => 28461, 25694 => 28386, 25695 => 28325, 25696 => 28327, 25697 => 28349,
+    25698 => 28347, 25699 => 28343, 25700 => 28375, 25701 => 28340, 25702 => 28367,
+    25703 => 28303, 25704 => 28354, 25705 => 28319, 25706 => 28514, 25707 => 28486,
+    25708 => 28487, 25709 => 28452, 25710 => 28437, 25711 => 28409, 25712 => 28463,
+    25713 => 28470, 25714 => 28491, 25715 => 28532, 25716 => 28458, 25717 => 28425,
+    25718 => 28457, 25719 => 28553, 25720 => 28557, 25721 => 28556, 25722 => 28536,
+    25723 => 28530, 25724 => 28540, 25725 => 28538, 25726 => 28625, 25889 => 28617,
+    25890 => 28583, 25891 => 28601, 25892 => 28598, 25893 => 28610, 25894 => 28641,
+    25895 => 28654, 25896 => 28638, 25897 => 28640, 25898 => 28655, 25899 => 28698,
+    25900 => 28707, 25901 => 28699, 25902 => 28729, 25903 => 28725, 25904 => 28751,
+    25905 => 28766, 25906 => 23424, 25907 => 23428, 25908 => 23445, 25909 => 23443,
+    25910 => 23461, 25911 => 23480, 25912 => 29999, 25913 => 39582, 25914 => 25652,
+    25915 => 23524, 25916 => 23534, 25917 => 35120, 25918 => 23536, 25919 => 36423,
+    25920 => 35591, 25921 => 36790, 25922 => 36819, 25923 => 36821, 25924 => 36837,
+    25925 => 36846, 25926 => 36836, 25927 => 36841, 25928 => 36838, 25929 => 36851,
+    25930 => 36840, 25931 => 36869, 25932 => 36868, 25933 => 36875, 25934 => 36902,
+    25935 => 36881, 25936 => 36877, 25937 => 36886, 25938 => 36897, 25939 => 36917,
+    25940 => 36918, 25941 => 36909, 25942 => 36911, 25943 => 36932, 25944 => 36945,
+    25945 => 36946, 25946 => 36944, 25947 => 36968, 25948 => 36952, 25949 => 36962,
+    25950 => 36955, 25951 => 26297, 25952 => 36980, 25953 => 36989, 25954 => 36994,
+    25955 => 37000, 25956 => 36995, 25957 => 37003, 25958 => 24400, 25959 => 24407,
+    25960 => 24406, 25961 => 24408, 25962 => 23611, 25963 => 21675, 25964 => 23632,
+    25965 => 23641, 25966 => 23409, 25967 => 23651, 25968 => 23654, 25969 => 32700,
+    25970 => 24362, 25971 => 24361, 25972 => 24365, 25973 => 33396, 25974 => 24380,
+    25975 => 39739, 25976 => 23662, 25977 => 22913, 25978 => 22915, 25979 => 22925,
+    25980 => 22953, 25981 => 22954, 25982 => 22947, 26145 => 22935, 26146 => 22986,
+    26147 => 22955, 26148 => 22942, 26149 => 22948, 26150 => 22994, 26151 => 22962,
+    26152 => 22959, 26153 => 22999, 26154 => 22974, 26155 => 23045, 26156 => 23046,
+    26157 => 23005, 26158 => 23048, 26159 => 23011, 26160 => 23000, 26161 => 23033,
+    26162 => 23052, 26163 => 23049, 26164 => 23090, 26165 => 23092, 26166 => 23057,
+    26167 => 23075, 26168 => 23059, 26169 => 23104, 26170 => 23143, 26171 => 23114,
+    26172 => 23125, 26173 => 23100, 26174 => 23138, 26175 => 23157, 26176 => 33004,
+    26177 => 23210, 26178 => 23195, 26179 => 23159, 26180 => 23162, 26181 => 23230,
+    26182 => 23275, 26183 => 23218, 26184 => 23250, 26185 => 23252, 26186 => 23224,
+    26187 => 23264, 26188 => 23267, 26189 => 23281, 26190 => 23254, 26191 => 23270,
+    26192 => 23256, 26193 => 23260, 26194 => 23305, 26195 => 23319, 26196 => 23318,
+    26197 => 23346, 26198 => 23351, 26199 => 23360, 26200 => 23573, 26201 => 23580,
+    26202 => 23386, 26203 => 23397, 26204 => 23411, 26205 => 23377, 26206 => 23379,
+    26207 => 23394, 26208 => 39541, 26209 => 39543, 26210 => 39544, 26211 => 39546,
+    26212 => 39551, 26213 => 39549, 26214 => 39552, 26215 => 39553, 26216 => 39557,
+    26217 => 39560, 26218 => 39562, 26219 => 39568, 26220 => 39570, 26221 => 39571,
+    26222 => 39574, 26223 => 39576, 26224 => 39579, 26225 => 39580, 26226 => 39581,
+    26227 => 39583, 26228 => 39584, 26229 => 39586, 26230 => 39587, 26231 => 39589,
+    26232 => 39591, 26233 => 32415, 26234 => 32417, 26235 => 32419, 26236 => 32421,
+    26237 => 32424, 26238 => 32425, 26401 => 32429, 26402 => 32432, 26403 => 32446,
+    26404 => 32448, 26405 => 32449, 26406 => 32450, 26407 => 32457, 26408 => 32459,
+    26409 => 32460, 26410 => 32464, 26411 => 32468, 26412 => 32471, 26413 => 32475,
+    26414 => 32480, 26415 => 32481, 26416 => 32488, 26417 => 32491, 26418 => 32494,
+    26419 => 32495, 26420 => 32497, 26421 => 32498, 26422 => 32525, 26423 => 32502,
+    26424 => 32506, 26425 => 32507, 26426 => 32510, 26427 => 32513, 26428 => 32514,
+    26429 => 32515, 26430 => 32519, 26431 => 32520, 26432 => 32523, 26433 => 32524,
+    26434 => 32527, 26435 => 32529, 26436 => 32530, 26437 => 32535, 26438 => 32537,
+    26439 => 32540, 26440 => 32539, 26441 => 32543, 26442 => 32545, 26443 => 32546,
+    26444 => 32547, 26445 => 32548, 26446 => 32549, 26447 => 32550, 26448 => 32551,
+    26449 => 32554, 26450 => 32555, 26451 => 32556, 26452 => 32557, 26453 => 32559,
+    26454 => 32560, 26455 => 32561, 26456 => 32562, 26457 => 32563, 26458 => 32565,
+    26459 => 24186, 26460 => 30079, 26461 => 24027, 26462 => 30014, 26463 => 37013,
+    26464 => 29582, 26465 => 29585, 26466 => 29614, 26467 => 29602, 26468 => 29599,
+    26469 => 29647, 26470 => 29634, 26471 => 29649, 26472 => 29623, 26473 => 29619,
+    26474 => 29632, 26475 => 29641, 26476 => 29640, 26477 => 29669, 26478 => 29657,
+    26479 => 39036, 26480 => 29706, 26481 => 29673, 26482 => 29671, 26483 => 29662,
+    26484 => 29626, 26485 => 29682, 26486 => 29711, 26487 => 29738, 26488 => 29787,
+    26489 => 29734, 26490 => 29733, 26491 => 29736, 26492 => 29744, 26493 => 29742,
+    26494 => 29740, 26657 => 29723, 26658 => 29722, 26659 => 29761, 26660 => 29788,
+    26661 => 29783, 26662 => 29781, 26663 => 29785, 26664 => 29815, 26665 => 29805,
+    26666 => 29822, 26667 => 29852, 26668 => 29838, 26669 => 29824, 26670 => 29825,
+    26671 => 29831, 26672 => 29835, 26673 => 29854, 26674 => 29864, 26675 => 29865,
+    26676 => 29840, 26677 => 29863, 26678 => 29906, 26679 => 29882, 26680 => 38890,
+    26681 => 38891, 26682 => 38892, 26683 => 26444, 26684 => 26451, 26685 => 26462,
+    26686 => 26440, 26687 => 26473, 26688 => 26533, 26689 => 26503, 26690 => 26474,
+    26691 => 26483, 26692 => 26520, 26693 => 26535, 26694 => 26485, 26695 => 26536,
+    26696 => 26526, 26697 => 26541, 26698 => 26507, 26699 => 26487, 26700 => 26492,
+    26701 => 26608, 26702 => 26633, 26703 => 26584, 26704 => 26634, 26705 => 26601,
+    26706 => 26544, 26707 => 26636, 26708 => 26585, 26709 => 26549, 26710 => 26586,
+    26711 => 26547, 26712 => 26589, 26713 => 26624, 26714 => 26563, 26715 => 26552,
+    26716 => 26594, 26717 => 26638, 26718 => 26561, 26719 => 26621, 26720 => 26674,
+    26721 => 26675, 26722 => 26720, 26723 => 26721, 26724 => 26702, 26725 => 26722,
+    26726 => 26692, 26727 => 26724, 26728 => 26755, 26729 => 26653, 26730 => 26709,
+    26731 => 26726, 26732 => 26689, 26733 => 26727, 26734 => 26688, 26735 => 26686,
+    26736 => 26698, 26737 => 26697, 26738 => 26665, 26739 => 26805, 26740 => 26767,
+    26741 => 26740, 26742 => 26743, 26743 => 26771, 26744 => 26731, 26745 => 26818,
+    26746 => 26990, 26747 => 26876, 26748 => 26911, 26749 => 26912, 26750 => 26873,
+    26913 => 26916, 26914 => 26864, 26915 => 26891, 26916 => 26881, 26917 => 26967,
+    26918 => 26851, 26919 => 26896, 26920 => 26993, 26921 => 26937, 26922 => 26976,
+    26923 => 26946, 26924 => 26973, 26925 => 27012, 26926 => 26987, 26927 => 27008,
+    26928 => 27032, 26929 => 27000, 26930 => 26932, 26931 => 27084, 26932 => 27015,
+    26933 => 27016, 26934 => 27086, 26935 => 27017, 26936 => 26982, 26937 => 26979,
+    26938 => 27001, 26939 => 27035, 26940 => 27047, 26941 => 27067, 26942 => 27051,
+    26943 => 27053, 26944 => 27092, 26945 => 27057, 26946 => 27073, 26947 => 27082,
+    26948 => 27103, 26949 => 27029, 26950 => 27104, 26951 => 27021, 26952 => 27135,
+    26953 => 27183, 26954 => 27117, 26955 => 27159, 26956 => 27160, 26957 => 27237,
+    26958 => 27122, 26959 => 27204, 26960 => 27198, 26961 => 27296, 26962 => 27216,
+    26963 => 27227, 26964 => 27189, 26965 => 27278, 26966 => 27257, 26967 => 27197,
+    26968 => 27176, 26969 => 27224, 26970 => 27260, 26971 => 27281, 26972 => 27280,
+    26973 => 27305, 26974 => 27287, 26975 => 27307, 26976 => 29495, 26977 => 29522,
+    26978 => 27521, 26979 => 27522, 26980 => 27527, 26981 => 27524, 26982 => 27538,
+    26983 => 27539, 26984 => 27533, 26985 => 27546, 26986 => 27547, 26987 => 27553,
+    26988 => 27562, 26989 => 36715, 26990 => 36717, 26991 => 36721, 26992 => 36722,
+    26993 => 36723, 26994 => 36725, 26995 => 36726, 26996 => 36728, 26997 => 36727,
+    26998 => 36729, 26999 => 36730, 27000 => 36732, 27001 => 36734, 27002 => 36737,
+    27003 => 36738, 27004 => 36740, 27005 => 36743, 27006 => 36747, 27169 => 36749,
+    27170 => 36750, 27171 => 36751, 27172 => 36760, 27173 => 36762, 27174 => 36558,
+    27175 => 25099, 27176 => 25111, 27177 => 25115, 27178 => 25119, 27179 => 25122,
+    27180 => 25121, 27181 => 25125, 27182 => 25124, 27183 => 25132, 27184 => 33255,
+    27185 => 29935, 27186 => 29940, 27187 => 29951, 27188 => 29967, 27189 => 29969,
+    27190 => 29971, 27191 => 25908, 27192 => 26094, 27193 => 26095, 27194 => 26096,
+    27195 => 26122, 27196 => 26137, 27197 => 26482, 27198 => 26115, 27199 => 26133,
+    27200 => 26112, 27201 => 28805, 27202 => 26359, 27203 => 26141, 27204 => 26164,
+    27205 => 26161, 27206 => 26166, 27207 => 26165, 27208 => 32774, 27209 => 26207,
+    27210 => 26196, 27211 => 26177, 27212 => 26191, 27213 => 26198, 27214 => 26209,
+    27215 => 26199, 27216 => 26231, 27217 => 26244, 27218 => 26252, 27219 => 26279,
+    27220 => 26269, 27221 => 26302, 27222 => 26331, 27223 => 26332, 27224 => 26342,
+    27225 => 26345, 27226 => 36146, 27227 => 36147, 27228 => 36150, 27229 => 36155,
+    27230 => 36157, 27231 => 36160, 27232 => 36165, 27233 => 36166, 27234 => 36168,
+    27235 => 36169, 27236 => 36167, 27237 => 36173, 27238 => 36181, 27239 => 36185,
+    27240 => 35271, 27241 => 35274, 27242 => 35275, 27243 => 35276, 27244 => 35278,
+    27245 => 35279, 27246 => 35280, 27247 => 35281, 27248 => 29294, 27249 => 29343,
+    27250 => 29277, 27251 => 29286, 27252 => 29295, 27253 => 29310, 27254 => 29311,
+    27255 => 29316, 27256 => 29323, 27257 => 29325, 27258 => 29327, 27259 => 29330,
+    27260 => 25352, 27261 => 25394, 27262 => 25520, 27425 => 25663, 27426 => 25816,
+    27427 => 32772, 27428 => 27626, 27429 => 27635, 27430 => 27645, 27431 => 27637,
+    27432 => 27641, 27433 => 27653, 27434 => 27655, 27435 => 27654, 27436 => 27661,
+    27437 => 27669, 27438 => 27672, 27439 => 27673, 27440 => 27674, 27441 => 27681,
+    27442 => 27689, 27443 => 27684, 27444 => 27690, 27445 => 27698, 27446 => 25909,
+    27447 => 25941, 27448 => 25963, 27449 => 29261, 27450 => 29266, 27451 => 29270,
+    27452 => 29232, 27453 => 34402, 27454 => 21014, 27455 => 32927, 27456 => 32924,
+    27457 => 32915, 27458 => 32956, 27459 => 26378, 27460 => 32957, 27461 => 32945,
+    27462 => 32939, 27463 => 32941, 27464 => 32948, 27465 => 32951, 27466 => 32999,
+    27467 => 33000, 27468 => 33001, 27469 => 33002, 27470 => 32987, 27471 => 32962,
+    27472 => 32964, 27473 => 32985, 27474 => 32973, 27475 => 32983, 27476 => 26384,
+    27477 => 32989, 27478 => 33003, 27479 => 33009, 27480 => 33012, 27481 => 33005,
+    27482 => 33037, 27483 => 33038, 27484 => 33010, 27485 => 33020, 27486 => 26389,
+    27487 => 33042, 27488 => 35930, 27489 => 33078, 27490 => 33054, 27491 => 33068,
+    27492 => 33048, 27493 => 33074, 27494 => 33096, 27495 => 33100, 27496 => 33107,
+    27497 => 33140, 27498 => 33113, 27499 => 33114, 27500 => 33137, 27501 => 33120,
+    27502 => 33129, 27503 => 33148, 27504 => 33149, 27505 => 33133, 27506 => 33127,
+    27507 => 22605, 27508 => 23221, 27509 => 33160, 27510 => 33154, 27511 => 33169,
+    27512 => 28373, 27513 => 33187, 27514 => 33194, 27515 => 33228, 27516 => 26406,
+    27517 => 33226, 27518 => 33211, 27681 => 33217, 27682 => 33190, 27683 => 27428,
+    27684 => 27447, 27685 => 27449, 27686 => 27459, 27687 => 27462, 27688 => 27481,
+    27689 => 39121, 27690 => 39122, 27691 => 39123, 27692 => 39125, 27693 => 39129,
+    27694 => 39130, 27695 => 27571, 27696 => 24384, 27697 => 27586, 27698 => 35315,
+    27699 => 26000, 27700 => 40785, 27701 => 26003, 27702 => 26044, 27703 => 26054,
+    27704 => 26052, 27705 => 26051, 27706 => 26060, 27707 => 26062, 27708 => 26066,
+    27709 => 26070, 27710 => 28800, 27711 => 28828, 27712 => 28822, 27713 => 28829,
+    27714 => 28859, 27715 => 28864, 27716 => 28855, 27717 => 28843, 27718 => 28849,
+    27719 => 28904, 27720 => 28874, 27721 => 28944, 27722 => 28947, 27723 => 28950,
+    27724 => 28975, 27725 => 28977, 27726 => 29043, 27727 => 29020, 27728 => 29032,
+    27729 => 28997, 27730 => 29042, 27731 => 29002, 27732 => 29048, 27733 => 29050,
+    27734 => 29080, 27735 => 29107, 27736 => 29109, 27737 => 29096, 27738 => 29088,
+    27739 => 29152, 27740 => 29140, 27741 => 29159, 27742 => 29177, 27743 => 29213,
+    27744 => 29224, 27745 => 28780, 27746 => 28952, 27747 => 29030, 27748 => 29113,
+    27749 => 25150, 27750 => 25149, 27751 => 25155, 27752 => 25160, 27753 => 25161,
+    27754 => 31035, 27755 => 31040, 27756 => 31046, 27757 => 31049, 27758 => 31067,
+    27759 => 31068, 27760 => 31059, 27761 => 31066, 27762 => 31074, 27763 => 31063,
+    27764 => 31072, 27765 => 31087, 27766 => 31079, 27767 => 31098, 27768 => 31109,
+    27769 => 31114, 27770 => 31130, 27771 => 31143, 27772 => 31155, 27773 => 24529,
+    27774 => 24528, 27937 => 24636, 27938 => 24669, 27939 => 24666, 27940 => 24679,
+    27941 => 24641, 27942 => 24665, 27943 => 24675, 27944 => 24747, 27945 => 24838,
+    27946 => 24845, 27947 => 24925, 27948 => 25001, 27949 => 24989, 27950 => 25035,
+    27951 => 25041, 27952 => 25094, 27953 => 32896, 27954 => 32895, 27955 => 27795,
+    27956 => 27894, 27957 => 28156, 27958 => 30710, 27959 => 30712, 27960 => 30720,
+    27961 => 30729, 27962 => 30743, 27963 => 30744, 27964 => 30737, 27965 => 26027,
+    27966 => 30765, 27967 => 30748, 27968 => 30749, 27969 => 30777, 27970 => 30778,
+    27971 => 30779, 27972 => 30751, 27973 => 30780, 27974 => 30757, 27975 => 30764,
+    27976 => 30755, 27977 => 30761, 27978 => 30798, 27979 => 30829, 27980 => 30806,
+    27981 => 30807, 27982 => 30758, 27983 => 30800, 27984 => 30791, 27985 => 30796,
+    27986 => 30826, 27987 => 30875, 27988 => 30867, 27989 => 30874, 27990 => 30855,
+    27991 => 30876, 27992 => 30881, 27993 => 30883, 27994 => 30898, 27995 => 30905,
+    27996 => 30885, 27997 => 30932, 27998 => 30937, 27999 => 30921, 28000 => 30956,
+    28001 => 30962, 28002 => 30981, 28003 => 30964, 28004 => 30995, 28005 => 31012,
+    28006 => 31006, 28007 => 31028, 28008 => 40859, 28009 => 40697, 28010 => 40699,
+    28011 => 40700, 28012 => 30449, 28013 => 30468, 28014 => 30477, 28015 => 30457,
+    28016 => 30471, 28017 => 30472, 28018 => 30490, 28019 => 30498, 28020 => 30489,
+    28021 => 30509, 28022 => 30502, 28023 => 30517, 28024 => 30520, 28025 => 30544,
+    28026 => 30545, 28027 => 30535, 28028 => 30531, 28029 => 30554, 28030 => 30568,
+    28193 => 30562, 28194 => 30565, 28195 => 30591, 28196 => 30605, 28197 => 30589,
+    28198 => 30592, 28199 => 30604, 28200 => 30609, 28201 => 30623, 28202 => 30624,
+    28203 => 30640, 28204 => 30645, 28205 => 30653, 28206 => 30010, 28207 => 30016,
+    28208 => 30030, 28209 => 30027, 28210 => 30024, 28211 => 30043, 28212 => 30066,
+    28213 => 30073, 28214 => 30083, 28215 => 32600, 28216 => 32609, 28217 => 32607,
+    28218 => 35400, 28219 => 32616, 28220 => 32628, 28221 => 32625, 28222 => 32633,
+    28223 => 32641, 28224 => 32638, 28225 => 30413, 28226 => 30437, 28227 => 34866,
+    28228 => 38021, 28229 => 38022, 28230 => 38023, 28231 => 38027, 28232 => 38026,
+    28233 => 38028, 28234 => 38029, 28235 => 38031, 28236 => 38032, 28237 => 38036,
+    28238 => 38039, 28239 => 38037, 28240 => 38042, 28241 => 38043, 28242 => 38044,
+    28243 => 38051, 28244 => 38052, 28245 => 38059, 28246 => 38058, 28247 => 38061,
+    28248 => 38060, 28249 => 38063, 28250 => 38064, 28251 => 38066, 28252 => 38068,
+    28253 => 38070, 28254 => 38071, 28255 => 38072, 28256 => 38073, 28257 => 38074,
+    28258 => 38076, 28259 => 38077, 28260 => 38079, 28261 => 38084, 28262 => 38088,
+    28263 => 38089, 28264 => 38090, 28265 => 38091, 28266 => 38092, 28267 => 38093,
+    28268 => 38094, 28269 => 38096, 28270 => 38097, 28271 => 38098, 28272 => 38101,
+    28273 => 38102, 28274 => 38103, 28275 => 38105, 28276 => 38104, 28277 => 38107,
+    28278 => 38110, 28279 => 38111, 28280 => 38112, 28281 => 38114, 28282 => 38116,
+    28283 => 38117, 28284 => 38119, 28285 => 38120, 28286 => 38122, 28449 => 38121,
+    28450 => 38123, 28451 => 38126, 28452 => 38127, 28453 => 38131, 28454 => 38132,
+    28455 => 38133, 28456 => 38135, 28457 => 38137, 28458 => 38140, 28459 => 38141,
+    28460 => 38143, 28461 => 38147, 28462 => 38146, 28463 => 38150, 28464 => 38151,
+    28465 => 38153, 28466 => 38154, 28467 => 38157, 28468 => 38158, 28469 => 38159,
+    28470 => 38162, 28471 => 38163, 28472 => 38164, 28473 => 38165, 28474 => 38166,
+    28475 => 38168, 28476 => 38171, 28477 => 38173, 28478 => 38174, 28479 => 38175,
+    28480 => 38178, 28481 => 38186, 28482 => 38187, 28483 => 38185, 28484 => 38188,
+    28485 => 38193, 28486 => 38194, 28487 => 38196, 28488 => 38198, 28489 => 38199,
+    28490 => 38200, 28491 => 38204, 28492 => 38206, 28493 => 38207, 28494 => 38210,
+    28495 => 38197, 28496 => 38212, 28497 => 38213, 28498 => 38214, 28499 => 38217,
+    28500 => 38220, 28501 => 38222, 28502 => 38223, 28503 => 38226, 28504 => 38227,
+    28505 => 38228, 28506 => 38230, 28507 => 38231, 28508 => 38232, 28509 => 38233,
+    28510 => 38235, 28511 => 38238, 28512 => 38239, 28513 => 38237, 28514 => 38241,
+    28515 => 38242, 28516 => 38244, 28517 => 38245, 28518 => 38246, 28519 => 38247,
+    28520 => 38248, 28521 => 38249, 28522 => 38250, 28523 => 38251, 28524 => 38252,
+    28525 => 38255, 28526 => 38257, 28527 => 38258, 28528 => 38259, 28529 => 38202,
+    28530 => 30695, 28531 => 30700, 28532 => 38601, 28533 => 31189, 28534 => 31213,
+    28535 => 31203, 28536 => 31211, 28537 => 31238, 28538 => 23879, 28539 => 31235,
+    28540 => 31234, 28541 => 31262, 28542 => 31252, 28705 => 31289, 28706 => 31287,
+    28707 => 31313, 28708 => 40655, 28709 => 39333, 28710 => 31344, 28711 => 30344,
+    28712 => 30350, 28713 => 30355, 28714 => 30361, 28715 => 30372, 28716 => 29918,
+    28717 => 29920, 28718 => 29996, 28719 => 40480, 28720 => 40482, 28721 => 40488,
+    28722 => 40489, 28723 => 40490, 28724 => 40491, 28725 => 40492, 28726 => 40498,
+    28727 => 40497, 28728 => 40502, 28729 => 40504, 28730 => 40503, 28731 => 40505,
+    28732 => 40506, 28733 => 40510, 28734 => 40513, 28735 => 40514, 28736 => 40516,
+    28737 => 40518, 28738 => 40519, 28739 => 40520, 28740 => 40521, 28741 => 40523,
+    28742 => 40524, 28743 => 40526, 28744 => 40529, 28745 => 40533, 28746 => 40535,
+    28747 => 40538, 28748 => 40539, 28749 => 40540, 28750 => 40542, 28751 => 40547,
+    28752 => 40550, 28753 => 40551, 28754 => 40552, 28755 => 40553, 28756 => 40554,
+    28757 => 40555, 28758 => 40556, 28759 => 40561, 28760 => 40557, 28761 => 40563,
+    28762 => 30098, 28763 => 30100, 28764 => 30102, 28765 => 30112, 28766 => 30109,
+    28767 => 30124, 28768 => 30115, 28769 => 30131, 28770 => 30132, 28771 => 30136,
+    28772 => 30148, 28773 => 30129, 28774 => 30128, 28775 => 30147, 28776 => 30146,
+    28777 => 30166, 28778 => 30157, 28779 => 30179, 28780 => 30184, 28781 => 30182,
+    28782 => 30180, 28783 => 30187, 28784 => 30183, 28785 => 30211, 28786 => 30193,
+    28787 => 30204, 28788 => 30207, 28789 => 30224, 28790 => 30208, 28791 => 30213,
+    28792 => 30220, 28793 => 30231, 28794 => 30218, 28795 => 30245, 28796 => 30232,
+    28797 => 30229, 28798 => 30233, 28961 => 30235, 28962 => 30268, 28963 => 30242,
+    28964 => 30240, 28965 => 30272, 28966 => 30253, 28967 => 30256, 28968 => 30271,
+    28969 => 30261, 28970 => 30275, 28971 => 30270, 28972 => 30259, 28973 => 30285,
+    28974 => 30302, 28975 => 30292, 28976 => 30300, 28977 => 30294, 28978 => 30315,
+    28979 => 30319, 28980 => 32714, 28981 => 31462, 28982 => 31352, 28983 => 31353,
+    28984 => 31360, 28985 => 31366, 28986 => 31368, 28987 => 31381, 28988 => 31398,
+    28989 => 31392, 28990 => 31404, 28991 => 31400, 28992 => 31405, 28993 => 31411,
+    28994 => 34916, 28995 => 34921, 28996 => 34930, 28997 => 34941, 28998 => 34943,
+    28999 => 34946, 29000 => 34978, 29001 => 35014, 29002 => 34999, 29003 => 35004,
+    29004 => 35017, 29005 => 35042, 29006 => 35022, 29007 => 35043, 29008 => 35045,
+    29009 => 35057, 29010 => 35098, 29011 => 35068, 29012 => 35048, 29013 => 35070,
+    29014 => 35056, 29015 => 35105, 29016 => 35097, 29017 => 35091, 29018 => 35099,
+    29019 => 35082, 29020 => 35124, 29021 => 35115, 29022 => 35126, 29023 => 35137,
+    29024 => 35174, 29025 => 35195, 29026 => 30091, 29027 => 32997, 29028 => 30386,
+    29029 => 30388, 29030 => 30684, 29031 => 32786, 29032 => 32788, 29033 => 32790,
+    29034 => 32796, 29035 => 32800, 29036 => 32802, 29037 => 32805, 29038 => 32806,
+    29039 => 32807, 29040 => 32809, 29041 => 32808, 29042 => 32817, 29043 => 32779,
+    29044 => 32821, 29045 => 32835, 29046 => 32838, 29047 => 32845, 29048 => 32850,
+    29049 => 32873, 29050 => 32881, 29051 => 35203, 29052 => 39032, 29053 => 39040,
+    29054 => 39043, 29217 => 39049, 29218 => 39052, 29219 => 39053, 29220 => 39055,
+    29221 => 39060, 29222 => 39066, 29223 => 39067, 29224 => 39070, 29225 => 39071,
+    29226 => 39073, 29227 => 39074, 29228 => 39077, 29229 => 39078, 29230 => 34381,
+    29231 => 34388, 29232 => 34412, 29233 => 34414, 29234 => 34431, 29235 => 34426,
+    29236 => 34428, 29237 => 34427, 29238 => 34472, 29239 => 34445, 29240 => 34443,
+    29241 => 34476, 29242 => 34461, 29243 => 34471, 29244 => 34467, 29245 => 34474,
+    29246 => 34451, 29247 => 34473, 29248 => 34486, 29249 => 34500, 29250 => 34485,
+    29251 => 34510, 29252 => 34480, 29253 => 34490, 29254 => 34481, 29255 => 34479,
+    29256 => 34505, 29257 => 34511, 29258 => 34484, 29259 => 34537, 29260 => 34545,
+    29261 => 34546, 29262 => 34541, 29263 => 34547, 29264 => 34512, 29265 => 34579,
+    29266 => 34526, 29267 => 34548, 29268 => 34527, 29269 => 34520, 29270 => 34513,
+    29271 => 34563, 29272 => 34567, 29273 => 34552, 29274 => 34568, 29275 => 34570,
+    29276 => 34573, 29277 => 34569, 29278 => 34595, 29279 => 34619, 29280 => 34590,
+    29281 => 34597, 29282 => 34606, 29283 => 34586, 29284 => 34622, 29285 => 34632,
+    29286 => 34612, 29287 => 34609, 29288 => 34601, 29289 => 34615, 29290 => 34623,
+    29291 => 34690, 29292 => 34594, 29293 => 34685, 29294 => 34686, 29295 => 34683,
+    29296 => 34656, 29297 => 34672, 29298 => 34636, 29299 => 34670, 29300 => 34699,
+    29301 => 34643, 29302 => 34659, 29303 => 34684, 29304 => 34660, 29305 => 34649,
+    29306 => 34661, 29307 => 34707, 29308 => 34735, 29309 => 34728, 29310 => 34770,
+    29473 => 34758, 29474 => 34696, 29475 => 34693, 29476 => 34733, 29477 => 34711,
+    29478 => 34691, 29479 => 34731, 29480 => 34789, 29481 => 34732, 29482 => 34741,
+    29483 => 34739, 29484 => 34763, 29485 => 34771, 29486 => 34749, 29487 => 34769,
+    29488 => 34752, 29489 => 34762, 29490 => 34779, 29491 => 34794, 29492 => 34784,
+    29493 => 34798, 29494 => 34838, 29495 => 34835, 29496 => 34814, 29497 => 34826,
+    29498 => 34843, 29499 => 34849, 29500 => 34873, 29501 => 34876, 29502 => 32566,
+    29503 => 32578, 29504 => 32580, 29505 => 32581, 29506 => 33296, 29507 => 31482,
+    29508 => 31485, 29509 => 31496, 29510 => 31491, 29511 => 31492, 29512 => 31509,
+    29513 => 31498, 29514 => 31531, 29515 => 31503, 29516 => 31559, 29517 => 31544,
+    29518 => 31530, 29519 => 31513, 29520 => 31534, 29521 => 31537, 29522 => 31520,
+    29523 => 31525, 29524 => 31524, 29525 => 31539, 29526 => 31550, 29527 => 31518,
+    29528 => 31576, 29529 => 31578, 29530 => 31557, 29531 => 31605, 29532 => 31564,
+    29533 => 31581, 29534 => 31584, 29535 => 31598, 29536 => 31611, 29537 => 31586,
+    29538 => 31602, 29539 => 31601, 29540 => 31632, 29541 => 31654, 29542 => 31655,
+    29543 => 31672, 29544 => 31660, 29545 => 31645, 29546 => 31656, 29547 => 31621,
+    29548 => 31658, 29549 => 31644, 29550 => 31650, 29551 => 31659, 29552 => 31668,
+    29553 => 31697, 29554 => 31681, 29555 => 31692, 29556 => 31709, 29557 => 31706,
+    29558 => 31717, 29559 => 31718, 29560 => 31722, 29561 => 31756, 29562 => 31742,
+    29563 => 31740, 29564 => 31759, 29565 => 31766, 29566 => 31755, 29729 => 31775,
+    29730 => 31786, 29731 => 31782, 29732 => 31800, 29733 => 31809, 29734 => 31808,
+    29735 => 33278, 29736 => 33281, 29737 => 33282, 29738 => 33284, 29739 => 33260,
+    29740 => 34884, 29741 => 33313, 29742 => 33314, 29743 => 33315, 29744 => 33325,
+    29745 => 33327, 29746 => 33320, 29747 => 33323, 29748 => 33336, 29749 => 33339,
+    29750 => 33331, 29751 => 33332, 29752 => 33342, 29753 => 33348, 29754 => 33353,
+    29755 => 33355, 29756 => 33359, 29757 => 33370, 29758 => 33375, 29759 => 33384,
+    29760 => 34942, 29761 => 34949, 29762 => 34952, 29763 => 35032, 29764 => 35039,
+    29765 => 35166, 29766 => 32669, 29767 => 32671, 29768 => 32679, 29769 => 32687,
+    29770 => 32688, 29771 => 32690, 29772 => 31868, 29773 => 25929, 29774 => 31889,
+    29775 => 31901, 29776 => 31900, 29777 => 31902, 29778 => 31906, 29779 => 31922,
+    29780 => 31932, 29781 => 31933, 29782 => 31937, 29783 => 31943, 29784 => 31948,
+    29785 => 31949, 29786 => 31944, 29787 => 31941, 29788 => 31959, 29789 => 31976,
+    29790 => 33390, 29791 => 26280, 29792 => 32703, 29793 => 32718, 29794 => 32725,
+    29795 => 32741, 29796 => 32737, 29797 => 32742, 29798 => 32745, 29799 => 32750,
+    29800 => 32755, 29801 => 31992, 29802 => 32119, 29803 => 32166, 29804 => 32174,
+    29805 => 32327, 29806 => 32411, 29807 => 40632, 29808 => 40628, 29809 => 36211,
+    29810 => 36228, 29811 => 36244, 29812 => 36241, 29813 => 36273, 29814 => 36199,
+    29815 => 36205, 29816 => 35911, 29817 => 35913, 29818 => 37194, 29819 => 37200,
+    29820 => 37198, 29821 => 37199, 29822 => 37220, 29985 => 37218, 29986 => 37217,
+    29987 => 37232, 29988 => 37225, 29989 => 37231, 29990 => 37245, 29991 => 37246,
+    29992 => 37234, 29993 => 37236, 29994 => 37241, 29995 => 37260, 29996 => 37253,
+    29997 => 37264, 29998 => 37261, 29999 => 37265, 30000 => 37282, 30001 => 37283,
+    30002 => 37290, 30003 => 37293, 30004 => 37294, 30005 => 37295, 30006 => 37301,
+    30007 => 37300, 30008 => 37306, 30009 => 35925, 30010 => 40574, 30011 => 36280,
+    30012 => 36331, 30013 => 36357, 30014 => 36441, 30015 => 36457, 30016 => 36277,
+    30017 => 36287, 30018 => 36284, 30019 => 36282, 30020 => 36292, 30021 => 36310,
+    30022 => 36311, 30023 => 36314, 30024 => 36318, 30025 => 36302, 30026 => 36303,
+    30027 => 36315, 30028 => 36294, 30029 => 36332, 30030 => 36343, 30031 => 36344,
+    30032 => 36323, 30033 => 36345, 30034 => 36347, 30035 => 36324, 30036 => 36361,
+    30037 => 36349, 30038 => 36372, 30039 => 36381, 30040 => 36383, 30041 => 36396,
+    30042 => 36398, 30043 => 36387, 30044 => 36399, 30045 => 36410, 30046 => 36416,
+    30047 => 36409, 30048 => 36405, 30049 => 36413, 30050 => 36401, 30051 => 36425,
+    30052 => 36417, 30053 => 36418, 30054 => 36433, 30055 => 36434, 30056 => 36426,
+    30057 => 36464, 30058 => 36470, 30059 => 36476, 30060 => 36463, 30061 => 36468,
+    30062 => 36485, 30063 => 36495, 30064 => 36500, 30065 => 36496, 30066 => 36508,
+    30067 => 36510, 30068 => 35960, 30069 => 35970, 30070 => 35978, 30071 => 35973,
+    30072 => 35992, 30073 => 35988, 30074 => 26011, 30075 => 35286, 30076 => 35294,
+    30077 => 35290, 30078 => 35292, 30241 => 35301, 30242 => 35307, 30243 => 35311,
+    30244 => 35390, 30245 => 35622, 30246 => 38739, 30247 => 38633, 30248 => 38643,
+    30249 => 38639, 30250 => 38662, 30251 => 38657, 30252 => 38664, 30253 => 38671,
+    30254 => 38670, 30255 => 38698, 30256 => 38701, 30257 => 38704, 30258 => 38718,
+    30259 => 40832, 30260 => 40835, 30261 => 40837, 30262 => 40838, 30263 => 40839,
+    30264 => 40840, 30265 => 40841, 30266 => 40842, 30267 => 40844, 30268 => 40702,
+    30269 => 40715, 30270 => 40717, 30271 => 38585, 30272 => 38588, 30273 => 38589,
+    30274 => 38606, 30275 => 38610, 30276 => 30655, 30277 => 38624, 30278 => 37518,
+    30279 => 37550, 30280 => 37576, 30281 => 37694, 30282 => 37738, 30283 => 37834,
+    30284 => 37775, 30285 => 37950, 30286 => 37995, 30287 => 40063, 30288 => 40066,
+    30289 => 40069, 30290 => 40070, 30291 => 40071, 30292 => 40072, 30293 => 31267,
+    30294 => 40075, 30295 => 40078, 30296 => 40080, 30297 => 40081, 30298 => 40082,
+    30299 => 40084, 30300 => 40085, 30301 => 40090, 30302 => 40091, 30303 => 40094,
+    30304 => 40095, 30305 => 40096, 30306 => 40097, 30307 => 40098, 30308 => 40099,
+    30309 => 40101, 30310 => 40102, 30311 => 40103, 30312 => 40104, 30313 => 40105,
+    30314 => 40107, 30315 => 40109, 30316 => 40110, 30317 => 40112, 30318 => 40113,
+    30319 => 40114, 30320 => 40115, 30321 => 40116, 30322 => 40117, 30323 => 40118,
+    30324 => 40119, 30325 => 40122, 30326 => 40123, 30327 => 40124, 30328 => 40125,
+    30329 => 40132, 30330 => 40133, 30331 => 40134, 30332 => 40135, 30333 => 40138,
+    30334 => 40139, 30497 => 40140, 30498 => 40141, 30499 => 40142, 30500 => 40143,
+    30501 => 40144, 30502 => 40147, 30503 => 40148, 30504 => 40149, 30505 => 40151,
+    30506 => 40152, 30507 => 40153, 30508 => 40156, 30509 => 40157, 30510 => 40159,
+    30511 => 40162, 30512 => 38780, 30513 => 38789, 30514 => 38801, 30515 => 38802,
+    30516 => 38804, 30517 => 38831, 30518 => 38827, 30519 => 38819, 30520 => 38834,
+    30521 => 38836, 30522 => 39601, 30523 => 39600, 30524 => 39607, 30525 => 40536,
+    30526 => 39606, 30527 => 39610, 30528 => 39612, 30529 => 39617, 30530 => 39616,
+    30531 => 39621, 30532 => 39618, 30533 => 39627, 30534 => 39628, 30535 => 39633,
+    30536 => 39749, 30537 => 39747, 30538 => 39751, 30539 => 39753, 30540 => 39752,
+    30541 => 39757, 30542 => 39761, 30543 => 39144, 30544 => 39181, 30545 => 39214,
+    30546 => 39253, 30547 => 39252, 30548 => 39647, 30549 => 39649, 30550 => 39654,
+    30551 => 39663, 30552 => 39659, 30553 => 39675, 30554 => 39661, 30555 => 39673,
+    30556 => 39688, 30557 => 39695, 30558 => 39699, 30559 => 39711, 30560 => 39715,
+    30561 => 40637, 30562 => 40638, 30563 => 32315, 30564 => 40578, 30565 => 40583,
+    30566 => 40584, 30567 => 40587, 30568 => 40594, 30569 => 37846, 30570 => 40605,
+    30571 => 40607, 30572 => 40667, 30573 => 40668, 30574 => 40669, 30575 => 40672,
+    30576 => 40671, 30577 => 40674, 30578 => 40681, 30579 => 40679, 30580 => 40677,
+    30581 => 40682, 30582 => 40687, 30583 => 40738, 30584 => 40748, 30585 => 40751,
+    30586 => 40761, 30587 => 40759, 30588 => 40765, 30589 => 40766, 30590 => 40772,
+    0 => 0 );
+
+    function gb2utf8($gb) {
+        if( !trim($gb) ) return $gb;
+        $utf8='';
+        while($gb) {
+            if( ord(substr($gb,0,1)) > 127 ) {
+                $t=substr($gb,0,2);
+                $gb=substr($gb,2);
+                $utf8 .= $this->u2utf8($this->codetable[hexdec(bin2hex($t))-0x8080]);
+            }
+            else {
+                $t=substr($gb,0,1);
+                $gb=substr($gb,1);
+                $utf8 .= $this->u2utf8($t);
+            }
+        }
+        return $utf8;
+    }
+
+    function u2utf8($c) {
+        $str='';
+        if ($c < 0x80) {
+            $str.=$c;
+        }
+        else if ($c < 0x800) {
+            $str.=chr(0xC0 | $c>>6);
+            $str.=chr(0x80 | $c & 0x3F);
+        }
+        else if ($c < 0x10000) {
+            $str.=chr(0xE0 | $c>>12);
+            $str.=chr(0x80 | $c>>6 & 0x3F);
+            $str.=chr(0x80 | $c & 0x3F);
+        }
+        else if ($c < 0x200000) {
+            $str.=chr(0xF0 | $c>>18);
+            $str.=chr(0x80 | $c>>12 & 0x3F);
+            $str.=chr(0x80 | $c>>6 & 0x3F);
+            $str.=chr(0x80 | $c & 0x3F);
+        }
+        return $str;
+    }
+
+} // END Class
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_gradient.php b/web/classes/jpgraph/jpgraph_gradient.php
new file mode 100755
index 0000000000000000000000000000000000000000..225cf60ce1e39f9fd0a40b0e0490567323192644
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_gradient.php
@@ -0,0 +1,434 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_GRADIENT.PHP
+ // Description: Create a color gradient
+ // Created:     2003-02-01
+ // Ver:         $Id: jpgraph_gradient.php 1761 2009-08-01 08:31:28Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+// Styles for gradient color fill
+define("GRAD_VER",1);
+define("GRAD_VERT",1);
+define("GRAD_HOR",2);
+define("GRAD_MIDHOR",3);
+define("GRAD_MIDVER",4);
+define("GRAD_CENTER",5);
+define("GRAD_WIDE_MIDVER",6);
+define("GRAD_WIDE_MIDHOR",7);
+define("GRAD_LEFT_REFLECTION",8);
+define("GRAD_RIGHT_REFLECTION",9);
+define("GRAD_RAISED_PANEL",10);
+define("GRAD_DIAGONAL",11);
+
+//===================================================
+// CLASS Gradient
+// Description: Handles gradient fills. This is to be
+// considered a "friend" class of Class Image.
+//===================================================
+class Gradient {
+    private $img=null, $numcolors=100;
+    //---------------
+    // CONSTRUCTOR
+    function __construct(&$img) {
+        $this->img = $img;
+    }
+
+
+    function SetNumColors($aNum) {
+        $this->numcolors=$aNum;
+    }
+    //---------------
+    // PUBLIC METHODS
+    // Produce a gradient filled rectangle with a smooth transition between
+    // two colors.
+    // ($xl,$yt)  Top left corner
+    // ($xr,$yb) Bottom right
+    // $from_color Starting color in gradient
+    // $to_color End color in the gradient
+    // $style  Which way is the gradient oriented?
+    function FilledRectangle($xl,$yt,$xr,$yb,$from_color,$to_color,$style=1) {
+        $this->img->SetLineWeight(1);
+        switch( $style ) {
+            case GRAD_VER:
+                $steps = ceil(abs($xr-$xl)+1);
+                $delta = $xr>=$xl ? 1 : -1;
+                $this->GetColArray($from_color,$to_color,$steps,$colors,$this->numcolors);
+                for( $i=0, $x=$xl; $i < $steps; ++$i ) {
+                    $this->img->current_color = $colors[$i];
+                    $this->img->Line($x,$yt,$x,$yb);
+                    $x += $delta;
+                }
+                break;
+
+            case GRAD_HOR:
+                $steps = ceil(abs($yb-$yt)+1);
+                $delta = $yb >= $yt ? 1 : -1;
+                $this->GetColArray($from_color,$to_color,$steps,$colors,$this->numcolors);
+                for($i=0,$y=$yt; $i < $steps; ++$i) {
+                    $this->img->current_color = $colors[$i];
+                    $this->img->Line($xl,$y,$xr,$y);
+                    $y += $delta;
+                }
+                break;
+
+            case GRAD_MIDHOR:
+                $steps = ceil(abs($yb-$yt)/2);
+                $delta = $yb >= $yt ? 1 : -1;
+                $this->GetColArray($from_color,$to_color,$steps,$colors,$this->numcolors);
+                for($y=$yt, $i=0; $i < $steps;  ++$i) {
+                    $this->img->current_color = $colors[$i];
+                    $this->img->Line($xl,$y,$xr,$y);
+                    $y += $delta;
+                }
+                --$i;
+                if( abs($yb-$yt) % 2 == 1 ) {
+                    --$steps;
+                }
+                for($j=0; $j < $steps; ++$j, --$i) {
+                    $this->img->current_color = $colors[$i];
+                    $this->img->Line($xl,$y,$xr,$y);
+                    $y += $delta;
+                }
+                $this->img->Line($xl,$y,$xr,$y);
+                break;
+
+            case GRAD_MIDVER:
+                $steps = ceil(abs($xr-$xl)/2);
+                $delta = $xr>=$xl ? 1 : -1;
+                $this->GetColArray($from_color,$to_color,$steps,$colors,$this->numcolors);
+                for($x=$xl, $i=0; $i < $steps; ++$i) {
+                    $this->img->current_color = $colors[$i];
+                    $this->img->Line($x,$yb,$x,$yt);
+                    $x += $delta;
+                }
+                --$i;
+                if( abs($xr-$xl) % 2 == 1 ) {
+                    --$steps;
+                }
+                for($j=0; $j < $steps; ++$j, --$i) {
+                    $this->img->current_color = $colors[$i];
+                    $this->img->Line($x,$yb,$x,$yt);
+                    $x += $delta;
+                }
+                $this->img->Line($x,$yb,$x,$yt);
+                break;
+
+            case GRAD_WIDE_MIDVER:
+                $diff = ceil(abs($xr-$xl));
+                $steps = floor(abs($diff)/3);
+                $firststep = $diff - 2*$steps ;
+                $delta = $xr >= $xl ? 1 : -1;
+                $this->GetColArray($from_color,$to_color,$firststep,$colors,$this->numcolors);
+                for($x=$xl, $i=0; $i < $firststep; ++$i) {
+                    $this->img->current_color = $colors[$i];
+                    $this->img->Line($x,$yb,$x,$yt);
+                    $x += $delta;
+                }
+                --$i;
+                $this->img->current_color = $colors[$i];
+                for($j=0; $j< $steps; ++$j) {
+                    $this->img->Line($x,$yb,$x,$yt);
+                    $x += $delta;
+                }
+
+                for($j=0; $j < $steps; ++$j, --$i) {
+                    $this->img->current_color = $colors[$i];
+                    $this->img->Line($x,$yb,$x,$yt);
+                    $x += $delta;
+                }
+                break;
+
+            case GRAD_WIDE_MIDHOR:
+                $diff = ceil(abs($yb-$yt));
+                $steps = floor(abs($diff)/3);
+                $firststep = $diff - 2*$steps ;
+                $delta = $yb >= $yt? 1 : -1;
+                $this->GetColArray($from_color,$to_color,$firststep,$colors,$this->numcolors);
+                for($y=$yt, $i=0; $i < $firststep;  ++$i) {
+                    $this->img->current_color = $colors[$i];
+                    $this->img->Line($xl,$y,$xr,$y);
+                    $y += $delta;
+                }
+                --$i;
+                $this->img->current_color = $colors[$i];
+                for($j=0; $j < $steps; ++$j) {
+                    $this->img->Line($xl,$y,$xr,$y);
+                    $y += $delta;
+                }
+                for($j=0; $j < $steps; ++$j, --$i) {
+                    $this->img->current_color = $colors[$i];
+                    $this->img->Line($xl,$y,$xr,$y);
+                    $y += $delta;
+                }
+                break;
+
+            case GRAD_LEFT_REFLECTION:
+                $steps1 = ceil(0.3*abs($xr-$xl));
+                $delta = $xr>=$xl ? 1 : -1;
+
+                $from_color = $this->img->rgb->Color($from_color);
+                $adj = 1.4;
+                $m = ($adj-1.0)*(255-min(255,min($from_color[0],min($from_color[1],$from_color[2]))));
+                $from_color2 = array(min(255,$from_color[0]+$m),
+                min(255,$from_color[1]+$m), min(255,$from_color[2]+$m));
+
+                $this->GetColArray($from_color2,$to_color,$steps1,$colors,$this->numcolors);
+                $n = count($colors);
+                for($x=$xl, $i=0; $i < $steps1 && $i < $n; ++$i) {
+                    $this->img->current_color = $colors[$i];
+                    $this->img->Line($x,$yb,$x,$yt);
+                    $x += $delta;
+                }
+                $steps2 = max(1,ceil(0.08*abs($xr-$xl)));
+                $this->img->SetColor($to_color);
+                for($j=0; $j< $steps2; ++$j) {
+                    $this->img->Line($x,$yb,$x,$yt);
+                    $x += $delta;
+                }
+                $steps = abs($xr-$xl)-$steps1-$steps2;
+                $this->GetColArray($to_color,$from_color,$steps,$colors,$this->numcolors);
+                $n = count($colors);
+                for($i=0; $i < $steps && $i < $n; ++$i) {
+                    $this->img->current_color = $colors[$i];
+                    $this->img->Line($x,$yb,$x,$yt);
+                    $x += $delta;
+                }
+                break;
+
+            case GRAD_RIGHT_REFLECTION:
+                $steps1 = ceil(0.7*abs($xr-$xl));
+                $delta = $xr>=$xl ? 1 : -1;
+
+                $this->GetColArray($from_color,$to_color,$steps1,$colors,$this->numcolors);
+                $n = count($colors);
+                for($x=$xl, $i=0; $i < $steps1 && $i < $n; ++$i) {
+                    $this->img->current_color = $colors[$i];
+                    $this->img->Line($x,$yb,$x,$yt);
+                    $x += $delta;
+                }
+                $steps2 = max(1,ceil(0.08*abs($xr-$xl)));
+                $this->img->SetColor($to_color);
+                for($j=0; $j< $steps2; ++$j) {
+                    $this->img->Line($x,$yb,$x,$yt);
+                    $x += $delta;
+                }
+
+                $from_color = $this->img->rgb->Color($from_color);
+                $adj = 1.4;
+                $m = ($adj-1.0)*(255-min(255,min($from_color[0],min($from_color[1],$from_color[2]))));
+                $from_color = array(min(255,$from_color[0]+$m),
+                min(255,$from_color[1]+$m), min(255,$from_color[2]+$m));
+
+                $steps = abs($xr-$xl)-$steps1-$steps2;
+                $this->GetColArray($to_color,$from_color,$steps,$colors,$this->numcolors);
+                $n = count($colors);
+                for($i=0; $i < $steps && $i < $n; ++$i) {
+                    $this->img->current_color = $colors[$i];
+                    $this->img->Line($x,$yb,$x,$yt);
+                    $x += $delta;
+                }
+                break;
+
+            case GRAD_CENTER:
+                $steps = ceil(min(($yb-$yt)+1,($xr-$xl)+1)/2);
+                $this->GetColArray($from_color,$to_color,$steps,$colors,$this->numcolors);
+                $dx = ($xr-$xl)/2;
+                $dy = ($yb-$yt)/2;
+                $x=$xl;$y=$yt;$x2=$xr;$y2=$yb;
+                $n = count($colors);
+                for($x=$xl, $i=0; $x < $xl+$dx && $y < $yt+$dy && $i < $n; ++$x, ++$y, --$x2, --$y2, ++$i) {
+                    $this->img->current_color = $colors[$i];
+                    $this->img->Rectangle($x,$y,$x2,$y2);
+                }
+                $this->img->Line($x,$y,$x2,$y2);
+                break;
+
+            case GRAD_RAISED_PANEL:
+                // right to left
+                $steps1 = $xr-$xl;
+                $delta = $xr>=$xl ? 1 : -1;
+                $this->GetColArray($to_color,$from_color,$steps1,$colors,$this->numcolors);
+                $n = count($colors);
+                for($x=$xl, $i=0; $i < $steps1 && $i < $n; ++$i) {
+                    $this->img->current_color = $colors[$i];
+                    $this->img->Line($x,$yb,$x,$yt);
+                    $x += $delta;
+                }
+
+                // left to right
+                $xr -= 3;
+                $xl += 3;
+                $yb -= 3;
+                $yt += 3;
+                $steps2 = $xr-$xl;
+                $delta = $xr>=$xl ? 1 : -1;
+                for($x=$xl, $j=$steps2; $j >= 0; --$j) {
+                    $this->img->current_color = $colors[$j];
+                    $this->img->Line($x,$yb,$x,$yt);
+                    $x += $delta;
+                }
+                break;
+
+            case GRAD_DIAGONAL:
+                // use the longer dimension to determine the required number of steps.
+                // first loop draws from one corner to the mid-diagonal and the second
+                // loop draws from the mid-diagonal to the opposing corner.
+                if($xr-$xl > $yb - $yt) {
+                    // width is greater than height -> use x-dimension for steps
+                    $steps = $xr-$xl;
+                    $delta = $xr>=$xl ? 1 : -1;
+                    $this->GetColArray($from_color,$to_color,$steps*2,$colors,$this->numcolors);
+                    $n = count($colors);
+
+                    for($x=$xl, $i=0; $i < $steps && $i < $n; ++$i) {
+                        $this->img->current_color = $colors[$i];
+                        $y = $yt+($i/$steps)*($yb-$yt)*$delta;
+                        $this->img->Line($x,$yt,$xl,$y);
+                        $x += $delta;
+                    }
+
+                    for($x=$xl, $i = 0; $i < $steps && $i < $n; ++$i) {
+                        $this->img->current_color = $colors[$steps+$i];
+                        $y = $yt+($i/$steps)*($yb-$yt)*$delta;
+                        $this->img->Line($x,$yb,$xr,$y);
+                        $x += $delta;
+                    }
+                } else {
+                    // height is greater than width -> use y-dimension for steps
+                    $steps = $yb-$yt;
+                    $delta = $yb>=$yt ? 1 : -1;
+                    $this->GetColArray($from_color,$to_color,$steps*2,$colors,$this->numcolors);
+                    $n = count($colors);
+
+                    for($y=$yt, $i=0; $i < $steps && $i < $n; ++$i) {
+                        $this->img->current_color = $colors[$i];
+                        $x = $xl+($i/$steps)*($xr-$xl)*$delta;
+                        $this->img->Line($x,$yt,$xl,$y);
+                        $y += $delta;
+                    }
+
+                    for($y=$yt, $i = 0; $i < $steps && $i < $n; ++$i) {
+                        $this->img->current_color = $colors[$steps+$i];
+                        $x = $xl+($i/$steps)*($xr-$xl)*$delta;
+                        $this->img->Line($x,$yb,$xr,$y);
+                        $x += $delta;
+                    }
+
+                }
+                break;
+
+            default:
+                JpGraphError::RaiseL(7001,$style);
+                //("Unknown gradient style (=$style).");
+                break;
+        }
+    }
+
+    // Fill a special case of a polygon with a flat bottom
+    // with a gradient. Can be used for filled line plots.
+    // Please note that this is NOT a generic gradient polygon fill
+    // routine. It assumes that the bottom is flat (like a drawing
+    // of a mountain)
+    function FilledFlatPolygon($pts,$from_color,$to_color) {
+        if( count($pts) == 0 ) return;
+
+        $maxy=$pts[1];
+        $miny=$pts[1];
+        $n = count($pts) ;
+        for( $i=0, $idx=0; $i < $n; $i += 2) {
+            $x = round($pts[$i]);
+            $y = round($pts[$i+1]);
+            $miny = min($miny,$y);
+            $maxy = max($maxy,$y);
+        }
+
+        $colors = array();
+        $this->GetColArray($from_color,$to_color,abs($maxy-$miny)+1,$colors,$this->numcolors);
+        for($i=$miny, $idx=0; $i <= $maxy; ++$i ) {
+            $colmap[$i] = $colors[$idx++];
+        }
+
+        $n = count($pts)/2 ;
+        $idx = 0 ;
+        while( $idx < $n-1 ) {
+            $p1 = array(round($pts[$idx*2]),round($pts[$idx*2+1]));
+            $p2 = array(round($pts[++$idx*2]),round($pts[$idx*2+1]));
+
+            // Find the largest rectangle we can fill
+            $y = max($p1[1],$p2[1]) ;
+            for($yy=$maxy; $yy > $y; --$yy) {
+                $this->img->current_color = $colmap[$yy];
+                $this->img->Line($p1[0],$yy,$p2[0]-1,$yy);
+            }
+
+            if( $p1[1] == $p2[1] ) {
+                continue;
+            }
+
+            // Fill the rest using lines (slow...)
+            $slope = ($p2[0]-$p1[0])/($p1[1]-$p2[1]);
+            $x1 = $p1[0];
+            $x2 = $p2[0]-1;
+            $start = $y;
+            if( $p1[1] > $p2[1] ) {
+                while( $y >= $p2[1] ) {
+                    $x1=$slope*($start-$y)+$p1[0];
+                    $this->img->current_color = $colmap[$y];
+                    $this->img->Line($x1,$y,$x2,$y);
+                    --$y;
+                }
+            }
+            else {
+                while( $y >= $p1[1] ) {
+                    $x2=$p2[0]+$slope*($start-$y);
+                    $this->img->current_color = $colmap[$y];
+                    $this->img->Line($x1,$y,$x2,$y);
+                    --$y;
+                }
+            }
+        }
+    }
+
+    //---------------
+    // PRIVATE METHODS
+    // Add to the image color map the necessary colors to do the transition
+    // between the two colors using $numcolors intermediate colors
+    function GetColArray($from_color,$to_color,$arr_size,&$colors,$numcols=100) {
+        if( $arr_size==0 ) {
+            return;
+        }
+
+        // If color is given as text get it's corresponding r,g,b values
+        $from_color = $this->img->rgb->Color($from_color);
+        $to_color = $this->img->rgb->Color($to_color);
+
+        $rdelta=($to_color[0]-$from_color[0])/$numcols;
+        $gdelta=($to_color[1]-$from_color[1])/$numcols;
+        $bdelta=($to_color[2]-$from_color[2])/$numcols;
+        $colorsperstep = $numcols/$arr_size;
+        $prevcolnum = -1;
+        $from_alpha = $from_color[3];
+        $to_alpha = $to_color[3];
+        $adelta = ( $to_alpha - $from_alpha ) / $numcols ;
+        for ($i=0; $i < $arr_size; ++$i) {
+            $colnum = floor($colorsperstep*$i);
+            if ( $colnum == $prevcolnum ) {
+                $colors[$i] = $colidx;
+            }
+            else {
+                $r = floor($from_color[0] + $colnum*$rdelta);
+                $g = floor($from_color[1] + $colnum*$gdelta);
+                $b = floor($from_color[2] + $colnum*$bdelta);
+                $alpha = $from_alpha + $colnum*$adelta;
+                $colidx = $this->img->rgb->Allocate(sprintf("#%02x%02x%02x",$r,$g,$b),$alpha);
+                $colors[$i] = $colidx;
+            }
+            $prevcolnum = $colnum;
+        }
+    }
+} // Class
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_iconplot.php b/web/classes/jpgraph/jpgraph_iconplot.php
new file mode 100755
index 0000000000000000000000000000000000000000..584f801768f24898dd1d21effb6f3c81687048ac
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_iconplot.php
@@ -0,0 +1,190 @@
+<?php
+//=======================================================================
+// File:        JPGRAPH_ICONPLOT.PHP
+// Description: Extension module to add icons to plots
+// Created:     2004-02-18
+// Ver:         $Id: jpgraph_iconplot.php 1404 2009-06-28 15:25:41Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+
+//===================================================
+// CLASS IconPlot
+// Description: Make it possible to add a (small) image
+// to the graph
+//===================================================
+class IconPlot {
+    public $iX=0,$iY=0,$iScale=1.0,$iMix=100;
+    private $iHorAnchor='left',$iVertAnchor='top';
+    private $iFile='';
+    private $iAnchors = array('left','right','top','bottom','center');
+    private $iCountryFlag='',$iCountryStdSize=3;
+    private $iScalePosY=null,$iScalePosX=null;
+    private $iImgString='';
+
+
+    function __construct($aFile="",$aX=0,$aY=0,$aScale=1.0,$aMix=100) {
+        $this->iFile = $aFile;
+        $this->iX=$aX;
+        $this->iY=$aY;
+        $this->iScale= $aScale;
+        if( $aMix < 0 || $aMix > 100 ) {
+            JpGraphError::RaiseL(8001); //('Mix value for icon must be between 0 and 100.');
+        }
+        $this->iMix = $aMix ;
+    }
+
+    function SetCountryFlag($aFlag,$aX=0,$aY=0,$aScale=1.0,$aMix=100,$aStdSize=3) {
+        $this->iCountryFlag = $aFlag;
+        $this->iX=$aX;
+        $this->iY=$aY;
+        $this->iScale= $aScale;
+        if( $aMix < 0 || $aMix > 100 ) {
+            JpGraphError::RaiseL(8001);//'Mix value for icon must be between 0 and 100.');
+        }
+        $this->iMix = $aMix;
+        $this->iCountryStdSize = $aStdSize;
+    }
+
+    function SetPos($aX,$aY) {
+        $this->iX=$aX;
+        $this->iY=$aY;
+    }
+
+    function CreateFromString($aStr) {
+        $this->iImgString = $aStr;
+    }
+
+    function SetScalePos($aX,$aY) {
+        $this->iScalePosX = $aX;
+        $this->iScalePosY = $aY;
+    }
+
+    function SetScale($aScale) {
+        $this->iScale = $aScale;
+    }
+
+    function SetMix($aMix) {
+        if( $aMix < 0 || $aMix > 100 ) {
+            JpGraphError::RaiseL(8001);//('Mix value for icon must be between 0 and 100.');
+        }
+        $this->iMix = $aMix ;
+    }
+
+    function SetAnchor($aXAnchor='left',$aYAnchor='center') {
+        if( !in_array($aXAnchor,$this->iAnchors) ||
+        !in_array($aYAnchor,$this->iAnchors) ) {
+            JpGraphError::RaiseL(8002);//("Anchor position for icons must be one of 'top', 'bottom', 'left', 'right' or 'center'");
+        }
+        $this->iHorAnchor=$aXAnchor;
+        $this->iVertAnchor=$aYAnchor;
+    }
+
+    function PreStrokeAdjust($aGraph) {
+        // Nothing to do ...
+    }
+
+    function DoLegend($aGraph) {
+        // Nothing to do ...
+    }
+
+    function Max() {
+        return array(false,false);
+    }
+
+
+    // The next four function are framework function tht gets called
+    // from Gantt and is not menaiungfull in the context of Icons but
+    // they must be implemented to avoid errors.
+    function GetMaxDate() { return false;   }
+    function GetMinDate() { return false;   }
+    function GetLineNbr() { return 0;   }
+    function GetAbsHeight() {return 0;  }
+
+
+    function Min() {
+        return array(false,false);
+    }
+
+    function StrokeMargin(&$aImg) {
+        return true;
+    }
+
+    function Stroke($aImg,$axscale=null,$ayscale=null) {
+        $this->StrokeWithScale($aImg,$axscale,$ayscale);
+    }
+
+    function StrokeWithScale($aImg,$axscale,$ayscale) {
+        if( $this->iScalePosX === null || $this->iScalePosY === null ||
+        	$axscale === null || $ayscale === null ) {
+            $this->_Stroke($aImg);
+        }
+        else {
+            $this->_Stroke($aImg,
+            	round($axscale->Translate($this->iScalePosX)),
+            	round($ayscale->Translate($this->iScalePosY)));
+        }
+    }
+
+    function GetWidthHeight() {
+        $dummy=0;
+        return $this->_Stroke($dummy,null,null,true);
+    }
+
+    function _Stroke($aImg,$x=null,$y=null,$aReturnWidthHeight=false) {
+        if( $this->iFile != '' && $this->iCountryFlag != '' ) {
+            JpGraphError::RaiseL(8003);//('It is not possible to specify both an image file and a country flag for the same icon.');
+        }
+        if( $this->iFile != '' ) {
+            $gdimg = Graph::LoadBkgImage('',$this->iFile);
+        }
+        elseif( $this->iImgString != '') {
+            $gdimg = Image::CreateFromString($this->iImgString);
+        }
+
+        else {
+            if( ! class_exists('FlagImages',false) ) {
+                JpGraphError::RaiseL(8004);//('In order to use Country flags as icons you must include the "jpgraph_flags.php" file.');
+            }
+            $fobj = new FlagImages($this->iCountryStdSize);
+            $dummy='';
+            $gdimg = $fobj->GetImgByName($this->iCountryFlag,$dummy);
+        }
+
+        $iconw = imagesx($gdimg);
+        $iconh = imagesy($gdimg);
+
+        if( $aReturnWidthHeight ) {
+            return array(round($iconw*$this->iScale),round($iconh*$this->iScale));
+        }
+
+        if( $x !== null && $y !== null ) {
+            $this->iX = $x; $this->iY = $y;
+        }
+        if( $this->iX >= 0  && $this->iX <= 1.0 ) {
+            $w = imagesx($aImg->img);
+            $this->iX = round($w*$this->iX);
+        }
+        if( $this->iY >= 0  && $this->iY <= 1.0 ) {
+            $h = imagesy($aImg->img);
+            $this->iY = round($h*$this->iY);
+        }
+
+        if( $this->iHorAnchor == 'center' )
+        $this->iX -= round($iconw*$this->iScale/2);
+        if( $this->iHorAnchor == 'right' )
+        $this->iX -= round($iconw*$this->iScale);
+        if( $this->iVertAnchor == 'center' )
+        $this->iY -= round($iconh*$this->iScale/2);
+        if( $this->iVertAnchor == 'bottom' )
+        $this->iY -= round($iconh*$this->iScale);
+
+        $aImg->CopyMerge($gdimg,$this->iX,$this->iY,0,0,
+        round($iconw*$this->iScale),round($iconh*$this->iScale),
+        $iconw,$iconh,
+        $this->iMix);
+    }
+}
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_imgtrans.php b/web/classes/jpgraph/jpgraph_imgtrans.php
new file mode 100755
index 0000000000000000000000000000000000000000..411a7811f20ff946604c095bc295721a6697e057
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_imgtrans.php
@@ -0,0 +1,223 @@
+<?php
+//=======================================================================
+// File:        JPGRAPH_IMGTRANS.PHP
+// Description: Extension for JpGraph to do some simple img transformations
+// Created:     2003-09-06
+// Ver:         $Id: jpgraph_imgtrans.php 1106 2009-02-22 20:16:35Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+//------------------------------------------------------------------------
+// Class ImgTrans
+// Perform some simple image transformations.
+//------------------------------------------------------------------------
+class ImgTrans {
+    private $gdImg=null;
+
+    function __construct($aGdImg) {
+        // Constructor
+        $this->gdImg = $aGdImg;
+    }
+
+    // --------------------------------------------------------------------
+    // _TransVert3D() and _TransHor3D() are helper methods to
+    // Skew3D().
+    // --------------------------------------------------------------------
+    function _TransVert3D($aGdImg,$aHorizon=100,$aSkewDist=120,$aDir=SKEW3D_DOWN,$aMinSize=true,$aFillColor='#FFFFFF',$aQuality=false,$aBorder=false,$aHorizonPos=0.5) {
+
+
+        // Parameter check
+    if( $aHorizonPos < 0 || $aHorizonPos > 1.0 ) {
+        JpGraphError::RaiseL(9001);
+        //("Value for image transformation out of bounds.\nVanishing point on horizon must be specified as a value between 0 and 1.");
+    }
+
+    $w = imagesx($aGdImg);
+    $h = imagesy($aGdImg);
+
+    // Create new image
+    $ww = $w;
+    if( $aMinSize )
+    $hh = ceil($h * $aHorizon / ($aSkewDist+$h));
+    else
+    $hh = $h;
+
+    $newgdh = imagecreatetruecolor($ww,$hh);
+    $crgb = new RGB( $newgdh );
+    $fillColor = $crgb->Allocate($aFillColor);
+    imagefilledrectangle($newgdh,0,0,$ww-1,$hh-1,$fillColor);
+
+    if( $aBorder ) {
+        $colidx = $crgb->Allocate($aBorder);
+        imagerectangle($newgdh,0,0,$ww-1,$hh-1,$colidx);
+    }
+
+    $mid = round($w * $aHorizonPos);
+
+    $last=$h;
+    for($y=0; $y < $h; ++$y) {
+
+        $yp = $h-$y-1;
+        $yt = floor($yp * $aHorizon / ($aSkewDist + $yp));
+
+        if( !$aQuality ) {
+            if( $last <= $yt ) continue ;
+            $last = $yt;
+        }
+
+        for($x=0; $x < $w; ++$x) {
+            $xt = ($x-$mid) * $aSkewDist / ($aSkewDist + $yp);
+            if( $aDir == SKEW3D_UP )
+            $rgb = imagecolorat($aGdImg,$x,$h-$y-1);
+            else
+            $rgb = imagecolorat($aGdImg,$x,$y);
+            $r = ($rgb >> 16) & 0xFF;
+            $g = ($rgb >> 8) & 0xFF;
+            $b = $rgb & 0xFF;
+            $colidx = imagecolorallocate($newgdh,$r,$g,$b);
+            $xt = round($xt+$mid);
+            if( $aDir == SKEW3D_UP ) {
+                $syt = $yt;
+            }
+            else {
+                $syt = $hh-$yt-1;
+            }
+
+            if( !empty($set[$yt]) ) {
+                $nrgb = imagecolorat($newgdh,$xt,$syt);
+                $nr = ($nrgb >> 16) & 0xFF;
+                $ng = ($nrgb >> 8) & 0xFF;
+                $nb = $nrgb & 0xFF;
+                $colidx = imagecolorallocate($newgdh,floor(($r+$nr)/2),
+                floor(($g+$ng)/2),floor(($b+$nb)/2));
+            }
+
+            imagesetpixel($newgdh,$xt,$syt,$colidx);
+        }
+
+        $set[$yt] = true;
+    }
+
+    return $newgdh;
+    }
+
+    // --------------------------------------------------------------------
+    // _TransVert3D() and _TransHor3D() are helper methods to
+    // Skew3D().
+    // --------------------------------------------------------------------
+    function _TransHor3D($aGdImg,$aHorizon=100,$aSkewDist=120,$aDir=SKEW3D_LEFT,$aMinSize=true,$aFillColor='#FFFFFF',$aQuality=false,$aBorder=false,$aHorizonPos=0.5) {
+
+        $w = imagesx($aGdImg);
+        $h = imagesy($aGdImg);
+
+        // Create new image
+        $hh = $h;
+        if( $aMinSize )
+        $ww = ceil($w * $aHorizon / ($aSkewDist+$w));
+        else
+        $ww = $w;
+
+        $newgdh = imagecreatetruecolor($ww,$hh);
+        $crgb = new RGB( $newgdh );
+        $fillColor = $crgb->Allocate($aFillColor);
+        imagefilledrectangle($newgdh,0,0,$ww-1,$hh-1,$fillColor);
+
+        if( $aBorder ) {
+            $colidx = $crgb->Allocate($aBorder);
+            imagerectangle($newgdh,0,0,$ww-1,$hh-1,$colidx);
+        }
+
+        $mid = round($h * $aHorizonPos);
+
+        $last = -1;
+        for($x=0; $x < $w-1; ++$x) {
+            $xt = floor($x * $aHorizon / ($aSkewDist + $x));
+            if( !$aQuality ) {
+                if( $last >= $xt ) continue ;
+                $last = $xt;
+            }
+
+            for($y=0; $y < $h; ++$y) {
+                $yp = $h-$y-1;
+                $yt = ($yp-$mid) * $aSkewDist / ($aSkewDist + $x);
+
+                if( $aDir == SKEW3D_RIGHT )
+                $rgb = imagecolorat($aGdImg,$w-$x-1,$y);
+                else
+                $rgb = imagecolorat($aGdImg,$x,$y);
+                $r = ($rgb >> 16) & 0xFF;
+                $g = ($rgb >> 8) & 0xFF;
+                $b = $rgb & 0xFF;
+                $colidx = imagecolorallocate($newgdh,$r,$g,$b);
+                $yt = floor($hh-$yt-$mid-1);
+                if( $aDir == SKEW3D_RIGHT ) {
+                    $sxt = $ww-$xt-1;
+                }
+                else
+                $sxt = $xt ;
+
+                if( !empty($set[$xt]) ) {
+                    $nrgb = imagecolorat($newgdh,$sxt,$yt);
+                    $nr = ($nrgb >> 16) & 0xFF;
+                    $ng = ($nrgb >> 8) & 0xFF;
+                    $nb = $nrgb & 0xFF;
+                    $colidx = imagecolorallocate($newgdh,floor(($r+$nr)/2),
+                    floor(($g+$ng)/2),floor(($b+$nb)/2));
+                }
+                imagesetpixel($newgdh,$sxt,$yt,$colidx);
+            }
+
+            $set[$xt] = true;
+        }
+
+        return $newgdh;
+    }
+
+    // --------------------------------------------------------------------
+    // Skew image for the apperance of a 3D effect
+    // This transforms an image into a 3D-skewed version
+    // of the image. The transformation is specified by giving the height
+    // of the artificial horizon and specifying a "skew" factor which
+    // is the distance on the horizon line between the point of
+    // convergence and perspective line.
+    //
+    // The function returns the GD handle of the transformed image
+    // leaving the original image untouched.
+    //
+    // Parameters:
+    // * $aGdImg, GD handle to the image to be transformed
+    // * $aHorizon, Distance to the horizon
+    // * $aSkewDist, Distance from the horizon point of convergence
+    //   on the horizon line to the perspective points. A larger
+    //   value will fore-shorten the image more
+    // * $aDir, parameter specifies type of convergence. This of this
+    //   as the walls in a room you are looking at. This specifies if the
+    //   image should be applied on the left,right,top or bottom walls.
+    // * $aMinSize, true=make the new image just as big as needed,
+    //   false = keep the image the same size as the original image
+    // * $aFillColor, Background fill color in the image
+    // * $aHiQuality, true=performa some interpolation that improves
+    //   the image quality but at the expense of performace. Enabling
+    //   high quality will have a dramatic effect on the time it takes
+    //   to transform an image.
+    // * $aBorder, if set to anything besides false this will draw a
+    //   a border of the speciied color around the image
+    // --------------------------------------------------------------------
+    function Skew3D($aHorizon=120,$aSkewDist=150,$aDir=SKEW3D_DOWN,$aHiQuality=false,$aMinSize=true,$aFillColor='#FFFFFF',$aBorder=false) {
+        return $this->_Skew3D($this->gdImg,$aHorizon,$aSkewDist,$aDir,$aHiQuality,
+        $aMinSize,$aFillColor,$aBorder);
+    }
+
+    function _Skew3D($aGdImg,$aHorizon=120,$aSkewDist=150,$aDir=SKEW3D_DOWN,$aHiQuality=false,$aMinSize=true,$aFillColor='#FFFFFF',$aBorder=false) {
+        if( $aDir == SKEW3D_DOWN || $aDir == SKEW3D_UP )
+        return $this->_TransVert3D($aGdImg,$aHorizon,$aSkewDist,$aDir,$aMinSize,$aFillColor,$aHiQuality,$aBorder);
+        else
+        return $this->_TransHor3D($aGdImg,$aHorizon,$aSkewDist,$aDir,$aMinSize,$aFillColor,$aHiQuality,$aBorder);
+
+    }
+
+}
+
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_led.php b/web/classes/jpgraph/jpgraph_led.php
new file mode 100755
index 0000000000000000000000000000000000000000..83bb2692a083ab0208022ecbc0924328bea5eb6a
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_led.php
@@ -0,0 +1,311 @@
+<?php
+//=======================================================================
+// File:        JPGRAPH_LED.PHP
+// Description: Module to generate Dotted LED-like digits
+// Created:     2006-11-26
+// Ver:         $Id: jpgraph_led.php 1674 2009-07-22 19:42:23Z ljp $
+//
+// Copyright 2006 (c) Asial Corporation. All rights reserved.
+//
+// Changed: 2007-08-06 by Alexander Kurochkin (inspector@list.ru)
+//========================================================================
+
+// Constants for color schema
+DEFINE('LEDC_RED', 0);
+DEFINE('LEDC_GREEN', 1);
+DEFINE('LEDC_BLUE', 2);
+DEFINE('LEDC_YELLOW', 3);
+DEFINE('LEDC_GRAY', 4);
+DEFINE('LEDC_CHOCOLATE', 5);
+DEFINE('LEDC_PERU', 6);
+DEFINE('LEDC_GOLDENROD', 7);
+DEFINE('LEDC_KHAKI', 8);
+DEFINE('LEDC_OLIVE', 9);
+DEFINE('LEDC_LIMEGREEN', 10);
+DEFINE('LEDC_FORESTGREEN', 11);
+DEFINE('LEDC_TEAL', 12);
+DEFINE('LEDC_STEELBLUE', 13);
+DEFINE('LEDC_NAVY', 14);
+DEFINE('LEDC_INVERTGRAY', 15);
+
+// Check that mb_strlen() is available
+if( ! function_exists('mb_strlen') ) {
+    JpGraphError::RaiseL(25500);
+    //'Multibyte strings must be enabled in the PHP installation in order to run the LED module
+    // so that the function mb_strlen() is available. See PHP documentation for more information.'
+}
+
+//========================================================================
+// CLASS DigitalLED74
+// Description:
+// Construct a number as an image that looks like LED numbers in a
+// 7x4 digital matrix
+//========================================================================
+class DigitalLED74
+{
+    private $iLED_X = 4, $iLED_Y=7,
+
+        // fg-up, fg-down, bg
+        $iColorSchema = array(
+            LEDC_RED  => array('red','darkred:0.9','red:0.3'),// 0
+            LEDC_GREEN  => array('green','darkgreen','green:0.3'),// 1
+            LEDC_BLUE  => array('lightblue:0.9','darkblue:0.85','darkblue:0.7'),// 2
+            LEDC_YELLOW  => array('yellow','yellow:0.4','yellow:0.3'),// 3
+            LEDC_GRAY  => array('gray:1.4','darkgray:0.85','darkgray:0.7'),
+            LEDC_CHOCOLATE => array('chocolate','chocolate:0.7','chocolate:0.5'),
+            LEDC_PERU  => array('peru:0.95','peru:0.6','peru:0.5'),
+            LEDC_GOLDENROD => array('goldenrod','goldenrod:0.6','goldenrod:0.5'),
+            LEDC_KHAKI  => array('khaki:0.7','khaki:0.4','khaki:0.3'),
+            LEDC_OLIVE  => array('#808000','#808000:0.7','#808000:0.6'),
+            LEDC_LIMEGREEN => array('limegreen:0.9','limegreen:0.5','limegreen:0.4'),
+            LEDC_FORESTGREEN => array('forestgreen','forestgreen:0.7','forestgreen:0.5'),
+            LEDC_TEAL  => array('teal','teal:0.7','teal:0.5'),
+            LEDC_STEELBLUE => array('steelblue','steelblue:0.65','steelblue:0.5'),
+            LEDC_NAVY  => array('navy:1.3','navy:0.95','navy:0.8'),//14
+            LEDC_INVERTGRAY => array('darkgray','lightgray:1.5','white')//15
+            ),
+
+        /* Each line of the character is encoded as a 4 bit value
+         0      ____
+         1      ___x
+         2      __x_
+         3      __xx
+         4      _x__
+         5      _x_x
+         6      _xx_
+         7      _xxx
+         8      x___
+         9      x__x
+         10     x_x_
+         11     x_xx
+         12     xx__
+         13     xx_x
+         14     xxx_
+         15     xxxx
+        */
+
+        $iLEDSpec = array(
+            0 => array(6,9,11,15,13,9,6),
+            1 => array(2,6,10,2,2,2,2),
+            2 => array(6,9,1,2,4,8,15),
+            3 => array(6,9,1,6,1,9,6),
+            4 => array(1,3,5,9,15,1,1),
+            5 => array(15,8,8,14,1,9,6),
+            6 => array(6,8,8,14,9,9,6),
+            7 => array(15,1,1,2,4,4,4),
+            8 => array(6,9,9,6,9,9,6),
+            9 => array(6,9,9,7,1,1,6),
+            '!' => array(4,4,4,4,4,0,4),
+            '?' => array(6,9,1,2,2,0,2),
+            '#' => array(0,9,15,9,15,9,0),
+            '@' => array(6,9,11,11,10,9,6),
+            '-' => array(0,0,0,15,0,0,0),
+            '_' => array(0,0,0,0,0,0,15),
+            '=' => array(0,0,15,0,15,0,0),
+            '+' => array(0,0,4,14,4,0,0),
+            '|' => array(4,4,4,4,4,4,4), //vertical line, used for simulate rus 'Ы'
+            ',' => array(0,0,0,0,0,12,4),
+            '.' => array(0,0,0,0,0,12,12),
+            ':' => array(12,12,0,0,0,12,12),
+            ';' => array(12,12,0,0,0,12,4),
+            '[' => array(3,2,2,2,2,2,3),
+            ']' => array(12,4,4,4,4,4,12),
+            '(' => array(1,2,2,2,2,2,1),
+            ')' => array(8,4,4,4,4,4,8),
+            '{' => array(3,2,2,6,2,2,3),
+            '}' => array(12,4,4,6,4,4,12),
+            '<' => array(1,2,4,8,4,2,1),
+            '>' => array(8,4,2,1,2,4,8),
+            '*' => array(9,6,15,6,9,0,0),
+            '"' => array(10,10,0,0,0,0,0),
+            '\'' => array(4,4,0,0,0,0,0),
+            '`' => array(4,2,0,0,0,0,0),
+            '~' => array(13,11,0,0,0,0,0),
+            '^' => array(4,10,0,0,0,0,0),
+            '\\' => array(8,8,4,6,2,1,1),
+            '/' => array(1,1,2,6,4,8,8),
+            '%' => array(1,9,2,6,4,9,8),
+            '&' => array(0,4,10,4,11,10,5),
+            '$' => array(2,7,8,6,1,14,4),
+            ' ' => array(0,0,0,0,0,0,0),
+            '•' => array(0,0,6,6,0,0,0), //149
+            '°' => array(14,10,14,0,0,0,0), //176
+            '†' => array(4,4,14,4,4,4,4), //134
+            '‡' => array(4,4,14,4,14,4,4), //135
+            '±' => array(0,4,14,4,0,14,0), //177
+            '‰' => array(0,4,2,15,2,4,0), //137 show right arrow
+            '™' => array(0,2,4,15,4,2,0), //156 show left arrow
+            'Ў' => array(0,0,8,8,0,0,0), //159 show small hi-stick - that need for simulate rus 'Ф'
+            "\t" => array(8,8,8,0,0,0,0), //show hi-stick - that need for simulate rus 'У'
+            "\r" => array(8,8,8,8,8,8,8), //vertical line - that need for simulate 'M', 'W' and rus 'М','Ш' ,'Щ'
+            "\n" => array(15,15,15,15,15,15,15), //fill up - that need for simulate rus 'Ж'
+            "Ґ" => array(10,5,10,5,10,5,10), //chess
+            "µ" => array(15,0,15,0,15,0,15), //4 horizontal lines
+            // latin
+            'A' => array(6,9,9,15,9,9,9),
+            'B' => array(14,9,9,14,9,9,14),
+            'C' => array(6,9,8,8,8,9,6),
+            'D' => array(14,9,9,9,9,9,14),
+            'E' => array(15,8,8,14,8,8,15),
+            'F' => array(15,8,8,14,8,8,8),
+            'G' => array(6,9,8,8,11,9,6),
+            'H' => array(9,9,9,15,9,9,9),
+            'I' => array(14,4,4,4,4,4,14),
+            'J' => array(15,1,1,1,1,9,6),
+            'K' => array(8,9,10,12,12,10,9),
+            'L' => array(8,8,8,8,8,8,15),
+            'M' => array(8,13,10,8,8,8,8),// need to add \r
+            'N' => array(9,9,13,11,9,9,9),
+            'O' => array(6,9,9,9,9,9,6),
+            'P' => array(14,9,9,14,8,8,8),
+            'Q' => array(6,9,9,9,13,11,6),
+            'R' => array(14,9,9,14,12,10,9),
+            'S' => array(6,9,8,6,1,9,6),
+            'T' => array(14,4,4,4,4,4,4),
+            'U' => array(9,9,9,9,9,9,6),
+            'V' => array(0,0,0,10,10,10,4),
+            'W' => array(8,8,8,8,10,13,8),// need to add \r
+            'X' => array(9,9,6,6,6,9,9),
+            'Y' => array(10,10,10,10,4,4,4),
+            'Z' => array(15,1,2,6,4,8,15),
+            // russian utf-8
+            'А' => array(6,9,9,15,9,9,9),
+            'Б' => array(14,8,8,14,9,9,14),
+            'В' => array(14,9,9,14,9,9,14),
+            'Г' => array(15,8,8,8,8,8,8),
+            'Д' => array(14,9,9,9,9,9,14),
+            'Е' => array(15,8,8,14,8,8,15),
+            'Ё' => array(6,15,8,14,8,8,15),
+            //Ж is combine: >\n<
+            'З' => array(6,9,1,2,1,9,6),
+            'И' => array(9,9,9,11,13,9,9),
+            'Й' => array(13,9,9,11,13,9,9),
+            'К' => array(9,10,12,10,9,9,9),
+            'Л' => array(7,9,9,9,9,9,9),
+            'М' => array(8,13,10,8,8,8,8),// need to add \r
+            'Н' => array(9,9,9,15,9,9,9),
+            'О' => array(6,9,9,9,9,9,6),
+            'П' => array(15,9,9,9,9,9,9),
+            'Р' => array(14,9,9,14,8,8,8),
+            'С' => array(6,9,8,8,8,9,6),
+            'Т' => array(14,4,4,4,4,4,4),
+            'У' => array(9,9,9,7,1,9,6),
+            'Ф' => array(2,7,10,10,7,2,2),// need to add Ў
+            'Х' => array(9,9,6,6,6,9,9),
+            'Ц' => array(10,10,10,10,10,15,1),
+            'Ч' => array(9,9,9,7,1,1,1),
+            'Ш' => array(10,10,10,10,10,10,15),// \r
+            'Щ' => array(10,10,10,10,10,15,0),// need to add \r
+            'Ъ' => array(12,4,4,6,5,5,6),
+            'Ы' => array(8,8,8,14,9,9,14),// need to add |
+            'Ь' => array(8,8,8,14,9,9,14),
+            'Э' => array(6,9,1,7,1,9,6),
+            'Ю' => array(2,2,2,3,2,2,2),// need to add O
+            'Я' => array(7,9,9,7,3,5,9)
+            ),
+
+        $iSuperSampling = 3, $iMarg = 1, $iRad = 4;
+
+    function __construct($aRadius = 2, $aMargin= 0.6) {
+        $this->iRad = $aRadius;
+        $this->iMarg = $aMargin;
+    }
+
+    function SetSupersampling($aSuperSampling = 2) {
+        $this->iSuperSampling = $aSuperSampling;
+    }
+
+    function _GetLED($aLedIdx, $aColor = 0) {
+        $width=  $this->iLED_X*$this->iRad*2 +  ($this->iLED_X+1)*$this->iMarg + $this->iRad ;
+        $height= $this->iLED_Y*$this->iRad*2 +  ($this->iLED_Y)*$this->iMarg + $this->iRad * 2;
+
+        // Adjust radious for supersampling
+        $rad = $this->iRad * $this->iSuperSampling;
+
+        // Margin in between "Led" dots
+        $marg = $this->iMarg * $this->iSuperSampling;
+
+        $swidth = $width*$this->iSuperSampling;
+        $sheight = $height*$this->iSuperSampling;
+
+        $simg = new RotImage($swidth, $sheight, 0, DEFAULT_GFORMAT, false);
+        $simg->SetColor($this->iColorSchema[$aColor][2]);
+        $simg->FilledRectangle(0, 0, $swidth-1, $sheight-1);
+
+        if( array_key_exists($aLedIdx, $this->iLEDSpec) ) {
+            $d = $this->iLEDSpec[$aLedIdx];
+        }
+        else {
+            $d = array(0,0,0,0,0,0,0);
+        }
+
+        for($r = 0; $r < 7; ++$r) {
+            $dr = $d[$r];
+            for($c = 0; $c < 4; ++$c) {
+                if( ($dr & pow(2,3-$c)) !== 0 ) {
+                    $color = $this->iColorSchema[$aColor][0];
+                }
+                else {
+                    $color = $this->iColorSchema[$aColor][1];
+                }
+
+                $x = 2*$rad*$c+$rad + ($c+1)*$marg + $rad ;
+                $y = 2*$rad*$r+$rad + ($r+1)*$marg + $rad ;
+
+                $simg->SetColor($color);
+                $simg->FilledCircle($x,$y,$rad);
+            }
+        }
+
+        $img =  new Image($width, $height, DEFAULT_GFORMAT, false);
+        $img->Copy($simg->img, 0, 0, 0, 0, $width, $height, $swidth, $sheight);
+        $simg->Destroy();
+        unset($simg);
+        return $img;
+    }
+
+
+    function Stroke($aValStr, $aColor = 0, $aFileName = '') {
+    	$this->StrokeNumber($aValStr, $aColor, $aFileName);
+    }
+
+
+    function StrokeNumber($aValStr, $aColor = 0, $aFileName = '') {
+        if( $aColor < 0 || $aColor >= sizeof($this->iColorSchema) ) {
+            $aColor = 0;
+        }
+
+        if(($n = mb_strlen($aValStr,'utf8')) == 0) {
+            $aValStr = ' ';
+            $n = 1;
+        }
+
+        for($i = 0; $i < $n; ++$i) {
+            $d = mb_substr($aValStr, $i, 1, 'utf8');
+            if(  ctype_digit($d) ) {
+                $d = (int)$d;
+            }
+            else {
+               $d = strtoupper($d);
+            }
+            $digit_img[$i] = $this->_GetLED($d, $aColor);
+        }
+
+        $w = imagesx($digit_img[0]->img);
+        $h = imagesy($digit_img[0]->img);
+
+        $number_img = new Image($w*$n, $h, DEFAULT_GFORMAT, false);
+
+        for($i = 0; $i < $n; ++$i) {
+            $number_img->Copy($digit_img[$i]->img, $i*$w, 0, 0, 0, $w, $h, $w, $h);
+        }
+
+        if( $aFileName != '' ) {
+            $number_img->Stream($aFileName);
+        } else {
+            $number_img->Headers();
+            $number_img->Stream();
+        }
+    }
+}
+?>
diff --git a/web/classes/jpgraph/jpgraph_legend.inc.php b/web/classes/jpgraph/jpgraph_legend.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..c7f38b511d7b7a0aaf8517c5e6e10ee4a7a98e9f
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_legend.inc.php
@@ -0,0 +1,494 @@
+<?php
+//=======================================================================
+// File:        JPGRAPH_LEGEND.INC.PHP
+// Description: Class to handle the legend box in the graph that gives
+//              names on the data series. The number of rows and columns
+//              in the legend are user specifyable.
+// Created:     2001-01-08 (Refactored to separate file 2008-08-01)
+// Ver:         $Id: jpgraph_legend.inc.php 1926 2010-01-11 16:33:07Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+DEFINE('_DEFAULT_LPM_SIZE',8); // Default Legend Plot Mark size
+
+
+//===================================================
+// CLASS Legend
+// Description: Responsible for drawing the box containing
+// all the legend text for the graph
+//===================================================
+
+class Legend {
+    public $txtcol=array();
+    public $font_family=FF_DEFAULT,$font_style=FS_NORMAL,$font_size=8; // old. 12
+    private $color=array(120,120,120); // Default frame color
+    private $fill_color=array(245,245,245); // Default fill color
+    private $shadow=false; // Shadow around legend "box"
+    private $shadow_color='darkgray';
+    private $mark_abs_hsize=_DEFAULT_LPM_SIZE,$mark_abs_vsize=_DEFAULT_LPM_SIZE;
+    private $xmargin=10,$ymargin=0,$shadow_width=2;
+    private $xlmargin=4;
+    private $ylinespacing=5;
+    
+     // We need a separate margin since the baseline of the last text would coincide with the bottom otherwise
+    private $ybottom_margin = 8;
+    
+    private $xpos=0.05, $ypos=0.15, $xabspos=-1, $yabspos=-1;
+    private $halign="right", $valign="top";
+    private $font_color='black';
+    private $hide=false,$layout_n=1;
+    private $weight=1,$frameweight=1;
+    private $csimareas='';
+    private $reverse = false ;
+    private $bkg_gradtype=-1, $bkg_gradfrom='lightgray', $bkg_gradto='gray';
+
+    //---------------
+    // CONSTRUCTOR
+    function __construct() {
+        // Empty
+    }
+    //---------------
+    // PUBLIC METHODS
+    function Hide($aHide=true) {
+        $this->hide=$aHide;
+    }
+
+    function SetHColMargin($aXMarg) {
+        $this->xmargin = $aXMarg;
+    }
+
+    function SetVColMargin($aSpacing) {
+        $this->ylinespacing = $aSpacing ;
+    }
+
+    function SetLeftMargin($aXMarg) {
+        $this->xlmargin = $aXMarg;
+    }
+
+    // Synonym
+    function SetLineSpacing($aSpacing) {
+        $this->ylinespacing = $aSpacing ;
+    }
+
+    function SetShadow($aShow='gray',$aWidth=4) {
+        if( is_string($aShow) ) {
+            $this->shadow_color = $aShow;
+            $this->shadow=true;
+        }
+        else {
+            $this->shadow = $aShow;
+        }
+        $this->shadow_width = $aWidth;
+    }
+
+    function SetMarkAbsSize($aSize) {
+        $this->mark_abs_vsize = $aSize ;
+        $this->mark_abs_hsize = $aSize ;
+    }
+
+    function SetMarkAbsVSize($aSize) {
+        $this->mark_abs_vsize = $aSize ;
+    }
+
+    function SetMarkAbsHSize($aSize) {
+        $this->mark_abs_hsize = $aSize ;
+    }
+
+    function SetLineWeight($aWeight) {
+        $this->weight = $aWeight;
+    }
+
+    function SetFrameWeight($aWeight) {
+        $this->frameweight = $aWeight;
+    }
+
+    function SetLayout($aDirection=LEGEND_VERT) {
+        $this->layout_n = $aDirection==LEGEND_VERT ? 1 : 99 ;
+    }
+
+    function SetColumns($aCols) {
+        $this->layout_n = $aCols ;
+    }
+
+    function SetReverse($f=true) {
+        $this->reverse = $f ;
+    }
+
+    // Set color on frame around box
+    function SetColor($aFontColor,$aColor='black') {
+        $this->font_color=$aFontColor;
+        $this->color=$aColor;
+    }
+
+    function SetFont($aFamily,$aStyle=FS_NORMAL,$aSize=10) {
+        $this->font_family = $aFamily;
+        $this->font_style = $aStyle;
+        $this->font_size = $aSize;
+    }
+
+    function SetPos($aX,$aY,$aHAlign='right',$aVAlign='top') {
+        $this->Pos($aX,$aY,$aHAlign,$aVAlign);
+    }
+
+    function SetAbsPos($aX,$aY,$aHAlign='right',$aVAlign='top') {
+        $this->xabspos=$aX;
+        $this->yabspos=$aY;
+        $this->halign=$aHAlign;
+        $this->valign=$aVAlign;
+    }
+
+    function Pos($aX,$aY,$aHAlign='right',$aVAlign='top') {
+        if( !($aX<1 && $aY<1) ) {
+            JpGraphError::RaiseL(25120);//(" Position for legend must be given as percentage in range 0-1");
+        }
+        $this->xpos=$aX;
+        $this->ypos=$aY;
+        $this->halign=$aHAlign;
+        $this->valign=$aVAlign;
+    }
+
+    function SetFillColor($aColor) {
+        $this->fill_color=$aColor;
+    }
+
+    function Clear() {
+        $this->txtcol = array();
+    }
+
+    function Add($aTxt,$aColor,$aPlotmark='',$aLinestyle=0,$csimtarget='',$csimalt='',$csimwintarget='') {
+        $this->txtcol[]=array($aTxt,$aColor,$aPlotmark,$aLinestyle,$csimtarget,$csimalt,$csimwintarget);
+    }
+
+    function GetCSIMAreas() {
+        return $this->csimareas;
+    }
+
+    function SetBackgroundGradient($aFrom='navy',$aTo='silver',$aGradType=2) {
+        $this->bkg_gradtype=$aGradType;
+        $this->bkg_gradfrom = $aFrom;
+        $this->bkg_gradto = $aTo;
+    }
+
+    function HasItems() {
+        return (boolean)(count($this->txtcol));
+    }
+
+    function Stroke($aImg) {
+        // Constant
+        $fillBoxFrameWeight=1;
+
+        if( $this->hide ) return;
+
+        $aImg->SetFont($this->font_family,$this->font_style,$this->font_size);
+
+        if( $this->reverse ) {
+            $this->txtcol = array_reverse($this->txtcol);
+        }
+
+        $n=count($this->txtcol);
+        if( $n == 0 ) return;
+
+        // Find out the max width and height of each column to be able
+        // to size the legend box.
+        $numcolumns = ($n > $this->layout_n ? $this->layout_n : $n);
+        for( $i=0; $i < $numcolumns; ++$i ) {
+            $colwidth[$i] = $aImg->GetTextWidth($this->txtcol[$i][0]) +
+                            2*$this->xmargin + 2*$this->mark_abs_hsize;
+            $colheight[$i] = 0;
+
+        }
+
+        // Find our maximum height in each row
+        $rows = 0 ; $rowheight[0] = 0;
+        for( $i=0; $i < $n; ++$i ) {
+            $h = max($this->mark_abs_vsize,$aImg->GetTextHeight($this->txtcol[$i][0]))+$this->ylinespacing;
+
+            // Makes sure we always have a minimum of 1/4 (1/2 on each side) of the mark as space
+            // between two vertical legend entries
+            //$h = round(max($h,$this->mark_abs_vsize+$this->ymargin));
+            //echo "Textheight #$i: tetxheight=".$aImg->GetTextHeight($this->txtcol[$i][0]).', ';
+            //echo "h=$h ({$this->mark_abs_vsize},{$this->ymargin})<br>";
+            if( $i % $numcolumns == 0 ) {
+                $rows++;
+                $rowheight[$rows-1] = 0;
+            }
+            $rowheight[$rows-1] = max($rowheight[$rows-1],$h)+1;
+        }
+
+        $abs_height = 0;
+        for( $i=0; $i < $rows; ++$i ) {
+            $abs_height += $rowheight[$i] ;
+        }
+
+        // Make sure that the height is at least as high as mark size + ymargin
+        $abs_height = max($abs_height,$this->mark_abs_vsize);
+        $abs_height += $this->ybottom_margin; 
+
+        // Find out the maximum width in each column
+        for( $i=$numcolumns; $i < $n; ++$i ) {
+            $colwidth[$i % $numcolumns] = max(
+                $aImg->GetTextWidth($this->txtcol[$i][0])+2*$this->xmargin+2*$this->mark_abs_hsize,
+                $colwidth[$i % $numcolumns]);
+        }
+
+        // Get the total width
+        $mtw = 0;
+        for( $i=0; $i < $numcolumns; ++$i ) {
+            $mtw += $colwidth[$i] ;
+        }
+
+        // remove the last rows interpace margin (since there is no next row)
+        $abs_height -= $this->ylinespacing;
+
+
+        // Find out maximum width we need for legend box
+        $abs_width = $mtw+$this->xlmargin+($numcolumns-1)*$this->mark_abs_hsize;
+
+        if( $this->xabspos === -1  && $this->yabspos === -1 ) {
+            $this->xabspos = $this->xpos*$aImg->width ;
+            $this->yabspos = $this->ypos*$aImg->height ;
+        }
+
+        // Positioning of the legend box
+        if( $this->halign == 'left' ) {
+        	$xp = $this->xabspos;
+        }
+        elseif( $this->halign == 'center' ) {
+        	$xp = $this->xabspos - $abs_width/2;
+        }
+        else {
+        	$xp = $aImg->width - $this->xabspos - $abs_width;
+        }
+
+        $yp=$this->yabspos;
+        if( $this->valign == 'center' ) {
+        	$yp-=$abs_height/2;
+        }
+        elseif( $this->valign == 'bottom' ) {
+        	$yp-=$abs_height;
+        }
+
+        // Stroke legend box
+        $aImg->SetColor($this->color);
+        $aImg->SetLineWeight($this->frameweight);
+        $aImg->SetLineStyle('solid');
+
+        if( $this->shadow ) {
+        	$aImg->ShadowRectangle($xp,$yp,
+                                   $xp+$abs_width+$this->shadow_width+2,
+                                   $yp+$abs_height+$this->shadow_width+2,
+                                   $this->fill_color,$this->shadow_width+2,$this->shadow_color);
+        }
+        else {
+            $aImg->SetColor($this->fill_color);
+            $aImg->FilledRectangle($xp,$yp,$xp+$abs_width,$yp+$abs_height);
+            $aImg->SetColor($this->color);
+            $aImg->Rectangle($xp,$yp,$xp+$abs_width,$yp+$abs_height);
+        }
+
+        if( $this->bkg_gradtype >= 0 ) {
+            $grad = new Gradient($aImg);
+            $grad->FilledRectangle($xp+1, $yp+1,
+                                   $xp+$abs_width-3, $yp+$abs_height-3,
+                                   $this->bkg_gradfrom, $this->bkg_gradto,
+                                   $this->bkg_gradtype);
+        }
+
+        // x1,y1 is the position for the legend marker + text
+        // The vertical position is the baseline position for the text
+        // and every marker is adjusted acording to that.
+
+        // For multiline texts this get more complicated.
+
+        $x1 = $xp + $this->xlmargin;
+        $y1 = $yp + $rowheight[0] - $this->ylinespacing + 2 ; // The ymargin is included in rowheight
+
+        // Now, y1 is the bottom vertical position of the first legend, i.e if
+        // the legend has multiple lines it is the bottom line.
+
+        $grad = new Gradient($aImg);
+        $patternFactory = null;
+
+        // Now stroke each legend in turn
+        // Each plot has added the following information to  the legend
+        // p[0] = Legend text
+        // p[1] = Color,
+        // p[2] = For markers a reference to the PlotMark object
+        // p[3] = For lines the line style, for gradient the negative gradient style
+        // p[4] = CSIM target
+        // p[5] = CSIM Alt text
+        $i = 1 ; $row = 0;
+        foreach($this->txtcol as $p) {
+
+            // STROKE DEBUG BOX
+            if( _JPG_DEBUG ) {
+                $aImg->SetLineWeight(1);
+                $aImg->SetColor('red');
+                $aImg->SetLineStyle('solid');
+                $aImg->Rectangle($x1,$y1,$xp+$abs_width-1,$y1-$rowheight[$row]);
+            }
+
+            $aImg->SetLineWeight($this->weight);
+            $x1 = round($x1)+1; // We add one to not collide with the border
+            $y1=round($y1);
+
+            // This is the center offset up from the baseline which is
+            // considered the "center" of the marks. This gets slightly complicated since
+            // we need to consider if the text is a multiline paragraph or if it is only
+            // a single line. The reason is that for single line the y1 corresponds to the baseline
+            // and that is fine. However for a multiline paragraph there is no single baseline
+            // and in that case the y1 corresponds to the lowest y for the bounding box. In that
+            // case we center the mark in the middle of the paragraph
+            if( !preg_match('/\n/',$p[0]) ) {
+                // Single line
+                $marky = ceil($y1-$this->mark_abs_vsize/2)-1;
+            } else {
+                // Paragraph
+                $marky = $y1 - $aImg->GetTextHeight($p[0])/2;
+
+              //  echo "y1=$y1, p[o]={$p[0]}, marky=$marky<br>";
+            }
+
+            //echo "<br>Mark #$i: marky=$marky<br>";
+
+            $x1 += $this->mark_abs_hsize;
+    
+            if ( !empty($p[2]) && $p[2]->GetType() > -1 ) {
+
+
+                // Make a plot mark legend. This is constructed with a mark which
+                // is run through with a line
+
+                // First construct a bit of the line that looks exactly like the
+                // line in the plot
+                $aImg->SetColor($p[1]);
+                if( is_string($p[3]) || $p[3]>0 ) {
+                    $aImg->SetLineStyle($p[3]);
+                    $aImg->StyleLine($x1-$this->mark_abs_hsize,$marky,$x1+$this->mark_abs_hsize,$marky);
+                }
+
+                // Stroke a mark using image
+                if( $p[2]->GetType() == MARK_IMG ) {
+                    $p[2]->Stroke($aImg,$x1,$marky);
+                }
+
+                // Stroke a mark with the standard size
+                // (As long as it is not an image mark )
+                if( $p[2]->GetType() != MARK_IMG ) {
+
+                    // Clear any user callbacks since we ont want them called for
+                    // the legend marks
+                    $p[2]->iFormatCallback = '';
+                    $p[2]->iFormatCallback2 = '';
+
+                    // Since size for circles is specified as the radius
+                    // this means that we must half the size to make the total
+                    // width behave as the other marks
+                    if( $p[2]->GetType() == MARK_FILLEDCIRCLE || $p[2]->GetType() == MARK_CIRCLE ) {
+                        $p[2]->SetSize(min($this->mark_abs_vsize,$this->mark_abs_hsize)/2);
+                        $p[2]->Stroke($aImg,$x1,$marky);
+                    }
+                    else {
+                        $p[2]->SetSize(min($this->mark_abs_vsize,$this->mark_abs_hsize));
+                        $p[2]->Stroke($aImg,$x1,$marky);
+                    }
+                }
+            }
+            elseif ( !empty($p[2]) && (is_string($p[3]) || $p[3]>0 ) ) {
+                // Draw a styled line
+                $aImg->SetColor($p[1]);
+                $aImg->SetLineStyle($p[3]);
+                $aImg->StyleLine($x1-$this->mark_abs_hsize,$marky,$x1+$this->mark_abs_hsize,$marky);
+                $aImg->StyleLine($x1-$this->mark_abs_hsize,$marky+1,$x1+$this->mark_abs_hsize,$marky+1);
+            }
+            else {
+                // Draw a colored box
+                $color = $p[1] ;
+
+                // We make boxes slightly larger to better show
+                $boxsize = max($this->mark_abs_vsize,$this->mark_abs_hsize) + 2 ;
+
+                $ym = $marky-ceil($boxsize/2) ; // Marker y-coordinate
+
+                // We either need to plot a gradient or a
+                // pattern. To differentiate we use a kludge.
+                // Patterns have a p[3] value of < -100
+                if( $p[3] < -100 ) {
+                    // p[1][0] == iPattern, p[1][1] == iPatternColor, p[1][2] == iPatternDensity
+                    if( $patternFactory == null ) {
+                        $patternFactory = new RectPatternFactory();
+                    }
+                    $prect = $patternFactory->Create($p[1][0],$p[1][1],1);
+                    $prect->SetBackground($p[1][3]);
+                    $prect->SetDensity($p[1][2]+1);
+                    $prect->SetPos(new Rectangle($x1,$ym,$boxsize,$boxsize));
+                    $prect->Stroke($aImg);
+                    $prect=null;
+                }
+                else {
+                    if( is_array($color) && count($color)==2 ) {
+                        // The client want a gradient color
+                        $grad->FilledRectangle($x1-$boxsize/2,$ym,
+                                               $x1+$boxsize/2,$ym+$boxsize,
+                                               $color[0],$color[1],-$p[3]);
+                    }
+                    else {
+                        $aImg->SetColor($p[1]);
+                        $aImg->FilledRectangle($x1-$boxsize/2,$ym, $x1+$boxsize/2,$ym+$boxsize);
+                    }
+
+                    // Draw a plot frame line
+                    $aImg->SetColor($this->color);
+                    $aImg->SetLineWeight($fillBoxFrameWeight);
+                    $aImg->Rectangle($x1-$boxsize/2,$ym,
+                                     $x1+$boxsize/2,$ym+$boxsize);
+                }
+            }
+            $aImg->SetColor($this->font_color);
+            $aImg->SetFont($this->font_family,$this->font_style,$this->font_size);
+            $aImg->SetTextAlign('left','baseline');
+
+            $debug=false;
+            $aImg->StrokeText($x1+$this->mark_abs_hsize+$this->xmargin,$y1,$p[0],
+                0,'left',$debug);
+
+            // Add CSIM for Legend if defined
+            if( !empty($p[4]) ) {
+
+                $xs = $x1 - $this->mark_abs_hsize ;
+                $ys = $y1 + 1 ;
+                $xe = $x1 + $aImg->GetTextWidth($p[0]) + $this->mark_abs_hsize + $this->xmargin ;
+                $ye = $y1-$rowheight[$row]+1;
+                $coords = "$xs,$ys,$xe,$y1,$xe,$ye,$xs,$ye";
+                if( ! empty($p[4]) ) {
+                    $this->csimareas .= "<area shape=\"poly\" coords=\"$coords\" href=\"".htmlentities($p[4])."\"";
+
+                    if( !empty($p[6]) ) {
+                        $this->csimareas .= " target=\"".$p[6]."\"";
+                    }
+
+                    if( !empty($p[5]) ) {
+                        $tmp=sprintf($p[5],$p[0]);
+                        $this->csimareas .= " title=\"$tmp\" alt=\"$tmp\" ";
+                    }
+                    $this->csimareas .= " />\n";
+                }
+            }
+
+            if( $i >= $this->layout_n ) {
+                $x1 = $xp+$this->xlmargin;
+                $row++;
+                if( !empty($rowheight[$row]) )
+                    $y1 += $rowheight[$row];
+                $i = 1;
+            }
+            else {
+                $x1 += $colwidth[($i-1) % $numcolumns] ;
+                ++$i;
+            }
+        }
+    }
+} // Class
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_line.php b/web/classes/jpgraph/jpgraph_line.php
new file mode 100755
index 0000000000000000000000000000000000000000..21dd821304550c5cb427a373dac05024bb1add44
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_line.php
@@ -0,0 +1,682 @@
+<?php
+/*=======================================================================
+ // File:  		 JPGRAPH_LINE.PHP
+ // Description: Line plot extension for JpGraph
+ // Created:  	 2001-01-08
+ // Ver:  		 $Id: jpgraph_line.php 1921 2009-12-11 11:46:39Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+require_once ('jpgraph_plotmark.inc.php');
+
+// constants for the (filled) area
+DEFINE("LP_AREA_FILLED", true);
+DEFINE("LP_AREA_NOT_FILLED", false);
+DEFINE("LP_AREA_BORDER",false);
+DEFINE("LP_AREA_NO_BORDER",true);
+
+//===================================================
+// CLASS LinePlot
+// Description:
+//===================================================
+class LinePlot extends Plot{
+    public $mark=null;
+    protected $filled=false;
+    protected $fill_color='blue';
+    protected $step_style=false, $center=false;
+    protected $line_style=1; // Default to solid
+    protected $filledAreas = array(); // array of arrays(with min,max,col,filled in them)
+    public $barcenter=false;  // When we mix line and bar. Should we center the line in the bar.
+    protected $fillFromMin = false, $fillFromMax = false;
+    protected $fillgrad=false,$fillgrad_fromcolor='navy',$fillgrad_tocolor='silver',$fillgrad_numcolors=100;
+    protected $iFastStroke=false;
+
+    //---------------
+    // CONSTRUCTOR
+    function LinePlot($datay,$datax=false) {
+        parent::__construct($datay,$datax);
+        $this->mark = new PlotMark() ;
+        $this->color = ColorFactory::getColor();
+        $this->fill_color = $this->color;
+    }
+    //---------------
+    // PUBLIC METHODS
+
+    function SetFilled($aFlg=true) {
+		$this->filled = $aFlg;
+    }
+
+    function SetBarCenter($aFlag=true) {
+        $this->barcenter=$aFlag;
+    }
+
+    function SetStyle($aStyle) {
+        $this->line_style=$aStyle;
+    }
+
+    function SetStepStyle($aFlag=true) {
+        $this->step_style = $aFlag;
+    }
+
+    function SetColor($aColor) {
+        parent::SetColor($aColor);
+    }
+
+    function SetFillFromYMin($f=true) {
+        $this->fillFromMin = $f ;
+    }
+
+    function SetFillFromYMax($f=true) {
+        $this->fillFromMax = $f ;
+    }
+
+    function SetFillColor($aColor,$aFilled=true) {
+    	//$this->color = $aColor;
+        $this->fill_color=$aColor;
+        $this->filled=$aFilled;
+    }
+
+    function SetFillGradient($aFromColor,$aToColor,$aNumColors=100,$aFilled=true) {
+        $this->fillgrad_fromcolor = $aFromColor;
+        $this->fillgrad_tocolor   = $aToColor;
+        $this->fillgrad_numcolors = $aNumColors;
+        $this->filled = $aFilled;
+        $this->fillgrad = true;
+    }
+
+    function Legend($graph) {
+        if( $this->legend!="" ) {
+            if( $this->filled && !$this->fillgrad ) {
+                $graph->legend->Add($this->legend,
+                $this->fill_color,$this->mark,0,
+                $this->legendcsimtarget,$this->legendcsimalt,$this->legendcsimwintarget);
+            }
+            elseif( $this->fillgrad ) {
+                $color=array($this->fillgrad_fromcolor,$this->fillgrad_tocolor);
+                // In order to differentiate between gradients and cooors specified as an RGB triple
+                $graph->legend->Add($this->legend,$color,"",-2 /* -GRAD_HOR */,
+                $this->legendcsimtarget,$this->legendcsimalt,$this->legendcsimwintarget);
+            } else {
+                $graph->legend->Add($this->legend,
+                $this->color,$this->mark,$this->line_style,
+                $this->legendcsimtarget,$this->legendcsimalt,$this->legendcsimwintarget);
+            }
+        }
+    }
+
+    function AddArea($aMin=0,$aMax=0,$aFilled=LP_AREA_NOT_FILLED,$aColor="gray9",$aBorder=LP_AREA_BORDER) {
+        if($aMin > $aMax) {
+            // swap
+            $tmp = $aMin;
+            $aMin = $aMax;
+            $aMax = $tmp;
+        }
+        $this->filledAreas[] = array($aMin,$aMax,$aColor,$aFilled,$aBorder);
+    }
+
+    // Gets called before any axis are stroked
+    function PreStrokeAdjust($graph) {
+
+        // If another plot type have already adjusted the
+        // offset we don't touch it.
+        // (We check for empty in case the scale is  a log scale
+        // and hence doesn't contain any xlabel_offset)
+        if( empty($graph->xaxis->scale->ticks->xlabel_offset) || $graph->xaxis->scale->ticks->xlabel_offset == 0 ) {
+            if( $this->center ) {
+                ++$this->numpoints;
+                $a=0.5; $b=0.5;
+            } else {
+                $a=0; $b=0;
+            }
+            $graph->xaxis->scale->ticks->SetXLabelOffset($a);
+            $graph->SetTextScaleOff($b);
+            //$graph->xaxis->scale->ticks->SupressMinorTickMarks();
+        }
+    }
+
+    function SetFastStroke($aFlg=true) {
+        $this->iFastStroke = $aFlg;
+    }
+
+    function FastStroke($img,$xscale,$yscale,$aStartPoint=0,$exist_x=true) {
+        // An optimized stroke for many data points with no extra
+        // features but 60% faster. You can't have values or line styles, or null
+        // values in plots.
+        $numpoints=count($this->coords[0]);
+        if( $this->barcenter ) {
+            $textadj = 0.5-$xscale->text_scale_off;
+        }
+        else {
+            $textadj = 0;
+        }
+
+        $img->SetColor($this->color);
+        $img->SetLineWeight($this->weight);
+        $pnts=$aStartPoint;
+        while( $pnts < $numpoints ) {
+            if( $exist_x ) {
+                $x=$this->coords[1][$pnts];
+            }
+            else {
+                $x=$pnts+$textadj;
+            }
+            $xt = $xscale->Translate($x);
+            $y=$this->coords[0][$pnts];
+            $yt = $yscale->Translate($y);
+            if( is_numeric($y) ) {
+                $cord[] = $xt;
+                $cord[] = $yt;
+            }
+            elseif( $y == '-' && $pnts > 0 ) {
+                // Just ignore
+            }
+            else {
+                JpGraphError::RaiseL(10002);//('Plot too complicated for fast line Stroke. Use standard Stroke()');
+            }
+            ++$pnts;
+        } // WHILE
+
+        $img->Polygon($cord,false,true);
+    }
+
+    function Stroke($img,$xscale,$yscale) {
+        $idx=0;
+        $numpoints=count($this->coords[0]);
+        if( isset($this->coords[1]) ) {
+            if( count($this->coords[1])!=$numpoints ) {
+                JpGraphError::RaiseL(2003,count($this->coords[1]),$numpoints);
+            //("Number of X and Y points are not equal. Number of X-points:".count($this->coords[1])." Number of Y-points:$numpoints");
+            }
+            else {
+                $exist_x = true;
+            }
+        }
+        else {
+            $exist_x = false;
+        }
+
+        if( $this->barcenter ) {
+            $textadj = 0.5-$xscale->text_scale_off;
+        }
+        else {
+            $textadj = 0;
+        }
+
+        // Find the first numeric data point
+        $startpoint=0;
+        while( $startpoint < $numpoints && !is_numeric($this->coords[0][$startpoint]) ) {
+            ++$startpoint;
+        }
+
+        // Bail out if no data points
+        if( $startpoint == $numpoints ) return;
+
+        if( $this->iFastStroke ) {
+            $this->FastStroke($img,$xscale,$yscale,$startpoint,$exist_x);
+            return;
+        }
+
+        if( $exist_x ) {
+            $xs=$this->coords[1][$startpoint];
+        }
+        else {
+            $xs= $textadj+$startpoint;
+        }
+
+        $img->SetStartPoint($xscale->Translate($xs),
+        $yscale->Translate($this->coords[0][$startpoint]));
+
+        if( $this->filled ) {
+            if( $this->fillFromMax ) {
+                //$max = $yscale->GetMaxVal();
+                $cord[$idx++] = $xscale->Translate($xs);
+                $cord[$idx++] = $yscale->scale_abs[1];
+            }
+            else {
+                $min = $yscale->GetMinVal();
+                if( $min > 0 || $this->fillFromMin ) {
+                    $fillmin = $yscale->scale_abs[0];//Translate($min);
+                }
+                else {
+                    $fillmin = $yscale->Translate(0);
+                }
+
+                $cord[$idx++] = $xscale->Translate($xs);
+                $cord[$idx++] = $fillmin;
+            }
+        }
+        $xt = $xscale->Translate($xs);
+        $yt = $yscale->Translate($this->coords[0][$startpoint]);
+        $cord[$idx++] = $xt;
+        $cord[$idx++] = $yt;
+        $yt_old = $yt;
+        $xt_old = $xt;
+        $y_old = $this->coords[0][$startpoint];
+
+        $this->value->Stroke($img,$this->coords[0][$startpoint],$xt,$yt);
+
+        $img->SetColor($this->color);
+        $img->SetLineWeight($this->weight);
+        $img->SetLineStyle($this->line_style);
+        $pnts=$startpoint+1;
+        $firstnonumeric = false;
+
+
+        while( $pnts < $numpoints ) {
+
+            if( $exist_x ) {
+                $x=$this->coords[1][$pnts];
+            }
+            else {
+                $x=$pnts+$textadj;
+            }
+            $xt = $xscale->Translate($x);
+            $yt = $yscale->Translate($this->coords[0][$pnts]);
+
+            $y=$this->coords[0][$pnts];
+            if( $this->step_style ) {
+                // To handle null values within step style we need to record the
+                // first non numeric value so we know from where to start if the
+                // non value is '-'.
+                if( is_numeric($y) ) {
+                    $firstnonumeric = false;
+                    if( is_numeric($y_old) ) {
+                        $img->StyleLine($xt_old,$yt_old,$xt,$yt_old);
+                        $img->StyleLine($xt,$yt_old,$xt,$yt);
+                    }
+                    elseif( $y_old == '-' ) {
+                        $img->StyleLine($xt_first,$yt_first,$xt,$yt_first);
+                        $img->StyleLine($xt,$yt_first,$xt,$yt);
+                    }
+                    else {
+                        $yt_old = $yt;
+                        $xt_old = $xt;
+                    }
+                    $cord[$idx++] = $xt;
+                    $cord[$idx++] = $yt_old;
+                    $cord[$idx++] = $xt;
+                    $cord[$idx++] = $yt;
+                }
+                elseif( $firstnonumeric==false ) {
+                    $firstnonumeric = true;
+                    $yt_first = $yt_old;
+                    $xt_first = $xt_old;
+                }
+            }
+            else {
+                $tmp1=$y;
+                $prev=$this->coords[0][$pnts-1];
+                if( $tmp1==='' || $tmp1===NULL || $tmp1==='X' ) $tmp1 = 'x';
+                if( $prev==='' || $prev===null || $prev==='X' ) $prev = 'x';
+
+                if( is_numeric($y) || (is_string($y) && $y != '-') ) {
+                    if( is_numeric($y) && (is_numeric($prev) || $prev === '-' ) ) {
+                        $img->StyleLineTo($xt,$yt);
+                    }
+                    else {
+                        $img->SetStartPoint($xt,$yt);
+                    }
+                }
+                if( $this->filled && $tmp1 !== '-' ) {
+                    if( $tmp1 === 'x' ) {
+                        $cord[$idx++] = $cord[$idx-3];
+                        $cord[$idx++] = $fillmin;
+                    }
+                    elseif( $prev === 'x' ) {
+                        $cord[$idx++] = $xt;
+                        $cord[$idx++] = $fillmin;
+                        $cord[$idx++] = $xt;
+                        $cord[$idx++] = $yt;
+                    }
+                    else {
+                        $cord[$idx++] = $xt;
+                        $cord[$idx++] = $yt;
+                    }
+                }
+                else {
+                    if( is_numeric($tmp1)  && (is_numeric($prev) || $prev === '-' ) ) {
+                        $cord[$idx++] = $xt;
+                        $cord[$idx++] = $yt;
+                    }
+                }
+            }
+            $yt_old = $yt;
+            $xt_old = $xt;
+            $y_old = $y;
+
+            $this->StrokeDataValue($img,$this->coords[0][$pnts],$xt,$yt);
+
+            ++$pnts;
+        }
+
+        if( $this->filled  ) {
+            $cord[$idx++] = $xt;
+            if( $this->fillFromMax ) {
+                $cord[$idx++] = $yscale->scale_abs[1];
+            }
+            else {
+                if( $min > 0 || $this->fillFromMin ) {
+                    $cord[$idx++] = $yscale->Translate($min);
+                }
+                else {
+                    $cord[$idx++] = $yscale->Translate(0);
+                }
+            }
+            if( $this->fillgrad ) {
+                $img->SetLineWeight(1);
+                $grad = new Gradient($img);
+                $grad->SetNumColors($this->fillgrad_numcolors);
+                $grad->FilledFlatPolygon($cord,$this->fillgrad_fromcolor,$this->fillgrad_tocolor);
+                $img->SetLineWeight($this->weight);
+            }
+            else {
+                $img->SetColor($this->fill_color);
+                $img->FilledPolygon($cord);
+            }
+            if( $this->weight > 0 ) { 
+                $img->SetLineWeight($this->weight);
+                $img->SetColor($this->color);
+                // Remove first and last coordinate before drawing the line
+                // sine we otherwise get the vertical start and end lines which
+                // doesn't look appropriate
+                $img->Polygon(array_slice($cord,2,count($cord)-4));
+            }
+        }
+
+        if(!empty($this->filledAreas)) {
+
+            $minY = $yscale->Translate($yscale->GetMinVal());
+            $factor = ($this->step_style ? 4 : 2);
+
+            for($i = 0; $i < sizeof($this->filledAreas); ++$i) {
+                // go through all filled area elements ordered by insertion
+                // fill polygon array
+                $areaCoords[] = $cord[$this->filledAreas[$i][0] * $factor];
+                $areaCoords[] = $minY;
+
+                $areaCoords =
+                array_merge($areaCoords,
+                array_slice($cord,
+                $this->filledAreas[$i][0] * $factor,
+                ($this->filledAreas[$i][1] - $this->filledAreas[$i][0] + ($this->step_style ? 0 : 1))  * $factor));
+                $areaCoords[] = $areaCoords[sizeof($areaCoords)-2]; // last x
+                $areaCoords[] = $minY; // last y
+
+                if($this->filledAreas[$i][3]) {
+                    $img->SetColor($this->filledAreas[$i][2]);
+                    $img->FilledPolygon($areaCoords);
+                    $img->SetColor($this->color);
+                }
+                // Check if we should draw the frame.
+                // If not we still re-draw the line since it might have been
+                // partially overwritten by the filled area and it doesn't look
+                // very good.
+                if( $this->filledAreas[$i][4] ) {
+                    $img->Polygon($areaCoords);
+                }
+                else {
+                    $img->Polygon($cord);
+                }
+
+                $areaCoords = array();
+            }
+        }
+
+        if( $this->mark->type == -1 || $this->mark->show == false )
+        return;
+
+        for( $pnts=0; $pnts<$numpoints; ++$pnts) {
+
+            if( $exist_x ) {
+                $x=$this->coords[1][$pnts];
+            }
+            else {
+                $x=$pnts+$textadj;
+            }
+            $xt = $xscale->Translate($x);
+            $yt = $yscale->Translate($this->coords[0][$pnts]);
+
+            if( is_numeric($this->coords[0][$pnts]) ) {
+                if( !empty($this->csimtargets[$pnts]) ) {
+                    if( !empty($this->csimwintargets[$pnts]) ) {
+                        $this->mark->SetCSIMTarget($this->csimtargets[$pnts],$this->csimwintargets[$pnts]);
+                    }
+                    else {
+                        $this->mark->SetCSIMTarget($this->csimtargets[$pnts]);
+                    }
+                    $this->mark->SetCSIMAlt($this->csimalts[$pnts]);
+                }
+                if( $exist_x ) {
+                    $x=$this->coords[1][$pnts];
+                }
+                else {
+                    $x=$pnts;
+                }
+                $this->mark->SetCSIMAltVal($this->coords[0][$pnts],$x);
+                $this->mark->Stroke($img,$xt,$yt);
+                $this->csimareas .= $this->mark->GetCSIMAreas();
+            }
+        }
+    }
+} // Class
+
+
+//===================================================
+// CLASS AccLinePlot
+// Description:
+//===================================================
+class AccLinePlot extends Plot {
+    protected $plots=null,$nbrplots=0;
+    private $iStartEndZero=true;
+    //---------------
+    // CONSTRUCTOR
+    function __construct($plots) {
+        $this->plots = $plots;
+        $this->nbrplots = count($plots);
+        $this->numpoints = $plots[0]->numpoints;
+
+        // Verify that all plots have the same number of data points
+        for( $i=1; $i < $this->nbrplots; ++$i ) {
+            if( $plots[$i]->numpoints != $this->numpoints ) {
+                JpGraphError::RaiseL(10003);//('Each plot in an accumulated lineplot must have the same number of data points',0)
+            }
+        }
+
+        for($i=0; $i < $this->nbrplots; ++$i ) {
+            $this->LineInterpolate($this->plots[$i]->coords[0]);
+        }
+    }
+
+    //---------------
+    // PUBLIC METHODS
+    function Legend($graph) {
+        foreach( $this->plots as $p ) {
+            $p->DoLegend($graph);
+        }
+    }
+
+    function Max() {
+        list($xmax) = $this->plots[0]->Max();
+        $nmax=0;
+        $n = count($this->plots);
+        for($i=0; $i < $n; ++$i) {
+            $nc = count($this->plots[$i]->coords[0]);
+            $nmax = max($nmax,$nc);
+            list($x) = $this->plots[$i]->Max();
+            $xmax = Max($xmax,$x);
+        }
+        for( $i = 0; $i < $nmax; $i++ ) {
+            // Get y-value for line $i by adding the
+            // individual bars from all the plots added.
+            // It would be wrong to just add the
+            // individual plots max y-value since that
+            // would in most cases give to large y-value.
+            $y=$this->plots[0]->coords[0][$i];
+            for( $j = 1; $j < $this->nbrplots; $j++ ) {
+                $y += $this->plots[ $j ]->coords[0][$i];
+            }
+            $ymax[$i] = $y;
+        }
+        $ymax = max($ymax);
+        return array($xmax,$ymax);
+    }
+
+    function Min() {
+        $nmax=0;
+        list($xmin,$ysetmin) = $this->plots[0]->Min();
+        $n = count($this->plots);
+        for($i=0; $i < $n; ++$i) {
+            $nc = count($this->plots[$i]->coords[0]);
+            $nmax = max($nmax,$nc);
+            list($x,$y) = $this->plots[$i]->Min();
+            $xmin = Min($xmin,$x);
+            $ysetmin = Min($y,$ysetmin);
+        }
+        for( $i = 0; $i < $nmax; $i++ ) {
+            // Get y-value for line $i by adding the
+            // individual bars from all the plots added.
+            // It would be wrong to just add the
+            // individual plots min y-value since that
+            // would in most cases give to small y-value.
+            $y=$this->plots[0]->coords[0][$i];
+            for( $j = 1; $j < $this->nbrplots; $j++ ) {
+                $y += $this->plots[ $j ]->coords[0][$i];
+            }
+            $ymin[$i] = $y;
+        }
+        $ymin = Min($ysetmin,Min($ymin));
+        return array($xmin,$ymin);
+    }
+
+    // Gets called before any axis are stroked
+    function PreStrokeAdjust($graph) {
+
+        // If another plot type have already adjusted the
+        // offset we don't touch it.
+        // (We check for empty in case the scale is  a log scale
+        // and hence doesn't contain any xlabel_offset)
+
+        if( empty($graph->xaxis->scale->ticks->xlabel_offset) ||
+        $graph->xaxis->scale->ticks->xlabel_offset == 0 ) {
+            if( $this->center ) {
+                ++$this->numpoints;
+                $a=0.5; $b=0.5;
+            } else {
+                $a=0; $b=0;
+            }
+            $graph->xaxis->scale->ticks->SetXLabelOffset($a);
+            $graph->SetTextScaleOff($b);
+            $graph->xaxis->scale->ticks->SupressMinorTickMarks();
+        }
+
+    }
+
+    function SetInterpolateMode($aIntMode) {
+        $this->iStartEndZero=$aIntMode;
+    }
+
+    // Replace all '-' with an interpolated value. We use straightforward
+    // linear interpolation. If the data starts with one or several '-' they
+    // will be replaced by the the first valid data point
+    function LineInterpolate(&$aData) {
+
+        $n=count($aData);
+        $i=0;
+
+        // If first point is undefined we will set it to the same as the first
+        // valid data
+        if( $aData[$i]==='-' ) {
+            // Find the first valid data
+            while( $i < $n && $aData[$i]==='-' ) {
+                ++$i;
+            }
+            if( $i < $n ) {
+                for($j=0; $j < $i; ++$j ) {
+                    if( $this->iStartEndZero )
+                    $aData[$i] = 0;
+                    else
+                    $aData[$j] = $aData[$i];
+                }
+            }
+            else {
+                // All '-' => Error
+                return false;
+            }
+        }
+
+        while($i < $n) {
+            while( $i < $n && $aData[$i] !== '-' ) {
+                ++$i;
+            }
+            if( $i < $n ) {
+                $pstart=$i-1;
+
+                // Now see how long this segment of '-' are
+                while( $i < $n && $aData[$i] === '-' ) {
+                    ++$i;
+                }
+                if( $i < $n ) {
+                    $pend=$i;
+                    $size=$pend-$pstart;
+                    $k=($aData[$pend]-$aData[$pstart])/$size;
+                    // Replace the segment of '-' with a linear interpolated value.
+                    for($j=1; $j < $size; ++$j ) {
+                        $aData[$pstart+$j] = $aData[$pstart] + $j*$k ;
+                    }
+                }
+                else {
+                    // There are no valid end point. The '-' goes all the way to the end
+                    // In that case we just set all the remaining values the the same as the
+                    // last valid data point.
+                    for( $j=$pstart+1; $j < $n; ++$j )
+                    if( $this->iStartEndZero ) {
+                        $aData[$j] = 0;
+                    }
+                    else {
+                        $aData[$j] = $aData[$pstart] ;
+                    }
+                }
+            }
+        }
+        return true;
+    }
+
+    // To avoid duplicate of line drawing code here we just
+    // change the y-values for each plot and then restore it
+    // after we have made the stroke. We must do this copy since
+    // it wouldn't be possible to create an acc line plot
+    // with the same graphs, i.e AccLinePlot(array($pl,$pl,$pl));
+    // since this method would have a side effect.
+    function Stroke($img,$xscale,$yscale) {
+        $img->SetLineWeight($this->weight);
+        $this->numpoints = count($this->plots[0]->coords[0]);
+        // Allocate array
+        $coords[$this->nbrplots][$this->numpoints]=0;
+        for($i=0; $i<$this->numpoints; $i++) {
+            $coords[0][$i]=$this->plots[0]->coords[0][$i];
+            $accy=$coords[0][$i];
+            for($j=1; $j<$this->nbrplots; ++$j ) {
+                $coords[$j][$i] = $this->plots[$j]->coords[0][$i]+$accy;
+                $accy = $coords[$j][$i];
+            }
+        }
+        for($j=$this->nbrplots-1; $j>=0; --$j) {
+            $p=$this->plots[$j];
+            for( $i=0; $i<$this->numpoints; ++$i) {
+                $tmp[$i]=$p->coords[0][$i];
+                $p->coords[0][$i]=$coords[$j][$i];
+            }
+            $p->Stroke($img,$xscale,$yscale);
+            for( $i=0; $i<$this->numpoints; ++$i) {
+                $p->coords[0][$i]=$tmp[$i];
+            }
+            $p->coords[0][]=$tmp;
+        }
+    }
+} // Class
+
+
+/* EOF */
+?>
diff --git a/web/classes/jpgraph/jpgraph_log.php b/web/classes/jpgraph/jpgraph_log.php
new file mode 100755
index 0000000000000000000000000000000000000000..d5146ecd8aa3d294461d73113965e7f776d1b65c
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_log.php
@@ -0,0 +1,305 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_LOG.PHP
+ // Description: Log scale plot extension for JpGraph
+ // Created:     2001-01-08
+ // Ver:         $Id: jpgraph_log.php 1106 2009-02-22 20:16:35Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+DEFINE('LOGLABELS_PLAIN',0);
+DEFINE('LOGLABELS_MAGNITUDE',1);
+
+//===================================================
+// CLASS LogScale
+// Description: Logarithmic scale between world and screen
+//===================================================
+class LogScale extends LinearScale {
+    //---------------
+    // CONSTRUCTOR
+
+    // Log scale is specified using the log of min and max
+    function __construct($min,$max,$type="y") {
+        parent::__construct($min,$max,$type);
+        $this->ticks = new LogTicks();
+        $this->name = 'log';
+    }
+
+    //----------------
+    // PUBLIC METHODS
+
+    // Translate between world and screen
+    function Translate($a) {
+        if( !is_numeric($a) ) {
+            if( $a != '' && $a != '-' && $a != 'x' ) { 
+                JpGraphError::RaiseL(11001);
+                // ('Your data contains non-numeric values.');
+            }
+            return 1;
+        }
+        if( $a < 0 ) {
+            JpGraphError::RaiseL(11002);
+            //("Negative data values can not be used in a log scale.");
+            exit(1);
+        }
+        if( $a==0 ) $a=1;
+        $a=log10($a);
+        return ceil($this->off + ($a*1.0 - $this->scale[0]) * $this->scale_factor);
+    }
+
+    // Relative translate (don't include offset) usefull when we just want
+    // to know the relative position (in pixels) on the axis
+    function RelTranslate($a) {
+        if( !is_numeric($a) ) {
+            if( $a != '' && $a != '-' && $a != 'x' ) {
+                JpGraphError::RaiseL(11001);
+                //('Your data contains non-numeric values.');
+            }
+            return 1;
+        }
+        if( $a==0 ) {
+            $a=1;
+        }
+        $a=log10($a);
+        return round(($a*1.0 - $this->scale[0]) * $this->scale_factor);
+    }
+
+    // Use bcpow() for increased precision
+    function GetMinVal() {
+        if( function_exists("bcpow") ) {
+            return round(bcpow(10,$this->scale[0],15),14);
+        }
+        else {
+            return round(pow(10,$this->scale[0]),14);
+        }
+    }
+
+    function GetMaxVal() {
+        if( function_exists("bcpow") ) {
+            return round(bcpow(10,$this->scale[1],15),14);
+        }
+        else {
+            return round(pow(10,$this->scale[1]),14);
+        }
+    }
+
+    // Logarithmic autoscaling is much simplier since we just
+    // set the min and max to logs of the min and max values.
+    // Note that for log autoscale the "maxstep" the fourth argument
+    // isn't used. This is just included to give the method the same
+    // signature as the linear counterpart.
+    function AutoScale($img,$min,$max,$maxsteps,$majend=true) {
+        if( $min==0 ) $min=1;
+
+        if( $max <= 0 ) {
+            JpGraphError::RaiseL(11004);
+            //('Scale error for logarithmic scale. You have a problem with your data values. The max value must be greater than 0. It is mathematically impossible to have 0 in a logarithmic scale.');
+        }
+        if( is_numeric($this->autoscale_min) ) {
+            $smin = round($this->autoscale_min);
+            $smax = ceil(log10($max));
+            if( $min >= $max ) {
+                JpGraphError::RaiseL(25071);//('You have specified a min value with SetAutoMin() which is larger than the maximum value used for the scale. This is not possible.');
+            }
+        }
+        else {
+            $smin = floor(log10($min));
+            if( is_numeric($this->autoscale_max) ) {
+                $smax = round($this->autoscale_max);
+                if( $smin >= $smax ) {
+                    JpGraphError::RaiseL(25072);//('You have specified a max value with SetAutoMax() which is smaller than the miminum value used for the scale. This is not possible.');
+                }
+            }
+            else
+            $smax = ceil(log10($max));
+        }
+
+        $this->Update($img,$smin,$smax);
+    }
+    //---------------
+    // PRIVATE METHODS
+} // Class
+
+//===================================================
+// CLASS LogTicks
+// Description:
+//===================================================
+class LogTicks extends Ticks{
+    private $label_logtype=LOGLABELS_MAGNITUDE;
+    private $ticklabels_pos = array();
+    //---------------
+    // CONSTRUCTOR
+    function LogTicks() {
+    }
+    //---------------
+    // PUBLIC METHODS
+    function IsSpecified() {
+        return true;
+    }
+
+    function SetLabelLogType($aType) {
+        $this->label_logtype = $aType;
+    }
+
+    // For log scale it's meaningless to speak about a major step
+    // We just return -1 to make the framework happy (specifically
+    // StrokeLabels() )
+    function GetMajor() {
+        return -1;
+    }
+
+    function SetTextLabelStart($aStart) {
+        JpGraphError::RaiseL(11005);
+        //('Specifying tick interval for a logarithmic scale is undefined. Remove any calls to SetTextLabelStart() or SetTextTickInterval() on the logarithmic scale.');
+    }
+
+    function SetXLabelOffset($dummy) {
+        // For log scales we dont care about XLabel offset
+    }
+
+    // Draw ticks on image "img" using scale "scale". The axis absolute
+    // position in the image is specified in pos, i.e. for an x-axis
+    // it specifies the absolute y-coord and for Y-ticks it specified the
+    // absolute x-position.
+    function Stroke($img,$scale,$pos) {
+        $start = $scale->GetMinVal();
+        $limit = $scale->GetMaxVal();
+        $nextMajor = 10*$start;
+        $step = $nextMajor / 10.0;
+
+
+        $img->SetLineWeight($this->weight);
+
+        if( $scale->type == "y" ) {
+            // member direction specified if the ticks should be on
+            // left or right side.
+            $a=$pos + $this->direction*$this->GetMinTickAbsSize();
+            $a2=$pos + $this->direction*$this->GetMajTickAbsSize();
+             
+            $count=1;
+            $this->maj_ticks_pos[0]=$scale->Translate($start);
+            $this->maj_ticklabels_pos[0]=$scale->Translate($start);
+            if( $this->supress_first )
+            $this->maj_ticks_label[0]="";
+            else {
+                if( $this->label_formfunc != '' ) {
+                    $f = $this->label_formfunc;
+                    $this->maj_ticks_label[0]=call_user_func($f,$start);
+                }
+                elseif( $this->label_logtype == LOGLABELS_PLAIN ) {
+                    $this->maj_ticks_label[0]=$start;
+                }
+                else {
+                    $this->maj_ticks_label[0]='10^'.round(log10($start));
+                }
+            }
+            $i=1;
+            for($y=$start; $y<=$limit; $y+=$step,++$count  ) {
+                $ys=$scale->Translate($y);
+                $this->ticks_pos[]=$ys;
+                $this->ticklabels_pos[]=$ys;
+                if( $count % 10 == 0 ) {
+                    if( !$this->supress_tickmarks ) {
+                        if( $this->majcolor!="" ) {
+                            $img->PushColor($this->majcolor);
+                            $img->Line($pos,$ys,$a2,$ys);
+                            $img->PopColor();
+                        }
+                        else {
+                            $img->Line($pos,$ys,$a2,$ys);
+                        }
+                    }
+
+                    $this->maj_ticks_pos[$i]=$ys;
+                    $this->maj_ticklabels_pos[$i]=$ys;
+
+                    if( $this->label_formfunc != '' ) {
+                        $f = $this->label_formfunc;
+                        $this->maj_ticks_label[$i]=call_user_func($f,$nextMajor);
+                    }
+                    elseif( $this->label_logtype == 0 ) {
+                        $this->maj_ticks_label[$i]=$nextMajor;
+                    }
+                    else {
+                        $this->maj_ticks_label[$i]='10^'.round(log10($nextMajor));
+                    }
+                    ++$i;
+                    $nextMajor *= 10;
+                    $step *= 10;
+                    $count=1;
+                }
+                else {
+                    if( !$this->supress_tickmarks && !$this->supress_minor_tickmarks) {
+                        if( $this->mincolor!="" ) {
+                            $img->PushColor($this->mincolor);
+                        }
+                        $img->Line($pos,$ys,$a,$ys);
+                        if( $this->mincolor!="" ) {
+                            $img->PopColor();
+                        }
+                    }
+                }
+            }
+        }
+        else {
+            $a=$pos - $this->direction*$this->GetMinTickAbsSize();
+            $a2=$pos - $this->direction*$this->GetMajTickAbsSize();
+            $count=1;
+            $this->maj_ticks_pos[0]=$scale->Translate($start);
+            $this->maj_ticklabels_pos[0]=$scale->Translate($start);
+            if( $this->supress_first ) {
+                $this->maj_ticks_label[0]="";
+            }
+            else {
+                if( $this->label_formfunc != '' ) {
+                    $f = $this->label_formfunc;
+                    $this->maj_ticks_label[0]=call_user_func($f,$start);
+                }
+                elseif( $this->label_logtype == 0 ) {
+                    $this->maj_ticks_label[0]=$start;
+                }
+                else {
+                    $this->maj_ticks_label[0]='10^'.round(log10($start));
+                }
+            }
+            $i=1;
+            for($x=$start; $x<=$limit; $x+=$step,++$count  ) {
+                $xs=$scale->Translate($x);
+                $this->ticks_pos[]=$xs;
+                $this->ticklabels_pos[]=$xs;
+                if( $count % 10 == 0 ) {
+                    if( !$this->supress_tickmarks ) {
+                        $img->Line($xs,$pos,$xs,$a2);
+                    }
+                    $this->maj_ticks_pos[$i]=$xs;
+                    $this->maj_ticklabels_pos[$i]=$xs;
+
+                    if( $this->label_formfunc != '' ) {
+                        $f = $this->label_formfunc;
+                        $this->maj_ticks_label[$i]=call_user_func($f,$nextMajor);
+                    }
+                    elseif( $this->label_logtype == 0 ) {
+                        $this->maj_ticks_label[$i]=$nextMajor;
+                    }
+                    else {
+                        $this->maj_ticks_label[$i]='10^'.round(log10($nextMajor));
+                    }
+                    ++$i;
+                    $nextMajor *= 10;
+                    $step *= 10;
+                    $count=1;
+                }
+                else {
+                    if( !$this->supress_tickmarks && !$this->supress_minor_tickmarks) {
+                        $img->Line($xs,$pos,$xs,$a);
+                    }
+                }
+            }
+        }
+        return true;
+    }
+} // Class
+/* EOF */
+?>
diff --git a/web/classes/jpgraph/jpgraph_meshinterpolate.inc.php b/web/classes/jpgraph/jpgraph_meshinterpolate.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..7e8ae5355ff695d502f679de8db04f09097ecadf
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_meshinterpolate.inc.php
@@ -0,0 +1,105 @@
+<?php
+/*=======================================================================
+// File:        JPGRAPH_MESHINTERPOLATE.INC.PHP
+// Description: Utility class to do mesh linear interpolation of a matrix
+// Created:     2009-03-09
+// Ver:         $Id: jpgraph_meshinterpolate.inc.php 1709 2009-07-30 08:00:08Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+*/
+  
+/**
+* Utility function to do linear mesh interpolation
+* @param $aDat Matrix to interpolate
+* @param $aFactor Interpolation factor  
+*/
+function doMeshInterpolate( &$aData, $aFactor ) {
+    $m = new MeshInterpolate();
+    $aData = $m->Linear($aData,$aFactor);
+}
+
+/**
+ * Utility class to interpolate a given data matrix
+ *
+ */
+class MeshInterpolate {
+    private $data = array();
+
+   /**
+    * Calculate the mid points of the given rectangle which has its top left
+    * corner at $row,$col. The $aFactordecides how many spliots should be done.
+    * i.e. how many more divisions should be done recursively
+    *
+    * @param $row Top left corner of square to work with
+    * @param $col Top left corner of square to work with
+    * $param $aFactor In how many subsquare should we split this square. A value of 1 indicates that no action
+    */
+    function IntSquare( $aRow, $aCol, $aFactor ) {
+        if ( $aFactor <= 1 )
+            return;
+
+        $step = pow( 2, $aFactor-1 );
+
+        $v0 = $this->data[$aRow][$aCol];
+        $v1 = $this->data[$aRow][$aCol + $step];
+        $v2 = $this->data[$aRow + $step][$aCol];
+        $v3 = $this->data[$aRow + $step][$aCol + $step];
+
+        $this->data[$aRow][$aCol + $step / 2] = ( $v0 + $v1 ) / 2;
+        $this->data[$aRow + $step / 2][$aCol] = ( $v0 + $v2 ) / 2;
+        $this->data[$aRow + $step][$aCol + $step / 2] = ( $v2 + $v3 ) / 2;
+        $this->data[$aRow + $step / 2][$aCol + $step] = ( $v1 + $v3 ) / 2;
+        $this->data[$aRow + $step / 2][$aCol + $step / 2] = ( $v0 + $v1 + $v2 + $v3 ) / 4;
+
+        $this->IntSquare( $aRow, $aCol, $aFactor-1 );
+        $this->IntSquare( $aRow, $aCol + $step / 2, $aFactor-1 );
+        $this->IntSquare( $aRow + $step / 2, $aCol, $aFactor-1 );
+        $this->IntSquare( $aRow + $step / 2, $aCol + $step / 2, $aFactor-1 );
+    }
+
+    /**
+     * Interpolate values in a matrice so that the total number of data points
+     * in vert and horizontal axis are $aIntNbr more. For example $aIntNbr=2 will
+     * make the data matrice have tiwce as many vertical and horizontal dta points.
+     *
+     * Note: This will blow up the matrcide in memory size in the order of $aInNbr^2
+     *
+     * @param  $ &$aData The original data matricde
+     * @param  $aInNbr Interpolation factor
+     * @return the interpolated matrice
+     */
+    function Linear( &$aData, $aIntFactor ) {
+        $step = pow( 2, $aIntFactor-1 );
+
+        $orig_cols = count( $aData[0] );
+        $orig_rows = count( $aData );
+        // Number of new columns/rows
+        // N = (a-1) * 2^(f-1) + 1
+        $p = pow( 2, $aIntFactor-1 );
+        $new_cols = $p * ( $orig_cols - 1 ) + 1;
+        $new_rows = $p * ( $orig_rows - 1 ) + 1;
+
+        $this->data = array_fill( 0, $new_rows, array_fill( 0, $new_cols, 0 ) );
+        // Initialize the new matrix with the values that we know
+        for ( $i = 0; $i < $new_rows; $i++ ) {
+            for ( $j = 0; $j < $new_cols; $j++ ) {
+                $v = 0 ;
+                if ( ( $i % $step == 0 ) && ( $j % $step == 0 ) ) {
+                    $v = $aData[$i / $step][$j / $step];
+                }
+                $this->data[$i][$j] = $v;
+            }
+        }
+
+        for ( $i = 0; $i < $new_rows-1; $i += $step ) {
+            for ( $j = 0; $j < $new_cols-1; $j += $step ) {
+                $this->IntSquare( $i, $j, $aIntFactor );
+            }
+        }
+
+        return $this->data;
+    }
+}
+  
+?>
diff --git a/web/classes/jpgraph/jpgraph_mgraph.php b/web/classes/jpgraph/jpgraph_mgraph.php
new file mode 100755
index 0000000000000000000000000000000000000000..80b2b6d71e111a33c7af5379d420b9c1b6bac055
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_mgraph.php
@@ -0,0 +1,345 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_MGRAPH.PHP
+ // Description: Class to handle multiple graphs in the same image
+ // Created:     2006-01-15
+ // Ver:         $Id: jpgraph_mgraph.php 1770 2009-08-17 06:10:22Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+//=============================================================================
+// CLASS MGraph
+// Description: Create a container image that can hold several graph
+//=============================================================================
+class MGraph {
+
+    public $title = null, $subtitle = null, $subsubtitle = null;
+
+    protected $img=NULL;
+    protected $iCnt=0,$iGraphs = array(); // image_handle, x, y, fx, fy, sizex, sizey
+    protected $iFillColor='white', $iCurrentColor=0;
+    protected $lm=4,$rm=4,$tm=4,$bm=4;
+    protected $iDoFrame = FALSE, $iFrameColor = 'black', $iFrameWeight = 1;
+    protected $iLineWeight = 1;
+    protected $expired=false;
+    protected $cache=null,$cache_name = '',$inline=true;
+    protected $image_format='png',$image_quality=75;
+    protected $iWidth=NULL,$iHeight=NULL;
+    protected $background_image='',$background_image_center=true,
+    $backround_image_format='',$background_image_mix=100,
+    $background_image_y=NULL, $background_image_x=NULL;
+    private $doshadow=false, $shadow_width=4, $shadow_color='gray@0.5';
+    public $footer;
+
+
+    // Create a new instane of the combined graph
+    function __construct($aWidth=NULL,$aHeight=NULL,$aCachedName='',$aTimeOut=0,$aInline=true) {
+        $this->iWidth = $aWidth;
+        $this->iHeight = $aHeight;
+
+        // If the cached version exist just read it directly from the
+        // cache, stream it back to browser and exit
+        if( $aCachedName!='' && READ_CACHE && $aInline ) {
+            $this->cache = new ImgStreamCache();
+            $this->cache->SetTimeOut($aTimeOut);
+            $image = new Image();
+            if( $this->cache->GetAndStream($image,$aCachedName) ) {
+                exit();
+            }
+        }
+        $this->inline = $aInline;
+        $this->cache_name = $aCachedName;
+
+        $this->title = new Text();
+        $this->title->ParagraphAlign('center');
+        $this->title->SetFont(FF_FONT2,FS_BOLD);
+        $this->title->SetMargin(3);
+        $this->title->SetAlign('center');
+
+        $this->subtitle = new Text();
+        $this->subtitle->ParagraphAlign('center');
+        $this->subtitle->SetFont(FF_FONT1,FS_BOLD);
+        $this->subtitle->SetMargin(3);
+        $this->subtitle->SetAlign('center');
+
+        $this->subsubtitle = new Text();
+        $this->subsubtitle->ParagraphAlign('center');
+        $this->subsubtitle->SetFont(FF_FONT1,FS_NORMAL);
+        $this->subsubtitle->SetMargin(3);
+        $this->subsubtitle->SetAlign('center');
+
+        $this->footer = new Footer();
+
+    }
+
+    // Specify background fill color for the combined graph
+    function SetFillColor($aColor) {
+        $this->iFillColor = $aColor;
+    }
+
+    // Add a frame around the combined graph
+    function SetFrame($aFlg,$aColor='black',$aWeight=1) {
+        $this->iDoFrame = $aFlg;
+        $this->iFrameColor = $aColor;
+        $this->iFrameWeight = $aWeight;
+    }
+
+    // Specify a background image blend
+    function SetBackgroundImageMix($aMix) {
+        $this->background_image_mix = $aMix ;
+    }
+
+    // Specify a background image
+    function SetBackgroundImage($aFileName,$aCenter_aX=NULL,$aY=NULL) {
+        // Second argument can be either a boolean value or
+        // a numeric
+        $aCenter=TRUE;
+        $aX=NULL;
+
+        if( is_numeric($aCenter_aX) ) {
+            $aX=$aCenter_aX;
+        }
+
+        // Get extension to determine image type
+        $e = explode('.',$aFileName);
+        if( !$e ) {
+            JpGraphError::RaiseL(12002,$aFileName);
+            //('Incorrect file name for MGraph::SetBackgroundImage() : '.$aFileName.' Must have a valid image extension (jpg,gif,png) when using autodetection of image type');
+        }
+
+        $valid_formats = array('png', 'jpg', 'gif');
+        $aImgFormat = strtolower($e[count($e)-1]);
+        if ($aImgFormat == 'jpeg')  {
+            $aImgFormat = 'jpg';
+        }
+        elseif (!in_array($aImgFormat, $valid_formats) )  {
+            JpGraphError::RaiseL(12003,$aImgFormat,$aFileName);
+            //('Unknown file extension ($aImgFormat) in MGraph::SetBackgroundImage() for filename: '.$aFileName);
+        }
+
+        $this->background_image = $aFileName;
+        $this->background_image_center=$aCenter;
+        $this->background_image_format=$aImgFormat;
+        $this->background_image_x = $aX;
+        $this->background_image_y = $aY;
+    }
+
+    function _strokeBackgroundImage() {
+        if( $this->background_image == '' ) return;
+
+        $bkgimg = Graph::LoadBkgImage('',$this->background_image);
+
+        // Background width & Heoght
+        $bw = imagesx($bkgimg);
+        $bh = imagesy($bkgimg);
+
+        // Canvas width and height
+        $cw = imagesx($this->img);
+        $ch = imagesy($this->img);
+
+        if( $this->doshadow ) {
+            $cw -= $this->shadow_width;
+            $ch -= $this->shadow_width;
+        }
+
+        if( $this->background_image_x === NULL || $this->background_image_y === NULL ) {
+            if( $this->background_image_center ) {
+                // Center original image in the plot area
+                $x = round($cw/2-$bw/2); $y = round($ch/2-$bh/2);
+            }
+            else {
+                // Just copy the image from left corner, no resizing
+                $x=0; $y=0;
+            }
+        }
+        else {
+            $x = $this->background_image_x;
+            $y = $this->background_image_y;
+        }
+        imagecopymerge($this->img,$bkgimg,$x,$y,0,0,$bw,$bh,$this->background_image_mix);
+    }
+
+    function AddMix($aGraph,$x=0,$y=0,$mix=100,$fx=0,$fy=0,$w=0,$h=0) {
+        $this->_gdImgHandle($aGraph->Stroke( _IMG_HANDLER),$x,$y,$fx=0,$fy=0,$w,$h,$mix);
+    }
+
+    function Add($aGraph,$x=0,$y=0,$fx=0,$fy=0,$w=0,$h=0) {
+        $this->_gdImgHandle($aGraph->Stroke( _IMG_HANDLER),$x,$y,$fx=0,$fy=0,$w,$h);
+    }
+
+    function _gdImgHandle($agdCanvas,$x,$y,$fx=0,$fy=0,$w=0,$h=0,$mix=100) {
+        if( $w == 0 ) {
+            $w = @imagesx($agdCanvas);
+        }
+        if( $w === NULL ) {
+            JpGraphError::RaiseL(12007);
+            //('Argument to MGraph::Add() is not a valid GD image handle.');
+            return;
+        }
+        if( $h == 0 ) {
+            $h = @imagesy($agdCanvas);
+        }
+        $this->iGraphs[$this->iCnt++] = array($agdCanvas,$x,$y,$fx,$fy,$w,$h,$mix);
+    }
+
+    function SetMargin($lm,$rm,$tm,$bm) {
+        $this->lm = $lm;
+        $this->rm = $rm;
+        $this->tm = $tm;
+        $this->bm = $bm;
+    }
+
+    function SetExpired($aFlg=true) {
+        $this->expired = $aFlg;
+    }
+
+    function SetImgFormat($aFormat,$aQuality=75) {
+        $this->image_format = $aFormat;
+        $this->image_quality = $aQuality;
+    }
+
+    // Set the shadow around the whole image
+    function SetShadow($aShowShadow=true,$aShadowWidth=4,$aShadowColor='gray@0.3') {
+        $this->doshadow = $aShowShadow;
+        $this->shadow_color = $aShadowColor;
+        $this->shadow_width = $aShadowWidth;
+        $this->footer->iBottomMargin += $aShadowWidth;
+        $this->footer->iRightMargin += $aShadowWidth;
+    }
+
+    function StrokeTitle($image,$w,$h) {
+        // Stroke title
+        if( $this->title->t !== '' ) {
+
+            $margin = 3;
+
+            $y = $this->title->margin;
+            if( $this->title->halign == 'center' ) {
+                $this->title->Center(0,$w,$y);
+            }
+            elseif( $this->title->halign == 'left' ) {
+                $this->title->SetPos($this->title->margin+2,$y);
+            }
+            elseif( $this->title->halign == 'right' ) {
+                $indent = 0;
+                if( $this->doshadow ) {
+                    $indent = $this->shadow_width+2;
+                }
+                $this->title->SetPos($w-$this->title->margin-$indent,$y,'right');
+            }
+            $this->title->Stroke($image);
+
+            // ... and subtitle
+            $y += $this->title->GetTextHeight($image) + $margin + $this->subtitle->margin;
+            if( $this->subtitle->halign == 'center' ) {
+                $this->subtitle->Center(0,$w,$y);
+            }
+            elseif( $this->subtitle->halign == 'left' ) {
+                $this->subtitle->SetPos($this->subtitle->margin+2,$y);
+            }
+            elseif( $this->subtitle->halign == 'right' ) {
+                $indent = 0;
+                if( $this->doshadow ) {
+                    $indent = $this->shadow_width+2;
+                }
+                $this->subtitle->SetPos($this->img->width-$this->subtitle->margin-$indent,$y,'right');
+            }
+            $this->subtitle->Stroke($image);
+
+            // ... and subsubtitle
+            $y += $this->subtitle->GetTextHeight($image) + $margin + $this->subsubtitle->margin;
+            if( $this->subsubtitle->halign == 'center' ) {
+                $this->subsubtitle->Center(0,$w,$y);
+            }
+            elseif( $this->subsubtitle->halign == 'left' ) {
+                $this->subsubtitle->SetPos($this->subsubtitle->margin+2,$y);
+            }
+            elseif( $this->subsubtitle->halign == 'right' ) {
+                $indent = 0;
+                if( $this->doshadow ) {
+                    $indent = $this->shadow_width+2;
+                }
+                $this->subsubtitle->SetPos($w-$this->subsubtitle->margin-$indent,$y,'right');
+            }
+            $this->subsubtitle->Stroke($image);
+
+        }
+    }
+
+    function Stroke($aFileName='') {
+        // Find out the necessary size for the container image
+        $w=0; $h=0;
+        for($i=0; $i < $this->iCnt; ++$i ) {
+            $maxw = $this->iGraphs[$i][1]+$this->iGraphs[$i][5];
+            $maxh = $this->iGraphs[$i][2]+$this->iGraphs[$i][6];
+            $w = max( $w, $maxw );
+            $h = max( $h, $maxh );
+        }
+        $w += $this->lm+$this->rm;
+        $h += $this->tm+$this->bm;
+
+        // User specified width,height overrides
+        if( $this->iWidth !== NULL && $this->iWidth !== 0 ) $w = $this->iWidth;
+        if( $this->iHeight!== NULL && $this->iHeight !== 0) $h = $this->iHeight;
+
+        if( $this->doshadow ) {
+            $w += $this->shadow_width;
+            $h += $this->shadow_width;
+        }
+
+        $image = new Image($w,$h);
+        $image->SetImgFormat( $this->image_format,$this->image_quality);
+
+        if( $this->doshadow ) {
+            $image->SetColor($this->iFrameColor);
+            $image->ShadowRectangle(0,0,$w-1,$h-1,$this->iFillColor,$this->shadow_width,$this->shadow_color);
+            $w -= $this->shadow_width;
+            $h -= $this->shadow_width;
+        }
+        else {
+            $image->SetColor($this->iFillColor);
+            $image->FilledRectangle(0,0,$w-1,$h-1);
+        }
+        $image->SetExpired($this->expired);
+
+        $this->img = $image->img;
+        $this->_strokeBackgroundImage();
+
+        if( $this->iDoFrame && ! $this->doshadow ) {
+           $image->SetColor($this->iFrameColor);
+           $image->SetLineWeight($this->iFrameWeight);
+           $image->Rectangle(0,0,$w-1,$h-1);
+        }
+
+        // Copy all sub graphs to the container
+        for($i=0; $i < $this->iCnt; ++$i ) {
+            $image->CopyMerge($this->iGraphs[$i][0],
+                            $this->iGraphs[$i][1]+$this->lm,$this->iGraphs[$i][2]+$this->tm,
+                            $this->iGraphs[$i][3],$this->iGraphs[$i][4],
+                            $this->iGraphs[$i][5],$this->iGraphs[$i][6],
+                            -1,-1, /* Full from width and height */
+                            $this->iGraphs[$i][7]);
+
+
+        }
+
+        $this->StrokeTitle($image,$w,$h);
+        $this->footer->Stroke($image);
+
+        // Output image
+        if( $aFileName == _IMG_HANDLER ) {
+            return $image->img;
+        }
+        else {
+            //Finally stream the generated picture
+            $this->cache = new ImgStreamCache();
+            $this->cache->PutAndStream($image,$this->cache_name,$this->inline,$aFileName);
+        }
+    }
+}
+
+// EOF
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_pie.php b/web/classes/jpgraph/jpgraph_pie.php
new file mode 100755
index 0000000000000000000000000000000000000000..c79d30facd08909af6ee91f646fadb1e88b16b51
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_pie.php
@@ -0,0 +1,1495 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_PIE.PHP
+ // Description: Pie plot extension for JpGraph
+ // Created:     2001-02-14
+ // Ver:         $Id: jpgraph_pie.php 1926 2010-01-11 16:33:07Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+
+// Defines for PiePlot::SetLabelType()
+define("PIE_VALUE_ABS",1);
+define("PIE_VALUE_PER",0);
+define("PIE_VALUE_PERCENTAGE",0);
+define("PIE_VALUE_ADJPERCENTAGE",2);
+define("PIE_VALUE_ADJPER",2);
+
+//===================================================
+// CLASS PiePlot
+// Description: Draws a pie plot
+//===================================================
+class PiePlot {
+    public $posx=0.5,$posy=0.5;
+    public $is_using_plot_theme = false;
+    public $theme="earth";
+    protected $use_plot_theme_colors = false;
+    protected $radius=0.3;
+    protected $explode_radius=array(),$explode_all=false,$explode_r=20;
+    protected $labels=null, $legends=null;
+    protected $csimtargets=null,$csimwintargets=null;  // Array of targets for CSIM
+    protected $csimareas='';  // Generated CSIM text
+    protected $csimalts=null;  // ALT tags for corresponding target
+    protected $data=null;
+    public $title;
+    protected $startangle=0;
+    protected $weight=1, $color="black";
+    protected $legend_margin=6,$show_labels=true;
+    protected $themearr = array(
+ "earth"  => array(136,34,40,45,46,62,63,134,74,10,120,136,141,168,180,77,209,218,346,395,89,430),
+ "pastel" => array(27,415,128,59,66,79,105,110,42,147,152,230,236,240,331,337,405,38),
+ "water"  => array(8,370,24,40,335,56,213,237,268,14,326,387,10,388),
+ "sand"   => array(27,168,34,170,19,50,65,72,131,209,46,393));
+    protected $setslicecolors=array();
+    protected $labeltype=0; // Default to percentage
+    protected $pie_border=true,$pie_interior_border=true;
+    public $value;
+    protected $ishadowcolor='',$ishadowdrop=4;
+    protected $ilabelposadj=1;
+    protected $legendcsimtargets = array(),$legendcsimwintargets = array();
+    protected $legendcsimalts = array();
+    protected $adjusted_data = array();
+    public $guideline = null;
+    protected $guidelinemargin=10,$iShowGuideLineForSingle = false;
+    protected $iGuideLineCurve = false,$iGuideVFactor=1.4,$iGuideLineRFactor=0.8;
+    protected $la = array(); // Holds the exact angle for each label
+
+    //---------------
+    // CONSTRUCTOR
+    function __construct($data) {
+        $this->data = array_reverse($data);
+        $this->title = new Text("");
+        $this->title->SetFont(FF_DEFAULT,FS_BOLD);
+        $this->value = new DisplayValue();
+        $this->value->Show();
+        $this->value->SetFormat('%.1f%%');
+        $this->guideline = new LineProperty();
+    }
+
+    //---------------
+    // PUBLIC METHODS
+    function SetCenter($x,$y=0.5) {
+        $this->posx = $x;
+        $this->posy = $y;
+    }
+
+    // Enable guideline and set drwaing policy
+    function SetGuideLines($aFlg=true,$aCurved=true,$aAlways=false) {
+        $this->guideline->Show($aFlg);
+        $this->iShowGuideLineForSingle = $aAlways;
+        $this->iGuideLineCurve = $aCurved;
+    }
+
+    // Adjuste the distance between labels and labels and pie
+    function SetGuideLinesAdjust($aVFactor,$aRFactor=0.8) {
+        $this->iGuideVFactor=$aVFactor;
+        $this->iGuideLineRFactor=$aRFactor;
+    }
+
+    function SetColor($aColor) {
+        $this->color = $aColor;
+    }
+
+    function SetSliceColors($aColors) {
+        $this->setslicecolors = $aColors;
+    }
+
+    function SetShadow($aColor='darkgray',$aDropWidth=4) {
+        $this->ishadowcolor = $aColor;
+        $this->ishadowdrop = $aDropWidth;
+    }
+
+    function SetCSIMTargets($aTargets,$aAlts='',$aWinTargets='') {
+        $this->csimtargets=array_reverse($aTargets);
+        if( is_array($aWinTargets) )
+        $this->csimwintargets=array_reverse($aWinTargets);
+        if( is_array($aAlts) )
+        $this->csimalts=array_reverse($aAlts);
+    }
+
+    function GetCSIMareas() {
+        return $this->csimareas;
+    }
+
+    function AddSliceToCSIM($i,$xc,$yc,$radius,$sa,$ea) {
+        //Slice number, ellipse centre (x,y), height, width, start angle, end angle
+        while( $sa > 2*M_PI ) $sa = $sa - 2*M_PI;
+        while( $ea > 2*M_PI ) $ea = $ea - 2*M_PI;
+
+        $sa = 2*M_PI - $sa;
+        $ea = 2*M_PI - $ea;
+
+        // Special case when we have only one slice since then both start and end
+        // angle will be == 0
+        if( abs($sa - $ea) < 0.0001 ) {
+            $sa=2*M_PI; $ea=0;
+        }
+
+        //add coordinates of the centre to the map
+        $xc = floor($xc);$yc=floor($yc);
+        $coords = "$xc, $yc";
+
+        //add coordinates of the first point on the arc to the map
+        $xp = floor(($radius*cos($ea))+$xc);
+        $yp = floor($yc-$radius*sin($ea));
+        $coords.= ", $xp, $yp";
+
+        //add coordinates every 0.2 radians
+        $a=$ea+0.2;
+
+        // If we cross the 360-limit with a slice we need to handle
+        // the fact that end angle is smaller than start
+        if( $sa < $ea ) {
+            while ($a <= 2*M_PI) {
+                $xp = floor($radius*cos($a)+$xc);
+                $yp = floor($yc-$radius*sin($a));
+                $coords.= ", $xp, $yp";
+                $a += 0.2;
+            }
+            $a -= 2*M_PI;
+        }
+
+
+        while ($a < $sa) {
+            $xp = floor($radius*cos($a)+$xc);
+            $yp = floor($yc-$radius*sin($a));
+            $coords.= ", $xp, $yp";
+            $a += 0.2;
+        }
+
+        //Add the last point on the arc
+        $xp = floor($radius*cos($sa)+$xc);
+        $yp = floor($yc-$radius*sin($sa));
+        $coords.= ", $xp, $yp";
+        if( !empty($this->csimtargets[$i]) ) {
+            $this->csimareas .= "<area shape=\"poly\" coords=\"$coords\" href=\"".$this->csimtargets[$i]."\"";
+            $tmp="";
+            if( !empty($this->csimwintargets[$i]) ) {
+                $this->csimareas .= " target=\"".$this->csimwintargets[$i]."\" ";
+            }
+            if( !empty($this->csimalts[$i]) ) {
+                $tmp=sprintf($this->csimalts[$i],$this->data[$i]);
+                $this->csimareas .= " title=\"$tmp\" alt=\"$tmp\" ";
+            }
+            $this->csimareas .= " />\n";
+        }
+    }
+
+
+    function SetTheme($aTheme) {
+//        JpGraphError::RaiseL(15012,$aTheme);
+//        return;
+
+        if( in_array($aTheme,array_keys($this->themearr)) ) {
+            $this->theme = $aTheme;
+            $this->is_using_plot_theme = true;
+        } else {
+            JpGraphError::RaiseL(15001,$aTheme);//("PiePLot::SetTheme() Unknown theme: $aTheme");
+        }
+    }
+
+    function ExplodeSlice($e,$radius=20) {
+        if( ! is_integer($e) )
+        JpGraphError::RaiseL(15002);//('Argument to PiePlot::ExplodeSlice() must be an integer');
+        $this->explode_radius[$e]=$radius;
+    }
+
+    function ExplodeAll($radius=20) {
+        $this->explode_all=true;
+        $this->explode_r = $radius;
+    }
+
+    function Explode($aExplodeArr) {
+        if( !is_array($aExplodeArr) ) {
+            JpGraphError::RaiseL(15003);
+            //("Argument to PiePlot::Explode() must be an array with integer distances.");
+        }
+        $this->explode_radius = $aExplodeArr;
+    }
+
+    function SetStartAngle($aStart) {
+        if( $aStart < 0 || $aStart > 360 ) {
+            JpGraphError::RaiseL(15004);//('Slice start angle must be between 0 and 360 degrees.');
+        }
+        if( $aStart == 0 ) {
+            $this->startangle = 0;
+        }
+        else {
+            $this->startangle = 360-$aStart;
+            $this->startangle *= M_PI/180;
+        }
+    }
+
+    // Size in percentage
+    function SetSize($aSize) {
+        if( ($aSize>0 && $aSize<=0.5) || ($aSize>10 && $aSize<1000) )
+        $this->radius = $aSize;
+        else
+        JpGraphError::RaiseL(15006);
+        //("PiePlot::SetSize() Radius for pie must either be specified as a fraction [0, 0.5] of the size of the image or as an absolute size in pixels  in the range [10, 1000]");
+    }
+
+    // Set label arrays
+    function SetLegends($aLegend) {
+        $this->legends = $aLegend;
+    }
+
+    // Set text labels for slices
+    function SetLabels($aLabels,$aLblPosAdj="auto") {
+        $this->labels = array_reverse($aLabels);
+        $this->ilabelposadj=$aLblPosAdj;
+    }
+
+    function SetLabelPos($aLblPosAdj) {
+        $this->ilabelposadj=$aLblPosAdj;
+    }
+
+    // Should we display actual value or percentage?
+    function SetLabelType($aType) {
+        if( $aType < 0 || $aType > 2 )
+        	JpGraphError::RaiseL(15008,$aType);
+	        //("PiePlot::SetLabelType() Type for pie plots must be 0 or 1 (not $t).");
+        $this->labeltype = $aType;
+    }
+
+    // Deprecated.
+    function SetValueType($aType) {
+        $this->SetLabelType($aType);
+    }
+
+    // Should the circle around a pie plot be displayed
+    function ShowBorder($exterior=true,$interior=true) {
+        $this->pie_border = $exterior;
+        $this->pie_interior_border = $interior;
+    }
+
+    // Setup the legends
+    function Legend($graph) {
+        $colors = array_keys($graph->img->rgb->rgb_table);
+        sort($colors);
+        $ta=$this->themearr[$this->theme];
+        $n = count($this->data);
+
+        if( $this->setslicecolors==null ) {
+            $numcolors=count($ta);
+            if( class_exists('PiePlot3D',false) && ($this instanceof PiePlot3D) ) {
+                $ta = array_reverse(array_slice($ta,0,$n));
+            }
+        }
+        else {
+            $this->setslicecolors = array_slice($this->setslicecolors,0,$n);
+            $numcolors=count($this->setslicecolors);
+            if( $graph->pieaa && !($this instanceof PiePlot3D) ) {
+                $this->setslicecolors = array_reverse($this->setslicecolors);
+            }
+        }
+
+        $sum=0;
+        for($i=0; $i < $n; ++$i)
+            $sum += $this->data[$i];
+
+        // Bail out with error if the sum is 0
+        if( $sum==0 )
+        JpGraphError::RaiseL(15009);//("Illegal pie plot. Sum of all data is zero for Pie!");
+
+        // Make sure we don't plot more values than data points
+        // (in case the user added more legends than data points)
+        $n = min(count($this->legends),count($this->data));
+        if( $this->legends != "" ) {
+            $this->legends = array_reverse(array_slice($this->legends,0,$n));
+        }
+        for( $i=$n-1; $i >= 0; --$i ) {
+            $l = $this->legends[$i];
+            // Replace possible format with actual values
+            if( count($this->csimalts) > $i ) {
+                $fmt = $this->csimalts[$i];
+            }
+            else {
+                $fmt = "%d"; // Deafult Alt if no other has been specified
+            }
+            if( $this->labeltype==0 ) {
+                $l = sprintf($l,100*$this->data[$i]/$sum);
+                $alt = sprintf($fmt,$this->data[$i]);
+
+            }
+            elseif( $this->labeltype == 1)  {
+                $l = sprintf($l,$this->data[$i]);
+                $alt = sprintf($fmt,$this->data[$i]);
+
+            }
+            else {
+                $l = sprintf($l,$this->adjusted_data[$i]);
+                $alt = sprintf($fmt,$this->adjusted_data[$i]);
+            }
+
+            if( empty($this->csimwintargets[$i]) ) {
+                $wintarg = '';
+            }
+            else {
+                $wintarg = $this->csimwintargets[$i];
+            }
+
+            if( $this->setslicecolors==null ) {
+                $graph->legend->Add($l,$colors[$ta[$i%$numcolors]],"",0,$this->csimtargets[$i],$alt,$wintarg);
+            }
+            else {
+                $graph->legend->Add($l,$this->setslicecolors[$i%$numcolors],"",0,$this->csimtargets[$i],$alt,$wintarg);
+            }
+        }
+    }
+
+    // Adjust the rounded percetage value so that the sum of
+    // of the pie slices are always 100%
+    // Using the Hare/Niemeyer method
+    function AdjPercentage($aData,$aPrec=0) {
+        $mul=100;
+        if( $aPrec > 0 && $aPrec < 3 ) {
+            if( $aPrec == 1 )
+            $mul=1000;
+            else
+            $mul=10000;
+        }
+
+        $tmp = array();
+        $result = array();
+        $quote_sum=0;
+        $n = count($aData) ;
+        for( $i=0, $sum=0; $i < $n; ++$i )
+        $sum+=$aData[$i];
+        foreach($aData as $index => $value) {
+            $tmp_percentage=$value/$sum*$mul;
+            $result[$index]=floor($tmp_percentage);
+            $tmp[$index]=$tmp_percentage-$result[$index];
+            $quote_sum+=$result[$index];
+        }
+        if( $quote_sum == $mul) {
+            if( $mul > 100 ) {
+                $tmp = $mul / 100;
+                for( $i=0; $i < $n; ++$i ) {
+                    $result[$i] /= $tmp ;
+                }
+            }
+            return $result;
+        }
+        arsort($tmp,SORT_NUMERIC);
+        reset($tmp);
+        for($i=0; $i < $mul-$quote_sum; $i++)
+        {
+            $result[key($tmp)]++;
+            next($tmp);
+        }
+        if( $mul > 100 ) {
+            $tmp = $mul / 100;
+            for( $i=0; $i < $n; ++$i ) {
+                $result[$i] /= $tmp ;
+            }
+        }
+        return $result;
+    }
+
+
+    function Stroke($img,$aaoption=0) {
+        // aaoption is used to handle antialias
+        // aaoption == 0 a normal pie
+        // aaoption == 1 just the body
+        // aaoption == 2 just the values
+
+        // Explode scaling. If anti alias we scale the image
+        // twice and we also need to scale the exploding distance
+        $expscale = $aaoption === 1 ? 2 : 1;
+
+        if( $this->labeltype == 2 ) {
+            // Adjust the data so that it will add up to 100%
+            $this->adjusted_data = $this->AdjPercentage($this->data);
+        }
+
+        if ($this->use_plot_theme_colors) {
+            $this->setslicecolors = null;
+        }
+
+        $colors = array_keys($img->rgb->rgb_table);
+        sort($colors);
+        $ta=$this->themearr[$this->theme];
+        $n = count($this->data);
+
+        if( $this->setslicecolors==null ) {
+            $numcolors=count($ta);
+        }
+        else {
+            // We need to create an array of colors as long as the data
+            // since we need to reverse it to get the colors in the right order
+            $numcolors=count($this->setslicecolors);
+            $i = 2*$numcolors;
+            while( $n > $i ) {
+                $this->setslicecolors = array_merge($this->setslicecolors,$this->setslicecolors);
+                $i += $n;
+            }
+            $tt = array_slice($this->setslicecolors,0,$n % $numcolors);
+            $this->setslicecolors = array_merge($this->setslicecolors,$tt);
+            $this->setslicecolors = array_reverse($this->setslicecolors);
+        }
+
+        // Draw the slices
+        $sum=0;
+        for($i=0; $i < $n; ++$i)
+            $sum += $this->data[$i];
+
+        // Bail out with error if the sum is 0
+        if( $sum==0 ) {
+            JpGraphError::RaiseL(15009);//("Sum of all data is 0 for Pie.");
+        }
+
+        // Set up the pie-circle
+        if( $this->radius <= 1 ) {
+            $radius = floor($this->radius*min($img->width,$img->height));
+        }
+        else {
+            $radius = $aaoption === 1 ? $this->radius*2 : $this->radius;
+        }
+
+        if( $this->posx <= 1 && $this->posx > 0 ) {
+            $xc = round($this->posx*$img->width);
+        }
+        else {
+            $xc = $this->posx ;
+        }
+
+        if( $this->posy <= 1 && $this->posy > 0 ) {
+            $yc = round($this->posy*$img->height);
+        }
+        else {
+            $yc = $this->posy ;
+        }
+
+        $n = count($this->data);
+
+        if( $this->explode_all ) {
+            for($i=0; $i < $n; ++$i) {
+                $this->explode_radius[$i]=$this->explode_r;
+            }
+        }
+
+        // If we have a shadow and not just drawing the labels
+        if( $this->ishadowcolor != "" && $aaoption !== 2) {
+            $accsum=0;
+            $angle2 = $this->startangle;
+            $img->SetColor($this->ishadowcolor);
+            for($i=0; $sum > 0 && $i < $n; ++$i) {
+                $j = $n-$i-1;
+                $d = $this->data[$i];
+                $angle1 = $angle2;
+                $accsum += $d;
+                $angle2 = $this->startangle+2*M_PI*$accsum/$sum;
+                if( empty($this->explode_radius[$j]) ) {
+                    $this->explode_radius[$j]=0;
+                }
+
+                if( $d < 0.00001 ) continue;
+
+                $la = 2*M_PI - (abs($angle2-$angle1)/2.0+$angle1);
+
+                $xcm = $xc + $this->explode_radius[$j]*cos($la)*$expscale;
+                $ycm = $yc - $this->explode_radius[$j]*sin($la)*$expscale;
+
+                $xcm += $this->ishadowdrop*$expscale;
+                $ycm += $this->ishadowdrop*$expscale;
+
+                $_sa = round($angle1*180/M_PI);
+                $_ea = round($angle2*180/M_PI);
+
+                // The CakeSlice method draws a full circle in case of start angle = end angle
+                // for pie slices we don't want this behaviour unless we only have one
+                // slice in the pie in case it is the wanted behaviour
+                if( $_ea-$_sa > 0.1 || $n==1 ) {
+                    $img->CakeSlice($xcm,$ycm,$radius-1,$radius-1,
+                    $angle1*180/M_PI,$angle2*180/M_PI,$this->ishadowcolor);
+                }
+            }
+        }
+
+        //--------------------------------------------------------------------------------
+        // This is the main loop to draw each cake slice
+        //--------------------------------------------------------------------------------
+
+        // Set up the accumulated sum, start angle for first slice and border color
+        $accsum=0;
+        $angle2 = $this->startangle;
+        $img->SetColor($this->color);
+
+        // Loop though all the slices if there is a pie to draw (sum>0)
+        // There are n slices in total
+        for($i=0; $sum>0 && $i < $n; ++$i) {
+
+            // $j is the actual index used for the slice
+            $j = $n-$i-1;
+
+            // Make sure we havea  valid distance to explode the slice
+            if( empty($this->explode_radius[$j]) ) {
+                $this->explode_radius[$j]=0;
+            }
+
+            // The actual numeric value for the slice
+            $d = $this->data[$i];
+
+            $angle1 = $angle2;
+
+            // Accumlate the sum
+            $accsum += $d;
+
+            // The new angle when we add the "size" of this slice
+            // angle1 is then the start and angle2 the end of this slice
+            $angle2 = $this->NormAngle($this->startangle+2*M_PI*$accsum/$sum);
+
+            // We avoid some trouble by not allowing end angle to be 0, in that case
+            // we translate to 360
+
+            // la is used to hold the label angle, which is centered on the slice
+            if( $angle2 < 0.0001 && $angle1 > 0.0001 ) {
+                $this->la[$i] = 2*M_PI - (abs(2*M_PI-$angle1)/2.0+$angle1);
+            }
+            elseif( $angle1 > $angle2 ) {
+                // The case where the slice crosses the 3 a'clock line
+                // Remember that the slices are counted clockwise and
+                // labels are counted counter clockwise so we need to revert with 2 PI
+                $this->la[$i] = 2*M_PI-$this->NormAngle($angle1 + ((2*M_PI - $angle1)+$angle2)/2);
+            }
+            else {
+                $this->la[$i] = 2*M_PI - (abs($angle2-$angle1)/2.0+$angle1);
+            }
+
+            // Too avoid rounding problems we skip the slice if it is too small
+            if( $d < 0.00001 ) continue;
+
+            // If the user has specified an array of colors for each slice then use
+            // that a color otherwise use the theme array (ta) of colors
+            if( $this->setslicecolors==null ) {
+                $slicecolor=$colors[$ta[$i%$numcolors]];
+            }
+            else {
+                $slicecolor=$this->setslicecolors[$i%$numcolors];
+            }
+
+//            $_sa = round($angle1*180/M_PI);
+//            $_ea = round($angle2*180/M_PI);
+//            $_la = round($this->la[$i]*180/M_PI);
+//            echo "Slice#$i: ang1=$_sa , ang2=$_ea, la=$_la, color=$slicecolor<br>";
+
+
+            // If we have enabled antialias then we don't draw any border so
+            // make the bordedr color the same as the slice color
+            if( $this->pie_interior_border && $aaoption===0 ) {
+                $img->SetColor($this->color);
+            }
+            else {
+                $img->SetColor($slicecolor);
+            }
+            $arccolor = $this->pie_border && $aaoption===0 ? $this->color : "";
+
+            // Calculate the x,y coordinates for the base of this slice taking
+            // the exploded distance into account. Here we use the mid angle as the
+            // ray of extension and we have the mid angle handy as it is also the
+            // label angle
+            $xcm = $xc + $this->explode_radius[$j]*cos($this->la[$i])*$expscale;
+            $ycm = $yc - $this->explode_radius[$j]*sin($this->la[$i])*$expscale;
+
+            // If we are not just drawing the labels then draw this cake slice
+            if( $aaoption !== 2 ) {
+
+                $_sa = round($angle1*180/M_PI);
+                $_ea = round($angle2*180/M_PI);
+                $_la = round($this->la[$i]*180/M_PI);
+                //echo "[$i] sa=$_sa, ea=$_ea, la[$i]=$_la, (color=$slicecolor)<br>";
+
+                // The CakeSlice method draws a full circle in case of start angle = end angle
+                // for pie slices we want this in case the slice have a value larger than 99% of the
+                // total sum
+                if( abs($_ea-$_sa) >= 1 || $d == $sum ) {
+                    $img->CakeSlice($xcm,$ycm,$radius-1,$radius-1,$_sa,$_ea,$slicecolor,$arccolor);
+                }
+            }
+
+            // If the CSIM is used then make sure we register a CSIM area for this slice as well
+            if( $this->csimtargets && $aaoption !== 1 ) {
+                $this->AddSliceToCSIM($i,$xcm,$ycm,$radius,$angle1,$angle2);
+            }
+        }
+
+        // Format the titles for each slice
+        if( $aaoption !== 2 ) {
+            for( $i=0; $i < $n; ++$i) {
+                if( $this->labeltype==0 ) {
+                    if( $sum != 0 )
+                    $l = 100.0*$this->data[$i]/$sum;
+                    else
+                    $l = 0.0;
+                }
+                elseif( $this->labeltype==1 ) {
+                    $l = $this->data[$i]*1.0;
+                }
+                else {
+                    $l = $this->adjusted_data[$i];
+                }
+                if( isset($this->labels[$i]) && is_string($this->labels[$i]) )
+                $this->labels[$i]=sprintf($this->labels[$i],$l);
+                else
+                $this->labels[$i]=$l;
+            }
+        }
+
+        if( $this->value->show && $aaoption !== 1 ) {
+            $this->StrokeAllLabels($img,$xc,$yc,$radius);
+        }
+
+        // Adjust title position
+        if( $aaoption !== 1 ) {
+            $this->title->SetPos($xc,
+            $yc-$this->title->GetFontHeight($img)-$radius-$this->title->margin,
+     "center","bottom");
+            $this->title->Stroke($img);
+        }
+
+    }
+
+    //---------------
+    // PRIVATE METHODS
+
+    function NormAngle($a) {
+        while( $a < 0 ) $a += 2*M_PI;
+        while( $a > 2*M_PI ) $a -= 2*M_PI;
+        return $a;
+    }
+
+    function Quadrant($a) {
+        $a=$this->NormAngle($a);
+        if( $a > 0 && $a <= M_PI/2 )
+        return 0;
+        if( $a > M_PI/2 && $a <= M_PI )
+        return 1;
+        if( $a > M_PI && $a <= 1.5*M_PI )
+        return 2;
+        if( $a > 1.5*M_PI )
+        return 3;
+    }
+
+    function StrokeGuideLabels($img,$xc,$yc,$radius) {
+        $n = count($this->labels);
+
+        //-----------------------------------------------------------------------
+        // Step 1 of the algorithm is to construct a number of clusters
+        // a cluster is defined as all slices within the same quadrant (almost)
+        // that has an angular distance less than the treshold
+        //-----------------------------------------------------------------------
+        $tresh_hold=25 * M_PI/180; // 25 degrees difference to be in a cluster
+        $incluster=false; // flag if we are currently in a cluster or not
+        $clusters = array(); // array of clusters
+        $cidx=-1;  // running cluster index
+
+        // Go through all the labels and construct a number of clusters
+        for($i=0; $i < $n-1; ++$i) {
+            // Calc the angle distance between two consecutive slices
+            $a1=$this->la[$i];
+            $a2=$this->la[$i+1];
+            $q1 = $this->Quadrant($a1);
+            $q2 = $this->Quadrant($a2);
+            $diff = abs($a1-$a2);
+            if( $diff < $tresh_hold ) {
+                if( $incluster ) {
+                    $clusters[$cidx][1]++;
+                    // Each cluster can only cover one quadrant
+                    // Do we cross a quadrant ( and must break the cluster)
+                    if( $q1 !=  $q2 ) {
+                        // If we cross a quadrant boundary we normally start a
+                        // new cluster. However we need to take the 12'a clock
+                        // and 6'a clock positions into a special consideration.
+                        // Case 1: WE go from q=1 to q=2 if the last slice on
+                        // the cluster for q=1 is close to 12'a clock and the
+                        // first slice in q=0 is small we extend the previous
+                        // cluster
+                        if( $q1 == 1 && $q2 == 0 && $a2 > (90-15)*M_PI/180 ) {
+                            if( $i < $n-2 ) {
+                                $a3 = $this->la[$i+2];
+                                // If there isn't a cluster coming up with the next-next slice
+                                // we extend the previous cluster to cover this slice as well
+                                if( abs($a3-$a2) >= $tresh_hold ) {
+                                    $clusters[$cidx][1]++;
+                                    $i++;
+                                }
+                            }
+                        }
+                        elseif( $q1 == 3 && $q2 == 2 && $a2 > (270-15)*M_PI/180 ) {
+                            if( $i < $n-2 ) {
+                                $a3 = $this->la[$i+2];
+                                // If there isn't a cluster coming up with the next-next slice
+                                // we extend the previous cluster to cover this slice as well
+                                if( abs($a3-$a2) >= $tresh_hold ) {
+                                    $clusters[$cidx][1]++;
+                                    $i++;
+                                }
+                            }
+                        }
+
+                        if( $q1==2 && $q2==1 && $a2 > (180-15)*M_PI/180 ) {
+                            $clusters[$cidx][1]++;
+                            $i++;
+                        }
+
+                        $incluster = false;
+                    }
+                }
+                elseif( $q1 == $q2)  {
+                    $incluster = true;
+                    // Now we have a special case for quadrant 0. If we previously
+                    // have a cluster of one in quadrant 0 we just extend that
+                    // cluster. If we don't do this then we risk that the label
+                    // for the cluster of one will cross the guide-line
+                    if( $q1 == 0 && $cidx > -1 &&
+                    $clusters[$cidx][1] == 1 &&
+                    $this->Quadrant($this->la[$clusters[$cidx][0]]) == 0 ) {
+                        $clusters[$cidx][1]++;
+                    }
+                    else {
+                        $cidx++;
+                        $clusters[$cidx][0] = $i;
+                        $clusters[$cidx][1] = 1;
+                    }
+                }
+                else {
+                    // Create a "cluster" of one since we are just crossing
+                    // a quadrant
+                    $cidx++;
+                    $clusters[$cidx][0] = $i;
+                    $clusters[$cidx][1] = 1;
+                }
+            }
+            else {
+                if( $incluster ) {
+                    // Add the last slice
+                    $clusters[$cidx][1]++;
+                    $incluster = false;
+                }
+                else { // Create a "cluster" of one
+                    $cidx++;
+                    $clusters[$cidx][0] = $i;
+                    $clusters[$cidx][1] = 1;
+                }
+            }
+        }
+        // Handle the very last slice
+        if( $incluster ) {
+            $clusters[$cidx][1]++;
+        }
+        else { // Create a "cluster" of one
+            $cidx++;
+            $clusters[$cidx][0] = $i;
+            $clusters[$cidx][1] = 1;
+        }
+
+        /*
+         if( true ) {
+         // Debug printout in labels
+         for( $i=0; $i <= $cidx; ++$i ) {
+         for( $j=0; $j < $clusters[$i][1]; ++$j ) {
+         $a = $this->la[$clusters[$i][0]+$j];
+         $aa = round($a*180/M_PI);
+         $q = $this->Quadrant($a);
+         $this->labels[$clusters[$i][0]+$j]="[$q:$aa] $i:$j";
+         }
+         }
+         }
+         */
+
+        //-----------------------------------------------------------------------
+        // Step 2 of the algorithm is use the clusters and draw the labels
+        // and guidelines
+        //-----------------------------------------------------------------------
+
+        // We use the font height as the base factor for how far we need to
+        // spread the labels in the Y-direction.
+        $this->value->ApplyFont($img);
+        $fh = $img->GetFontHeight();
+        $origvstep=$fh*$this->iGuideVFactor;
+        $this->value->SetMargin(0);
+
+        // Number of clusters found
+        $nc = count($clusters);
+
+        // Walk through all the clusters
+        for($i=0; $i < $nc; ++$i) {
+
+            // Start angle and number of slices in this cluster
+            $csize = $clusters[$i][1];
+            $a = $this->la[$clusters[$i][0]];
+            $q = $this->Quadrant($a);
+
+            // Now set up the start and end conditions to make sure that
+            // in each cluster we walk through the all the slices starting with the slice
+            // closest to the equator. Since all slices are numbered clockwise from "3'a clock"
+            // we have different conditions depending on in which quadrant the slice lies within.
+            if( $q == 0 ) {
+                $start = $csize-1; $idx = $start; $step = -1; $vstep = -$origvstep;
+            }
+            elseif( $q == 1 ) {
+                $start = 0; $idx = $start; $step = 1; $vstep = -$origvstep;
+            }
+            elseif( $q == 2 ) {
+                $start = $csize-1; $idx = $start; $step = -1; $vstep = $origvstep;
+            }
+            elseif( $q == 3 ) {
+                $start = 0; $idx = $start; $step = 1; $vstep = $origvstep;
+            }
+
+            // Walk through all slices within this cluster
+            for($j=0; $j < $csize; ++$j) {
+                // Now adjust the position of the labels in each cluster starting
+                // with the slice that is closest to the equator of the pie
+                $a = $this->la[$clusters[$i][0]+$idx];
+
+                // Guide line start in the center of the arc of the slice
+                $r = $radius+$this->explode_radius[$n-1-($clusters[$i][0]+$idx)];
+                $x = round($r*cos($a)+$xc);
+                $y = round($yc-$r*sin($a));
+
+                // The distance from the arc depends on chosen font and the "R-Factor"
+                $r += $fh*$this->iGuideLineRFactor;
+
+                // Should the labels be placed curved along the pie or in straight columns
+                // outside the pie?
+                if( $this->iGuideLineCurve )
+                $xt=round($r*cos($a)+$xc);
+
+                // If this is the first slice in the cluster we need some first time
+                // proessing
+                if( $idx == $start ) {
+                    if( ! $this->iGuideLineCurve )
+                    $xt=round($r*cos($a)+$xc);
+                    $yt=round($yc-$r*sin($a));
+
+                    // Some special consideration in case this cluster starts
+                    // in quadrant 1 or 3 very close to the "equator" (< 20 degrees)
+                    // and the previous clusters last slice is within the tolerance.
+                    // In that case we add a font height to this labels Y-position
+                    // so it doesn't collide with
+                    // the slice in the previous cluster
+                    $prevcluster = ($i + ($nc-1) ) % $nc;
+                    $previdx=$clusters[$prevcluster][0]+$clusters[$prevcluster][1]-1;
+                    if( $q == 1 && $a > 160*M_PI/180 ) {
+                        // Get the angle for the previous clusters last slice
+                        $diff = abs($a-$this->la[$previdx]);
+                        if( $diff < $tresh_hold ) {
+                            $yt -= $fh;
+                        }
+                    }
+                    elseif( $q == 3 && $a > 340*M_PI/180 ) {
+                        // We need to subtract 360 to compare angle distance between
+                        // q=0 and q=3
+                        $diff = abs($a-$this->la[$previdx]-360*M_PI/180);
+                        if( $diff < $tresh_hold ) {
+                            $yt += $fh;
+                        }
+                    }
+
+                }
+                else {
+                    // The step is at minimum $vstep but if the slices are relatively large
+                    // we make sure that we add at least a step that corresponds to the vertical
+                    // distance between the centers at the arc on the slice
+                    $prev_a = $this->la[$clusters[$i][0]+($idx-$step)];
+                    $dy = abs($radius*(sin($a)-sin($prev_a))*1.2);
+                    if( $vstep > 0 )
+                    $yt += max($vstep,$dy);
+                    else
+                    $yt += min($vstep,-$dy);
+                }
+
+                $label = $this->labels[$clusters[$i][0]+$idx];
+
+                if( $csize == 1 ) {
+                    // A "meta" cluster with only one slice
+                    $r = $radius+$this->explode_radius[$n-1-($clusters[$i][0]+$idx)];
+                    $rr = $r+$img->GetFontHeight()/2;
+                    $xt=round($rr*cos($a)+$xc);
+                    $yt=round($yc-$rr*sin($a));
+                    $this->StrokeLabel($label,$img,$xc,$yc,$a,$r);
+                    if( $this->iShowGuideLineForSingle )
+                    $this->guideline->Stroke($img,$x,$y,$xt,$yt);
+                }
+                else {
+                    $this->guideline->Stroke($img,$x,$y,$xt,$yt);
+                    if( $q==1 || $q==2 ) {
+                        // Left side of Pie
+                        $this->guideline->Stroke($img,$xt,$yt,$xt-$this->guidelinemargin,$yt);
+                        $lbladj = -$this->guidelinemargin-5;
+                        $this->value->halign = "right";
+                        $this->value->valign = "center";
+                    }
+                    else {
+                        // Right side of pie
+                        $this->guideline->Stroke($img,$xt,$yt,$xt+$this->guidelinemargin,$yt);
+                        $lbladj = $this->guidelinemargin+5;
+                        $this->value->halign = "left";
+                        $this->value->valign = "center";
+                    }
+                    $this->value->Stroke($img,$label,$xt+$lbladj,$yt);
+                }
+
+                // Udate idx to point to next slice in the cluster to process
+                $idx += $step;
+            }
+        }
+    }
+
+    function StrokeAllLabels($img,$xc,$yc,$radius) {
+        // First normalize all angles for labels
+        $n = count($this->la);
+        for($i=0; $i < $n; ++$i) {
+            $this->la[$i] = $this->NormAngle($this->la[$i]);
+        }
+        if( $this->guideline->iShow ) {
+            $this->StrokeGuideLabels($img,$xc,$yc,$radius);
+        }
+        else {
+            $n = count($this->labels);
+            for($i=0; $i < $n; ++$i) {
+                $this->StrokeLabel($this->labels[$i],$img,$xc,$yc,
+                $this->la[$i],
+                $radius + $this->explode_radius[$n-1-$i]);
+            }
+        }
+    }
+
+    // Position the labels of each slice
+    function StrokeLabel($label,$img,$xc,$yc,$a,$r) {
+
+        // Default value
+        if( $this->ilabelposadj === 'auto' )
+        $this->ilabelposadj = 0.65;
+
+        // We position the values diferently depending on if they are inside
+        // or outside the pie
+        if( $this->ilabelposadj < 1.0 ) {
+
+            $this->value->SetAlign('center','center');
+            $this->value->margin = 0;
+
+            $xt=round($this->ilabelposadj*$r*cos($a)+$xc);
+            $yt=round($yc-$this->ilabelposadj*$r*sin($a));
+
+            $this->value->Stroke($img,$label,$xt,$yt);
+        }
+        else {
+
+            $this->value->halign = "left";
+            $this->value->valign = "top";
+            $this->value->margin = 0;
+
+            // Position the axis title.
+            // dx, dy is the offset from the top left corner of the bounding box that sorrounds the text
+            // that intersects with the extension of the corresponding axis. The code looks a little
+            // bit messy but this is really the only way of having a reasonable position of the
+            // axis titles.
+            $this->value->ApplyFont($img);
+            $h=$img->GetTextHeight($label);
+            // For numeric values the format of the display value
+            // must be taken into account
+            if( is_numeric($label) ) {
+                if( $label > 0 )
+                $w=$img->GetTextWidth(sprintf($this->value->format,$label));
+                else
+                $w=$img->GetTextWidth(sprintf($this->value->negformat,$label));
+            }
+            else
+            $w=$img->GetTextWidth($label);
+
+            if( $this->ilabelposadj > 1.0 && $this->ilabelposadj < 5.0) {
+                $r *= $this->ilabelposadj;
+            }
+
+            $r += $img->GetFontHeight()/1.5;
+
+            $xt=round($r*cos($a)+$xc);
+            $yt=round($yc-$r*sin($a));
+
+            // Normalize angle
+            while( $a < 0 ) $a += 2*M_PI;
+            while( $a > 2*M_PI ) $a -= 2*M_PI;
+
+            if( $a>=7*M_PI/4 || $a <= M_PI/4 ) $dx=0;
+            if( $a>=M_PI/4 && $a <= 3*M_PI/4 ) $dx=($a-M_PI/4)*2/M_PI;
+            if( $a>=3*M_PI/4 && $a <= 5*M_PI/4 ) $dx=1;
+            if( $a>=5*M_PI/4 && $a <= 7*M_PI/4 ) $dx=(1-($a-M_PI*5/4)*2/M_PI);
+
+            if( $a>=7*M_PI/4 ) $dy=(($a-M_PI)-3*M_PI/4)*2/M_PI;
+            if( $a<=M_PI/4 ) $dy=(1-$a*2/M_PI);
+            if( $a>=M_PI/4 && $a <= 3*M_PI/4 ) $dy=1;
+            if( $a>=3*M_PI/4 && $a <= 5*M_PI/4 ) $dy=(1-($a-3*M_PI/4)*2/M_PI);
+            if( $a>=5*M_PI/4 && $a <= 7*M_PI/4 ) $dy=0;
+
+            $this->value->Stroke($img,$label,$xt-$dx*$w,$yt-$dy*$h);
+        }
+    }
+
+    function UsePlotThemeColors($flag = true) {
+        $this->use_plot_theme_colors = $flag;
+    }
+} // Class
+
+
+//===================================================
+// CLASS PiePlotC
+// Description: Same as a normal pie plot but with a
+// filled circle in the center
+//===================================================
+class PiePlotC extends PiePlot {
+    private $imidsize=0.5;  // Fraction of total width
+    private $imidcolor='white';
+    public $midtitle='';
+    private $middlecsimtarget='',$middlecsimwintarget='',$middlecsimalt='';
+
+    function __construct($data,$aCenterTitle='') {
+        parent::__construct($data);
+        $this->midtitle = new Text();
+        $this->midtitle->ParagraphAlign('center');
+    }
+
+    function SetMid($aTitle,$aColor='white',$aSize=0.5) {
+        $this->midtitle->Set($aTitle);
+
+        $this->imidsize = $aSize ;
+        $this->imidcolor = $aColor ;
+    }
+
+    function SetMidTitle($aTitle) {
+        $this->midtitle->Set($aTitle);
+    }
+
+    function SetMidSize($aSize) {
+        $this->imidsize = $aSize ;
+    }
+
+    function SetMidColor($aColor) {
+        $this->imidcolor = $aColor ;
+    }
+
+    function SetMidCSIM($aTarget,$aAlt='',$aWinTarget='') {
+        $this->middlecsimtarget = $aTarget;
+        $this->middlecsimwintarget = $aWinTarget;
+        $this->middlecsimalt = $aAlt;
+    }
+
+    function AddSliceToCSIM($i,$xc,$yc,$radius,$sa,$ea) {
+        //Slice number, ellipse centre (x,y), radius, start angle, end angle
+        while( $sa > 2*M_PI ) $sa = $sa - 2*M_PI;
+        while( $ea > 2*M_PI ) $ea = $ea - 2*M_PI;
+
+        $sa = 2*M_PI - $sa;
+        $ea = 2*M_PI - $ea;
+
+        // Special case when we have only one slice since then both start and end
+        // angle will be == 0
+        if( abs($sa - $ea) < 0.0001 ) {
+            $sa=2*M_PI; $ea=0;
+        }
+
+        // Add inner circle first point
+        $xp = floor(($this->imidsize*$radius*cos($ea))+$xc);
+        $yp = floor($yc-($this->imidsize*$radius*sin($ea)));
+        $coords = "$xp, $yp";
+
+        //add coordinates every 0.25 radians
+        $a=$ea+0.25;
+
+        // If we cross the 360-limit with a slice we need to handle
+        // the fact that end angle is smaller than start
+        if( $sa < $ea ) {
+            while ($a <= 2*M_PI) {
+                $xp = floor($radius*cos($a)+$xc);
+                $yp = floor($yc-$radius*sin($a));
+                $coords.= ", $xp, $yp";
+                $a += 0.25;
+            }
+            $a -= 2*M_PI;
+        }
+
+        while ($a < $sa) {
+            $xp = floor(($this->imidsize*$radius*cos($a)+$xc));
+            $yp = floor($yc-($this->imidsize*$radius*sin($a)));
+            $coords.= ", $xp, $yp";
+            $a += 0.25;
+        }
+
+        // Make sure we end at the last point
+        $xp = floor(($this->imidsize*$radius*cos($sa)+$xc));
+        $yp = floor($yc-($this->imidsize*$radius*sin($sa)));
+        $coords.= ", $xp, $yp";
+
+        // Straight line to outer circle
+        $xp = floor($radius*cos($sa)+$xc);
+        $yp = floor($yc-$radius*sin($sa));
+        $coords.= ", $xp, $yp";
+
+        //add coordinates every 0.25 radians
+        $a=$sa - 0.25;
+        while ($a > $ea) {
+            $xp = floor($radius*cos($a)+$xc);
+            $yp = floor($yc-$radius*sin($a));
+            $coords.= ", $xp, $yp";
+            $a -= 0.25;
+        }
+
+        //Add the last point on the arc
+        $xp = floor($radius*cos($ea)+$xc);
+        $yp = floor($yc-$radius*sin($ea));
+        $coords.= ", $xp, $yp";
+
+        // Close the arc
+        $xp = floor(($this->imidsize*$radius*cos($ea))+$xc);
+        $yp = floor($yc-($this->imidsize*$radius*sin($ea)));
+        $coords .= ", $xp, $yp";
+
+        if( !empty($this->csimtargets[$i]) ) {
+            $this->csimareas .= "<area shape=\"poly\" coords=\"$coords\" href=\"".
+            $this->csimtargets[$i]."\"";
+            if( !empty($this->csimwintargets[$i]) ) {
+                $this->csimareas .= " target=\"".$this->csimwintargets[$i]."\" ";
+            }
+            if( !empty($this->csimalts[$i]) ) {
+                $tmp=sprintf($this->csimalts[$i],$this->data[$i]);
+                $this->csimareas .= " title=\"$tmp\"  alt=\"$tmp\" ";
+            }
+            $this->csimareas .= " />\n";
+        }
+    }
+
+
+    function Stroke($img,$aaoption=0) {
+
+        // Stroke the pie but don't stroke values
+        $tmp =  $this->value->show;
+        $this->value->show = false;
+        parent::Stroke($img,$aaoption);
+        $this->value->show = $tmp;
+
+        $xc = round($this->posx*$img->width);
+        $yc = round($this->posy*$img->height);
+
+        $radius = floor($this->radius * min($img->width,$img->height)) ;
+
+
+        if( $this->imidsize > 0 && $aaoption !== 2 ) {
+
+            if( $this->ishadowcolor != "" ) {
+                $img->SetColor($this->ishadowcolor);
+                $img->FilledCircle($xc+$this->ishadowdrop,$yc+$this->ishadowdrop,
+                round($radius*$this->imidsize));
+            }
+
+            $img->SetColor($this->imidcolor);
+            $img->FilledCircle($xc,$yc,round($radius*$this->imidsize));
+
+            if(  $this->pie_border && $aaoption === 0 ) {
+                $img->SetColor($this->color);
+                $img->Circle($xc,$yc,round($radius*$this->imidsize));
+            }
+
+            if( !empty($this->middlecsimtarget) )
+            $this->AddMiddleCSIM($xc,$yc,round($radius*$this->imidsize));
+
+        }
+
+        if( $this->value->show && $aaoption !== 1) {
+            $this->StrokeAllLabels($img,$xc,$yc,$radius);
+            $this->midtitle->SetPos($xc,$yc,'center','center');
+            $this->midtitle->Stroke($img);
+        }
+
+    }
+
+    function AddMiddleCSIM($xc,$yc,$r) {
+        $xc=round($xc);$yc=round($yc);$r=round($r);
+        $this->csimareas .= "<area shape=\"circle\" coords=\"$xc,$yc,$r\" href=\"".
+        $this->middlecsimtarget."\"";
+        if( !empty($this->middlecsimwintarget) ) {
+            $this->csimareas .= " target=\"".$this->middlecsimwintarget."\"";
+        }
+        if( !empty($this->middlecsimalt) ) {
+            $tmp = $this->middlecsimalt;
+            $this->csimareas .= " title=\"$tmp\" alt=\"$tmp\" ";
+        }
+        $this->csimareas .= " />\n";
+    }
+
+    function StrokeLabel($label,$img,$xc,$yc,$a,$r) {
+
+        if( $this->ilabelposadj === 'auto' )
+        $this->ilabelposadj = (1-$this->imidsize)/2+$this->imidsize;
+
+        parent::StrokeLabel($label,$img,$xc,$yc,$a,$r);
+
+    }
+
+}
+
+
+//===================================================
+// CLASS PieGraph
+// Description:
+//===================================================
+class PieGraph extends Graph {
+    private $posx, $posy, $radius;
+    private $legends=array();
+    public $plots=array();
+    public $pieaa = false ;
+    //---------------
+    // CONSTRUCTOR
+    function __construct($width=300,$height=200,$cachedName="",$timeout=0,$inline=1) {
+        parent::__construct($width,$height,$cachedName,$timeout,$inline);
+        $this->posx=$width/2;
+        $this->posy=$height/2;
+        $this->SetColor(array(255,255,255));
+
+        if ($this->graph_theme) {
+          $this->graph_theme->ApplyGraph($this);
+        }
+    }
+
+    //---------------
+    // PUBLIC METHODS
+    function Add($aObj) {
+
+        if( is_array($aObj) && count($aObj) > 0 )
+        $cl = $aObj[0];
+        else
+        $cl = $aObj;
+
+        if( $cl instanceof Text )
+        $this->AddText($aObj);
+        elseif( class_exists('IconPlot',false) && ($cl instanceof IconPlot) )
+        $this->AddIcon($aObj);
+        else {
+            if( is_array($aObj) ) {
+                $n = count($aObj);
+                for($i=0; $i < $n; ++$i ) {
+                    //if ($aObj[$i]->theme) {
+                    //    $this->ClearTheme();
+                    //}
+                    $this->plots[] = $aObj[$i];
+                }
+            }
+            else {
+                //if ($aObj->theme) {
+                //    $this->ClearTheme();
+                //}
+                $this->plots[] = $aObj;
+            }
+        }
+
+        if ($this->graph_theme) {
+            $this->graph_theme->SetupPlot($aObj);
+            if ($aObj->is_using_plot_theme) {
+                $aObj->UsePlotThemeColors();
+            }
+        }
+    }
+
+    function SetAntiAliasing($aFlg=true) {
+        $this->pieaa = $aFlg;
+    }
+
+    function SetColor($c) {
+        $this->SetMarginColor($c);
+    }
+
+
+    function DisplayCSIMAreas() {
+        $csim="";
+        foreach($this->plots as $p ) {
+            $csim .= $p->GetCSIMareas();
+        }
+        
+        $csim.= $this->legend->GetCSIMareas();
+        if (preg_match_all("/area shape=\"(\w+)\" coords=\"([0-9\, ]+)\"/", $csim, $coords)) {
+            $this->img->SetColor($this->csimcolor);
+            $n = count($coords[0]);
+            for ($i=0; $i < $n; $i++) {
+                if ($coords[1][$i]=="poly") {
+                    preg_match_all('/\s*([0-9]+)\s*,\s*([0-9]+)\s*,*/',$coords[2][$i],$pts);
+                    $this->img->SetStartPoint($pts[1][count($pts[0])-1],$pts[2][count($pts[0])-1]);
+                    $m = count($pts[0]);
+                    for ($j=0; $j < $m; $j++) {
+                        $this->img->LineTo($pts[1][$j],$pts[2][$j]);
+                    }
+                } else if ($coords[1][$i]=="rect") {
+                    $pts = preg_split('/,/', $coords[2][$i]);
+                    $this->img->SetStartPoint($pts[0],$pts[1]);
+                    $this->img->LineTo($pts[2],$pts[1]);
+                    $this->img->LineTo($pts[2],$pts[3]);
+                    $this->img->LineTo($pts[0],$pts[3]);
+                    $this->img->LineTo($pts[0],$pts[1]);
+
+                }
+            }
+        }
+    }
+
+    // Method description
+    function Stroke($aStrokeFileName="") {
+
+        // If the filename is the predefined value = '_csim_special_'
+        // we assume that the call to stroke only needs to do enough
+        // to correctly generate the CSIM maps.
+        // We use this variable to skip things we don't strictly need
+        // to do to generate the image map to improve performance
+        // a best we can. Therefor you will see a lot of tests !$_csim in the
+        // code below.
+        $_csim = ($aStrokeFileName===_CSIM_SPECIALFILE);
+
+        // If we are called the second time (perhaps the user has called GetHTMLImageMap()
+        // himself then the legends have alsready been populated once in order to get the
+        // CSIM coordinats. Since we do not want the legends to be populated a second time
+        // we clear the legends
+        $this->legend->Clear();
+
+        // We need to know if we have stroked the plot in the
+        // GetCSIMareas. Otherwise the CSIM hasn't been generated
+        // and in the case of GetCSIM called before stroke to generate
+        // CSIM without storing an image to disk GetCSIM must call Stroke.
+        $this->iHasStroked = true;
+
+        $n = count($this->plots);
+
+        if( $this->pieaa ) {
+
+            if( !$_csim ) {
+                if( $this->background_image != "" ) {
+                    $this->StrokeFrameBackground();
+                }
+                else {
+                    $this->StrokeFrame();
+                    $this->StrokeBackgroundGrad();
+                }
+            }
+
+
+            $w = $this->img->width;
+            $h = $this->img->height;
+            $oldimg = $this->img->img;
+
+            $this->img->CreateImgCanvas(2*$w,2*$h);
+
+            $this->img->SetColor( $this->margin_color );
+            $this->img->FilledRectangle(0,0,2*$w-1,2*$h-1);
+
+            // Make all icons *2 i size since we will be scaling down the
+            // imahe to do the anti aliasing
+            $ni = count($this->iIcons);
+            for($i=0; $i < $ni; ++$i) {
+                $this->iIcons[$i]->iScale *= 2 ;
+                if( $this->iIcons[$i]->iX > 1 )
+                $this->iIcons[$i]->iX *= 2 ;
+                if( $this->iIcons[$i]->iY > 1 )
+                $this->iIcons[$i]->iY *= 2 ;
+            }
+
+            $this->StrokeIcons();
+
+            for($i=0; $i < $n; ++$i) {
+                if( $this->plots[$i]->posx > 1 )
+                $this->plots[$i]->posx *= 2 ;
+                if( $this->plots[$i]->posy > 1 )
+                $this->plots[$i]->posy *= 2 ;
+
+                $this->plots[$i]->Stroke($this->img,1);
+
+                if( $this->plots[$i]->posx > 1 )
+                $this->plots[$i]->posx /= 2 ;
+                if( $this->plots[$i]->posy > 1 )
+                $this->plots[$i]->posy /= 2 ;
+            }
+
+            $indent = $this->doframe ? ($this->frame_weight + ($this->doshadow ? $this->shadow_width : 0 )) : 0 ;
+            $indent += $this->framebevel ? $this->framebeveldepth + 1 : 0 ;
+            $this->img->CopyCanvasH($oldimg,$this->img->img,$indent,$indent,$indent,$indent,
+            $w-2*$indent,$h-2*$indent,2*($w-$indent),2*($h-$indent));
+
+            $this->img->img = $oldimg ;
+            $this->img->width = $w ;
+            $this->img->height = $h ;
+
+            for($i=0; $i < $n; ++$i) {
+                $this->plots[$i]->Stroke($this->img,2); // Stroke labels
+                $this->plots[$i]->Legend($this);
+            }
+
+        }
+        else {
+
+            if( !$_csim ) {
+                if( $this->background_image != "" ) {
+                    $this->StrokeFrameBackground();
+                }
+                else {
+                    $this->StrokeFrame();
+                    $this->StrokeBackgroundGrad();
+                }
+            }
+
+            $this->StrokeIcons();
+
+            for($i=0; $i < $n; ++$i) {
+                $this->plots[$i]->Stroke($this->img);
+                $this->plots[$i]->Legend($this);
+            }
+        }
+
+        $this->legend->Stroke($this->img);
+        $this->footer->Stroke($this->img);
+        $this->StrokeTitles();
+
+        if( !$_csim ) {
+
+            // Stroke texts
+            if( $this->texts != null ) {
+                $n = count($this->texts);
+                for($i=0; $i < $n; ++$i ) {
+                    $this->texts[$i]->Stroke($this->img);
+                }
+            }
+
+            if( _JPG_DEBUG ) {
+                $this->DisplayCSIMAreas();
+            }
+
+            // Should we do any final image transformation
+            if( $this->iImgTrans ) {
+                if( !class_exists('ImgTrans',false) ) {
+                    require_once('jpgraph_imgtrans.php');
+                    //JpGraphError::Raise('In order to use image transformation you must include the file jpgraph_imgtrans.php in your script.');
+                }
+
+                $tform = new ImgTrans($this->img->img);
+                $this->img->img = $tform->Skew3D($this->iImgTransHorizon,$this->iImgTransSkewDist,
+                $this->iImgTransDirection,$this->iImgTransHighQ,
+                $this->iImgTransMinSize,$this->iImgTransFillColor,
+                $this->iImgTransBorder);
+            }
+
+
+            // If the filename is given as the special "__handle"
+            // then the image handler is returned and the image is NOT
+            // streamed back
+            if( $aStrokeFileName == _IMG_HANDLER ) {
+                return $this->img->img;
+            }
+            else {
+                // Finally stream the generated picture
+                $this->cache->PutAndStream($this->img,$this->cache_name,$this->inline,
+                $aStrokeFileName);
+            }
+        }
+    }
+} // Class
+
+/* EOF */
+?>
diff --git a/web/classes/jpgraph/jpgraph_pie3d.php b/web/classes/jpgraph/jpgraph_pie3d.php
new file mode 100755
index 0000000000000000000000000000000000000000..52b8631e6b28c9c48795c2d8365668398de54627
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_pie3d.php
@@ -0,0 +1,933 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_PIE3D.PHP
+ // Description: 3D Pie plot extension for JpGraph
+ // Created:     2001-03-24
+ // Ver:         $Id: jpgraph_pie3d.php 1329 2009-06-20 19:23:30Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+//===================================================
+// CLASS PiePlot3D
+// Description: Plots a 3D pie with a specified projection
+// angle between 20 and 70 degrees.
+//===================================================
+class PiePlot3D extends PiePlot {
+    private $labelhintcolor="red",$showlabelhint=true;
+    private $angle=50;
+    private $edgecolor="", $edgeweight=1;
+    private $iThickness=false;
+
+    //---------------
+    // CONSTRUCTOR
+    function __construct($data) {
+        $this->radius = 0.5;
+        $this->data = $data;
+        $this->title = new Text("");
+        $this->title->SetFont(FF_FONT1,FS_BOLD);
+        $this->value = new DisplayValue();
+        $this->value->Show();
+        $this->value->SetFormat('%.0f%%');
+    }
+
+    //---------------
+    // PUBLIC METHODS
+
+    // Set label arrays
+    function SetLegends($aLegend) {
+        $this->legends = array_reverse(array_slice($aLegend,0,count($this->data)));
+    }
+
+    function SetSliceColors($aColors) {
+        $this->setslicecolors = $aColors;
+    }
+
+    function Legend($aGraph) {
+        parent::Legend($aGraph);
+        $aGraph->legend->txtcol = array_reverse($aGraph->legend->txtcol);
+    }
+
+    function SetCSIMTargets($aTargets,$aAlts='',$aWinTargets='') {
+        $this->csimtargets = $aTargets;
+        $this->csimwintargets = $aWinTargets;
+        $this->csimalts = $aAlts;
+    }
+
+    // Should the slices be separated by a line? If color is specified as "" no line
+    // will be used to separate pie slices.
+    function SetEdge($aColor='black',$aWeight=1) {
+        $this->edgecolor = $aColor;
+        $this->edgeweight = $aWeight;
+    }
+
+    // Specify projection angle for 3D in degrees
+    // Must be between 20 and 70 degrees
+    function SetAngle($a) {
+        if( $a<5 || $a>90 ) {
+            JpGraphError::RaiseL(14002);
+            //("PiePlot3D::SetAngle() 3D Pie projection angle must be between 5 and 85 degrees.");
+        }
+        else {
+            $this->angle = $a;
+        }
+    }
+
+    function Add3DSliceToCSIM($i,$xc,$yc,$height,$width,$thick,$sa,$ea) {  //Slice number, ellipse centre (x,y), height, width, start angle, end angle
+
+        $sa *= M_PI/180;
+        $ea *= M_PI/180;
+
+        //add coordinates of the centre to the map
+        $coords = "$xc, $yc";
+
+        //add coordinates of the first point on the arc to the map
+        $xp = floor($width*cos($sa)/2+$xc);
+        $yp = floor($yc-$height*sin($sa)/2);
+        $coords.= ", $xp, $yp";
+
+        //If on the front half, add the thickness offset
+        if ($sa >= M_PI && $sa <= 2*M_PI*1.01) {
+            $yp = floor($yp+$thick);
+            $coords.= ", $xp, $yp";
+        }
+
+        //add coordinates every 0.2 radians
+        $a=$sa+0.2;
+        while ($a<$ea) {
+            $xp = floor($width*cos($a)/2+$xc);
+            if ($a >= M_PI && $a <= 2*M_PI*1.01) {
+                $yp = floor($yc-($height*sin($a)/2)+$thick);
+            } else {
+                $yp = floor($yc-$height*sin($a)/2);
+            }
+            $coords.= ", $xp, $yp";
+            $a += 0.2;
+        }
+
+        //Add the last point on the arc
+        $xp = floor($width*cos($ea)/2+$xc);
+        $yp = floor($yc-$height*sin($ea)/2);
+
+
+        if ($ea >= M_PI && $ea <= 2*M_PI*1.01) {
+            $coords.= ", $xp, ".floor($yp+$thick);
+        }
+        $coords.= ", $xp, $yp";
+        $alt='';
+
+        if( !empty($this->csimtargets[$i]) ) {
+            $this->csimareas .= "<area shape=\"poly\" coords=\"$coords\" href=\"".$this->csimtargets[$i]."\"";
+
+            if( !empty($this->csimwintargets[$i]) ) {
+                $this->csimareas .= " target=\"".$this->csimwintargets[$i]."\" ";
+            }
+             
+            if( !empty($this->csimalts[$i]) ) {
+                $tmp=sprintf($this->csimalts[$i],$this->data[$i]);
+                $this->csimareas .= "alt=\"$tmp\" title=\"$tmp\" ";
+            }
+            $this->csimareas .=  " />\n";
+        }
+
+    }
+
+    function SetLabels($aLabels,$aLblPosAdj="auto") {
+        $this->labels = $aLabels;
+        $this->ilabelposadj=$aLblPosAdj;
+    }
+
+
+    // Distance from the pie to the labels
+    function SetLabelMargin($m) {
+        $this->value->SetMargin($m);
+    }
+
+    // Show a thin line from the pie to the label for a specific slice
+    function ShowLabelHint($f=true) {
+        $this->showlabelhint=$f;
+    }
+
+    // Set color of hint line to label for each slice
+    function SetLabelHintColor($c) {
+        $this->labelhintcolor=$c;
+    }
+
+    function SetHeight($aHeight) {
+        $this->iThickness = $aHeight;
+    }
+
+
+    // Normalize Angle between 0-360
+    function NormAngle($a) {
+        // Normalize anle to 0 to 2M_PI
+        //
+        if( $a > 0 ) {
+            while($a > 360) $a -= 360;
+        }
+        else {
+            while($a < 0) $a += 360;
+        }
+        if( $a < 0 )
+        $a = 360 + $a;
+
+        if( $a == 360 ) $a=0;
+        return $a;
+    }
+
+
+
+    // Draw one 3D pie slice at position ($xc,$yc) with height $z
+    function Pie3DSlice($img,$xc,$yc,$w,$h,$sa,$ea,$z,$fillcolor,$shadow=0.65) {
+
+        // Due to the way the 3D Pie algorithm works we are
+        // guaranteed that any slice we get into this method
+        // belongs to either the left or right side of the
+        // pie ellipse. Hence, no slice will cross 90 or 270
+        // point.
+        if( ($sa < 90 && $ea > 90) || ( ($sa > 90 && $sa < 270) && $ea > 270) ) {
+            JpGraphError::RaiseL(14003);//('Internal assertion failed. Pie3D::Pie3DSlice');
+            exit(1);
+        }
+
+        $p[] = array();
+
+        // Setup pre-calculated values
+        $rsa = $sa/180*M_PI; // to Rad
+        $rea = $ea/180*M_PI; // to Rad
+        $sinsa = sin($rsa);
+        $cossa = cos($rsa);
+        $sinea = sin($rea);
+        $cosea = cos($rea);
+
+        // p[] is the points for the overall slice and
+        // pt[] is the points for the top pie
+
+        // Angular step when approximating the arc with a polygon train.
+        $step = 0.05;
+
+        if( $sa >= 270 ) {
+            if( $ea > 360 || ($ea > 0 && $ea <= 90) ) {
+                if( $ea > 0 && $ea <= 90 ) {
+                    // Adjust angle to simplify conditions in loops
+                    $rea += 2*M_PI;
+                }
+
+                $p = array($xc,$yc,$xc,$yc+$z,
+                $xc+$w*$cossa,$z+$yc-$h*$sinsa);
+                $pt = array($xc,$yc,$xc+$w*$cossa,$yc-$h*$sinsa);
+
+                for( $a=$rsa; $a < 2*M_PI; $a += $step ) {
+                    $tca = cos($a);
+                    $tsa = sin($a);
+                    $p[] = $xc+$w*$tca;
+                    $p[] = $z+$yc-$h*$tsa;
+                    $pt[] = $xc+$w*$tca;
+                    $pt[] = $yc-$h*$tsa;
+                }
+
+                $pt[] = $xc+$w;
+                $pt[] = $yc;
+
+                $p[] = $xc+$w;
+                $p[] = $z+$yc;
+                $p[] = $xc+$w;
+                $p[] = $yc;
+                $p[] = $xc;
+                $p[] = $yc;
+
+                for( $a=2*M_PI+$step; $a < $rea; $a += $step ) {
+                    $pt[] = $xc + $w*cos($a);
+                    $pt[] = $yc - $h*sin($a);
+                }
+
+                $pt[] = $xc+$w*$cosea;
+                $pt[] = $yc-$h*$sinea;
+                $pt[] = $xc;
+                $pt[] = $yc;
+
+            }
+            else {
+                $p = array($xc,$yc,$xc,$yc+$z,
+                $xc+$w*$cossa,$z+$yc-$h*$sinsa);
+                $pt = array($xc,$yc,$xc+$w*$cossa,$yc-$h*$sinsa);
+
+                $rea = $rea == 0.0 ? 2*M_PI : $rea;
+                for( $a=$rsa; $a < $rea; $a += $step ) {
+                    $tca = cos($a);
+                    $tsa = sin($a);
+                    $p[] = $xc+$w*$tca;
+                    $p[] = $z+$yc-$h*$tsa;
+                    $pt[] = $xc+$w*$tca;
+                    $pt[] = $yc-$h*$tsa;
+                }
+
+                $pt[] = $xc+$w*$cosea;
+                $pt[] = $yc-$h*$sinea;
+                $pt[] = $xc;
+                $pt[] = $yc;
+
+                $p[] = $xc+$w*$cosea;
+                $p[] = $z+$yc-$h*$sinea;
+                $p[] = $xc+$w*$cosea;
+                $p[] = $yc-$h*$sinea;
+                $p[] = $xc;
+                $p[] = $yc;
+            }
+        }
+        elseif( $sa >= 180 ) {
+            $p = array($xc,$yc,$xc,$yc+$z,$xc+$w*$cosea,$z+$yc-$h*$sinea);
+            $pt = array($xc,$yc,$xc+$w*$cosea,$yc-$h*$sinea);
+
+            for( $a=$rea; $a>$rsa; $a -= $step ) {
+                $tca = cos($a);
+                $tsa = sin($a);
+                $p[] = $xc+$w*$tca;
+                $p[] = $z+$yc-$h*$tsa;
+                $pt[] = $xc+$w*$tca;
+                $pt[] = $yc-$h*$tsa;
+            }
+
+            $pt[] = $xc+$w*$cossa;
+            $pt[] = $yc-$h*$sinsa;
+            $pt[] = $xc;
+            $pt[] = $yc;
+
+            $p[] = $xc+$w*$cossa;
+            $p[] = $z+$yc-$h*$sinsa;
+            $p[] = $xc+$w*$cossa;
+            $p[] = $yc-$h*$sinsa;
+            $p[] = $xc;
+            $p[] = $yc;
+
+        }
+        elseif( $sa >= 90 ) {
+            if( $ea > 180 ) {
+                $p = array($xc,$yc,$xc,$yc+$z,$xc+$w*$cosea,$z+$yc-$h*$sinea);
+                $pt = array($xc,$yc,$xc+$w*$cosea,$yc-$h*$sinea);
+
+                for( $a=$rea; $a > M_PI; $a -= $step ) {
+                    $tca = cos($a);
+                    $tsa = sin($a);
+                    $p[] = $xc+$w*$tca;
+                    $p[] = $z + $yc - $h*$tsa;
+                    $pt[] = $xc+$w*$tca;
+                    $pt[] = $yc-$h*$tsa;
+                }
+
+                $p[] = $xc-$w;
+                $p[] = $z+$yc;
+                $p[] = $xc-$w;
+                $p[] = $yc;
+                $p[] = $xc;
+                $p[] = $yc;
+
+                $pt[] = $xc-$w;
+                $pt[] = $z+$yc;
+                $pt[] = $xc-$w;
+                $pt[] = $yc;
+
+                for( $a=M_PI-$step; $a > $rsa; $a -= $step ) {
+                    $pt[] = $xc + $w*cos($a);
+                    $pt[] = $yc - $h*sin($a);
+                }
+
+                $pt[] = $xc+$w*$cossa;
+                $pt[] = $yc-$h*$sinsa;
+                $pt[] = $xc;
+                $pt[] = $yc;
+
+            }
+            else { // $sa >= 90 && $ea <= 180
+                $p = array($xc,$yc,$xc,$yc+$z,
+                $xc+$w*$cosea,$z+$yc-$h*$sinea,
+                $xc+$w*$cosea,$yc-$h*$sinea,
+                $xc,$yc);
+
+                $pt = array($xc,$yc,$xc+$w*$cosea,$yc-$h*$sinea);
+
+                for( $a=$rea; $a>$rsa; $a -= $step ) {
+                    $pt[] = $xc + $w*cos($a);
+                    $pt[] = $yc - $h*sin($a);
+                }
+
+                $pt[] = $xc+$w*$cossa;
+                $pt[] = $yc-$h*$sinsa;
+                $pt[] = $xc;
+                $pt[] = $yc;
+
+            }
+        }
+        else { // sa > 0 && ea < 90
+
+            $p = array($xc,$yc,$xc,$yc+$z,
+            $xc+$w*$cossa,$z+$yc-$h*$sinsa,
+            $xc+$w*$cossa,$yc-$h*$sinsa,
+            $xc,$yc);
+
+            $pt = array($xc,$yc,$xc+$w*$cossa,$yc-$h*$sinsa);
+
+            for( $a=$rsa; $a < $rea; $a += $step ) {
+                $pt[] = $xc + $w*cos($a);
+                $pt[] = $yc - $h*sin($a);
+            }
+
+            $pt[] = $xc+$w*$cosea;
+            $pt[] = $yc-$h*$sinea;
+            $pt[] = $xc;
+            $pt[] = $yc;
+        }
+         
+        $img->PushColor($fillcolor.":".$shadow);
+        $img->FilledPolygon($p);
+        $img->PopColor();
+
+        $img->PushColor($fillcolor);
+        $img->FilledPolygon($pt);
+        $img->PopColor();
+    }
+
+    function SetStartAngle($aStart) {
+        if( $aStart < 0 || $aStart > 360 ) {
+            JpGraphError::RaiseL(14004);//('Slice start angle must be between 0 and 360 degrees.');
+        }
+        $this->startangle = $aStart;
+    }
+
+    // Draw a 3D Pie
+    function Pie3D($aaoption,$img,$data,$colors,$xc,$yc,$d,$angle,$z,
+                   $shadow=0.65,$startangle=0,$edgecolor="",$edgeweight=1) {
+
+        //---------------------------------------------------------------------------
+        // As usual the algorithm get more complicated than I originally
+        // envisioned. I believe that this is as simple as it is possible
+        // to do it with the features I want. It's a good exercise to start
+        // thinking on how to do this to convince your self that all this
+        // is really needed for the general case.
+        //
+        // The algorithm two draw 3D pies without "real 3D" is done in
+        // two steps.
+        // First imagine the pie cut in half through a thought line between
+        // 12'a clock and 6'a clock. It now easy to imagine that we can plot
+        // the individual slices for each half by starting with the topmost
+        // pie slice and continue down to 6'a clock.
+        //
+        // In the algortithm this is done in three principal steps
+        // Step 1. Do the knife cut to ensure by splitting slices that extends
+        // over the cut line. This is done by splitting the original slices into
+        // upto 3 subslices.
+        // Step 2. Find the top slice for each half
+        // Step 3. Draw the slices from top to bottom
+        //
+        // The thing that slightly complicates this scheme with all the
+        // angle comparisons below is that we can have an arbitrary start
+        // angle so we must take into account the different equivalence classes.
+        // For the same reason we must walk through the angle array in a
+        // modulo fashion.
+        //
+        // Limitations of algorithm:
+        // * A small exploded slice which crosses the 270 degree point
+        //   will get slightly nagged close to the center due to the fact that
+        //   we print the slices in Z-order and that the slice left part
+        //   get printed first and might get slightly nagged by a larger
+        //   slice on the right side just before the right part of the small
+        //   slice. Not a major problem though.
+        //---------------------------------------------------------------------------
+
+
+        // Determine the height of the ellippse which gives an
+        // indication of the inclination angle
+        $h = ($angle/90.0)*$d;
+        $sum = 0;
+        for($i=0; $i<count($data); ++$i ) {
+            $sum += $data[$i];
+        }
+
+        // Special optimization
+        if( $sum==0 ) return;
+
+        if( $this->labeltype == 2 ) {
+            $this->adjusted_data = $this->AdjPercentage($data);
+        }
+
+        // Setup the start
+        $accsum = 0;
+        $a = $startangle;
+        $a = $this->NormAngle($a);
+
+        //
+        // Step 1 . Split all slices that crosses 90 or 270
+        //
+        $idx=0;
+        $adjexplode=array();
+        $numcolors = count($colors);
+        for($i=0; $i<count($data); ++$i, ++$idx ) {
+            $da = $data[$i]/$sum * 360;
+
+            if( empty($this->explode_radius[$i]) ) {
+                $this->explode_radius[$i]=0;
+            }
+
+            $expscale=1;
+            if( $aaoption == 1 ) {
+                $expscale=2;
+            }
+
+            $la = $a + $da/2;
+            $explode = array( $xc + $this->explode_radius[$i]*cos($la*M_PI/180)*$expscale,
+            $yc - $this->explode_radius[$i]*sin($la*M_PI/180) * ($h/$d) *$expscale );
+            $adjexplode[$idx] = $explode;
+            $labeldata[$i] = array($la,$explode[0],$explode[1]);
+            $originalangles[$i] = array($a,$a+$da);
+
+            $ne = $this->NormAngle($a+$da);
+            if( $da <= 180 ) {
+                // If the slice size is <= 90 it can at maximum cut across
+                // one boundary (either 90 or 270) where it needs to be split
+                $split=-1; // no split
+                if( ($da<=90 && ($a <= 90 && $ne > 90)) ||
+                (($da <= 180 && $da >90)  && (($a < 90 || $a >= 270) && $ne > 90)) ) {
+                    $split = 90;
+                }
+                elseif( ($da<=90 && ($a <= 270 && $ne > 270)) ||
+                (($da<=180 && $da>90) && ($a >= 90 && $a < 270 && ($a+$da) > 270 )) ) {
+                    $split = 270;
+                }
+                if( $split > 0 ) { // split in two
+                    $angles[$idx] = array($a,$split);
+                    $adjcolors[$idx] = $colors[$i % $numcolors];
+                    $adjexplode[$idx] = $explode;
+                    $angles[++$idx] = array($split,$ne);
+                    $adjcolors[$idx] = $colors[$i % $numcolors];
+                    $adjexplode[$idx] = $explode;
+                }
+                else { // no split
+                    $angles[$idx] = array($a,$ne);
+                    $adjcolors[$idx] = $colors[$i  % $numcolors];
+                    $adjexplode[$idx] = $explode;
+                }
+            }
+            else {
+                // da>180
+                // Slice may, depending on position, cross one or two
+                // bonudaries
+
+                if( $a < 90 )        $split = 90;
+                elseif( $a <= 270 )  $split = 270;
+                else                 $split = 90;
+
+                $angles[$idx] = array($a,$split);
+                $adjcolors[$idx] = $colors[$i % $numcolors];
+                $adjexplode[$idx] = $explode;
+                //if( $a+$da > 360-$split ) {
+                // For slices larger than 270 degrees we might cross
+                // another boundary as well. This means that we must
+                // split the slice further. The comparison gets a little
+                // bit complicated since we must take into accound that
+                // a pie might have a startangle >0 and hence a slice might
+                // wrap around the 0 angle.
+                // Three cases:
+                //  a) Slice starts before 90 and hence gets a split=90, but
+                //     we must also check if we need to split at 270
+                //  b) Slice starts after 90 but before 270 and slices
+                //     crosses 90 (after a wrap around of 0)
+                //  c) If start is > 270 (hence the firstr split is at 90)
+                //     and the slice is so large that it goes all the way
+                //     around 270.
+                if( ($a < 90 && ($a+$da > 270)) || ($a > 90 && $a<=270 && ($a+$da>360+90) ) || ($a > 270 && $this->NormAngle($a+$da)>270) ) {
+                    $angles[++$idx] = array($split,360-$split);
+                    $adjcolors[$idx] = $colors[$i % $numcolors];
+                    $adjexplode[$idx] = $explode;
+                    $angles[++$idx] = array(360-$split,$ne);
+                    $adjcolors[$idx] = $colors[$i % $numcolors];
+                    $adjexplode[$idx] = $explode;
+                }
+                else {
+                    // Just a simple split to the previous decided
+                    // angle.
+                    $angles[++$idx] = array($split,$ne);
+                    $adjcolors[$idx] = $colors[$i % $numcolors];
+                    $adjexplode[$idx] = $explode;
+                }
+            }
+            $a += $da;
+            $a = $this->NormAngle($a);
+        }
+
+        // Total number of slices
+        $n = count($angles);
+
+        for($i=0; $i<$n; ++$i) {
+            list($dbgs,$dbge) = $angles[$i];
+        }
+
+        //
+        // Step 2. Find start index (first pie that starts in upper left quadrant)
+        //
+        $minval = $angles[0][0];
+        $min = 0;
+        for( $i=0; $i<$n; ++$i ) {
+            if( $angles[$i][0] < $minval ) {
+                $minval = $angles[$i][0];
+                $min = $i;
+            }
+        }
+        $j = $min;
+        $cnt = 0;
+        while( $angles[$j][1] <= 90 ) {
+            $j++;
+            if( $j>=$n) {
+                $j=0;
+            }
+            if( $cnt > $n ) {
+                JpGraphError::RaiseL(14005);
+                //("Pie3D Internal error (#1). Trying to wrap twice when looking for start index");
+            }
+            ++$cnt;
+        }
+        $start = $j;
+
+        //
+        // Step 3. Print slices in z-order
+        //
+        $cnt = 0;
+
+        // First stroke all the slices between 90 and 270 (left half circle)
+        // counterclockwise
+         
+        while( $angles[$j][0] < 270  && $aaoption !== 2 ) {
+
+            list($x,$y) = $adjexplode[$j];
+
+            $this->Pie3DSlice($img,$x,$y,$d,$h,$angles[$j][0],$angles[$j][1],
+            $z,$adjcolors[$j],$shadow);
+
+            $last = array($x,$y,$j);
+
+            $j++;
+            if( $j >= $n ) $j=0;
+            if( $cnt > $n ) {
+                JpGraphError::RaiseL(14006);
+                //("Pie3D Internal Error: Z-Sorting algorithm for 3D Pies is not working properly (2). Trying to wrap twice while stroking.");
+            }
+            ++$cnt;
+        }
+         
+        $slice_left = $n-$cnt;
+        $j=$start-1;
+        if($j<0) $j=$n-1;
+        $cnt = 0;
+
+        // The stroke all slices from 90 to -90 (right half circle)
+        // clockwise
+        while( $cnt < $slice_left  && $aaoption !== 2 ) {
+
+            list($x,$y) = $adjexplode[$j];
+
+            $this->Pie3DSlice($img,$x,$y,$d,$h,$angles[$j][0],$angles[$j][1],
+            $z,$adjcolors[$j],$shadow);
+            $j--;
+            if( $cnt > $n ) {
+                JpGraphError::RaiseL(14006);
+                //("Pie3D Internal Error: Z-Sorting algorithm for 3D Pies is not working properly (2). Trying to wrap twice while stroking.");
+            }
+            if($j<0) $j=$n-1;
+            $cnt++;
+        }
+
+        // Now do a special thing. Stroke the last slice on the left
+        // halfcircle one more time.  This is needed in the case where
+        // the slice close to 270 have been exploded. In that case the
+        // part of the slice close to the center of the pie might be
+        // slightly nagged.
+        if( $aaoption !== 2 )
+        $this->Pie3DSlice($img,$last[0],$last[1],$d,$h,$angles[$last[2]][0],
+        $angles[$last[2]][1],$z,$adjcolors[$last[2]],$shadow);
+
+
+        if( $aaoption !== 1 ) {
+            // Now print possible labels and add csim
+            $this->value->ApplyFont($img);
+            $margin = $img->GetFontHeight()/2 + $this->value->margin ;
+            for($i=0; $i < count($data); ++$i ) {
+                $la = $labeldata[$i][0];
+                $x = $labeldata[$i][1] + cos($la*M_PI/180)*($d+$margin)*$this->ilabelposadj;
+                $y = $labeldata[$i][2] - sin($la*M_PI/180)*($h+$margin)*$this->ilabelposadj;
+                if( $this->ilabelposadj >= 1.0 ) {
+                    if( $la > 180 && $la < 360 ) $y += $z;
+                }
+                if( $this->labeltype == 0 ) {
+                    if( $sum > 0 ) $l = 100*$data[$i]/$sum;
+                    else $l = 0;
+                }
+                elseif( $this->labeltype == 1 ) {
+                    $l = $data[$i];
+                }
+                else {
+                    $l = $this->adjusted_data[$i];
+                }
+                if( isset($this->labels[$i]) && is_string($this->labels[$i]) ) {
+                    $l=sprintf($this->labels[$i],$l);
+                }
+
+                $this->StrokeLabels($l,$img,$labeldata[$i][0]*M_PI/180,$x,$y,$z);
+                 
+                $this->Add3DSliceToCSIM($i,$labeldata[$i][1],$labeldata[$i][2],$h*2,$d*2,$z,
+                $originalangles[$i][0],$originalangles[$i][1]);
+            }
+        }
+
+        //
+        // Finally add potential lines in pie
+        //
+
+        if( $edgecolor=="" || $aaoption !== 0 ) return;
+
+        $accsum = 0;
+        $a = $startangle;
+        $a = $this->NormAngle($a);
+
+        $a *= M_PI/180.0;
+
+        $idx=0;
+        $img->PushColor($edgecolor);
+        $img->SetLineWeight($edgeweight);
+
+        $fulledge = true;
+        for($i=0; $i < count($data) && $fulledge; ++$i ) {
+            if( empty($this->explode_radius[$i]) ) {
+                $this->explode_radius[$i]=0;
+            }
+            if( $this->explode_radius[$i] > 0 ) {
+                $fulledge = false;
+            }
+        }
+         
+
+        for($i=0; $i < count($data); ++$i, ++$idx ) {
+
+            $da = $data[$i]/$sum * 2*M_PI;
+            $this->StrokeFullSliceFrame($img,$xc,$yc,$a,$a+$da,$d,$h,$z,$edgecolor,
+            $this->explode_radius[$i],$fulledge);
+            $a += $da;
+        }
+        $img->PopColor();
+    }
+
+    function StrokeFullSliceFrame($img,$xc,$yc,$sa,$ea,$w,$h,$z,$edgecolor,$exploderadius,$fulledge) {
+        $step = 0.02;
+
+        if( $exploderadius > 0 ) {
+            $la = ($sa+$ea)/2;
+            $xc += $exploderadius*cos($la);
+            $yc -= $exploderadius*sin($la) * ($h/$w) ;
+             
+        }
+
+        $p = array($xc,$yc,$xc+$w*cos($sa),$yc-$h*sin($sa));
+
+        for($a=$sa; $a < $ea; $a += $step ) {
+            $p[] = $xc + $w*cos($a);
+            $p[] = $yc - $h*sin($a);
+        }
+
+        $p[] = $xc+$w*cos($ea);
+        $p[] = $yc-$h*sin($ea);
+        $p[] = $xc;
+        $p[] = $yc;
+
+        $img->SetColor($edgecolor);
+        $img->Polygon($p);
+
+        // Unfortunately we can't really draw the full edge around the whole of
+        // of the slice if any of the slices are exploded. The reason is that
+        // this algorithm is to simply. There are cases where the edges will
+        // "overwrite" other slices when they have been exploded.
+        // Doing the full, proper 3D hidden lines stiff is actually quite
+        // tricky. So for exploded pies we only draw the top edge. Not perfect
+        // but the "real" solution is much more complicated.
+        if( $fulledge && !( $sa > 0 && $sa < M_PI && $ea < M_PI) ) {
+
+            if($sa < M_PI && $ea > M_PI) {
+                $sa = M_PI;
+            }
+
+            if($sa < 2*M_PI && (($ea >= 2*M_PI) || ($ea > 0 && $ea < $sa ) ) ) {
+                $ea = 2*M_PI;
+            }
+
+            if( $sa >= M_PI && $ea <= 2*M_PI ) {
+                $p = array($xc + $w*cos($sa),$yc - $h*sin($sa),
+                $xc + $w*cos($sa),$z + $yc - $h*sin($sa));
+
+                for($a=$sa+$step; $a < $ea; $a += $step ) {
+                    $p[] = $xc + $w*cos($a);
+                    $p[] = $z + $yc - $h*sin($a);
+                }
+                $p[] = $xc + $w*cos($ea);
+                $p[] = $z + $yc - $h*sin($ea);
+                $p[] = $xc + $w*cos($ea);
+                $p[] = $yc - $h*sin($ea);
+                $img->SetColor($edgecolor);
+                $img->Polygon($p);
+            }
+        }
+    }
+
+    function Stroke($img,$aaoption=0) {
+        $n = count($this->data);
+
+        // If user hasn't set the colors use the theme array
+        if( $this->setslicecolors==null ) {
+            $colors = array_keys($img->rgb->rgb_table);
+            sort($colors);
+            $idx_a=$this->themearr[$this->theme];
+            $ca = array();
+            $m = count($idx_a);
+            for($i=0; $i < $m; ++$i) {
+                $ca[$i] = $colors[$idx_a[$i]];
+            }
+            $ca = array_reverse(array_slice($ca,0,$n));
+        }
+        else {
+            $ca = $this->setslicecolors;
+        }
+
+
+        if( $this->posx <= 1 && $this->posx > 0 ) {
+            $xc = round($this->posx*$img->width);
+        }
+        else {
+            $xc = $this->posx ;
+        }
+
+        if( $this->posy <= 1 && $this->posy > 0 ) {
+            $yc = round($this->posy*$img->height);
+        }
+        else {
+            $yc = $this->posy ;
+        }
+
+        if( $this->radius <= 1 ) {
+            $width = floor($this->radius*min($img->width,$img->height));
+            // Make sure that the pie doesn't overflow the image border
+            // The 0.9 factor is simply an extra margin to leave some space
+            // between the pie an the border of the image.
+            $width = min($width,min($xc*0.9,($yc*90/$this->angle-$width/4)*0.9));
+        }
+        else {
+            $width = $this->radius * ($aaoption === 1 ? 2 : 1 ) ;
+        }
+
+        // Add a sanity check for width
+        if( $width < 1 ) {
+            JpGraphError::RaiseL(14007);//("Width for 3D Pie is 0. Specify a size > 0");
+        }
+
+        // Establish a thickness. By default the thickness is a fifth of the
+        // pie slice width (=pie radius) but since the perspective depends
+        // on the inclination angle we use some heuristics to make the edge
+        // slightly thicker the less the angle.
+
+        // Has user specified an absolute thickness? In that case use
+        // that instead
+
+        if( $this->iThickness ) {
+            $thick = $this->iThickness;
+            $thick *= ($aaoption === 1 ? 2 : 1 );
+        }
+        else {
+            $thick = $width/12;
+        }
+        $a = $this->angle;
+        
+        if( $a <= 30 ) $thick *= 1.6;
+        elseif( $a <= 40 ) $thick *= 1.4;
+        elseif( $a <= 50 ) $thick *= 1.2;
+        elseif( $a <= 60 ) $thick *= 1.0;
+        elseif( $a <= 70 ) $thick *= 0.8;
+        elseif( $a <= 80 ) $thick *= 0.7;
+        else $thick *= 0.6;
+
+        $thick = floor($thick);
+
+        if( $this->explode_all ) {
+            for($i=0; $i < $n; ++$i)
+                $this->explode_radius[$i]=$this->explode_r;
+        }
+
+        $this->Pie3D($aaoption,$img,$this->data, $ca, $xc, $yc, $width, $this->angle,
+        $thick, 0.65, $this->startangle, $this->edgecolor, $this->edgeweight);
+
+        // Adjust title position
+        if( $aaoption != 1 ) {
+            $this->title->SetPos($xc,$yc-$this->title->GetFontHeight($img)-$width/2-$this->title->margin,         "center","bottom");
+            $this->title->Stroke($img);
+        }
+    }
+
+    //---------------
+    // PRIVATE METHODS
+
+    // Position the labels of each slice
+    function StrokeLabels($label,$img,$a,$xp,$yp,$z) {
+        $this->value->halign="left";
+        $this->value->valign="top";
+
+        // Position the axis title.
+        // dx, dy is the offset from the top left corner of the bounding box that sorrounds the text
+        // that intersects with the extension of the corresponding axis. The code looks a little
+        // bit messy but this is really the only way of having a reasonable position of the
+        // axis titles.
+        $this->value->ApplyFont($img);
+        $h=$img->GetTextHeight($label);
+        // For numeric values the format of the display value
+        // must be taken into account
+        if( is_numeric($label) ) {
+            if( $label >= 0 ) {
+                $w=$img->GetTextWidth(sprintf($this->value->format,$label));
+            }
+            else {
+                $w=$img->GetTextWidth(sprintf($this->value->negformat,$label));
+            }
+        }
+        else {
+            $w=$img->GetTextWidth($label);
+        }
+        
+        while( $a > 2*M_PI ) {
+            $a -= 2*M_PI;
+        }
+        
+        if( $a>=7*M_PI/4 || $a <= M_PI/4 ) $dx=0;
+        if( $a>=M_PI/4 && $a <= 3*M_PI/4 ) $dx=($a-M_PI/4)*2/M_PI;
+        if( $a>=3*M_PI/4 && $a <= 5*M_PI/4 ) $dx=1;
+        if( $a>=5*M_PI/4 && $a <= 7*M_PI/4 ) $dx=(1-($a-M_PI*5/4)*2/M_PI);
+
+        if( $a>=7*M_PI/4 ) $dy=(($a-M_PI)-3*M_PI/4)*2/M_PI;
+        if( $a<=M_PI/4 ) $dy=(1-$a*2/M_PI);
+        if( $a>=M_PI/4 && $a <= 3*M_PI/4 ) $dy=1;
+        if( $a>=3*M_PI/4 && $a <= 5*M_PI/4 ) $dy=(1-($a-3*M_PI/4)*2/M_PI);
+        if( $a>=5*M_PI/4 && $a <= 7*M_PI/4 ) $dy=0;
+
+        $x = round($xp-$dx*$w);
+        $y = round($yp-$dy*$h);
+
+        // Mark anchor point for debugging
+        /*
+        $img->SetColor('red');
+        $img->Line($xp-10,$yp,$xp+10,$yp);
+        $img->Line($xp,$yp-10,$xp,$yp+10);
+        */
+
+        $oldmargin = $this->value->margin;
+        $this->value->margin=0;
+        $this->value->Stroke($img,$label,$x,$y);
+        $this->value->margin=$oldmargin;
+
+    }
+} // Class
+
+/* EOF */
+?>
diff --git a/web/classes/jpgraph/jpgraph_plotband.php b/web/classes/jpgraph/jpgraph_plotband.php
new file mode 100755
index 0000000000000000000000000000000000000000..b7aef75069bea837ffbf3eaf23ca2956395e3b7b
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_plotband.php
@@ -0,0 +1,635 @@
+<?php
+//=======================================================================
+// File:        JPGRAPH_PLOTBAND.PHP
+// Description: PHP4 Graph Plotting library. Extension module.
+// Created:     2004-02-18
+// Ver:         $Id: jpgraph_plotband.php 1106 2009-02-22 20:16:35Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+// Constants for types of static bands in plot area
+define("BAND_RDIAG",1); // Right diagonal lines
+define("BAND_LDIAG",2); // Left diagonal lines
+define("BAND_SOLID",3); // Solid one color
+define("BAND_VLINE",4); // Vertical lines
+define("BAND_HLINE",5);  // Horizontal lines
+define("BAND_3DPLANE",6);  // "3D" Plane
+define("BAND_HVCROSS",7);  // Vertical/Hor crosses
+define("BAND_DIAGCROSS",8); // Diagonal crosses
+
+
+// Utility class to hold coordinates for a rectangle
+class Rectangle {
+    public $x,$y,$w,$h;
+    public $xe, $ye;
+    function __construct($aX,$aY,$aWidth,$aHeight) {
+        $this->x=$aX;
+        $this->y=$aY;
+        $this->w=$aWidth;
+        $this->h=$aHeight;
+        $this->xe=$aX+$aWidth-1;
+        $this->ye=$aY+$aHeight-1;
+    }
+}
+
+//=====================================================================
+// Class RectPattern
+// Base class for pattern hierarchi that is used to display patterned
+// bands on the graph. Any subclass that doesn't override Stroke()
+// must at least implement method DoPattern($aImg) which is responsible
+// for drawing the pattern onto the graph.
+//=====================================================================
+class RectPattern {
+    protected $color;
+    protected $weight;
+    protected $rect=null;
+    protected $doframe=true;
+    protected $linespacing; // Line spacing in pixels
+    protected $iBackgroundColor=-1;  // Default is no background fill
+
+    function __construct($aColor,$aWeight=1) {
+        $this->color = $aColor;
+        $this->weight = $aWeight;
+    }
+
+    function SetBackground($aBackgroundColor) {
+        $this->iBackgroundColor=$aBackgroundColor;
+    }
+
+    function SetPos($aRect) {
+        $this->rect = $aRect;
+    }
+
+    function ShowFrame($aShow=true) {
+        $this->doframe=$aShow;
+    }
+
+    function SetDensity($aDens) {
+        if( $aDens < 1 || $aDens > 100 )
+        JpGraphError::RaiseL(16001,$aDens);
+        //(" Desity for pattern must be between 1 and 100. (You tried $aDens)");
+        // 1% corresponds to linespacing=50
+        // 100 % corresponds to linespacing 1
+        $this->linespacing = floor(((100-$aDens)/100.0)*50)+1;
+
+    }
+
+    function Stroke($aImg) {
+        if( $this->rect == null )
+        JpGraphError::RaiseL(16002);
+        //(" No positions specified for pattern.");
+
+        if( !(is_numeric($this->iBackgroundColor) && $this->iBackgroundColor==-1) ) {
+            $aImg->SetColor($this->iBackgroundColor);
+            $aImg->FilledRectangle($this->rect->x,$this->rect->y,$this->rect->xe,$this->rect->ye);
+        }
+
+        $aImg->SetColor($this->color);
+        $aImg->SetLineWeight($this->weight);
+
+        // Virtual function implemented by subclass
+        $this->DoPattern($aImg);
+
+        // Frame around the pattern area
+        if( $this->doframe )
+        $aImg->Rectangle($this->rect->x,$this->rect->y,$this->rect->xe,$this->rect->ye);
+    }
+
+}
+
+
+//=====================================================================
+// Class RectPatternSolid
+// Implements a solid band
+//=====================================================================
+class RectPatternSolid extends RectPattern {
+
+    function __construct($aColor="black",$aWeight=1) {
+        parent::__construct($aColor,$aWeight);
+    }
+
+    function DoPattern($aImg) {
+        $aImg->SetColor($this->color);
+        $aImg->FilledRectangle($this->rect->x,$this->rect->y,
+        $this->rect->xe,$this->rect->ye);
+    }
+}
+
+//=====================================================================
+// Class RectPatternHor
+// Implements horizontal line pattern
+//=====================================================================
+class RectPatternHor extends RectPattern {
+
+    function __construct($aColor="black",$aWeight=1,$aLineSpacing=7) {
+        parent::__construct($aColor,$aWeight);
+        $this->linespacing = $aLineSpacing;
+    }
+
+    function DoPattern($aImg) {
+        $x0 = $this->rect->x;
+        $x1 = $this->rect->xe;
+        $y = $this->rect->y;
+        while( $y < $this->rect->ye ) {
+            $aImg->Line($x0,$y,$x1,$y);
+            $y += $this->linespacing;
+        }
+    }
+}
+
+//=====================================================================
+// Class RectPatternVert
+// Implements vertical line pattern
+//=====================================================================
+class RectPatternVert extends RectPattern {
+
+    function __construct($aColor="black",$aWeight=1,$aLineSpacing=7) {
+        parent::__construct($aColor,$aWeight);
+        $this->linespacing = $aLineSpacing;
+    }
+
+    //--------------------
+    // Private methods
+    //
+    function DoPattern($aImg) {
+        $x = $this->rect->x;
+        $y0 = $this->rect->y;
+        $y1 = $this->rect->ye;
+        while( $x < $this->rect->xe ) {
+            $aImg->Line($x,$y0,$x,$y1);
+            $x += $this->linespacing;
+        }
+    }
+}
+
+
+//=====================================================================
+// Class RectPatternRDiag
+// Implements right diagonal pattern
+//=====================================================================
+class RectPatternRDiag extends RectPattern {
+
+    function __construct($aColor="black",$aWeight=1,$aLineSpacing=12) {
+        parent::__construct($aColor,$aWeight);
+        $this->linespacing = $aLineSpacing;
+    }
+
+    function DoPattern($aImg) {
+        //  --------------------
+        //  | /   /   /   /   /|
+        //  |/   /   /   /   / |
+        //  |   /   /   /   /  |
+        //  --------------------
+        $xe = $this->rect->xe;
+        $ye = $this->rect->ye;
+        $x0 = $this->rect->x + round($this->linespacing/2);
+        $y0 = $this->rect->y;
+        $x1 = $this->rect->x;
+        $y1 = $this->rect->y + round($this->linespacing/2);
+
+        while($x0<=$xe && $y1<=$ye) {
+            $aImg->Line($x0,$y0,$x1,$y1);
+            $x0 += $this->linespacing;
+            $y1 += $this->linespacing;
+        }
+
+        if( $xe-$x1 > $ye-$y0 ) {
+            // Width larger than height
+            $x1 = $this->rect->x + ($y1-$ye);
+            $y1 = $ye;
+            $y0 = $this->rect->y;
+            while( $x0 <= $xe ) {
+                $aImg->Line($x0,$y0,$x1,$y1);
+                $x0 += $this->linespacing;
+                $x1 += $this->linespacing;
+            }
+             
+            $y0=$this->rect->y + ($x0-$xe);
+            $x0=$xe;
+        }
+        else {
+            // Height larger than width
+            $diff = $x0-$xe;
+            $y0 = $diff+$this->rect->y;
+            $x0 = $xe;
+            $x1 = $this->rect->x;
+            while( $y1 <= $ye ) {
+                $aImg->Line($x0,$y0,$x1,$y1);
+                $y1 += $this->linespacing;
+                $y0 += $this->linespacing;
+            }
+             
+            $diff = $y1-$ye;
+            $y1 = $ye;
+            $x1 = $diff + $this->rect->x;
+        }
+
+        while( $y0 <= $ye ) {
+            $aImg->Line($x0,$y0,$x1,$y1);
+            $y0 += $this->linespacing;
+            $x1 += $this->linespacing;
+        }
+    }
+}
+
+//=====================================================================
+// Class RectPatternLDiag
+// Implements left diagonal pattern
+//=====================================================================
+class RectPatternLDiag extends RectPattern {
+
+    function __construct($aColor="black",$aWeight=1,$aLineSpacing=12) {
+        $this->linespacing = $aLineSpacing;
+        parent::__construct($aColor,$aWeight);
+    }
+
+    function DoPattern($aImg) {
+        //  --------------------
+        //  |\   \   \   \   \ |
+        //  | \   \   \   \   \|
+        //  |  \   \   \   \   |
+        //  |------------------|
+        $xe = $this->rect->xe;
+        $ye = $this->rect->ye;
+        $x0 = $this->rect->x + round($this->linespacing/2);
+        $y0 = $this->rect->ye;
+        $x1 = $this->rect->x;
+        $y1 = $this->rect->ye - round($this->linespacing/2);
+
+        while($x0<=$xe && $y1>=$this->rect->y) {
+            $aImg->Line($x0,$y0,$x1,$y1);
+            $x0 += $this->linespacing;
+            $y1 -= $this->linespacing;
+        }
+        if( $xe-$x1 > $ye-$this->rect->y ) {
+            // Width larger than height
+            $x1 = $this->rect->x + ($this->rect->y-$y1);
+            $y0=$ye; $y1=$this->rect->y;
+            while( $x0 <= $xe ) {
+                $aImg->Line($x0,$y0,$x1,$y1);
+                $x0 += $this->linespacing;
+                $x1 += $this->linespacing;
+            }
+             
+            $y0=$this->rect->ye - ($x0-$xe);
+            $x0=$xe;
+        }
+        else {
+            // Height larger than width
+            $diff = $x0-$xe;
+            $y0 = $ye-$diff;
+            $x0 = $xe;
+            while( $y1 >= $this->rect->y ) {
+                $aImg->Line($x0,$y0,$x1,$y1);
+                $y0 -= $this->linespacing;
+                $y1 -= $this->linespacing;
+            }
+            $diff = $this->rect->y - $y1;
+            $x1 = $this->rect->x + $diff;
+            $y1 = $this->rect->y;
+        }
+        while( $y0 >= $this->rect->y ) {
+            $aImg->Line($x0,$y0,$x1,$y1);
+            $y0 -= $this->linespacing;
+            $x1 += $this->linespacing;
+        }
+    }
+}
+
+//=====================================================================
+// Class RectPattern3DPlane
+// Implements "3D" plane pattern
+//=====================================================================
+class RectPattern3DPlane extends RectPattern {
+    private $alpha=50;  // Parameter that specifies the distance
+    // to "simulated" horizon in pixel from the
+    // top of the band. Specifies how fast the lines
+    // converge.
+
+    function __construct($aColor="black",$aWeight=1) {
+        parent::__construct($aColor,$aWeight);
+        $this->SetDensity(10);  // Slightly larger default
+    }
+
+    function SetHorizon($aHorizon) {
+        $this->alpha=$aHorizon;
+    }
+
+    function DoPattern($aImg) {
+        // "Fake" a nice 3D grid-effect.
+        $x0 = $this->rect->x + $this->rect->w/2;
+        $y0 = $this->rect->y;
+        $x1 = $x0;
+        $y1 = $this->rect->ye;
+        $x0_right = $x0;
+        $x1_right = $x1;
+
+        // BTW "apa" means monkey in Swedish but is really a shortform for
+        // "alpha+a" which was the labels I used on paper when I derived the
+        // geometric to get the 3D perspective right.
+        // $apa is the height of the bounding rectangle plus the distance to the
+        // artifical horizon (alpha)
+        $apa = $this->rect->h + $this->alpha;
+
+        // Three cases and three loops
+        // 1) The endpoint of the line ends on the bottom line
+        // 2) The endpoint ends on the side
+        // 3) Horizontal lines
+
+        // Endpoint falls on bottom line
+        $middle=$this->rect->x + $this->rect->w/2;
+        $dist=$this->linespacing;
+        $factor=$this->alpha /($apa);
+        while($x1>$this->rect->x) {
+            $aImg->Line($x0,$y0,$x1,$y1);
+            $aImg->Line($x0_right,$y0,$x1_right,$y1);
+            $x1 = $middle - $dist;
+            $x0 = $middle - $dist * $factor;
+            $x1_right = $middle + $dist;
+            $x0_right =  $middle + $dist * $factor;
+            $dist += $this->linespacing;
+        }
+
+        // Endpoint falls on sides
+        $dist -= $this->linespacing;
+        $d=$this->rect->w/2;
+        $c = $apa - $d*$apa/$dist;
+        while( $x0>$this->rect->x ) {
+            $aImg->Line($x0,$y0,$this->rect->x,$this->rect->ye-$c);
+            $aImg->Line($x0_right,$y0,$this->rect->xe,$this->rect->ye-$c);
+            $dist += $this->linespacing;
+            $x0 = $middle - $dist * $factor;
+            $x1 = $middle - $dist;
+            $x0_right =  $middle + $dist * $factor;
+            $c = $apa - $d*$apa/$dist;
+        }
+
+        // Horizontal lines
+        // They need some serious consideration since they are a function
+        // of perspective depth (alpha) and density (linespacing)
+        $x0=$this->rect->x;
+        $x1=$this->rect->xe;
+        $y=$this->rect->ye;
+
+        // The first line is drawn directly. Makes the loop below slightly
+        // more readable.
+        $aImg->Line($x0,$y,$x1,$y);
+        $hls = $this->linespacing;
+
+        // A correction factor for vertical "brick" line spacing to account for
+        // a) the difference in number of pixels hor vs vert
+        // b) visual apperance to make the first layer of "bricks" look more
+        // square.
+        $vls = $this->linespacing*0.6;
+
+        $ds = $hls*($apa-$vls)/$apa;
+        // Get the slope for the "perspective line" going from bottom right
+        // corner to top left corner of the "first" brick.
+
+        // Uncomment the following lines if you want to get a visual understanding
+        // of what this helpline does. BTW this mimics the way you would get the
+        // perspective right when drawing on paper.
+        /*
+        $x0 = $middle;
+        $y0 = $this->rect->ye;
+        $len=floor(($this->rect->ye-$this->rect->y)/$vls);
+        $x1 = $middle+round($len*$ds);
+        $y1 = $this->rect->ye-$len*$vls;
+        $aImg->PushColor("red");
+        $aImg->Line($x0,$y0,$x1,$y1);
+        $aImg->PopColor();
+        */
+
+        $y -= $vls;
+        $k=($this->rect->ye-($this->rect->ye-$vls))/($middle-($middle-$ds));
+        $dist = $hls;
+        while( $y>$this->rect->y ) {
+            $aImg->Line($this->rect->x,$y,$this->rect->xe,$y);
+            $adj = $k*$dist/(1+$dist*$k/$apa);
+            if( $adj < 2 ) $adj=1;
+            $y = $this->rect->ye - round($adj);
+            $dist += $hls;
+        }
+    }
+}
+
+//=====================================================================
+// Class RectPatternCross
+// Vert/Hor crosses
+//=====================================================================
+class RectPatternCross extends RectPattern {
+    private $vert=null;
+    private $hor=null;
+    function __construct($aColor="black",$aWeight=1) {
+        parent::__construct($aColor,$aWeight);
+        $this->vert = new RectPatternVert($aColor,$aWeight);
+        $this->hor  = new RectPatternHor($aColor,$aWeight);
+    }
+
+    function SetOrder($aDepth) {
+        $this->vert->SetOrder($aDepth);
+        $this->hor->SetOrder($aDepth);
+    }
+
+    function SetPos($aRect) {
+        parent::SetPos($aRect);
+        $this->vert->SetPos($aRect);
+        $this->hor->SetPos($aRect);
+    }
+
+    function SetDensity($aDens) {
+        $this->vert->SetDensity($aDens);
+        $this->hor->SetDensity($aDens);
+    }
+
+    function DoPattern($aImg) {
+        $this->vert->DoPattern($aImg);
+        $this->hor->DoPattern($aImg);
+    }
+}
+
+//=====================================================================
+// Class RectPatternDiagCross
+// Vert/Hor crosses
+//=====================================================================
+
+class RectPatternDiagCross extends RectPattern {
+    private $left=null;
+    private $right=null;
+    function __construct($aColor="black",$aWeight=1) {
+        parent::__construct($aColor,$aWeight);
+        $this->right = new RectPatternRDiag($aColor,$aWeight);
+        $this->left  = new RectPatternLDiag($aColor,$aWeight);
+    }
+
+    function SetOrder($aDepth) {
+        $this->left->SetOrder($aDepth);
+        $this->right->SetOrder($aDepth);
+    }
+
+    function SetPos($aRect) {
+        parent::SetPos($aRect);
+        $this->left->SetPos($aRect);
+        $this->right->SetPos($aRect);
+    }
+
+    function SetDensity($aDens) {
+        $this->left->SetDensity($aDens);
+        $this->right->SetDensity($aDens);
+    }
+
+    function DoPattern($aImg) {
+        $this->left->DoPattern($aImg);
+        $this->right->DoPattern($aImg);
+    }
+
+}
+
+//=====================================================================
+// Class RectPatternFactory
+// Factory class for rectangular pattern
+//=====================================================================
+class RectPatternFactory {
+    function __construct() {
+        // Empty
+    }
+    function Create($aPattern,$aColor,$aWeight=1) {
+        switch($aPattern) {
+            case BAND_RDIAG:
+                $obj =  new RectPatternRDiag($aColor,$aWeight);
+                break;
+            case BAND_LDIAG:
+                $obj =  new RectPatternLDiag($aColor,$aWeight);
+                break;
+            case BAND_SOLID:
+                $obj =  new RectPatternSolid($aColor,$aWeight);
+                break;
+            case BAND_VLINE:
+                $obj =  new RectPatternVert($aColor,$aWeight);
+                break;
+            case BAND_HLINE:
+                $obj =  new RectPatternHor($aColor,$aWeight);
+                break;
+            case BAND_3DPLANE:
+                $obj =  new RectPattern3DPlane($aColor,$aWeight);
+                break;
+            case BAND_HVCROSS:
+                $obj =  new RectPatternCross($aColor,$aWeight);
+                break;
+            case BAND_DIAGCROSS:
+                $obj =  new RectPatternDiagCross($aColor,$aWeight);
+                break;
+            default:
+                JpGraphError::RaiseL(16003,$aPattern);
+                //(" Unknown pattern specification ($aPattern)");
+        }
+        return $obj;
+    }
+}
+
+
+//=====================================================================
+// Class PlotBand
+// Factory class which is used by the client.
+// It is responsible for factoring the corresponding pattern
+// concrete class.
+//=====================================================================
+class PlotBand {
+    public $depth; // Determine if band should be over or under the plots
+    private $prect=null;
+    private $dir, $min, $max;
+
+    function __construct($aDir,$aPattern,$aMin,$aMax,$aColor="black",$aWeight=1,$aDepth=DEPTH_BACK) {
+        $f =  new RectPatternFactory();
+        $this->prect = $f->Create($aPattern,$aColor,$aWeight);
+        if( is_numeric($aMin) && is_numeric($aMax) && ($aMin > $aMax) )
+        JpGraphError::RaiseL(16004);
+        //('Min value for plotband is larger than specified max value. Please correct.');
+        $this->dir = $aDir;
+        $this->min = $aMin;
+        $this->max = $aMax;
+        $this->depth=$aDepth;
+    }
+
+    // Set position. aRect contains absolute image coordinates
+    function SetPos($aRect) {
+        assert( $this->prect != null ) ;
+        $this->prect->SetPos($aRect);
+    }
+
+    function ShowFrame($aFlag=true) {
+        $this->prect->ShowFrame($aFlag);
+    }
+
+    // Set z-order. In front of pplot or in the back
+    function SetOrder($aDepth) {
+        $this->depth=$aDepth;
+    }
+
+    function SetDensity($aDens) {
+        $this->prect->SetDensity($aDens);
+    }
+
+    function GetDir() {
+        return $this->dir;
+    }
+
+    function GetMin() {
+        return $this->min;
+    }
+
+    function GetMax() {
+        return $this->max;
+    }
+
+    function PreStrokeAdjust($aGraph) {
+        // Nothing to do
+    }
+
+    // Display band
+    function Stroke($aImg,$aXScale,$aYScale) {
+        assert( $this->prect != null ) ;
+        if( $this->dir == HORIZONTAL ) {
+            if( $this->min === 'min' ) $this->min = $aYScale->GetMinVal();
+            if( $this->max === 'max' ) $this->max = $aYScale->GetMaxVal();
+
+            // Only draw the bar if it actually appears in the range
+            if ($this->min < $aYScale->GetMaxVal() && $this->max > $aYScale->GetMinVal()) {
+                 
+                // Trucate to limit of axis
+                $this->min = max($this->min, $aYScale->GetMinVal());
+                $this->max = min($this->max, $aYScale->GetMaxVal());
+
+                $x=$aXScale->scale_abs[0];
+                $y=$aYScale->Translate($this->max);
+                $width=$aXScale->scale_abs[1]-$aXScale->scale_abs[0]+1;
+                $height=abs($y-$aYScale->Translate($this->min))+1;
+                $this->prect->SetPos(new Rectangle($x,$y,$width,$height));
+                $this->prect->Stroke($aImg);
+            }
+        }
+        else { // VERTICAL
+            if( $this->min === 'min' ) $this->min = $aXScale->GetMinVal();
+            if( $this->max === 'max' ) $this->max = $aXScale->GetMaxVal();
+
+            // Only draw the bar if it actually appears in the range
+            if ($this->min < $aXScale->GetMaxVal() && $this->max > $aXScale->GetMinVal()) {
+                 
+                // Trucate to limit of axis
+                $this->min = max($this->min, $aXScale->GetMinVal());
+                $this->max = min($this->max, $aXScale->GetMaxVal());
+
+                $y=$aYScale->scale_abs[1];
+                $x=$aXScale->Translate($this->min);
+                $height=abs($aYScale->scale_abs[1]-$aYScale->scale_abs[0]);
+                $width=abs($x-$aXScale->Translate($this->max));
+                $this->prect->SetPos(new Rectangle($x,$y,$width,$height));
+                $this->prect->Stroke($aImg);
+            }
+        }
+    }
+}
+
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_plotline.php b/web/classes/jpgraph/jpgraph_plotline.php
new file mode 100755
index 0000000000000000000000000000000000000000..4ee0f56484eab3a040923e773b4a5f7edfdb5918
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_plotline.php
@@ -0,0 +1,142 @@
+<?php
+/*=======================================================================
+ // File:  		 JPGRAPH_PLOTLINE.PHP
+ // Description: PlotLine extension for JpGraph
+ // Created:  	 2009-03-24
+ // Ver:  		 $Id: jpgraph_plotline.php 1931 2010-03-22 15:05:48Z ljp $
+ //
+ // CLASS PlotLine
+ // Data container class to hold properties for a static
+ // line that is drawn directly in the plot area.
+ // Useful to add static borders inside a plot to show for example set-values
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+class PlotLine {
+    public $scaleposition, $direction=-1;
+    protected $weight=1;
+    protected $color = 'black';
+    private $legend='',$hidelegend=false, $legendcsimtarget='', $legendcsimalt='',$legendcsimwintarget='';
+    private $iLineStyle='solid';
+    public $numpoints=0; // Needed since the framework expects this property
+
+    function __construct($aDir=HORIZONTAL,$aPos=0,$aColor='black',$aWeight=1) {
+        $this->direction = $aDir;
+        $this->color=$aColor;
+        $this->weight=$aWeight;
+        $this->scaleposition=$aPos;
+    }
+
+    function SetLegend($aLegend,$aCSIM='',$aCSIMAlt='',$aCSIMWinTarget='') {
+        $this->legend = $aLegend;
+        $this->legendcsimtarget = $aCSIM;
+        $this->legendcsimwintarget = $aCSIMWinTarget;
+        $this->legendcsimalt = $aCSIMAlt;
+    }
+
+    function HideLegend($f=true) {
+        $this->hidelegend = $f;
+    }
+
+    function SetPosition($aScalePosition) {
+        $this->scaleposition=$aScalePosition;
+    }
+
+    function SetDirection($aDir) {
+        $this->direction = $aDir;
+    }
+
+    function SetColor($aColor) {
+        $this->color=$aColor;
+    }
+
+    function SetWeight($aWeight) {
+        $this->weight=$aWeight;
+    }
+
+    function SetLineStyle($aStyle) {
+        $this->iLineStyle = $aStyle;
+    }
+
+    function GetCSIMAreas() {
+        return '';
+    }
+
+    //---------------
+    // PRIVATE METHODS
+
+    function DoLegend($graph) {
+        if( !$this->hidelegend ) $this->Legend($graph);
+    }
+
+    // Framework function the chance for each plot class to set a legend
+    function Legend($aGraph) {
+        if( $this->legend != '' ) {
+            $dummyPlotMark = new PlotMark();
+            $lineStyle = 1;
+            $aGraph->legend->Add($this->legend,$this->color,$dummyPlotMark,$lineStyle,
+            $this->legendcsimtarget,$this->legendcsimalt,$this->legendcsimwintarget);
+        }
+    }
+
+    function PreStrokeAdjust($aGraph) {
+        // Nothing to do
+    }
+
+    // Called by framework to allow the object to draw
+    // optional information in the margin area
+    function StrokeMargin($aImg) {
+        // Nothing to do
+    }
+
+    // Framework function to allow the object to adjust the scale
+    function PrescaleSetup($aGraph) {
+        // Nothing to do
+    }
+
+    function Min() {
+        return array(null,null);
+    }
+
+    function Max() {
+        return array(null,null);
+    }
+
+    function _Stroke($aImg,$aMinX,$aMinY,$aMaxX,$aMaxY,$aXPos,$aYPos) {
+        $aImg->SetColor($this->color);
+        $aImg->SetLineWeight($this->weight);
+        $oldStyle = $aImg->SetLineStyle($this->iLineStyle);
+        if( $this->direction == VERTICAL ) {
+            $ymin_abs = $aMinY;
+            $ymax_abs = $aMaxY;
+            $xpos_abs = $aXPos;
+            $aImg->StyleLine($xpos_abs, $ymin_abs, $xpos_abs, $ymax_abs);
+        }
+        elseif( $this->direction == HORIZONTAL ) {
+            $xmin_abs = $aMinX;
+            $xmax_abs = $aMaxX;
+            $ypos_abs = $aYPos;
+            $aImg->StyleLine($xmin_abs, $ypos_abs, $xmax_abs, $ypos_abs);
+        }
+        else {
+            JpGraphError::RaiseL(25125);//(" Illegal direction for static line");
+        }
+        $aImg->SetLineStyle($oldStyle);
+    }
+
+    function Stroke($aImg,$aXScale,$aYScale) {
+        $this->_Stroke($aImg,
+            $aImg->left_margin,
+            $aYScale->Translate($aYScale->GetMinVal()),
+            $aImg->width-$aImg->right_margin,
+            $aYScale->Translate($aYScale->GetMaxVal()),
+            $aXScale->Translate($this->scaleposition),
+            $aYScale->Translate($this->scaleposition)
+        );
+    }
+}
+
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_plotmark.inc.php b/web/classes/jpgraph/jpgraph_plotmark.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..29c4d0325ad520390524cd7b3f8e6d63b2f57b50
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_plotmark.inc.php
@@ -0,0 +1,504 @@
+<?php
+//=======================================================================
+// File:        JPGRAPH_PLOTMARK.PHP
+// Description: Class file. Handles plotmarks
+// Created:     2003-03-21
+// Ver:         $Id: jpgraph_plotmark.inc.php 1106 2009-02-22 20:16:35Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+
+//===================================================
+// CLASS PlotMark
+// Description: Handles the plot marks in graphs
+//===================================================
+
+class PlotMark {
+    public $title, $show=true;
+    public $type,$weight=1;
+    public $iFormatCallback="", $iFormatCallback2="";
+    public $fill_color="blue";
+    public $color="black", $width=4;
+    private $yvalue,$xvalue='',$csimtarget,$csimwintarget='',$csimalt,$csimareas;
+    private $markimg='',$iScale=1.0;
+    private $oldfilename='',$iFileName='';
+    private $imgdata_balls = null;
+    private $imgdata_diamonds = null;
+    private $imgdata_squares = null;
+    private $imgdata_bevels = null;
+    private $imgdata_stars = null;
+    private $imgdata_pushpins = null;
+
+    //--------------
+    // CONSTRUCTOR
+    function __construct() {
+        $this->title = new Text();
+        $this->title->Hide();
+        $this->csimareas = '';
+        $this->type=-1;
+    }
+    //---------------
+    // PUBLIC METHODS
+    function SetType($aType,$aFileName='',$aScale=1.0) {
+        $this->type = $aType;
+        if( $aType == MARK_IMG && $aFileName=='' ) {
+            JpGraphError::RaiseL(23003);//('A filename must be specified if you set the mark type to MARK_IMG.');
+        }
+        $this->iFileName = $aFileName;
+        $this->iScale = $aScale;
+    }
+
+    function SetCallback($aFunc) {
+        $this->iFormatCallback = $aFunc;
+    }
+
+    function SetCallbackYX($aFunc) {
+        $this->iFormatCallback2 = $aFunc;
+    }
+
+    function GetType() {
+        return $this->type;
+    }
+
+    function SetColor($aColor) {
+        $this->color=$aColor;
+    }
+
+    function SetFillColor($aFillColor) {
+        $this->fill_color = $aFillColor;
+    }
+
+    function SetWeight($aWeight) {
+        $this->weight = $aWeight;
+    }
+
+    // Synonym for SetWidth()
+    function SetSize($aWidth) {
+        $this->width=$aWidth;
+    }
+
+    function SetWidth($aWidth) {
+        $this->width=$aWidth;
+    }
+
+    function SetDefaultWidth() {
+        switch( $this->type ) {
+            case MARK_CIRCLE:
+            case MARK_FILLEDCIRCLE:
+                $this->width=4;
+                break;
+            default:
+                $this->width=7;
+        }
+    }
+
+    function GetWidth() {
+        return $this->width;
+    }
+
+    function Hide($aHide=true) {
+        $this->show = !$aHide;
+    }
+
+    function Show($aShow=true) {
+        $this->show = $aShow;
+    }
+
+    function SetCSIMAltVal($aY,$aX='') {
+        $this->yvalue=$aY;
+        $this->xvalue=$aX;
+    }
+
+    function SetCSIMTarget($aTarget,$aWinTarget='') {
+        $this->csimtarget=$aTarget;
+        $this->csimwintarget=$aWinTarget;
+    }
+
+    function SetCSIMAlt($aAlt) {
+        $this->csimalt=$aAlt;
+    }
+
+    function GetCSIMAreas(){
+        return $this->csimareas;
+    }
+
+    function AddCSIMPoly($aPts) {
+        $coords = round($aPts[0]).", ".round($aPts[1]);
+        $n = count($aPts)/2;
+        for( $i=1; $i < $n; ++$i){
+            $coords .= ", ".round($aPts[2*$i]).", ".round($aPts[2*$i+1]);
+        }
+        $this->csimareas="";
+        if( !empty($this->csimtarget) ) {
+            $this->csimareas .= "<area shape=\"poly\" coords=\"$coords\" href=\"".htmlentities($this->csimtarget)."\"";
+
+            if( !empty($this->csimwintarget) ) {
+                $this->csimareas .= " target=\"".$this->csimwintarget."\" ";
+            }
+
+            if( !empty($this->csimalt) ) {
+                $tmp=sprintf($this->csimalt,$this->yvalue,$this->xvalue);
+                $this->csimareas .= " title=\"$tmp\" alt=\"$tmp\"";
+            }
+            $this->csimareas .= " />\n";
+        }
+    }
+
+    function AddCSIMCircle($x,$y,$r) {
+        $x = round($x); $y=round($y); $r=round($r);
+        $this->csimareas="";
+        if( !empty($this->csimtarget) ) {
+            $this->csimareas .= "<area shape=\"circle\" coords=\"$x,$y,$r\" href=\"".htmlentities($this->csimtarget)."\"";
+
+            if( !empty($this->csimwintarget) ) {
+                $this->csimareas .= " target=\"".$this->csimwintarget."\" ";
+            }
+
+            if( !empty($this->csimalt) ) {
+                $tmp=sprintf($this->csimalt,$this->yvalue,$this->xvalue);
+                $this->csimareas .= " title=\"$tmp\" alt=\"$tmp\" ";
+            }
+            $this->csimareas .= " />\n";
+        }
+    }
+     
+    function Stroke($img,$x,$y) {
+        if( !$this->show ) return;
+
+        if( $this->iFormatCallback != '' || $this->iFormatCallback2 != '' ) {
+
+            if( $this->iFormatCallback != '' ) {
+                $f = $this->iFormatCallback;
+                list($width,$color,$fcolor) = call_user_func($f,$this->yvalue);
+                $filename = $this->iFileName;
+                $imgscale = $this->iScale;
+            }
+            else {
+                $f = $this->iFormatCallback2;
+                list($width,$color,$fcolor,$filename,$imgscale) = call_user_func($f,$this->yvalue,$this->xvalue);
+                if( $filename=="" ) $filename = $this->iFileName;
+                if( $imgscale=="" ) $imgscale = $this->iScale;
+            }
+
+            if( $width=="" ) $width = $this->width;
+            if( $color=="" ) $color = $this->color;
+            if( $fcolor=="" ) $fcolor = $this->fill_color;
+
+        }
+        else {
+            $fcolor = $this->fill_color;
+            $color = $this->color;
+            $width = $this->width;
+            $filename = $this->iFileName;
+            $imgscale = $this->iScale;
+        }
+
+        if( $this->type == MARK_IMG ||
+        ($this->type >= MARK_FLAG1 && $this->type <= MARK_FLAG4 ) ||
+        $this->type >= MARK_IMG_PUSHPIN ) {
+
+            // Note: For the builtin images we use the "filename" parameter
+            // to denote the color
+            $anchor_x = 0.5;
+            $anchor_y = 0.5;
+            switch( $this->type ) {
+                case MARK_FLAG1:
+                case MARK_FLAG2:
+                case MARK_FLAG3:
+                case MARK_FLAG4:
+                    $this->markimg = FlagCache::GetFlagImgByName($this->type-MARK_FLAG1+1,$filename);
+                    break;
+
+                case MARK_IMG :
+                    // Load an image and use that as a marker
+                    // Small optimization, if we have already read an image don't
+                    // waste time reading it again.
+                    if( $this->markimg == '' || !($this->oldfilename === $filename) ) {
+                        $this->markimg = Graph::LoadBkgImage('',$filename);
+                        $this->oldfilename = $filename ;
+                    }
+                    break;
+
+                case MARK_IMG_PUSHPIN:
+                case MARK_IMG_SPUSHPIN:
+                case MARK_IMG_LPUSHPIN:
+                    if( $this->imgdata_pushpins == null ) {
+                        require_once 'imgdata_pushpins.inc.php';
+                        $this->imgdata_pushpins = new ImgData_PushPins();
+                    }
+                    $this->markimg = $this->imgdata_pushpins->GetImg($this->type,$filename);
+                    list($anchor_x,$anchor_y) = $this->imgdata_pushpins->GetAnchor();
+                    break;
+
+                case MARK_IMG_SQUARE:
+                    if( $this->imgdata_squares == null ) {
+                        require_once 'imgdata_squares.inc.php';
+                        $this->imgdata_squares = new ImgData_Squares();
+                    }
+                    $this->markimg = $this->imgdata_squares->GetImg($this->type,$filename);
+                    list($anchor_x,$anchor_y) = $this->imgdata_squares->GetAnchor();
+                    break;
+
+                case MARK_IMG_STAR:
+                    if( $this->imgdata_stars == null ) {
+                        require_once 'imgdata_stars.inc.php';
+                        $this->imgdata_stars = new ImgData_Stars();
+                    }
+                    $this->markimg = $this->imgdata_stars->GetImg($this->type,$filename);
+                    list($anchor_x,$anchor_y) = $this->imgdata_stars->GetAnchor();
+                    break;
+
+                case MARK_IMG_BEVEL:
+                    if( $this->imgdata_bevels == null ) {
+                        require_once 'imgdata_bevels.inc.php';
+                        $this->imgdata_bevels = new ImgData_Bevels();
+                    }
+                    $this->markimg = $this->imgdata_bevels->GetImg($this->type,$filename);
+                    list($anchor_x,$anchor_y) = $this->imgdata_bevels->GetAnchor();
+                    break;
+
+                case MARK_IMG_DIAMOND:
+                    if( $this->imgdata_diamonds == null ) {
+                        require_once 'imgdata_diamonds.inc.php';
+                        $this->imgdata_diamonds = new ImgData_Diamonds();
+                    }
+                    $this->markimg = $this->imgdata_diamonds->GetImg($this->type,$filename);
+                    list($anchor_x,$anchor_y) = $this->imgdata_diamonds->GetAnchor();
+                    break;
+
+                case MARK_IMG_BALL:
+                case MARK_IMG_SBALL:
+                case MARK_IMG_MBALL:
+                case MARK_IMG_LBALL:
+                    if( $this->imgdata_balls == null ) {
+                        require_once 'imgdata_balls.inc.php';
+                        $this->imgdata_balls = new ImgData_Balls();
+                    }
+                    $this->markimg = $this->imgdata_balls->GetImg($this->type,$filename);
+                    list($anchor_x,$anchor_y) = $this->imgdata_balls->GetAnchor();
+                    break;
+            }
+
+            $w = $img->GetWidth($this->markimg);
+            $h = $img->GetHeight($this->markimg);
+             
+            $dw = round($imgscale * $w );
+            $dh = round($imgscale * $h );
+
+            // Do potential rotation
+            list($x,$y) = $img->Rotate($x,$y);
+
+            $dx = round($x-$dw*$anchor_x);
+            $dy = round($y-$dh*$anchor_y);
+             
+            $this->width = max($dx,$dy);
+             
+            $img->Copy($this->markimg,$dx,$dy,0,0,$dw,$dh,$w,$h);
+            if( !empty($this->csimtarget) ) {
+                $this->csimareas = "<area shape=\"rect\" coords=\"".
+                $dx.','.$dy.','.round($dx+$dw).','.round($dy+$dh).'" '.
+      "href=\"".htmlentities($this->csimtarget)."\"";
+
+                if( !empty($this->csimwintarget) ) {
+                    $this->csimareas .= " target=\"".$this->csimwintarget."\" ";
+                }
+
+                if( !empty($this->csimalt) ) {
+                    $tmp=sprintf($this->csimalt,$this->yvalue,$this->xvalue);
+                    $this->csimareas .= " title=\"$tmp\" alt=\"$tmp\" ";
+                }
+                $this->csimareas .= " />\n";
+            }
+             
+            // Stroke title
+            $this->title->Align("center","top");
+            $this->title->Stroke($img,$x,$y+round($dh/2));
+            return;
+        }
+
+        $weight = $this->weight;
+        $dx=round($width/2,0);
+        $dy=round($width/2,0);
+        $pts=0;
+
+        switch( $this->type ) {
+            case MARK_SQUARE:
+                $c[]=$x-$dx;$c[]=$y-$dy;
+                $c[]=$x+$dx;$c[]=$y-$dy;
+                $c[]=$x+$dx;$c[]=$y+$dy;
+                $c[]=$x-$dx;$c[]=$y+$dy;
+                $c[]=$x-$dx;$c[]=$y-$dy;
+                $pts=5;
+                break;
+            case MARK_UTRIANGLE:
+                ++$dx;++$dy;
+                $c[]=$x-$dx;$c[]=$y+0.87*$dy; // tan(60)/2*$dx
+                $c[]=$x;$c[]=$y-0.87*$dy;
+                $c[]=$x+$dx;$c[]=$y+0.87*$dy;
+                $c[]=$x-$dx;$c[]=$y+0.87*$dy; // tan(60)/2*$dx
+                $pts=4;
+                break;
+            case MARK_DTRIANGLE:
+                ++$dx;++$dy;
+                $c[]=$x;$c[]=$y+0.87*$dy; // tan(60)/2*$dx
+                $c[]=$x-$dx;$c[]=$y-0.87*$dy;
+                $c[]=$x+$dx;$c[]=$y-0.87*$dy;
+                $c[]=$x;$c[]=$y+0.87*$dy; // tan(60)/2*$dx
+                $pts=4;
+                break;
+            case MARK_DIAMOND:
+                $c[]=$x;$c[]=$y+$dy;
+                $c[]=$x-$dx;$c[]=$y;
+                $c[]=$x;$c[]=$y-$dy;
+                $c[]=$x+$dx;$c[]=$y;
+                $c[]=$x;$c[]=$y+$dy;
+                $pts=5;
+                break;
+            case MARK_LEFTTRIANGLE:
+                $c[]=$x;$c[]=$y;
+                $c[]=$x;$c[]=$y+2*$dy;
+                $c[]=$x+$dx*2;$c[]=$y;
+                $c[]=$x;$c[]=$y;
+                $pts=4;
+                break;
+            case MARK_RIGHTTRIANGLE:
+                $c[]=$x-$dx*2;$c[]=$y;
+                $c[]=$x;$c[]=$y+2*$dy;
+                $c[]=$x;$c[]=$y;
+                $c[]=$x-$dx*2;$c[]=$y;
+                $pts=4;
+                break;
+            case MARK_FLASH:
+                $dy *= 2;
+                $c[]=$x+$dx/2; $c[]=$y-$dy;
+                $c[]=$x-$dx+$dx/2; $c[]=$y+$dy*0.7-$dy;
+                $c[]=$x+$dx/2; $c[]=$y+$dy*1.3-$dy;
+                $c[]=$x-$dx+$dx/2; $c[]=$y+2*$dy-$dy;
+                $img->SetLineWeight($weight);
+                $img->SetColor($color);
+                $img->Polygon($c);
+                $img->SetLineWeight(1);
+                $this->AddCSIMPoly($c);
+                break;
+        }
+
+        if( $pts>0 ) {
+            $this->AddCSIMPoly($c);
+            $img->SetLineWeight($weight);
+            $img->SetColor($fcolor);
+            $img->FilledPolygon($c);
+            $img->SetColor($color);
+            $img->Polygon($c);
+            $img->SetLineWeight(1);
+        }
+        elseif( $this->type==MARK_CIRCLE ) {
+            $img->SetColor($color);
+            $img->Circle($x,$y,$width);
+            $this->AddCSIMCircle($x,$y,$width);
+        }
+        elseif( $this->type==MARK_FILLEDCIRCLE ) {
+            $img->SetColor($fcolor);
+            $img->FilledCircle($x,$y,$width);
+            $img->SetColor($color);
+            $img->Circle($x,$y,$width);
+            $this->AddCSIMCircle($x,$y,$width);
+        }
+        elseif( $this->type==MARK_CROSS ) {
+            // Oversize by a pixel to match the X
+            $img->SetColor($color);
+            $img->SetLineWeight($weight);
+            $img->Line($x,$y+$dy+1,$x,$y-$dy-1);
+            $img->Line($x-$dx-1,$y,$x+$dx+1,$y);
+            $this->AddCSIMCircle($x,$y,$dx);
+        }
+        elseif( $this->type==MARK_X ) {
+            $img->SetColor($color);
+            $img->SetLineWeight($weight);
+            $img->Line($x+$dx,$y+$dy,$x-$dx,$y-$dy);
+            $img->Line($x-$dx,$y+$dy,$x+$dx,$y-$dy);
+            $this->AddCSIMCircle($x,$y,$dx+$dy);
+        }
+        elseif( $this->type==MARK_STAR ) {
+            $img->SetColor($color);
+            $img->SetLineWeight($weight);
+            $img->Line($x+$dx,$y+$dy,$x-$dx,$y-$dy);
+            $img->Line($x-$dx,$y+$dy,$x+$dx,$y-$dy);
+            // Oversize by a pixel to match the X
+            $img->Line($x,$y+$dy+1,$x,$y-$dy-1);
+            $img->Line($x-$dx-1,$y,$x+$dx+1,$y);
+            $this->AddCSIMCircle($x,$y,$dx+$dy);
+        }
+
+        // Stroke title
+        $this->title->Align("center","center");
+        $this->title->Stroke($img,$x,$y);
+    }
+} // Class
+
+
+
+//========================================================================
+// CLASS ImgData
+// Description: Base class for all image data classes that contains the
+// real image data.
+//========================================================================
+class ImgData {
+    protected $name = '';  // Each subclass gives a name
+    protected $an = array();  // Data array names
+    protected $colors = array(); // Available colors
+    protected $index  = array(); // Index for colors
+    protected $maxidx = 0 ;  // Max color index
+    protected $anchor_x=0.5, $anchor_y=0.5 ;    // Where is the center of the image
+    
+    function __construct() {
+        // Empty
+    }
+    
+    // Create a GD image from the data and return a GD handle
+    function GetImg($aMark,$aIdx) {
+        $n = $this->an[$aMark];
+        if( is_string($aIdx) ) {
+            if( !in_array($aIdx,$this->colors) ) {
+                JpGraphError::RaiseL(23001,$this->name,$aIdx);//('This marker "'.($this->name).'" does not exist in color: '.$aIdx);
+            }
+            $idx = $this->index[$aIdx];
+        }
+        elseif( !is_integer($aIdx) ||
+        (is_integer($aIdx) && $aIdx > $this->maxidx ) ) {
+            JpGraphError::RaiseL(23002,$this->name);//('Mark color index too large for marker "'.($this->name).'"');
+        }
+        else
+        $idx = $aIdx ;
+        return Image::CreateFromString(base64_decode($this->{$n}[$idx][1]));
+    }
+    
+    function GetAnchor() {
+        return array($this->anchor_x,$this->anchor_y);
+    }
+}
+
+
+// Keep a global flag cache to reduce memory usage
+$_gFlagCache=array(
+1 => null,
+2 => null,
+3 => null,
+4 => null,
+);
+// Only supposed to b called as statics
+class FlagCache {
+    
+    static function GetFlagImgByName($aSize,$aName) {
+        global $_gFlagCache;
+        require_once('jpgraph_flags.php');
+        if( $_gFlagCache[$aSize] === null ) {
+            $_gFlagCache[$aSize] = new FlagImages($aSize);
+        }
+        $f = $_gFlagCache[$aSize];
+        $idx = $f->GetIdxByName($aName,$aFullName);
+        return $f->GetImgByIdx($idx);
+    }
+}
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_polar.php b/web/classes/jpgraph/jpgraph_polar.php
new file mode 100755
index 0000000000000000000000000000000000000000..62c6bbc86fec994c64fc5314853ef2f31a4dc1c4
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_polar.php
@@ -0,0 +1,897 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_POLAR.PHP
+ // Description: Polar plot extension for JpGraph
+ // Created:     2003-02-02
+ // Ver:         $Id: jpgraph_polar.php 1796 2009-09-07 09:37:19Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+require_once ('jpgraph_plotmark.inc.php');
+require_once "jpgraph_log.php";
+
+
+define('POLAR_360',1);
+define('POLAR_180',2);
+
+//
+// Note. Don't attempt to make sense of this code.
+// In order not to have to be able to inherit the scaling code
+// from the main graph package we have had to make some "tricks" since
+// the original scaling and axis was not designed to do what is
+// required here.
+// There were two option. 1: Re-implement everything and get a clean design
+// and 2: do some "small" trickery and be able to inherit most of
+// the functionlity from the main graph package.
+// We choose 2: here in order to save some time.
+//
+
+//--------------------------------------------------------------------------
+// class PolarPlot
+//--------------------------------------------------------------------------
+class PolarPlot {
+    public $line_style='solid',$mark;
+    public $legendcsimtarget='';
+    public $legendcsimalt='';
+    public $legend="";
+    public $csimtargets=array(); // Array of targets for CSIM
+    public $csimareas="";   // Resultant CSIM area tags
+    public $csimalts=null;   // ALT:s for corresponding target
+    public $scale=null;
+    private $numpoints=0;
+    private $iColor='navy',$iFillColor='';
+    private $iLineWeight=1;
+    private $coord=null;
+
+    function __construct($aData) {
+        $n = count($aData);
+        if( $n & 1 ) {
+            JpGraphError::RaiseL(17001);
+            //('Polar plots must have an even number of data point. Each data point is a tuple (angle,radius).');
+        }
+        $this->numpoints = $n/2;
+        $this->coord = $aData;
+        $this->mark = new PlotMark();
+    }
+
+    function SetWeight($aWeight) {
+        $this->iLineWeight = $aWeight;
+    }
+
+    function SetColor($aColor){
+        $this->iColor = $aColor;
+    }
+
+    function SetFillColor($aColor){
+        $this->iFillColor = $aColor;
+    }
+
+    function Max() {
+        $m = $this->coord[1];
+        $i=1;
+        while( $i < $this->numpoints ) {
+            $m = max($m,$this->coord[2*$i+1]);
+            ++$i;
+        }
+        return $m;
+    }
+    // Set href targets for CSIM
+    function SetCSIMTargets($aTargets,$aAlts=null) {
+        $this->csimtargets=$aTargets;
+        $this->csimalts=$aAlts;
+    }
+
+    // Get all created areas
+    function GetCSIMareas() {
+        return $this->csimareas;
+    }
+
+    function SetLegend($aLegend,$aCSIM="",$aCSIMAlt="") {
+        $this->legend = $aLegend;
+        $this->legendcsimtarget = $aCSIM;
+        $this->legendcsimalt = $aCSIMAlt;
+    }
+
+    // Private methods
+
+    function Legend($aGraph) {
+        $color = $this->iColor ;
+        if( $this->legend != "" ) {
+            if( $this->iFillColor!='' ) {
+                $color = $this->iFillColor;
+                $aGraph->legend->Add($this->legend,$color,$this->mark,0,
+                $this->legendcsimtarget,$this->legendcsimalt);
+            }
+            else {
+                $aGraph->legend->Add($this->legend,$color,$this->mark,$this->line_style,
+                $this->legendcsimtarget,$this->legendcsimalt);
+            }
+        }
+    }
+
+    function Stroke($img,$scale) {
+
+        $i=0;
+        $p=array();
+        $this->csimareas='';
+        while($i < $this->numpoints) {
+            list($x1,$y1) = $scale->PTranslate($this->coord[2*$i],$this->coord[2*$i+1]);
+            $p[2*$i] = $x1;
+            $p[2*$i+1] = $y1;
+
+            if( isset($this->csimtargets[$i]) ) {
+                $this->mark->SetCSIMTarget($this->csimtargets[$i]);
+                $this->mark->SetCSIMAlt($this->csimalts[$i]);
+                $this->mark->SetCSIMAltVal($this->coord[2*$i], $this->coord[2*$i+1]);
+                $this->mark->Stroke($img,$x1,$y1);
+                $this->csimareas .= $this->mark->GetCSIMAreas();
+            }
+            else {
+            	$this->mark->Stroke($img,$x1,$y1);
+            }
+
+            ++$i;
+        }
+
+        if( $this->iFillColor != '' ) {
+            $img->SetColor($this->iFillColor);
+            $img->FilledPolygon($p);
+        }
+        $img->SetLineWeight($this->iLineWeight);
+        $img->SetColor($this->iColor);
+        $img->Polygon($p,$this->iFillColor!='');
+    }
+}
+
+//--------------------------------------------------------------------------
+// class PolarAxis
+//--------------------------------------------------------------------------
+class PolarAxis extends Axis {
+    private $angle_step=15,$angle_color='lightgray',$angle_label_color='black';
+    private $angle_fontfam=FF_FONT1,$angle_fontstyle=FS_NORMAL,$angle_fontsize=10;
+    private $angle_fontcolor = 'navy';
+    private $gridminor_color='lightgray',$gridmajor_color='lightgray';
+    private $show_minor_grid = false, $show_major_grid = true ;
+    private $show_angle_mark=true, $show_angle_grid=true, $show_angle_label=true;
+    private $angle_tick_len=3, $angle_tick_len2=3, $angle_tick_color='black';
+    private $show_angle_tick=true;
+    private $radius_tick_color='black';
+
+    function __construct($img,$aScale) {
+        parent::__construct($img,$aScale);
+    }
+
+    function ShowAngleDegreeMark($aFlg=true) {
+        $this->show_angle_mark = $aFlg;
+    }
+
+    function SetAngleStep($aStep) {
+        $this->angle_step=$aStep;
+    }
+
+    function HideTicks($aFlg=true,$aAngleFlg=true) {
+        parent::HideTicks($aFlg,$aFlg);
+        $this->show_angle_tick = !$aAngleFlg;
+    }
+
+    function ShowAngleLabel($aFlg=true) {
+        $this->show_angle_label = $aFlg;
+    }
+
+    function ShowGrid($aMajor=true,$aMinor=false,$aAngle=true) {
+        $this->show_minor_grid = $aMinor;
+        $this->show_major_grid = $aMajor;
+        $this->show_angle_grid = $aAngle ;
+    }
+
+    function SetAngleFont($aFontFam,$aFontStyle=FS_NORMAL,$aFontSize=10) {
+        $this->angle_fontfam = $aFontFam;
+        $this->angle_fontstyle = $aFontStyle;
+        $this->angle_fontsize = $aFontSize;
+    }
+
+    function SetColor($aColor,$aRadColor='',$aAngleColor='') {
+        if( $aAngleColor == '' )
+        $aAngleColor=$aColor;
+        parent::SetColor($aColor,$aRadColor);
+        $this->angle_fontcolor = $aAngleColor;
+    }
+
+    function SetGridColor($aMajorColor,$aMinorColor='',$aAngleColor='') {
+        if( $aMinorColor == '' )
+        $aMinorColor = $aMajorColor;
+        if( $aAngleColor == '' )
+        $aAngleColor = $aMajorColor;
+
+        $this->gridminor_color = $aMinorColor;
+        $this->gridmajor_color = $aMajorColor;
+        $this->angle_color = $aAngleColor;
+    }
+
+    function SetTickColors($aRadColor,$aAngleColor='') {
+        $this->radius_tick_color = $aRadColor;
+        $this->angle_tick_color = $aAngleColor;
+    }
+
+    // Private methods
+    function StrokeGrid($pos) {
+        $x = round($this->img->left_margin + $this->img->plotwidth/2);
+        $this->scale->ticks->Stroke($this->img,$this->scale,$pos);
+
+        // Stroke the minor arcs
+        $pmin = array();
+        $p = $this->scale->ticks->ticks_pos;
+        $n = count($p);
+        $i = 0;
+        $this->img->SetColor($this->gridminor_color);
+        while( $i < $n ) {
+            $r = $p[$i]-$x+1;
+            $pmin[]=$r;
+            if( $this->show_minor_grid ) {
+                $this->img->Circle($x,$pos,$r);
+            }
+            $i++;
+        }
+
+        $limit = max($this->img->plotwidth,$this->img->plotheight)*1.4 ;
+        while( $r < $limit ) {
+            $off = $r;
+            $i=1;
+            $r = $off + round($p[$i]-$x+1);
+            while( $r < $limit && $i < $n ) {
+                $r = $off+$p[$i]-$x;
+                $pmin[]=$r;
+                if( $this->show_minor_grid ) {
+                    $this->img->Circle($x,$pos,$r);
+                }
+                $i++;
+            }
+        }
+
+        // Stroke the major arcs
+        if( $this->show_major_grid ) {
+            // First determine how many minor step on
+            // every major step. We have recorded the minor radius
+            // in pmin and use these values. This is done in order
+            // to avoid rounding errors if we were to recalculate the
+            // different major radius.
+            $pmaj = $this->scale->ticks->maj_ticks_pos;
+            $p = $this->scale->ticks->ticks_pos;
+            if( $this->scale->name == 'lin' ) {
+                $step=round(($pmaj[1] - $pmaj[0])/($p[1] - $p[0]));
+            }
+            else {
+                $step=9;
+            }
+            $n = round(count($pmin)/$step);
+            $i = 0;
+            $this->img->SetColor($this->gridmajor_color);
+            $limit = max($this->img->plotwidth,$this->img->plotheight)*1.4 ;
+            $off = $r;
+            $i=0;
+            $r = $pmin[$i*$step];
+            while( $r < $limit && $i < $n ) {
+                $r = $pmin[$i*$step];
+                $this->img->Circle($x,$pos,$r);
+                $i++;
+            }
+        }
+
+        // Draw angles
+        if( $this->show_angle_grid ) {
+            $this->img->SetColor($this->angle_color);
+            $d = max($this->img->plotheight,$this->img->plotwidth)*1.4 ;
+            $a = 0;
+            $p = $this->scale->ticks->ticks_pos;
+            $start_radius = $p[1]-$x;
+            while( $a < 360 ) {
+                if( $a == 90 || $a == 270 ) {
+                    // Make sure there are no rounding problem with
+                    // exactly vertical lines
+                    $this->img->Line($x+$start_radius*cos($a/180*M_PI)+1,
+                                     $pos-$start_radius*sin($a/180*M_PI),
+                                     $x+$start_radius*cos($a/180*M_PI)+1,
+                                     $pos-$d*sin($a/180*M_PI));
+
+                }
+                else {
+                    $this->img->Line($x+$start_radius*cos($a/180*M_PI)+1,
+                                     $pos-$start_radius*sin($a/180*M_PI),
+                                     $x+$d*cos($a/180*M_PI),
+                                     $pos-$d*sin($a/180*M_PI));
+                }
+                $a += $this->angle_step;
+            }
+        }
+    }
+
+    function StrokeAngleLabels($pos,$type) {
+
+        if( !$this->show_angle_label )
+            return;
+
+        $x0 = round($this->img->left_margin+$this->img->plotwidth/2)+1;
+
+        $d = max($this->img->plotwidth,$this->img->plotheight)*1.42;
+        $a = $this->angle_step;
+        $t = new Text();
+        $t->SetColor($this->angle_fontcolor);
+        $t->SetFont($this->angle_fontfam,$this->angle_fontstyle,$this->angle_fontsize);
+        $xright = $this->img->width - $this->img->right_margin;
+        $ytop = $this->img->top_margin;
+        $xleft = $this->img->left_margin;
+        $ybottom = $this->img->height - $this->img->bottom_margin;
+        $ha = 'left';
+        $va = 'center';
+        $w = $this->img->plotwidth/2;
+        $h = $this->img->plotheight/2;
+        $xt = $x0; $yt = $pos;
+        $margin=5;
+
+        $tl  = $this->angle_tick_len ; // Outer len
+        $tl2 = $this->angle_tick_len2 ; // Interior len
+
+        $this->img->SetColor($this->angle_tick_color);
+        $rot90 = $this->img->a == 90 ;
+
+        if( $type == POLAR_360 ) {
+
+            // Corner angles of the four corners
+            $ca1 = atan($h/$w)/M_PI*180;
+            $ca2 = 180-$ca1;
+            $ca3 = $ca1+180;
+            $ca4 = 360-$ca1;
+            $end = 360;
+
+            while( $a < $end ) {
+                $ca = cos($a/180*M_PI);
+                $sa = sin($a/180*M_PI);
+                $x = $d*$ca;
+                $y = $d*$sa;
+                $xt=1000;$yt=1000;
+                if( $a <= $ca1 || $a >= $ca4 ) {
+                    $yt = $pos - $w * $y/$x;
+                    $xt = $xright + $margin;
+                    if( $rot90 ) {
+                        $ha = 'center';
+                        $va = 'top';
+                    }
+                    else {
+                        $ha = 'left';
+                        $va = 'center';
+                    }
+                    $x1=$xright-$tl2; $x2=$xright+$tl;
+                    $y1=$y2=$yt;
+                }
+                elseif( $a > $ca1 && $a < $ca2 ) {
+                    $xt = $x0 + $h * $x/$y;
+                    $yt = $ytop - $margin;
+                    if( $rot90 ) {
+                        $ha = 'left';
+                        $va = 'center';
+                    }
+                    else {
+                        $ha = 'center';
+                        $va = 'bottom';
+                    }
+                    $y1=$ytop+$tl2;$y2=$ytop-$tl;
+                    $x1=$x2=$xt;
+                }
+                elseif( $a >= $ca2 && $a <= $ca3 ) {
+                    $yt = $pos + $w * $y/$x;
+                    $xt = $xleft - $margin;
+                    if( $rot90 ) {
+                        $ha = 'center';
+                        $va = 'bottom';
+                    }
+                    else {
+                        $ha = 'right';
+                        $va = 'center';
+                    }
+                    $x1=$xleft+$tl2;$x2=$xleft-$tl;
+                    $y1=$y2=$yt;
+                }
+                else {
+                    $xt = $x0 - $h * $x/$y;
+                    $yt = $ybottom + $margin;
+                    if( $rot90 ) {
+                        $ha = 'right';
+                        $va = 'center';
+                    }
+                    else {
+                        $ha = 'center';
+                        $va = 'top';
+                    }
+                    $y1=$ybottom-$tl2;$y2=$ybottom+$tl;
+                    $x1=$x2=$xt;
+                }
+                if( $a != 0 && $a != 180 ) {
+                    $t->Align($ha,$va);
+                    if( $this->scale->clockwise ) {
+                        $t->Set(360-$a);
+                    }
+                    else {
+                        $t->Set($a);
+                    }
+                    if( $this->show_angle_mark && $t->font_family > 4 ) {
+                        $a .= SymChar::Get('degree');
+                    }
+                    $t->Stroke($this->img,$xt,$yt);
+                    if( $this->show_angle_tick ) {
+                        $this->img->Line($x1,$y1,$x2,$y2);
+                    }
+                }
+                $a += $this->angle_step;
+            }
+        }
+        else {
+            // POLAR_HALF
+            $ca1 = atan($h/$w*2)/M_PI*180;
+            $ca2 = 180-$ca1;
+            $end = 180;
+            while( $a < $end ) {
+                $ca = cos($a/180*M_PI);
+                $sa = sin($a/180*M_PI);
+                $x = $d*$ca;
+                $y = $d*$sa;
+                if( $a <= $ca1 ) {
+                    $yt = $pos - $w * $y/$x;
+                    $xt = $xright + $margin;
+                    if( $rot90 ) {
+                        $ha = 'center';
+                        $va = 'top';
+                    }
+                    else {
+                        $ha = 'left';
+                        $va = 'center';
+                    }
+                    $x1=$xright-$tl2; $x2=$xright+$tl;
+                    $y1=$y2=$yt;
+                }
+                elseif( $a > $ca1 && $a < $ca2 ) {
+                    $xt = $x0 + 2*$h * $x/$y;
+                    $yt = $ytop - $margin;
+                    if( $rot90 ) {
+                        $ha = 'left';
+                        $va = 'center';
+                    }
+                    else {
+                        $ha = 'center';
+                        $va = 'bottom';
+                    }
+                    $y1=$ytop+$tl2;$y2=$ytop-$tl;
+                    $x1=$x2=$xt;
+                }
+                elseif( $a >= $ca2 ) {
+                    $yt = $pos + $w * $y/$x;
+                    $xt = $xleft - $margin;
+                    if( $rot90 ) {
+                        $ha = 'center';
+                        $va = 'bottom';
+                    }
+                    else {
+                        $ha = 'right';
+                        $va = 'center';
+                    }
+                    $x1=$xleft+$tl2;$x2=$xleft-$tl;
+                    $y1=$y2=$yt;
+                }
+                $t->Align($ha,$va);
+                if( $this->show_angle_mark && $t->font_family > 4 ) {
+                	$a .= SymChar::Get('degree');
+                }
+                $t->Set($a);
+                $t->Stroke($this->img,$xt,$yt);
+                if( $this->show_angle_tick ) {
+                    $this->img->Line($x1,$y1,$x2,$y2);
+                }
+                $a += $this->angle_step;
+            }
+        }
+    }
+
+    function Stroke($pos,$dummy=true) {
+
+        $this->img->SetLineWeight($this->weight);
+        $this->img->SetColor($this->color);
+        $this->img->SetFont($this->font_family,$this->font_style,$this->font_size);
+        if( !$this->hide_line ) {
+            $this->img->FilledRectangle($this->img->left_margin,$pos,
+                                        $this->img->width-$this->img->right_margin,
+                                        $pos+$this->weight-1);
+        }
+        $y=$pos+$this->img->GetFontHeight()+$this->title_margin+$this->title->margin;
+        if( $this->title_adjust=="high" ) {
+            $this->title->SetPos($this->img->width-$this->img->right_margin,$y,"right","top");
+        }
+        elseif( $this->title_adjust=="middle" || $this->title_adjust=="center" ) {
+            $this->title->SetPos(($this->img->width-$this->img->left_margin-$this->img->right_margin)/2+$this->img->left_margin,
+                                $y,"center","top");
+        }
+        elseif($this->title_adjust=="low") {
+            $this->title->SetPos($this->img->left_margin,$y,"left","top");
+        }
+        else {
+            JpGraphError::RaiseL(17002,$this->title_adjust);
+            //('Unknown alignment specified for X-axis title. ('.$this->title_adjust.')');
+        }
+
+
+        if (!$this->hide_labels) {
+            $this->StrokeLabels($pos,false);
+        }
+        $this->img->SetColor($this->radius_tick_color);
+        $this->scale->ticks->Stroke($this->img,$this->scale,$pos);
+
+        //
+        // Mirror the positions for the left side of the scale
+        //
+        $mid = 2*($this->img->left_margin+$this->img->plotwidth/2);
+        $n = count($this->scale->ticks->ticks_pos);
+        $i=0;
+        while( $i < $n ) {
+            $this->scale->ticks->ticks_pos[$i] =
+            $mid-$this->scale->ticks->ticks_pos[$i] ;
+            ++$i;
+        }
+
+        $n = count($this->scale->ticks->maj_ticks_pos);
+        $i=0;
+        while( $i < $n ) {
+            $this->scale->ticks->maj_ticks_pos[$i] =
+            $mid-$this->scale->ticks->maj_ticks_pos[$i] ;
+            ++$i;
+        }
+
+        $n = count($this->scale->ticks->maj_ticklabels_pos);
+        $i=1;
+        while( $i < $n ) {
+            $this->scale->ticks->maj_ticklabels_pos[$i] =
+            $mid-$this->scale->ticks->maj_ticklabels_pos[$i] ;
+            ++$i;
+        }
+
+        // Draw the left side of the scale
+        $n = count($this->scale->ticks->ticks_pos);
+        $yu = $pos - $this->scale->ticks->direction*$this->scale->ticks->GetMinTickAbsSize();
+
+
+        // Minor ticks
+        if( ! $this->scale->ticks->supress_minor_tickmarks ) {
+            $i=1;
+            while( $i < $n/2 ) {
+                $x = round($this->scale->ticks->ticks_pos[$i]) ;
+                $this->img->Line($x,$pos,$x,$yu);
+                ++$i;
+            }
+        }
+
+        $n = count($this->scale->ticks->maj_ticks_pos);
+        $yu = $pos - $this->scale->ticks->direction*$this->scale->ticks->GetMajTickAbsSize();
+
+
+        // Major ticks
+        if( ! $this->scale->ticks->supress_tickmarks ) {
+            $i=1;
+            while( $i < $n/2 ) {
+                $x = round($this->scale->ticks->maj_ticks_pos[$i]) ;
+                $this->img->Line($x,$pos,$x,$yu);
+                ++$i;
+            }
+        }
+        if (!$this->hide_labels) {
+            $this->StrokeLabels($pos,false);
+        }
+        $this->title->Stroke($this->img);
+    }
+}
+
+class PolarScale extends LinearScale {
+    private $graph;
+    public $clockwise=false;
+
+    function __construct($aMax,$graph,$aClockwise) {
+        parent::__construct(0,$aMax,'x');
+        $this->graph = $graph;
+        $this->clockwise = $aClockwise;
+    }
+
+    function SetClockwise($aFlg) {
+        $this->clockwise = $aFlg;
+    }
+
+    function _Translate($v) {
+        return parent::Translate($v);
+    }
+
+    function PTranslate($aAngle,$aRad) {
+
+        $m = $this->scale[1];
+        $w = $this->graph->img->plotwidth/2;
+        $aRad = $aRad/$m*$w;
+
+        $a = $aAngle/180 * M_PI;
+        if( $this->clockwise ) { 
+            $a = 2*M_PI-$a;
+        }
+
+        $x = cos($a) * $aRad;
+        $y = sin($a) * $aRad;
+
+        $x += $this->_Translate(0);
+
+        if( $this->graph->iType == POLAR_360 ) {
+            $y = ($this->graph->img->top_margin + $this->graph->img->plotheight/2) - $y;
+        }
+        else {
+            $y = ($this->graph->img->top_margin + $this->graph->img->plotheight) - $y;
+        }
+        return array($x,$y);
+    }
+}
+
+class PolarLogScale extends LogScale {
+    private $graph;
+    public $clockwise=false;
+
+    function __construct($aMax,$graph,$aClockwise=false) {
+        parent::__construct(0,$aMax,'x');
+        $this->graph = $graph;
+        $this->ticks->SetLabelLogType(LOGLABELS_MAGNITUDE);
+        $this->clockwise = $aClockwise;
+
+    }
+
+    function SetClockwise($aFlg) {
+        $this->clockwise = $aFlg;
+    }
+
+    function PTranslate($aAngle,$aRad) {
+
+        if( $aRad == 0 )
+        $aRad = 1;
+        $aRad = log10($aRad);
+        $m = $this->scale[1];
+        $w = $this->graph->img->plotwidth/2;
+        $aRad = $aRad/$m*$w;
+
+        $a = $aAngle/180 * M_PI;
+        if( $this->clockwise ) {
+            $a = 2*M_PI-$a;
+        }
+
+        $x = cos( $a ) * $aRad;
+        $y = sin( $a ) * $aRad;
+
+        $x += $w+$this->graph->img->left_margin;//$this->_Translate(0);
+        if( $this->graph->iType == POLAR_360 ) {
+            $y = ($this->graph->img->top_margin + $this->graph->img->plotheight/2) - $y;
+        }
+        else {
+            $y = ($this->graph->img->top_margin + $this->graph->img->plotheight) - $y;
+        }
+        return array($x,$y);
+    }
+}
+
+class PolarGraph extends Graph {
+    public $scale;
+    public $axis;
+    public $iType=POLAR_360;
+    private $iClockwise=false;
+
+    function __construct($aWidth=300,$aHeight=200,$aCachedName="",$aTimeOut=0,$aInline=true) {
+        parent::__construct($aWidth,$aHeight,$aCachedName,$aTimeOut,$aInline) ;
+        $this->SetDensity(TICKD_DENSE);
+        $this->SetBox();
+        $this->SetMarginColor('white');
+    }
+
+    function SetDensity($aDense) {
+        $this->SetTickDensity(TICKD_NORMAL,$aDense);
+    }
+
+    function SetClockwise($aFlg) {
+        $this->scale->SetClockwise($aFlg);
+    }
+
+    function Set90AndMargin($lm=0,$rm=0,$tm=0,$bm=0) {
+        $adj = ($this->img->height - $this->img->width)/2;
+        $this->SetAngle(90);
+        $lm2 = -$adj + ($lm-$rm+$tm+$bm)/2;
+        $rm2 = -$adj + (-$lm+$rm+$tm+$bm)/2;
+        $tm2 = $adj + ($tm-$bm+$lm+$rm)/2;
+        $bm2 = $adj + (-$tm+$bm+$lm+$rm)/2;
+        $this->SetMargin($lm2, $rm2, $tm2, $bm2);
+        $this->axis->SetLabelAlign('right','center');
+    }
+
+    function SetScale($aScale,$rmax=0,$dummy1=1,$dummy2=1,$dummy3=1) {
+        if( $aScale == 'lin' ) {
+            $this->scale = new PolarScale($rmax,$this,$this->iClockwise);
+        }
+        elseif( $aScale == 'log' ) {
+            $this->scale = new PolarLogScale($rmax,$this,$this->iClockwise);
+        }
+        else {
+            JpGraphError::RaiseL(17004);//('Unknown scale type for polar graph. Must be "lin" or "log"');
+        }
+
+        $this->axis = new PolarAxis($this->img,$this->scale);
+        $this->SetMargin(40,40,50,40);
+    }
+
+    function SetType($aType) {
+        $this->iType = $aType;
+    }
+
+    function SetPlotSize($w,$h) {
+        $this->SetMargin(($this->img->width-$w)/2,($this->img->width-$w)/2,
+                         ($this->img->height-$h)/2,($this->img->height-$h)/2);
+    }
+
+    // Private methods
+    function GetPlotsMax() {
+        $n = count($this->plots);
+        $m = $this->plots[0]->Max();
+        $i=1;
+        while($i < $n) {
+            $m = max($this->plots[$i]->Max(),$m);
+            ++$i;
+        }
+        return $m;
+    }
+
+    function Stroke($aStrokeFileName="") {
+
+        // Start by adjusting the margin so that potential titles will fit.
+        $this->AdjustMarginsForTitles();
+
+        // If the filename is the predefined value = '_csim_special_'
+        // we assume that the call to stroke only needs to do enough
+        // to correctly generate the CSIM maps.
+        // We use this variable to skip things we don't strictly need
+        // to do to generate the image map to improve performance
+        // a best we can. Therefor you will see a lot of tests !$_csim in the
+        // code below.
+        $_csim = ($aStrokeFileName===_CSIM_SPECIALFILE);
+
+        // We need to know if we have stroked the plot in the
+        // GetCSIMareas. Otherwise the CSIM hasn't been generated
+        // and in the case of GetCSIM called before stroke to generate
+        // CSIM without storing an image to disk GetCSIM must call Stroke.
+        $this->iHasStroked = true;
+
+        //Check if we should autoscale axis
+        if( !$this->scale->IsSpecified() && count($this->plots)>0 ) {
+            $max = $this->GetPlotsMax();
+            $t1 = $this->img->plotwidth;
+            $this->img->plotwidth /= 2;
+            $t2 = $this->img->left_margin;
+            $this->img->left_margin += $this->img->plotwidth+1;
+            $this->scale->AutoScale($this->img,0,$max,
+            $this->img->plotwidth/$this->xtick_factor/2);
+            $this->img->plotwidth = $t1;
+            $this->img->left_margin = $t2;
+        }
+        else {
+            // The tick calculation will use the user suplied min/max values to determine
+            // the ticks. If auto_ticks is false the exact user specifed min and max
+            // values will be used for the scale.
+            // If auto_ticks is true then the scale might be slightly adjusted
+            // so that the min and max values falls on an even major step.
+            //$min = 0;
+            $max = $this->scale->scale[1];
+            $t1 = $this->img->plotwidth;
+            $this->img->plotwidth /= 2;
+            $t2 = $this->img->left_margin;
+            $this->img->left_margin += $this->img->plotwidth+1;
+            $this->scale->AutoScale($this->img,0,$max,
+            $this->img->plotwidth/$this->xtick_factor/2);
+            $this->img->plotwidth = $t1;
+            $this->img->left_margin = $t2;
+        }
+
+        if( $this->iType ==  POLAR_180 ) {
+        	$pos = $this->img->height - $this->img->bottom_margin;
+        }
+        else {
+        	$pos = $this->img->plotheight/2 + $this->img->top_margin;
+        }
+
+        if( !$_csim ) {
+            $this->StrokePlotArea();
+        }
+
+        $this->iDoClipping = true;
+
+        if( $this->iDoClipping ) {
+            $oldimage = $this->img->CloneCanvasH();
+        }
+
+        if( !$_csim ) {
+            $this->axis->StrokeGrid($pos);
+        }
+
+        // Stroke all plots for Y1 axis
+        for($i=0; $i < count($this->plots); ++$i) {
+            $this->plots[$i]->Stroke($this->img,$this->scale);
+        }
+
+
+        if( $this->iDoClipping ) {
+            // Clipping only supports graphs at 0 and 90 degrees
+            if( $this->img->a == 0  ) {
+                $this->img->CopyCanvasH($oldimage,$this->img->img,
+                                        $this->img->left_margin,$this->img->top_margin,
+                                        $this->img->left_margin,$this->img->top_margin,
+                                        $this->img->plotwidth+1,$this->img->plotheight+1);
+            }
+            elseif( $this->img->a == 90 ) {
+                $adj1 = round(($this->img->height - $this->img->width)/2);
+                $adj2 = round(($this->img->width - $this->img->height)/2);
+                $lm = $this->img->left_margin;
+                $rm = $this->img->right_margin;
+                $tm = $this->img->top_margin;
+                $bm = $this->img->bottom_margin;
+                $this->img->CopyCanvasH($oldimage,$this->img->img,
+                                        $adj2 + round(($lm-$rm+$tm+$bm)/2),
+                                        $adj1 + round(($tm-$bm+$lm+$rm)/2),
+                                        $adj2 + round(($lm-$rm+$tm+$bm)/2),
+                                        $adj1 + round(($tm-$bm+$lm+$rm)/2),
+                                        $this->img->plotheight+1,
+                                        $this->img->plotwidth+1);
+            }
+            $this->img->Destroy();
+            $this->img->SetCanvasH($oldimage);
+        }
+
+        if( !$_csim ) {
+            $this->axis->Stroke($pos);
+            $this->axis->StrokeAngleLabels($pos,$this->iType);
+        }
+
+        if( !$_csim ) {
+            $this->StrokePlotBox();
+            $this->footer->Stroke($this->img);
+
+            // The titles and legends never gets rotated so make sure
+            // that the angle is 0 before stroking them
+            $aa = $this->img->SetAngle(0);
+            $this->StrokeTitles();
+        }
+
+        for($i=0; $i < count($this->plots) ; ++$i ) {
+            $this->plots[$i]->Legend($this);
+        }
+
+        $this->legend->Stroke($this->img);
+
+        if( !$_csim ) {
+
+            $this->StrokeTexts();
+            $this->img->SetAngle($aa);
+
+            // Draw an outline around the image map
+            if(_JPG_DEBUG)
+            	$this->DisplayClientSideaImageMapAreas();
+
+            // If the filename is given as the special "__handle"
+            // then the image handler is returned and the image is NOT
+            // streamed back
+            if( $aStrokeFileName == _IMG_HANDLER ) {
+                return $this->img->img;
+            }
+            else {
+                // Finally stream the generated picture
+                $this->cache->PutAndStream($this->img,$this->cache_name,$this->inline,$aStrokeFileName);
+            }
+        }
+    }
+}
+
+
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_radar.php b/web/classes/jpgraph/jpgraph_radar.php
new file mode 100755
index 0000000000000000000000000000000000000000..1d3de628617437e0403311a6507301c913381f80
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_radar.php
@@ -0,0 +1,861 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_RADAR.PHP
+ // Description: Radar plot extension for JpGraph
+ // Created:     2001-02-04
+ // Ver:         $Id: jpgraph_radar.php 1783 2009-08-25 11:41:01Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+require_once('jpgraph_plotmark.inc.php');
+
+//===================================================
+// CLASS RadarLogTicks
+// Description: Logarithmic ticks
+//===================================================
+class RadarLogTicks extends Ticks {
+
+    function __construct() {
+            // Empty
+    }
+
+    function Stroke($aImg,&$grid,$aPos,$aAxisAngle,$aScale,&$aMajPos,&$aMajLabel) {
+        $start = $aScale->GetMinVal();
+        $limit = $aScale->GetMaxVal();
+        $nextMajor = 10*$start;
+        $step = $nextMajor / 10.0;
+        $count=1;
+
+        $ticklen_maj=5;
+        $dx_maj=round(sin($aAxisAngle)*$ticklen_maj);
+        $dy_maj=round(cos($aAxisAngle)*$ticklen_maj);
+        $ticklen_min=3;
+        $dx_min=round(sin($aAxisAngle)*$ticklen_min);
+        $dy_min=round(cos($aAxisAngle)*$ticklen_min);
+
+        $aMajPos=array();
+        $aMajLabel=array();
+
+        if( $this->supress_first ) {
+            $aMajLabel[] = '';
+        }
+        else {
+            $aMajLabel[]=$start;
+        }
+
+        $yr=$aScale->RelTranslate($start);
+        $xt=round($yr*cos($aAxisAngle))+$aScale->scale_abs[0];
+        $yt=$aPos-round($yr*sin($aAxisAngle));
+        $aMajPos[]=$xt+2*$dx_maj;
+        $aMajPos[]=$yt-$aImg->GetFontheight()/2;
+        $grid[]=$xt;
+        $grid[]=$yt;
+
+        $aImg->SetLineWeight($this->weight);
+
+        for($y=$start; $y<=$limit; $y+=$step,++$count  ) {
+            $yr=$aScale->RelTranslate($y);
+            $xt=round($yr*cos($aAxisAngle))+$aScale->scale_abs[0];
+            $yt=$aPos-round($yr*sin($aAxisAngle));
+            if( $count % 10 == 0 ) {
+                $grid[]=$xt;
+                $grid[]=$yt;
+                $aMajPos[]=$xt+2*$dx_maj;
+                $aMajPos[]=$yt-$aImg->GetFontheight()/2;
+                if( !$this->supress_tickmarks ) {
+                    if( $this->majcolor != '' ) {
+                        $aImg->PushColor($this->majcolor);
+                    }
+                    $aImg->Line($xt+$dx_maj,$yt+$dy_maj,$xt-$dx_maj,$yt-$dy_maj);
+                    if( $this->majcolor != '' ) {
+                        $aImg->PopColor();
+                    }
+                }
+                if( $this->label_formfunc != '' ) {
+                    $f=$this->label_formfunc;
+                    $l = call_user_func($f,$nextMajor);
+                }
+                else {
+                    $l = $nextMajor;
+                }
+
+                $aMajLabel[]=$l;
+                $nextMajor *= 10;
+                $step *= 10;
+                $count=1;
+            }
+            else {
+                if( !$this->supress_minor_tickmarks ) {
+                    if( $this->mincolor != '' ) {
+                        $aImg->PushColor($this->mincolor);
+                    }
+                    $aImg->Line($xt+$dx_min,$yt+$dy_min,$xt-$dx_min,$yt-$dy_min);
+                    if( $this->mincolor != '' ) {
+                        $aImg->PopColor();
+                    }
+                }
+            }
+        }
+    }
+}
+
+//===================================================
+// CLASS RadarLinear
+// Description: Linear ticks
+//===================================================
+class RadarLinearTicks extends Ticks {
+
+    private $minor_step=1, $major_step=2;
+    private $xlabel_offset=0,$xtick_offset=0;
+
+    function __construct() {
+        // Empty
+    }
+
+    // Return major step size in world coordinates
+    function GetMajor() {
+        return $this->major_step;
+    }
+
+    // Return minor step size in world coordinates
+    function GetMinor() {
+        return $this->minor_step;
+    }
+
+    // Set Minor and Major ticks (in world coordinates)
+    function Set($aMajStep,$aMinStep=false) {
+        if( $aMinStep==false ) {
+            $aMinStep=$aMajStep;
+        }
+
+        if( $aMajStep <= 0 || $aMinStep <= 0 ) {
+            JpGraphError::RaiseL(25064);
+            //JpGraphError::Raise(" Minor or major step size is 0. Check that you haven't got an accidental SetTextTicks(0) in your code. If this is not the case you might have stumbled upon a bug in JpGraph. Please report this and if possible include the data that caused the problem.");
+        }
+
+        $this->major_step=$aMajStep;
+        $this->minor_step=$aMinStep;
+        $this->is_set = true;
+    }
+
+    function Stroke($aImg,&$grid,$aPos,$aAxisAngle,$aScale,&$aMajPos,&$aMajLabel) {
+        // Prepare to draw linear ticks
+        $maj_step_abs = abs($aScale->scale_factor*$this->major_step);
+        $min_step_abs = abs($aScale->scale_factor*$this->minor_step);
+        $nbrmaj = round($aScale->world_abs_size/$maj_step_abs);
+        $nbrmin = round($aScale->world_abs_size/$min_step_abs);
+        $skip = round($nbrmin/$nbrmaj); // Don't draw minor on top of major
+
+        // Draw major ticks
+        $ticklen2=$this->major_abs_size;
+        $dx=round(sin($aAxisAngle)*$ticklen2);
+        $dy=round(cos($aAxisAngle)*$ticklen2);
+        $label=$aScale->scale[0]+$this->major_step;
+
+        $aImg->SetLineWeight($this->weight);
+
+        $aMajPos = array();
+        $aMajLabel = array();
+
+        for($i=1; $i<=$nbrmaj; ++$i) {
+            $xt=round($i*$maj_step_abs*cos($aAxisAngle))+$aScale->scale_abs[0];
+            $yt=$aPos-round($i*$maj_step_abs*sin($aAxisAngle));
+
+            if( $this->label_formfunc != '' ) {
+                $f=$this->label_formfunc;
+                $l = call_user_func($f,$label);
+            }
+            else {
+                $l = $label;
+            }
+
+            $aMajLabel[]=$l;
+            $label += $this->major_step;
+            $grid[]=$xt;
+            $grid[]=$yt;
+            $aMajPos[($i-1)*2]=$xt+2*$dx;
+            $aMajPos[($i-1)*2+1]=$yt-$aImg->GetFontheight()/2;
+            if( !$this->supress_tickmarks ) {
+                if( $this->majcolor != '' ) {
+                    $aImg->PushColor($this->majcolor);
+                }
+                $aImg->Line($xt+$dx,$yt+$dy,$xt-$dx,$yt-$dy);
+                if( $this->majcolor != '' ) {
+                    $aImg->PopColor();
+                }
+            }
+        }
+
+        // Draw minor ticks
+        $ticklen2=$this->minor_abs_size;
+        $dx=round(sin($aAxisAngle)*$ticklen2);
+        $dy=round(cos($aAxisAngle)*$ticklen2);
+        if( !$this->supress_tickmarks && !$this->supress_minor_tickmarks) {
+            if( $this->mincolor != '' ) {
+                $aImg->PushColor($this->mincolor);
+            }
+            for($i=1; $i<=$nbrmin; ++$i) {
+                if( ($i % $skip) == 0 ) {
+                    continue;
+                }
+                $xt=round($i*$min_step_abs*cos($aAxisAngle))+$aScale->scale_abs[0];
+                $yt=$aPos-round($i*$min_step_abs*sin($aAxisAngle));
+                $aImg->Line($xt+$dx,$yt+$dy,$xt-$dx,$yt-$dy);
+            }
+            if( $this->mincolor != '' ) {
+                $aImg->PopColor();
+            }
+        }
+    }
+}
+
+
+//===================================================
+// CLASS RadarAxis
+// Description: Implements axis for the radar graph
+//===================================================
+class RadarAxis extends AxisPrototype {
+    public $title=null;
+    private $title_color='navy';
+    private $len=0;
+
+    function __construct($img,$aScale,$color=array(0,0,0)) {
+        parent::__construct($img,$aScale,$color);
+        $this->len = $img->plotheight;
+        $this->title = new Text();
+        $this->title->SetFont(FF_FONT1,FS_BOLD);
+        $this->color = array(0,0,0);
+    }
+
+    // Stroke the axis
+    // $pos    = Vertical position of axis
+    // $aAxisAngle = Axis angle
+    // $grid   = Returns an array with positions used to draw the grid
+    // $lf   = Label flag, TRUE if the axis should have labels
+    function Stroke($pos,$aAxisAngle,&$grid,$title,$lf) {
+        $this->img->SetColor($this->color);
+
+        // Determine end points for the axis
+        $x=round($this->scale->world_abs_size*cos($aAxisAngle)+$this->scale->scale_abs[0]);
+        $y=round($pos-$this->scale->world_abs_size*sin($aAxisAngle));
+
+        // Draw axis
+        $this->img->SetColor($this->color);
+        $this->img->SetLineWeight($this->weight);
+        if( !$this->hide ) {
+            $this->img->Line($this->scale->scale_abs[0],$pos,$x,$y);
+        }
+
+        $this->scale->ticks->Stroke($this->img,$grid,$pos,$aAxisAngle,$this->scale,$majpos,$majlabel);
+        $ncolor=0;
+        if( isset($this->ticks_label_colors) ) {
+            $ncolor=count($this->ticks_label_colors);
+        }
+
+        // Draw labels
+        if( $lf && !$this->hide ) {
+            $this->img->SetFont($this->font_family,$this->font_style,$this->font_size);
+            $this->img->SetTextAlign('left','top');
+            $this->img->SetColor($this->label_color);
+
+            // majpos contains (x,y) coordinates for labels
+            if( ! $this->hide_labels ) {
+                $n = floor(count($majpos)/2);
+                for($i=0; $i < $n; ++$i) {
+                    // Set specific label color if specified
+                    if( $ncolor > 0 ) {
+                        $this->img->SetColor($this->ticks_label_colors[$i % $ncolor]);
+                    }
+
+                    if( $this->ticks_label != null && isset($this->ticks_label[$i]) ) {
+                        $this->img->StrokeText($majpos[$i*2],$majpos[$i*2+1],$this->ticks_label[$i]);
+                    }
+                    else {
+                        $this->img->StrokeText($majpos[$i*2],$majpos[$i*2+1],$majlabel[$i]);
+                    }
+                }
+            }
+        }
+        $this->_StrokeAxisTitle($pos,$aAxisAngle,$title);
+    }
+
+    function _StrokeAxisTitle($pos,$aAxisAngle,$title) {
+        $this->title->Set($title);
+        $marg=6+$this->title->margin;
+        $xt=round(($this->scale->world_abs_size+$marg)*cos($aAxisAngle)+$this->scale->scale_abs[0]);
+        $yt=round($pos-($this->scale->world_abs_size+$marg)*sin($aAxisAngle));
+
+        // Position the axis title.
+        // dx, dy is the offset from the top left corner of the bounding box that sorrounds the text
+        // that intersects with the extension of the corresponding axis. The code looks a little
+        // bit messy but this is really the only way of having a reasonable position of the
+        // axis titles.
+        if( $this->title->iWordwrap > 0 ) {
+            $title = wordwrap($title,$this->title->iWordwrap,"\n");
+        }
+
+        $h=$this->img->GetTextHeight($title)*1.2;
+        $w=$this->img->GetTextWidth($title)*1.2;
+
+        while( $aAxisAngle > 2*M_PI )
+            $aAxisAngle -= 2*M_PI;
+
+        // Around 3 a'clock
+        if( $aAxisAngle>=7*M_PI/4 || $aAxisAngle <= M_PI/4 ) $dx=-0.15; // Small trimming to make the dist to the axis more even
+
+        // Around 12 a'clock
+        if( $aAxisAngle>=M_PI/4 && $aAxisAngle <= 3*M_PI/4 ) $dx=($aAxisAngle-M_PI/4)*2/M_PI;
+
+        // Around 9 a'clock
+        if( $aAxisAngle>=3*M_PI/4 && $aAxisAngle <= 5*M_PI/4 ) $dx=1;
+
+        // Around 6 a'clock
+        if( $aAxisAngle>=5*M_PI/4 && $aAxisAngle <= 7*M_PI/4 ) $dx=(1-($aAxisAngle-M_PI*5/4)*2/M_PI);
+
+        if( $aAxisAngle>=7*M_PI/4 ) $dy=(($aAxisAngle-M_PI)-3*M_PI/4)*2/M_PI;
+        if( $aAxisAngle<=M_PI/12 ) $dy=(0.5-$aAxisAngle*2/M_PI);
+        if( $aAxisAngle<=M_PI/4 && $aAxisAngle > M_PI/12) $dy=(1-$aAxisAngle*2/M_PI);
+        if( $aAxisAngle>=M_PI/4 && $aAxisAngle <= 3*M_PI/4 ) $dy=1;
+        if( $aAxisAngle>=3*M_PI/4 && $aAxisAngle <= 5*M_PI/4 ) $dy=(1-($aAxisAngle-3*M_PI/4)*2/M_PI);
+        if( $aAxisAngle>=5*M_PI/4 && $aAxisAngle <= 7*M_PI/4 ) $dy=0;
+
+        if( !$this->hide ) {
+            $this->title->Stroke($this->img,$xt-$dx*$w,$yt-$dy*$h,$title);
+        }
+    }
+
+} // Class
+
+
+//===================================================
+// CLASS RadarGrid
+// Description: Draws grid for the radar graph
+//===================================================
+class RadarGrid { //extends Grid {
+    private $type='solid';
+    private $grid_color='#DDDDDD';
+    private $show=false, $weight=1;
+
+    function __construct() {
+        // Empty
+    }
+
+    function SetColor($aMajColor) {
+        $this->grid_color = $aMajColor;
+    }
+
+    function SetWeight($aWeight) {
+        $this->weight=$aWeight;
+    }
+
+    // Specify if grid should be dashed, dotted or solid
+    function SetLineStyle($aType) {
+        $this->type = $aType;
+    }
+
+    // Decide if both major and minor grid should be displayed
+    function Show($aShowMajor=true) {
+        $this->show=$aShowMajor;
+    }
+
+    function Stroke($img,$grid) {
+        if( !$this->show ) {
+            return;
+        }
+
+        $nbrticks = count($grid[0])/2;
+        $nbrpnts = count($grid);
+        $img->SetColor($this->grid_color);
+        $img->SetLineWeight($this->weight);
+
+        for($i=0; $i<$nbrticks; ++$i) {
+            for($j=0; $j<$nbrpnts; ++$j) {
+                $pnts[$j*2]=$grid[$j][$i*2];
+                $pnts[$j*2+1]=$grid[$j][$i*2+1];
+            }
+            for($k=0; $k<$nbrpnts; ++$k ){
+                $l=($k+1)%$nbrpnts;
+                if( $this->type == 'solid' )
+                    $img->Line($pnts[$k*2],$pnts[$k*2+1],$pnts[$l*2],$pnts[$l*2+1]);
+                elseif( $this->type == 'dotted' )
+                    $img->DashedLine($pnts[$k*2],$pnts[$k*2+1],$pnts[$l*2],$pnts[$l*2+1],1,6);
+                elseif( $this->type == 'dashed' )
+                    $img->DashedLine($pnts[$k*2],$pnts[$k*2+1],$pnts[$l*2],$pnts[$l*2+1],2,4);
+                elseif( $this->type == 'longdashed' )
+                    $img->DashedLine($pnts[$k*2],$pnts[$k*2+1],$pnts[$l*2],$pnts[$l*2+1],8,6);
+            }
+            $pnts=array();
+        }
+    }
+} // Class
+
+
+//===================================================
+// CLASS RadarPlot
+// Description: Plot a radarplot
+//===================================================
+class RadarPlot {
+    public $mark=null;
+    public $legend='';
+    public $legendcsimtarget='';
+    public $legendcsimalt='';
+    public $csimtargets=array(); // Array of targets for CSIM
+    public $csimareas="";   // Resultant CSIM area tags
+    public $csimalts=null;   // ALT:s for corresponding target
+    private $data=array();
+    private $fill=false, $fill_color=array(200,170,180);
+    private $color=array(0,0,0);
+    private $weight=1;
+    private $linestyle='solid';
+
+    //---------------
+    // CONSTRUCTOR
+    function __construct($data) {
+        $this->data = $data;
+        $this->mark = new PlotMark();
+    }
+
+    function Min() {
+        return Min($this->data);
+    }
+
+    function Max() {
+        return Max($this->data);
+    }
+
+    function SetLegend($legend) {
+        $this->legend=$legend;
+    }
+
+    function SetLineStyle($aStyle) {
+        $this->linestyle=$aStyle;
+    }
+
+    function SetLineWeight($w) {
+        $this->weight=$w;
+    }
+
+    function SetFillColor($aColor) {
+        $this->fill_color = $aColor;
+        $this->fill = true;
+    }
+
+    function SetFill($f=true) {
+        $this->fill = $f;
+    }
+
+    function SetColor($aColor,$aFillColor=false) {
+        $this->color = $aColor;
+        if( $aFillColor ) {
+            $this->SetFillColor($aFillColor);
+            $this->fill = true;
+        }
+    }
+
+    // Set href targets for CSIM
+    function SetCSIMTargets($aTargets,$aAlts=null) {
+        $this->csimtargets=$aTargets;
+        $this->csimalts=$aAlts;
+    }
+
+    // Get all created areas
+    function GetCSIMareas() {
+        return $this->csimareas;
+    }
+
+    function Stroke($img, $pos, $scale, $startangle) {
+        $nbrpnts = count($this->data);
+        $astep=2*M_PI/$nbrpnts;
+        $a=$startangle;
+
+        for($i=0; $i<$nbrpnts; ++$i) {
+
+            // Rotate each non null point to the correct axis-angle
+            $cs=$scale->RelTranslate($this->data[$i]);
+            $x=round($cs*cos($a)+$scale->scale_abs[0]);
+            $y=round($pos-$cs*sin($a));
+
+            $pnts[$i*2]=$x;
+            $pnts[$i*2+1]=$y;
+
+            // If the next point is null then we draw this polygon segment
+            // to the center, skip the next and draw the next segment from
+            // the center up to the point on the axis with the first non-null
+            // value and continues from that point. Some additoinal logic is necessary
+            // to handle the boundary conditions
+            if( $i < $nbrpnts-1 ) {
+                if( is_null($this->data[$i+1]) ) {
+                    $cs = 0;
+                    $x=round($cs*cos($a)+$scale->scale_abs[0]);
+                    $y=round($pos-$cs*sin($a));
+                    $pnts[$i*2]=$x;
+                    $pnts[$i*2+1]=$y;
+                    $a += $astep;
+                }
+            }
+
+            $a += $astep;
+        }
+
+        if( $this->fill ) {
+            $img->SetColor($this->fill_color);
+            $img->FilledPolygon($pnts);
+        }
+
+        $img->SetLineWeight($this->weight);
+        $img->SetColor($this->color);
+        $img->SetLineStyle($this->linestyle);
+        $pnts[] = $pnts[0];
+        $pnts[] = $pnts[1];
+        $img->Polygon($pnts);
+        $img->SetLineStyle('solid'); // Reset line style to default
+
+        // Add plotmarks on top
+        if( $this->mark->show ) {
+			for($i=0; $i < $nbrpnts; ++$i) {
+	            if( isset($this->csimtargets[$i]) ) {
+	                $this->mark->SetCSIMTarget($this->csimtargets[$i]);
+	                $this->mark->SetCSIMAlt($this->csimalts[$i]);
+	                $this->mark->SetCSIMAltVal($pnts[$i*2], $pnts[$i*2+1]);
+	                $this->mark->Stroke($img, $pnts[$i*2], $pnts[$i*2+1]);
+	                $this->csimareas .= $this->mark->GetCSIMAreas();
+	            }
+	            else {
+					$this->mark->Stroke($img,$pnts[$i*2],$pnts[$i*2+1]);
+	            }
+            }
+        }
+
+    }
+
+    function GetCount() {
+        return count($this->data);
+    }
+
+    function Legend($graph) {
+        if( $this->legend == '' ) {
+            return;
+        }
+        if( $this->fill ) {
+            $graph->legend->Add($this->legend,$this->fill_color,$this->mark);
+        } else {
+            $graph->legend->Add($this->legend,$this->color,$this->mark);
+        }
+    }
+
+} // Class
+
+//===================================================
+// CLASS RadarGraph
+// Description: Main container for a radar graph
+//===================================================
+class RadarGraph extends Graph {
+    public $grid,$axis=null;
+    private $posx,$posy;
+    private $len;
+    private $axis_title=null;
+
+    function __construct($width=300,$height=200,$cachedName="",$timeout=0,$inline=1) {
+        parent::__construct($width,$height,$cachedName,$timeout,$inline);
+        $this->posx = $width/2;
+        $this->posy = $height/2;
+        $this->len = min($width,$height)*0.35;
+        $this->SetColor(array(255,255,255));
+        $this->SetTickDensity(TICKD_NORMAL);
+        $this->SetScale('lin');
+        $this->SetGridDepth(DEPTH_FRONT);
+    }
+
+    function HideTickMarks($aFlag=true) {
+        $this->axis->scale->ticks->SupressTickMarks($aFlag);
+    }
+
+    function ShowMinorTickmarks($aFlag=true) {
+        $this->yscale->ticks->SupressMinorTickMarks(!$aFlag);
+    }
+
+    function SetScale($axtype,$ymin=1,$ymax=1,$dummy1=null,$dumy2=null) {
+        if( $axtype != 'lin' && $axtype != 'log' ) {
+            JpGraphError::RaiseL(18003,$axtype);
+            //("Illegal scale for radarplot ($axtype). Must be \"lin\" or \"log\"");
+        }
+        if( $axtype == 'lin' ) {
+            $this->yscale = new LinearScale($ymin,$ymax);
+            $this->yscale->ticks = new RadarLinearTicks();
+            $this->yscale->ticks->SupressMinorTickMarks();
+        }
+        elseif( $axtype == 'log' ) {
+            $this->yscale = new LogScale($ymin,$ymax);
+            $this->yscale->ticks = new RadarLogTicks();
+        }
+
+        $this->axis = new RadarAxis($this->img,$this->yscale);
+        $this->grid = new RadarGrid();
+    }
+
+    function SetSize($aSize) {
+        if( $aSize < 0.1 || $aSize>1 ) {
+            JpGraphError::RaiseL(18004,$aSize);
+            //("Radar Plot size must be between 0.1 and 1. (Your value=$s)");
+        }
+        $this->len=min($this->img->width,$this->img->height)*$aSize/2;
+    }
+
+    function SetPlotSize($aSize) {
+        $this->SetSize($aSize);
+    }
+
+    function SetTickDensity($densy=TICKD_NORMAL,$dummy1=null) {
+        $this->ytick_factor=25;
+        switch( $densy ) {
+            case TICKD_DENSE:
+                $this->ytick_factor=12;
+                break;
+            case TICKD_NORMAL:
+                $this->ytick_factor=25;
+                break;
+            case TICKD_SPARSE:
+                $this->ytick_factor=40;
+                break;
+            case TICKD_VERYSPARSE:
+                $this->ytick_factor=70;
+                break;
+            default:
+                JpGraphError::RaiseL(18005,$densy);
+                //("RadarPlot Unsupported Tick density: $densy");
+        }
+    }
+
+    function SetPos($px,$py=0.5) {
+        $this->SetCenter($px,$py);
+    }
+
+    function SetCenter($px,$py=0.5) {
+        if( $px >= 0 && $px <= 1 ) {
+        	$this->posx = $this->img->width*$px;
+        }
+        else {
+        	$this->posx = $px;
+        }
+        if( $py >= 0 && $py <= 1 ) {
+        	$this->posy = $this->img->height*$py;
+        }
+        else {
+        	$this->posy = $py;
+        }
+    }
+
+    function SetColor($aColor) {
+        $this->SetMarginColor($aColor);
+    }
+
+    function SetTitles($aTitleArray) {
+        $this->axis_title = $aTitleArray;
+    }
+
+    function Add($aPlot) {
+    	if( $aPlot == null ) {
+            JpGraphError::RaiseL(25010);//("Graph::Add() You tried to add a null plot to the graph.");
+        }
+        if( is_array($aPlot) && count($aPlot) > 0 ) {
+            $cl = $aPlot[0];
+        }
+        else {
+            $cl = $aPlot;
+        }
+
+        if( $cl instanceof Text ) $this->AddText($aPlot);
+        elseif( class_exists('IconPlot',false) && ($cl instanceof IconPlot) ) $this->AddIcon($aPlot);
+        else {
+            $this->plots[] = $aPlot;
+        }
+    }
+
+    function GetPlotsYMinMax($aPlots) {
+        $min=$aPlots[0]->Min();
+        $max=$aPlots[0]->Max();
+        foreach( $this->plots as $p ) {
+            $max=max($max,$p->Max());
+            $min=min($min,$p->Min());
+        }
+        if( $min < 0 ) {
+            JpGraphError::RaiseL(18006,$min);
+            //("Minimum data $min (Radar plots should only be used when all data points > 0)");
+        }
+        return array($min,$max);
+    }
+
+    function StrokeIcons() {
+    	if( $this->iIcons != null ) {
+        	$n = count($this->iIcons);
+        	for( $i=0; $i < $n; ++$i ) {
+            	$this->iIcons[$i]->Stroke($this->img);
+        	}
+    	}
+    }
+
+	function StrokeTexts() {
+        if( $this->texts != null ) {
+			$n = count($this->texts);
+            for( $i=0; $i < $n; ++$i ) {
+                $this->texts[$i]->Stroke($this->img);
+            }
+        }
+    }
+
+    // Stroke the Radar graph
+    function Stroke($aStrokeFileName='') {
+
+        // If the filename is the predefined value = '_csim_special_'
+        // we assume that the call to stroke only needs to do enough
+        // to correctly generate the CSIM maps.
+        // We use this variable to skip things we don't strictly need
+        // to do to generate the image map to improve performance
+        // a best we can. Therefor you will see a lot of tests !$_csim in the
+        // code below.
+        $_csim = ( $aStrokeFileName === _CSIM_SPECIALFILE );
+
+        // We need to know if we have stroked the plot in the
+        // GetCSIMareas. Otherwise the CSIM hasn't been generated
+        // and in the case of GetCSIM called before stroke to generate
+        // CSIM without storing an image to disk GetCSIM must call Stroke.
+        $this->iHasStroked = true;
+
+        $n = count($this->plots);
+        // Set Y-scale
+
+        if( !$this->yscale->IsSpecified() && count($this->plots) > 0 ) {
+            list($min,$max) = $this->GetPlotsYMinMax($this->plots);
+            $this->yscale->AutoScale($this->img,0,$max,$this->len/$this->ytick_factor);
+        }
+        elseif( $this->yscale->IsSpecified() &&
+                ( $this->yscale->auto_ticks || !$this->yscale->ticks->IsSpecified()) ) {
+
+            // The tick calculation will use the user suplied min/max values to determine
+            // the ticks. If auto_ticks is false the exact user specifed min and max
+            // values will be used for the scale.
+            // If auto_ticks is true then the scale might be slightly adjusted
+            // so that the min and max values falls on an even major step.
+            $min = $this->yscale->scale[0];
+            $max = $this->yscale->scale[1];
+            $this->yscale->AutoScale($this->img,$min,$max,
+                                     $this->len/$this->ytick_factor,
+                                     $this->yscale->auto_ticks);
+        }
+
+        // Set start position end length of scale (in absolute pixels)
+        $this->yscale->SetConstants($this->posx,$this->len);
+
+        // We need as many axis as there are data points
+        $nbrpnts=$this->plots[0]->GetCount();
+
+        // If we have no titles just number the axis 1,2,3,...
+        if( $this->axis_title==null ) {
+            for($i=0; $i < $nbrpnts; ++$i ) {
+                $this->axis_title[$i] = $i+1;
+            }
+        }
+        elseif( count($this->axis_title) < $nbrpnts) {
+            JpGraphError::RaiseL(18007);
+            // ("Number of titles does not match number of points in plot.");
+        }
+        for( $i=0; $i < $n; ++$i ) {
+            if( $nbrpnts != $this->plots[$i]->GetCount() ) {
+                JpGraphError::RaiseL(18008);
+                //("Each radar plot must have the same number of data points.");
+            }
+        }
+
+        if( !$_csim ) {
+        	if( $this->background_image != '' ) {
+            	$this->StrokeFrameBackground();
+        	}
+        	else {
+            	$this->StrokeFrame();
+            	$this->StrokeBackgroundGrad();
+        	}
+        }
+        $astep=2*M_PI/$nbrpnts;
+
+		if( !$_csim ) {
+     		if( $this->iIconDepth == DEPTH_BACK ) {
+        		$this->StrokeIcons();
+        	}
+
+
+	        // Prepare legends
+    	    for($i=0; $i < $n; ++$i) {
+        	    $this->plots[$i]->Legend($this);
+	        }
+    	    $this->legend->Stroke($this->img);
+        	$this->footer->Stroke($this->img);
+		}
+
+		if( !$_csim ) {
+	        if( $this->grid_depth == DEPTH_BACK ) {
+	            // Draw axis and grid
+	            for( $i=0,$a=M_PI/2; $i < $nbrpnts; ++$i, $a += $astep ) {
+	                $this->axis->Stroke($this->posy,$a,$grid[$i],$this->axis_title[$i],$i==0);
+	            }
+                $this->grid->Stroke($this->img,$grid);
+	        }
+            if( $this->iIconDepth == DEPTH_BACK ) {
+                $this->StrokeIcons();
+            }
+
+		}
+
+        // Plot points
+        $a=M_PI/2;
+        for($i=0; $i < $n; ++$i ) {
+            $this->plots[$i]->Stroke($this->img, $this->posy, $this->yscale, $a);
+        }
+
+        if( !$_csim ) {
+            if( $this->grid_depth != DEPTH_BACK ) {
+                // Draw axis and grid
+                for( $i=0,$a=M_PI/2; $i < $nbrpnts; ++$i, $a += $astep ) {
+                   $this->axis->Stroke($this->posy,$a,$grid[$i],$this->axis_title[$i],$i==0);
+                }
+                $this->grid->Stroke($this->img,$grid);
+            }
+
+        	$this->StrokeTitles();
+       		$this->StrokeTexts();
+       		if( $this->iIconDepth == DEPTH_FRONT ) {
+        		$this->StrokeIcons();
+        	}
+		}
+
+        // Should we do any final image transformation
+        if( $this->iImgTrans && !$_csim ) {
+            if( !class_exists('ImgTrans',false) ) {
+                require_once('jpgraph_imgtrans.php');
+            }
+
+            $tform = new ImgTrans($this->img->img);
+            $this->img->img = $tform->Skew3D($this->iImgTransHorizon,$this->iImgTransSkewDist,
+            $this->iImgTransDirection,$this->iImgTransHighQ,
+            $this->iImgTransMinSize,$this->iImgTransFillColor,
+            $this->iImgTransBorder);
+        }
+
+		if( !$_csim ) {
+	        // If the filename is given as the special "__handle"
+	        // then the image handler is returned and the image is NOT
+	        // streamed back
+	        if( $aStrokeFileName == _IMG_HANDLER ) {
+	            return $this->img->img;
+	        }
+	        else {
+	            // Finally stream the generated picture
+	            $this->cache->PutAndStream($this->img,$this->cache_name,$this->inline,$aStrokeFileName);
+	        }
+		}
+    }
+} // Class
+
+/* EOF */
+?>
diff --git a/web/classes/jpgraph/jpgraph_regstat.php b/web/classes/jpgraph/jpgraph_regstat.php
new file mode 100755
index 0000000000000000000000000000000000000000..0f6c96be776a23761636bc1166712ccdc076bf3e
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_regstat.php
@@ -0,0 +1,215 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_REGSTAT.PHP
+ // Description: Regression and statistical analysis helper classes
+ // Created:     2002-12-01
+ // Ver:         $Id: jpgraph_regstat.php 1131 2009-03-11 20:08:24Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+//------------------------------------------------------------------------
+// CLASS Spline
+// Create a new data array from an existing data array but with more points.
+// The new points are interpolated using a cubic spline algorithm
+//------------------------------------------------------------------------
+class Spline {
+    // 3:rd degree polynom approximation
+
+    private $xdata,$ydata;   // Data vectors
+    private $y2;   // 2:nd derivate of ydata
+    private $n=0;
+
+    function __construct($xdata,$ydata) {
+        $this->y2 = array();
+        $this->xdata = $xdata;
+        $this->ydata = $ydata;
+
+        $n = count($ydata);
+        $this->n = $n;
+        if( $this->n !== count($xdata) ) {
+            JpGraphError::RaiseL(19001);
+            //('Spline: Number of X and Y coordinates must be the same');
+        }
+
+        // Natural spline 2:derivate == 0 at endpoints
+        $this->y2[0]    = 0.0;
+        $this->y2[$n-1] = 0.0;
+        $delta[0] = 0.0;
+
+        // Calculate 2:nd derivate
+        for($i=1; $i < $n-1; ++$i) {
+            $d = ($xdata[$i+1]-$xdata[$i-1]);
+            if( $d == 0  ) {
+                JpGraphError::RaiseL(19002);
+                //('Invalid input data for spline. Two or more consecutive input X-values are equal. Each input X-value must differ since from a mathematical point of view it must be a one-to-one mapping, i.e. each X-value must correspond to exactly one Y-value.');
+            }
+            $s = ($xdata[$i]-$xdata[$i-1])/$d;
+            $p = $s*$this->y2[$i-1]+2.0;
+            $this->y2[$i] = ($s-1.0)/$p;
+            $delta[$i] = ($ydata[$i+1]-$ydata[$i])/($xdata[$i+1]-$xdata[$i]) -
+            ($ydata[$i]-$ydata[$i-1])/($xdata[$i]-$xdata[$i-1]);
+            $delta[$i] = (6.0*$delta[$i]/($xdata[$i+1]-$xdata[$i-1])-$s*$delta[$i-1])/$p;
+        }
+
+        // Backward substitution
+        for( $j=$n-2; $j >= 0; --$j ) {
+            $this->y2[$j] = $this->y2[$j]*$this->y2[$j+1] + $delta[$j];
+        }
+    }
+
+    // Return the two new data vectors
+    function Get($num=50) {
+        $n = $this->n ;
+        $step = ($this->xdata[$n-1]-$this->xdata[0]) / ($num-1);
+        $xnew=array();
+        $ynew=array();
+        $xnew[0] = $this->xdata[0];
+        $ynew[0] = $this->ydata[0];
+        for( $j=1; $j < $num; ++$j ) {
+            $xnew[$j] = $xnew[0]+$j*$step;
+            $ynew[$j] = $this->Interpolate($xnew[$j]);
+        }
+        return array($xnew,$ynew);
+    }
+
+    // Return a single interpolated Y-value from an x value
+    function Interpolate($xpoint) {
+
+        $max = $this->n-1;
+        $min = 0;
+
+        // Binary search to find interval
+        while( $max-$min > 1 ) {
+            $k = ($max+$min) / 2;
+            if( $this->xdata[$k] > $xpoint )
+            $max=$k;
+            else
+            $min=$k;
+        }
+
+        // Each interval is interpolated by a 3:degree polynom function
+        $h = $this->xdata[$max]-$this->xdata[$min];
+
+        if( $h == 0  ) {
+            JpGraphError::RaiseL(19002);
+            //('Invalid input data for spline. Two or more consecutive input X-values are equal. Each input X-value must differ since from a mathematical point of view it must be a one-to-one mapping, i.e. each X-value must correspond to exactly one Y-value.');
+        }
+
+
+        $a = ($this->xdata[$max]-$xpoint)/$h;
+        $b = ($xpoint-$this->xdata[$min])/$h;
+        return $a*$this->ydata[$min]+$b*$this->ydata[$max]+
+        (($a*$a*$a-$a)*$this->y2[$min]+($b*$b*$b-$b)*$this->y2[$max])*($h*$h)/6.0;
+    }
+}
+
+//------------------------------------------------------------------------
+// CLASS Bezier
+// Create a new data array from a number of control points
+//------------------------------------------------------------------------
+class Bezier {
+    /**
+     * @author Thomas Despoix, openXtrem company
+     * @license released under QPL
+     * @abstract Bezier interoplated point generation,
+     * computed from control points data sets, based on Paul Bourke algorithm :
+     * http://local.wasp.uwa.edu.au/~pbourke/geometry/bezier/index2.html
+     */
+    private $datax = array();
+    private $datay = array();
+    private $n=0;
+
+    function __construct($datax, $datay, $attraction_factor = 1) {
+        // Adding control point multiple time will raise their attraction power over the curve
+        $this->n = count($datax);
+        if( $this->n !== count($datay) ) {
+            JpGraphError::RaiseL(19003);
+            //('Bezier: Number of X and Y coordinates must be the same');
+        }
+        $idx=0;
+        foreach($datax as $datumx) {
+            for ($i = 0; $i < $attraction_factor; $i++) {
+                $this->datax[$idx++] = $datumx;
+            }
+        }
+        $idx=0;
+        foreach($datay as $datumy) {
+            for ($i = 0; $i < $attraction_factor; $i++) {
+                $this->datay[$idx++] = $datumy;
+            }
+        }
+        $this->n *= $attraction_factor;
+    }
+
+    /**
+     * Return a set of data points that specifies the bezier curve with $steps points
+     * @param $steps Number of new points to return
+     * @return array($datax, $datay)
+     */
+    function Get($steps) {
+        $datax = array();
+        $datay = array();
+        for ($i = 0; $i < $steps; $i++) {
+            list($datumx, $datumy) = $this->GetPoint((double) $i / (double) $steps);
+            $datax[$i] = $datumx;
+            $datay[$i] = $datumy;
+        }
+         
+        $datax[] = end($this->datax);
+        $datay[] = end($this->datay);
+         
+        return array($datax, $datay);
+    }
+
+    /**
+     * Return one point on the bezier curve. $mu is the position on the curve where $mu is in the
+     * range 0 $mu < 1 where 0 is tha start point and 1 is the end point. Note that every newly computed
+     * point depends on all the existing points
+     * 
+     * @param $mu Position on the bezier curve
+     * @return array($x, $y)
+     */
+    function GetPoint($mu) {
+        $n = $this->n - 1;
+        $k = 0;
+        $kn = 0;
+        $nn = 0;
+        $nkn = 0;
+        $blend = 0.0;
+        $newx = 0.0;
+        $newy = 0.0;
+
+        $muk = 1.0;
+        $munk = (double) pow(1-$mu,(double) $n);
+
+        for ($k = 0; $k <= $n; $k++) {
+            $nn = $n;
+            $kn = $k;
+            $nkn = $n - $k;
+            $blend = $muk * $munk;
+            $muk *= $mu;
+            $munk /= (1-$mu);
+            while ($nn >= 1) {
+                $blend *= $nn;
+                $nn--;
+                if ($kn > 1) {
+                    $blend /= (double) $kn;
+                    $kn--;
+                }
+                if ($nkn > 1) {
+                    $blend /= (double) $nkn;
+                    $nkn--;
+                }
+            }
+            $newx += $this->datax[$k] * $blend;
+            $newy += $this->datay[$k] * $blend;
+        }
+
+        return array($newx, $newy);
+    }
+}
+
+// EOF
+?>
diff --git a/web/classes/jpgraph/jpgraph_rgb.inc.php b/web/classes/jpgraph/jpgraph_rgb.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..53892611e8f2432a705e83b23f1b2802e5e2bc5b
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_rgb.inc.php
@@ -0,0 +1,615 @@
+<?php
+//=======================================================================
+// File:        JPGRAPH_RGB.INC.PHP
+// Description: Class to handle RGb color space specification and
+//              named colors
+// Created:     2001-01-08 (Refactored to separate file 2008-08-01)
+// Ver:         $Id: jpgraph_rgb.inc.php 1893 2009-10-02 23:15:25Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+
+/*===================================================
+// CLASS RGB
+// Description: Color definitions as RGB triples
+//===================================================
+*/
+
+class RGB {
+    public $rgb_table;
+    public $img;
+
+    function __construct($aImg=null) {
+        $this->img = $aImg;
+
+        // Conversion array between color names and RGB
+        $this->rgb_table = array(
+            'aqua'=> array(0,255,255),
+            'lime'=> array(0,255,0),
+            'teal'=> array(0,128,128),
+            'whitesmoke'=>array(245,245,245),
+            'gainsboro'=>array(220,220,220),
+            'oldlace'=>array(253,245,230),
+            'linen'=>array(250,240,230),
+            'antiquewhite'=>array(250,235,215),
+            'papayawhip'=>array(255,239,213),
+            'blanchedalmond'=>array(255,235,205),
+            'bisque'=>array(255,228,196),
+            'peachpuff'=>array(255,218,185),
+            'navajowhite'=>array(255,222,173),
+            'moccasin'=>array(255,228,181),
+            'cornsilk'=>array(255,248,220),
+            'ivory'=>array(255,255,240),
+            'lemonchiffon'=>array(255,250,205),
+            'seashell'=>array(255,245,238),
+            'mintcream'=>array(245,255,250),
+            'azure'=>array(240,255,255),
+            'aliceblue'=>array(240,248,255),
+            'lavender'=>array(230,230,250),
+            'lavenderblush'=>array(255,240,245),
+            'mistyrose'=>array(255,228,225),
+            'white'=>array(255,255,255),
+            'black'=>array(0,0,0),
+            'darkslategray'=>array(47,79,79),
+            'dimgray'=>array(105,105,105),
+            'slategray'=>array(112,128,144),
+            'lightslategray'=>array(119,136,153),
+            'gray'=>array(190,190,190),
+            'lightgray'=>array(211,211,211),
+            'midnightblue'=>array(25,25,112),
+            'navy'=>array(0,0,128),
+            'indigo'=>array(75,0,130),
+            'electricindigo'=>array(102,0,255),
+            'deepindigo'=>array(138,43,226),
+            'pigmentindigo'=>array(75,0,130),
+            'indigodye'=>array(0,65,106),
+            'cornflowerblue'=>array(100,149,237),
+            'darkslateblue'=>array(72,61,139),
+            'slateblue'=>array(106,90,205),
+            'mediumslateblue'=>array(123,104,238),
+            'lightslateblue'=>array(132,112,255),
+            'mediumblue'=>array(0,0,205),
+            'royalblue'=>array(65,105,225),
+            'blue'=>array(0,0,255),
+            'dodgerblue'=>array(30,144,255),
+            'deepskyblue'=>array(0,191,255),
+            'skyblue'=>array(135,206,235),
+            'lightskyblue'=>array(135,206,250),
+            'steelblue'=>array(70,130,180),
+            'lightred'=>array(211,167,168),
+            'lightsteelblue'=>array(176,196,222),
+            'lightblue'=>array(173,216,230),
+            'powderblue'=>array(176,224,230),
+            'paleturquoise'=>array(175,238,238),
+            'darkturquoise'=>array(0,206,209),
+            'mediumturquoise'=>array(72,209,204),
+            'turquoise'=>array(64,224,208),
+            'cyan'=>array(0,255,255),
+            'lightcyan'=>array(224,255,255),
+            'cadetblue'=>array(95,158,160),
+            'mediumaquamarine'=>array(102,205,170),
+            'aquamarine'=>array(127,255,212),
+            'darkgreen'=>array(0,100,0),
+            'darkolivegreen'=>array(85,107,47),
+            'darkseagreen'=>array(143,188,143),
+            'seagreen'=>array(46,139,87),
+            'mediumseagreen'=>array(60,179,113),
+            'lightseagreen'=>array(32,178,170),
+            'palegreen'=>array(152,251,152),
+            'springgreen'=>array(0,255,127),
+            'lawngreen'=>array(124,252,0),
+            'green'=>array(0,255,0),
+            'chartreuse'=>array(127,255,0),
+            'mediumspringgreen'=>array(0,250,154),
+            'greenyellow'=>array(173,255,47),
+            'limegreen'=>array(50,205,50),
+            'yellowgreen'=>array(154,205,50),
+            'forestgreen'=>array(34,139,34),
+            'olivedrab'=>array(107,142,35),
+            'darkkhaki'=>array(189,183,107),
+            'khaki'=>array(240,230,140),
+            'palegoldenrod'=>array(238,232,170),
+            'lightgoldenrodyellow'=>array(250,250,210),
+            'lightyellow'=>array(255,255,200),
+            'yellow'=>array(255,255,0),
+            'gold'=>array(255,215,0),
+            'lightgoldenrod'=>array(238,221,130),
+            'goldenrod'=>array(218,165,32),
+            'darkgoldenrod'=>array(184,134,11),
+            'rosybrown'=>array(188,143,143),
+            'indianred'=>array(205,92,92),
+            'saddlebrown'=>array(139,69,19),
+            'sienna'=>array(160,82,45),
+            'peru'=>array(205,133,63),
+            'burlywood'=>array(222,184,135),
+            'beige'=>array(245,245,220),
+            'wheat'=>array(245,222,179),
+            'sandybrown'=>array(244,164,96),
+            'tan'=>array(210,180,140),
+            'chocolate'=>array(210,105,30),
+            'firebrick'=>array(178,34,34),
+            'brown'=>array(165,42,42),
+            'darksalmon'=>array(233,150,122),
+            'salmon'=>array(250,128,114),
+            'lightsalmon'=>array(255,160,122),
+            'orange'=>array(255,165,0),
+            'darkorange'=>array(255,140,0),
+            'coral'=>array(255,127,80),
+            'lightcoral'=>array(240,128,128),
+            'tomato'=>array(255,99,71),
+            'orangered'=>array(255,69,0),
+            'red'=>array(255,0,0),
+            'hotpink'=>array(255,105,180),
+            'deeppink'=>array(255,20,147),
+            'pink'=>array(255,192,203),
+            'lightpink'=>array(255,182,193),
+            'palevioletred'=>array(219,112,147),
+            'maroon'=>array(176,48,96),
+            'mediumvioletred'=>array(199,21,133),
+            'violetred'=>array(208,32,144),
+            'magenta'=>array(255,0,255),
+            'violet'=>array(238,130,238),
+            'plum'=>array(221,160,221),
+            'orchid'=>array(218,112,214),
+            'mediumorchid'=>array(186,85,211),
+            'darkorchid'=>array(153,50,204),
+            'darkviolet'=>array(148,0,211),
+            'blueviolet'=>array(138,43,226),
+            'purple'=>array(160,32,240),
+            'mediumpurple'=>array(147,112,219),
+            'thistle'=>array(216,191,216),
+            'snow1'=>array(255,250,250),
+            'snow2'=>array(238,233,233),
+            'snow3'=>array(205,201,201),
+            'snow4'=>array(139,137,137),
+            'seashell1'=>array(255,245,238),
+            'seashell2'=>array(238,229,222),
+            'seashell3'=>array(205,197,191),
+            'seashell4'=>array(139,134,130),
+            'AntiqueWhite1'=>array(255,239,219),
+            'AntiqueWhite2'=>array(238,223,204),
+            'AntiqueWhite3'=>array(205,192,176),
+            'AntiqueWhite4'=>array(139,131,120),
+            'bisque1'=>array(255,228,196),
+            'bisque2'=>array(238,213,183),
+            'bisque3'=>array(205,183,158),
+            'bisque4'=>array(139,125,107),
+            'peachPuff1'=>array(255,218,185),
+            'peachpuff2'=>array(238,203,173),
+            'peachpuff3'=>array(205,175,149),
+            'peachpuff4'=>array(139,119,101),
+            'navajowhite1'=>array(255,222,173),
+            'navajowhite2'=>array(238,207,161),
+            'navajowhite3'=>array(205,179,139),
+            'navajowhite4'=>array(139,121,94),
+            'lemonchiffon1'=>array(255,250,205),
+            'lemonchiffon2'=>array(238,233,191),
+            'lemonchiffon3'=>array(205,201,165),
+            'lemonchiffon4'=>array(139,137,112),
+            'ivory1'=>array(255,255,240),
+            'ivory2'=>array(238,238,224),
+            'ivory3'=>array(205,205,193),
+            'ivory4'=>array(139,139,131),
+            'honeydew'=>array(193,205,193),
+            'lavenderblush1'=>array(255,240,245),
+            'lavenderblush2'=>array(238,224,229),
+            'lavenderblush3'=>array(205,193,197),
+            'lavenderblush4'=>array(139,131,134),
+            'mistyrose1'=>array(255,228,225),
+            'mistyrose2'=>array(238,213,210),
+            'mistyrose3'=>array(205,183,181),
+            'mistyrose4'=>array(139,125,123),
+            'azure1'=>array(240,255,255),
+            'azure2'=>array(224,238,238),
+            'azure3'=>array(193,205,205),
+            'azure4'=>array(131,139,139),
+            'slateblue1'=>array(131,111,255),
+            'slateblue2'=>array(122,103,238),
+            'slateblue3'=>array(105,89,205),
+            'slateblue4'=>array(71,60,139),
+            'royalblue1'=>array(72,118,255),
+            'royalblue2'=>array(67,110,238),
+            'royalblue3'=>array(58,95,205),
+            'royalblue4'=>array(39,64,139),
+            'dodgerblue1'=>array(30,144,255),
+            'dodgerblue2'=>array(28,134,238),
+            'dodgerblue3'=>array(24,116,205),
+            'dodgerblue4'=>array(16,78,139),
+            'steelblue1'=>array(99,184,255),
+            'steelblue2'=>array(92,172,238),
+            'steelblue3'=>array(79,148,205),
+            'steelblue4'=>array(54,100,139),
+            'deepskyblue1'=>array(0,191,255),
+            'deepskyblue2'=>array(0,178,238),
+            'deepskyblue3'=>array(0,154,205),
+            'deepskyblue4'=>array(0,104,139),
+            'skyblue1'=>array(135,206,255),
+            'skyblue2'=>array(126,192,238),
+            'skyblue3'=>array(108,166,205),
+            'skyblue4'=>array(74,112,139),
+            'lightskyblue1'=>array(176,226,255),
+            'lightskyblue2'=>array(164,211,238),
+            'lightskyblue3'=>array(141,182,205),
+            'lightskyblue4'=>array(96,123,139),
+            'slategray1'=>array(198,226,255),
+            'slategray2'=>array(185,211,238),
+            'slategray3'=>array(159,182,205),
+            'slategray4'=>array(108,123,139),
+            'lightsteelblue1'=>array(202,225,255),
+            'lightsteelblue2'=>array(188,210,238),
+            'lightsteelblue3'=>array(162,181,205),
+            'lightsteelblue4'=>array(110,123,139),
+            'lightblue1'=>array(191,239,255),
+            'lightblue2'=>array(178,223,238),
+            'lightblue3'=>array(154,192,205),
+            'lightblue4'=>array(104,131,139),
+            'lightcyan1'=>array(224,255,255),
+            'lightcyan2'=>array(209,238,238),
+            'lightcyan3'=>array(180,205,205),
+            'lightcyan4'=>array(122,139,139),
+            'paleturquoise1'=>array(187,255,255),
+            'paleturquoise2'=>array(174,238,238),
+            'paleturquoise3'=>array(150,205,205),
+            'paleturquoise4'=>array(102,139,139),
+            'cadetblue1'=>array(152,245,255),
+            'cadetblue2'=>array(142,229,238),
+            'cadetblue3'=>array(122,197,205),
+            'cadetblue4'=>array(83,134,139),
+            'turquoise1'=>array(0,245,255),
+            'turquoise2'=>array(0,229,238),
+            'turquoise3'=>array(0,197,205),
+            'turquoise4'=>array(0,134,139),
+            'cyan1'=>array(0,255,255),
+            'cyan2'=>array(0,238,238),
+            'cyan3'=>array(0,205,205),
+            'cyan4'=>array(0,139,139),
+            'darkslategray1'=>array(151,255,255),
+            'darkslategray2'=>array(141,238,238),
+            'darkslategray3'=>array(121,205,205),
+            'darkslategray4'=>array(82,139,139),
+            'aquamarine1'=>array(127,255,212),
+            'aquamarine2'=>array(118,238,198),
+            'aquamarine3'=>array(102,205,170),
+            'aquamarine4'=>array(69,139,116),
+            'darkseagreen1'=>array(193,255,193),
+            'darkseagreen2'=>array(180,238,180),
+            'darkseagreen3'=>array(155,205,155),
+            'darkseagreen4'=>array(105,139,105),
+            'seagreen1'=>array(84,255,159),
+            'seagreen2'=>array(78,238,148),
+            'seagreen3'=>array(67,205,128),
+            'seagreen4'=>array(46,139,87),
+            'palegreen1'=>array(154,255,154),
+            'palegreen2'=>array(144,238,144),
+            'palegreen3'=>array(124,205,124),
+            'palegreen4'=>array(84,139,84),
+            'springgreen1'=>array(0,255,127),
+            'springgreen2'=>array(0,238,118),
+            'springgreen3'=>array(0,205,102),
+            'springgreen4'=>array(0,139,69),
+            'chartreuse1'=>array(127,255,0),
+            'chartreuse2'=>array(118,238,0),
+            'chartreuse3'=>array(102,205,0),
+            'chartreuse4'=>array(69,139,0),
+            'olivedrab1'=>array(192,255,62),
+            'olivedrab2'=>array(179,238,58),
+            'olivedrab3'=>array(154,205,50),
+            'olivedrab4'=>array(105,139,34),
+            'darkolivegreen1'=>array(202,255,112),
+            'darkolivegreen2'=>array(188,238,104),
+            'darkolivegreen3'=>array(162,205,90),
+            'darkolivegreen4'=>array(110,139,61),
+            'khaki1'=>array(255,246,143),
+            'khaki2'=>array(238,230,133),
+            'khaki3'=>array(205,198,115),
+            'khaki4'=>array(139,134,78),
+            'lightgoldenrod1'=>array(255,236,139),
+            'lightgoldenrod2'=>array(238,220,130),
+            'lightgoldenrod3'=>array(205,190,112),
+            'lightgoldenrod4'=>array(139,129,76),
+            'yellow1'=>array(255,255,0),
+            'yellow2'=>array(238,238,0),
+            'yellow3'=>array(205,205,0),
+            'yellow4'=>array(139,139,0),
+            'gold1'=>array(255,215,0),
+            'gold2'=>array(238,201,0),
+            'gold3'=>array(205,173,0),
+            'gold4'=>array(139,117,0),
+            'goldenrod1'=>array(255,193,37),
+            'goldenrod2'=>array(238,180,34),
+            'goldenrod3'=>array(205,155,29),
+            'goldenrod4'=>array(139,105,20),
+            'darkgoldenrod1'=>array(255,185,15),
+            'darkgoldenrod2'=>array(238,173,14),
+            'darkgoldenrod3'=>array(205,149,12),
+            'darkgoldenrod4'=>array(139,101,8),
+            'rosybrown1'=>array(255,193,193),
+            'rosybrown2'=>array(238,180,180),
+            'rosybrown3'=>array(205,155,155),
+            'rosybrown4'=>array(139,105,105),
+            'indianred1'=>array(255,106,106),
+            'indianred2'=>array(238,99,99),
+            'indianred3'=>array(205,85,85),
+            'indianred4'=>array(139,58,58),
+            'sienna1'=>array(255,130,71),
+            'sienna2'=>array(238,121,66),
+            'sienna3'=>array(205,104,57),
+            'sienna4'=>array(139,71,38),
+            'burlywood1'=>array(255,211,155),
+            'burlywood2'=>array(238,197,145),
+            'burlywood3'=>array(205,170,125),
+            'burlywood4'=>array(139,115,85),
+            'wheat1'=>array(255,231,186),
+            'wheat2'=>array(238,216,174),
+            'wheat3'=>array(205,186,150),
+            'wheat4'=>array(139,126,102),
+            'tan1'=>array(255,165,79),
+            'tan2'=>array(238,154,73),
+            'tan3'=>array(205,133,63),
+            'tan4'=>array(139,90,43),
+            'chocolate1'=>array(255,127,36),
+            'chocolate2'=>array(238,118,33),
+            'chocolate3'=>array(205,102,29),
+            'chocolate4'=>array(139,69,19),
+            'firebrick1'=>array(255,48,48),
+            'firebrick2'=>array(238,44,44),
+            'firebrick3'=>array(205,38,38),
+            'firebrick4'=>array(139,26,26),
+            'brown1'=>array(255,64,64),
+            'brown2'=>array(238,59,59),
+            'brown3'=>array(205,51,51),
+            'brown4'=>array(139,35,35),
+            'salmon1'=>array(255,140,105),
+            'salmon2'=>array(238,130,98),
+            'salmon3'=>array(205,112,84),
+            'salmon4'=>array(139,76,57),
+            'lightsalmon1'=>array(255,160,122),
+            'lightsalmon2'=>array(238,149,114),
+            'lightsalmon3'=>array(205,129,98),
+            'lightsalmon4'=>array(139,87,66),
+            'orange1'=>array(255,165,0),
+            'orange2'=>array(238,154,0),
+            'orange3'=>array(205,133,0),
+            'orange4'=>array(139,90,0),
+            'darkorange1'=>array(255,127,0),
+            'darkorange2'=>array(238,118,0),
+            'darkorange3'=>array(205,102,0),
+            'darkorange4'=>array(139,69,0),
+            'coral1'=>array(255,114,86),
+            'coral2'=>array(238,106,80),
+            'coral3'=>array(205,91,69),
+            'coral4'=>array(139,62,47),
+            'tomato1'=>array(255,99,71),
+            'tomato2'=>array(238,92,66),
+            'tomato3'=>array(205,79,57),
+            'tomato4'=>array(139,54,38),
+            'orangered1'=>array(255,69,0),
+            'orangered2'=>array(238,64,0),
+            'orangered3'=>array(205,55,0),
+            'orangered4'=>array(139,37,0),
+            'deeppink1'=>array(255,20,147),
+            'deeppink2'=>array(238,18,137),
+            'deeppink3'=>array(205,16,118),
+            'deeppink4'=>array(139,10,80),
+            'hotpink1'=>array(255,110,180),
+            'hotpink2'=>array(238,106,167),
+            'hotpink3'=>array(205,96,144),
+            'hotpink4'=>array(139,58,98),
+            'pink1'=>array(255,181,197),
+            'pink2'=>array(238,169,184),
+            'pink3'=>array(205,145,158),
+            'pink4'=>array(139,99,108),
+            'lightpink1'=>array(255,174,185),
+            'lightpink2'=>array(238,162,173),
+            'lightpink3'=>array(205,140,149),
+            'lightpink4'=>array(139,95,101),
+            'palevioletred1'=>array(255,130,171),
+            'palevioletred2'=>array(238,121,159),
+            'palevioletred3'=>array(205,104,137),
+            'palevioletred4'=>array(139,71,93),
+            'maroon1'=>array(255,52,179),
+            'maroon2'=>array(238,48,167),
+            'maroon3'=>array(205,41,144),
+            'maroon4'=>array(139,28,98),
+            'violetred1'=>array(255,62,150),
+            'violetred2'=>array(238,58,140),
+            'violetred3'=>array(205,50,120),
+            'violetred4'=>array(139,34,82),
+            'magenta1'=>array(255,0,255),
+            'magenta2'=>array(238,0,238),
+            'magenta3'=>array(205,0,205),
+            'magenta4'=>array(139,0,139),
+            'mediumred'=>array(140,34,34),
+            'orchid1'=>array(255,131,250),
+            'orchid2'=>array(238,122,233),
+            'orchid3'=>array(205,105,201),
+            'orchid4'=>array(139,71,137),
+            'plum1'=>array(255,187,255),
+            'plum2'=>array(238,174,238),
+            'plum3'=>array(205,150,205),
+            'plum4'=>array(139,102,139),
+            'mediumorchid1'=>array(224,102,255),
+            'mediumorchid2'=>array(209,95,238),
+            'mediumorchid3'=>array(180,82,205),
+            'mediumorchid4'=>array(122,55,139),
+            'darkorchid1'=>array(191,62,255),
+            'darkorchid2'=>array(178,58,238),
+            'darkorchid3'=>array(154,50,205),
+            'darkorchid4'=>array(104,34,139),
+            'purple1'=>array(155,48,255),
+            'purple2'=>array(145,44,238),
+            'purple3'=>array(125,38,205),
+            'purple4'=>array(85,26,139),
+            'mediumpurple1'=>array(171,130,255),
+            'mediumpurple2'=>array(159,121,238),
+            'mediumpurple3'=>array(137,104,205),
+            'mediumpurple4'=>array(93,71,139),
+            'thistle1'=>array(255,225,255),
+            'thistle2'=>array(238,210,238),
+            'thistle3'=>array(205,181,205),
+            'thistle4'=>array(139,123,139),
+            'gray1'=>array(10,10,10),
+            'gray2'=>array(40,40,30),
+            'gray3'=>array(70,70,70),
+            'gray4'=>array(100,100,100),
+            'gray5'=>array(130,130,130),
+            'gray6'=>array(160,160,160),
+            'gray7'=>array(190,190,190),
+            'gray8'=>array(210,210,210),
+            'gray9'=>array(240,240,240),
+            'darkgray'=>array(100,100,100),
+            'darkblue'=>array(0,0,139),
+            'darkcyan'=>array(0,139,139),
+            'darkmagenta'=>array(139,0,139),
+            'darkred'=>array(139,0,0),
+            'silver'=>array(192, 192, 192),
+            'eggplant'=>array(144,176,168),
+            'lightgreen'=>array(144,238,144));
+    }
+
+
+    //----------------
+    // PUBLIC METHODS
+    // Colors can be specified as either
+    // 1. #xxxxxx   HTML style
+    // 2. "colorname"  as a named color
+    // 3. array(r,g,b) RGB triple
+    // This function translates this to a native RGB format and returns an
+    // RGB triple.
+
+    function Color($aColor) {
+        if (is_string($aColor)) {
+            $matches = array();
+            // this regex will parse a color string and fill the $matches array as such:
+            // 0: the full match if any
+            // 1: a hex string preceded by a hash, can be 3 characters (#fff) or 6 (#ffffff) (4 or 5 also accepted but...)
+            // 2,3,4: r,g,b values in hex if the first character of the string is #
+            // 5: all alpha-numeric characters at the beginning of the string if string does not start with #
+            // 6: alpha value prefixed by @ if supplied
+            // 7: alpha value with @ stripped
+            // 8: adjust value prefixed with : if supplied
+            // 9: adjust value with : stripped
+            $regex = '/(#([0-9a-fA-F]{1,2})([0-9a-fA-F]{1,2})([0-9a-fA-F]{1,2}))?([\w]+)?(@([\d\.,]+))?(:([\d\.,]+))?/';
+            if(!preg_match($regex, $aColor, $matches)) {
+                JpGraphError::RaiseL(25078,$aColor);//(" Unknown color: $aColor");
+            }
+            if(empty($matches[5])) {
+                $r = strlen($matches[2]) == 1 ? $matches[2].$matches[2] : $matches[2];
+                $g = strlen($matches[3]) == 1 ? $matches[3].$matches[3] : $matches[3];
+                $b = strlen($matches[4]) == 1 ? $matches[4].$matches[4] : $matches[4];
+                $r = hexdec($r);
+                $g = hexdec($g);
+                $b = hexdec($b);
+            }else {
+                if(!isset($this->rgb_table[$matches[5]]) ) {
+                    JpGraphError::RaiseL(25078,$aColor);//(" Unknown color: $aColor");
+                }
+                $r = $this->rgb_table[$matches[5]][0];
+                $g = $this->rgb_table[$matches[5]][1];
+                $b = $this->rgb_table[$matches[5]][2];
+            }
+            $alpha	= isset($matches[7]) ? str_replace(',','.',$matches[7]) : 0;
+            $adj	= isset($matches[9]) ? str_replace(',','.',$matches[9]) : 1.0;
+
+            if( $adj < 0 ) {
+                JpGraphError::RaiseL(25077);//('Adjustment factor for color must be > 0');
+            }
+
+            // Scale adj so that an adj=2 always
+            // makes the color 100% white (i.e. 255,255,255.
+            // and adj=1 neutral and adj=0 black.
+            if( $adj == 1) {
+                return array($r,$g,$b,$alpha);
+            }
+            elseif( $adj > 1 ) {
+                $m = ($adj-1.0)*(255-min(255,min($r,min($g,$b))));
+                return array(min(255,$r+$m), min(255,$g+$m), min(255,$b+$m),$alpha);
+            }
+            elseif( $adj < 1 ) {
+                $m = ($adj-1.0)*max(255,max($r,max($g,$b)));
+                return array(max(0,$r+$m), max(0,$g+$m), max(0,$b+$m),$alpha);
+            }
+        } elseif( is_array($aColor) ) {
+            if(!isset($aColor[3])) $aColor[3] = 0;
+            return $aColor;
+        }
+        else {
+            JpGraphError::RaiseL(25079,$aColor,count($aColor));//(" Unknown color specification: $aColor , size=".count($aColor));
+        }
+    }
+
+    // Compare two colors
+    // return true if equal
+    function Equal($aCol1,$aCol2) {
+        $c1 = $this->Color($aCol1);
+        $c2 = $this->Color($aCol2);
+        return $c1[0]==$c2[0] && $c1[1]==$c2[1] && $c1[2]==$c2[2] ;
+    }
+
+    // Allocate a new color in the current image
+    // Return new color index, -1 if no more colors could be allocated
+    function Allocate($aColor,$aAlpha=0.0) {
+        list ($r, $g, $b, $a) = $this->color($aColor);
+        // If alpha is specified in the color string then this
+        // takes precedence over the second argument
+        if( $a > 0 ) {
+            $aAlpha = $a;
+        }
+        if( $aAlpha < 0 || $aAlpha > 1 ) {
+            JpGraphError::RaiseL(25080);//('Alpha parameter for color must be between 0.0 and 1.0');
+        }
+        return imagecolorresolvealpha($this->img, $r, $g, $b, round($aAlpha * 127));
+    }
+
+    // Try to convert an array with three valid numbers to the corresponding hex array
+    // This is currenly only used in processing the colors for barplots in order to be able
+    // to handle the case where the color might be specified as an array of colros as well.
+    // In that case we must be able to find out if an array of values should be interpretated as
+    // a single color (specifeid as an RGB triple)
+    static function tryHexConversion($aColor) {
+        if( is_array( $aColor ) ) {
+            if( count( $aColor ) == 3 ) {
+                if( is_numeric($aColor[0]) && is_numeric($aColor[1]) && is_numeric($aColor[2]) ) {
+                    if( ($aColor[0] >= 0 && $aColor[0] <= 255) &&
+                        ($aColor[1] >= 0 && $aColor[1] <= 255) &&
+                        ($aColor[2] >= 0 && $aColor[2] <= 255) ) {
+                        return sprintf('#%02x%02x%02x',$aColor[0],$aColor[1],$aColor[2]);
+                    }
+                }
+            }
+        }
+        return $aColor;
+    }
+
+    // Return a RGB tripple corresponding to a position in the normal light spectrum
+    // The argumen values is in the range [0, 1] where a value of 0 correponds to blue and
+    // a value of 1 corresponds to red. Values in betwen is mapped to a linear interpolation
+    // of the constituting colors in the visible color spectra.
+    // The $aDynamicRange specified how much of the dynamic range we shold use
+    // a value of 1.0 give the full dyanmic range and a lower value give more dark
+    // colors. In the extreme of 0.0 then all colors will be black.
+    static function GetSpectrum($aVal,$aDynamicRange=1.0) {
+        if( $aVal < 0 || $aVal > 1.0001 ) {
+            return array(0,0,0); // Invalid case - just return black
+        }
+
+        $sat = round(255*$aDynamicRange);
+        $a = 0.25;
+        if( $aVal <= 0.25 ) {
+            return array(0, round($sat*$aVal/$a), $sat);
+        }
+        elseif( $aVal <= 0.5 ) {
+            return array(0, $sat, round($sat-$sat*($aVal-0.25)/$a));
+        }
+        elseif( $aVal <= 0.75 ) {
+            return array(round($sat*($aVal-0.5)/$a), $sat, 0);
+        }
+        else {
+            return array($sat, round($sat-$sat*($aVal-0.75)/$a), 0);
+        }
+    }
+
+} // Class
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_scatter.php b/web/classes/jpgraph/jpgraph_scatter.php
new file mode 100755
index 0000000000000000000000000000000000000000..fe987c2c9ed1595526a01ae71ac64698c43df0ef
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_scatter.php
@@ -0,0 +1,242 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_SCATTER.PHP
+ // Description: Scatter (and impuls) plot extension for JpGraph
+ // Created:     2001-02-11
+ // Ver:         $Id: jpgraph_scatter.php 1397 2009-06-27 21:34:14Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+require_once ('jpgraph_plotmark.inc.php');
+
+//===================================================
+// CLASS FieldArrow
+// Description: Draw an arrow at (x,y) with angle a
+//===================================================
+class FieldArrow {
+    public $iColor='black';
+    public $iSize=10;  // Length in pixels for  arrow
+    public $iArrowSize = 2;
+    private $isizespec = array(
+    	array(2,1),array(3,2),array(4,3),array(6,4),array(7,4),array(8,5),array(10,6),array(12,7),array(16,8),array(20,10)
+    	);
+    function __construct() {
+    	// Empty
+    }
+
+    function SetSize($aSize,$aArrowSize=2) {
+        $this->iSize = $aSize;
+        $this->iArrowSize = $aArrowSize;
+    }
+
+    function SetColor($aColor) {
+        $this->iColor = $aColor;
+    }
+
+    function Stroke($aImg,$x,$y,$a) {
+        // First rotate the center coordinates
+        list($x,$y) = $aImg->Rotate($x,$y);
+
+        $old_origin = $aImg->SetCenter($x,$y);
+        $old_a = $aImg->a;
+        $aImg->SetAngle(-$a+$old_a);
+
+        $dx = round($this->iSize/2);
+        $c = array($x-$dx,$y,$x+$dx,$y);
+        $x += $dx;
+
+        list($dx,$dy) = $this->isizespec[$this->iArrowSize];
+        $ca = array($x,$y,$x-$dx,$y-$dy,$x-$dx,$y+$dy,$x,$y);
+
+        $aImg->SetColor($this->iColor);
+        $aImg->Polygon($c);
+        $aImg->FilledPolygon($ca);
+
+        $aImg->SetCenter($old_origin[0],$old_origin[1]);
+        $aImg->SetAngle($old_a);
+    }
+}
+
+//===================================================
+// CLASS FieldPlot
+// Description: Render a field plot
+//===================================================
+class FieldPlot extends Plot {
+    public $arrow = '';
+    private $iAngles = array();
+    private $iCallback = '';
+
+    function __construct($datay,$datax,$angles) {
+        if( (count($datax) != count($datay)) )
+        JpGraphError::RaiseL(20001);//("Fieldplots must have equal number of X and Y points.");
+        if( (count($datax) != count($angles)) )
+        JpGraphError::RaiseL(20002);//("Fieldplots must have an angle specified for each X and Y points.");
+
+        $this->iAngles = $angles;
+
+        parent::__construct($datay,$datax);
+        $this->value->SetAlign('center','center');
+        $this->value->SetMargin(15);
+
+        $this->arrow = new FieldArrow();
+    }
+
+    function SetCallback($aFunc) {
+        $this->iCallback = $aFunc;
+    }
+
+    function Stroke($img,$xscale,$yscale) {
+
+        // Remeber base color and size
+        $bc = $this->arrow->iColor;
+        $bs = $this->arrow->iSize;
+        $bas = $this->arrow->iArrowSize;
+
+        for( $i=0; $i<$this->numpoints; ++$i ) {
+            // Skip null values
+            if( $this->coords[0][$i]==="" )
+            continue;
+
+            $f = $this->iCallback;
+            if( $f != "" ) {
+                list($cc,$cs,$cas) = call_user_func($f,$this->coords[1][$i],$this->coords[0][$i],$this->iAngles[$i]);
+                // Fall back on global data if the callback isn't set
+                if( $cc  == "" ) $cc = $bc;
+                if( $cs  == "" ) $cs = $bs;
+                if( $cas == "" ) $cas = $bas;
+                $this->arrow->SetColor($cc);
+                $this->arrow->SetSize($cs,$cas);
+            }
+
+            $xt = $xscale->Translate($this->coords[1][$i]);
+            $yt = $yscale->Translate($this->coords[0][$i]);
+
+            $this->arrow->Stroke($img,$xt,$yt,$this->iAngles[$i]);
+            $this->value->Stroke($img,$this->coords[0][$i],$xt,$yt);
+        }
+    }
+
+    // Framework function
+    function Legend($aGraph) {
+        if( $this->legend != "" ) {
+            $aGraph->legend->Add($this->legend,$this->mark->fill_color,$this->mark,0,
+            $this->legendcsimtarget,$this->legendcsimalt,$this->legendcsimwintarget);
+        }
+    }
+}
+
+//===================================================
+// CLASS ScatterPlot
+// Description: Render X and Y plots
+//===================================================
+class ScatterPlot extends Plot {
+    public $mark,$link;
+    private $impuls = false;
+    //---------------
+    // CONSTRUCTOR
+    function __construct($datay,$datax=false) {
+        if( (count($datax) != count($datay)) && is_array($datax)) {
+        	JpGraphError::RaiseL(20003);//("Scatterplot must have equal number of X and Y points.");
+        }
+        parent::__construct($datay,$datax);
+        $this->mark = new PlotMark();
+        $this->mark->SetType(MARK_SQUARE);
+        $this->mark->SetColor($this->color);
+        $this->value->SetAlign('center','center');
+        $this->value->SetMargin(0);
+        $this->link = new LineProperty(1,'black','solid');
+        $this->link->iShow = false;
+    }
+
+    //---------------
+    // PUBLIC METHODS
+    function SetImpuls($f=true) {
+        $this->impuls = $f;
+    }
+
+    function SetStem($f=true) {
+        $this->impuls = $f;
+    }
+
+    // Combine the scatter plot points with a line
+    function SetLinkPoints($aFlag=true,$aColor="black",$aWeight=1,$aStyle='solid') {
+    	$this->link->iShow = $aFlag;
+    	$this->link->iColor = $aColor;
+    	$this->link->iWeight = $aWeight;
+    	$this->link->iStyle = $aStyle;
+    }
+
+    function Stroke($img,$xscale,$yscale) {
+
+        $ymin=$yscale->scale_abs[0];
+        if( $yscale->scale[0] < 0 )
+        $yzero=$yscale->Translate(0);
+        else
+        $yzero=$yscale->scale_abs[0];
+
+        $this->csimareas = '';
+        for( $i=0; $i<$this->numpoints; ++$i ) {
+
+            // Skip null values
+            if( $this->coords[0][$i]==='' || $this->coords[0][$i]==='-' || $this->coords[0][$i]==='x')
+            continue;
+
+            if( isset($this->coords[1]) )
+            $xt = $xscale->Translate($this->coords[1][$i]);
+            else
+            $xt = $xscale->Translate($i);
+            $yt = $yscale->Translate($this->coords[0][$i]);
+
+
+            if( $this->link->iShow && isset($yt_old) ) {
+                $img->SetColor($this->link->iColor);
+                $img->SetLineWeight($this->link->iWeight);
+                $old = $img->SetLineStyle($this->link->iStyle);
+                $img->StyleLine($xt_old,$yt_old,$xt,$yt);
+                $img->SetLineStyle($old);
+            }
+
+            if( $this->impuls ) {
+                $img->SetColor($this->color);
+                $img->SetLineWeight($this->weight);
+                $img->Line($xt,$yzero,$xt,$yt);
+            }
+
+            if( !empty($this->csimtargets[$i]) ) {
+                if( !empty($this->csimwintargets[$i]) ) {
+                    $this->mark->SetCSIMTarget($this->csimtargets[$i],$this->csimwintargets[$i]);
+                }
+                else {
+                    $this->mark->SetCSIMTarget($this->csimtargets[$i]);
+                }
+                $this->mark->SetCSIMAlt($this->csimalts[$i]);
+            }
+
+            if( isset($this->coords[1]) ) {
+                $this->mark->SetCSIMAltVal($this->coords[0][$i],$this->coords[1][$i]);
+            }
+            else {
+                $this->mark->SetCSIMAltVal($this->coords[0][$i],$i);
+            }
+
+            $this->mark->Stroke($img,$xt,$yt);
+
+            $this->csimareas .= $this->mark->GetCSIMAreas();
+            $this->value->Stroke($img,$this->coords[0][$i],$xt,$yt);
+
+            $xt_old = $xt;
+            $yt_old = $yt;
+        }
+    }
+
+    // Framework function
+    function Legend($aGraph) {
+        if( $this->legend != "" ) {
+            $aGraph->legend->Add($this->legend,$this->mark->fill_color,$this->mark,0,
+            $this->legendcsimtarget,$this->legendcsimalt,$this->legendcsimwintarget);
+        }
+    }
+} // Class
+/* EOF */
+?>
diff --git a/web/classes/jpgraph/jpgraph_stock.php b/web/classes/jpgraph/jpgraph_stock.php
new file mode 100755
index 0000000000000000000000000000000000000000..88c420848a0431d05e6f1c16a44519309e32ff47
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_stock.php
@@ -0,0 +1,198 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_STOCK.PHP
+ // Description: Stock plot extension for JpGraph
+ // Created:     2003-01-27
+ // Ver:         $Id: jpgraph_stock.php 1364 2009-06-24 07:07:44Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+//===================================================
+// CLASS StockPlot
+//===================================================
+class StockPlot extends Plot {
+    protected $iTupleSize = 4;
+    private $iWidth=9;
+    private $iEndLines=1;
+    private $iStockColor1='white',$iStockColor2='darkred',$iStockColor3='darkred';
+    //---------------
+    // CONSTRUCTOR
+    function __construct($datay,$datax=false) {
+        if( count($datay) % $this->iTupleSize ) {
+            JpGraphError::RaiseL(21001,$this->iTupleSize);
+            //('Data values for Stock charts must contain an even multiple of '.$this->iTupleSize.' data points.');
+        }
+        parent::__construct($datay,$datax);
+        $this->numpoints /= $this->iTupleSize;
+    }
+    //---------------
+    // PUBLIC METHODS
+
+    function SetColor($aColor,$aColor1='white',$aColor2='darkred',$aColor3='darkred') {
+        $this->color = $aColor;
+        $this->iStockColor1 = $aColor1;
+        $this->iStockColor2 = $aColor2;
+        $this->iStockColor3 = $aColor3;
+    }
+
+    function SetWidth($aWidth) {
+        // Make sure it's odd
+        $this->iWidth = 2*floor($aWidth/2)+1;
+    }
+
+    function HideEndLines($aHide=true) {
+        $this->iEndLines = !$aHide;
+    }
+
+    // Gets called before any axis are stroked
+    function PreStrokeAdjust($graph) {
+        if( $this->center ) {
+            $a=0.5; $b=0.5;
+            $this->numpoints++;
+        } else {
+            $a=0; $b=0;
+        }
+        $graph->xaxis->scale->ticks->SetXLabelOffset($a);
+        $graph->SetTextScaleOff($b);
+    }
+
+    // Method description
+    function Stroke($img,$xscale,$yscale) {
+        $n=$this->numpoints;
+        if( $this->center ) $n--;
+        if( isset($this->coords[1]) ) {
+            if( count($this->coords[1])!=$n ) {
+                JpGraphError::RaiseL(2003,count($this->coords[1]),$n);
+                // ("Number of X and Y points are not equal. Number of X-points:".count($this->coords[1])." Number of Y-points:$numpoints");
+            }
+            else {
+                $exist_x = true;
+            }
+        }
+        else {
+            $exist_x = false;
+        }
+
+        if( $exist_x ) {
+            $xs=$this->coords[1][0];
+        }
+        else {
+            $xs=0;
+        }
+
+        $ts = $this->iTupleSize;
+        $this->csimareas = '';
+        for( $i=0; $i<$n; ++$i) {
+
+            //If value is NULL, then don't draw a bar at all
+            if ($this->coords[0][$i*$ts] === null) continue;
+
+            if( $exist_x ) {
+                $x=$this->coords[1][$i];
+				if ($x === null) continue;
+            }
+            else {
+                $x=$i;
+            }
+            $xt = $xscale->Translate($x);
+
+            $neg = $this->coords[0][$i*$ts] > $this->coords[0][$i*$ts+1] ;
+            $yopen  = $yscale->Translate($this->coords[0][$i*$ts]);
+            $yclose = $yscale->Translate($this->coords[0][$i*$ts+1]);
+            $ymin   = $yscale->Translate($this->coords[0][$i*$ts+2]);
+            $ymax   = $yscale->Translate($this->coords[0][$i*$ts+3]);
+
+            $dx = floor($this->iWidth/2);
+            $xl = $xt - $dx;
+            $xr = $xt + $dx;
+
+            if( $neg ) {
+                $img->SetColor($this->iStockColor3);
+            }
+            else {
+                $img->SetColor($this->iStockColor1);
+            }
+            $img->FilledRectangle($xl,$yopen,$xr,$yclose);
+            $img->SetLineWeight($this->weight);
+            if( $neg ) {
+                $img->SetColor($this->iStockColor2);
+            }
+            else {
+                $img->SetColor($this->color);
+            }
+
+            $img->Rectangle($xl,$yopen,$xr,$yclose);
+
+            if( $yopen < $yclose ) {
+                $ytop = $yopen ;
+                $ybottom = $yclose ;
+            }
+            else {
+                $ytop = $yclose ;
+                $ybottom = $yopen ;
+            }
+            $img->SetColor($this->color);
+            $img->Line($xt,$ytop,$xt,$ymax);
+            $img->Line($xt,$ybottom,$xt,$ymin);
+
+            if( $this->iEndLines ) {
+                $img->Line($xl,$ymax,$xr,$ymax);
+                $img->Line($xl,$ymin,$xr,$ymin);
+            }
+
+            // A chance for subclasses to add things to the bar
+            // for data point i
+            $this->ModBox($img,$xscale,$yscale,$i,$xl,$xr,$neg);
+
+            // Setup image maps
+            if( !empty($this->csimtargets[$i]) ) {
+                $this->csimareas.= '<area shape="rect" coords="'.
+                round($xl).','.round($ytop).','.
+                round($xr).','.round($ybottom).'" ';
+                $this->csimareas .= ' href="'.$this->csimtargets[$i].'"';
+                if( !empty($this->csimalts[$i]) ) {
+                    $sval=$this->csimalts[$i];
+                    $this->csimareas .= " title=\"$sval\" alt=\"$sval\" ";
+                }
+                $this->csimareas.= "  />\n";
+            }
+        }
+        return true;
+    }
+
+    // A hook for subclasses to modify the plot
+    function ModBox($img,$xscale,$yscale,$i,$xl,$xr,$neg) {}
+
+} // Class
+
+//===================================================
+// CLASS BoxPlot
+//===================================================
+class BoxPlot extends StockPlot {
+    private $iPColor='black',$iNColor='white';
+
+    function __construct($datay,$datax=false) {
+        $this->iTupleSize=5;
+        parent::__construct($datay,$datax);
+    }
+
+    function SetMedianColor($aPos,$aNeg) {
+        $this->iPColor = $aPos;
+        $this->iNColor = $aNeg;
+    }
+
+    function ModBox($img,$xscale,$yscale,$i,$xl,$xr,$neg) {
+        if( $neg )
+        $img->SetColor($this->iNColor);
+        else
+        $img->SetColor($this->iPColor);
+
+        $y = $yscale->Translate($this->coords[0][$i*5+4]);
+        $img->Line($xl,$y,$xr,$y);
+    }
+}
+
+/* EOF */
+?>
diff --git a/web/classes/jpgraph/jpgraph_table.php b/web/classes/jpgraph/jpgraph_table.php
new file mode 100755
index 0000000000000000000000000000000000000000..852d78b0213a2187e3b4269f1bc34782cbe879fe
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_table.php
@@ -0,0 +1,1325 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_TABLE.PHP
+ // Description: Classes to create basic tables of data
+ // Created:     2006-01-25
+ // Ver:         $Id: jpgraph_table.php 1514 2009-07-07 11:15:58Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+// Style of grid lines in table
+DEFINE('TGRID_SINGLE',1);
+DEFINE('TGRID_DOUBLE',2);
+DEFINE('TGRID_DOUBLE2',3);
+
+// Type of constrain for image constrain
+DEFINE('TIMG_WIDTH',1);
+DEFINE('TIMG_HEIGHT',2);
+
+//---------------------------------------------------------------------
+// CLASS GTextTableCell
+// Description:
+// Internal class that represents each cell in the table
+//---------------------------------------------------------------------
+class GTextTableCell {
+    public $iColSpan=1,$iRowSpan=1;
+    public $iMarginLeft=5,$iMarginRight=5,$iMarginTop=5,$iMarginBottom=5;
+    public $iVal=NULL;
+    private $iBGColor='', $iFontColor='black';
+    private $iFF=FF_FONT1,$iFS=FS_NORMAL,$iFSize=10;
+    private $iRow=0, $iCol=0;
+    private $iVertAlign = 'bottom', $iHorAlign = 'left';
+    private $iMerged=FALSE,$iPRow=NULL,$iPCol=NULL;
+    private $iTable=NULL;
+    private $iGridColor=array('darkgray','darkgray','darkgray','darkgray');
+    private $iGridWeight=array(1,1,0,0); // left,top,bottom,right;
+    private $iGridStyle=array(TGRID_SINGLE,TGRID_SINGLE,TGRID_SINGLE,TGRID_SINGLE); // left,top,bottom,right;
+    private $iNumberFormat=null;
+    private $iIcon=null, $iIconConstrain=array();
+    private $iCSIMtarget = '',$iCSIMwintarget = '', $iCSIMalt = '', $iCSIMArea = '';
+
+    function __construct($aVal='',$aRow=0,$aCol=0) {
+        $this->iVal = new Text($aVal);
+        $this->iRow = $aRow;
+        $this->iCol = $aCol;
+        $this->iPRow = $aRow; // Initialiy each cell is its own parent
+        $this->iPCol = $aCol;
+        $this->iIconConstrain = array(-1,-1);
+    }
+
+    function Init($aTable) {
+        $this->iTable = $aTable;
+    }
+
+    function SetCSIMTarget($aTarget,$aAlt='',$aWinTarget='') {
+        $this->iCSIMtarget = $aTarget;
+        $this->iCSIMwintarget = $aWinTarget;
+        $this->iCSIMalt = $aAlt;
+    }
+
+    function GetCSIMArea() {
+        if( $this->iCSIMtarget !== '' )
+        return $this->iCSIMArea;
+        else
+        return '';
+    }
+
+    function SetImageConstrain($aType,$aVal) {
+        if( !in_array($aType,array(TIMG_WIDTH, TIMG_HEIGHT)) ) {
+            JpGraphError::RaiseL(27015);
+        }
+        $this->iIconConstrain = array($aType,$aVal);
+    }
+
+    function SetCountryFlag($aFlag,$aScale=1.0,$aMix=100,$aStdSize=3) {
+        $this->iIcon = new IconPlot();
+        $this->iIcon->SetCountryFlag($aFlag,0,0,$aScale,$aMix,$aStdSize);
+    }
+
+    function SetImage($aFile,$aScale=1.0,$aMix=100) {
+        $this->iIcon = new IconPlot($aFile,0,0,$aScale,$aMix);
+    }
+
+    function SetImageFromString($aStr,$aScale=1.0,$aMix=100) {
+        $this->iIcon = new IconPlot("",0,0,$aScale,$aMix);
+        $this->iIcon->CreateFromString($aStr);
+    }
+
+    function SetRowColSpan($aRowSpan,$aColSpan) {
+        $this->iRowSpan = $aRowSpan;
+        $this->iColSpan = $aColSpan;
+        $this->iMerged = true;
+    }
+
+    function SetMerged($aPRow,$aPCol,$aFlg=true) {
+        $this->iMerged = $aFlg;
+        $this->iPRow=$aPRow;
+        $this->iPCol=$aPCol;
+    }
+
+    function IsMerged() {
+        return $this->iMerged;
+    }
+
+    function SetNumberFormat($aF) {
+        $this->iNumberFormat = $aF;
+    }
+
+    function Set($aTxt) {
+        $this->iVal->Set($aTxt);
+    }
+
+    function SetFont($aFF,$aFS,$aFSize) {
+        $this->iFF = $aFF;
+        $this->iFS = $aFS;
+        $this->iFSize = $aFSize;
+        $this->iVal->SetFont($aFF,$aFS,$aFSize);
+    }
+
+    function SetFillColor($aColor) {
+        $this->iBGColor=$aColor;
+    }
+
+    function SetFontColor($aColor) {
+        $this->iFontColor=$aColor;
+    }
+
+    function SetGridColor($aLeft,$aTop=null,$aBottom=null,$aRight=null) {
+        if( $aLeft !== null ) $this->iGridColor[0] = $aLeft;
+        if( $aTop !== null ) $this->iGridColor[1] = $aTop;
+        if( $aBottom !== null ) $this->iGridColor[2] = $aBottom;
+        if( $aRight !== null )$this->iGridColor[3] = $aRight;
+    }
+
+    function SetGridStyle($aLeft,$aTop=null,$aBottom=null,$aRight=null) {
+        if( $aLeft !== null ) $this->iGridStyle[0] = $aLeft;
+        if( $aTop !== null ) $this->iGridStyle[1] = $aTop;
+        if( $aBottom !== null ) $this->iGridStyle[2] = $aBottom;
+        if( $aRight !== null )$this->iGridStyle[3] = $aRight;
+    }
+
+    function SetGridWeight($aLeft=null,$aTop=null,$aBottom=null,$aRight=null) {
+        if( $aLeft !== null ) $this->iGridWeight[0] = $aLeft;
+        if( $aTop !== null ) $this->iGridWeight[1] = $aTop;
+        if( $aBottom !== null ) $this->iGridWeight[2] = $aBottom;
+        if( $aRight !== null ) $this->iGridWeight[3] = $aRight;
+    }
+
+    function SetMargin($aLeft,$aRight,$aTop,$aBottom) {
+        $this->iMarginLeft=$aLeft;
+        $this->iMarginRight=$aRight;
+        $this->iMarginTop=$aTop;
+        $this->iMarginBottom=$aBottom;
+    }
+
+    function GetWidth($aImg) {
+        if( $this->iIcon !== null ) {
+            if( $this->iIconConstrain[0] == TIMG_WIDTH ) {
+            	$this->iIcon->SetScale(1);
+            	$tmp = $this->iIcon->GetWidthHeight();
+                $this->iIcon->SetScale($this->iIconConstrain[1]/$tmp[0]);
+            }
+            elseif( $this->iIconConstrain[0] == TIMG_HEIGHT ) {
+            	$this->iIcon->SetScale(1);
+            	$tmp = $this->iIcon->GetWidthHeight();
+                $this->iIcon->SetScale($this->iIconConstrain[1]/$tmp[1]);
+            }
+            $tmp = $this->iIcon->GetWidthHeight();
+            $iwidth = $tmp[0];
+        }
+        else {
+            $iwidth=0;
+        }
+        if( $this->iTable->iCells[$this->iPRow][$this->iPCol]->iVal->dir == 0 ) {
+            $pwidth = $this->iTable->iCells[$this->iPRow][$this->iPCol]->iVal->GetWidth($aImg);
+        }
+        elseif( $this->iTable->iCells[$this->iPRow][$this->iPCol]->iVal->dir == 90 ) {
+            $pwidth = $this->iTable->iCells[$this->iPRow][$this->iPCol]->iVal->GetFontHeight($aImg)+2;
+        }
+        else {
+            $pwidth = $this->iTable->iCells[$this->iPRow][$this->iPCol]->iVal->GetWidth($aImg)+2;
+        }
+
+        $pcolspan = $this->iTable->iCells[$this->iPRow][$this->iPCol]->iColSpan;
+        return round(max($iwidth,$pwidth)/$pcolspan) + $this->iMarginLeft + $this->iMarginRight;
+    }
+
+    function GetHeight($aImg) {
+        if( $this->iIcon !== null ) {
+            if( $this->iIconConstrain[0] == TIMG_WIDTH ) {
+            	$this->iIcon->SetScale(1);
+            	$tmp = $this->iIcon->GetWidthHeight();
+            	$this->iIcon->SetScale($this->iIconConstrain[1]/$tmp[0]);
+            }
+            elseif( $this->iIconConstrain[0] == TIMG_HEIGHT ) {
+            	$this->iIcon->SetScale(1);
+            	$tmp = $this->iIcon->GetWidthHeight();
+                $this->iIcon->SetScale($this->iIconConstrain[1]/$tmp[1]);
+            }
+            $tmp = $this->iIcon->GetWidthHeight();
+            $iheight =  $tmp[1];
+        }
+        else {
+            $iheight = 0;
+        }
+        if( $this->iTable->iCells[$this->iPRow][$this->iPCol]->iVal->dir == 0 ) {
+            $pheight = $this->iTable->iCells[$this->iPRow][$this->iPCol]->iVal->GetHeight($aImg);
+        }
+        else {
+            $pheight = $this->iTable->iCells[$this->iPRow][$this->iPCol]->iVal->GetHeight($aImg)+1;
+        }
+        $prowspan = $this->iTable->iCells[$this->iPRow][$this->iPCol]->iRowSpan;
+        return round(max($iheight,$pheight)/$prowspan) + $this->iMarginTop + $this->iMarginBottom;
+    }
+
+    function SetAlign($aHorAlign='left',$aVertAlign='bottom') {
+        $aHorAlign = strtolower($aHorAlign);
+        $aVertAlign = strtolower($aVertAlign);
+        $chk = array('left','right','center','bottom','top','middle');
+        if( !in_array($aHorAlign,$chk) || !in_array($aVertAlign,$chk) ) {
+            JpGraphError::RaiseL(27011,$aHorAlign,$aVertAlign);
+        }
+        $this->iVertAlign = $aVertAlign;
+        $this->iHorAlign = $aHorAlign;
+    }
+
+    function AdjustMarginsForGrid() {
+        if( $this->iCol > 0 ) {
+            switch( $this->iGridStyle[0] ) {
+                case TGRID_SINGLE:  $wf=1;  break;
+                case TGRID_DOUBLE:  $wf=3;  break;
+                case TGRID_DOUBLE2: $wf=4;  break;
+            }
+            $this->iMarginLeft += $this->iGridWeight[0]*$wf;
+        }
+        if( $this->iRow > 0 ) {
+            switch( $this->iGridStyle[1] ) {
+                case TGRID_SINGLE:  $wf=1;  break;
+                case TGRID_DOUBLE:  $wf=3;  break;
+                case TGRID_DOUBLE2: $wf=4;  break;
+            }
+            $this->iMarginTop += $this->iGridWeight[1]*$wf;
+        }
+        if( $this->iRow+$this->iRowSpan-1 < $this->iTable->iSize[0]-1 ) {
+            switch( $this->iGridStyle[2] ) {
+                case TGRID_SINGLE: $wf=1; break;
+                case TGRID_DOUBLE: $wf=3; break;
+                case TGRID_DOUBLE2: $wf=4; break;
+            }
+            $this->iMarginBottom += $this->iGridWeight[2]*$wf;
+        }
+        if( $this->iCol+$this->iColSpan-1 < $this->iTable->iSize[1]-1 ) {
+            switch( $this->iGridStyle[3] ) {
+                case TGRID_SINGLE: $wf=1; break;
+                case TGRID_DOUBLE: $wf=3; break;
+                case TGRID_DOUBLE2: $wf=4; break;
+            }
+            $this->iMarginRight += $this->iGridWeight[3]*$wf;
+        }
+    }
+
+    function StrokeVGrid($aImg,$aX,$aY,$aWidth,$aHeight,$aDir=1) {
+        // Left or right grid line
+        // For the right we increase the X-pos and for the right we decrease it. This is
+        // determined by the direction argument.
+        $idx = $aDir==1 ? 0 : 3;
+
+        // We don't stroke the grid lines that are on the edge of the table since this is
+        // the place of the border.
+        if( ( ($this->iCol > 0 && $idx==0) || ($this->iCol+$this->iColSpan-1 < $this->iTable->iSize[1]-1 && $idx==3) )
+        && $this->iGridWeight[$idx] > 0 ) {
+            $x = $aDir==1 ? $aX : $aX + $aWidth-1;
+            $y = $aY+$aHeight-1;
+            $aImg->SetColor($this->iGridColor[$idx]);
+            switch( $this->iGridStyle[$idx] ) {
+                case TGRID_SINGLE:
+                    for( $i=0; $i < $this->iGridWeight[$idx]; ++$i )
+                    $aImg->Line($x+$i*$aDir,$aY, $x+$i*$aDir,$y);
+                    break;
+
+                case TGRID_DOUBLE:
+                    for( $i=0; $i < $this->iGridWeight[$idx]; ++$i )
+                    $aImg->Line($x+$i*$aDir,$aY, $x+$i*$aDir,$y);
+                    $x += $this->iGridWeight[$idx]*2;
+                    for( $i=0; $i < $this->iGridWeight[$idx]; ++$i )
+                    $aImg->Line($x+$i*$aDir,$aY, $x+$i*$aDir,$y);
+                    break;
+
+                case TGRID_DOUBLE2:
+                    for( $i=0; $i < $this->iGridWeight[$idx]*2; ++$i )
+                    $aImg->Line($x+$i*$aDir,$aY,$x+$i*$aDir,$y);
+                    $x += $this->iGridWeight[$idx]*3;
+                    for( $i=0; $i < $this->iGridWeight[$idx]; ++$i )
+                    $aImg->Line($x+$i*$aDir,$aY, $x+$i*$aDir,$y);
+                    break;
+            }
+        }
+    }
+
+    function StrokeHGrid($aImg,$aX,$aY,$aWidth,$aHeight,$aDir=1) {
+        // Top or bottom grid line
+        // For the left we increase the X-pos and for the right we decrease it. This is
+        // determined by the direction argument.
+        $idx = $aDir==1 ? 1 : 2;
+
+        // We don't stroke the grid lines that are on the edge of the table since this is
+        // the place of the border.
+        if( ( ($this->iRow > 0 && $idx==1) || ($this->iRow+$this->iRowSpan-1 < $this->iTable->iSize[0]-1 && $idx==2) )
+        && $this->iGridWeight[$idx] > 0) {
+            $y = $aDir==1 ? $aY : $aY+$aHeight-1;
+            $x = $aX+$aWidth-1;
+            $aImg->SetColor($this->iGridColor[$idx]);
+            switch( $this->iGridStyle[$idx] ) {
+                case TGRID_SINGLE:
+                    for( $i=0; $i < $this->iGridWeight[$idx]; ++$i )
+                    $aImg->Line($aX,$y+$i, $x,$y+$i);
+                    break;
+
+                case TGRID_DOUBLE:
+                    for( $i=0; $i < $this->iGridWeight[$idx]; ++$i )
+                    $aImg->Line($aX,$y+$i, $x,$y+$i);
+                    $y += $this->iGridWeight[$idx]*2;
+                    for( $i=0; $i < $this->iGridWeight[$idx]; ++$i )
+                    $aImg->Line($aX,$y+$i, $x,$y+$i);
+                    break;
+
+                case TGRID_DOUBLE2:
+                    for( $i=0; $i < $this->iGridWeight[$idx]*2; ++$i )
+                    $aImg->Line($aX,$y+$i, $x,$y+$i);
+                    $y += $this->iGridWeight[$idx]*3;
+                    for( $i=0; $i < $this->iGridWeight[$idx]; ++$i )
+                    $aImg->Line($aX,$y+$i, $x,$y+$i);
+                    break;
+            }
+        }
+    }
+
+    function Stroke($aImg,$aX,$aY,$aWidth,$aHeight) {
+        // If this is a merged cell we only stroke if it is the parent cell.
+        // The parent cell holds the merged cell block
+        if( $this->iMerged && ($this->iRow != $this->iPRow || $this->iCol != $this->iPCol) ) {
+            return;
+        }
+
+        if( $this->iBGColor != '' ) {
+            $aImg->SetColor($this->iBGColor);
+            $aImg->FilledRectangle($aX,$aY,$aX+$aWidth-1,$aY+$aHeight-1);
+        }
+
+        $coords = $aX.','.$aY.','.($aX+$aWidth-1).','.$aY.','.($aX+$aWidth-1).','.($aY+$aHeight-1).','.$aX.','.($aY+$aHeight-1);
+        if( ! empty($this->iCSIMtarget) ) {
+            $this->iCSIMArea = '<area shape="poly" coords="'.$coords.'" href="'.$this->iCSIMtarget.'"';
+            if( ! empty($this->iCSIMwintarget) ) {
+                $this->iCSIMArea .= " target=\"".$this->iCSIMwintarget."\"";
+            }
+            if( ! empty($this->iCSIMalt) ) {
+                $this->iCSIMArea .= ' alt="'.$this->iCSIMalt.'" title="'.$this->iCSIMalt."\" ";
+            }
+            $this->iCSIMArea .= " />\n";
+        }
+
+        $this->StrokeVGrid($aImg,$aX,$aY,$aWidth,$aHeight);
+        $this->StrokeVGrid($aImg,$aX,$aY,$aWidth,$aHeight,-1);
+        $this->StrokeHGrid($aImg,$aX,$aY,$aWidth,$aHeight);
+        $this->StrokeHGrid($aImg,$aX,$aY,$aWidth,$aHeight,-1);
+
+        if( $this->iIcon !== null ) {
+            switch( $this->iHorAlign ) {
+                case 'left':
+                    $x = $aX+$this->iMarginLeft;
+                    $hanchor='left';
+                    break;
+                case 'center':
+                case 'middle':
+                    $x = $aX+$this->iMarginLeft+round(($aWidth-$this->iMarginLeft-$this->iMarginRight)/2);
+                    $hanchor='center';
+                    break;
+                case 'right':
+                    $x = $aX+$aWidth-$this->iMarginRight-1;
+                    $hanchor='right';
+                    break;
+                default:
+                    JpGraphError::RaiseL(27012,$this->iHorAlign);
+            }
+
+            switch( $this->iVertAlign ) {
+                case 'top':
+                    $y = $aY+$this->iMarginTop;
+                    $vanchor='top';
+                    break;
+                case 'center':
+                case 'middle':
+                    $y = $aY+$this->iMarginTop+round(($aHeight-$this->iMarginTop-$this->iMarginBottom)/2);
+                    $vanchor='center';
+                    break;
+                case 'bottom':
+                    $y = $aY+$aHeight-1-$this->iMarginBottom;
+                    $vanchor='bottom';
+                    break;
+                default:
+                    JpGraphError::RaiseL(27012,$this->iVertAlign);
+            }
+            $this->iIcon->SetAnchor($hanchor,$vanchor);
+            $this->iIcon->_Stroke($aImg,$x,$y);
+        }
+        $this->iVal->SetColor($this->iFontColor);
+        $this->iVal->SetFont($this->iFF,$this->iFS,$this->iFSize);
+        switch( $this->iHorAlign ) {
+            case 'left':
+                $x = $aX+$this->iMarginLeft;
+                break;
+            case 'center':
+            case 'middle':
+                $x = $aX+$this->iMarginLeft+round(($aWidth-$this->iMarginLeft-$this->iMarginRight)/2);
+                break;
+            case 'right':
+                $x = $aX+$aWidth-$this->iMarginRight-1;
+                break;
+            default:
+                JpGraphError::RaiseL(27012,$this->iHorAlign);
+        }
+        // A workaround for the shortcomings in the TTF font handling in GD
+        // The anchor position for rotated text (=90) is to "short" so we add
+        // an offset based on the actual font size
+        if( $this->iVal->dir != 0 && $this->iVal->font_family >= 10 ) {
+            $aY += 4 + round($this->iVal->font_size*0.8);
+        }
+        switch( $this->iVertAlign ) {
+            case 'top':
+                $y = $aY+$this->iMarginTop;
+                break;
+            case 'center':
+            case 'middle':
+                $y = $aY+$this->iMarginTop+round(($aHeight-$this->iMarginTop-$this->iMarginBottom)/2);
+                //$y -= round($this->iVal->GetFontHeight($aImg)/2);
+                $y -= round($this->iVal->GetHeight($aImg)/2);
+                break;
+            case 'bottom':
+                //$y = $aY+$aHeight-1-$this->iMarginBottom-$this->iVal->GetFontHeight($aImg);
+                $y = $aY+$aHeight-$this->iMarginBottom-$this->iVal->GetHeight($aImg);
+                break;
+            default:
+                JpGraphError::RaiseL(27012,$this->iVertAlign);
+        }
+        $this->iVal->SetAlign($this->iHorAlign,'top');
+        if( $this->iNumberFormat !== null && is_numeric($this->iVal->t) ) {
+            $this->iVal->t = sprintf($this->iNumberFormat,$this->iVal->t);
+        }
+        $this->iVal->Stroke($aImg,$x,$y);
+    }
+}
+
+//---------------------------------------------------------------------
+// CLASS GTextTable
+// Description:
+// Graphic text table
+//---------------------------------------------------------------------
+class GTextTable {
+    public $iCells = array(), $iSize=array(0,0); // Need to be public since they are used by the cell
+    private $iWidth=0, $iHeight=0;
+    private $iColWidth=NULL,$iRowHeight=NULL;
+    private $iImg=NULL;
+    private $iXPos=0, $iYPos=0;
+    private $iScaleXPos=null,$iScaleYPos=null;
+    private $iBGColor='';
+    private $iBorderColor='black',$iBorderWeight=1;
+    private $iInit=false;
+    private $iYAnchor='top',$iXAnchor='left';
+    /*-----------------------------------------------------------------
+     * First and second phase constructors
+     *-----------------------------------------------------------------
+     */
+    function __construct() {
+        // Empty
+    }
+
+    function Init($aRows=0,$aCols=0,$aFillText='') {
+        $this->iSize[0] = $aRows;
+        $this->iSize[1] = $aCols;
+        for($i=0; $i < $this->iSize[0]; ++$i) {
+            for($j=0; $j < $this->iSize[1]; ++$j) {
+                $this->iCells[$i][$j] = new GTextTableCell($aFillText,$i,$j);
+                $this->iCells[$i][$j]->Init($this);
+            }
+        }
+        $this->iInit=true;
+    }
+
+    /*-----------------------------------------------------------------
+     * Outer border of table
+     *-----------------------------------------------------------------
+     */
+    function SetBorder($aWeight=1,$aColor='black') {
+        $this->iBorderColor=$aColor;
+        $this->iBorderWeight = $aWeight;
+    }
+
+
+    /*-----------------------------------------------------------------
+     * Position in graph of table
+     *-----------------------------------------------------------------
+     */
+    function SetPos($aX,$aY) {
+        $this->iXPos = $aX;
+        $this->iYPos = $aY;
+    }
+
+    function SetScalePos($aX,$aY) {
+        $this->iScaleXPos = $aX;
+        $this->iScaleYPos = $aY;
+    }
+
+    function SetAnchorPos($aXAnchor,$aYAnchor='top') {
+        $this->iXAnchor = $aXAnchor;
+        $this->iYAnchor = $aYAnchor;
+    }
+
+    /*-----------------------------------------------------------------
+     * Setup country flag in a cell
+     *-----------------------------------------------------------------
+     */
+    function SetCellCountryFlag($aRow,$aCol,$aFlag,$aScale=1.0,$aMix=100,$aStdSize=3) {
+        $this->_chkR($aRow);
+        $this->_chkC($aCol);
+        $this->iCells[$aRow][$aCol]->SetCountryFlag($aFlag,$aScale,$aMix,$aStdSize);
+
+    }
+
+    /*-----------------------------------------------------------------
+     * Setup image in a cell
+     *-----------------------------------------------------------------
+     */
+    function SetCellImage($aRow,$aCol,$aFile,$aScale=1.0,$aMix=100) {
+        $this->_chkR($aRow);
+        $this->_chkC($aCol);
+        $this->iCells[$aRow][$aCol]->SetImage($aFile,$aScale,$aMix);
+    }
+
+    function SetRowImage($aRow,$aFile,$aScale=1.0,$aMix=100) {
+        $this->_chkR($aRow);
+        for($j=0; $j < $this->iSize[1]; ++$j) {
+            $this->iCells[$aRow][$j]->SetImage($aFile,$aScale,$aMix);
+        }
+    }
+
+    function SetColImage($aCol,$aFile,$aScale=1.0,$aMix=100) {
+        $this->_chkC($aCol);
+        for($j=0; $j < $this->iSize[0]; ++$j) {
+            $this->iCells[$j][$aCol]->SetImage($aFile,$aScale,$aMix);
+        }
+    }
+
+    function SetImage($aFileR1,$aScaleC1=null,$aMixR2=null,$aC2=null,$aFile=null,$aScale=1.0,$aMix=100) {
+        if( $aScaleC1 !== null && $aMixR2!==null && $aC2!==null && $aFile!==null ) {
+            $this->_chkR($aArgR1);  $this->_chkC($aC1);
+            $this->_chkR($aR2);  $this->_chkC($aC2);
+        }
+        else {
+            if( $aScaleC1 !== null ) $aScale = $aScaleC1;
+            if( $aMixR2 !== null ) $aMix = $aMixR2;
+            $aFile = $aFileR1;
+            $aMixR2 = $this->iSize[0]-1; $aFileR1 = 0;
+            $aC2 = $this->iSize[1]-1; $aScaleC1 = 0;
+        }
+        for($i=$aArgR1; $i <= $aR2; ++$i) {
+            for($j=$aC1; $j <= $aC2; ++$j) {
+                $this->iCells[$i][$j]->SetImage($aFile,$aScale,$aMix);
+            }
+        }
+    }
+
+    function SetCellImageConstrain($aRow,$aCol,$aType,$aVal) {
+        $this->_chkR($aRow);
+        $this->_chkC($aCol);
+        $this->iCells[$aRow][$aCol]->SetImageConstrain($aType,$aVal);
+    }
+
+    /*-----------------------------------------------------------------
+     * Generate a HTML version of the table
+     *-----------------------------------------------------------------
+     */
+    function toString() {
+        $t = '<table border=1 cellspacing=0 cellpadding=0>';
+        for($i=0; $i < $this->iSize[0]; ++$i) {
+            $t .= '<tr>';
+            for($j=0; $j < $this->iSize[1]; ++$j) {
+                $t .= '<td>';
+                if( $this->iCells[$i][$j]->iMerged )
+                $t .= 'M ';
+                $t .= 'val='.$this->iCells[$i][$j]->iVal->t;
+                $t .= ' (cs='.$this->iCells[$i][$j]->iColSpan.
+        ', rs='.$this->iCells[$i][$j]->iRowSpan.')';
+                $t .= '</td>';
+            }
+            $t .= '</tr>';
+        }
+        $t .= '</table>';
+        return $t;
+    }
+
+    /*-----------------------------------------------------------------
+     * Specify data for table
+     *-----------------------------------------------------------------
+     */
+    function Set($aArg1,$aArg2=NULL,$aArg3=NULL) {
+        if( $aArg2===NULL && $aArg3===NULL ) {
+            if( is_array($aArg1) ) {
+                if( is_array($aArg1[0]) ) {
+                    $m = count($aArg1);
+                    // Find the longest row
+                    $n=0;
+                    for($i=0; $i < $m; ++$i)
+                    $n = max(count($aArg1[$i]),$n);
+                    for($i=0; $i < $m; ++$i) {
+                        for($j=0; $j < $n; ++$j) {
+                            if( isset($aArg1[$i][$j]) ){
+                                $this->_setcell($i,$j,(string)$aArg1[$i][$j]);
+                            }
+                            else {
+                                $this->_setcell($i,$j);
+                            }
+                        }
+                    }
+                    $this->iSize[0] = $m;
+                    $this->iSize[1] = $n;
+                    $this->iInit=true;
+                }
+                else {
+                    JpGraphError::RaiseL(27001);
+                    //('Illegal argument to GTextTable::Set(). Array must be 2 dimensional');
+                }
+            }
+            else {
+                JpGraphError::RaiseL(27002);
+                //('Illegal argument to GTextTable::Set()');
+            }
+        }
+        else {
+            // Must be in the form (row,col,val)
+            $this->_chkR($aArg1);
+            $this->_chkC($aArg2);
+            $this->_setcell($aArg1,$aArg2,(string)$aArg3);
+        }
+    }
+
+    /*---------------------------------------------------------------------
+     * Cell margin setting
+     *---------------------------------------------------------------------
+     */
+    function SetPadding($aArgR1,$aC1=null,$aR2=null,$aC2=null,$aPad=null) {
+        if( $aC1 !== null && $aR2!==null && $aC2!==null && $aPad!==null ) {
+            $this->_chkR($aArgR1);  $this->_chkC($aC1);
+            $this->_chkR($aR2);  $this->_chkC($aC2);
+        }
+        else {
+            $aPad = $aArgR1;
+            $aR2 = $this->iSize[0]-1; $aArgR1 = 0;
+            $aC2 = $this->iSize[1]-1; $aC1 = 0;
+        }
+        for($i=$aArgR1; $i <= $aR2; ++$i) {
+            for($j=$aC1; $j <= $aC2; ++$j) {
+                $this->iCells[$i][$j]->SetMargin($aPad,$aPad,$aPad,$aPad);
+            }
+        }
+    }
+
+    function SetRowPadding($aRow,$aPad) {
+        $this->_chkR($aRow);
+        for($j=0; $j < $this->iSize[1]; ++$j) {
+            $this->iCells[$aRow][$j]->SetMargin($aPad,$aPad,$aPad,$aPad);
+        }
+    }
+
+    function SetColPadding($aCol,$aPad) {
+        $this->_chkC($aCol);
+        for($j=0; $j < $this->iSize[0]; ++$j) {
+            $this->iCells[$j][$aCol]->SetMargin($aPad,$aPad,$aPad,$aPad);
+        }
+    }
+
+    function SetCellPadding($aRow,$aCol,$aPad) {
+        $this->_chkR($aRow);
+        $this->_chkC($aCol);
+        $this->iCells[$aRow][$aCol]->SetMargin($aPad,$aPad,$aPad,$aPad);
+    }
+
+
+    /*---------------------------------------------------------------------
+     * Cell text orientation setting
+     *---------------------------------------------------------------------
+     */
+    function SetTextOrientation($aArgR1,$aC1=null,$aR2=null,$aC2=null,$aO=null) {
+        if( $aC1 !== null && $aR2!==null && $aC2!==null && $aPad!==null ) {
+            $this->_chkR($aArgR1);  $this->_chkC($aC1);
+            $this->_chkR($aR2);  $this->_chkC($aC2);
+        }
+        else {
+            $aO = $aArgR1;
+            $aR2 = $this->iSize[0]-1; $aArgR1 = 0;
+            $aC2 = $this->iSize[1]-1; $aC1 = 0;
+        }
+        for($i=$aArgR1; $i <= $aR2; ++$i) {
+            for($j=$aC1; $j <= $aC2; ++$j) {
+                $this->iCells[$i][$j]->iVal->SetOrientation($aO);
+            }
+        }
+    }
+
+    function SetRowTextOrientation($aRow,$aO) {
+        $this->_chkR($aRow);
+        for($j=0; $j < $this->iSize[1]; ++$j) {
+            $this->iCells[$aRow][$j]->iVal->SetOrientation($aO);
+        }
+    }
+
+    function SetColTextOrientation($aCol,$aO) {
+        $this->_chkC($aCol);
+        for($j=0; $j < $this->iSize[0]; ++$j) {
+            $this->iCells[$j][$aCol]->iVal->SetOrientation($aO);
+        }
+    }
+
+    function SetCellTextOrientation($aRow,$aCol,$aO) {
+        $this->_chkR($aRow);
+        $this->_chkC($aCol);
+        $this->iCells[$aRow][$aCol]->iVal->SetOrientation($aO);
+    }
+
+
+
+
+    /*---------------------------------------------------------------------
+     * Font color setting
+     *---------------------------------------------------------------------
+     */
+
+    function SetColor($aArgR1,$aC1=null,$aR2=null,$aC2=null,$aArg=null) {
+        if( $aC1 !== null && $aR2!==null && $aC2!==null && $aArg!==null ) {
+            $this->_chkR($aArgR1);  $this->_chkC($aC1);
+            $this->_chkR($aR2);  $this->_chkC($aC2);
+        }
+        else {
+            $aArg = $aArgR1;
+            $aR2 = $this->iSize[0]-1; $aArgR1 = 0;
+            $aC2 = $this->iSize[1]-1; $aC1 = 0;
+        }
+        for($i=$aArgR1; $i <= $aR2; ++$i) {
+            for($j=$aC1; $j <= $aC2; ++$j) {
+                $this->iCells[$i][$j]->SetFontColor($aArg);
+            }
+        }
+    }
+
+    function SetRowColor($aRow,$aColor) {
+        $this->_chkR($aRow);
+        for($j=0; $j < $this->iSize[1]; ++$j) {
+            $this->iCells[$aRow][$j]->SetFontColor($aColor);
+        }
+    }
+
+    function SetColColor($aCol,$aColor) {
+        $this->_chkC($aCol);
+        for($i=0; $i < $this->iSize[0]; ++$i) {
+            $this->iCells[$i][$aCol]->SetFontColor($aColor);
+        }
+    }
+
+    function SetCellColor($aRow,$aCol,$aColor) {
+        $this->_chkR($aRow);
+        $this->_chkC($aCol);
+        $this->iCells[$aRow][$aCol]->SetFontColor($aColor);
+    }
+
+    /*---------------------------------------------------------------------
+     * Fill color settings
+     *---------------------------------------------------------------------
+     */
+
+    function SetFillColor($aArgR1,$aC1=null,$aR2=null,$aC2=null,$aArg=null) {
+        if( $aC1 !== null && $aR2!==null && $aC2!==null && $aArg!==null ) {
+            $this->_chkR($aArgR1);  $this->_chkC($aC1);
+            $this->_chkR($aR2);  $this->_chkC($aC2);
+            for($i=$aArgR1; $i <= $aR2; ++$i) {
+                for($j=$aC1; $j <= $aC2; ++$j) {
+                    $this->iCells[$i][$j]->SetFillColor($aArg);
+                }
+            }
+        }
+        else {
+            $this->iBGColor = $aArgR1;
+        }
+    }
+
+    function SetRowFillColor($aRow,$aColor) {
+        $this->_chkR($aRow);
+        for($j=0; $j < $this->iSize[1]; ++$j) {
+            $this->iCells[$aRow][$j]->SetFillColor($aColor);
+        }
+    }
+
+    function SetColFillColor($aCol,$aColor) {
+        $this->_chkC($aCol);
+        for($i=0; $i < $this->iSize[0]; ++$i) {
+            $this->iCells[$i][$aCol]->SetFillColor($aColor);
+        }
+    }
+
+    function SetCellFillColor($aRow,$aCol,$aColor) {
+        $this->_chkR($aRow);
+        $this->_chkC($aCol);
+        $this->iCells[$aRow][$aCol]->SetFillColor($aColor);
+    }
+
+    /*---------------------------------------------------------------------
+     * Font family setting
+     *---------------------------------------------------------------------
+     */
+    function SetFont() {
+        $numargs = func_num_args();
+        if( $numargs == 2 || $numargs == 3 ) {
+            $aFF = func_get_arg(0);
+            $aFS = func_get_arg(1);
+            if( $numargs == 3 )
+            $aFSize=func_get_arg(2);
+            else
+            $aFSize=10;
+            $aR2 = $this->iSize[0]-1; $aR1 = 0;
+            $aC2 = $this->iSize[1]-1; $aC1 = 0;
+
+        }
+        elseif($numargs == 6 || $numargs == 7 ) {
+            $aR1 = func_get_arg(0); $aC1 = func_get_arg(1);
+            $aR2 = func_get_arg(2); $aC2 = func_get_arg(3);
+            $aFF = func_get_arg(4); $aFS = func_get_arg(5);
+            if( $numargs == 7 )
+            $aFSize=func_get_arg(6);
+            else
+            $aFSize=10;
+        }
+        else {
+            JpGraphError::RaiseL(27003);
+            //('Wrong number of arguments to GTextTable::SetColor()');
+        }
+        $this->_chkR($aR1);  $this->_chkC($aC1);
+        $this->_chkR($aR2);  $this->_chkC($aC2);
+        for($i=$aR1; $i <= $aR2; ++$i) {
+            for($j=$aC1; $j <= $aC2; ++$j) {
+                $this->iCells[$i][$j]->SetFont($aFF,$aFS,$aFSize);
+            }
+        }
+    }
+
+    function SetRowFont($aRow,$aFF,$aFS,$aFSize=10) {
+        $this->_chkR($aRow);
+        for($j=0; $j < $this->iSize[1]; ++$j) {
+            $this->iCells[$aRow][$j]->SetFont($aFF,$aFS,$aFSize);
+        }
+    }
+
+    function SetColFont($aCol,$aFF,$aFS,$aFSize=10) {
+        $this->_chkC($aCol);
+        for($i=0; $i < $this->iSize[0]; ++$i) {
+            $this->iCells[$i][$aCol]->SetFont($aFF,$aFS,$aFSize);
+        }
+    }
+
+    function SetCellFont($aRow,$aCol,$aFF,$aFS,$aFSize=10) {
+        $this->_chkR($aRow);
+        $this->_chkC($aCol);
+        $this->iCells[$aRow][$aCol]->SetFont($aFF,$aFS,$aFSize);
+    }
+
+    /*---------------------------------------------------------------------
+     * Cell align settings
+     *---------------------------------------------------------------------
+     */
+
+    function SetAlign($aR1HAlign=null,$aC1VAlign=null,$aR2=null,$aC2=null,$aHArg=null,$aVArg='center') {
+        if( $aC1VAlign !== null && $aR2!==null && $aC2!==null && $aHArg!==null ) {
+            $this->_chkR($aR1HAlign);  $this->_chkC($aC1VAlign);
+            $this->_chkR($aR2);  $this->_chkC($aC2);
+        }
+        else {
+            if( $aR1HAlign === null ) {
+                JpGraphError::RaiseL(27010);
+            }
+            if( $aC1VAlign === null ) {
+                $aC1VAlign = 'center';
+            }
+            $aHArg = $aR1HAlign;
+            $aVArg = $aC1VAlign === null ? 'center' : $aC1VAlign ;
+            $aR2 = $this->iSize[0]-1; $aR1HAlign = 0;
+            $aC2 = $this->iSize[1]-1; $aC1VAlign = 0;
+        }
+        for($i=$aR1HAlign; $i <= $aR2; ++$i) {
+            for($j=$aC1VAlign; $j <= $aC2; ++$j) {
+                $this->iCells[$i][$j]->SetAlign($aHArg,$aVArg);
+            }
+        }
+    }
+
+    function SetCellAlign($aRow,$aCol,$aHorAlign,$aVertAlign='bottom') {
+        $this->_chkR($aRow);
+        $this->_chkC($aCol);
+        $this->iCells[$aRow][$aCol]->SetAlign($aHorAlign,$aVertAlign);
+    }
+
+    function SetRowAlign($aRow,$aHorAlign,$aVertAlign='bottom') {
+        $this->_chkR($aRow);
+        for($j=0; $j < $this->iSize[1]; ++$j) {
+            $this->iCells[$aRow][$j]->SetAlign($aHorAlign,$aVertAlign);
+        }
+    }
+
+    function SetColAlign($aCol,$aHorAlign,$aVertAlign='bottom') {
+        $this->_chkC($aCol);
+        for($i=0; $i < $this->iSize[0]; ++$i) {
+            $this->iCells[$i][$aCol]->SetAlign($aHorAlign,$aVertAlign);
+        }
+    }
+
+    /*---------------------------------------------------------------------
+     * Cell number format
+     *---------------------------------------------------------------------
+     */
+
+    function SetNumberFormat($aArgR1,$aC1=null,$aR2=null,$aC2=null,$aArg=null) {
+        if( $aC1 !== null && $aR2!==null && $aC2!==null && $aArg!==null ) {
+            $this->_chkR($aArgR1);  $this->_chkC($aC1);
+            $this->_chkR($aR2);  $this->_chkC($aC2);
+        }
+        else {
+            $aArg = $aArgR1;
+            $aR2 = $this->iSize[0]-1; $aArgR1 = 0;
+            $aC2 = $this->iSize[1]-1; $aC1 = 0;
+        }
+        if( !is_string($aArg) ) {
+            JpGraphError::RaiseL(27013); // argument must be a string
+        }
+        for($i=$aArgR1; $i <= $aR2; ++$i) {
+            for($j=$aC1; $j <= $aC2; ++$j) {
+                $this->iCells[$i][$j]->SetNumberFormat($aArg);
+            }
+        }
+    }
+
+    function SetRowNumberFormat($aRow,$aF) {
+        $this->_chkR($aRow);
+        if( !is_string($aF) ) {
+            JpGraphError::RaiseL(27013); // argument must be a string
+        }
+        for($j=0; $j < $this->iSize[1]; ++$j) {
+            $this->iCells[$aRow][$j]->SetNumberFormat($aF);
+        }
+    }
+
+    function SetColNumberFormat($aCol,$aF) {
+        $this->_chkC($aCol);
+        if( !is_string($aF) ) {
+            JpGraphError::RaiseL(27013); // argument must be a string
+        }
+        for($i=0; $i < $this->iSize[0]; ++$i) {
+            $this->iCells[$i][$aCol]->SetNumberFormat($aF);
+        }
+    }
+
+    function SetCellNumberFormat($aRow,$aCol,$aF) {
+        $this->_chkR($aRow); $this->_chkC($aCol);
+        if( !is_string($aF) ) {
+            JpGraphError::RaiseL(27013); // argument must be a string
+        }
+        $this->iCells[$aRow][$aCol]->SetNumberFormat($aF);
+    }
+
+    /*---------------------------------------------------------------------
+     * Set row and column min size
+     *---------------------------------------------------------------------
+     */
+
+    function SetMinColWidth($aColWidth,$aWidth=null) {
+        // If there is only one argument this means that all
+        // columns get set to the same width
+        if( $aWidth===null ) {
+            for($i=0; $i < $this->iSize[1]; ++$i) {
+                $this->iColWidth[$i]  = $aColWidth;
+            }
+        }
+        else {
+            $this->_chkC($aColWidth);
+            $this->iColWidth[$aColWidth]  = $aWidth;
+        }
+    }
+
+    function SetMinRowHeight($aRowHeight,$aHeight=null) {
+        // If there is only one argument this means that all
+        // rows get set to the same height
+        if( $aHeight===null ) {
+            for($i=0; $i < $this->iSize[0]; ++$i) {
+                $this->iRowHeight[$i]  = $aRowHeight;
+            }
+        }
+        else {
+            $this->_chkR($aRowHeight);
+            $this->iRowHeight[$aRowHeight]  = $aHeight;
+        }
+    }
+
+    /*---------------------------------------------------------------------
+     * Grid line settings
+     *---------------------------------------------------------------------
+     */
+
+    function SetGrid($aWeight=1,$aColor='black',$aStyle=TGRID_SINGLE) {
+        $rc = $this->iSize[0];
+        $cc = $this->iSize[1];
+        for($i=0; $i < $rc; ++$i) {
+            for($j=0; $j < $cc; ++$j) {
+                $this->iCells[$i][$j]->SetGridColor($aColor,$aColor);
+                $this->iCells[$i][$j]->SetGridWeight($aWeight,$aWeight);
+                $this->iCells[$i][$j]->SetGridStyle($aStyle);
+            }
+        }
+    }
+
+    function SetColGrid($aCol,$aWeight=1,$aColor='black',$aStyle=TGRID_SINGLE) {
+        $this->_chkC($aCol);
+        for($i=0; $i < $this->iSize[0]; ++$i) {
+            $this->iCells[$i][$aCol]->SetGridWeight($aWeight);
+            $this->iCells[$i][$aCol]->SetGridColor($aColor);
+            $this->iCells[$i][$aCol]->SetGridStyle($aStyle);
+        }
+    }
+
+    function SetRowGrid($aRow,$aWeight=1,$aColor='black',$aStyle=TGRID_SINGLE) {
+        $this->_chkR($aRow);
+        for($j=0; $j < $this->iSize[1]; ++$j) {
+            $this->iCells[$aRow][$j]->SetGridWeight(NULL,$aWeight);
+            $this->iCells[$aRow][$j]->SetGridColor(NULL,$aColor);
+            $this->iCells[$aRow][$j]->SetGridStyle(NULL,$aStyle);
+        }
+    }
+
+    /*---------------------------------------------------------------------
+     * Merge cells
+     *---------------------------------------------------------------------
+     */
+
+    function MergeRow($aRow,$aHAlign='center',$aVAlign='center') {
+        $this->_chkR($aRow);
+        $this->MergeCells($aRow,0,$aRow,$this->iSize[1]-1,$aHAlign,$aVAlign);
+    }
+
+    function MergeCol($aCol,$aHAlign='center',$aVAlign='center') {
+        $this->_chkC($aCol);
+        $this->MergeCells(0,$aCol,$this->iSize[0]-1,$aCol,$aHAlign,$aVAlign);
+    }
+
+    function MergeCells($aR1,$aC1,$aR2,$aC2,$aHAlign='center',$aVAlign='center') {
+        if( $aR1 > $aR2 || $aC1 > $aC2 ) {
+            JpGraphError::RaiseL(27004);
+            //('GTextTable::MergeCells(). Specified cell range to be merged is not valid.');
+        }
+        $this->_chkR($aR1); $this->_chkC($aC1);
+        $this->_chkR($aR2); $this->_chkC($aC2);
+        $rspan = $aR2-$aR1+1;
+        $cspan = $aC2-$aC1+1;
+        // Setup the parent cell for this merged group
+        if( $this->iCells[$aR1][$aC1]->IsMerged() ) {
+            JpGraphError::RaiseL(27005,$aR1,$aC1,$aR2,$aC2);
+            //("Cannot merge already merged cells in the range ($aR1,$aC1), ($aR2,$aC2)");
+        }
+        $this->iCells[$aR1][$aC1]->SetRowColSpan($rspan,$cspan);
+        $this->iCells[$aR1][$aC1]->SetAlign($aHAlign,$aVAlign);
+        for($i=$aR1; $i <= $aR2; ++$i) {
+            for($j=$aC1; $j <= $aC2; ++$j) {
+                if( ! ($i == $aR1 && $j == $aC1) ) {
+                    if( $this->iCells[$i][$j]->IsMerged() ) {
+                        JpGraphError::RaiseL(27005,$aR1,$aC1,$aR2,$aC2);
+                        //("Cannot merge already merged cells in the range ($aR1,$aC1), ($aR2,$aC2)");
+                    }
+                    $this->iCells[$i][$j]->SetMerged($aR1,$aC1,true);
+                }
+            }
+        }
+    }
+
+
+    /*---------------------------------------------------------------------
+     * CSIM methods
+     *---------------------------------------------------------------------
+     */
+
+    function SetCSIMTarget($aTarget,$aAlt=null,$aAutoTarget=false) {
+        $m = $this->iSize[0];
+        $n = $this->iSize[1];
+        $csim = '';
+        for($i=0; $i < $m; ++$i) {
+            for($j=0; $j < $n; ++$j) {
+                if( $aAutoTarget )
+                $t = $aTarget."?row=$i&col=$j";
+                else
+                $t = $aTarget;
+                $this->iCells[$i][$j]->SetCSIMTarget($t,$aAlt);
+            }
+        }
+    }
+
+    function SetCellCSIMTarget($aRow,$aCol,$aTarget,$aAlt=null) {
+        $this->_chkR($aRow);
+        $this->_chkC($aCol);
+        $this->iCells[$aRow][$aCol]->SetCSIMTarget($aTarget,$aAlt);
+    }
+
+    /*---------------------------------------------------------------------
+     * Private methods
+     *---------------------------------------------------------------------
+     */
+
+    function GetCSIMAreas() {
+        $m = $this->iSize[0];
+        $n = $this->iSize[1];
+        $csim = '';
+        for($i=0; $i < $m; ++$i) {
+            for($j=0; $j < $n; ++$j) {
+                $csim .= $this->iCells[$i][$j]->GetCSIMArea();
+            }
+        }
+        return $csim;
+    }
+
+    function _chkC($aCol) {
+        if( ! $this->iInit ) {
+            JpGraphError::Raise(27014); // Table not initialized
+        }
+        if( $aCol < 0 || $aCol >= $this->iSize[1] )
+        JpGraphError::RaiseL(27006,$aCol);
+        //("GTextTable:\nColumn argument ($aCol) is outside specified table size.");
+    }
+
+    function _chkR($aRow) {
+        if( ! $this->iInit ) {
+            JpGraphError::Raise(27014); // Table not initialized
+        }
+        if( $aRow < 0 || $aRow >= $this->iSize[0] )
+        JpGraphError::RaiseL(27007,$aRow);
+        //("GTextTable:\nRow argument ($aRow) is outside specified table size.");
+    }
+
+    function _getScalePos() {
+        if( $this->iScaleXPos === null || $this->iScaleYPos === null ) {
+            return false;
+        }
+        return array($this->iScaleXPos, $this->iScaleYPos);
+    }
+
+    function _autoSizeTable($aImg) {
+        // Get maximum column width and row height
+        $m = $this->iSize[0];
+        $n = $this->iSize[1];
+        $w=1;$h=1;
+
+        // Get maximum row height per row
+        for($i=0; $i < $m; ++$i) {
+            $h=0;
+            for($j=0; $j < $n; ++$j) {
+                $h = max($h,$this->iCells[$i][$j]->GetHeight($aImg));
+            }
+            if( isset($this->iRowHeight[$i]) ) {
+                $this->iRowHeight[$i]  = max($h,$this->iRowHeight[$i]);
+            }
+            else
+            $this->iRowHeight[$i]  = $h;
+        }
+
+        // Get maximum col width per columns
+        for($j=0; $j < $n; ++$j) {
+            $w=0;
+            for($i=0; $i < $m; ++$i) {
+                $w = max($w,$this->iCells[$i][$j]->GetWidth($aImg));
+            }
+            if( isset($this->iColWidth[$j]) ) {
+                $this->iColWidth[$j]  = max($w,$this->iColWidth[$j]);
+            }
+            else
+            $this->iColWidth[$j]  = $w;
+        }
+    }
+
+    function _setcell($aRow,$aCol,$aVal='') {
+        if( isset($this->iCells[$aRow][$aCol]) ) {
+            $this->iCells[$aRow][$aCol]->Set($aVal);
+        }
+        else {
+            $this->iCells[$aRow][$aCol] = new GTextTableCell((string)$aVal,$aRow,$aCol);
+            $this->iCells[$aRow][$aCol]->Init($this);
+        }
+    }
+
+    function StrokeWithScale($aImg,$aXScale,$aYScale) {
+        if( is_numeric($this->iScaleXPos) && is_numeric($this->iScaleYPos) ) {
+            $x = round($aXScale->Translate($this->iScaleXPos));
+            $y = round($aYScale->Translate($this->iScaleYPos));
+            $this->Stroke($aImg,$x,$y);
+        }
+        else {
+            $this->Stroke($aImg);
+        }
+    }
+
+    function Stroke($aImg,$aX=NULL,$aY=NULL) {
+        if( $aX !== NULL && $aY !== NULL ) {
+            $this->iXPos = $aX;
+            $this->iYPos = $aY;
+        }
+
+        $rc = $this->iSize[0]; // row count
+        $cc = $this->iSize[1]; // column count
+
+        if( $rc == 0 || $cc == 0 ) {
+            JpGraphError::RaiseL(27009);
+        }
+
+        // Adjust margins of each cell based on the weight of the grid. Each table grid line
+        // is actually occupying the left side and top part of each cell.
+        for($j=0; $j < $cc; ++$j) {
+            $this->iCells[0][$j]->iMarginTop += $this->iBorderWeight;
+        }
+        for($i=0; $i < $rc; ++$i) {
+            $this->iCells[$i][0]->iMarginLeft += $this->iBorderWeight;
+        }
+        for($i=0; $i < $rc; ++$i) {
+            for($j=0; $j < $cc; ++$j) {
+                $this->iCells[$i][$j]->AdjustMarginsForGrid();
+            }
+        }
+
+        // adjust row and column size depending on cell content
+        $this->_autoSizeTable($aImg);
+
+        if( $this->iSize[1] != count($this->iColWidth) || $this->iSize[0] != count($this->iRowHeight) ) {
+            JpGraphError::RaiseL(27008);
+            //('Column and row size arrays must match the dimesnions of the table');
+        }
+
+        // Find out overall table size
+        $width=0;
+        for($i=0; $i < $cc; ++$i) {
+            $width += $this->iColWidth[$i];
+        }
+        $height=0;
+        for($i=0; $i < $rc; ++$i) {
+            $height += $this->iRowHeight[$i];
+        }
+
+        // Adjust the X,Y position to alway be at the top left corner
+        // The anchor position, i.e. how the client want to interpret the specified
+        // x and y coordinate must be taken into account
+        switch( strtolower($this->iXAnchor) ) {
+            case 'left' :
+                break;
+            case 'center':
+                $this->iXPos -= round($width/2);
+                break;
+            case 'right':
+                $this->iXPos -= $width;
+                break;
+        }
+        switch( strtolower($this->iYAnchor) ) {
+            case 'top' :
+                break;
+            case 'center':
+            case 'middle':
+                $this->iYPos -= round($height/2);
+                break;
+            case 'bottom':
+                $this->iYPos -= $height;
+                break;
+        }
+
+        // Set the overall background color of the table if set
+        if( $this->iBGColor !== '' ) {
+            $aImg->SetColor($this->iBGColor);
+            $aImg->FilledRectangle($this->iXPos,$this->iYPos,$this->iXPos+$width,$this->iYPos+$height);
+        }
+
+        // Stroke all cells
+        $rpos=$this->iYPos;
+        for($i=0; $i < $rc; ++$i) {
+            $cpos=$this->iXPos;
+            for($j=0; $j < $cc; ++$j) {
+                // Calculate width and height of this cell if it is spanning
+                // more than one column or row
+                $cwidth=0;
+                for( $k=0; $k < $this->iCells[$i][$j]->iColSpan; ++$k ) {
+                    $cwidth += $this->iColWidth[$j+$k];
+                }
+                $cheight=0;
+                for( $k=0; $k < $this->iCells[$i][$j]->iRowSpan; ++$k ) {
+                    $cheight += $this->iRowHeight[$i+$k];
+                }
+
+                $this->iCells[$i][$j]->Stroke($aImg,$cpos,$rpos,$cwidth,$cheight);
+                $cpos += $this->iColWidth[$j];
+            }
+            $rpos += $this->iRowHeight[$i];
+        }
+
+        // Stroke outer border
+        $aImg->SetColor($this->iBorderColor);
+        if( $this->iBorderWeight == 1 )
+        $aImg->Rectangle($this->iXPos,$this->iYPos,$this->iXPos+$width,$this->iYPos+$height);
+        else {
+            for( $i=0; $i < $this->iBorderWeight; ++$i )
+            $aImg->Rectangle($this->iXPos+$i,$this->iYPos+$i,
+            $this->iXPos+$width-1+$this->iBorderWeight-$i,
+            $this->iYPos+$height-1+$this->iBorderWeight-$i);
+        }
+    }
+}
+
+/*
+ EOF
+ */
+?>
diff --git a/web/classes/jpgraph/jpgraph_text.inc.php b/web/classes/jpgraph/jpgraph_text.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..7d0f6687f81af69eec2dcfd87110c1ec28687e0d
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_text.inc.php
@@ -0,0 +1,327 @@
+<?php
+//=======================================================================
+// File:        JPGRAPH_TEXT.INC.PHP
+// Description: Class to handle text as object in the graph.
+//              The low level text layout engine is handled by the GD class
+// Created:     2001-01-08 (Refactored to separate file 2008-08-01)
+// Ver:         $Id: jpgraph_text.inc.php 1844 2009-09-26 17:05:31Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+
+//===================================================
+// CLASS Text
+// Description: Arbitrary text object that can be added to the graph
+//===================================================
+class Text {
+    public $t;
+    public $x=0,$y=0,$halign="left",$valign="top",$color=array(0,0,0);
+    public $hide=false, $dir=0;
+    public $iScalePosY=null,$iScalePosX=null;
+    public $iWordwrap=0;
+    public $font_family=FF_DEFAULT,$font_style=FS_NORMAL; // old. FF_FONT1
+    protected $boxed=false; // Should the text be boxed
+    protected $paragraph_align="left";
+    protected $icornerradius=0,$ishadowwidth=3;
+    protected $fcolor='white',$bcolor='black',$shadow=false;
+    protected $iCSIMarea='',$iCSIMalt='',$iCSIMtarget='',$iCSIMWinTarget='';
+    private $iBoxType = 1; // Which variant of filled box around text we want
+
+    // for __get, __set
+    private $_margin;
+    private $_font_size=8; // old. 12
+
+    //---------------
+    // CONSTRUCTOR
+
+    // Create new text at absolute pixel coordinates
+    function __construct($aTxt="",$aXAbsPos=0,$aYAbsPos=0) {
+        if( ! is_string($aTxt) ) {
+            JpGraphError::RaiseL(25050);//('First argument to Text::Text() must be s atring.');
+        }
+        $this->t = $aTxt;
+        $this->x = round($aXAbsPos);
+        $this->y = round($aYAbsPos);
+        $this->margin = 0;
+    }
+    //---------------
+    // PUBLIC METHODS
+    // Set the string in the text object
+    function Set($aTxt) {
+        $this->t = $aTxt;
+    }
+
+    // Alias for Pos()
+    function SetPos($aXAbsPos=0,$aYAbsPos=0,$aHAlign="left",$aVAlign="top") {
+    //$this->Pos($aXAbsPos,$aYAbsPos,$aHAlign,$aVAlign);
+        $this->x = $aXAbsPos;
+        $this->y = $aYAbsPos;
+        $this->halign = $aHAlign;
+        $this->valign = $aVAlign;
+    }
+
+    function SetScalePos($aX,$aY) {
+        $this->iScalePosX = $aX;
+        $this->iScalePosY = $aY;
+    }
+
+    // Specify alignment for the text
+    function Align($aHAlign,$aVAlign="top",$aParagraphAlign="") {
+        $this->halign = $aHAlign;
+        $this->valign = $aVAlign;
+        if( $aParagraphAlign != "" )
+            $this->paragraph_align = $aParagraphAlign;
+    }
+
+    // Alias
+    function SetAlign($aHAlign,$aVAlign="top",$aParagraphAlign="") {
+        $this->Align($aHAlign,$aVAlign,$aParagraphAlign);
+    }
+
+    // Specifies the alignment for a multi line text
+    function ParagraphAlign($aAlign) {
+        $this->paragraph_align = $aAlign;
+    }
+
+    // Specifies the alignment for a multi line text
+    function SetParagraphAlign($aAlign) {
+        $this->paragraph_align = $aAlign;
+    }
+
+    function SetShadow($aShadowColor='gray',$aShadowWidth=3) {
+        $this->ishadowwidth=$aShadowWidth;
+        $this->shadow=$aShadowColor;
+        $this->boxed=true;
+    }
+
+    function SetWordWrap($aCol) {
+        $this->iWordwrap = $aCol ;
+    }
+
+    // Specify that the text should be boxed. fcolor=frame color, bcolor=border color,
+    // $shadow=drop shadow should be added around the text.
+    function SetBox($aFrameColor=array(255,255,255),$aBorderColor=array(0,0,0),$aShadowColor=false,$aCornerRadius=4,$aShadowWidth=3) {
+        if( $aFrameColor === false ) {
+            $this->boxed=false;
+        }
+        else {
+            $this->boxed=true;
+        }
+        $this->fcolor=$aFrameColor;
+        $this->bcolor=$aBorderColor;
+        // For backwards compatibility when shadow was just true or false
+        if( $aShadowColor === true ) {
+            $aShadowColor = 'gray';
+        }
+        $this->shadow=$aShadowColor;
+        $this->icornerradius=$aCornerRadius;
+        $this->ishadowwidth=$aShadowWidth;
+    }
+
+    function SetBox2($aFrameColor=array(255,255,255),$aBorderColor=array(0,0,0),$aShadowColor=false,$aCornerRadius=4,$aShadowWidth=3) {
+        $this->iBoxType=2;
+        $this->SetBox($aFrameColor,$aBorderColor,$aShadowColor,$aCornerRadius,$aShadowWidth);
+    }
+
+    // Hide the text
+    function Hide($aHide=true) {
+        $this->hide=$aHide;
+    }
+
+    // This looks ugly since it's not a very orthogonal design
+    // but I added this "inverse" of Hide() to harmonize
+    // with some classes which I designed more recently (especially)
+    // jpgraph_gantt
+    function Show($aShow=true) {
+        $this->hide=!$aShow;
+    }
+
+    // Specify font
+    function SetFont($aFamily,$aStyle=FS_NORMAL,$aSize=10) {
+        $this->font_family=$aFamily;
+        $this->font_style=$aStyle;
+        $this->font_size=$aSize;
+    }
+
+    // Center the text between $left and $right coordinates
+    function Center($aLeft,$aRight,$aYAbsPos=false) {
+        $this->x = $aLeft + ($aRight-$aLeft )/2;
+        $this->halign = "center";
+        if( is_numeric($aYAbsPos) )
+            $this->y = $aYAbsPos;
+    }
+
+    // Set text color
+    function SetColor($aColor) {
+        $this->color = $aColor;
+    }
+
+    function SetAngle($aAngle) {
+        $this->SetOrientation($aAngle);
+    }
+
+    // Orientation of text. Note only TTF fonts can have an arbitrary angle
+    function SetOrientation($aDirection=0) {
+        if( is_numeric($aDirection) )
+            $this->dir=$aDirection;
+        elseif( $aDirection=="h" )
+            $this->dir = 0;
+        elseif( $aDirection=="v" )
+            $this->dir = 90;
+        else
+            JpGraphError::RaiseL(25051);//(" Invalid direction specified for text.");
+    }
+
+    // Total width of text
+    function GetWidth($aImg) {
+        $aImg->SetFont($this->font_family,$this->font_style,$this->raw_font_size);
+        $w = $aImg->GetTextWidth($this->t,$this->dir);
+        return $w;
+    }
+
+    // Hight of font
+    function GetFontHeight($aImg) {
+        $aImg->SetFont($this->font_family,$this->font_style,$this->raw_font_size);
+        $h = $aImg->GetFontHeight();
+        return $h;
+
+    }
+
+    function GetTextHeight($aImg) {
+        $aImg->SetFont($this->font_family,$this->font_style,$this->raw_font_size);
+        $h = $aImg->GetTextHeight($this->t,$this->dir);
+        return $h;
+    }
+
+    function GetHeight($aImg) {
+    // Synonym for GetTextHeight()
+        $aImg->SetFont($this->font_family,$this->font_style,$this->raw_font_size);
+        $h = $aImg->GetTextHeight($this->t,$this->dir);
+        return $h;
+    }
+
+    // Set the margin which will be interpretated differently depending
+    // on the context.
+    function SetMargin($aMarg) {
+        $this->margin = $aMarg;
+    }
+
+    function StrokeWithScale($aImg,$axscale,$ayscale) {
+        if( $this->iScalePosX === null || $this->iScalePosY === null ) {
+            $this->Stroke($aImg);
+        }
+        else {
+            $this->Stroke($aImg,
+                round($axscale->Translate($this->iScalePosX)),
+                round($ayscale->Translate($this->iScalePosY)));
+        }
+    }
+
+    function SetCSIMTarget($aURITarget,$aAlt='',$aWinTarget='') {
+        $this->iCSIMtarget = $aURITarget;
+        $this->iCSIMalt = $aAlt;
+        $this->iCSIMWinTarget = $aWinTarget;
+    }
+
+    function GetCSIMareas() {
+        if( $this->iCSIMtarget !== '' ) {
+            return $this->iCSIMarea;
+        }
+        else {
+            return '';
+        }
+    }
+
+    // Display text in image
+    function Stroke($aImg,$x=null,$y=null) {
+
+        if( $x !== null ) $this->x = round($x);
+        if( $y !== null ) $this->y = round($y);
+
+        // Insert newlines
+        if( $this->iWordwrap > 0 ) {
+            $this->t = wordwrap($this->t,$this->iWordwrap,"\n");
+        }
+
+        // If position been given as a fraction of the image size
+        // calculate the absolute position
+        if( $this->x < 1 && $this->x > 0 ) $this->x *= $aImg->width;
+        if( $this->y < 1 && $this->y > 0 ) $this->y *= $aImg->height;
+
+        $aImg->PushColor($this->color);
+        $aImg->SetFont($this->font_family,$this->font_style,$this->raw_font_size);
+        $aImg->SetTextAlign($this->halign,$this->valign);
+
+        if( $this->boxed ) {
+            if( $this->fcolor=="nofill" ) {
+                $this->fcolor=false;
+            }
+
+            $oldweight=$aImg->SetLineWeight(1);
+
+            if( $this->iBoxType == 2 && $this->font_family > FF_FONT2+2 ) {
+
+                $bbox = $aImg->StrokeBoxedText2($this->x, $this->y,
+                                                $this->t, $this->dir,
+                                                $this->fcolor,
+                                                $this->bcolor,
+                                                $this->shadow,
+                                                $this->paragraph_align,
+                                                2,4,
+                                                $this->icornerradius,
+                                                $this->ishadowwidth);
+            }
+            else {
+                $bbox = $aImg->StrokeBoxedText($this->x,$this->y,$this->t,
+                    $this->dir,$this->fcolor,$this->bcolor,$this->shadow,
+                    $this->paragraph_align,3,3,$this->icornerradius,
+                    $this->ishadowwidth);
+            }
+
+            $aImg->SetLineWeight($oldweight);
+        }
+        else {
+            $debug=false;
+            $bbox = $aImg->StrokeText($this->x,$this->y,$this->t,$this->dir,$this->paragraph_align,$debug);
+        }
+
+        // Create CSIM targets
+        $coords = $bbox[0].','.$bbox[1].','.$bbox[2].','.$bbox[3].','.$bbox[4].','.$bbox[5].','.$bbox[6].','.$bbox[7];
+        $this->iCSIMarea = "<area shape=\"poly\" coords=\"$coords\" href=\"".htmlentities($this->iCSIMtarget)."\" ";
+        if( trim($this->iCSIMalt) != '' ) {
+            $this->iCSIMarea .= " alt=\"".$this->iCSIMalt."\" ";
+            $this->iCSIMarea .= " title=\"".$this->iCSIMalt."\" ";
+        }
+        if( trim($this->iCSIMWinTarget) != '' ) {
+            $this->iCSIMarea .= " target=\"".$this->iCSIMWinTarget."\" ";
+        }
+        $this->iCSIMarea .= " />\n";
+
+        $aImg->PopColor($this->color);
+    }
+
+    function __get($name) {
+
+        if (strpos($name, 'raw_') !== false) {
+            // if $name == 'raw_left_margin' , return $this->_left_margin;
+            $variable_name = '_' . str_replace('raw_', '', $name);
+            return $this->$variable_name;
+        }
+
+        $variable_name = '_' . $name; 
+
+        if (isset($this->$variable_name)) {
+            return $this->$variable_name * SUPERSAMPLING_SCALE;
+        } else {
+            JpGraphError::RaiseL('25132', $name);
+        } 
+    }
+
+    function __set($name, $value) {
+        $this->{'_'.$name} = $value;
+    }
+} // Class
+
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_theme.inc.php b/web/classes/jpgraph/jpgraph_theme.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..0cc54c476865acb9d2024195ddc5e1487a2b3f5a
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_theme.inc.php
@@ -0,0 +1,136 @@
+<?php
+//=======================================================================
+// File:        JPGRAPH_THEME.INC.PHP
+// Description: Class to define graph theme
+// Created:     2010-09-29 
+// Ver:         $Id: jpgraph_theme.inc.php 83 2010-10-01 11:24:19Z atsushi $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+
+// include Theme classes
+foreach (glob(dirname(__FILE__) . '/themes/*.php') as $theme_class_script) {
+  require_once($theme_class_script);
+}
+
+//===================================================
+// CLASS 
+// Description: 
+//===================================================
+abstract class Theme {
+    protected $color_index;
+    
+    function __construct() {
+        $this->color_index = 0;
+    }
+    /**
+    * 
+    */
+    abstract function GetColorList();
+
+    /**
+    *
+    */
+    abstract function ApplyPlot($plot);
+
+
+    /**
+    *
+    */   
+    function SetupPlot($plot) {
+        if (is_array($plot)) {
+            foreach ($plot as $obj) {
+                $this->ApplyPlot($obj);
+            }
+        } else {
+            $this->ApplyPlot($plot);
+        }
+    }
+
+    /**
+    *
+    */
+    function ApplyGraph($graph) {
+
+        $this->graph = $graph;
+        $method_name = '';
+
+        if (get_class($graph) == 'Graph') {
+            $method_name = 'SetupGraph';
+        } else {
+            $method_name = 'Setup' . get_class($graph);
+        }
+
+        if (method_exists($this, $method_name)) {
+            $this->$method_name($graph);
+        } else {
+            JpGraphError::RaiseL(30001, $method_name, $method_name); //Theme::%s() is not defined. \nPlease make %s(\$graph) function in your theme classs.
+        }
+    }
+
+    /**
+    *
+    */
+    function PreStrokeApply($graph) {
+    }
+
+    /**
+    *
+    */
+    function GetThemeColors($num = 30) { 
+        $result_list = array();
+
+        $old_index = $this->color_index;
+        $this->color_index = 0;
+        $count = 0;
+  
+        $i = 0;
+        while (true) {
+            for ($j = 0; $j < count($this->GetColorList()); $j++) {
+                if (++$count > $num) {
+                    break 2;
+                }
+                $result_list[] = $this->GetNextColor();
+            }
+            $i++;
+        }
+
+        $this->color_index = $old_index;
+        
+        return $result_list;
+    }
+
+    /**
+    *
+    */
+    function GetNextColor() {
+        $color_list = $this->GetColorList();
+
+        $color = null;
+        if (isset($color_list[$this->color_index])) {
+            $color = $color_list[$this->color_index];
+        } else {
+            $color_count = count($color_list);
+            if ($color_count <= $this->color_index) {
+                $color_tmp = $color_list[$this->color_index % $color_count];
+                $brightness = 1.0 - intval($this->color_index / $color_count) * 0.2;
+                $rgb = new RGB();
+                $color = $color_tmp . ':' . $brightness;
+                $color = $rgb->Color($color);
+                $alpha = array_pop($color);
+                $color = $rgb->tryHexConversion($color);
+                if ($alpha) {
+                    $color .= '@' . $alpha;
+                }
+            }
+        }
+
+        $this->color_index++;
+
+        return $color;
+    }
+
+} // Class
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_ttf.inc.php b/web/classes/jpgraph/jpgraph_ttf.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..5a1bc3e23f8be16abc9347caca45c4b14748b9e0
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_ttf.inc.php
@@ -0,0 +1,631 @@
+<?php
+//=======================================================================
+// File:        jpgraph_ttf.inc.php
+// Description: Handling of TTF fonts
+// Created:     2006-11-19
+// Ver:         $Id: jpgraph_ttf.inc.php 1858 2009-09-28 14:39:51Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+
+// TTF Font families
+define("FF_COURIER",10);
+define("FF_VERDANA",11);
+define("FF_TIMES",12);
+define("FF_COMIC",14);
+define("FF_ARIAL",15);
+define("FF_GEORGIA",16);
+define("FF_TREBUCHE",17);
+
+// Gnome Vera font
+// Available from http://www.gnome.org/fonts/
+define("FF_VERA",18);
+define("FF_VERAMONO",19);
+define("FF_VERASERIF",20);
+
+// Chinese font
+define("FF_SIMSUN",30);
+define("FF_CHINESE",31);
+define("FF_BIG5",32);
+
+// Japanese font
+define("FF_MINCHO",40);
+define("FF_PMINCHO",41);
+define("FF_GOTHIC",42);
+define("FF_PGOTHIC",43);
+
+// Hebrew fonts
+define("FF_DAVID",44);
+define("FF_MIRIAM",45);
+define("FF_AHRON",46);
+
+// Dejavu-fonts http://sourceforge.net/projects/dejavu
+define("FF_DV_SANSSERIF",47);
+define("FF_DV_SERIF",48);
+define("FF_DV_SANSSERIFMONO",49);
+define("FF_DV_SERIFCOND",50);
+define("FF_DV_SANSSERIFCOND",51);
+
+// Extra fonts
+// Download fonts from
+// http://www.webfontlist.com
+// http://www.webpagepublicity.com/free-fonts.html
+// http://www.fontonic.com/fonts.asp?width=d&offset=120
+// http://www.fontspace.com/category/famous
+
+// define("FF_SPEEDO",71);  // This font is also known as Bauer (Used for development gauge fascia)
+define("FF_DIGITAL",72); // Digital readout font
+define("FF_COMPUTER",73); // The classic computer font
+define("FF_CALCULATOR",74); // Triad font
+
+define("FF_USERFONT",90);
+define("FF_USERFONT1",90);
+define("FF_USERFONT2",91);
+define("FF_USERFONT3",92);
+
+// Limits for fonts
+define("_FIRST_FONT",10);
+define("_LAST_FONT",99);
+
+// TTF Font styles
+define("FS_NORMAL",9001);
+define("FS_BOLD",9002);
+define("FS_ITALIC",9003);
+define("FS_BOLDIT",9004);
+define("FS_BOLDITALIC",9004);
+
+//Definitions for internal font
+define("FF_FONT0",1);
+define("FF_FONT1",2);
+define("FF_FONT2",4);
+
+//------------------------------------------------------------------------
+// Defines for font setup
+//------------------------------------------------------------------------
+
+// Actual name of the TTF file used together with FF_CHINESE aka FF_BIG5
+// This is the TTF file being used when the font family is specified as
+// either FF_CHINESE or FF_BIG5
+define('CHINESE_TTF_FONT','bkai00mp.ttf');
+
+// Special unicode greek language support
+define("LANGUAGE_GREEK",false);
+
+// If you are setting this config to true the conversion of greek characters
+// will assume that the input text is windows 1251
+define("GREEK_FROM_WINDOWS",false);
+
+// Special unicode cyrillic language support
+define("LANGUAGE_CYRILLIC",false);
+
+// If you are setting this config to true the conversion
+// will assume that the input text is windows 1251, if
+// false it will assume koi8-r
+define("CYRILLIC_FROM_WINDOWS",false);
+
+// The following constant is used to auto-detect
+// whether cyrillic conversion is really necessary
+// if enabled. Just replace 'windows-1251' with a variable
+// containing the input character encoding string
+// of your application calling jpgraph.
+// A typical such string would be 'UTF-8' or 'utf-8'.
+// The comparison is case-insensitive.
+// If this charset is not a 'koi8-r' or 'windows-1251'
+// derivate then no conversion is done.
+//
+// This constant can be very important in multi-user
+// multi-language environments where a cyrillic conversion
+// could be needed for some cyrillic people
+// and resulting in just erraneous conversions
+// for not-cyrillic language based people.
+//
+// Example: In the free project management
+// software dotproject.net $locale_char_set is dynamically
+// set by the language environment the user has chosen.
+//
+// Usage: define('LANGUAGE_CHARSET', $locale_char_set);
+//
+// where $locale_char_set is a GLOBAL (string) variable
+// from the application including JpGraph.
+//
+define('LANGUAGE_CHARSET', null);
+
+// Japanese TrueType font used with FF_MINCHO, FF_PMINCHO, FF_GOTHIC, FF_PGOTHIC
+// Standard fonts from Infomation-technology Promotion Agency (IPA)
+// See http://mix-mplus-ipa.sourceforge.jp/
+define('MINCHO_TTF_FONT','ipam.ttf');
+define('PMINCHO_TTF_FONT','ipamp.ttf');
+define('GOTHIC_TTF_FONT','ipag.ttf');
+define('PGOTHIC_TTF_FONT','ipagp.ttf');
+
+// Assume that Japanese text have been entered in EUC-JP encoding.
+// If this define is true then conversion from EUC-JP to UTF8 is done
+// automatically in the library using the mbstring module in PHP.
+define('ASSUME_EUCJP_ENCODING',false);
+
+
+// Default font family
+define('FF_DEFAULT', FF_DV_SANSSERIF);
+
+
+
+//=================================================================
+// CLASS LanguageConv
+// Description:
+// Converts various character encoding into proper
+// UTF-8 depending on how the library have been configured and
+// what font family is being used
+//=================================================================
+class LanguageConv {
+    private $g2312 = null ;
+
+    function Convert($aTxt,$aFF) {
+        if( LANGUAGE_GREEK ) {
+            if( GREEK_FROM_WINDOWS ) {
+                $unistring = LanguageConv::gr_win2uni($aTxt);
+            } else  {
+                $unistring = LanguageConv::gr_iso2uni($aTxt);
+            }
+            return $unistring;
+        } elseif( LANGUAGE_CYRILLIC ) {
+            if( CYRILLIC_FROM_WINDOWS && (!defined('LANGUAGE_CHARSET') || stristr(LANGUAGE_CHARSET, 'windows-1251')) ) {
+                $aTxt = convert_cyr_string($aTxt, "w", "k");
+            }
+            if( !defined('LANGUAGE_CHARSET') || stristr(LANGUAGE_CHARSET, 'koi8-r') || stristr(LANGUAGE_CHARSET, 'windows-1251')) {
+                $isostring = convert_cyr_string($aTxt, "k", "i");
+                $unistring = LanguageConv::iso2uni($isostring);
+            }
+            else {
+                $unistring = $aTxt;
+            }
+            return $unistring;
+        }
+        elseif( $aFF === FF_SIMSUN ) {
+            // Do Chinese conversion
+            if( $this->g2312 == null ) {
+                include_once 'jpgraph_gb2312.php' ;
+                $this->g2312 = new GB2312toUTF8();
+            }
+            return $this->g2312->gb2utf8($aTxt);
+        }
+        elseif( $aFF === FF_BIG5 ) {
+            if( !function_exists('iconv') ) {
+                JpGraphError::RaiseL(25006);
+                //('Usage of FF_CHINESE (FF_BIG5) font family requires that your PHP setup has the iconv() function. By default this is not compiled into PHP (needs the "--width-iconv" when configured).');
+            }
+            return iconv('BIG5','UTF-8',$aTxt);
+        }
+        elseif( ASSUME_EUCJP_ENCODING &&
+        ($aFF == FF_MINCHO || $aFF == FF_GOTHIC || $aFF == FF_PMINCHO || $aFF == FF_PGOTHIC) ) {
+            if( !function_exists('mb_convert_encoding') ) {
+                JpGraphError::RaiseL(25127);
+            }
+            return mb_convert_encoding($aTxt, 'UTF-8','EUC-JP');
+        }
+        elseif( $aFF == FF_DAVID || $aFF == FF_MIRIAM || $aFF == FF_AHRON ) {
+            return LanguageConv::heb_iso2uni($aTxt);
+        }
+        else
+        return $aTxt;
+    }
+
+    // Translate iso encoding to unicode
+    public static function iso2uni ($isoline){
+        $uniline='';
+        for ($i=0; $i < strlen($isoline); $i++){
+            $thischar=substr($isoline,$i,1);
+            $charcode=ord($thischar);
+            $uniline.=($charcode>175) ? "&#" . (1040+($charcode-176)). ";" : $thischar;
+        }
+        return $uniline;
+    }
+
+    // Translate greek iso encoding to unicode
+    public static function gr_iso2uni ($isoline) {
+        $uniline='';
+        for ($i=0; $i < strlen($isoline); $i++) {
+            $thischar=substr($isoline,$i,1);
+            $charcode=ord($thischar);
+            $uniline.=($charcode>179 && $charcode!=183 && $charcode!=187 && $charcode!=189) ? "&#" . (900+($charcode-180)). ";" : $thischar;
+        }
+        return $uniline;
+    }
+
+    // Translate greek win encoding to unicode
+    public static function gr_win2uni ($winline) {
+        $uniline='';
+        for ($i=0; $i < strlen($winline); $i++) {
+            $thischar=substr($winline,$i,1);
+            $charcode=ord($thischar);
+            if ($charcode==161 || $charcode==162) {
+                $uniline.="&#" . (740+$charcode). ";";
+            }
+            else {
+                $uniline.=(($charcode>183 && $charcode!=187 && $charcode!=189) || $charcode==180) ? "&#" . (900+($charcode-180)). ";" : $thischar;
+            }
+        }
+        return $uniline;
+    }
+
+    public static function heb_iso2uni($isoline) {
+        $isoline = hebrev($isoline);
+        $o = '';
+
+        $n = strlen($isoline);
+        for($i=0; $i < $n; $i++) {
+            $c=ord( substr($isoline,$i,1) );
+            $o .= ($c > 223) && ($c < 251) ? '&#'.(1264+$c).';' : chr($c);
+        }
+        return utf8_encode($o);
+    }
+}
+
+//=============================================================
+// CLASS TTF
+// Description: Handle TTF font names and mapping and loading of
+//              font files
+//=============================================================
+class TTF {
+    private $font_files,$style_names;
+
+    function __construct() {
+
+	        // String names for font styles to be used in error messages
+	    $this->style_names=array(
+	    	FS_NORMAL =>'normal',
+	    	FS_BOLD =>'bold',
+	    	FS_ITALIC =>'italic',
+	    	FS_BOLDITALIC =>'bolditalic');
+
+	    // File names for available fonts
+	    $this->font_files=array(
+	    FF_COURIER => array(FS_NORMAL =>'cour.ttf',
+	    	FS_BOLD  =>'courbd.ttf',
+	    	FS_ITALIC =>'couri.ttf',
+	    	FS_BOLDITALIC =>'courbi.ttf' ),
+	    FF_GEORGIA => array(FS_NORMAL =>'georgia.ttf',
+	    	FS_BOLD  =>'georgiab.ttf',
+	    	FS_ITALIC =>'georgiai.ttf',
+	    	FS_BOLDITALIC =>'' ),
+	    FF_TREBUCHE =>array(FS_NORMAL =>'trebuc.ttf',
+	    	FS_BOLD  =>'trebucbd.ttf',
+	    	FS_ITALIC =>'trebucit.ttf',
+	    	FS_BOLDITALIC =>'trebucbi.ttf' ),
+	    FF_VERDANA  => array(FS_NORMAL =>'verdana.ttf',
+	    	FS_BOLD  =>'verdanab.ttf',
+	    	FS_ITALIC =>'verdanai.ttf',
+	    	FS_BOLDITALIC =>'' ),
+	    FF_TIMES =>   array(FS_NORMAL =>'times.ttf',
+	    	FS_BOLD  =>'timesbd.ttf',
+	    	FS_ITALIC =>'timesi.ttf',
+	    	FS_BOLDITALIC =>'timesbi.ttf' ),
+	    FF_COMIC =>   array(FS_NORMAL =>'comic.ttf',
+	    	FS_BOLD  =>'comicbd.ttf',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ),
+	    FF_ARIAL =>   array(FS_NORMAL =>'arial.ttf',
+	    	FS_BOLD  =>'arialbd.ttf',
+	    	FS_ITALIC =>'ariali.ttf',
+	    	FS_BOLDITALIC =>'arialbi.ttf' ) ,
+	    FF_VERA =>    array(FS_NORMAL =>'Vera.ttf',
+	    	FS_BOLD  =>'VeraBd.ttf',
+	    	FS_ITALIC =>'VeraIt.ttf',
+	    	FS_BOLDITALIC =>'VeraBI.ttf' ),
+	    FF_VERAMONO => array(FS_NORMAL =>'VeraMono.ttf',
+	    	FS_BOLD =>'VeraMoBd.ttf',
+	    	FS_ITALIC =>'VeraMoIt.ttf',
+	    	FS_BOLDITALIC =>'VeraMoBI.ttf' ),
+	    FF_VERASERIF=> array(FS_NORMAL =>'VeraSe.ttf',
+	    	FS_BOLD =>'VeraSeBd.ttf',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ) ,
+
+	    /* Chinese fonts */
+	    FF_SIMSUN  =>  array(
+	    	FS_NORMAL =>'simsun.ttc',
+	    	FS_BOLD =>'simhei.ttf',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ),
+	    FF_CHINESE  =>   array(
+	    	FS_NORMAL =>CHINESE_TTF_FONT,
+	    	FS_BOLD =>'',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ),
+	    FF_BIG5  =>   array(
+	    	FS_NORMAL =>CHINESE_TTF_FONT,
+	    	FS_BOLD =>'',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ),
+
+	    /* Japanese fonts */
+	    FF_MINCHO  =>  array(
+	    	FS_NORMAL =>MINCHO_TTF_FONT,
+	    	FS_BOLD =>'',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ),
+
+	    FF_PMINCHO  =>  array(
+	    	FS_NORMAL =>PMINCHO_TTF_FONT,
+	    	FS_BOLD =>'',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ),
+
+	    FF_GOTHIC   =>  array(
+	    	FS_NORMAL =>GOTHIC_TTF_FONT,
+	    	FS_BOLD =>'',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ),
+
+	    FF_PGOTHIC  =>  array(
+	    	FS_NORMAL =>PGOTHIC_TTF_FONT,
+	    	FS_BOLD =>'',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ),
+
+	    /* Hebrew fonts */
+	    FF_DAVID  =>  array(
+	    	FS_NORMAL =>'DAVIDNEW.TTF',
+	    	FS_BOLD =>'',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ),
+
+	    FF_MIRIAM  =>  array(
+	    	FS_NORMAL =>'MRIAMY.TTF',
+	    	FS_BOLD =>'',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ),
+
+	    FF_AHRON  =>  array(
+	    	FS_NORMAL =>'ahronbd.ttf',
+	    	FS_BOLD =>'',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ),
+
+	    /* Misc fonts */
+	    FF_DIGITAL =>   array(
+	    	FS_NORMAL =>'DIGIRU__.TTF',
+	    	FS_BOLD =>'Digirtu_.ttf',
+	    	FS_ITALIC =>'Digir___.ttf',
+	    	FS_BOLDITALIC =>'DIGIRT__.TTF' ),
+
+	    /* This is an experimental font for the speedometer development
+	    FF_SPEEDO =>    array(
+	    FS_NORMAL =>'Speedo.ttf',
+	    FS_BOLD =>'',
+	    FS_ITALIC =>'',
+	    FS_BOLDITALIC =>'' ),
+	    */
+
+	    FF_COMPUTER  =>  array(
+	    	FS_NORMAL =>'COMPUTER.TTF',
+	    	FS_BOLD =>'',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ),
+
+	    FF_CALCULATOR => array(
+	    	FS_NORMAL =>'Triad_xs.ttf',
+	    	FS_BOLD =>'',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ),
+
+	    /* Dejavu fonts */
+	    FF_DV_SANSSERIF => array(
+	    	FS_NORMAL =>array('DejaVuSans.ttf'),
+	    	FS_BOLD =>array('DejaVuSans-Bold.ttf','DejaVuSansBold.ttf'),
+	    	FS_ITALIC =>array('DejaVuSans-Oblique.ttf','DejaVuSansOblique.ttf'),
+	    	FS_BOLDITALIC =>array('DejaVuSans-BoldOblique.ttf','DejaVuSansBoldOblique.ttf') ),
+
+	    FF_DV_SANSSERIFMONO => array(
+	    	FS_NORMAL =>array('DejaVuSansMono.ttf','DejaVuMonoSans.ttf'),
+	    	FS_BOLD =>array('DejaVuSansMono-Bold.ttf','DejaVuMonoSansBold.ttf'),
+	    	FS_ITALIC =>array('DejaVuSansMono-Oblique.ttf','DejaVuMonoSansOblique.ttf'),
+	    	FS_BOLDITALIC =>array('DejaVuSansMono-BoldOblique.ttf','DejaVuMonoSansBoldOblique.ttf') ),
+
+	    FF_DV_SANSSERIFCOND => array(
+	    	FS_NORMAL =>array('DejaVuSansCondensed.ttf','DejaVuCondensedSans.ttf'),
+	    	FS_BOLD =>array('DejaVuSansCondensed-Bold.ttf','DejaVuCondensedSansBold.ttf'),
+	    	FS_ITALIC =>array('DejaVuSansCondensed-Oblique.ttf','DejaVuCondensedSansOblique.ttf'),
+	    	FS_BOLDITALIC =>array('DejaVuSansCondensed-BoldOblique.ttf','DejaVuCondensedSansBoldOblique.ttf') ),
+
+	    FF_DV_SERIF => array(
+	    	FS_NORMAL =>array('DejaVuSerif.ttf'),
+	    	FS_BOLD =>array('DejaVuSerif-Bold.ttf','DejaVuSerifBold.ttf'),
+	    	FS_ITALIC =>array('DejaVuSerif-Italic.ttf','DejaVuSerifItalic.ttf'),
+	    	FS_BOLDITALIC =>array('DejaVuSerif-BoldItalic.ttf','DejaVuSerifBoldItalic.ttf') ),
+
+	    FF_DV_SERIFCOND => array(
+	    	FS_NORMAL =>array('DejaVuSerifCondensed.ttf','DejaVuCondensedSerif.ttf'),
+	    	FS_BOLD =>array('DejaVuSerifCondensed-Bold.ttf','DejaVuCondensedSerifBold.ttf'),
+	    	FS_ITALIC =>array('DejaVuSerifCondensed-Italic.ttf','DejaVuCondensedSerifItalic.ttf'),
+	    	FS_BOLDITALIC =>array('DejaVuSerifCondensed-BoldItalic.ttf','DejaVuCondensedSerifBoldItalic.ttf') ),
+
+
+	    /* Placeholders for defined fonts */
+	    FF_USERFONT1 => array(
+	    	FS_NORMAL =>'',
+	    	FS_BOLD =>'',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ),
+
+	    FF_USERFONT2 => array(
+	    	FS_NORMAL =>'',
+	    	FS_BOLD =>'',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ),
+
+	    FF_USERFONT3 => array(
+	    	FS_NORMAL =>'',
+	    	FS_BOLD =>'',
+	    	FS_ITALIC =>'',
+	    	FS_BOLDITALIC =>'' ),
+
+	    );
+    }
+
+    //---------------
+    // PUBLIC METHODS
+    // Create the TTF file from the font specification
+    function File($family,$style=FS_NORMAL) {
+        $fam = @$this->font_files[$family];
+        if( !$fam ) {
+            JpGraphError::RaiseL(25046,$family);//("Specified TTF font family (id=$family) is unknown or does not exist. Please note that TTF fonts are not distributed with JpGraph for copyright reasons. You can find the MS TTF WEB-fonts (arial, courier etc) for download at http://corefonts.sourceforge.net/");
+        }
+        $ff = @$fam[$style];
+
+        // There are several optional file names. They are tried in order
+        // and the first one found is used
+        if( !is_array($ff) ) {
+            $ff = array($ff);
+        }
+
+        $jpgraph_font_dir = dirname(__FILE__).'/fonts/';
+
+        foreach ($ff as $font_file) {
+            // All font families are guaranteed to have the normal style
+
+            if( $font_file==='' )
+                    JpGraphError::RaiseL(25047,$this->style_names[$style],$this->font_files[$family][FS_NORMAL]);//('Style "'.$this->style_names[$style].'" is not available for font family '.$this->font_files[$family][FS_NORMAL].'.');
+            if( !$font_file ) {
+                JpGraphError::RaiseL(25048,$fam);//("Unknown font style specification [$fam].");
+            }
+
+            // check jpgraph/src/fonts dir
+            $jpgraph_font_file = $jpgraph_font_dir . $font_file;
+            if (file_exists($jpgraph_font_file) === true && is_readable($jpgraph_font_file) === true) { 
+                $font_file = $jpgraph_font_file;
+                break;
+            }
+
+            // check OS font dir
+            if ($family >= FF_MINCHO && $family <= FF_PGOTHIC) {
+                $font_file = MBTTF_DIR.$font_file;
+            } else {
+                $font_file = TTF_DIR.$font_file;
+            }
+            if (file_exists($font_file) === true && is_readable($font_file) === true) { 
+                break;
+            }
+        }
+
+        if( !file_exists($font_file) ) {
+        	JpGraphError::RaiseL(25049,$font_file);//("Font file \"$font_file\" is not readable or does not exist.");
+        }
+
+        return $font_file;
+    }
+
+    function SetUserFont($aNormal,$aBold='',$aItalic='',$aBoldIt='') {
+        $this->font_files[FF_USERFONT] =
+        	array(FS_NORMAL     => $aNormal,
+        		  FS_BOLD => $aBold,
+        		  FS_ITALIC => $aItalic,
+        		  FS_BOLDITALIC => $aBoldIt ) ;
+    }
+
+    function SetUserFont1($aNormal,$aBold='',$aItalic='',$aBoldIt='') {
+        $this->font_files[FF_USERFONT1] =
+        	array(FS_NORMAL     => $aNormal,
+        		  FS_BOLD => $aBold,
+        		  FS_ITALIC => $aItalic,
+        		  FS_BOLDITALIC => $aBoldIt ) ;
+    }
+
+    function SetUserFont2($aNormal,$aBold='',$aItalic='',$aBoldIt='') {
+        $this->font_files[FF_USERFONT2] =
+        	array(FS_NORMAL     => $aNormal,
+        		  FS_BOLD => $aBold,
+        		  FS_ITALIC => $aItalic,
+        		  FS_BOLDITALIC => $aBoldIt ) ;
+    }
+
+    function SetUserFont3($aNormal,$aBold='',$aItalic='',$aBoldIt='') {
+        $this->font_files[FF_USERFONT3] =
+        	array(FS_NORMAL     => $aNormal,
+        		  FS_BOLD => $aBold,
+        		  FS_ITALIC => $aItalic,
+        		  FS_BOLDITALIC => $aBoldIt ) ;
+    }
+
+} // Class
+
+
+//=============================================================================
+// CLASS SymChar
+// Description: Code values for some commonly used characters that
+//              normally isn't available directly on the keyboard, for example
+//              mathematical and greek symbols.
+//=============================================================================
+class  SymChar {
+    static function Get($aSymb,$aCapital=FALSE) {
+        $iSymbols = array(
+        /* Greek */
+        array('alpha','03B1','0391'),
+        array('beta','03B2','0392'),
+        array('gamma','03B3','0393'),
+        array('delta','03B4','0394'),
+        array('epsilon','03B5','0395'),
+        array('zeta','03B6','0396'),
+        array('ny','03B7','0397'),
+        array('eta','03B8','0398'),
+        array('theta','03B8','0398'),
+        array('iota','03B9','0399'),
+        array('kappa','03BA','039A'),
+        array('lambda','03BB','039B'),
+        array('mu','03BC','039C'),
+        array('nu','03BD','039D'),
+        array('xi','03BE','039E'),
+        array('omicron','03BF','039F'),
+        array('pi','03C0','03A0'),
+        array('rho','03C1','03A1'),
+        array('sigma','03C3','03A3'),
+        array('tau','03C4','03A4'),
+        array('upsilon','03C5','03A5'),
+        array('phi','03C6','03A6'),
+        array('chi','03C7','03A7'),
+        array('psi','03C8','03A8'),
+        array('omega','03C9','03A9'),
+        /* Money */
+        array('euro','20AC'),
+        array('yen','00A5'),
+        array('pound','20A4'),
+        /* Math */
+        array('approx','2248'),
+        array('neq','2260'),
+        array('not','2310'),
+        array('def','2261'),
+        array('inf','221E'),
+        array('sqrt','221A'),
+        array('int','222B'),
+        /* Misc */
+        array('copy','00A9'),
+        array('para','00A7'),
+        array('tm','2122'),   /* Trademark symbol */
+        array('rtm','00AE'),   /* Registered trademark */
+        array('degree','00b0'),
+        array('lte','2264'), /* Less than or equal */
+        array('gte','2265'), /* Greater than or equal */
+
+        );
+
+        $n = count($iSymbols);
+        $i=0;
+        $found = false;
+        $aSymb = strtolower($aSymb);
+        while( $i < $n && !$found ) {
+            $found = $aSymb === $iSymbols[$i++][0];
+        }
+        if( $found ) {
+            $ca = $iSymbols[--$i];
+            if( $aCapital && count($ca)==3 )
+                $s = $ca[2];
+            else
+                $s = $ca[1];
+            return sprintf('&#%04d;',hexdec($s));
+        }
+        else
+            return '';
+    }
+}
+
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_utils.inc.php b/web/classes/jpgraph/jpgraph_utils.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..f0d002c14d02518e6acbfd213efcab11d41d4d73
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_utils.inc.php
@@ -0,0 +1,685 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_UTILS.INC
+ // Description: Collection of non-essential "nice to have" utilities
+ // Created:     2005-11-20
+ // Ver:         $Id: jpgraph_utils.inc.php 1777 2009-08-23 17:34:36Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+//===================================================
+// CLASS FuncGenerator
+// Description: Utility class to help generate data for function plots.
+// The class supports both parametric and regular functions.
+//===================================================
+class FuncGenerator {
+    private $iFunc='',$iXFunc='',$iMin,$iMax,$iStepSize;
+
+    function __construct($aFunc,$aXFunc='') {
+        $this->iFunc = $aFunc;
+        $this->iXFunc = $aXFunc;
+    }
+
+    function E($aXMin,$aXMax,$aSteps=50) {
+        $this->iMin = $aXMin;
+        $this->iMax = $aXMax;
+        $this->iStepSize = ($aXMax-$aXMin)/$aSteps;
+
+        if( $this->iXFunc != '' )
+        $t = 'for($i='.$aXMin.'; $i<='.$aXMax.'; $i += '.$this->iStepSize.') {$ya[]='.$this->iFunc.';$xa[]='.$this->iXFunc.';}';
+        elseif( $this->iFunc != '' )
+        $t = 'for($x='.$aXMin.'; $x<='.$aXMax.'; $x += '.$this->iStepSize.') {$ya[]='.$this->iFunc.';$xa[]=$x;} $x='.$aXMax.';$ya[]='.$this->iFunc.';$xa[]=$x;';
+        else
+        JpGraphError::RaiseL(24001);//('FuncGenerator : No function specified. ');
+
+        @eval($t);
+
+        // If there is an error in the function specifcation this is the only
+        // way we can discover that.
+        if( empty($xa) || empty($ya) )
+        JpGraphError::RaiseL(24002);//('FuncGenerator : Syntax error in function specification ');
+
+        return array($xa,$ya);
+    }
+}
+
+
+//=============================================================================
+// CLASS DateScaleUtils
+// Description: Help to create a manual date scale
+//=============================================================================
+define('DSUTILS_MONTH',1); // Major and minor ticks on a monthly basis
+define('DSUTILS_MONTH1',1); // Major and minor ticks on a monthly basis
+define('DSUTILS_MONTH2',2); // Major ticks on a bi-monthly basis
+define('DSUTILS_MONTH3',3); // Major icks on a tri-monthly basis
+define('DSUTILS_MONTH6',4); // Major on a six-monthly basis
+define('DSUTILS_WEEK1',5); // Major ticks on a weekly basis
+define('DSUTILS_WEEK2',6); // Major ticks on a bi-weekly basis
+define('DSUTILS_WEEK4',7); // Major ticks on a quod-weekly basis
+define('DSUTILS_DAY1',8); // Major ticks on a daily basis
+define('DSUTILS_DAY2',9); // Major ticks on a bi-daily basis
+define('DSUTILS_DAY4',10); // Major ticks on a qoud-daily basis
+define('DSUTILS_YEAR1',11); // Major ticks on a yearly basis
+define('DSUTILS_YEAR2',12); // Major ticks on a bi-yearly basis
+define('DSUTILS_YEAR5',13); // Major ticks on a five-yearly basis
+
+
+class DateScaleUtils {
+    public static $iMin=0, $iMax=0;
+
+    private static $starthour,$startmonth, $startday, $startyear;
+    private static $endmonth, $endyear, $endday;
+    private static $tickPositions=array(),$minTickPositions=array();
+    private static $iUseWeeks = true;
+
+    static function UseWeekFormat($aFlg) {
+        self::$iUseWeeks = $aFlg;
+    }
+
+    static function doYearly($aType,$aMinor=false) {
+        $i=0; $j=0;
+        $m = self::$startmonth;
+        $y = self::$startyear;
+
+        if( self::$startday == 1 ) {
+            self::$tickPositions[$i++] = mktime(0,0,0,$m,1,$y);
+        }
+        ++$m;
+
+
+        switch( $aType ) {
+            case DSUTILS_YEAR1:
+                for($y=self::$startyear; $y <= self::$endyear; ++$y ) {
+                    if( $aMinor ) {
+                        while( $m <= 12 ) {
+                            if( !($y == self::$endyear && $m > self::$endmonth) ) {
+                                self::$minTickPositions[$j++] = mktime(0,0,0,$m,1,$y);
+                            }
+                            ++$m;
+                        }
+                        $m=1;
+                    }
+                    self::$tickPositions[$i++] = mktime(0,0,0,1,1,$y);
+                }
+                break;
+            case DSUTILS_YEAR2:
+                $y=self::$startyear;
+                while( $y <= self::$endyear ) {
+                    self::$tickPositions[$i++] = mktime(0,0,0,1,1,$y);
+                    for($k=0; $k < 1; ++$k ) {
+                        ++$y;
+                        if( $aMinor ) {
+                            self::$minTickPositions[$j++] = mktime(0,0,0,1,1,$y);
+                        }
+                    }
+                    ++$y;
+                }
+                break;
+            case DSUTILS_YEAR5:
+                $y=self::$startyear;
+                while( $y <= self::$endyear ) {
+                    self::$tickPositions[$i++] = mktime(0,0,0,1,1,$y);
+                    for($k=0; $k < 4; ++$k ) {
+                        ++$y;
+                        if( $aMinor ) {
+                            self::$minTickPositions[$j++] = mktime(0,0,0,1,1,$y);
+                        }
+                    }
+                    ++$y;
+                }
+                break;
+        }
+    }
+
+    static function doDaily($aType,$aMinor=false) {
+        $m = self::$startmonth;
+        $y = self::$startyear;
+        $d = self::$startday;
+        $h = self::$starthour;
+        $i=0;$j=0;
+
+        if( $h == 0 ) {
+            self::$tickPositions[$i++] = mktime(0,0,0,$m,$d,$y);
+        }
+        $t = mktime(0,0,0,$m,$d,$y);
+
+        switch($aType) {
+            case DSUTILS_DAY1:
+                while( $t <= self::$iMax ) {
+                    $t = strtotime('+1 day',$t);
+                    self::$tickPositions[$i++] = $t;
+                    if( $aMinor ) {
+                        self::$minTickPositions[$j++] = strtotime('+12 hours',$t);
+                    }
+                }
+                break;
+            case DSUTILS_DAY2:
+                while( $t <= self::$iMax ) {
+                    $t = strtotime('+1 day',$t);
+                    if( $aMinor ) {
+                        self::$minTickPositions[$j++] = $t;
+                    }
+                    $t = strtotime('+1 day',$t);
+                    self::$tickPositions[$i++] = $t;
+                }
+                break;
+            case DSUTILS_DAY4:
+                while( $t <= self::$iMax ) {
+                    for($k=0; $k < 3; ++$k ) {
+                        $t = strtotime('+1 day',$t);
+                        if( $aMinor ) {
+                            self::$minTickPositions[$j++] = $t;
+                        }
+                    }
+                    $t = strtotime('+1 day',$t);
+                    self::$tickPositions[$i++] = $t;
+                }
+                break;
+        }
+    }
+
+    static function doWeekly($aType,$aMinor=false) {
+        $hpd = 3600*24;
+        $hpw = 3600*24*7;
+        // Find out week number of min date
+        $thursday = self::$iMin + $hpd * (3 - (date('w', self::$iMin) + 6) % 7);
+        $week = 1 + (date('z', $thursday) - (11 - date('w', mktime(0, 0, 0, 1, 1, date('Y', $thursday)))) % 7) / 7;
+        $daynumber = date('w',self::$iMin);
+        if( $daynumber == 0 ) $daynumber = 7;
+        $m = self::$startmonth;
+        $y = self::$startyear;
+        $d = self::$startday;
+        $i=0;$j=0;
+        // The assumption is that the weeks start on Monday. If the first day
+        // is later in the week then the first week tick has to be on the following
+        // week.
+        if( $daynumber == 1 ) {
+            self::$tickPositions[$i++] = mktime(0,0,0,$m,$d,$y);
+            $t = mktime(0,0,0,$m,$d,$y) + $hpw;
+        }
+        else {
+            $t = mktime(0,0,0,$m,$d,$y) + $hpd*(8-$daynumber);
+        }
+
+        switch($aType) {
+            case DSUTILS_WEEK1:
+                $cnt=0;
+                break;
+            case DSUTILS_WEEK2:
+                $cnt=1;
+                break;
+            case DSUTILS_WEEK4:
+                $cnt=3;
+                break;
+        }
+        while( $t <= self::$iMax ) {
+            self::$tickPositions[$i++] = $t;
+            for($k=0; $k < $cnt; ++$k ) {
+                $t += $hpw;
+                if( $aMinor ) {
+                    self::$minTickPositions[$j++] = $t;
+                }
+            }
+            $t += $hpw;
+        }
+    }
+
+    static function doMonthly($aType,$aMinor=false) {
+        $monthcount=0;
+        $m = self::$startmonth;
+        $y = self::$startyear;
+        $i=0; $j=0;
+
+        // Skip the first month label if it is before the startdate
+        if( self::$startday == 1 ) {
+            self::$tickPositions[$i++] = mktime(0,0,0,$m,1,$y);
+            $monthcount=1;
+        }
+        if( $aType == 1 ) {
+            if( self::$startday < 15 ) {
+                self::$minTickPositions[$j++] = mktime(0,0,0,$m,15,$y);
+            }
+        }
+        ++$m;
+
+        // Loop through all the years included in the scale
+        for($y=self::$startyear; $y <= self::$endyear; ++$y ) {
+            // Loop through all the months. There are three cases to consider:
+            // 1. We are in the first year and must start with the startmonth
+            // 2. We are in the end year and we must stop at last month of the scale
+            // 3. A year in between where we run through all the 12 months
+            $stopmonth = $y == self::$endyear ? self::$endmonth : 12;
+            while( $m <= $stopmonth ) {
+                switch( $aType ) {
+                    case DSUTILS_MONTH1:
+                        // Set minor tick at the middle of the month
+                        if( $aMinor ) {
+                            if( $m <= $stopmonth ) {
+                                if( !($y==self::$endyear && $m==$stopmonth && self::$endday < 15) )
+                                self::$minTickPositions[$j++] = mktime(0,0,0,$m,15,$y);
+                            }
+                        }
+                        // Major at month
+                        // Get timestamp of first hour of first day in each month
+                        self::$tickPositions[$i++] = mktime(0,0,0,$m,1,$y);
+
+                        break;
+                    case DSUTILS_MONTH2:
+                        if( $aMinor ) {
+                            // Set minor tick at start of each month
+                            self::$minTickPositions[$j++] = mktime(0,0,0,$m,1,$y);
+                        }
+
+                        // Major at every second month
+                        // Get timestamp of first hour of first day in each month
+                        if( $monthcount % 2 == 0 ) {
+                            self::$tickPositions[$i++] = mktime(0,0,0,$m,1,$y);
+                        }
+                        break;
+                    case DSUTILS_MONTH3:
+                        if( $aMinor ) {
+                            // Set minor tick at start of each month
+                            self::$minTickPositions[$j++] = mktime(0,0,0,$m,1,$y);
+                        }
+                        // Major at every third month
+                        // Get timestamp of first hour of first day in each month
+                        if( $monthcount % 3 == 0 ) {
+                            self::$tickPositions[$i++] = mktime(0,0,0,$m,1,$y);
+                        }
+                        break;
+                    case DSUTILS_MONTH6:
+                        if( $aMinor ) {
+                            // Set minor tick at start of each month
+                            self::$minTickPositions[$j++] = mktime(0,0,0,$m,1,$y);
+                        }
+                        // Major at every third month
+                        // Get timestamp of first hour of first day in each month
+                        if( $monthcount % 6 == 0 ) {
+                            self::$tickPositions[$i++] = mktime(0,0,0,$m,1,$y);
+                        }
+                        break;
+                }
+                ++$m;
+                ++$monthcount;
+            }
+            $m=1;
+        }
+
+        // For the case where all dates are within the same month
+        // we want to make sure we have at least two ticks on the scale
+        // since the scale want work properly otherwise
+        if(self::$startmonth == self::$endmonth && self::$startyear == self::$endyear && $aType==1 ) {
+            self::$tickPositions[$i++] = mktime(0 ,0 ,0, self::$startmonth + 1, 1, self::$startyear);
+        }
+
+        return array(self::$tickPositions,self::$minTickPositions);
+    }
+
+    static function GetTicks($aData,$aType=1,$aMinor=false,$aEndPoints=false) {
+        $n = count($aData);
+        return self::GetTicksFromMinMax($aData[0],$aData[$n-1],$aType,$aMinor,$aEndPoints);
+    }
+
+    static function GetAutoTicks($aMin,$aMax,$aMaxTicks=10,$aMinor=false) {
+        $diff = $aMax - $aMin;
+        $spd = 3600*24;
+        $spw = $spd*7;
+        $spm = $spd*30;
+        $spy = $spd*352;
+
+        if( self::$iUseWeeks )
+        $w = 'W';
+        else
+        $w = 'd M';
+
+        // Decision table for suitable scales
+        // First value: Main decision point
+        // Second value: Array of formatting depending on divisor for wanted max number of ticks. <divisor><formatting><format-string>,..
+        $tt = array(
+            array($spw, array(1,DSUTILS_DAY1,'d M',2,DSUTILS_DAY2,'d M',-1,DSUTILS_DAY4,'d M')),
+            array($spm, array(1,DSUTILS_DAY1,'d M',2,DSUTILS_DAY2,'d M',4,DSUTILS_DAY4,'d M',7,DSUTILS_WEEK1,$w,-1,DSUTILS_WEEK2,$w)),
+            array($spy, array(1,DSUTILS_DAY1,'d M',2,DSUTILS_DAY2,'d M',4,DSUTILS_DAY4,'d M',7,DSUTILS_WEEK1,$w,14,DSUTILS_WEEK2,$w,30,DSUTILS_MONTH1,'M',60,DSUTILS_MONTH2,'M',-1,DSUTILS_MONTH3,'M')),
+            array(-1, array(30,DSUTILS_MONTH1,'M-Y',60,DSUTILS_MONTH2,'M-Y',90,DSUTILS_MONTH3,'M-Y',180,DSUTILS_MONTH6,'M-Y',352,DSUTILS_YEAR1,'Y',704,DSUTILS_YEAR2,'Y',-1,DSUTILS_YEAR5,'Y')));
+
+        $ntt = count($tt);
+        $nd = floor($diff/$spd);
+        for($i=0; $i < $ntt; ++$i ) {
+            if( $diff <= $tt[$i][0] || $i==$ntt-1) {
+                $t = $tt[$i][1];
+                $n = count($t)/3;
+                for( $j=0; $j < $n; ++$j ) {
+                    if( $nd/$t[3*$j] <= $aMaxTicks || $j==$n-1) {
+                        $type = $t[3*$j+1];
+                        $fs = $t[3*$j+2];
+                        list($tickPositions,$minTickPositions) = self::GetTicksFromMinMax($aMin,$aMax,$type,$aMinor);
+                        return array($fs,$tickPositions,$minTickPositions,$type);
+                    }
+                }
+            }
+        }
+    }
+
+    static function GetTicksFromMinMax($aMin,$aMax,$aType,$aMinor=false,$aEndPoints=false) {
+        self::$starthour = date('G',$aMin);
+        self::$startmonth = date('n',$aMin);
+        self::$startday = date('j',$aMin);
+        self::$startyear = date('Y',$aMin);
+        self::$endmonth = date('n',$aMax);
+        self::$endyear = date('Y',$aMax);
+        self::$endday = date('j',$aMax);
+        self::$iMin = $aMin;
+        self::$iMax = $aMax;
+
+        if( $aType <= DSUTILS_MONTH6 ) {
+            self::doMonthly($aType,$aMinor);
+        }
+        elseif( $aType <= DSUTILS_WEEK4 ) {
+            self::doWeekly($aType,$aMinor);
+        }
+        elseif( $aType <= DSUTILS_DAY4 ) {
+            self::doDaily($aType,$aMinor);
+        }
+        elseif( $aType <= DSUTILS_YEAR5 ) {
+            self::doYearly($aType,$aMinor);
+        }
+        else {
+            JpGraphError::RaiseL(24003);
+        }
+        // put a label at the very left data pos
+        if( $aEndPoints ) {
+            $tickPositions[$i++] = $aData[0];
+        }
+
+        // put a label at the very right data pos
+        if( $aEndPoints ) {
+            $tickPositions[$i] = $aData[$n-1];
+        }
+
+        return array(self::$tickPositions,self::$minTickPositions);
+    }
+}
+
+//=============================================================================
+// Class ReadFileData
+//=============================================================================
+Class ReadFileData {
+    //----------------------------------------------------------------------------
+    // Desciption:
+    // Read numeric data from a file.
+    // Each value should be separated by either a new line or by a specified
+    // separator character (default is ',').
+    // Before returning the data each value is converted to a proper float
+    // value. The routine is robust in the sense that non numeric data in the
+    // file will be discarded.
+    //
+    // Returns:
+    // The number of data values read on success, FALSE on failure
+    //----------------------------------------------------------------------------
+    static function FromCSV($aFile,&$aData,$aSepChar=',',$aMaxLineLength=1024) {
+        $rh = @fopen($aFile,'r');
+        if( $rh === false ) {
+                return false;
+        }
+        $tmp = array();
+        $lineofdata = fgetcsv($rh, 1000, ',');
+        while ( $lineofdata !== FALSE) {
+            $tmp = array_merge($tmp,$lineofdata);
+            $lineofdata = fgetcsv($rh, $aMaxLineLength, $aSepChar);
+        }
+        fclose($rh);
+
+        // Now make sure that all data is numeric. By default
+        // all data is read as strings
+        $n = count($tmp);
+        $aData = array();
+        $cnt=0;
+        for($i=0; $i < $n; ++$i) {
+            if( $tmp[$i] !== "" ) {
+                $aData[$cnt++] = floatval($tmp[$i]);
+            }
+        }
+        return $cnt;
+    }
+
+    //----------------------------------------------------------------------------
+    // Desciption:
+    // Read numeric data from a file.
+    // Each value should be separated by either a new line or by a specified
+    // separator character (default is ',').
+    // Before returning the data each value is converted to a proper float
+    // value. The routine is robust in the sense that non numeric data in the
+    // file will be discarded.
+    //
+    // Options:
+    // 'separator'     => ',',
+    // 'enclosure'     => '"',
+    // 'readlength'    => 1024,
+    // 'ignore_first'  => false,
+    // 'first_as_key'  => false
+    // 'escape'        => '\',   # PHP >= 5.3 only
+    //
+    // Returns:
+    // The number of lines read on success, FALSE on failure
+    //----------------------------------------------------------------------------
+    static function FromCSV2($aFile, &$aData, $aOptions = array()) {
+        $aDefaults = array(
+            'separator'     => ',',
+            'enclosure'     => chr(34),
+            'escape'        => chr(92),
+            'readlength'    => 1024,
+            'ignore_first'  => false,
+            'first_as_key'  => false
+            );
+
+        $aOptions = array_merge(
+            $aDefaults, is_array($aOptions) ? $aOptions : array());
+
+        if( $aOptions['first_as_key'] ) {
+            $aOptions['ignore_first'] =  true;
+        }
+
+        $rh = @fopen($aFile, 'r');
+
+        if( $rh === false ) {
+            return false;
+        }
+
+        $aData  = array();
+        $aLine  = fgetcsv($rh,
+                          $aOptions['readlength'],
+                          $aOptions['separator'],
+                          $aOptions['enclosure']
+                          /*, $aOptions['escape']     # PHP >= 5.3 only */
+                          );
+
+        // Use numeric array keys for the columns by default
+        // If specified use first lines values as assoc keys instead
+        $keys = array_keys($aLine);
+        if( $aOptions['first_as_key'] ) {
+            $keys = array_values($aLine);
+        }
+
+        $num_lines = 0;
+        $num_cols  = count($aLine);
+
+        while ($aLine !== false) {
+            if( is_array($aLine) && count($aLine) != $num_cols ) {
+                JpGraphError::RaiseL(24004);
+                // 'ReadCSV2: Column count mismatch in %s line %d'
+            }
+
+            // fgetcsv returns NULL for empty lines
+            if( !is_null($aLine) ) {
+                $num_lines++;
+
+                if( !($aOptions['ignore_first'] && $num_lines == 1) && is_numeric($aLine[0]) ) {
+                    for( $i = 0; $i < $num_cols; $i++ ) {
+                        $aData[ $keys[$i] ][] = floatval($aLine[$i]);
+                    }
+                }
+            }
+
+            $aLine = fgetcsv($rh,
+                             $aOptions['readlength'],
+                             $aOptions['separator'],
+                             $aOptions['enclosure']
+                             /*, $aOptions['escape']     # PHP >= 5.3 only*/
+                );
+        }
+
+        fclose($rh);
+
+        if( $aOptions['ignore_first'] ) {
+            $num_lines--;
+        }
+
+        return $num_lines;
+    }
+
+    // Read data from two columns in a plain text file
+    static function From2Col($aFile, $aCol1, $aCol2, $aSepChar=' ') {
+        $lines = @file($aFile,FILE_IGNORE_NEW_LINES|FILE_SKIP_EMPTY_LINES);
+        if( $lines === false ) {
+                return false;
+        }
+        $s = '/[\s]+/';
+        if( $aSepChar == ',' ) {
+                        $s = '/[\s]*,[\s]*/';
+        }
+        elseif( $aSepChar == ';' ) {
+                        $s = '/[\s]*;[\s]*/';
+        }
+        foreach( $lines as $line => $datarow ) {
+                $split = preg_split($s,$datarow);
+                $aCol1[] = floatval(trim($split[0]));
+                $aCol2[] = floatval(trim($split[1]));
+        }
+
+        return count($lines);
+    }
+
+    // Read data from one columns in a plain text file
+    static function From1Col($aFile, $aCol1) {
+        $lines = @file($aFile,FILE_IGNORE_NEW_LINES|FILE_SKIP_EMPTY_LINES);
+        if( $lines === false ) {
+                return false;
+        }
+        foreach( $lines as $line => $datarow ) {
+                $aCol1[] = floatval(trim($datarow));
+        }
+
+        return count($lines);
+    }
+
+    static function FromMatrix($aFile,$aSepChar=' ') {
+        $lines = @file($aFile,FILE_IGNORE_NEW_LINES|FILE_SKIP_EMPTY_LINES);
+        if( $lines === false ) {
+                return false;
+        }
+        $mat = array();
+        $reg = '/'.$aSepChar.'/';
+        foreach( $lines as $line => $datarow ) {
+                $row = preg_split($reg,trim($datarow));
+                foreach ($row as $key => $cell ) {
+                        $row[$key] = floatval(trim($cell));
+                }
+                $mat[] = $row;
+        }
+        return $mat;
+    }
+
+
+}
+
+define('__LR_EPSILON', 1.0e-8);
+//=============================================================================
+// Class LinearRegression
+//=============================================================================
+class LinearRegression {
+        private $ix=array(),$iy=array();
+        private $ib=0, $ia=0;
+        private $icalculated=false;
+        public $iDet=0, $iCorr=0, $iStdErr=0;
+
+        public function __construct($aDataX,$aDataY) {
+                if( count($aDataX) !== count($aDataY) ) {
+                        JpGraph::Raise('LinearRegression: X and Y data array must be of equal length.');
+                }
+                $this->ix = $aDataX;
+                $this->iy = $aDataY;
+        }
+
+        public function Calc() {
+
+                $this->icalculated = true;
+
+                $n = count($this->ix);
+                $sx2 = 0 ;
+                $sy2 = 0 ;
+                $sxy = 0 ;
+                $sx = 0 ;
+                $sy = 0 ;
+
+                for( $i=0; $i < $n; ++$i ) {
+                        $sx2 += $this->ix[$i] * $this->ix[$i];
+                        $sy2 += $this->iy[$i] * $this->iy[$i];
+                        $sxy += $this->ix[$i] * $this->iy[$i];
+                        $sx += $this->ix[$i];
+                        $sy += $this->iy[$i];
+                }
+
+                if( $n*$sx2 - $sx*$sx > __LR_EPSILON ) {
+                        $this->ib = ($n*$sxy - $sx*$sy) / ( $n*$sx2 - $sx*$sx );
+                        $this->ia = ( $sy - $this->ib*$sx ) / $n;
+
+                        $sx = $this->ib * ( $sxy - $sx*$sy/$n );
+                        $sy2 = $sy2 - $sy*$sy/$n;
+                        $sy = $sy2 - $sx;
+
+                        $this->iDet = $sx / $sy2;
+                        $this->iCorr = sqrt($this->iDet);
+                        if( $n > 2 ) {
+                                $this->iStdErr = sqrt( $sy / ($n-2) );
+                        }
+                        else {
+                                $this->iStdErr = NAN ;
+                        }
+                }
+                else {
+                        $this->ib = 0;
+                        $this->ia = 0;
+                }
+
+        }
+
+        public function GetAB() {
+                if( $this->icalculated == false )
+                        $this->Calc();
+                return array($this->ia, $this->ib);
+        }
+
+        public function GetStat() {
+                if( $this->icalculated == false )
+                        $this->Calc();
+                return array($this->iStdErr, $this->iCorr, $this->iDet);
+        }
+
+        public function GetY($aMinX, $aMaxX, $aStep=1) {
+                if( $this->icalculated == false )
+                        $this->Calc();
+
+                $yy = array();
+                $i = 0;
+                for( $x=$aMinX; $x <= $aMaxX; $x += $aStep ) {
+                        $xx[$i  ] = $x;
+                        $yy[$i++] = $this->ia + $this->ib * $x;
+                }
+
+                return array($xx,$yy);
+        }
+
+}
+
+?>
diff --git a/web/classes/jpgraph/jpgraph_windrose.php b/web/classes/jpgraph/jpgraph_windrose.php
new file mode 100755
index 0000000000000000000000000000000000000000..8eef2cbe45306b3b8b0fcd9f81976458760c525c
--- /dev/null
+++ b/web/classes/jpgraph/jpgraph_windrose.php
@@ -0,0 +1,1566 @@
+<?php
+/*=======================================================================
+ // File:        JPGRAPH_WINDROSE.PHP
+ // Description: Windrose extension for JpGraph
+ // Created:     2003-09-17
+ // Ver:         $Id: jpgraph_windrose.php 1928 2010-01-11 19:56:51Z ljp $
+ //
+ // Copyright (c) Asial Corporation. All rights reserved.
+ //========================================================================
+ */
+
+require_once('jpgraph_glayout_vh.inc.php');
+
+//------------------------------------------------------------------------
+// Determine how many compass directions to show
+//------------------------------------------------------------------------
+define('WINDROSE_TYPE4',1);
+define('WINDROSE_TYPE8',2);
+define('WINDROSE_TYPE16',3);
+define('WINDROSE_TYPEFREE',4);
+
+//------------------------------------------------------------------------
+// How should the labels for the circular grids be aligned
+//------------------------------------------------------------------------
+define('LBLALIGN_CENTER',1);
+define('LBLALIGN_TOP',2);
+
+//------------------------------------------------------------------------
+// How should the labels around the plot be align
+//------------------------------------------------------------------------
+define('LBLPOSITION_CENTER',1);
+define('LBLPOSITION_EDGE',2);
+
+//------------------------------------------------------------------------
+// Interpretation of ordinal values in the data
+//------------------------------------------------------------------------
+define('KEYENCODING_CLOCKWISE',1);
+define('KEYENCODING_ANTICLOCKWISE',2);
+
+// Internal debug flag
+define('__DEBUG',false);
+
+
+//===================================================
+// CLASS WindrosePlotScale
+//===================================================
+class WindrosePlotScale {
+    private $iMax,$iDelta=5;
+    private $iNumCirc=3;
+    public $iMaxNum=0;
+    private $iLblFmt='%.0f%%';
+    public $iFontFamily=FF_VERDANA,$iFontStyle=FS_NORMAL,$iFontSize=10;
+    public $iZFontFamily=FF_ARIAL,$iZFontStyle=FS_NORMAL,$iZFontSize=10;
+    public $iFontColor='black',$iZFontColor='black';
+    private $iFontFrameColor=false, $iFontBkgColor=false;
+    private $iLblZeroTxt=null;
+    private $iLblAlign=LBLALIGN_CENTER;
+    public $iAngle='auto';
+    private $iManualScale = false;
+    private $iHideLabels = false;
+
+    function __construct($aData) {
+        $max=0;
+        $totlegsum = 0;
+        $maxnum=0;
+        $this->iZeroSum=0;
+        foreach( $aData as $idx => $legdata ) {
+            $legsum = array_sum($legdata);
+            $maxnum = max($maxnum,count($legdata)-1);
+            $max = max($legsum-$legdata[0],$max);
+            $totlegsum += $legsum;
+            $this->iZeroSum += $legdata[0] ;
+        }
+        if( round($totlegsum) > 100 ) {
+            JpGraphError::RaiseL(22001,$legsum);
+            //("Total percentage for all windrose legs in a windrose plot can not exceed  100% !\n(Current max is: ".$legsum.')');
+        }
+        $this->iMax = $max ;
+        $this->iMaxNum = $maxnum;
+        $this->iNumCirc = $this->GetNumCirc();
+        $this->iMaxVal = $this->iNumCirc * $this->iDelta ;
+    }
+
+    // Return number of grid circles
+    function GetNumCirc() {
+        // Never return less than 1 circles
+        $num = ceil($this->iMax / $this->iDelta);
+        return max(1,$num) ;
+    }
+
+    function SetMaxValue($aMax) {
+        $this->iMax = $aMax;
+        $this->iNumCirc = $this->GetNumCirc();
+        $this->iMaxVal = $this->iNumCirc * $this->iDelta ;
+    }
+
+    // Set step size for circular grid
+    function Set($aMax,$aDelta=null) {
+        if( $aDelta==null ) {
+            $this->SetMaxValue($aMax);
+            return;
+        }
+        $this->iDelta = $aDelta;
+        $this->iNumCirc = ceil($aMax/$aDelta); //$this->GetNumCirc();
+        $this->iMaxVal = $this->iNumCirc * $this->iDelta ;
+        $this->iMax=$aMax;
+        // Remember that user has specified interval so don't
+        // do autoscaling
+        $this->iManualScale = true;
+    }
+
+    function AutoScale($aRadius,$aMinDist=30) {
+
+        if( $this->iManualScale ) return;
+
+        // Make sure distance (in pixels) between two circles
+        // is never less than $aMinDist pixels
+        $tst = ceil($aRadius / $this->iNumCirc) ;
+
+        while( $tst <= $aMinDist && $this->iDelta < 100 ) {
+            $this->iDelta += 5;
+            $tst = ceil($aRadius / $this->GetNumCirc()) ;
+        }
+
+        if( $this->iDelta >= 100 ) {
+            JpGraphError::RaiseL(22002);//('Graph is too small to have a scale. Please make the graph larger.');
+        }
+
+        // If the distance is to large try with multiples of 2 instead
+        if( $tst > $aMinDist * 3 ) {
+            $this->iDelta = 2;
+            $tst = ceil($aRadius / $this->iNumCirc) ;
+
+            while( $tst <= $aMinDist && $this->iDelta < 100 ) {
+                $this->iDelta += 2;
+                $tst = ceil($aRadius / $this->GetNumCirc()) ;
+            }
+
+            if( $this->iDelta >= 100 ) {
+                JpGraphError::RaiseL(22002); //('Graph is too small to have a scale. Please make the graph larger.');
+            }
+        }
+
+        $this->iNumCirc = $this->GetNumCirc();
+        $this->iMaxVal = $this->iNumCirc * $this->iDelta ;
+    }
+
+    // Return max of all leg values
+    function GetMax() {
+        return $this->iMax;
+    }
+
+    function Hide($aFlg=true) {
+        $this->iHideLabels = $aFlg;
+    }
+
+    function SetAngle($aAngle) {
+        $this->iAngle = $aAngle ;
+    }
+
+    // Translate a Leg value to radius distance
+    function RelTranslate($aVal,$r,$ri) {
+        $tv = round($aVal/$this->iMaxVal*($r-$ri));
+        return $tv ;
+    }
+
+    function SetLabelAlign($aAlign) {
+        $this->iLblAlign = $aAlign ;
+    }
+
+    function SetLabelFormat($aFmt) {
+        $this->iLblFmt = $aFmt ;
+    }
+
+    function SetLabelFillColor($aBkgColor,$aBorderColor=false) {
+
+        $this->iFontBkgColor = $aBkgColor;
+        if( $aBorderColor === false ) {
+            $this->iFontFrameColor = $aBkgColor;
+        }
+        else {
+            $this->iFontFrameColor = $aBorderColor;
+        }
+    }
+
+    function SetFontColor($aColor) {
+        $this->iFontColor = $aColor ;
+        $this->iZFontColor = $aColor ;
+    }
+
+    function SetFont($aFontFamily,$aFontStyle=FS_NORMAL,$aFontSize=10) {
+        $this->iFontFamily = $aFontFamily ;
+        $this->iFontStyle = $aFontStyle ;
+        $this->iFontSize = $aFontSize ;
+        $this->SetZFont($aFontFamily,$aFontStyle,$aFontSize);
+    }
+
+    function SetZFont($aFontFamily,$aFontStyle=FS_NORMAL,$aFontSize=10) {
+        $this->iZFontFamily = $aFontFamily ;
+        $this->iZFontStyle = $aFontStyle ;
+        $this->iZFontSize = $aFontSize ;
+    }
+
+    function SetZeroLabel($aTxt) {
+        $this->iLblZeroTxt = $aTxt ;
+    }
+
+    function SetZFontColor($aColor) {
+        $this->iZFontColor = $aColor ;
+    }
+
+    function StrokeLabels($aImg,$xc,$yc,$ri,$rr) {
+
+        if( $this->iHideLabels ) return;
+
+        // Setup some convinient vairables
+        $a = $this->iAngle * M_PI/180.0;
+        $n = $this->iNumCirc;
+        $d = $this->iDelta;
+
+        // Setup the font and font color
+        $val = new Text();
+        $val->SetFont($this->iFontFamily,$this->iFontStyle,$this->iFontSize);
+        $val->SetColor($this->iFontColor);
+
+        if( $this->iFontBkgColor !== false ) {
+            $val->SetBox($this->iFontBkgColor,$this->iFontFrameColor);
+        }
+
+        // Position the labels relative to the radiant circles
+        if( $this->iLblAlign == LBLALIGN_TOP ) {
+            if( $a > 0 && $a <= M_PI/2 ) {
+                $val->SetAlign('left','bottom');
+            }
+            elseif( $a > M_PI/2 && $a <= M_PI ) {
+                $val->SetAlign('right','bottom');
+            }
+        }
+        elseif( $this->iLblAlign == LBLALIGN_CENTER ) {
+            $val->SetAlign('center','center');
+        }
+
+        // Stroke the labels close to each circle
+        $v = $d ;
+        $si = sin($a);
+        $co = cos($a);
+        for( $i=0; $i < $n; ++$i, $v += $d ) {
+            $r = $ri + ($i+1) * $rr;
+            $x = $xc + $co * $r;
+            $y = $yc - $si * $r;
+            $val->Set(sprintf($this->iLblFmt,$v));
+            $val->Stroke($aImg,$x,$y);
+        }
+
+        // Print the text in the zero circle
+        if( $this->iLblZeroTxt === null ) {
+            $this->iLblZeroTxt = sprintf($this->iLblFmt,$this->iZeroSum);
+        }
+        else {
+            $this->iLblZeroTxt = sprintf($this->iLblZeroTxt,$this->iZeroSum);
+        }
+
+        $val->Set($this->iLblZeroTxt);
+        $val->SetAlign('center','center');
+        $val->SetParagraphAlign('center');
+        $val->SetColor($this->iZFontColor);
+        $val->SetFont($this->iZFontFamily,$this->iZFontStyle,$this->iZFontSize);
+        $val->Stroke($aImg,$xc,$yc);
+    }
+}
+
+//===================================================
+// CLASS LegendStyle
+//===================================================
+class LegendStyle {
+    public $iLength = 40, $iMargin = 20 , $iBottomMargin=5;
+    public $iCircleWeight=2,  $iCircleRadius = 18, $iCircleColor='black';
+    public $iTxtFontFamily=FF_VERDANA,$iTxtFontStyle=FS_NORMAL,$iTxtFontSize=8;
+    public $iLblFontFamily=FF_VERDANA,$iLblFontStyle=FS_NORMAL,$iLblFontSize=8;
+    public $iCircleFontFamily=FF_VERDANA,$iCircleFontStyle=FS_NORMAL,$iCircleFontSize=8;
+    public $iLblFontColor='black',$iTxtFontColor='black',$iCircleFontColor='black';
+    public $iShow=true;
+    public $iFormatString='%.1f';
+    public $iTxtMargin=6, $iTxt='';
+    public $iZCircleTxt='Calm';
+
+    function SetFont($aFontFamily,$aFontStyle=FS_NORMAL,$aFontSize=10) {
+        $this->iLblFontFamily = $aFontFamily ;
+        $this->iLblFontStyle = $aFontStyle ;
+        $this->iLblFontSize = $aFontSize ;
+        $this->iTxtFontFamily = $aFontFamily ;
+        $this->iTxtFontStyle = $aFontStyle ;
+        $this->iTxtFontSize = $aFontSize ;
+        $this->iCircleFontFamily = $aFontFamily ;
+        $this->iCircleFontStyle = $aFontStyle ;
+        $this->iCircleFontSize = $aFontSize ;
+    }
+
+    function SetLFont($aFontFamily,$aFontStyle=FS_NORMAL,$aFontSize=10) {
+        $this->iLblFontFamily = $aFontFamily ;
+        $this->iLblFontStyle = $aFontStyle ;
+        $this->iLblFontSize = $aFontSize ;
+    }
+
+    function SetTFont($aFontFamily,$aFontStyle=FS_NORMAL,$aFontSize=10) {
+        $this->iTxtFontFamily = $aFontFamily ;
+        $this->iTxtFontStyle = $aFontStyle ;
+        $this->iTxtFontSize = $aFontSize ;
+    }
+
+    function SetCFont($aFontFamily,$aFontStyle=FS_NORMAL,$aFontSize=10) {
+        $this->iCircleFontFamily = $aFontFamily ;
+        $this->iCircleFontStyle = $aFontStyle ;
+        $this->iCircleFontSize = $aFontSize ;
+    }
+
+
+    function SetFontColor($aColor) {
+        $this->iTxtFontColor = $aColor ;
+        $this->iLblFontColor = $aColor ;
+        $this->iCircleFontColor = $aColor ;
+    }
+
+    function SetTFontColor($aColor) {
+        $this->iTxtFontColor = $aColor ;
+    }
+
+    function SetLFontColor($aColor) {
+        $this->iLblFontColor = $aColor ;
+    }
+
+    function SetCFontColor($aColor) {
+        $this->iCircleFontColor = $aColor ;
+    }
+
+    function SetCircleWeight($aWeight) {
+        $this->iCircleWeight = $aWeight;
+    }
+
+    function SetCircleRadius($aRadius) {
+        $this->iCircleRadius = $aRadius;
+    }
+
+    function SetCircleColor($aColor) {
+        $this->iCircleColor = $aColor ;
+    }
+
+    function SetCircleText($aTxt) {
+        $this->iZCircleTxt = $aTxt;
+    }
+
+    function SetMargin($aMarg,$aBottomMargin=5) {
+        $this->iMargin=$aMarg;
+        $this->iBottomMargin=$aBottomMargin;
+    }
+
+    function SetLength($aLength) {
+        $this->iLength = $aLength ;
+    }
+
+    function Show($aFlg=true) {
+        $this->iShow = $aFlg;
+    }
+
+    function Hide($aFlg=true) {
+        $this->iShow = ! $aFlg;
+    }
+
+    function SetFormat($aFmt) {
+        $this->iFormatString=$aFmt;
+    }
+
+    function SetText($aTxt) {
+        $this->iTxt = $aTxt ;
+    }
+
+}
+
+define('RANGE_OVERLAPPING',0);
+define('RANGE_DISCRETE',1);
+
+//===================================================
+// CLASS WindrosePlot
+//===================================================
+class WindrosePlot {
+    private $iAntiAlias=true;
+    private $iData=array();
+    public $iX=0.5,$iY=0.5;
+    public $iSize=0.55;
+    private $iGridColor1='gray',$iGridColor2='darkgreen';
+    private $iRadialColorArray=array();
+    private $iRadialWeightArray=array();
+    private $iRadialStyleArray=array();
+    private $iRanges = array(1,2,3,5,6,10,13.5,99.0);
+    private $iRangeStyle = RANGE_OVERLAPPING ;
+    public $iCenterSize=60;
+    private $iType = WINDROSE_TYPE16;
+    public $iFontFamily=FF_VERDANA,$iFontStyle=FS_NORMAL,$iFontSize=10;
+    public $iFontColor='darkgray';
+    private $iRadialGridStyle='longdashed';
+    private $iAllDirectionLabels =  array('E','ENE','NE','NNE','N','NNW','NW','WNW','W','WSW','SW','SSW','S','SSE','SE','ESE');
+    private $iStandardDirections = array();
+    private $iCircGridWeight=3, $iRadialGridWeight=1;
+    private $iLabelMargin=12;
+    private $iLegweights = array(2,4,6,8,10,12,14,16,18,20);
+    private $iLegColors = array('orange','black','blue','red','green','purple','navy','yellow','brown');
+    private $iLabelFormatString='', $iLabels=array();
+    private $iLabelPositioning = LBLPOSITION_EDGE;
+    private $iColor='white';
+    private $iShowBox=false, $iBoxColor='black',$iBoxWeight=1,$iBoxStyle='solid';
+    private $iOrdinalEncoding=KEYENCODING_ANTICLOCKWISE;
+    public $legend=null;
+
+    function __construct($aData) {
+        $this->iData = $aData;
+        $this->legend = new LegendStyle();
+
+        // Setup the scale
+        $this->scale = new WindrosePlotScale($this->iData);
+
+        // default label for free type i agle and a degree sign
+        $this->iLabelFormatString = '%.1f'.SymChar::Get('degree');
+
+        $delta = 2*M_PI/16;
+        for( $i=0, $a=0; $i < 16; ++$i, $a += $delta ) {
+            $this->iStandardDirections[$this->iAllDirectionLabels[$i]] = $a;
+        }
+    }
+
+    // Dummy method to make window plots have the same signature as the
+    // layout classes since windrose plots are "leaf" classes in the hierarchy
+    function LayoutSize() {
+        return 1;
+    }
+
+    function SetSize($aSize) {
+        $this->iSize = $aSize;
+    }
+
+    function SetDataKeyEncoding($aEncoding) {
+        $this->iOrdinalEncoding = $aEncoding;
+    }
+
+    function SetColor($aColor) {
+        $this->iColor = $aColor;
+    }
+
+    function SetRadialColors($aColors) {
+        $this->iRadialColorArray = $aColors;
+    }
+
+    function SetRadialWeights($aWeights) {
+        $this->iRadialWeightArray = $aWeights;
+    }
+
+    function SetRadialStyles($aStyles) {
+        $this->iRadialStyleArray = $aStyles;
+    }
+
+    function SetBox($aColor='black',$aWeight=1, $aStyle='solid', $aShow=true) {
+        $this->iShowBox = $aShow ;
+        $this->iBoxColor = $aColor ;
+        $this->iBoxWeight = $aWeight ;
+        $this->iBoxStyle = $aStyle;
+    }
+
+    function SetLabels($aLabels) {
+        $this->iLabels = $aLabels ;
+    }
+
+    function SetLabelMargin($aMarg) {
+        $this->iLabelMargin = $aMarg ;
+    }
+
+    function SetLabelFormat($aLblFormat) {
+        $this->iLabelFormatString = $aLblFormat ;
+    }
+
+    function SetCompassLabels($aLabels) {
+        if( count($aLabels) != 16 ) {
+            JpgraphError::RaiseL(22004); //('Label specification for windrose directions must have 16 values (one for each compass direction).');
+        }
+        $this->iAllDirectionLabels = $aLabels ;
+
+        $delta = 2*M_PI/16;
+        for( $i=0, $a=0; $i < 16; ++$i, $a += $delta ) {
+            $this->iStandardDirections[$this->iAllDirectionLabels[$i]] = $a;
+        }
+
+    }
+
+    function SetCenterSize($aSize) {
+        $this->iCenterSize = $aSize;
+    }
+    // Alias for SetCenterSize
+    function SetZCircleSize($aSize) {
+        $this->iCenterSize = $aSize;
+    }
+
+    function SetFont($aFFam,$aFStyle=FS_NORMAL,$aFSize=10) {
+        $this->iFontFamily = $aFFam ;
+        $this->iFontStyle = $aFStyle ;
+        $this->iFontSize = $aFSize ;
+    }
+
+    function SetFontColor($aColor) {
+        $this->iFontColor=$aColor;
+    }
+
+    function SetGridColor($aColor1,$aColor2) {
+        $this->iGridColor1 = $aColor1;
+        $this->iGridColor2 = $aColor2;
+    }
+
+    function SetGridWeight($aGrid1=1,$aGrid2=2) {
+        $this->iCircGridWeight = $aGrid1 ;
+        $this->iRadialGridWeight = $aGrid2 ;
+    }
+
+    function SetRadialGridStyle($aStyle) {
+        $aStyle = strtolower($aStyle);
+        if( !in_array($aStyle,array('solid','dotted','dashed','longdashed')) ) {
+            JpGraphError::RaiseL(22005); //("Line style for radial lines must be on of ('solid','dotted','dashed','longdashed') ");
+        }
+        $this->iRadialGridStyle=$aStyle;
+    }
+
+    function SetRanges($aRanges) {
+        $this->iRanges = $aRanges;
+    }
+
+    function SetRangeStyle($aStyle) {
+        $this->iRangeStyle = $aStyle;
+    }
+
+    function SetRangeColors($aLegColors) {
+        $this->iLegColors = $aLegColors;
+    }
+
+    function SetRangeWeights($aWeights) {
+        $n=count($aWeights);
+        for($i=0; $i< $n; ++$i ) {
+            $aWeights[$i] = floor($aWeights[$i]/2);
+        }
+        $this->iLegweights = $aWeights;
+
+    }
+
+    function SetType($aType) {
+        if( $aType < WINDROSE_TYPE4 || $aType > WINDROSE_TYPEFREE ) {
+            JpGraphError::RaiseL(22006); //('Illegal windrose type specified.');
+        }
+        $this->iType = $aType;
+    }
+
+    // Alias for SetPos()
+    function SetCenterPos($aX,$aY) {
+        $this->iX = $aX;
+        $this->iY = $aY;        
+    }
+    
+    function SetPos($aX,$aY) {
+        $this->iX = $aX;
+        $this->iY = $aY;
+    }
+
+    function SetAntiAlias($aFlag) {
+        $this->iAntiAlias = $aFlag ;
+        if( ! $aFlag )
+        $this->iCircGridWeight = 1;
+    }
+
+    function _ThickCircle($aImg,$aXC,$aYC,$aRad,$aWeight=2,$aColor) {
+
+        $aImg->SetColor($aColor);
+        $aRad *= 2 ;
+        $aImg->Ellipse($aXC,$aYC,$aRad,$aRad);
+        if( $aWeight > 1 ) {
+            $aImg->Ellipse($aXC,$aYC,$aRad+1,$aRad+1);
+            $aImg->Ellipse($aXC,$aYC,$aRad+2,$aRad+2);
+            if( $aWeight > 2 ) {
+                $aImg->Ellipse($aXC,$aYC,$aRad+3,$aRad+3);
+                $aImg->Ellipse($aXC,$aYC,$aRad+3,$aRad+4);
+                $aImg->Ellipse($aXC,$aYC,$aRad+4,$aRad+3);
+            }
+        }
+    }
+
+    function _StrokeWindLeg($aImg,$xc,$yc,$a,$ri,$r,$weight,$color) {
+
+        // If less than 1 px long then we assume this has been caused by rounding problems
+        // and should not be stroked
+        if( $r < 1 ) return;
+
+        $xt = $xc + cos($a)*$ri;
+        $yt = $yc - sin($a)*$ri;
+        $xxt = $xc + cos($a)*($ri+$r);
+        $yyt = $yc - sin($a)*($ri+$r);
+
+        $x1 = $xt - $weight*sin($a);
+        $y1 = $yt - $weight*cos($a);
+        $x2 = $xxt - $weight*sin($a);
+        $y2 = $yyt - $weight*cos($a);
+
+        $x3 = $xxt + $weight*sin($a);
+        $y3 = $yyt + $weight*cos($a);
+        $x4 = $xt + $weight*sin($a);
+        $y4 = $yt + $weight*cos($a);
+
+        $pts = array($x1,$y1,$x2,$y2,$x3,$y3,$x4,$y4);
+        $aImg->SetColor($color);
+        $aImg->FilledPolygon($pts);
+
+    }
+
+    function _StrokeLegend($aImg,$x,$y,$scaling=1,$aReturnWidth=false) {
+
+        if( ! $this->legend->iShow ) return 0;
+
+        $nlc = count($this->iLegColors);
+        $nlw = count($this->iLegweights);
+
+        // Setup font for ranges
+        $value = new Text();
+        $value->SetAlign('center','bottom');
+        $value->SetFont($this->legend->iLblFontFamily,
+        $this->legend->iLblFontStyle,
+        $this->legend->iLblFontSize*$scaling);
+        $value->SetColor($this->legend->iLblFontColor);
+
+        // Remember x-center
+        $xcenter = $x ;
+
+        // Construct format string
+        $fmt = $this->legend->iFormatString.'-'.$this->legend->iFormatString;
+
+        // Make sure that the length of each range is enough to cover the
+        // size of the labels
+        $tst = sprintf($fmt,$this->iRanges[0],$this->iRanges[1]);
+        $value->Set($tst);
+        $w = $value->GetWidth($aImg);
+        $l = round(max($this->legend->iLength * $scaling,$w*1.5));
+
+        $r = $this->legend->iCircleRadius * $scaling ;
+        $len = 2*$r + $this->scale->iMaxNum * $l;
+
+        // We are called just to find out the width
+        if( $aReturnWidth ) return $len;
+
+        $x -= round($len/2);
+        $x += $r;
+
+        // 4 pixels extra vertical margin since the circle sometimes is +/- 1 pixel of the
+        // theorethical radius due to imperfection in the GD library
+        //$y -= round(max($r,$scaling*$this->iLegweights[($this->scale->iMaxNum-1) % $nlw])+4*$scaling);
+        $y -= ($this->legend->iCircleRadius + 2)*$scaling+$this->legend->iBottomMargin*$scaling;
+
+        // Adjust for bottom text
+        if( $this->legend->iTxt != '' ) {
+            // Setup font for text
+            $value->Set($this->legend->iTxt);
+            $y -= /*$this->legend->iTxtMargin + */ $value->GetHeight($aImg);
+        }
+
+        // Stroke 0-circle
+        $this->_ThickCircle($aImg,$x,$y,$r,$this->legend->iCircleWeight,
+        $this->legend->iCircleColor);
+
+        // Remember the center of the circe
+        $xc=$x; $yc=$y;
+
+        $value->SetAlign('center','bottom');
+        $x += $r+1;
+
+        // Stroke all used ranges
+        $txty = $y -
+        round($this->iLegweights[($this->scale->iMaxNum-1)%$nlw]*$scaling) - 4*$scaling;
+        if( $this->scale->iMaxNum >= count($this->iRanges) ) {
+            JpGraphError::RaiseL(22007); //('To few values for the range legend.');
+        }
+        $i=0;$idx=0;
+        while( $i < $this->scale->iMaxNum ) {
+            $y1 = $y - round($this->iLegweights[$i % $nlw]*$scaling);
+            $y2 = $y + round($this->iLegweights[$i % $nlw]*$scaling);
+            $x2 = $x + $l ;
+            $aImg->SetColor($this->iLegColors[$i % $nlc]);
+            $aImg->FilledRectangle($x,$y1,$x2,$y2);
+            if( $this->iRangeStyle == RANGE_OVERLAPPING ) {
+                $lbl = sprintf($fmt,$this->iRanges[$idx],$this->iRanges[$idx+1]);
+            }
+            else {
+                $lbl = sprintf($fmt,$this->iRanges[$idx],$this->iRanges[$idx+1]);
+                ++$idx;
+            }
+            $value->Set($lbl);
+            $value->Stroke($aImg,$x+$l/2,$txty);
+            $x = $x2;
+            ++$i;++$idx;
+        }
+
+        // Setup circle font
+        $value->SetFont($this->legend->iCircleFontFamily,
+        $this->legend->iCircleFontStyle,
+        $this->legend->iCircleFontSize*$scaling);
+        $value->SetColor($this->legend->iCircleFontColor);
+
+        // Stroke 0-circle text
+        $value->Set($this->legend->iZCircleTxt);
+        $value->SetAlign('center','center');
+        $value->ParagraphAlign('center');
+        $value->Stroke($aImg,$xc,$yc);
+
+        // Setup circle font
+        $value->SetFont($this->legend->iTxtFontFamily,
+        $this->legend->iTxtFontStyle,
+        $this->legend->iTxtFontSize*$scaling);
+        $value->SetColor($this->legend->iTxtFontColor);
+
+        // Draw the text under the legend
+        $value->Set($this->legend->iTxt);
+        $value->SetAlign('center','top');
+        $value->SetParagraphAlign('center');
+        $value->Stroke($aImg,$xcenter,$y2+$this->legend->iTxtMargin*$scaling);
+    }
+
+    function SetAutoScaleAngle($aIsRegRose=true) {
+
+        // If the user already has manually set an angle don't
+        // trye to find a position
+        if( is_numeric($this->scale->iAngle) )
+            return;
+
+        if( $aIsRegRose ) {
+
+            // Create a complete data for all directions
+            // and translate string directions to ordinal values.
+            // This will much simplify the logic below
+            for( $i=0; $i < 16; ++$i ) {
+                $dtxt = $this->iAllDirectionLabels[$i];
+                if( !empty($this->iData[$dtxt]) ) {
+                    $data[$i] = $this->iData[$dtxt];
+                }
+                elseif( !empty($this->iData[strtolower($dtxt)]) ) {
+                    $data[$i] = $this->iData[strtolower($dtxt)];
+                }
+                elseif( !empty($this->iData[$i]) ) {
+                    $data[$i] = $this->iData[$i];
+                }
+                else {
+                    $data[$i] = array();
+                }
+            }
+
+            // Find the leg which has the lowest weighted sum of number of data around it
+            $c0 = array_sum($data[0]);
+            $c1 = array_sum($data[1]);
+            $found = 1;
+            $min = $c0+$c1*100; // Initialize to a high value
+            for( $i=1; $i < 15; ++$i ) {
+                $c2 = array_sum($data[$i+1]);
+
+                // Weight the leg we will use more to give preference
+                // to a short middle leg even if the 3 way sum is similair
+                $w = $c0 + 3*$c1 + $c2 ;
+                if( $w < $min ) {
+                    $min = $w;
+                    $found = $i;
+                }
+                $c0 = $c1;
+                $c1 = $c2;
+            }
+            $this->scale->iAngle = $found*22.5;
+        }
+        else {
+            $n = count($this->iData);
+            foreach( $this->iData as $dir => $leg ) {
+                if( !is_numeric($dir) ) {
+                    $pos = array_search(strtoupper($dir),$this->iAllDirectionLabels);
+                    if( $pos !== false ) {
+                        $dir = $pos*22.5;
+                    }
+                }
+                $data[round($dir)] = $leg;
+            }
+
+            // Get all the angles for the data and sort it
+            $keys = array_keys($data);
+            sort($keys, SORT_NUMERIC);
+
+            $n = count($data);
+            $found = false;
+            $max = 0 ;
+            for( $i=0; $i < 15; ++$i ) {
+                $try_a = round(22.5*$i);
+
+                if( $try_a > $keys[$n-1] ) break;
+
+                if( in_array($try_a,$keys) ) continue;
+
+                // Find the angle just lower than this
+                $j=0;
+                while( $j < $n && $keys[$j] <= $try_a ) ++$j;
+                if( $j == 0 ) {
+                    $kj = 0; $keys[$n-1];
+                    $d1 = 0; abs($kj-$try_a);
+                }
+                else {
+                    --$j;
+                    $kj = $keys[$j];
+                    $d1 = abs($kj-$try_a);
+                }
+
+                // Find the angle just larger than this
+                $l=$n-1;
+                while( $l >= 0 && $keys[$l] >= $try_a ) --$l;
+                if( $l == $n-1) {
+                    $kl = $keys[0];
+                    $d2 = abs($kl-$try_a);
+                }
+                else {
+                    ++$l;
+                    $kl = $keys[$l];
+                    $d2 = abs($kl-$try_a);
+                }
+
+                // Weight the distance so that legs with large spread
+                // gets a better weight
+                $w = $d1 + $d2;
+                if( $i == 0 ) {
+                    $w = round(1.4 * $w);
+                }
+                $diff = abs($d1 - $d2);
+                $w *= (360-$diff);
+                if( $w > $max ) {
+                    $found = $i;
+                    $max = $w;
+                }
+            }
+
+            $a = $found*22.5;
+
+            // Some heuristics to have some preferred positions
+            if( $keys[$n-1] < 25 ) $a = 45;
+            elseif( $keys[0] > 60 ) $a = 45;
+            elseif( $keys[0] > 25 && $keys[$n-1] < 340 ) $a = 0;
+            elseif( $keys[$n-1] < 75 ) $a = 90;
+            elseif( $keys[$n-1] < 120 ) $a = 135;
+            elseif( $keys[$n-1] < 160 ) $a = 180;
+
+            $this->scale->iAngle = $a ;
+        }
+    }
+
+    function NormAngle($a) {
+        while( $a > 360 ) {
+            $a -= 360;
+        }
+        return $a;
+    }
+
+    function SetLabelPosition($aPos) {
+        $this->iLabelPositioning  = $aPos ;
+    }
+
+    function _StrokeFreeRose($dblImg,$value,$scaling,$xc,$yc,$r,$ri) {
+
+        // Plot radial grid lines and remember the end position
+        // and the angle for later use when plotting the labels
+        if( $this->iType != WINDROSE_TYPEFREE ) {
+            JpGraphError::RaiseL(22008); //('Internal error: Trying to plot free Windrose even though type is not a free windorose');
+        }
+
+        // Check if we should auto-position the angle for the
+        // labels. Basically we try to find a firection with smallest
+        // (or none) data.
+        $this->SetAutoScaleAngle(false);
+
+        $nlc = count($this->iLegColors);
+        $nlw = count($this->iLegweights);
+
+        // Stroke grid lines for directions and remember the
+        // position for the labels
+        $txtpos=array();
+        $num = count($this->iData);
+
+        $keys = array_keys($this->iData);
+
+        foreach( $this->iData as $dir => $legdata ) {
+            if( in_array($dir,$this->iAllDirectionLabels,true) === true) {
+                $a = $this->iStandardDirections[strtoupper($dir)];
+                if( in_array($a*180/M_PI,$keys) ) {
+                    JpGraphError::RaiseL(22009,round($a*180/M_PI));
+                    //('You have specified the same direction twice, once with an angle and once with a compass direction ('.$a*180/M_PI.' degrees.)');
+                }
+            }
+            elseif( is_numeric($dir) ) {
+                $this->NormAngle($dir);
+
+                if( $this->iOrdinalEncoding == KEYENCODING_CLOCKWISE ) {
+                    $dir = 360-$dir;
+                }
+
+                $a = $dir * M_PI/180;
+            }
+            else {
+                JpGraphError::RaiseL(22010);//('Direction must either be a numeric value or one of the 16 compass directions');
+            }
+
+            $xxc = round($xc + cos($a)*$ri);
+            $yyc = round($yc - sin($a)*$ri);
+            $x = round($xc + cos($a)*$r);
+            $y = round($yc - sin($a)*$r);
+            if( empty($this->iRadialColorArray[$dir]) ) {
+                $dblImg->SetColor($this->iGridColor2);
+            }
+            else {
+                $dblImg->SetColor($this->iRadialColorArray[$dir]);
+            }
+            if( empty($this->iRadialWeightArray[$dir]) ) {
+                $dblImg->SetLineWeight($this->iRadialGridWeight);
+            }
+            else {
+                $dblImg->SetLineWeight($this->iRadialWeightArray[$dir]);
+            }
+            if( empty($this->iRadialStyleArray[$dir]) ) {
+                $dblImg->SetLineStyle($this->iRadialGridStyle);
+            }
+            else {
+                $dblImg->SetLineStyle($this->iRadialStyleArray[$dir]);
+            }
+            $dblImg->StyleLine($xxc,$yyc,$x,$y);
+            $txtpos[] = array($x,$y,$a);
+        }
+        $dblImg->SetLineWeight(1);
+
+        // Setup labels
+        $lr = $scaling * $this->iLabelMargin;
+
+        if( $this->iLabelPositioning == LBLPOSITION_EDGE ) {
+            $value->SetAlign('left','top');
+        }
+        else {
+            $value->SetAlign('center','center');
+            $value->SetMargin(0);
+        }
+
+        for($i=0; $i < $num; ++$i ) {
+
+            list($x,$y,$a) = $txtpos[$i];
+
+            // Determine the label
+
+            $da = $a*180/M_PI;
+            if( $this->iOrdinalEncoding == KEYENCODING_CLOCKWISE ) {
+                $da = 360 - $da;
+            }
+
+            //$da = 360-$da;
+            
+            if( !empty($this->iLabels[$keys[$i]]) ) {
+                $lbl = $this->iLabels[$keys[$i]];
+            }
+            else {
+                $lbl = sprintf($this->iLabelFormatString,$da);
+            }
+
+            if( $this->iLabelPositioning == LBLPOSITION_CENTER ) {
+                $dx = $dy = 0;
+            }
+            else {
+                // LBLPOSIITON_EDGE
+                if( $a>=7*M_PI/4 || $a <= M_PI/4 ) $dx=0;
+                if( $a>=M_PI/4 && $a <= 3*M_PI/4 ) $dx=($a-M_PI/4)*2/M_PI;
+                if( $a>=3*M_PI/4 && $a <= 5*M_PI/4 ) $dx=1;
+                if( $a>=5*M_PI/4 && $a <= 7*M_PI/4 ) $dx=(1-($a-M_PI*5/4)*2/M_PI);
+
+                if( $a>=7*M_PI/4 ) $dy=(($a-M_PI)-3*M_PI/4)*2/M_PI;
+                if( $a<=M_PI/4 ) $dy=(0.5+$a*2/M_PI);
+                if( $a>=M_PI/4 && $a <= 3*M_PI/4 ) $dy=1;
+                if( $a>=3*M_PI/4 && $a <= 5*M_PI/4 ) $dy=(1-($a-3*M_PI/4)*2/M_PI);
+                if( $a>=5*M_PI/4 && $a <= 7*M_PI/4 ) $dy=0;
+            }
+
+            $value->Set($lbl);
+            $th = $value->GetHeight($dblImg);
+            $tw = $value->GetWidth($dblImg);
+            $xt=round($lr*cos($a)+$x) - $dx*$tw;
+            $yt=round($y-$lr*sin($a)) - $dy*$th;
+
+            $value->Stroke($dblImg,$xt,$yt);
+        }
+
+        if( __DEBUG ) {
+            $dblImg->SetColor('red');
+            $dblImg->Circle($xc,$yc,$lr+$r);
+        }
+
+        // Stroke all the legs
+        reset($this->iData);
+        $i=0;
+        foreach($this->iData as $dir => $legdata) {
+            $legdata = array_slice($legdata,1);
+            $nn = count($legdata);
+
+            $a = $txtpos[$i][2];
+            $rri = $ri/$scaling;
+            for( $j=0; $j < $nn; ++$j ) {
+                // We want the non scaled original radius
+                $legr = $this->scale->RelTranslate($legdata[$j],$r/$scaling,$ri/$scaling) ;
+                $this->_StrokeWindLeg($dblImg, $xc, $yc, $a,
+                $rri *$scaling,
+                $legr *$scaling,
+                $this->iLegweights[$j % $nlw] * $scaling,
+                $this->iLegColors[$j % $nlc]);
+                $rri += $legr;
+            }
+            ++$i;
+        }
+    }
+
+    // Translate potential string specified compass labels to their
+    // corresponding index.
+    function FixupIndexes($aDataArray,$num) {
+        $ret = array();
+        $keys = array_keys($aDataArray);
+        foreach($aDataArray as $idx => $data) {
+            if( is_string($idx) ) {
+                $idx = strtoupper($idx);
+                $res = array_search($idx,$this->iAllDirectionLabels);
+                if( $res === false ) {
+                    JpGraphError::RaiseL(22011,$idx); //('Windrose index must be numeric or direction label. You have specified index='.$idx);
+                }
+                $idx = $res;
+                if( $idx % (16 / $num) !== 0 ) {
+                    JpGraphError::RaiseL(22012); //('Windrose radial axis specification contains a direction which is not enabled.');
+                }
+                $idx /= (16/$num) ;
+
+                if( in_array($idx,$keys,1) ) {
+                    JpgraphError::RaiseL(22013,$idx); //('You have specified the look&feel for the same compass direction twice, once with text and once with index (Index='.$idx.')');
+                }
+            }
+            if( $idx < 0 || $idx > 15 ) {
+                JpgraphError::RaiseL(22014); //('Index for copmass direction must be between 0 and 15.');
+            }
+            $ret[$idx] = $data;
+        }
+        return $ret;
+    }
+
+    function _StrokeRegularRose($dblImg,$value,$scaling,$xc,$yc,$r,$ri) {
+        // _StrokeRegularRose($dblImg,$xc,$yc,$r,$ri)
+        // Plot radial grid lines and remember the end position
+        // and the angle for later use when plotting the labels
+        switch( $this->iType ) {
+            case WINDROSE_TYPE4:
+                $num = 4; break;
+            case WINDROSE_TYPE8:
+                $num = 8; break;
+            case WINDROSE_TYPE16:
+                $num = 16; break;
+            default:
+                JpGraphError::RaiseL(22015);//('You have specified an undefined Windrose plot type.');
+        }
+
+        // Check if we should auto-position the angle for the
+        // labels. Basically we try to find a firection with smallest
+        // (or none) data.
+        $this->SetAutoScaleAngle(true);
+
+        $nlc = count($this->iLegColors);
+        $nlw = count($this->iLegweights);
+
+        $this->iRadialColorArray = $this->FixupIndexes($this->iRadialColorArray,$num);
+        $this->iRadialWeightArray = $this->FixupIndexes($this->iRadialWeightArray,$num);
+        $this->iRadialStyleArray = $this->FixupIndexes($this->iRadialStyleArray,$num);
+
+        $txtpos=array();
+        $a = 2*M_PI/$num;
+        $dblImg->SetColor($this->iGridColor2);
+        $dblImg->SetLineStyle($this->iRadialGridStyle);
+        $dblImg->SetLineWeight($this->iRadialGridWeight);
+
+        // Translate any name specified directions to the index
+        // so we can easily use it in the loop below
+        for($i=0; $i < $num; ++$i ) {
+            $xxc = round($xc + cos($a*$i)*$ri);
+            $yyc = round($yc - sin($a*$i)*$ri);
+            $x = round($xc + cos($a*$i)*$r);
+            $y = round($yc - sin($a*$i)*$r);
+            if( empty($this->iRadialColorArray[$i]) ) {
+                $dblImg->SetColor($this->iGridColor2);
+            }
+            else {
+                $dblImg->SetColor($this->iRadialColorArray[$i]);
+            }
+            if( empty($this->iRadialWeightArray[$i]) ) {
+                $dblImg->SetLineWeight($this->iRadialGridWeight);
+            }
+            else {
+                $dblImg->SetLineWeight($this->iRadialWeightArray[$i]);
+            }
+            if( empty($this->iRadialStyleArray[$i]) ) {
+                $dblImg->SetLineStyle($this->iRadialGridStyle);
+            }
+            else {
+                $dblImg->SetLineStyle($this->iRadialStyleArray[$i]);
+            }
+
+            $dblImg->StyleLine($xxc,$yyc,$x,$y);
+            $txtpos[] = array($x,$y,$a*$i);
+        }
+        $dblImg->SetLineWeight(1);
+
+        $lr = $scaling * $this->iLabelMargin;
+        if( $this->iLabelPositioning == LBLPOSITION_CENTER ) {
+            $value->SetAlign('center','center');
+        }
+        else {
+            $value->SetAlign('left','top');
+            $value->SetMargin(0);
+            $lr /= 2 ;
+        }
+
+        for($i=0; $i < $num; ++$i ) {
+            list($x,$y,$a) = $txtpos[$i];
+
+            // Set the position of the label
+            if( $this->iLabelPositioning == LBLPOSITION_CENTER ) {
+                $dx = $dy = 0;
+            }
+            else {
+                // LBLPOSIITON_EDGE
+                if( $a>=7*M_PI/4 || $a <= M_PI/4 ) $dx=0;
+                if( $a>=M_PI/4 && $a <= 3*M_PI/4 ) $dx=($a-M_PI/4)*2/M_PI;
+                if( $a>=3*M_PI/4 && $a <= 5*M_PI/4 ) $dx=1;
+                if( $a>=5*M_PI/4 && $a <= 7*M_PI/4 ) $dx=(1-($a-M_PI*5/4)*2/M_PI);
+
+                if( $a>=7*M_PI/4 ) $dy=(($a-M_PI)-3*M_PI/4)*2/M_PI;
+                if( $a<=M_PI/4 ) $dy=(0.5+$a*2/M_PI);
+                if( $a>=M_PI/4 && $a <= 3*M_PI/4 ) $dy=1;
+                if( $a>=3*M_PI/4 && $a <= 5*M_PI/4 ) $dy=(1-($a-3*M_PI/4)*2/M_PI);
+                if( $a>=5*M_PI/4 && $a <= 7*M_PI/4 ) $dy=0;
+            }
+
+            $value->Set($this->iAllDirectionLabels[$i*(16/$num)]);
+            $th = $value->GetHeight($dblImg);
+            $tw = $value->GetWidth($dblImg);
+            $xt=round($lr*cos($a)+$x) - $dx*$tw;
+            $yt=round($y-$lr*sin($a)) - $dy*$th;
+
+            $value->Stroke($dblImg,$xt,$yt);
+        }
+
+        if( __DEBUG ) {
+            $dblImg->SetColor("red");
+            $dblImg->Circle($xc,$yc,$lr+$r);
+        }
+
+        // Stroke all the legs
+        reset($this->iData);
+        $keys = array_keys($this->iData);
+        foreach($this->iData as $idx => $legdata) {
+            $legdata = array_slice($legdata,1);
+            $nn = count($legdata);
+            if( is_string($idx) ) {
+                $idx = strtoupper($idx);
+                $idx = array_search($idx,$this->iAllDirectionLabels);
+                if( $idx === false ) {
+                    JpGraphError::RaiseL(22016);//('Windrose leg index must be numeric or direction label.');
+                }
+                if( $idx % (16 / $num) !== 0 ) {
+                    JpGraphError::RaiseL(22017);//('Windrose data contains a direction which is not enabled. Please adjust what labels are displayed.');
+                }
+                $idx /= (16/$num) ;
+
+                if( in_array($idx,$keys,1) ) {
+                    JpgraphError::RaiseL(22018,$idx);//('You have specified data for the same compass direction twice, once with text and once with index (Index='.$idx.')');
+
+                }
+            }
+            if( $idx < 0 || $idx > 15 ) {
+                JpgraphError::RaiseL(22019);//('Index for direction must be between 0 and 15. You can\'t specify angles for a Regular Windplot, only index and compass directions.');
+            }
+            $a = $idx * (360 / $num) ;
+            $a *= M_PI/180.0;
+            $rri = $ri/$scaling;
+            for( $j=0; $j < $nn; ++$j ) {
+                // We want the non scaled original radius
+                $legr = $this->scale->RelTranslate($legdata[$j], $r/$scaling,$ri/$scaling) ;
+                $this->_StrokeWindLeg($dblImg, $xc, $yc, $a,
+                $rri *$scaling,
+                $legr *$scaling,
+                $this->iLegweights[$j % $nlw] * $scaling,
+                $this->iLegColors[$j % $nlc]);
+                $rri += $legr;
+            }
+        }
+    }
+
+
+    function getWidth($aImg) {
+
+        $scaling = 1;//$this->iAntiAlias ? 2 : 1 ;
+       	if( $this->iSize > 0 && $this->iSize < 1 ) {
+			$this->iSize *= min($aImg->width,$aImg->height);
+       	}
+
+
+        $value = new Text();
+        $value->SetFont($this->iFontFamily,$this->iFontStyle,$this->iFontSize*$scaling);
+        $value->SetColor($this->iFontColor);
+        // Setup extra size around the graph needed so that the labels
+        // doesn't get cut. For this we need to find the largest label.
+        // The code below gives a possible a little to large margin. The
+        // really, really proper way would be to account for what angle
+        // the label are at
+        $n = count($this->iLabels);
+        if( $n > 0 ) {
+            $maxh=0;$maxw=0;
+            foreach($this->iLabels as $key => $lbl) {
+                $value->Set($lbl);
+                $maxw = max($maxw,$value->GetWidth($aImg));
+            }
+        }
+        else {
+            $value->Set('888.888'); // Dummy value to get width/height
+            $maxw = $value->GetWidth($aImg);
+        }
+        // Add an extra margin of 50% the font size
+        $maxw += round($this->iFontSize*$scaling * 0.4) ;
+
+        $valxmarg = 1.5*$maxw+2*$this->iLabelMargin*$scaling;
+        $w = round($this->iSize*$scaling + $valxmarg);
+
+        // Make sure that the width of the legend fits
+        $legendwidth = $this->_StrokeLegend($aImg,0,0,$scaling,true)+10*$scaling;
+        $w = max($w,$legendwidth);
+
+        return $w;
+    }
+
+    function getHeight($aImg) {
+
+        $scaling = 1;//$this->iAntiAlias ? 2 : 1 ;
+       	if( $this->iSize > 0 && $this->iSize < 1 ) {
+			$this->iSize *= min($aImg->width,$aImg->height);
+       	}
+
+        $value = new Text();
+        $value->SetFont($this->iFontFamily,$this->iFontStyle,$this->iFontSize*$scaling);
+        $value->SetColor($this->iFontColor);
+        // Setup extra size around the graph needed so that the labels
+        // doesn't get cut. For this we need to find the largest label.
+        // The code below gives a possible a little to large margin. The
+        // really, really proper way would be to account for what angle
+        // the label are at
+        $n = count($this->iLabels);
+        if( $n > 0 ) {
+            $maxh=0;$maxw=0;
+            foreach($this->iLabels as $key => $lbl) {
+                $value->Set($lbl);
+                $maxh = max($maxh,$value->GetHeight($aImg));
+            }
+        }
+        else {
+            $value->Set('180.8'); // Dummy value to get width/height
+            $maxh = $value->GetHeight($aImg);
+        }
+        // Add an extra margin of 50% the font size
+        //$maxh += round($this->iFontSize*$scaling * 0.5) ;
+        $valymarg = 2*$maxh+2*$this->iLabelMargin*$scaling;
+
+        $legendheight = round($this->legend->iShow ? 1 : 0);
+        $legendheight *= max($this->legend->iCircleRadius*2,$this->legend->iTxtFontSize*2)+
+        				 $this->legend->iMargin + $this->legend->iBottomMargin + 2;
+        $legendheight *= $scaling;
+        $h = round($this->iSize*$scaling + $valymarg) + $legendheight ;
+
+        return $h;
+    }
+
+    function Stroke($aGraph) {
+
+		$aImg = $aGraph->img;
+
+		if( $this->iX > 0 && $this->iX < 1 ) {
+			$this->iX = round( $aImg->width * $this->iX ) ;
+		}
+
+       	if( $this->iY > 0 && $this->iY < 1 ) {
+       		$this->iY = round( $aImg->height * $this->iY ) ;
+       	}
+
+       	if( $this->iSize > 0 && $this->iSize < 1 ) {
+			$this->iSize *= min($aImg->width,$aImg->height);
+       	}
+
+       	if( $this->iCenterSize > 0 && $this->iCenterSize < 1 ) {
+			$this->iCenterSize *= $this->iSize;
+       	}
+
+        $this->scale->AutoScale(($this->iSize - $this->iCenterSize)/2, round(2.5*$this->scale->iFontSize));
+
+        $scaling = $this->iAntiAlias ? 2 : 1 ;
+
+        $value = new Text();
+        $value->SetFont($this->iFontFamily,$this->iFontStyle,$this->iFontSize*$scaling);
+        $value->SetColor($this->iFontColor);
+
+        $legendheight = round($this->legend->iShow ? 1 : 0);
+        $legendheight *= max($this->legend->iCircleRadius*2,$this->legend->iTxtFontSize*2)+
+        $this->legend->iMargin + $this->legend->iBottomMargin + 2;
+        $legendheight *= $scaling;
+
+        $w = $scaling*$this->getWidth($aImg);
+        $h = $scaling*$this->getHeight($aImg);
+
+        // Copy back the double buffered image to the proper canvas
+        $ww = $w / $scaling ;
+        $hh = $h / $scaling ;
+
+        // Create the double buffer
+        if( $this->iAntiAlias ) {
+            $dblImg = new RotImage($w,$h);
+            // Set the background color
+            $dblImg->SetColor($this->iColor);
+            $dblImg->FilledRectangle(0,0,$w,$h);
+        }
+        else {
+            $dblImg = $aImg ;
+            // Make sure the ix and it coordinates correpond to the new top left center
+            $dblImg->SetTranslation($this->iX-$w/2, $this->iY-$h/2);
+        }
+
+        if( __DEBUG ) {
+            $dblImg->SetColor('red');
+            $dblImg->Rectangle(0,0,$w-1,$h-1);
+        }
+
+        $dblImg->SetColor('black');
+
+        if( $this->iShowBox ) {
+            $dblImg->SetColor($this->iBoxColor);
+            $old = $dblImg->SetLineWeight($this->iBoxWeight);
+            $dblImg->SetLineStyle($this->iBoxStyle);
+            $dblImg->Rectangle(0,0,$w-1,$h-1);
+            $dblImg->SetLineWeight($old);
+        }
+
+        $xc = round($w/2);
+        $yc = round(($h-$legendheight)/2);
+
+        if( __DEBUG ) {
+            $dblImg->SetColor('red');
+            $old = $dblImg->SetLineWeight(2);
+            $dblImg->Line($xc-5,$yc-5,$xc+5,$yc+5);
+			$dblImg->Line($xc+5,$yc-5,$xc-5,$yc+5);
+			$dblImg->SetLineWeight($old);
+        }
+
+        $this->iSize *= $scaling;
+
+        // Inner circle size
+        $ri = $this->iCenterSize/2 ;
+
+        // Full circle radius
+        $r = round( $this->iSize/2 );
+
+        // Get number of grid circles
+        $n = $this->scale->GetNumCirc();
+
+        // Plot circle grids
+        $ri *= $scaling ;
+        $rr = round(($r-$ri)/$n);
+        for( $i = 1; $i <= $n; ++$i ) {
+            $this->_ThickCircle($dblImg,$xc,$yc,$rr*$i+$ri,
+            $this->iCircGridWeight,$this->iGridColor1);
+        }
+
+        $num = 0 ;
+
+        if( $this->iType == WINDROSE_TYPEFREE ) {
+            $this->_StrokeFreeRose($dblImg,$value,$scaling,$xc,$yc,$r,$ri);
+        }
+        else {
+            // Check if we need to re-code the interpretation of the ordinal
+            // number in the data. Internally ordinal value 0 is East and then
+            // counted anti-clockwise. The user might choose an encoding
+            // that have 0 being the first axis to the right of the "N" axis and then
+            // counted clock-wise
+            if( $this->iOrdinalEncoding == KEYENCODING_CLOCKWISE ) {
+                if( $this->iType == WINDROSE_TYPE16 ) {
+                    $const1 = 19; $const2 = 16;
+                }
+                elseif( $this->iType == WINDROSE_TYPE8 ) {
+                    $const1 = 9; $const2 = 8;
+                }
+                else {
+                    $const1 = 4; $const2 = 4;
+                }
+                $tmp = array();
+                $n=count($this->iData);
+                foreach( $this->iData as $key => $val ) {
+                    if( is_numeric($key) ) {
+                        $key = ($const1 - $key) % $const2 ;
+                    }
+                    $tmp[$key] = $val;
+                }
+                $this->iData = $tmp;
+            }
+            $this->_StrokeRegularRose($dblImg,$value,$scaling,$xc,$yc,$r,$ri);
+        }
+
+        // Stroke the labels
+        $this->scale->iFontSize *= $scaling;
+        $this->scale->iZFontSize *= $scaling;
+        $this->scale->StrokeLabels($dblImg,$xc,$yc,$ri,$rr);
+
+        // Stroke the inner circle again since the legs
+        // might have written over it
+        $this->_ThickCircle($dblImg,$xc,$yc,$ri,$this->iCircGridWeight,$this->iGridColor1);
+
+        if( $ww > $aImg->width ) {
+            JpgraphError::RaiseL(22020);
+            //('Windrose plot is too large to fit the specified Graph size. Please use WindrosePlot::SetSize() to make the plot smaller or increase the size of the Graph in the initial WindroseGraph() call.');
+        }
+
+        $x = $xc;
+        $y = $h;
+        $this->_StrokeLegend($dblImg,$x,$y,$scaling);
+
+        if( $this->iAntiAlias ) {
+            $aImg->Copy($dblImg->img, $this->iX-$ww/2, $this->iY-$hh/2, 0, 0, $ww,$hh, $w,$h);
+        }
+
+        // We need to restore the translation matrix
+        $aImg->SetTranslation(0,0);
+
+    }
+
+}
+
+//============================================================
+// CLASS WindroseGraph
+//============================================================
+class WindroseGraph extends Graph {
+    private $posx, $posy;
+    public $plots=array();
+
+    function __construct($width=300,$height=200,$cachedName="",$timeout=0,$inline=1) {
+        parent::__construct($width,$height,$cachedName,$timeout,$inline);
+        $this->posx=$width/2;
+        $this->posy=$height/2;
+        $this->SetColor('white');
+        $this->title->SetFont(FF_VERDANA,FS_NORMAL,12);
+        $this->title->SetMargin(8);
+        $this->subtitle->SetFont(FF_VERDANA,FS_NORMAL,10);
+        $this->subtitle->SetMargin(0);
+        $this->subsubtitle->SetFont(FF_VERDANA,FS_NORMAL,8);
+        $this->subsubtitle->SetMargin(0);
+    }
+
+    function StrokeTexts() {
+        if( $this->texts != null ) {
+            $n = count($this->texts);
+            for($i=0; $i < $n; ++$i ) {
+                $this->texts[$i]->Stroke($this->img);
+            }
+        }
+    }
+
+    function StrokeIcons() {
+        if( $this->iIcons != null ) {
+            $n = count($this->iIcons);
+            for( $i=0; $i < $n; ++$i ) {
+                // Since Windrose graphs doesn't have any linear scale the position of
+                // each icon has to be given as absolute coordinates
+                $this->iIcons[$i]->_Stroke($this->img);
+            }
+        }
+    }
+
+    //---------------
+    // PUBLIC METHODS
+    function Add($aObj) {
+        if( is_array($aObj) && count($aObj) > 0 ) {
+            $cl = $aObj[0];
+        }
+        else {
+            $cl = $aObj;
+        }
+        if( $cl instanceof Text ) {
+            $this->AddText($aObj);
+        }
+        elseif( $cl instanceof IconPlot ) {
+            $this->AddIcon($aObj);
+        }
+        elseif( ($cl instanceof WindrosePlot) || ($cl instanceof LayoutRect) || ($cl instanceof LayoutHor)) {
+            $this->plots[] = $aObj;
+        }
+        else {
+            JpgraphError::RaiseL(22021);
+        }
+    }
+
+    function AddText($aTxt,$aToY2=false) {
+        parent::AddText($aTxt);
+    }
+
+    function SetColor($c) {
+        $this->SetMarginColor($c);
+    }
+
+    // Method description
+    function Stroke($aStrokeFileName="") {
+
+        // If the filename is the predefined value = '_csim_special_'
+        // we assume that the call to stroke only needs to do enough
+        // to correctly generate the CSIM maps.
+        // We use this variable to skip things we don't strictly need
+        // to do to generate the image map to improve performance
+        // as best we can. Therefore you will see a lot of tests !$_csim in the
+        // code below.
+        $_csim = ($aStrokeFileName===_CSIM_SPECIALFILE);
+
+        // We need to know if we have stroked the plot in the
+        // GetCSIMareas. Otherwise the CSIM hasn't been generated
+        // and in the case of GetCSIM called before stroke to generate
+        // CSIM without storing an image to disk GetCSIM must call Stroke.
+        $this->iHasStroked = true;
+
+        if( $this->background_image != "" || $this->background_cflag != "" ) {
+            $this->StrokeFrameBackground();
+        }
+        else {
+            $this->StrokeFrame();
+        }
+
+        // n holds number of plots
+        $n = count($this->plots);
+        for($i=0; $i < $n ; ++$i) {
+     		$this->plots[$i]->Stroke($this);
+        }
+
+        $this->footer->Stroke($this->img);
+        $this->StrokeIcons();
+        $this->StrokeTexts();
+        $this->StrokeTitles();
+
+        // If the filename is given as the special "__handle"
+        // then the image handler is returned and the image is NOT
+        // streamed back
+        if( $aStrokeFileName == _IMG_HANDLER ) {
+            return $this->img->img;
+        }
+        else {
+            // Finally stream the generated picture
+            $this->cache->PutAndStream($this->img,$this->cache_name,$this->inline,
+            $aStrokeFileName);
+        }
+    }
+
+} // Class
+
+?>
diff --git a/web/classes/jpgraph/lang/de.inc.php b/web/classes/jpgraph/lang/de.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..37ba264f4a42e6f231657fc22a1741b40cdb2960
--- /dev/null
+++ b/web/classes/jpgraph/lang/de.inc.php
@@ -0,0 +1,552 @@
+<?php
+/*=======================================================================
+// File:        DE.INC.PHP
+// Description: German language file for error messages
+// Created:     2006-03-06
+// Author:      Timo Leopold (timo@leopold-hh.de)
+//              Johan Persson (ljp@localhost.nil)
+// Ver:         $Id: de.inc.php 1886 2009-10-01 23:30:16Z ljp $
+//
+// Copyright (c)
+//========================================================================
+*/
+
+// Notiz: Das Format fuer jede Fehlermeldung ist array(<Fehlermeldung>,<Anzahl der Argumente>)
+$_jpg_messages = array(
+
+/*
+** Headers wurden bereits gesendet - Fehler. Dies wird als HTML formatiert, weil es direkt als text zurueckgesendet wird
+*/
+10  => array('<table border="1"><tr><td style="color:darkred;font-size:1.2em;"><b>JpGraph Fehler:</b>
+HTTP header wurden bereits gesendet.<br>Fehler in der Datei <b>%s</b> in der Zeile <b>%d</b>.</td></tr><tr><td><b>Erklärung:</b><br>HTTP header wurden bereits zum Browser gesendet, wobei die Daten als Text gekennzeichnet wurden, bevor die Bibliothek die Chance hatte, seinen Bild-HTTP-Header zum Browser zu schicken. Dies verhindert, dass die Bibliothek Bilddaten zum Browser schicken kann (weil sie vom Browser als Text interpretiert würden und daher nur Mist dargestellt würde).<p>Wahrscheinlich steht Text im Skript bevor <i>Graph::Stroke()</i> aufgerufen wird. Wenn dieser Text zum Browser gesendet wird, nimmt dieser an, dass die gesamten Daten aus Text bestehen. Such nach irgendwelchem Text, auch nach Leerzeichen und Zeilenumbrüchen, die eventuell bereits zum Browser gesendet wurden. <p>Zum Beispiel ist ein oft auftretender Fehler, eine Leerzeile am Anfang der Datei oder vor <i>Graph::Stroke()</i> zu lassen."<b>&lt;?php</b>".</td></tr></table>',2),
+
+/*
+** Setup Fehler
+*/
+11 => array('Es wurde kein Pfad für CACHE_DIR angegeben. Bitte gib einen Pfad CACHE_DIR in der Datei jpg-config.inc an.',0),
+12 => array('Es wurde kein Pfad für TTF_DIR angegeben und der Pfad kann nicht automatisch ermittelt werden. Bitte gib den Pfad in der Datei jpg-config.inc an.',0),
+13 => array('The installed PHP version (%s) is not compatible with this release of the library. The library requires at least PHP version %s',2),
+
+/*
+**  jpgraph_bar
+*/
+
+2001 => array('Die Anzahl der Farben ist nicht gleich der Anzahl der Vorlagen in BarPlot::SetPattern().',0),
+2002 => array('Unbekannte Vorlage im Aufruf von BarPlot::SetPattern().',0),
+2003 => array('Anzahl der X- und Y-Koordinaten sind nicht identisch. Anzahl der X-Koordinaten: %d; Anzahl der Y-Koordinaten: %d.',2),
+2004 => array('Alle Werte für ein Balkendiagramm (barplot) müssen numerisch sein. Du hast den Wert nr [%d] == %s angegeben.',2),
+2005 => array('Du hast einen leeren Vektor für die Schattierungsfarben im Balkendiagramm (barplot) angegeben.',0),
+2006 => array('Unbekannte Position für die Werte der Balken: %s.',1),
+2007 => array('Kann GroupBarPlot nicht aus einem leeren Vektor erzeugen.',0),
+2008 => array('GroupBarPlot Element nbr %d wurde nicht definiert oder ist leer.',0),
+2009 => array('Eins der Objekte, das an GroupBar weitergegeben wurde ist kein Balkendiagramm (BarPlot). Versichere Dich, dass Du den GroupBarPlot aus einem Vektor von Balkendiagrammen (barplot) oder AccBarPlot-Objekten erzeugst. (Class = %s)',1),
+2010 => array('Kann AccBarPlot nicht aus einem leeren Vektor erzeugen.',0),
+2011 => array('AccBarPlot-Element nbr %d wurde nicht definiert oder ist leer.',1),
+2012 => array('Eins der Objekte, das an AccBar weitergegeben wurde ist kein Balkendiagramm (barplot). Versichere Dich, dass Du den AccBar-Plot aus einem Vektor von Balkendiagrammen (barplot) erzeugst. (Class=%s)',1),
+2013 => array('Du hast einen leeren Vektor für die Schattierungsfarben im Balkendiagramm (barplot) angegeben.',0),
+2014 => array('Die Anzahl der Datenpunkte jeder Datenreihe in AccBarPlot muss gleich sein.',0),
+2015 => array('Individual bar plots in an AccBarPlot or GroupBarPlot can not have specified X-coordinates',0),
+
+
+/*
+**  jpgraph_date
+*/
+
+3001 => array('Es ist nur möglich, entweder SetDateAlign() oder SetTimeAlign() zu benutzen, nicht beides!',0),
+
+/*
+**  jpgraph_error
+*/
+
+4002 => array('Fehler bei den Eingabedaten von LineErrorPlot. Die Anzahl der Datenpunkte mus ein Mehrfaches von drei sein!',0),
+
+/*
+**  jpgraph_flags
+*/
+
+5001 => array('Unbekannte Flaggen-Größe (%d).',1),
+5002 => array('Der Flaggen-Index %s existiert nicht.',1),
+5003 => array('Es wurde eine ungültige Ordnungszahl (%d) für den Flaggen-Index angegeben.',1),
+5004 => array('Der Landesname %s hat kein korrespondierendes Flaggenbild. Die Flagge mag existieren, abr eventuell unter einem anderen Namen, z.B. versuche "united states" statt "usa".',1),
+
+
+/*
+**  jpgraph_gantt
+*/
+
+6001 => array('Interner Fehler. Die Höhe für ActivityTitles ist < 0.',0),
+6002 => array('Es dürfen keine negativen Werte für die Gantt-Diagramm-Dimensionen angegeben werden. Verwende 0, wenn die Dimensionen automatisch ermittelt werden sollen.',0),
+6003 => array('Ungültiges Format für den Bedingungs-Parameter bei Index=%d in CreateSimple(). Der Parameter muss bei index 0 starten und Vektoren in der Form (Row,Constrain-To,Constrain-Type) enthalten.',1),
+6004 => array('Ungültiges Format für den Fortschritts-Parameter bei Index=%d in CreateSimple(). Der Parameter muss bei Index 0 starten und Vektoren in der Form (Row,Progress) enthalten.',1),
+6005 => array('SetScale() ist nicht sinnvoll bei Gantt-Diagrammen.',0),
+6006 => array('Das Gantt-Diagramm kann nicht automatisch skaliert werden. Es existieren keine Aktivitäten mit Termin. [GetBarMinMax() start >= n]',0),
+6007 => array('Plausibiltätsprüfung für die automatische Gantt-Diagramm-Größe schlug fehl. Entweder die Breite (=%d) oder die Höhe (=%d) ist größer als MAX_GANTTIMG_SIZE. Dies kann möglicherweise durch einen falschen Wert bei einer Aktivität hervorgerufen worden sein.',2),
+6008 => array('Du hast eine Bedingung angegeben von Reihe=%d bis Reihe=%d, die keine Aktivität hat.',2),
+6009 => array('Unbekannter Bedingungstyp von Reihe=%d bis Reihe=%d',2),
+6010 => array('Ungültiger Icon-Index für das eingebaute Gantt-Icon [%d]',1),
+6011 => array('Argument für IconImage muss entweder ein String oder ein Integer sein.',0),
+6012 => array('Unbekannter Typ bei der Gantt-Objekt-Title-Definition.',0),
+6015 => array('Ungültige vertikale Position %d',1),
+6016 => array('Der eingegebene Datums-String (%s) für eine Gantt-Aktivität kann nicht interpretiert werden. Versichere Dich, dass es ein gültiger Datumsstring ist, z.B. 2005-04-23 13:30',1),
+6017 => array('Unbekannter Datumstyp in GanttScale (%s).',1),
+6018 => array('Intervall für Minuten muss ein gerader Teiler einer Stunde sein, z.B. 1,5,10,12,15,20,30, etc. Du hast ein Intervall von %d Minuten angegeben.',1),
+6019 => array('Die vorhandene Breite (%d) für die Minuten ist zu klein, um angezeigt zu werden. Bitte benutze die automatische Größenermittlung oder vergrößere die Breite des Diagramms.',1),
+6020 => array('Das Intervall für die Stunden muss ein gerader Teiler eines Tages sein, z.B. 0:30, 1:00, 1:30, 4:00, etc. Du hast ein Intervall von %d eingegeben.',1),
+6021 => array('Unbekanntes Format für die Woche.',0),
+6022 => array('Die Gantt-Skala wurde nicht eingegeben.',0),
+6023 => array('Wenn Du sowohl Stunden als auch Minuten anzeigen lassen willst, muss das Stunden-Interval gleich 1 sein (anderenfalls ist es nicht sinnvoll, Minuten anzeigen zu lassen).',0),
+6024 => array('Das CSIM-Ziel muss als String angegeben werden. Der Start des Ziels ist: %d',1),
+6025 => array('Der CSIM-Alt-Text muss als String angegeben werden. Der Beginn des Alt-Textes ist: %d',1),
+6027 => array('Der Fortschrittswert muss im Bereich [0, 1] liegen.',0),
+6028 => array('Die eingegebene Höhe (%d) für GanttBar ist nicht im zulässigen Bereich.',1),
+6029 => array('Der Offset für die vertikale Linie muss im Bereich [0,1] sein.',0),
+6030 => array('Unbekannte Pfeilrichtung für eine Verbindung.',0),
+6031 => array('Unbekannter Pfeiltyp für eine Verbindung.',0),
+6032 => array('Interner Fehler: Unbekannter Pfadtyp (=%d) für eine Verbindung.',1),
+6033 => array('Array of fonts must contain arrays with 3 elements, i.e. (Family, Style, Size)',0),
+
+/*
+**  jpgraph_gradient
+*/
+
+7001 => array('Unbekannter Gradiententyp (=%d).',1),
+
+/*
+**  jpgraph_iconplot
+*/
+
+8001 => array('Der Mix-Wert für das Icon muss zwischen 0 und 100 sein.',0),
+8002 => array('Die Ankerposition für Icons muss entweder "top", "bottom", "left", "right" oder "center" sein.',0),
+8003 => array('Es ist nicht möglich, gleichzeitig ein Bild und eine Landesflagge für dasselbe Icon zu definieren',0),
+8004 => array('Wenn Du Landesflaggen benutzen willst, musst Du die Datei "jpgraph_flags.php" hinzufügen (per include).',0),
+
+/*
+**  jpgraph_imgtrans
+*/
+
+9001 => array('Der Wert für die Bildtransformation ist außerhalb des zulässigen Bereichs. Der verschwindende Punkt am Horizont muss als Wert zwischen 0 und 1 angegeben werden.',0),
+
+/*
+**  jpgraph_lineplot
+*/
+
+10001 => array('Die Methode LinePlot::SetFilled() sollte nicht mehr benutzt werden. Benutze lieber SetFillColor()',0),
+10002 => array('Der Plot ist zu kompliziert für FastLineStroke. Benutze lieber den StandardStroke()',0),
+10003 => array('Each plot in an accumulated lineplot must have the same number of data points.',0),
+/*
+**  jpgraph_log
+*/
+
+11001 => array('Deine Daten enthalten nicht-numerische Werte.',0),
+11002 => array('Negative Werte können nicht für logarithmische Achsen verwendet werden.',0),
+11003 => array('Deine Daten enthalten nicht-numerische Werte.',0),
+11004 => array('Skalierungsfehler für die logarithmische Achse. Es gibt ein Problem mit den Daten der Achse. Der größte Wert muss größer sein als Null. Es ist mathematisch nicht möglich, einen Wert gleich Null in der Skala zu haben.',0),
+11005 => array('Das Tick-Intervall für die logarithmische Achse ist nicht definiert. Lösche jeden Aufruf von SetTextLabelStart() oder SetTextTickInterval() bei der logarithmischen Achse.',0),
+
+/*
+**  jpgraph_mgraph
+*/
+
+12001 => array("Du benutzt GD 2.x und versuchst ein Nicht-Truecolor-Bild als Hintergrundbild zu benutzen. Um Hintergrundbilder mit GD 2.x zu benutzen, ist es notwendig Truecolor zu aktivieren, indem die USE_TRUECOLOR-Konstante auf TRUE gesetzt wird. Wegen eines Bugs in GD 2.0.1 ist die Qualität der Truetype-Schriften sehr schlecht, wenn man Truetype-Schriften mit Truecolor-Bildern verwendet.",0),
+12002 => array('Ungültiger Dateiname für MGraph::SetBackgroundImage() : %s. Die Datei muss eine gültige Dateierweiterung haben (jpg,gif,png), wenn die automatische Typerkennung verwendet wird.',1),
+12003 => array('Unbekannte Dateierweiterung (%s) in MGraph::SetBackgroundImage() für Dateiname: %s',2),
+12004 => array('Das Bildformat des Hintergrundbildes (%s) wird von Deiner System-Konfiguration nicht unterstützt. ',1),
+12005 => array('Das Hintergrundbild kann nicht gelesen werden: %s',1),
+12006 => array('Es wurden ungültige Größen für Breite oder Höhe beim Erstellen des Bildes angegeben, (Breite=%d, Höhe=%d)',2),
+12007 => array('Das Argument für MGraph::Add() ist nicht gültig für GD.',0),
+12008 => array('Deine PHP- (und GD-lib-) Installation scheint keine bekannten Bildformate zu unterstützen.',0),
+12009 => array('Deine PHP-Installation unterstützt das gewählte Bildformat nicht: %s',1),
+12010 => array('Es konnte kein Bild als Datei %s erzeugt werden. Überprüfe, ob Du die entsprechenden Schreibrechte im aktuellen Verzeichnis hast.',1),
+12011 => array('Es konnte kein Truecolor-Bild erzeugt werden. Überprüfe, ob Du wirklich die GD2-Bibliothek installiert hast.',0),
+12012 => array('Es konnte kein Bild erzeugt werden. Überprüfe, ob Du wirklich die GD2-Bibliothek installiert hast.',0),
+
+/*
+**  jpgraph_pie3d
+*/
+
+14001 => array('Pie3D::ShowBorder(). Missbilligte Funktion. Benutze Pie3D::SetEdge(), um die Ecken der Tortenstücke zu kontrollieren.',0),
+14002 => array('PiePlot3D::SetAngle() 3D-Torten-Projektionswinkel muss zwischen 5 und 85 Grad sein.',0),
+14003 => array('Interne Festlegung schlug fehl. Pie3D::Pie3DSlice',0),
+14004 => array('Tortenstück-Startwinkel muss zwischen 0 und 360 Grad sein.',0),
+14005 => array('Pie3D Interner Fehler: Versuch, zweimal zu umhüllen bei der Suche nach dem Startindex.',0,),
+14006 => array('Pie3D Interner Fehler: Z-Sortier-Algorithmus für 3D-Tortendiagramme funktioniert nicht einwandfrei (2). Versuch, zweimal zu umhüllen beim Erstellen des Bildes.',0),
+14007 => array('Die Breite für das 3D-Tortendiagramm ist 0. Gib eine Breite > 0 an.',0),
+
+/*
+**  jpgraph_pie
+*/
+
+15001 => array('PiePLot::SetTheme() Unbekannter Stil: %s',1),
+15002 => array('Argument für PiePlot::ExplodeSlice() muss ein Integer-Wert sein',0),
+15003 => array('Argument für PiePlot::Explode() muss ein Vektor mit Integer-Werten sein.',0),
+15004 => array('Tortenstück-Startwinkel muss zwischen 0 und 360 Grad sein.',0),
+15005 => array('PiePlot::SetFont() sollte nicht mehr verwendet werden. Benutze stattdessen PiePlot->value->SetFont().',0),
+15006 => array('PiePlot::SetSize() Radius für Tortendiagramm muss entweder als Bruch [0, 0.5] der Bildgröße oder als Absoluwert in Pixel im Bereich [10, 1000] angegeben werden.',0),
+15007 => array('PiePlot::SetFontColor() sollte nicht mehr verwendet werden. Benutze stattdessen PiePlot->value->SetColor()..',0),
+15008 => array('PiePlot::SetLabelType() der Typ für Tortendiagramme muss entweder 0 or 1 sein (nicht %d).',1),
+15009 => array('Ungültiges Tortendiagramm. Die Summe aller Daten ist Null.',0),
+15010 => array('Die Summe aller Daten ist Null.',0),
+15011 => array('Um Bildtransformationen benutzen zu können, muss die Datei jpgraph_imgtrans.php eingefügt werden (per include).',0), // @todo translate into German
+15012 => array('PiePlot::SetTheme() is no longer recommended. Use PieGraph::SetTheme()',0),
+
+/*
+**  jpgraph_plotband
+*/
+
+16001 => array('Die Dichte für das Pattern muss zwischen 1 und 100 sein. (Du hast %f eingegeben)',1),
+16002 => array('Es wurde keine Position für das Pattern angegeben.',0),
+16003 => array('Unbekannte Pattern-Definition (%d)',0),
+16004 => array('Der Mindeswert für das PlotBand ist größer als der Maximalwert. Bitte korrigiere dies!',0),
+
+
+/*
+**  jpgraph_polar
+*/
+
+17001 => array('PolarPlots müssen eine gerade Anzahl von Datenpunkten haben. Jeder Datenpunkt ist ein Tupel (Winkel, Radius).',0),
+17002 => array('Unbekannte Ausrichtung für X-Achsen-Titel. (%s)',1),
+//17003 => array('Set90AndMargin() wird für PolarGraph nicht unterstützt.',0),
+17004 => array('Unbekannter Achsentyp für PolarGraph. Er muss entweder \'lin\' oder \'log\' sein.',0),
+
+/*
+**  jpgraph_radar
+*/
+
+18001 => array('ClientSideImageMaps werden für RadarPlots nicht unterstützt.',0),
+18002 => array('RadarGraph::SupressTickMarks() sollte nicht mehr verwendet werden. Benutze stattdessen HideTickMarks().',0),
+18003 => array('Ungültiger Achsentyp für RadarPlot (%s). Er muss entweder \'lin\' oder \'log\' sein.',1),
+18004 => array('Die RadarPlot-Größe muss zwischen 0.1 und 1 sein. (Dein Wert=%f)',1),
+18005 => array('RadarPlot: nicht unterstützte Tick-Dichte: %d',1),
+18006 => array('Minimum Daten %f (RadarPlots sollten nur verwendet werden, wenn alle Datenpunkte einen Wert > 0 haben).',1),
+18007 => array('Die Anzahl der Titel entspricht nicht der Anzahl der Datenpunkte.',0),
+18008 => array('Jeder RadarPlot muss die gleiche Anzahl von Datenpunkten haben.',0),
+
+/*
+**  jpgraph_regstat
+*/
+
+19001 => array('Spline: Anzahl der X- und Y-Koordinaten muss gleich sein.',0),
+19002 => array('Ungültige Dateneingabe für Spline. Zwei oder mehr aufeinanderfolgende X-Werte sind identisch. Jeder eigegebene X-Wert muss unterschiedlich sein, weil vom mathematischen Standpunkt ein Eins-zu-Eins-Mapping vorliegen muss, d.h. jeder X-Wert korrespondiert mit exakt einem Y-Wert.',0),
+19003 => array('Bezier: Anzahl der X- und Y-Koordinaten muss gleich sein.',0),
+
+/*
+**  jpgraph_scatter
+*/
+
+20001 => array('Fieldplots müssen die gleiche Anzahl von X und Y Datenpunkten haben.',0),
+20002 => array('Bei Fieldplots muss ein Winkel für jeden X und Y Datenpunkt angegeben werden.',0),
+20003 => array('Scatterplots müssen die gleiche Anzahl von X- und Y-Datenpunkten haben.',0),
+
+/*
+**  jpgraph_stock
+*/
+
+21001 => array('Die Anzahl der Datenwerte für Stock-Charts müssen ein Mehrfaches von %d Datenpunkten sein.',1),
+
+/*
+**  jpgraph_plotmark
+*/
+
+23001 => array('Der Marker "%s" existiert nicht in der Farbe: %d',2),
+23002 => array('Der Farb-Index ist zu hoch für den Marker "%s"',1),
+23003 => array('Ein Dateiname muss angegeben werden, wenn Du den Marker-Typ auf MARK_IMG setzt.',0),
+
+/*
+**  jpgraph_utils
+*/
+
+24001 => array('FuncGenerator : Keine Funktion definiert. ',0),
+24002 => array('FuncGenerator : Syntax-Fehler in der Funktionsdefinition ',0),
+24003 => array('DateScaleUtils: Unknown tick type specified in call to GetTicks()',0),
+24004 => array('ReadCSV2: Die anzahl der spalten fehler in %s reihe %d',2),
+/*
+**  jpgraph
+*/
+
+25001 => array('Diese PHP-Installation ist nicht mit der GD-Bibliothek kompiliert. Bitte kompiliere PHP mit GD-Unterstützung neu, damit JpGraph funktioniert. (Weder die Funktion imagetypes() noch imagecreatefromstring() existiert!)',0),
+25002 => array('Diese PHP-Installation scheint nicht die benötigte GD-Bibliothek zu unterstützen. Bitte schau in der PHP-Dokumentation nach, wie man die GD-Bibliothek installiert und aktiviert.',0),
+25003 => array('Genereller PHP Fehler : Bei %s:%d : %s',3),
+25004 => array('Genereller PHP Fehler : %s ',1),
+25005 => array('PHP_SELF, die PHP-Global-Variable kann nicht ermittelt werden. PHP kann nicht von der Kommandozeile gestartet werden, wenn der Cache oder die Bilddateien automatisch benannt werden sollen.',0),
+25006 => array('Die Benutzung der FF_CHINESE (FF_BIG5) Schriftfamilie benötigt die iconv() Funktion in Deiner PHP-Konfiguration. Dies wird nicht defaultmäßig in PHP kompiliert (benötigt "--width-iconv" bei der Konfiguration).',0),
+25007 => array('Du versuchst das lokale (%s) zu verwenden, was von Deiner PHP-Installation nicht unterstützt wird. Hinweis: Benutze \'\', um das defaultmäßige Lokale für diese geographische Region festzulegen.',1),
+25008 => array('Die Bild-Breite und Höhe in Graph::Graph() müssen numerisch sein',0),
+25009 => array('Die Skalierung der Achsen muss angegeben werden mit Graph::SetScale()',0),
+
+25010 => array('Graph::Add() Du hast versucht, einen leeren Plot zum Graph hinzuzufügen.',0),
+25011 => array('Graph::AddY2() Du hast versucht, einen leeren Plot zum Graph hinzuzufügen.',0),
+25012 => array('Graph::AddYN() Du hast versucht, einen leeren Plot zum Graph hinzuzufügen.',0),
+25013 => array('Es können nur Standard-Plots zu multiplen Y-Achsen hinzugefügt werden',0),
+25014 => array('Graph::AddText() Du hast versucht, einen leeren Text zum Graph hinzuzufügen.',0),
+25015 => array('Graph::AddLine() Du hast versucht, eine leere Linie zum Graph hinzuzufügen.',0),
+25016 => array('Graph::AddBand() Du hast versucht, ein leeres Band zum Graph hinzuzufügen.',0),
+25017 => array('Du benutzt GD 2.x und versuchst, ein Hintergrundbild in einem Truecolor-Bild zu verwenden. Um Hintergrundbilder mit GD 2.x zu verwenden, ist es notwendig, Truecolor zu aktivieren, indem die USE_TRUECOLOR-Konstante auf TRUE gesetzt wird. Wegen eines Bugs in GD 2.0.1 ist die Qualität der Schrift sehr schlecht, wenn Truetype-Schrift in Truecolor-Bildern verwendet werden.',0),
+25018 => array('Falscher Dateiname für Graph::SetBackgroundImage() : "%s" muss eine gültige Dateinamenerweiterung (jpg,gif,png) haben, wenn die automatische Dateityperkennung verwenndet werden soll.',1),
+25019 => array('Unbekannte Dateinamenerweiterung (%s) in Graph::SetBackgroundImage() für Dateiname: "%s"',2),
+
+25020 => array('Graph::SetScale(): Dar Maximalwert muss größer sein als der Mindestwert.',0),
+25021 => array('Unbekannte Achsendefinition für die Y-Achse. (%s)',1),
+25022 => array('Unbekannte Achsendefinition für die X-Achse. (%s)',1),
+25023 => array('Nicht unterstützter Y2-Achsentyp: "%s" muss einer von (lin,log,int) sein.',1),
+25024 => array('Nicht unterstützter X-Achsentyp: "%s" muss einer von (lin,log,int) sein.',1),
+25025 => array('Nicht unterstützte Tick-Dichte: %d',1),
+25026 => array('Nicht unterstützter Typ der nicht angegebenen Y-Achse. Du hast entweder: 1. einen Y-Achsentyp für automatisches Skalieren definiert, aber keine Plots angegeben. 2. eine Achse direkt definiert, aber vergessen, die Tick-Dichte zu festzulegen.',0),
+25027 => array('Kann cached CSIM "%s" zum Lesen nicht öffnen.',1),
+25028 => array('Apache/PHP hat keine Schreibrechte, in das CSIM-Cache-Verzeichnis (%s) zu schreiben. Überprüfe die Rechte.',1),
+25029 => array('Kann nicht in das CSIM "%s" schreiben. Überprüfe die Schreibrechte und den freien Speicherplatz.',1),
+
+25030 => array('Fehlender Skriptname für StrokeCSIM(). Der Name des aktuellen Skriptes muss als erster Parameter von StrokeCSIM() angegeben werden.',0),
+25031 => array('Der Achsentyp muss mittels Graph::SetScale() angegeben werden.',0),
+25032 => array('Es existieren keine Plots für die Y-Achse nbr:%d',1),
+25033 => array('',0),
+25034 => array('Undefinierte X-Achse kann nicht gezeichnet werden. Es wurden keine Plots definiert.',0),
+25035 => array('Du hast Clipping aktiviert. Clipping wird nur für Diagramme mit 0 oder 90 Grad Rotation unterstützt. Bitte verändere Deinen Rotationswinkel (=%d Grad) dementsprechend oder deaktiviere Clipping.',1),
+25036 => array('Unbekannter Achsentyp AxisStyle() : %s',1),
+25037 => array('Das Bildformat Deines Hintergrundbildes (%s) wird von Deiner System-Konfiguration nicht unterstützt. ',1),
+25038 => array('Das Hintergrundbild scheint von einem anderen Typ (unterschiedliche Dateierweiterung) zu sein als der angegebene Typ. Angegebenen: %s; Datei: %s',2),
+25039 => array('Hintergrundbild kann nicht gelesen werden: "%s"',1),
+
+25040 => array('Es ist nicht möglich, sowohl ein Hintergrundbild als auch eine Hintergrund-Landesflagge anzugeben.',0),
+25041 => array('Um Landesflaggen als Hintergrund benutzen zu können, muss die Datei "jpgraph_flags.php" eingefügt werden (per include).',0),
+25042 => array('Unbekanntes Hintergrundbild-Layout',0),
+25043 => array('Unbekannter Titelhintergrund-Stil.',0),
+25044 => array('Automatisches Skalieren kann nicht verwendet werden, weil es unmöglich ist, einen gültigen min/max Wert für die Y-Achse zu ermitteln (nur Null-Werte).',0),
+25045 => array('Die Schriftfamilien FF_HANDWRT und FF_BOOK sind wegen Copyright-Problemen nicht mehr verfügbar. Diese Schriften können nicht mehr mit JpGraph verteilt werden. Bitte lade Dir Schriften von http://corefonts.sourceforge.net/ herunter.',0),
+25046 => array('Angegebene TTF-Schriftfamilie (id=%d) ist unbekannt oder existiert nicht. Bitte merke Dir, dass TTF-Schriften wegen Copyright-Problemen nicht mit JpGraph mitgeliefert werden. Du findest MS-TTF-Internetschriften (arial, courier, etc.) zum Herunterladen unter http://corefonts.sourceforge.net/',1),
+25047 => array('Stil %s ist nicht verfügbar für Schriftfamilie %s',2),
+25048 => array('Unbekannte Schriftstildefinition [%s].',1),
+25049 => array('Schriftdatei "%s" ist nicht lesbar oder existiert nicht.',1),
+
+25050 => array('Erstes Argument für Text::Text() muss ein String sein.',0),
+25051 => array('Ungültige Richtung angegeben für Text.',0),
+25052 => array('PANIK: Interner Fehler in SuperScript::Stroke(). Unbekannte vertikale Ausrichtung für Text.',0),
+25053 => array('PANIK: Interner Fehler in SuperScript::Stroke(). Unbekannte horizontale Ausrichtung für Text.',0),
+25054 => array('Interner Fehler: Unbekannte Grid-Achse %s',1),
+25055 => array('Axis::SetTickDirection() sollte nicht mehr verwendet werden. Benutze stattdessen Axis::SetTickSide().',0),
+25056 => array('SetTickLabelMargin() sollte nicht mehr verwendet werden. Benutze stattdessen Axis::SetLabelMargin().',0),
+25057 => array('SetTextTicks() sollte nicht mehr verwendet werden. Benutze stattdessen SetTextTickInterval().',0),
+25058 => array('TextLabelIntevall >= 1 muss angegeben werden.',0),
+25059 => array('SetLabelPos() sollte nicht mehr verwendet werden. Benutze stattdessen Axis::SetLabelSide().',0),
+
+25060 => array('Unbekannte Ausrichtung angegeben für X-Achsentitel (%s).',1),
+25061 => array('Unbekannte Ausrichtung angegeben für Y-Achsentitel (%s).',1),
+25062 => array('Label unter einem Winkel werden für die Y-Achse nicht unterstützt.',0),
+25063 => array('Ticks::SetPrecision() sollte nicht mehr verwendet werden. Benutze stattdessen Ticks::SetLabelFormat() (oder Ticks::SetFormatCallback()).',0),
+25064 => array('Kleinere oder größere Schrittgröße ist 0. Überprüfe, ob Du fälschlicherweise SetTextTicks(0) in Deinem Skript hast. Wenn dies nicht der Fall ist, bist Du eventuell über einen Bug in JpGraph gestolpert. Bitte sende einen Report und füge den Code an, der den Fehler verursacht hat.',0),
+25065 => array('Tick-Positionen müssen als array() angegeben werden',0),
+25066 => array('Wenn die Tick-Positionen und -Label von Hand eingegeben werden, muss die Anzahl der Ticks und der Label gleich sein.',0),
+25067 => array('Deine von Hand eingegebene Achse und Ticks sind nicht korrekt. Die Skala scheint zu klein zu sein für den Tickabstand.',0),
+25068 => array('Ein Plot hat eine ungültige Achse. Dies kann beispielsweise der Fall sein, wenn Du automatisches Text-Skalieren verwendest, um ein Liniendiagramm zu zeichnen mit nur einem Datenpunkt, oder wenn die Bildfläche zu klein ist. Es kann auch der Fall sein, dass kein Datenpunkt einen numerischen Wert hat (vielleicht nur \'-\' oder \'x\').',0),
+25069 => array('Grace muss größer sein als 0',0),
+
+25070 => array('Deine Daten enthalten nicht-numerische Werte.',0),
+25071 => array('Du hast mit SetAutoMin() einen Mindestwert angegeben, der größer ist als der Maximalwert für die Achse. Dies ist nicht möglich.',0),
+25072 => array('Du hast mit SetAutoMax() einen Maximalwert angegeben, der kleiner ist als der Minimalwert der Achse. Dies ist nicht möglich.',0),
+25073 => array('Interner Fehler. Der Integer-Skalierungs-Algorithmus-Vergleich ist außerhalb der Grenzen  (r=%f).',1),
+25074 => array('Interner Fehler. Der Skalierungsbereich ist negativ (%f) [für %s Achse]. Dieses Problem könnte verursacht werden durch den Versuch, \'ungültige\' Werte in die Daten-Vektoren einzugeben (z.B. nur String- oder NULL-Werte), was beim automatischen Skalieren einen Fehler erzeugt.',2),
+25075 => array('Die automatischen Ticks können nicht gesetzt werden, weil min==max.',0),
+25077 => array('Einstellfaktor für die Farbe muss größer sein als 0',0),
+25078 => array('Unbekannte Farbe: %s',1),
+25079 => array('Unbekannte Farbdefinition: %s, Größe=%d',2),
+
+25080 => array('Der Alpha-Parameter für Farben muss zwischen 0.0 und 1.0 liegen.',0),
+25081 => array('Das ausgewählte Grafikformat wird entweder nicht unterstützt oder ist unbekannt [%s]',1),
+25082 => array('Es wurden ungültige Größen für Breite und Höhe beim Erstellen des Bildes definiert (Breite=%d, Höhe=%d).',2),
+25083 => array('Es wurde eine ungültige Größe beim Kopieren des Bildes angegeben. Die Größe für das kopierte Bild wurde auf 1 Pixel oder weniger gesetzt.',0),
+25084 => array('Fehler beim Erstellen eines temporären GD-Canvas. Möglicherweise liegt ein Arbeitsspeicherproblem vor.',0),
+25085 => array('Ein Bild kann nicht aus dem angegebenen String erzeugt werden. Er ist entweder in einem nicht unterstützen Format oder er represäntiert ein kaputtes Bild.',0),
+25086 => array('Du scheinst nur GD 1.x installiert zu haben. Um Alphablending zu aktivieren, ist GD 2.x oder höher notwendig. Bitte installiere GD 2.x oder versichere Dich, dass die Konstante USE_GD2 richtig gesetzt ist. Standardmäßig wird die installierte GD-Version automatisch erkannt. Ganz selten wird GD2 erkannt, obwohl nur GD1 installiert ist. Die Konstante USE_GD2 muss dann zu "false" gesetzt werden.',0),
+25087 => array('Diese PHP-Version wurde ohne TTF-Unterstützung konfiguriert. PHP muss mit TTF-Unterstützung neu kompiliert und installiert werden.',0),
+25088 => array('Die GD-Schriftunterstützung wurde falsch konfiguriert. Der Aufruf von imagefontwidth() ist fehlerhaft.',0),
+25089 => array('Die GD-Schriftunterstützung wurde falsch konfiguriert. Der Aufruf von imagefontheight() ist fehlerhaft.',0),
+
+25090 => array('Unbekannte Richtung angegeben im Aufruf von StrokeBoxedText() [%s].',1),
+25091 => array('Die interne Schrift untestützt das Schreiben von Text in einem beliebigen Winkel nicht. Benutze stattdessen TTF-Schriften.',0),
+25092 => array('Es liegt entweder ein Konfigurationsproblem mit TrueType oder ein Problem beim Lesen der Schriftdatei "%s" vor. Versichere Dich, dass die Datei existiert und Leserechte und -pfad vergeben sind. (wenn \'basedir\' restriction in PHP aktiviert ist, muss die Schriftdatei im Dokumentwurzelverzeichnis abgelegt werden). Möglicherweise ist die FreeType-Bibliothek falsch installiert. Versuche, mindestens zur FreeType-Version 2.1.13 zu aktualisieren und kompiliere GD mit einem korrekten Setup neu, damit die FreeType-Bibliothek gefunden werden kann.',1),
+25093 => array('Die Schriftdatei "%s" kann nicht gelesen werden beim Aufruf von Image::GetBBoxTTF. Bitte versichere Dich, dass die Schrift gesetzt wurde, bevor diese Methode aufgerufen wird, und dass die Schrift im TTF-Verzeichnis installiert ist.',1),
+25094 => array('Die Textrichtung muss in einem Winkel zwischen 0 und 90 engegeben werden.',0),
+25095 => array('Unbekannte Schriftfamilien-Definition. ',0),
+25096 => array('Der Farbpalette können keine weiteren Farben zugewiesen werden. Dem Bild wurde bereits die größtmögliche Anzahl von Farben (%d) zugewiesen und die Palette ist voll. Verwende stattdessen ein TrueColor-Bild',0),
+25097 => array('Eine Farbe wurde als leerer String im Aufruf von PushColor() angegegeben.',0),
+25098 => array('Negativer Farbindex. Unpassender Aufruf von PopColor().',0),
+25099 => array('Die Parameter für Helligkeit und Kontrast sind außerhalb des zulässigen Bereichs [-1,1]',0),
+
+25100 => array('Es liegt ein Problem mit der Farbpalette und dem GD-Setup vor. Bitte deaktiviere anti-aliasing oder verwende GD2 mit TrueColor. Wenn die GD2-Bibliothek installiert ist, versichere Dich, dass die Konstante USE_GD2 auf "true" gesetzt und TrueColor aktiviert ist.',0),
+25101 => array('Ungültiges numerisches Argument für SetLineStyle(): (%d)',1),
+25102 => array('Ungültiges String-Argument für SetLineStyle(): %s',1),
+25103 => array('Ungültiges Argument für SetLineStyle %s',1),
+25104 => array('Unbekannter Linientyp: %s',1),
+25105 => array('Es wurden NULL-Daten für ein gefülltes Polygon angegeben. Sorge dafür, dass keine NULL-Daten angegeben werden.',0),
+25106 => array('Image::FillToBorder : es können keine weiteren Farben zugewiesen werden.',0),
+25107 => array('In Datei "%s" kann nicht geschrieben werden. Überprüfe die aktuellen Schreibrechte.',1),
+25108 => array('Das Bild kann nicht gestreamt werden. Möglicherweise liegt ein Fehler im PHP/GD-Setup vor. Kompiliere PHP neu und verwende die eingebaute GD-Bibliothek, die mit PHP angeboten wird.',0),
+25109 => array('Deine PHP- (und GD-lib-) Installation scheint keine bekannten Grafikformate zu unterstützen. Sorge zunächst dafür, dass GD als PHP-Modul kompiliert ist. Wenn Du außerdem JPEG-Bilder verwenden willst, musst Du die JPEG-Bibliothek installieren. Weitere Details sind in der PHP-Dokumentation zu finden.',0),
+
+25110 => array('Dein PHP-Installation unterstützt das gewählte Grafikformat nicht: %s',1),
+25111 => array('Das gecachete Bild %s kann nicht gelöscht werden. Problem mit den Rechten?',1),
+25112 => array('Das Datum der gecacheten Datei (%s) liegt in der Zukunft.',1),
+25113 => array('Das gecachete Bild %s kann nicht gelöscht werden. Problem mit den Rechten?',1),
+25114 => array('PHP hat nicht die erforderlichen Rechte, um in die Cache-Datei %s zu schreiben. Bitte versichere Dich, dass der Benutzer, der PHP anwendet, die entsprechenden Schreibrechte für die Datei hat, wenn Du das Cache-System in JPGraph verwenden willst.',1),
+25115 => array('Berechtigung für gecachetes Bild %s kann nicht gesetzt werden. Problem mit den Rechten?',1),
+25116 => array('Datei kann nicht aus dem Cache %s geöffnet werden',1),
+25117 => array('Gecachetes Bild %s kann nicht zum Lesen geöffnet werden.',1),
+25118 => array('Verzeichnis %s kann nicht angelegt werden. Versichere Dich, dass PHP die Schreibrechte in diesem Verzeichnis hat.',1),
+25119 => array('Rechte für Datei %s können nicht gesetzt werden. Problem mit den Rechten?',1),
+
+25120 => array('Die Position für die Legende muss als Prozentwert im Bereich 0-1 angegeben werden.',0),
+25121 => array('Eine leerer Datenvektor wurde für den Plot eingegeben. Es muss wenigstens ein Datenpunkt vorliegen.',0),
+25122 => array('Stroke() muss als Subklasse der Klasse Plot definiert sein.',0),
+25123 => array('Du kannst keine Text-X-Achse mit X-Koordinaten verwenden. Benutze stattdessen eine "int" oder "lin" Achse.',0),
+25124 => array('Der Eingabedatenvektor mus aufeinanderfolgende Werte von 0 aufwärts beinhalten. Der angegebene Y-Vektor beginnt mit leeren Werten (NULL).',0),
+25125 => array('Ungültige Richtung für statische Linie.',0),
+25126 => array('Es kann kein TrueColor-Bild erzeugt werden. Überprüfe, ob die GD2-Bibliothek und PHP korrekt aufgesetzt wurden.',0),
+25127 => array('The library has been configured for automatic encoding conversion of Japanese fonts. This requires that PHP has the mb_convert_encoding() function. Your PHP installation lacks this function (PHP needs the "--enable-mbstring" when compiled).',0),
+25128 => array('The function imageantialias() is not available in your PHP installation. Use the GD version that comes with PHP and not the standalone version.',0),
+25129 => array('Anti-alias can not be used with dashed lines. Please disable anti-alias or use solid lines.',0),
+25130 => array('Too small plot area. (%d x %d). With the given image size and margins there is to little space left for the plot. Increase the plot size or reduce the margins.',2),
+
+25131 => array('StrokeBoxedText2() only supports TTF fonts and not built-in bitmap fonts.',0),
+25132 => array('Undefined property %s.',1), // @todo translate
+25133 => array('Use Graph::SetTheme() after Graph::SetScale().',0), // @todo translate
+
+/*
+**  jpgraph_led
+*/
+
+25500 => array('Multibyte strings must be enabled in the PHP installation in order to run the LED module so that the function mb_strlen() is available. See PHP documentation for more information.',0),
+
+
+/*
+**---------------------------------------------------------------------------------------------
+** Pro-version strings
+**---------------------------------------------------------------------------------------------
+*/
+
+/*
+**  jpgraph_table
+*/
+
+27001 => array('GTextTable: Ungültiges Argument für Set(). Das Array-Argument muss 2-- dimensional sein.',0),
+27002 => array('GTextTable: Ungültiges Argument für Set()',0),
+27003 => array('GTextTable: Falsche Anzahl von Argumenten für GTextTable::SetColor()',0),
+27004 => array('GTextTable: Angegebener Zellenbereich, der verschmolzen werden soll, ist ungültig.',0),
+27005 => array('GTextTable: Bereits verschmolzene Zellen im Bereich (%d,%d) bis (%d,%d) können nicht ein weiteres Mal verschmolzen werden.',4),
+27006 => array('GTextTable: Spalten-Argument = %d liegt außerhalb der festgelegten Tabellengröße.',1),
+27007 => array('GTextTable: Zeilen-Argument = %d liegt außerhalb der festgelegten Tabellengröße.',1),
+27008 => array('GTextTable: Spalten- und Zeilengröße müssen zu den Dimensionen der Tabelle passen.',0),
+27009 => array('GTextTable: Die Anzahl der Tabellenspalten oder -zeilen ist 0. Versichere Dich, dass die Methoden Init() oder Set() aufgerufen werden.',0),
+27010 => array('GTextTable: Es wurde keine Ausrichtung beim Aufruf von SetAlign() angegeben.',0),
+27011 => array('GTextTable: Es wurde eine unbekannte Ausrichtung beim Aufruf von SetAlign() abgegeben. Horizontal=%s, Vertikal=%s',2),
+27012 => array('GTextTable: Interner Fehler. Es wurde ein ungültiges Argument festgeleget %s',1),
+27013 => array('GTextTable: Das Argument für FormatNumber() muss ein String sein.',0),
+27014 => array('GTextTable: Die Tabelle wurde weder mit einem Aufruf von Set() noch von Init() initialisiert.',0),
+27015 => array('GTextTable: Der Zellenbildbedingungstyp muss entweder TIMG_WIDTH oder TIMG_HEIGHT sein.',0),
+
+/*
+**  jpgraph_windrose
+*/
+
+22001 => array('Die Gesamtsumme der prozentualen Anteile aller Windrosenarme darf 100%% nicht überschreiten!\n(Aktuell max: %d)',1),
+22002 => array('Das Bild ist zu klein für eine Skala. Bitte vergrößere das Bild.',0),
+22004 => array('Die Etikettendefinition für Windrosenrichtungen müssen 16 Werte haben (eine für jede Kompassrichtung).',0),
+22005 => array('Der Linientyp für radiale Linien muss einer von ("solid","dotted","dashed","longdashed") sein.',0),
+22006 => array('Es wurde ein ungültiger Windrosentyp angegeben.',0),
+22007 => array('Es wurden zu wenig Werte für die Bereichslegende angegeben.',0),
+22008 => array('Interner Fehler: Versuch, eine freie Windrose zu plotten, obwohl der Typ keine freie Windrose ist.',0),
+22009 => array('Du hast die gleiche Richtung zweimal angegeben, einmal mit einem Winkel und einmal mit einer Kompassrichtung (%f Grad).',0),
+22010 => array('Die Richtung muss entweder ein numerischer Wert sein oder eine der 16 Kompassrichtungen',0),
+22011 => array('Der Windrosenindex muss ein numerischer oder Richtungswert sein. Du hast angegeben Index=%d',1),
+22012 => array('Die radiale Achsendefinition für die Windrose enthält eine nicht aktivierte Richtung.',0),
+22013 => array('Du hast dasselbe Look&Feel für die gleiche Kompassrichtung zweimal engegeben, einmal mit Text und einmal mit einem Index (Index=%d)',1),
+22014 => array('Der Index für eine Kompassrichtung muss zwischen 0 und 15 sein.',0),
+22015 => array('Du hast einen unbekannten Windrosenplottyp angegeben.',0),
+22016 => array('Der Windrosenarmindex muss ein numerischer oder ein Richtungswert sein.',0),
+22017 => array('Die Windrosendaten enthalten eine Richtung, die nicht aktiviert ist. Bitte berichtige, welche Label angezeigt werden sollen.',0),
+22018 => array('Du hast für dieselbe Kompassrichtung zweimal Daten angegeben, einmal mit Text und einmal mit einem Index (Index=%d)',1),
+22019 => array('Der Index für eine Richtung muss zwischen 0 und 15 sein. Winkel dürfen nicht für einen regelmäßigen Windplot angegeben werden, sondern entweder ein Index oder eine Kompassrichtung.',0),
+22020 => array('Der Windrosenplot ist zu groß für die angegebene Bildgröße. Benutze entweder WindrosePlot::SetSize(), um den Plot kleiner zu machen oder vergrößere das Bild im ursprünglichen Aufruf von WindroseGraph().',0),
+22021 => array('It is only possible to add Text, IconPlot or WindrosePlot to a Windrose Graph',0),
+
+/*
+**  jpgraph_odometer
+*/
+
+13001 => array('Unbekannter Nadeltypstil (%d).',1),
+13002 => array('Ein Wert für das Odometer (%f) ist außerhalb des angegebenen Bereichs [%f,%f]',3),
+
+/*
+**  jpgraph_barcode
+*/
+
+1001 => array('Unbekannte Kodier-Specifikation: %s',1),
+1002 => array('datenvalidierung schlug fehl. [%s] kann nicht mittels der Kodierung "%s" kodiert werden',2),
+1003 => array('Interner Kodierfehler. Kodieren von %s ist nicht möglich in Code 128',1),
+1004 => array('Interner barcode Fehler. Unbekannter UPC-E Kodiertyp: %s',1),
+1005 => array('Interner Fehler. Das Textzeichen-Tupel (%s, %s) kann nicht im Code-128 Zeichensatz C kodiert werden.',2),
+1006 => array('Interner Kodierfehler für CODE 128. Es wurde versucht, CTRL in CHARSET != A zu kodieren.',0),
+1007 => array('Interner Kodierfehler für CODE 128. Es wurde versucht, DEL in CHARSET != B zu kodieren.',0),
+1008 => array('Interner Kodierfehler für CODE 128. Es wurde versucht, kleine Buchstaben in CHARSET != B zu kodieren.',0),
+1009 => array('Kodieren mittels CODE 93 wird noch nicht unterstützt.',0),
+1010 => array('Kodieren mittels POSTNET wird noch nicht unterstützt.',0),
+1011 => array('Nicht untrstütztes Barcode-Backend für den Typ %s',1),
+
+/*
+** PDF417
+*/
+
+26000 => array('PDF417: The PDF417 module requires that the PHP installation must support the function bcmod(). This is normally enabled at compile time. See documentation for more information.',0),
+26001 => array('PDF417: Die Anzahl der Spalten muss zwischen 1 und 30 sein.',0),
+26002 => array('PDF417: Der Fehler-Level muss zwischen 0 und 8 sein.',0),
+26003 => array('PDF417: Ungültiges Format für Eingabedaten, um sie mit PDF417 zu kodieren.',0),
+26004 => array('PDF417: die eigebenen Daten können nicht mit Fehler-Level %d und %d spalten kodiert werden, weil daraus zu viele Symbole oder mehr als 90 Zeilen resultieren.',2),
+26005 => array('PDF417: Die Datei "%s" kann nicht zum Schreiben geöffnet werden.',1),
+26006 => array('PDF417: Interner Fehler. Die Eingabedatendatei für PDF417-Cluster %d ist fehlerhaft.',1),
+26007 => array('PDF417: Interner Fehler. GetPattern: Ungültiger Code-Wert %d (Zeile %d)',2),
+26008 => array('PDF417: Interner Fehler. Modus wurde nicht in der Modusliste!! Modus %d',1),
+26009 => array('PDF417: Kodierfehler: Ungültiges Zeichen. Zeichen kann nicht mit ASCII-Code %d kodiert werden.',1),
+26010 => array('PDF417: Interner Fehler: Keine Eingabedaten beim Dekodieren.',0),
+26011 => array('PDF417: Kodierfehler. Numerisches Kodieren bei nicht-numerischen Daten nicht möglich.',0),
+26012 => array('PDF417: Interner Fehler. Es wurden für den Binary-Kompressor keine Daten zum Dekodieren eingegeben.',0),
+26013 => array('PDF417: Interner Fehler. Checksum Fehler. Koeffiziententabellen sind fehlerhaft.',0),
+26014 => array('PDF417: Interner Fehler. Es wurden keine Daten zum Berechnen von Kodewörtern eingegeben.',0),
+26015 => array('PDF417: Interner Fehler. Ein Eintrag 0 in die Statusübertragungstabellen ist nicht NULL. Eintrag 1 = (%s)',1),
+26016 => array('PDF417: Interner Fehler: Nichtregistrierter Statusübertragungsmodus beim Dekodieren.',0),
+
+
+/*
+** jpgraph_contour
+*/
+
+28001 => array('Dritten parameter fur Contour muss ein vector der fargen sind.',0),
+28002 => array('Die anzahlen der farges jeder isobar linien muss gleich sein.',0),
+28003 => array('ContourPlot Interner Fehler: isobarHCrossing: Spalten index ist zu hoch (%d)',1),
+28004 => array('ContourPlot Interner Fehler: isobarHCrossing: Reihe index ist zu hoch (%d)',1),
+28005 => array('ContourPlot Interner Fehler: isobarVCrossing: Reihe index ist zu hoch (%d)',1),
+28006 => array('ContourPlot Interner Fehler: isobarVCrossing: Spalten index ist zu hoch (%d)',1),
+28007 => array('ContourPlot. Interpolation faktor ist zu hoch (>5)',0),
+
+
+/*
+ * jpgraph_matrix and colormap
+*/
+29201 => array('Min range value must be less or equal to max range value for colormaps',0),
+29202 => array('The distance between min and max value is too small for numerical precision',0),
+29203 => array('Number of color quantification level must be at least %d',1),
+29204 => array('Number of colors (%d) is invalid for this colormap. It must be a number that can be written as: %d + k*%d',3),
+29205 => array('Colormap specification out of range. Must be an integer in range [0,%d]',1),
+29206 => array('Invalid object added to MatrixGraph',0),
+29207 => array('Empty input data specified for MatrixPlot',0),
+29208 => array('Unknown side specifiction for matrix labels "%s"',1),
+29209 => array('CSIM Target matrix must be the same size as the data matrix (csim=%d x %d, data=%d x %d)',4),
+29210 => array('CSIM Target for matrix labels does not match the number of labels (csim=%d, labels=%d)',2),
+
+
+/*
+* jpgraph_theme
+*/
+30001 => array("Theme::%s() is not defined. \nPlease make %s(\$graph) function in your theme classs.",2),
+
+
+);
+
+?>
diff --git a/web/classes/jpgraph/lang/en.inc.php b/web/classes/jpgraph/lang/en.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..101e8bd8292d7b0313e65f4a9aa2cc8f60eb7bff
--- /dev/null
+++ b/web/classes/jpgraph/lang/en.inc.php
@@ -0,0 +1,545 @@
+<?php
+/*=======================================================================
+// File:     EN.INC.PHP
+// Description: English language file for error messages
+// Created:     2006-01-25
+// Ver:        $Id: en.inc.php 1886 2009-10-01 23:30:16Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+*/
+
+// Note: Format of each error message is array(<error message>,<number of arguments>)
+$_jpg_messages = array(
+
+/*
+** Headers already sent error. This is formatted as HTML different since this will be sent back directly as text
+*/
+10  => array('<table border="1"><tr><td style="color:darkred; font-size:1.2em;"><b>JpGraph Error:</b>
+HTTP headers have already been sent.<br>Caused by output from file <b>%s</b> at line <b>%d</b>.</td></tr><tr><td><b>Explanation:</b><br>HTTP headers have already been sent back to the browser indicating the data as text before the library got a chance to send it\'s image HTTP header to this browser. This makes it impossible for the library to send back image data to the browser (since that would be interpretated as text by the browser and show up as junk text).<p>Most likely you have some text in your script before the call to <i>Graph::Stroke()</i>. If this texts gets sent back to the browser the browser will assume that all data is plain text. Look for any text, even spaces and newlines, that might have been sent back to the browser. <p>For example it is a common mistake to leave a blank line before the opening "<b>&lt;?php</b>".</td></tr></table>',2),
+
+/*
+** Setup errors
+*/
+11 => array('No path specified for CACHE_DIR. Please specify CACHE_DIR manually in jpg-config.inc',0),
+12 => array('No path specified for TTF_DIR and path can not be determined automatically. Please specify TTF_DIR manually (in jpg-config.inc).',0),
+13 => array('The installed PHP version (%s) is not compatible with this release of the library. The library requires at least PHP version %s',2),
+
+
+/*
+**  jpgraph_bar
+*/
+
+2001 => array('Number of colors is not the same as the number of patterns in BarPlot::SetPattern()',0),
+2002 => array('Unknown pattern specified in call to BarPlot::SetPattern()',0),
+2003 => array('Number of X and Y points are not equal. Number of X-points: %d Number of Y-points: %d',2),
+2004 => array('All values for a barplot must be numeric. You have specified value nr [%d] == %s',2),
+2005 => array('You have specified an empty array for shadow colors in the bar plot.',0),
+2006 => array('Unknown position for values on bars : %s',1),
+2007 => array('Cannot create GroupBarPlot from empty plot array.',0),
+2008 => array('Group bar plot element nbr %d is undefined or empty.',0),
+2009 => array('One of the objects submitted to GroupBar is not a BarPlot. Make sure that you create the GroupBar plot from an array of BarPlot or AccBarPlot objects. (Class = %s)',1),
+2010 => array('Cannot create AccBarPlot from empty plot array.',0),
+2011 => array('Acc bar plot element nbr %d is undefined or empty.',1),
+2012 => array('One of the objects submitted to AccBar is not a BarPlot. Make sure that you create the AccBar plot from an array of BarPlot objects. (Class=%s)',1),
+2013 => array('You have specified an empty array for shadow colors in the bar plot.',0),
+2014 => array('Number of datapoints for each data set in accbarplot must be the same',0),
+2015 => array('Individual bar plots in an AccBarPlot or GroupBarPlot can not have specified X-coordinates',0),
+
+
+/*
+**  jpgraph_date
+*/
+
+3001 => array('It is only possible to use either SetDateAlign() or SetTimeAlign() but not both',0),
+
+/*
+**  jpgraph_error
+*/
+
+4002 => array('Error in input data to LineErrorPlot. Number of data points must be a multiple of 3',0),
+
+/*
+**  jpgraph_flags
+*/
+
+5001 => array('Unknown flag size (%d).',1),
+5002 => array('Flag index %s does not exist.',1),
+5003 => array('Invalid ordinal number (%d) specified for flag index.',1),
+5004 => array('The (partial) country name %s does not have a corresponding flag image. The flag may still exist but under another name, e.g. instead of "usa" try "united states".',1),
+
+
+/*
+**  jpgraph_gantt
+*/
+
+6001 => array('Internal error. Height for ActivityTitles is < 0',0),
+6002 => array('You can\'t specify negative sizes for Gantt graph dimensions. Use 0 to indicate that you want the library to automatically determine a dimension.',0),
+6003 => array('Invalid format for Constrain parameter at index=%d in CreateSimple(). Parameter must start with index 0 and contain arrays of (Row,Constrain-To,Constrain-Type)',1),
+6004 => array('Invalid format for Progress parameter at index=%d in CreateSimple(). Parameter must start with index 0 and contain arrays of (Row,Progress)',1),
+6005 => array('SetScale() is not meaningful with Gantt charts.',0),
+6006 => array('Cannot autoscale Gantt chart. No dated activities exist. [GetBarMinMax() start >= n]',0),
+6007 => array('Sanity check for automatic Gantt chart size failed. Either the width (=%d) or height (=%d) is larger than MAX_GANTTIMG_SIZE. This could potentially be caused by a wrong date in one of the activities.',2),
+6008 => array('You have specified a constrain from row=%d to row=%d which does not have any activity',2),
+6009 => array('Unknown constrain type specified from row=%d to row=%d',2),
+6010 => array('Illegal icon index for Gantt builtin icon [%d]',1),
+6011 => array('Argument to IconImage must be string or integer',0),
+6012 => array('Unknown type in Gantt object title specification',0),
+6015 => array('Illegal vertical position %d',1),
+6016 => array('Date string (%s) specified for Gantt activity can not be interpretated. Please make sure it is a valid time string, e.g. 2005-04-23 13:30',1),
+6017 => array('Unknown date format in GanttScale (%s).',1),
+6018 => array('Interval for minutes must divide the hour evenly, e.g. 1,5,10,12,15,20,30 etc You have specified an interval of %d minutes.',1),
+6019 => array('The available width (%d) for minutes are to small for this scale to be displayed. Please use auto-sizing or increase the width of the graph.',1),
+6020 => array('Interval for hours must divide the day evenly, e.g. 0:30, 1:00, 1:30, 4:00 etc. You have specified an interval of %d',1),
+6021 => array('Unknown formatting style for week.',0),
+6022 => array('Gantt scale has not been specified.',0),
+6023 => array('If you display both hour and minutes the hour interval must be 1 (Otherwise it doesn\'t make sense to display minutes).',0),
+6024 => array('CSIM Target must be specified as a string. Start of target is: %d',1),
+6025 => array('CSIM Alt text must be specified as a string. Start of alt text is: %d',1),
+6027 => array('Progress value must in range [0, 1]',0),
+6028 => array('Specified height (%d) for gantt bar is out of range.',1),
+6029 => array('Offset for vertical line must be in range [0,1]',0),
+6030 => array('Unknown arrow direction for link.',0),
+6031 => array('Unknown arrow type for link.',0),
+6032 => array('Internal error: Unknown path type (=%d) specified for link.',1),
+6033 => array('Array of fonts must contain arrays with 3 elements, i.e. (Family, Style, Size)',0),
+
+/*
+**  jpgraph_gradient
+*/
+
+7001 => array('Unknown gradient style (=%d).',1),
+
+/*
+**  jpgraph_iconplot
+*/
+
+8001 => array('Mix value for icon must be between 0 and 100.',0),
+8002 => array('Anchor position for icons must be one of "top", "bottom", "left", "right" or "center"',0),
+8003 => array('It is not possible to specify both an image file and a country flag for the same icon.',0),
+8004 => array('In order to use Country flags as icons you must include the "jpgraph_flags.php" file.',0),
+
+/*
+**  jpgraph_imgtrans
+*/
+
+9001 => array('Value for image transformation out of bounds. Vanishing point on horizon must be specified as a value between 0 and 1.',0),
+
+/*
+**  jpgraph_lineplot
+*/
+
+10001 => array('LinePlot::SetFilled() is deprecated. Use SetFillColor()',0),
+10002 => array('Plot too complicated for fast line Stroke. Use standard Stroke()',0),
+10003 => array('Each plot in an accumulated lineplot must have the same number of data points.',0),
+
+/*
+**  jpgraph_log
+*/
+
+11001 => array('Your data contains non-numeric values.',0),
+11002 => array('Negative data values can not be used in a log scale.',0),
+11003 => array('Your data contains non-numeric values.',0),
+11004 => array('Scale error for logarithmic scale. You have a problem with your data values. The max value must be greater than 0. It is mathematically impossible to have 0 in a logarithmic scale.',0),
+11005 => array('Specifying tick interval for a logarithmic scale is undefined. Remove any calls to SetTextLabelStart() or SetTextTickInterval() on the logarithmic scale.',0),
+
+/*
+**  jpgraph_mgraph
+*/
+
+12001 => array("You are using GD 2.x and are trying to use a background images on a non truecolor image. To use background images with GD 2.x it is necessary to enable truecolor by setting the USE_TRUECOLOR constant to TRUE. Due to a bug in GD 2.0.1 using any truetype fonts with truecolor images will result in very poor quality fonts.",0),
+12002 => array('Incorrect file name for MGraph::SetBackgroundImage() : %s Must have a valid image extension (jpg,gif,png) when using auto detection of image type',1),
+12003 => array('Unknown file extension (%s) in MGraph::SetBackgroundImage() for filename: %s',2),
+12004 => array('The image format of your background image (%s) is not supported in your system configuration. ',1),
+12005 => array('Can\'t read background image: %s',1),
+12006 => array('Illegal sizes specified for width or height when creating an image, (width=%d, height=%d)',2),
+12007 => array('Argument to MGraph::Add() is not a valid GD image handle.',0),
+12008 => array('Your PHP (and GD-lib) installation does not appear to support any known graphic formats.',0),
+12009 => array('Your PHP installation does not support the chosen graphic format: %s',1),
+12010 => array('Can\'t create or stream image to file %s Check that PHP has enough permission to write a file to the current directory.',1),
+12011 => array('Can\'t create truecolor image. Check that you really have GD2 library installed.',0),
+12012 => array('Can\'t create image. Check that you really have GD2 library installed.',0),
+
+/*
+**  jpgraph_pie3d
+*/
+
+14001 => array('Pie3D::ShowBorder() . Deprecated function. Use Pie3D::SetEdge() to control the edges around slices.',0),
+14002 => array('PiePlot3D::SetAngle() 3D Pie projection angle must be between 5 and 85 degrees.',0),
+14003 => array('Internal assertion failed. Pie3D::Pie3DSlice',0),
+14004 => array('Slice start angle must be between 0 and 360 degrees.',0),
+14005 => array('Pie3D Internal error: Trying to wrap twice when looking for start index',0,),
+14006 => array('Pie3D Internal Error: Z-Sorting algorithm for 3D Pies is not working properly (2). Trying to wrap twice while stroking.',0),
+14007 => array('Width for 3D Pie is 0. Specify a size > 0',0),
+
+/*
+**  jpgraph_pie
+*/
+
+15001 => array('PiePLot::SetTheme() Unknown theme: %s',1),
+15002 => array('Argument to PiePlot::ExplodeSlice() must be an integer',0),
+15003 => array('Argument to PiePlot::Explode() must be an array with integer distances.',0),
+15004 => array('Slice start angle must be between 0 and 360 degrees.',0),
+15005 => array('PiePlot::SetFont() is deprecated. Use PiePlot->value->SetFont() instead.',0),
+15006 => array('PiePlot::SetSize() Radius for pie must either be specified as a fraction [0, 0.5] of the size of the image or as an absolute size in pixels  in the range [10, 1000]',0),
+15007 => array('PiePlot::SetFontColor() is deprecated. Use PiePlot->value->SetColor() instead.',0),
+15008 => array('PiePlot::SetLabelType() Type for pie plots must be 0 or 1 (not %d).',1),
+15009 => array('Illegal pie plot. Sum of all data is zero for Pie Plot',0),
+15010 => array('Sum of all data is 0 for Pie.',0),
+15011 => array('In order to use image transformation you must include the file jpgraph_imgtrans.php in your script.',0),
+15012 => array('PiePlot::SetTheme() is no longer supported. Use PieGraph::SetTheme()',0),
+
+/*
+**  jpgraph_plotband
+*/
+
+16001 => array('Density for pattern must be between 1 and 100. (You tried %f)',1),
+16002 => array('No positions specified for pattern.',0),
+16003 => array('Unknown pattern specification (%d)',0),
+16004 => array('Min value for plotband is larger than specified max value. Please correct.',0),
+
+
+/*
+**  jpgraph_polar
+*/
+
+17001 => array('Polar plots must have an even number of data point. Each data point is a tuple (angle,radius).',0),
+17002 => array('Unknown alignment specified for X-axis title. (%s)',1),
+//17003 => array('Set90AndMargin() is not supported for polar graphs.',0),
+17004 => array('Unknown scale type for polar graph. Must be "lin" or "log"',0),
+
+/*
+**  jpgraph_radar
+*/
+
+18001 => array('Client side image maps not supported for RadarPlots.',0),
+18002 => array('RadarGraph::SupressTickMarks() is deprecated. Use HideTickMarks() instead.',0),
+18003 => array('Illegal scale for radarplot (%s). Must be \'lin\' or \'log\'',1),
+18004 => array('Radar Plot size must be between 0.1 and 1. (Your value=%f)',1),
+18005 => array('RadarPlot Unsupported Tick density: %d',1),
+18006 => array('Minimum data %f (Radar plots should only be used when all data points > 0)',1),
+18007 => array('Number of titles does not match number of points in plot.',0),
+18008 => array('Each radar plot must have the same number of data points.',0),
+
+/*
+**  jpgraph_regstat
+*/
+
+19001 => array('Spline: Number of X and Y coordinates must be the same',0),
+19002 => array('Invalid input data for spline. Two or more consecutive input X-values are equal. Each input X-value must differ since from a mathematical point of view it must be a one-to-one mapping, i.e. each X-value must correspond to exactly one Y-value.',0),
+19003 => array('Bezier: Number of X and Y coordinates must be the same',0),
+
+/*
+**  jpgraph_scatter
+*/
+
+20001 => array('Fieldplots must have equal number of X and Y points.',0),
+20002 => array('Fieldplots must have an angle specified for each X and Y points.',0),
+20003 => array('Scatterplot must have equal number of X and Y points.',0),
+
+/*
+**  jpgraph_stock
+*/
+
+21001 => array('Data values for Stock charts must contain an even multiple of %d data points.',1),
+
+/*
+**  jpgraph_plotmark
+*/
+
+23001 => array('This marker "%s" does not exist in color with index: %d',2),
+23002 => array('Mark color index too large for marker "%s"',1),
+23003 => array('A filename must be specified if you set the mark type to MARK_IMG.',0),
+
+/*
+**  jpgraph_utils
+*/
+
+24001 => array('FuncGenerator : No function specified. ',0),
+24002 => array('FuncGenerator : Syntax error in function specification ',0),
+24003 => array('DateScaleUtils: Unknown tick type specified in call to GetTicks()',0),
+24004 => array('ReadCSV2: Column count mismatch in %s line %d',2),
+/*
+**  jpgraph
+*/
+
+25001 => array('This PHP installation is not configured with the GD library. Please recompile PHP with GD support to run JpGraph. (Neither function imagetypes() nor imagecreatefromstring() does exist)',0),
+25002 => array('Your PHP installation does not seem to have the required GD library. Please see the PHP documentation on how to install and enable the GD library.',0),
+25003 => array('General PHP error : At %s:%d : %s',3),
+25004 => array('General PHP error : %s ',1),
+25005 => array('Can\'t access PHP_SELF, PHP global variable. You can\'t run PHP from command line if you want to use the \'auto\' naming of cache or image files.',0),
+25006 => array('Usage of FF_CHINESE (FF_BIG5) font family requires that your PHP setup has the iconv() function. By default this is not compiled into PHP (needs the "--width-iconv" when configured).',0),
+25007 => array('You are trying to use the locale (%s) which your PHP installation does not support. Hint: Use \'\' to indicate the default locale for this geographic region.',1),
+25008 => array('Image width/height argument in Graph::Graph() must be numeric',0),
+25009 => array('You must specify what scale to use with a call to Graph::SetScale()',0),
+
+25010 => array('Graph::Add() You tried to add a null plot to the graph.',0),
+25011 => array('Graph::AddY2() You tried to add a null plot to the graph.',0),
+25012 => array('Graph::AddYN() You tried to add a null plot to the graph.',0),
+25013 => array('You can only add standard plots to multiple Y-axis',0),
+25014 => array('Graph::AddText() You tried to add a null text to the graph.',0),
+25015 => array('Graph::AddLine() You tried to add a null line to the graph.',0),
+25016 => array('Graph::AddBand() You tried to add a null band to the graph.',0),
+25017 => array('You are using GD 2.x and are trying to use a background images on a non truecolor image. To use background images with GD 2.x it is necessary to enable truecolor by setting the USE_TRUECOLOR constant to TRUE. Due to a bug in GD 2.0.1 using any truetype fonts with truecolor images will result in very poor quality fonts.',0),
+25018 => array('Incorrect file name for Graph::SetBackgroundImage() : "%s" Must have a valid image extension (jpg,gif,png) when using auto detection of image type',1),
+25019 => array('Unknown file extension (%s) in Graph::SetBackgroundImage() for filename: "%s"',2),
+
+25020 => array('Graph::SetScale(): Specified Max value must be larger than the specified Min value.',0),
+25021 => array('Unknown scale specification for Y-scale. (%s)',1),
+25022 => array('Unknown scale specification for X-scale. (%s)',1),
+25023 => array('Unsupported Y2 axis type: "%s" Must be one of (lin,log,int)',1),
+25024 => array('Unsupported Y axis type:  "%s" Must be one of (lin,log,int)',1),
+25025 => array('Unsupported Tick density: %d',1),
+25026 => array('Can\'t draw unspecified Y-scale. You have either: 1. Specified an Y axis for auto scaling but have not supplied any plots. 2. Specified a scale manually but have forgot to specify the tick steps',0),
+25027 => array('Can\'t open cached CSIM "%s" for reading.',1),
+25028 => array('Apache/PHP does not have permission to write to the CSIM cache directory (%s). Check permissions.',1),
+25029 => array('Can\'t write CSIM "%s" for writing. Check free space and permissions.',1),
+
+25030 => array('Missing script name in call to StrokeCSIM(). You must specify the name of the actual image script as the first parameter to StrokeCSIM().',0),
+25031 => array('You must specify what scale to use with a call to Graph::SetScale().',0),
+25032 => array('No plots for Y-axis nbr:%d',1),
+25033 => array('',0),
+25034 => array('Can\'t draw unspecified X-scale. No plots specified.',0),
+25035 => array('You have enabled clipping. Clipping is only supported for graphs at 0 or 90 degrees rotation. Please adjust you current angle (=%d degrees) or disable clipping.',1),
+25036 => array('Unknown AxisStyle() : %s',1),
+25037 => array('The image format of your background image (%s) is not supported in your system configuration. ',1),
+25038 => array('Background image seems to be of different type (has different file extension) than specified imagetype. Specified: %s File: %s',2),
+25039 => array('Can\'t read background image: "%s"',1),
+
+25040 => array('It is not possible to specify both a background image and a background country flag.',0),
+25041 => array('In order to use Country flags as backgrounds you must include the "jpgraph_flags.php" file.',0),
+25042 => array('Unknown background image layout',0),
+25043 => array('Unknown title background style.',0),
+25044 => array('Cannot use auto scaling since it is impossible to determine a valid min/max value of the Y-axis (only null values).',0),
+25045 => array('Font families FF_HANDWRT and FF_BOOK are no longer available due to copyright problem with these fonts. Fonts can no longer be distributed with JpGraph. Please download fonts from http://corefonts.sourceforge.net/',0),
+25046 => array('Specified TTF font family (id=%d) is unknown or does not exist. Please note that TTF fonts are not distributed with JpGraph for copyright reasons. You can find the MS TTF WEB-fonts (arial, courier etc) for download at http://corefonts.sourceforge.net/',1),
+25047 => array('Style %s is not available for font family %s',2),
+25048 => array('Unknown font style specification [%s].',1),
+25049 => array('Font file "%s" is not readable or does not exist.',1),
+
+25050 => array('First argument to Text::Text() must be a string.',0),
+25051 => array('Invalid direction specified for text.',0),
+25052 => array('PANIC: Internal error in SuperScript::Stroke(). Unknown vertical alignment for text',0),
+25053 => array('PANIC: Internal error in SuperScript::Stroke(). Unknown horizontal alignment for text',0),
+25054 => array('Internal error: Unknown grid axis %s',1),
+25055 => array('Axis::SetTickDirection() is deprecated. Use Axis::SetTickSide() instead',0),
+25056 => array('SetTickLabelMargin() is deprecated. Use Axis::SetLabelMargin() instead.',0),
+25057 => array('SetTextTicks() is deprecated. Use SetTextTickInterval() instead.',0),
+25058 => array('Text label interval must be specified >= 1.',0),
+25059 => array('SetLabelPos() is deprecated. Use Axis::SetLabelSide() instead.',0),
+
+25060 => array('Unknown alignment specified for X-axis title. (%s)',1),
+25061 => array('Unknown alignment specified for Y-axis title. (%s)',1),
+25062 => array('Labels at an angle are not supported on Y-axis',0),
+25063 => array('Ticks::SetPrecision() is deprecated. Use Ticks::SetLabelFormat() (or Ticks::SetFormatCallback()) instead',0),
+25064 => array('Minor or major step size is 0. Check that you haven\'t got an accidental SetTextTicks(0) in your code. If this is not the case you might have stumbled upon a bug in JpGraph. Please report this and if possible include the data that caused the problem',0),
+25065 => array('Tick positions must be specified as an array()',0),
+25066 => array('When manually specifying tick positions and labels the number of labels must be the same as the number of specified ticks.',0),
+25067 => array('Your manually specified scale and ticks is not correct. The scale seems to be too small to hold any of the specified tick marks.',0),
+25068 => array('A plot has an illegal scale. This could for example be that you are trying to use text auto scaling to draw a line plot with only one point or that the plot area is too small. It could also be that no input data value is numeric (perhaps only \'-\' or \'x\')',0),
+25069 => array('Grace must be larger then 0',0),
+25070 => array('Either X or Y data arrays contains non-numeric values. Check that the data is really specified as numeric data and not as strings. It is an error to specify data for example as \'-2345.2\' (using quotes).',0),
+25071 => array('You have specified a min value with SetAutoMin() which is larger than the maximum value used for the scale. This is not possible.',0),
+25072 => array('You have specified a max value with SetAutoMax() which is smaller than the minimum value used for the scale. This is not possible.',0),
+25073 => array('Internal error. Integer scale algorithm comparison out of bound (r=%f)',1),
+25074 => array('Internal error. The scale range is negative (%f) [for %s scale] This problem could potentially be caused by trying to use \"illegal\" values in the input data arrays (like trying to send in strings or only NULL values) which causes the auto scaling to fail.',2),
+25075 => array('Can\'t automatically determine ticks since min==max.',0),
+25077 => array('Adjustment factor for color must be > 0',0),
+25078 => array('Unknown color: %s',1),
+25079 => array('Unknown color specification: %s, size=%d',2),
+
+25080 => array('Alpha parameter for color must be between 0.0 and 1.0',0),
+25081 => array('Selected graphic format is either not supported or unknown [%s]',1),
+25082 => array('Illegal sizes specified for width or height when creating an image, (width=%d, height=%d)',2),
+25083 => array('Illegal image size when copying image. Size for copied to image is 1 pixel or less.',0),
+25084 => array('Failed to create temporary GD canvas. Possible Out of memory problem.',0),
+25085 => array('An image can not be created from the supplied string. It is either in a format not supported or the string is representing an corrupt image.',0),
+25086 => array('You only seem to have GD 1.x installed. To enable Alphablending requires GD 2.x or higher. Please install GD or make sure the constant USE_GD2 is specified correctly to reflect your installation. By default it tries to auto detect what version of GD you have installed. On some very rare occasions it may falsely detect GD2 where only GD1 is installed. You must then set USE_GD2 to false.',0),
+25087 => array('This PHP build has not been configured with TTF support. You need to recompile your PHP installation with FreeType support.',0),
+25088 => array('You have a misconfigured GD font support. The call to imagefontwidth() fails.',0),
+25089 => array('You have a misconfigured GD font support. The call to imagefontheight() fails.',0),
+
+25090 => array('Unknown direction specified in call to StrokeBoxedText() [%s]',1),
+25091 => array('Internal font does not support drawing text at arbitrary angle. Use TTF fonts instead.',0),
+25092 => array('There is either a configuration problem with TrueType or a problem reading font file "%s" Make sure file exists and is in a readable place for the HTTP process. (If \'basedir\' restriction is enabled in PHP then the font file must be located in the document root.). It might also be a wrongly installed FreeType library. Try upgrading to at least FreeType 2.1.13 and recompile GD with the correct setup so it can find the new FT library.',1),
+25093 => array('Can not read font file "%s" in call to Image::GetBBoxTTF. Please make sure that you have set a font before calling this method and that the font is installed in the TTF directory.',1),
+25094 => array('Direction for text most be given as an angle between 0 and 90.',0),
+25095 => array('Unknown font font family specification. ',0),
+25096 => array('Can\'t allocate any more colors in palette image. Image has already allocated maximum of %d colors and the palette  is now full. Change to a truecolor image instead',0),
+25097 => array('Color specified as empty string in PushColor().',0),
+25098 => array('Negative Color stack index. Unmatched call to PopColor()',0),
+25099 => array('Parameters for brightness and Contrast out of range [-1,1]',0),
+
+25100 => array('Problem with color palette and your GD setup. Please disable anti-aliasing or use GD2 with true-color. If you have GD2 library installed please make sure that you have set the USE_GD2 constant to true and truecolor is enabled.',0),
+25101 => array('Illegal numeric argument to SetLineStyle(): (%d)',1),
+25102 => array('Illegal string argument to SetLineStyle(): %s',1),
+25103 => array('Illegal argument to SetLineStyle %s',1),
+25104 => array('Unknown line style: %s',1),
+25105 => array('NULL data specified for a filled polygon. Check that your data is not NULL.',0),
+25106 => array('Image::FillToBorder : Can not allocate more colors',0),
+25107 => array('Can\'t write to file "%s". Check that the process running PHP has enough permission.',1),
+25108 => array('Can\'t stream image. This is most likely due to a faulty PHP/GD setup. Try to recompile PHP and use the built-in GD library that comes with PHP.',0),
+25109 => array('Your PHP (and GD-lib) installation does not appear to support any known graphic formats. You need to first make sure GD is compiled as a module to PHP. If you also want to use JPEG images you must get the JPEG library. Please see the PHP docs for details.',0),
+
+25110 => array('Your PHP installation does not support the chosen graphic format: %s',1),
+25111 => array('Can\'t delete cached image %s. Permission problem?',1),
+25112 => array('Cached imagefile (%s) has file date in the future.',1),
+25113 => array('Can\'t delete cached image "%s". Permission problem?',1),
+25114 => array('PHP has not enough permissions to write to the cache file "%s". Please make sure that the user running PHP has write permission for this file if you wan to use the cache system with JpGraph.',1),
+25115 => array('Can\'t set permission for cached image "%s". Permission problem?',1),
+25116 => array('Cant open file from cache "%s"',1),
+25117 => array('Can\'t open cached image "%s" for reading.',1),
+25118 => array('Can\'t create directory "%s". Make sure PHP has write permission to this directory.',1),
+25119 => array('Can\'t set permissions for "%s". Permission problems?',1),
+
+25120 => array('Position for legend must be given as percentage in range 0-1',0),
+25121 => array('Empty input data array specified for plot. Must have at least one data point.',0),
+25122 => array('Stroke() must be implemented by concrete subclass to class Plot',0),
+25123 => array('You can\'t use a text X-scale with specified X-coords. Use a "int" or "lin" scale instead.',0),
+25124 => array('The input data array must have consecutive values from position 0 and forward. The given y-array starts with empty values (NULL)',0),
+25125 => array('Illegal direction for static line',0),
+25126 => array('Can\'t create truecolor image. Check that the GD2 library is properly setup with PHP.',0),
+25127 => array('The library has been configured for automatic encoding conversion of Japanese fonts. This requires that PHP has the mb_convert_encoding() function. Your PHP installation lacks this function (PHP needs the "--enable-mbstring" when compiled).',0),
+25128 => array('The function imageantialias() is not available in your PHP installation. Use the GD version that comes with PHP and not the standalone version.',0),
+25129 => array('Anti-alias can not be used with dashed lines. Please disable anti-alias or use solid lines.',0),
+25130 => array('Too small plot area. (%d x %d). With the given image size and margins there is to little space left for the plot. Increase the plot size or reduce the margins.',2),
+
+25131 => array('StrokeBoxedText2() only supports TTF fonts and not built-in bitmap fonts.',0),
+25132 => array('Undefined property %s.',1),
+25133 => array('Use Graph::SetTheme() after Graph::SetScale().',0),
+
+/*
+**  jpgraph_led
+*/
+
+25500 => array('Multibyte strings must be enabled in the PHP installation in order to run the LED module so that the function mb_strlen() is available. See PHP documentation for more information.',0),
+
+/*
+**---------------------------------------------------------------------------------------------
+** Pro-version strings
+**---------------------------------------------------------------------------------------------
+*/
+
+/*
+**  jpgraph_table
+*/
+
+27001 => array('GTextTable: Invalid argument to Set(). Array argument must be 2 dimensional',0),
+27002 => array('GTextTable: Invalid argument to Set()',0),
+27003 => array('GTextTable: Wrong number of arguments to GTextTable::SetColor()',0),
+27004 => array('GTextTable: Specified cell range to be merged is not valid.',0),
+27005 => array('GTextTable: Cannot merge already merged cells in the range: (%d,%d) to (%d,%d)',4),
+27006 => array('GTextTable: Column argument = %d is outside specified table size.',1),
+27007 => array('GTextTable: Row argument = %d is outside specified table size.',1),
+27008 => array('GTextTable: Column and row size arrays must match the dimensions of the table',0),
+27009 => array('GTextTable: Number of table columns or rows are 0. Make sure Init() or Set() is called.',0),
+27010 => array('GTextTable: No alignment specified in call to SetAlign()',0),
+27011 => array('GTextTable: Unknown alignment specified in SetAlign(). Horizontal=%s, Vertical=%s',2),
+27012 => array('GTextTable: Internal error. Invalid alignment specified =%s',1),
+27013 => array('GTextTable: Argument to FormatNumber() must be a string.',0),
+27014 => array('GTextTable: Table is not initilaized with either a call to Set() or Init()',0),
+27015 => array('GTextTable: Cell image constrain type must be TIMG_WIDTH or TIMG_HEIGHT',0),
+
+/*
+**  jpgraph_windrose
+*/
+
+22001 => array('Total percentage for all windrose legs in a windrose plot can not exceed 100%% !\n(Current max is: %d)',1),
+22002 => array('Graph is too small to have a scale. Please make the graph larger.',0),
+22004 => array('Label specification for windrose directions must have 16 values (one for each compass direction).',0),
+22005 => array('Line style for radial lines must be on of ("solid","dotted","dashed","longdashed") ',0),
+22006 => array('Illegal windrose type specified.',0),
+22007 => array('To few values for the range legend.',0),
+22008 => array('Internal error: Trying to plot free Windrose even though type is not a free windrose',0),
+22009 => array('You have specified the same direction twice, once with an angle and once with a compass direction (%f degrees)',0),
+22010 => array('Direction must either be a numeric value or one of the 16 compass directions',0),
+22011 => array('Windrose index must be numeric or direction label. You have specified index=%d',1),
+22012 => array('Windrose radial axis specification contains a direction which is not enabled.',0),
+22013 => array('You have specified the look&feel for the same compass direction twice, once with text and once with index (Index=%d)',1),
+22014 => array('Index for compass direction must be between 0 and 15.',0),
+22015 => array('You have specified an undefined Windrose plot type.',0),
+22016 => array('Windrose leg index must be numeric or direction label.',0),
+22017 => array('Windrose data contains a direction which is not enabled. Please adjust what labels are displayed.',0),
+22018 => array('You have specified data for the same compass direction twice, once with text and once with index (Index=%d)',1),
+22019 => array('Index for direction must be between 0 and 15. You can\'t specify angles for a Regular Windplot, only index and compass directions.',0),
+22020 => array('Windrose plot is too large to fit the specified Graph size. Please use WindrosePlot::SetSize() to make the plot smaller or increase the size of the Graph in the initial WindroseGraph() call.',0),
+22021 => array('It is only possible to add Text, IconPlot or WindrosePlot to a Windrose Graph',0),
+/*
+**  jpgraph_odometer
+*/
+
+13001 => array('Unknown needle style (%d).',1),
+13002 => array('Value for odometer (%f) is outside specified scale [%f,%f]',3),
+
+/*
+**  jpgraph_barcode
+*/
+
+1001 => array('Unknown encoder specification: %s',1),
+1002 => array('Data validation failed. Can\'t encode [%s] using encoding "%s"',2),
+1003 => array('Internal encoding error. Trying to encode %s is not possible in Code 128',1),
+1004 => array('Internal barcode error. Unknown UPC-E encoding type: %s',1),
+1005 => array('Internal error. Can\'t encode character tuple (%s, %s) in Code-128 charset C',2),
+1006 => array('Internal encoding error for CODE 128. Trying to encode control character in CHARSET != A',0),
+1007 => array('Internal encoding error for CODE 128. Trying to encode DEL in CHARSET != B',0),
+1008 => array('Internal encoding error for CODE 128. Trying to encode small letters in CHARSET != B',0),
+1009 => array('Encoding using CODE 93 is not yet supported.',0),
+1010 => array('Encoding using POSTNET is not yet supported.',0),
+1011 => array('Non supported barcode backend for type %s',1),
+
+/*
+** PDF417
+*/
+26000 => array('PDF417: The PDF417 module requires that the PHP installation must support the function bcmod(). This is normally enabled at compile time. See documentation for more information.',0),
+26001 => array('PDF417: Number of Columns must be >= 1 and <= 30',0),
+26002 => array('PDF417: Error level must be between 0 and 8',0),
+26003 => array('PDF417: Invalid format for input data to encode with PDF417',0),
+26004 => array('PDF417: Can\'t encode given data with error level %d and %d columns since it results in too many symbols or more than 90 rows.',2),
+26005 => array('PDF417: Can\'t open file "%s" for writing',1),
+26006 => array('PDF417: Internal error. Data files for PDF417 cluster %d is corrupted.',1),
+26007 => array('PDF417: Internal error. GetPattern: Illegal Code Value = %d (row=%d)',2),
+26008 => array('PDF417: Internal error. Mode not found in mode list!! mode=%d',1),
+26009 => array('PDF417: Encode error: Illegal character. Can\'t encode character with ASCII code=%d',1),
+26010 => array('PDF417: Internal error: No input data in decode.',0),
+26011 => array('PDF417: Encoding error. Can\'t use numeric encoding on non-numeric data.',0),
+26012 => array('PDF417: Internal error. No input data to decode for Binary compressor.',0),
+26013 => array('PDF417: Internal error. Checksum error. Coefficient tables corrupted.',0),
+26014 => array('PDF417: Internal error. No data to calculate codewords on.',0),
+26015 => array('PDF417: Internal error. State transition table entry 0 is NULL. Entry 1 = (%s)',1),
+26016 => array('PDF417: Internal error: Unrecognized state transition mode in decode.',0),
+
+/*
+** jpgraph_contour
+*/
+
+28001 => array('Third argument to Contour must be an array of colors.',0),
+28002 => array('Number of colors must equal the number of isobar lines specified',0),
+28003 => array('ContourPlot Internal Error: isobarHCrossing: Coloumn index too large (%d)',1),
+28004 => array('ContourPlot Internal Error: isobarHCrossing: Row index too large (%d)',1),
+28005 => array('ContourPlot Internal Error: isobarVCrossing: Row index too large (%d)',1),
+28006 => array('ContourPlot Internal Error: isobarVCrossing: Col index too large (%d)',1),
+28007 => array('ContourPlot interpolation factor is too large (>5)',0),
+
+/*
+ * jpgraph_matrix and colormap
+*/
+29201 => array('Min range value must be less or equal to max range value for colormaps',0),
+29202 => array('The distance between min and max value is too small for numerical precision',0),
+29203 => array('Number of color quantification level must be at least %d',1),
+29204 => array('Number of colors (%d) is invalid for this colormap. It must be a number that can be written as: %d + k*%d',3),
+29205 => array('Colormap specification out of range. Must be an integer in range [0,%d]',1),
+29206 => array('Invalid object added to MatrixGraph',0),
+29207 => array('Empty input data specified for MatrixPlot',0),
+29208 => array('Unknown side specifiction for matrix labels "%s"',1),
+29209 => array('CSIM Target matrix must be the same size as the data matrix (csim=%d x %d, data=%d x %d)',4),
+29210 => array('CSIM Target for matrix labels does not match the number of labels (csim=%d, labels=%d)',2),
+
+
+/*
+* jpgraph_theme
+*/
+30001 => array("Theme::%s() is not defined. \nPlease make %s(\$graph) function in your theme classs.",2),
+
+);
+
+?>
diff --git a/web/classes/jpgraph/lang/prod.inc.php b/web/classes/jpgraph/lang/prod.inc.php
new file mode 100755
index 0000000000000000000000000000000000000000..c34c2b3bca231eb03d49249de3a67f3f133c9455
--- /dev/null
+++ b/web/classes/jpgraph/lang/prod.inc.php
@@ -0,0 +1,386 @@
+<?php
+/*=======================================================================
+// File: 	PROD.INC.PHP
+// Description: Special localization file with the same error messages
+//              for all errors.
+// Created: 	2006-02-18
+// Ver:		$Id: prod.inc.php 1886 2009-10-01 23:30:16Z ljp $
+//
+// Copyright (c) Asial Corporation. All rights reserved.
+//========================================================================
+*/
+
+// The single error message for all errors
+DEFINE('DEFAULT_ERROR_MESSAGE','We are sorry but the system could not generate the requested image. Please contact site support to resolve this problem. Problem no: #');
+
+// Note: Format of each error message is array(<error message>,<number of arguments>)
+$_jpg_messages = array(
+
+/*
+** Headers already sent error. This is formatted as HTML different since this will be sent back directly as text
+*/
+10  => array('<table border=1><tr><td><font color=darkred size=4><b>JpGraph Error:</b>
+HTTP headers have already been sent.<br>Caused by output from file <b>%s</b> at line <b>%d</b>.</font></td></tr><tr><td><b>Explanation:</b><br>HTTP headers have already been sent back to the browser indicating the data as text before the library got a chance to send it\'s image HTTP header to this browser. This makes it impossible for the library to send back image data to the browser (since that would be interpretated as text by the browser and show up as junk text).<p>Most likely you have some text in your script before the call to <i>Graph::Stroke()</i>. If this texts gets sent back to the browser the browser will assume that all data is plain text. Look for any text, even spaces and newlines, that might have been sent back to the browser. <p>For example it is a common mistake to leave a blank line before the opening "<b>&lt;?php</b>".</td></tr></table>',2),
+
+
+11 => array(DEFAULT_ERROR_MESSAGE.'11',0),
+12 => array(DEFAULT_ERROR_MESSAGE.'12',0),
+13 => array(DEFAULT_ERROR_MESSAGE.'13',0),
+2001 => array(DEFAULT_ERROR_MESSAGE.'2001',0),
+2002 => array(DEFAULT_ERROR_MESSAGE.'2002',0),
+2003 => array(DEFAULT_ERROR_MESSAGE.'2003',0),
+2004 => array(DEFAULT_ERROR_MESSAGE.'2004',0),
+2005 => array(DEFAULT_ERROR_MESSAGE.'2005',0),
+2006 => array(DEFAULT_ERROR_MESSAGE.'2006',0),
+2007 => array(DEFAULT_ERROR_MESSAGE.'2007',0),
+2008 => array(DEFAULT_ERROR_MESSAGE.'2008',0),
+2009 => array(DEFAULT_ERROR_MESSAGE.'2009',0),
+2010 => array(DEFAULT_ERROR_MESSAGE.'2010',0),
+2011 => array(DEFAULT_ERROR_MESSAGE.'2011',0),
+2012 => array(DEFAULT_ERROR_MESSAGE.'2012',0),
+2013 => array(DEFAULT_ERROR_MESSAGE.'2013',0),
+2014 => array(DEFAULT_ERROR_MESSAGE.'2014',0),
+3001 => array(DEFAULT_ERROR_MESSAGE.'3001',0),
+4002 => array(DEFAULT_ERROR_MESSAGE.'4002',0),
+5001 => array(DEFAULT_ERROR_MESSAGE.'5001',0),
+5002 => array(DEFAULT_ERROR_MESSAGE.'5002',0),
+5003 => array(DEFAULT_ERROR_MESSAGE.'5003',0),
+5004 => array(DEFAULT_ERROR_MESSAGE.'5004',0),
+6001 => array(DEFAULT_ERROR_MESSAGE.'6001',0),
+6002 => array(DEFAULT_ERROR_MESSAGE.'6002',0),
+6003 => array(DEFAULT_ERROR_MESSAGE.'6003',0),
+6004 => array(DEFAULT_ERROR_MESSAGE.'6004',0),
+6005 => array(DEFAULT_ERROR_MESSAGE.'6005',0),
+6006 => array(DEFAULT_ERROR_MESSAGE.'6006',0),
+6007 => array(DEFAULT_ERROR_MESSAGE.'6007',0),
+6008 => array(DEFAULT_ERROR_MESSAGE.'6008',0),
+6009 => array(DEFAULT_ERROR_MESSAGE.'6009',0),
+6010 => array(DEFAULT_ERROR_MESSAGE.'6010',0),
+6011 => array(DEFAULT_ERROR_MESSAGE.'6011',0),
+6012 => array(DEFAULT_ERROR_MESSAGE.'6012',0),
+6015 => array(DEFAULT_ERROR_MESSAGE.'6015',0),
+6016 => array(DEFAULT_ERROR_MESSAGE.'6016',0),
+6017 => array(DEFAULT_ERROR_MESSAGE.'6017',0),
+6018 => array(DEFAULT_ERROR_MESSAGE.'6018',0),
+6019 => array(DEFAULT_ERROR_MESSAGE.'6019',0),
+6020 => array(DEFAULT_ERROR_MESSAGE.'6020',0),
+6021 => array(DEFAULT_ERROR_MESSAGE.'6021',0),
+6022 => array(DEFAULT_ERROR_MESSAGE.'6022',0),
+6023 => array(DEFAULT_ERROR_MESSAGE.'6023',0),
+6024 => array(DEFAULT_ERROR_MESSAGE.'6024',0),
+6025 => array(DEFAULT_ERROR_MESSAGE.'6025',0),
+6027 => array(DEFAULT_ERROR_MESSAGE.'6027',0),
+6028 => array(DEFAULT_ERROR_MESSAGE.'6028',0),
+6029 => array(DEFAULT_ERROR_MESSAGE.'6029',0),
+6030 => array(DEFAULT_ERROR_MESSAGE.'6030',0),
+6031 => array(DEFAULT_ERROR_MESSAGE.'6031',0),
+6032 => array(DEFAULT_ERROR_MESSAGE.'6032',0),
+6033 => array(DEFAULT_ERROR_MESSAGE.'6033',0),
+7001 => array(DEFAULT_ERROR_MESSAGE.'7001',0),
+8001 => array(DEFAULT_ERROR_MESSAGE.'8001',0),
+8002 => array(DEFAULT_ERROR_MESSAGE.'8002',0),
+8003 => array(DEFAULT_ERROR_MESSAGE.'8003',0),
+8004 => array(DEFAULT_ERROR_MESSAGE.'8004',0),
+9001 => array(DEFAULT_ERROR_MESSAGE.'9001',0),
+10001 => array(DEFAULT_ERROR_MESSAGE.'10001',0),
+10002 => array(DEFAULT_ERROR_MESSAGE.'10002',0),
+10003 => array(DEFAULT_ERROR_MESSAGE.'10003',0),
+11001 => array(DEFAULT_ERROR_MESSAGE.'11001',0),
+11002 => array(DEFAULT_ERROR_MESSAGE.'11002',0),
+11003 => array(DEFAULT_ERROR_MESSAGE.'11003',0),
+11004 => array(DEFAULT_ERROR_MESSAGE.'11004',0),
+11005 => array(DEFAULT_ERROR_MESSAGE.'11005',0),
+12001 => array(DEFAULT_ERROR_MESSAGE.'12001',0),
+12002 => array(DEFAULT_ERROR_MESSAGE.'12002',0),
+12003 => array(DEFAULT_ERROR_MESSAGE.'12003',0),
+12004 => array(DEFAULT_ERROR_MESSAGE.'12004',0),
+12005 => array(DEFAULT_ERROR_MESSAGE.'12005',0),
+12006 => array(DEFAULT_ERROR_MESSAGE.'12006',0),
+12007 => array(DEFAULT_ERROR_MESSAGE.'12007',0),
+12008 => array(DEFAULT_ERROR_MESSAGE.'12008',0),
+12009 => array(DEFAULT_ERROR_MESSAGE.'12009',0),
+12010 => array(DEFAULT_ERROR_MESSAGE.'12010',0),
+12011 => array(DEFAULT_ERROR_MESSAGE.'12011',0),
+12012 => array(DEFAULT_ERROR_MESSAGE.'12012',0),
+14001 => array(DEFAULT_ERROR_MESSAGE.'14001',0),
+14002 => array(DEFAULT_ERROR_MESSAGE.'14002',0),
+14003 => array(DEFAULT_ERROR_MESSAGE.'14003',0),
+14004 => array(DEFAULT_ERROR_MESSAGE.'14004',0),
+14005 => array(DEFAULT_ERROR_MESSAGE.'14005',0),
+14006 => array(DEFAULT_ERROR_MESSAGE.'14006',0),
+14007 => array(DEFAULT_ERROR_MESSAGE.'14007',0),
+15001 => array(DEFAULT_ERROR_MESSAGE.'15001',0),
+15002 => array(DEFAULT_ERROR_MESSAGE.'15002',0),
+15003 => array(DEFAULT_ERROR_MESSAGE.'15003',0),
+15004 => array(DEFAULT_ERROR_MESSAGE.'15004',0),
+15005 => array(DEFAULT_ERROR_MESSAGE.'15005',0),
+15006 => array(DEFAULT_ERROR_MESSAGE.'15006',0),
+15007 => array(DEFAULT_ERROR_MESSAGE.'15007',0),
+15008 => array(DEFAULT_ERROR_MESSAGE.'15008',0),
+15009 => array(DEFAULT_ERROR_MESSAGE.'15009',0),
+15010 => array(DEFAULT_ERROR_MESSAGE.'15010',0),
+15011 => array(DEFAULT_ERROR_MESSAGE.'15011',0),
+15012 => array(DEFAULT_ERROR_MESSAGE.'15012',0),
+16001 => array(DEFAULT_ERROR_MESSAGE.'16001',0),
+16002 => array(DEFAULT_ERROR_MESSAGE.'16002',0),
+16003 => array(DEFAULT_ERROR_MESSAGE.'16003',0),
+16004 => array(DEFAULT_ERROR_MESSAGE.'16004',0),
+17001 => array(DEFAULT_ERROR_MESSAGE.'17001',0),
+17002 => array(DEFAULT_ERROR_MESSAGE.'17002',0),
+17004 => array(DEFAULT_ERROR_MESSAGE.'17004',0),
+18001 => array(DEFAULT_ERROR_MESSAGE.'18001',0),
+18002 => array(DEFAULT_ERROR_MESSAGE.'18002',0),
+18003 => array(DEFAULT_ERROR_MESSAGE.'18003',0),
+18004 => array(DEFAULT_ERROR_MESSAGE.'18004',0),
+18005 => array(DEFAULT_ERROR_MESSAGE.'18005',0),
+18006 => array(DEFAULT_ERROR_MESSAGE.'18006',0),
+18007 => array(DEFAULT_ERROR_MESSAGE.'18007',0),
+18008 => array(DEFAULT_ERROR_MESSAGE.'18008',0),
+19001 => array(DEFAULT_ERROR_MESSAGE.'19001',0),
+19002 => array(DEFAULT_ERROR_MESSAGE.'19002',0),
+19003 => array(DEFAULT_ERROR_MESSAGE.'19003',0),
+20001 => array(DEFAULT_ERROR_MESSAGE.'20001',0),
+20002 => array(DEFAULT_ERROR_MESSAGE.'20002',0),
+20003 => array(DEFAULT_ERROR_MESSAGE.'20003',0),
+21001 => array(DEFAULT_ERROR_MESSAGE.'21001',0),
+23001 => array(DEFAULT_ERROR_MESSAGE.'23001',0),
+23002 => array(DEFAULT_ERROR_MESSAGE.'23002',0),
+23003 => array(DEFAULT_ERROR_MESSAGE.'23003',0),
+24001 => array(DEFAULT_ERROR_MESSAGE.'24001',0),
+24002 => array(DEFAULT_ERROR_MESSAGE.'24002',0),
+24003 => array(DEFAULT_ERROR_MESSAGE.'24003',0),
+24004 => array(DEFAULT_ERROR_MESSAGE.'24004',0),
+25001 => array(DEFAULT_ERROR_MESSAGE.'25001',0),
+25002 => array(DEFAULT_ERROR_MESSAGE.'25002',0),
+25003 => array(DEFAULT_ERROR_MESSAGE.'25003',0),
+25004 => array(DEFAULT_ERROR_MESSAGE.'25004',0),
+25005 => array(DEFAULT_ERROR_MESSAGE.'25005',0),
+25006 => array(DEFAULT_ERROR_MESSAGE.'25006',0),
+25007 => array(DEFAULT_ERROR_MESSAGE.'25007',0),
+25008 => array(DEFAULT_ERROR_MESSAGE.'25008',0),
+25009 => array(DEFAULT_ERROR_MESSAGE.'25009',0),
+25010 => array(DEFAULT_ERROR_MESSAGE.'25010',0),
+25011 => array(DEFAULT_ERROR_MESSAGE.'25011',0),
+25012 => array(DEFAULT_ERROR_MESSAGE.'25012',0),
+25013 => array(DEFAULT_ERROR_MESSAGE.'25013',0),
+25014 => array(DEFAULT_ERROR_MESSAGE.'25014',0),
+25015 => array(DEFAULT_ERROR_MESSAGE.'25015',0),
+25016 => array(DEFAULT_ERROR_MESSAGE.'25016',0),
+25017 => array(DEFAULT_ERROR_MESSAGE.'25017',0),
+25018 => array(DEFAULT_ERROR_MESSAGE.'25018',0),
+25019 => array(DEFAULT_ERROR_MESSAGE.'25019',0),
+25020 => array(DEFAULT_ERROR_MESSAGE.'25020',0),
+25021 => array(DEFAULT_ERROR_MESSAGE.'25021',0),
+25022 => array(DEFAULT_ERROR_MESSAGE.'25022',0),
+25023 => array(DEFAULT_ERROR_MESSAGE.'25023',0),
+25024 => array(DEFAULT_ERROR_MESSAGE.'25024',0),
+25025 => array(DEFAULT_ERROR_MESSAGE.'25025',0),
+25026 => array(DEFAULT_ERROR_MESSAGE.'25026',0),
+25027 => array(DEFAULT_ERROR_MESSAGE.'25027',0),
+25028 => array(DEFAULT_ERROR_MESSAGE.'25028',0),
+25029 => array(DEFAULT_ERROR_MESSAGE.'25029',0),
+25030 => array(DEFAULT_ERROR_MESSAGE.'25030',0),
+25031 => array(DEFAULT_ERROR_MESSAGE.'25031',0),
+25032 => array(DEFAULT_ERROR_MESSAGE.'25032',0),
+25033 => array(DEFAULT_ERROR_MESSAGE.'25033',0),
+25034 => array(DEFAULT_ERROR_MESSAGE.'25034',0),
+25035 => array(DEFAULT_ERROR_MESSAGE.'25035',0),
+25036 => array(DEFAULT_ERROR_MESSAGE.'25036',0),
+25037 => array(DEFAULT_ERROR_MESSAGE.'25037',0),
+25038 => array(DEFAULT_ERROR_MESSAGE.'25038',0),
+25039 => array(DEFAULT_ERROR_MESSAGE.'25039',0),
+25040 => array(DEFAULT_ERROR_MESSAGE.'25040',0),
+25041 => array(DEFAULT_ERROR_MESSAGE.'25041',0),
+25042 => array(DEFAULT_ERROR_MESSAGE.'25042',0),
+25043 => array(DEFAULT_ERROR_MESSAGE.'25043',0),
+25044 => array(DEFAULT_ERROR_MESSAGE.'25044',0),
+25045 => array(DEFAULT_ERROR_MESSAGE.'25045',0),
+25046 => array(DEFAULT_ERROR_MESSAGE.'25046',0),
+25047 => array(DEFAULT_ERROR_MESSAGE.'25047',0),
+25048 => array(DEFAULT_ERROR_MESSAGE.'25048',0),
+25049 => array(DEFAULT_ERROR_MESSAGE.'25049',0),
+25050 => array(DEFAULT_ERROR_MESSAGE.'25050',0),
+25051 => array(DEFAULT_ERROR_MESSAGE.'25051',0),
+25052 => array(DEFAULT_ERROR_MESSAGE.'25052',0),
+25053 => array(DEFAULT_ERROR_MESSAGE.'25053',0),
+25054 => array(DEFAULT_ERROR_MESSAGE.'25054',0),
+25055 => array(DEFAULT_ERROR_MESSAGE.'25055',0),
+25056 => array(DEFAULT_ERROR_MESSAGE.'25056',0),
+25057 => array(DEFAULT_ERROR_MESSAGE.'25057',0),
+25058 => array(DEFAULT_ERROR_MESSAGE.'25058',0),
+25059 => array(DEFAULT_ERROR_MESSAGE.'25059',0),
+25060 => array(DEFAULT_ERROR_MESSAGE.'25060',0),
+25061 => array(DEFAULT_ERROR_MESSAGE.'25061',0),
+25062 => array(DEFAULT_ERROR_MESSAGE.'25062',0),
+25063 => array(DEFAULT_ERROR_MESSAGE.'25063',0),
+25064 => array(DEFAULT_ERROR_MESSAGE.'25064',0),
+25065 => array(DEFAULT_ERROR_MESSAGE.'25065',0),
+25066 => array(DEFAULT_ERROR_MESSAGE.'25066',0),
+25067 => array(DEFAULT_ERROR_MESSAGE.'25067',0),
+25068 => array(DEFAULT_ERROR_MESSAGE.'25068',0),
+25069 => array(DEFAULT_ERROR_MESSAGE.'25069',0),
+25070 => array(DEFAULT_ERROR_MESSAGE.'25070',0),
+25071 => array(DEFAULT_ERROR_MESSAGE.'25071',0),
+25072 => array(DEFAULT_ERROR_MESSAGE.'25072',0),
+25073 => array(DEFAULT_ERROR_MESSAGE.'25073',0),
+25074 => array(DEFAULT_ERROR_MESSAGE.'25074',0),
+25075 => array(DEFAULT_ERROR_MESSAGE.'25075',0),
+25077 => array(DEFAULT_ERROR_MESSAGE.'25077',0),
+25078 => array(DEFAULT_ERROR_MESSAGE.'25078',0),
+25079 => array(DEFAULT_ERROR_MESSAGE.'25079',0),
+25080 => array(DEFAULT_ERROR_MESSAGE.'25080',0),
+25081 => array(DEFAULT_ERROR_MESSAGE.'25081',0),
+25082 => array(DEFAULT_ERROR_MESSAGE.'25082',0),
+25083 => array(DEFAULT_ERROR_MESSAGE.'25083',0),
+25084 => array(DEFAULT_ERROR_MESSAGE.'25084',0),
+25085 => array(DEFAULT_ERROR_MESSAGE.'25085',0),
+25086 => array(DEFAULT_ERROR_MESSAGE.'25086',0),
+25087 => array(DEFAULT_ERROR_MESSAGE.'25087',0),
+25088 => array(DEFAULT_ERROR_MESSAGE.'25088',0),
+25089 => array(DEFAULT_ERROR_MESSAGE.'25089',0),
+25090 => array(DEFAULT_ERROR_MESSAGE.'25090',0),
+25091 => array(DEFAULT_ERROR_MESSAGE.'25091',0),
+25092 => array(DEFAULT_ERROR_MESSAGE.'25092',0),
+25093 => array(DEFAULT_ERROR_MESSAGE.'25093',0),
+25094 => array(DEFAULT_ERROR_MESSAGE.'25094',0),
+25095 => array(DEFAULT_ERROR_MESSAGE.'25095',0),
+25096 => array(DEFAULT_ERROR_MESSAGE.'25096',0),
+25097 => array(DEFAULT_ERROR_MESSAGE.'25097',0),
+25098 => array(DEFAULT_ERROR_MESSAGE.'25098',0),
+25099 => array(DEFAULT_ERROR_MESSAGE.'25099',0),
+25100 => array(DEFAULT_ERROR_MESSAGE.'25100',0),
+25101 => array(DEFAULT_ERROR_MESSAGE.'25101',0),
+25102 => array(DEFAULT_ERROR_MESSAGE.'25102',0),
+25103 => array(DEFAULT_ERROR_MESSAGE.'25103',0),
+25104 => array(DEFAULT_ERROR_MESSAGE.'25104',0),
+25105 => array(DEFAULT_ERROR_MESSAGE.'25105',0),
+25106 => array(DEFAULT_ERROR_MESSAGE.'25106',0),
+25107 => array(DEFAULT_ERROR_MESSAGE.'25107',0),
+25108 => array(DEFAULT_ERROR_MESSAGE.'25108',0),
+25109 => array(DEFAULT_ERROR_MESSAGE.'25109',0),
+25110 => array(DEFAULT_ERROR_MESSAGE.'25110',0),
+25111 => array(DEFAULT_ERROR_MESSAGE.'25111',0),
+25112 => array(DEFAULT_ERROR_MESSAGE.'25112',0),
+25113 => array(DEFAULT_ERROR_MESSAGE.'25113',0),
+25114 => array(DEFAULT_ERROR_MESSAGE.'25114',0),
+25115 => array(DEFAULT_ERROR_MESSAGE.'25115',0),
+25116 => array(DEFAULT_ERROR_MESSAGE.'25116',0),
+25117 => array(DEFAULT_ERROR_MESSAGE.'25117',0),
+25118 => array(DEFAULT_ERROR_MESSAGE.'25118',0),
+25119 => array(DEFAULT_ERROR_MESSAGE.'25119',0),
+25120 => array(DEFAULT_ERROR_MESSAGE.'25120',0),
+25121 => array(DEFAULT_ERROR_MESSAGE.'25121',0),
+25122 => array(DEFAULT_ERROR_MESSAGE.'25122',0),
+25123 => array(DEFAULT_ERROR_MESSAGE.'25123',0),
+25124 => array(DEFAULT_ERROR_MESSAGE.'25124',0),
+25125 => array(DEFAULT_ERROR_MESSAGE.'25125',0),
+25126 => array(DEFAULT_ERROR_MESSAGE.'25126',0),
+25127 => array(DEFAULT_ERROR_MESSAGE.'25127',0),
+25128 => array(DEFAULT_ERROR_MESSAGE.'25128',0),
+25129 => array(DEFAULT_ERROR_MESSAGE.'25129',0),
+25130 => array(DEFAULT_ERROR_MESSAGE.'25130',0),
+25131 => array(DEFAULT_ERROR_MESSAGE.'25131',0),
+25132 => array(DEFAULT_ERROR_MESSAGE.'25132',0),
+25133 => array(DEFAULT_ERROR_MESSAGE.'25133',0),
+25500 => array(DEFAULT_ERROR_MESSAGE.'25500',0),
+24003 => array(DEFAULT_ERROR_MESSAGE.'24003',0),
+24004 => array(DEFAULT_ERROR_MESSAGE.'24004',0),
+24005 => array(DEFAULT_ERROR_MESSAGE.'24005',0),
+24006 => array(DEFAULT_ERROR_MESSAGE.'24006',0),
+24007 => array(DEFAULT_ERROR_MESSAGE.'24007',0),
+24008 => array(DEFAULT_ERROR_MESSAGE.'24008',0),
+24009 => array(DEFAULT_ERROR_MESSAGE.'24009',0),
+24010 => array(DEFAULT_ERROR_MESSAGE.'24010',0),
+24011 => array(DEFAULT_ERROR_MESSAGE.'24011',0),
+24012 => array(DEFAULT_ERROR_MESSAGE.'24012',0),
+24013 => array(DEFAULT_ERROR_MESSAGE.'24013',0),
+24014 => array(DEFAULT_ERROR_MESSAGE.'24014',0),
+24015 => array(DEFAULT_ERROR_MESSAGE.'24015',0),
+22001 => array(DEFAULT_ERROR_MESSAGE.'22001',0),
+22002 => array(DEFAULT_ERROR_MESSAGE.'22002',0),
+22004 => array(DEFAULT_ERROR_MESSAGE.'22004',0),
+22005 => array(DEFAULT_ERROR_MESSAGE.'22005',0),
+22006 => array(DEFAULT_ERROR_MESSAGE.'22006',0),
+22007 => array(DEFAULT_ERROR_MESSAGE.'22007',0),
+22008 => array(DEFAULT_ERROR_MESSAGE.'22008',0),
+22009 => array(DEFAULT_ERROR_MESSAGE.'22009',0),
+22010 => array(DEFAULT_ERROR_MESSAGE.'22010',0),
+22011 => array(DEFAULT_ERROR_MESSAGE.'22011',0),
+22012 => array(DEFAULT_ERROR_MESSAGE.'22012',0),
+22013 => array(DEFAULT_ERROR_MESSAGE.'22013',0),
+22014 => array(DEFAULT_ERROR_MESSAGE.'22014',0),
+22015 => array(DEFAULT_ERROR_MESSAGE.'22015',0),
+22016 => array(DEFAULT_ERROR_MESSAGE.'22016',0),
+22017 => array(DEFAULT_ERROR_MESSAGE.'22017',0),
+22018 => array(DEFAULT_ERROR_MESSAGE.'22018',0),
+22019 => array(DEFAULT_ERROR_MESSAGE.'22019',0),
+22020 => array(DEFAULT_ERROR_MESSAGE.'22020',0),
+13001 => array(DEFAULT_ERROR_MESSAGE.'13001',0),
+13002 => array(DEFAULT_ERROR_MESSAGE.'13002',0),
+1001 => array(DEFAULT_ERROR_MESSAGE.'1001',0),
+1002 => array(DEFAULT_ERROR_MESSAGE.'1002',0),
+1003 => array(DEFAULT_ERROR_MESSAGE.'1003',0),
+1004 => array(DEFAULT_ERROR_MESSAGE.'1004',0),
+1005 => array(DEFAULT_ERROR_MESSAGE.'1005',0),
+1006 => array(DEFAULT_ERROR_MESSAGE.'1006',0),
+1007 => array(DEFAULT_ERROR_MESSAGE.'1007',0),
+1008 => array(DEFAULT_ERROR_MESSAGE.'1008',0),
+1009 => array(DEFAULT_ERROR_MESSAGE.'1009',0),
+1010 => array(DEFAULT_ERROR_MESSAGE.'1010',0),
+1011 => array(DEFAULT_ERROR_MESSAGE.'1011',0),
+26000 => array(DEFAULT_ERROR_MESSAGE.'26000',0),
+26001 => array(DEFAULT_ERROR_MESSAGE.'26001',0),
+26002 => array(DEFAULT_ERROR_MESSAGE.'26002',0),
+26003 => array(DEFAULT_ERROR_MESSAGE.'26003',0),
+26004 => array(DEFAULT_ERROR_MESSAGE.'26004',0),
+26005 => array(DEFAULT_ERROR_MESSAGE.'26005',0),
+26006 => array(DEFAULT_ERROR_MESSAGE.'26006',0),
+26007 => array(DEFAULT_ERROR_MESSAGE.'26007',0),
+26008 => array(DEFAULT_ERROR_MESSAGE.'26008',0),
+26009 => array(DEFAULT_ERROR_MESSAGE.'26009',0),
+26010 => array(DEFAULT_ERROR_MESSAGE.'26010',0),
+26011 => array(DEFAULT_ERROR_MESSAGE.'26011',0),
+26012 => array(DEFAULT_ERROR_MESSAGE.'26012',0),
+26013 => array(DEFAULT_ERROR_MESSAGE.'26013',0),
+26014 => array(DEFAULT_ERROR_MESSAGE.'26014',0),
+26015 => array(DEFAULT_ERROR_MESSAGE.'26015',0),
+26016 => array(DEFAULT_ERROR_MESSAGE.'26016',0),
+
+27001 => array(DEFAULT_ERROR_MESSAGE.'27001',0),
+27002 => array(DEFAULT_ERROR_MESSAGE.'27002',0),
+27003 => array(DEFAULT_ERROR_MESSAGE.'27003',0),
+27004 => array(DEFAULT_ERROR_MESSAGE.'27004',0),
+27005 => array(DEFAULT_ERROR_MESSAGE.'27005',0),
+27006 => array(DEFAULT_ERROR_MESSAGE.'27006',0),
+27007 => array(DEFAULT_ERROR_MESSAGE.'27007',0),
+27008 => array(DEFAULT_ERROR_MESSAGE.'27008',0),
+27009 => array(DEFAULT_ERROR_MESSAGE.'27009',0),
+27010 => array(DEFAULT_ERROR_MESSAGE.'27010',0),
+27011 => array(DEFAULT_ERROR_MESSAGE.'27011',0),
+27012 => array(DEFAULT_ERROR_MESSAGE.'27012',0),
+27013 => array(DEFAULT_ERROR_MESSAGE.'27013',0),
+27014 => array(DEFAULT_ERROR_MESSAGE.'27014',0),
+27015 => array(DEFAULT_ERROR_MESSAGE.'27015',0),
+
+28001 => array(DEFAULT_ERROR_MESSAGE.'28001',0),
+28002 => array(DEFAULT_ERROR_MESSAGE.'28002',0),
+28003 => array(DEFAULT_ERROR_MESSAGE.'28003',0),
+28004 => array(DEFAULT_ERROR_MESSAGE.'28004',0),
+28005 => array(DEFAULT_ERROR_MESSAGE.'28005',0),
+28006 => array(DEFAULT_ERROR_MESSAGE.'28006',0),
+28007 => array(DEFAULT_ERROR_MESSAGE.'28007',0),
+
+29201 => array(DEFAULT_ERROR_MESSAGE.'28001',0),
+29202 => array(DEFAULT_ERROR_MESSAGE.'28002',0),
+29203 => array(DEFAULT_ERROR_MESSAGE.'28003',0),
+29204 => array(DEFAULT_ERROR_MESSAGE.'28004',0),
+29205 => array(DEFAULT_ERROR_MESSAGE.'28005',0),
+29206 => array(DEFAULT_ERROR_MESSAGE.'28006',0),
+29207 => array(DEFAULT_ERROR_MESSAGE.'28007',0),
+29208 => array(DEFAULT_ERROR_MESSAGE.'28008',0),
+29209 => array(DEFAULT_ERROR_MESSAGE.'28009',0),
+29210 => array(DEFAULT_ERROR_MESSAGE.'28010',0),
+
+);
+
+?>
diff --git a/web/classes/jpgraph/themes/AquaTheme.class.php b/web/classes/jpgraph/themes/AquaTheme.class.php
new file mode 100755
index 0000000000000000000000000000000000000000..751b420268eb5644c37d0c0e4d1efa444b652184
--- /dev/null
+++ b/web/classes/jpgraph/themes/AquaTheme.class.php
@@ -0,0 +1,202 @@
+<?php
+
+/**
+* Aqua Theme class
+*/
+class AquaTheme extends Theme 
+{
+    protected $font_color       = '#0044CC';
+    protected $background_color = '#DDFFFF';
+    protected $axis_color       = '#0066CC';
+    protected $grid_color       = '#3366CC';
+
+    function GetColorList() {
+        return array(
+            '#183152',
+            '#C4D7ED',
+            '#375D81',
+            '#ABC8E2',
+            '#E1E6FA',
+            '#9BBAB2',
+            '#3B4259',
+            '#0063BC',
+            '#1D5A73',
+            '#ABABFF',
+            '#27ADC5',
+            '#EDFFCC',
+
+/*
+
+            '#66FFFF',
+            '#00AABB',
+            '#00FFCC',
+            '#33CCFF',
+            '#008866',
+            '#99FFFF',
+            '#0099FF',
+            '#99FFCC',
+            '#3399FF',
+            '#2277FF',
+            '#445588',
+            '#003388',
+            '#338877',
+            '#55DDFF',
+            '#00FF99',
+            '#BBBBBB',
+            '#77AAFF',
+            '#00FFCC',
+*/
+        );
+    }
+
+    function SetupGraph($graph) {
+
+        // graph
+        /*
+        $img = $graph->img;
+        $height = $img->height;
+        $graph->SetMargin($img->left_margin, $img->right_margin, $img->top_margin, $height * 0.25);
+        */
+        $graph->SetFrame(false);
+        $graph->SetMarginColor('white');
+        $graph->SetBackgroundGradient($this->background_color, '#FFFFFF', GRAD_HOR, BGRAD_PLOT);
+
+        // legend
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.85, 'center', 'top');
+        $graph->legend->SetFillColor('white');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(3);
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // xaxis
+        $graph->xaxis->title->SetColor($this->font_color);  
+        $graph->xaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->xaxis->SetTickSide(SIDE_BOTTOM);
+        $graph->xaxis->SetLabelMargin(10);
+                
+        // yaxis
+        $graph->yaxis->title->SetColor($this->font_color);  
+        $graph->yaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->yaxis->SetTickSide(SIDE_LEFT);
+        $graph->yaxis->SetLabelMargin(8);
+        $graph->yaxis->HideLine();
+        $graph->yaxis->HideTicks();
+        $graph->xaxis->SetTitleMargin(15);
+
+        // grid
+        $graph->ygrid->SetColor($this->grid_color);
+        $graph->ygrid->SetLineStyle('dotted');
+
+
+        // font
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+//        $graph->img->SetAntiAliasing();
+    }
+
+
+    function SetupPieGraph($graph) {
+
+        // graph
+        $graph->SetFrame(false);
+
+        // legend
+        $graph->legend->SetFillColor('white');
+
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.80, 'center', 'top');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(4);
+
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // title
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+        $graph->SetAntiAliasing();
+    }
+
+
+    function PreStrokeApply($graph) {
+        if ($graph->legend->HasItems()) {
+            $img = $graph->img;
+            $height = $img->height;
+            $graph->SetMargin(
+                $img->raw_left_margin, 
+                $img->raw_right_margin, 
+                $img->raw_top_margin, 
+                $height * 0.25
+            );
+        }
+    }
+
+    function ApplyPlot($plot) {
+
+        switch (get_class($plot))
+        { 
+            case 'GroupBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'AccBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'BarPlot':
+            {
+                $plot->Clear();
+
+                $color = $this->GetNextColor();
+                $plot->SetColor($color);
+                $plot->SetFillColor($color);
+                //$plot->SetShadow();
+                break;
+            }
+
+            case 'LinePlot':
+            {
+                $plot->Clear();
+                $plot->SetColor($this->GetNextColor());
+                $plot->SetWeight(2);
+//                $plot->SetBarCenter();
+                break;
+            }
+
+            case 'PiePlot':
+            {
+                $plot->SetCenter(0.5, 0.45);
+                $plot->ShowBorder(false);
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+
+            case 'PiePlot3D':
+            {
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+    
+            default:
+            {
+            }
+        }
+    }
+}
+
+
+?>
diff --git a/web/classes/jpgraph/themes/GreenTheme.class.php b/web/classes/jpgraph/themes/GreenTheme.class.php
new file mode 100755
index 0000000000000000000000000000000000000000..a61fbd834d323f0d73828bd7b9b785d67dbb1786
--- /dev/null
+++ b/web/classes/jpgraph/themes/GreenTheme.class.php
@@ -0,0 +1,178 @@
+<?php
+
+/**
+* Green Theme class
+*/
+class GreenTheme extends Theme 
+{
+    private $font_color       = '#009900';
+    private $background_color = '#EEFFDD';
+    private $axis_color       = '#00CC00';
+    private $grid_color       = '#33CC33';
+
+    function GetColorList() {
+        return array(
+            '#66CC00',
+            '#009900',
+            '#AAFF77',
+            '#559922',
+            '#00CC33',
+            '#99FF00',
+            '#009966',
+            '#00FF99',
+            '#99BB66',
+            '#33FF00',
+            '#DDFFBB',
+            '#669933',
+            '#BBDDCC',
+            '#77CCBB',
+            '#668833',
+            '#BBEE66',
+        );
+    }
+
+    function SetupGraph($graph) {
+
+        // graph
+        /*
+        $img = $graph->img;
+        $height = $img->height;
+        $graph->SetMargin($img->left_margin, $img->right_margin, $img->top_margin, $height * 0.25);
+        */
+        $graph->SetFrame(false);
+        $graph->SetMarginColor('white');
+        $graph->SetBackgroundGradient($this->background_color, '#FFFFFF', GRAD_HOR, BGRAD_PLOT);
+
+        // legend
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.85, 'center', 'top');
+        $graph->legend->SetFillColor('white');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(3);
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // xaxis
+        $graph->xaxis->title->SetColor($this->font_color);  
+        $graph->xaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->xaxis->SetTickSide(SIDE_BOTTOM);
+        $graph->xaxis->SetLabelMargin(10);
+                
+        // yaxis
+        $graph->yaxis->title->SetColor($this->font_color);  
+        $graph->yaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->yaxis->SetTickSide(SIDE_LEFT);
+        $graph->yaxis->SetLabelMargin(8);
+        $graph->yaxis->HideLine();
+        $graph->yaxis->HideTicks();
+        $graph->xaxis->SetTitleMargin(15);
+
+        // grid
+        $graph->ygrid->SetColor($this->grid_color);
+        $graph->ygrid->SetLineStyle('dotted');
+
+
+        // font
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+//        $graph->img->SetAntiAliasing();
+    }
+
+
+    function SetupPieGraph($graph) {
+
+        // graph
+        $graph->SetFrame(false);
+
+        // legend
+        $graph->legend->SetFillColor('white');
+        /*
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.85, 'center', 'top');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(3);
+        */
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // title
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+        $graph->SetAntiAliasing();
+    }
+
+
+    function PreStrokeApply($graph) {
+        if ($graph->legend->HasItems()) {
+            $img = $graph->img;
+            $height = $img->height;
+            $graph->SetMargin($img->left_margin, $img->right_margin, $img->top_margin, $height * 0.25);
+        }
+    }
+
+    function ApplyPlot($plot) {
+
+        switch (get_class($plot))
+        { 
+            case 'GroupBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'AccBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'BarPlot':
+            {
+                $plot->Clear();
+
+                $color = $this->GetNextColor();
+                $plot->SetColor($color);
+                $plot->SetFillColor($color);
+                $plot->SetShadow('red', 3, 4, false);
+                break;
+            }
+
+            case 'LinePlot':
+            {
+                $plot->Clear();
+
+                $plot->SetColor($this->GetNextColor().'@0.4');
+                $plot->SetWeight(2);
+                break;
+            }
+
+            case 'PiePlot':
+            {
+                $plot->ShowBorder(false);
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+
+            case 'PiePlot3D':
+            {
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+    
+            default:
+            {
+            }
+        }
+    }
+}
+
+
+?>
diff --git a/web/classes/jpgraph/themes/OceanTheme.class.php b/web/classes/jpgraph/themes/OceanTheme.class.php
new file mode 100755
index 0000000000000000000000000000000000000000..b2750360d7506a45a66e55f685020abaf5b591b4
--- /dev/null
+++ b/web/classes/jpgraph/themes/OceanTheme.class.php
@@ -0,0 +1,180 @@
+<?php
+
+/**
+* Ocean Theme class
+*/
+class OceanTheme extends Theme 
+{
+    protected $font_color       = '#0066FF';
+    private $background_color = '#DDEEFF';
+    private $axis_color       = '#0000CC';
+    private $grid_color       = '#3333CC';
+
+    function GetColorList() {
+        return array(
+            '#0066FF',
+            '#CCCCFF',
+            '#0000FF',
+            '#3366FF',
+            '#33CCFF',
+            '#660088',
+            '#3300FF',
+            '#0099FF',
+            '#6633FF',
+            '#0055EE',
+            '#2277EE',
+            '#3300FF',
+            '#AA00EE',
+            '#778899',
+            '#114499',
+            '#7744EE',
+            '#002288',
+            '#6666FF',
+        );
+    }
+
+    function SetupGraph($graph) {
+
+        // graph
+        /*
+        $img = $graph->img;
+        $height = $img->height;
+        $graph->SetMargin($img->left_margin, $img->right_margin, $img->top_margin, $height * 0.25);
+        */
+        $graph->SetFrame(false);
+        $graph->SetMarginColor('white');
+        $graph->SetBackgroundGradient($this->background_color, '#FFFFFF', GRAD_HOR, BGRAD_PLOT);
+
+        // legend
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.85, 'center', 'top');
+        $graph->legend->SetFillColor('white');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(3);
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // xaxis
+        $graph->xaxis->title->SetColor($this->font_color);  
+        $graph->xaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->xaxis->SetTickSide(SIDE_BOTTOM);
+        $graph->xaxis->SetLabelMargin(10);
+                
+        // yaxis
+        $graph->yaxis->title->SetColor($this->font_color);  
+        $graph->yaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->yaxis->SetTickSide(SIDE_LEFT);
+        $graph->yaxis->SetLabelMargin(8);
+        $graph->yaxis->HideLine();
+        $graph->yaxis->HideTicks();
+        $graph->xaxis->SetTitleMargin(15);
+
+        // grid
+        $graph->ygrid->SetColor($this->grid_color);
+        $graph->ygrid->SetLineStyle('dotted');
+
+
+        // font
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+//        $graph->img->SetAntiAliasing();
+    }
+
+
+    function SetupPieGraph($graph) {
+
+        // graph
+        $graph->SetFrame(false);
+
+        // legend
+        $graph->legend->SetFillColor('white');
+        /*
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.85, 'center', 'top');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(3);
+        */
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // title
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+        $graph->SetAntiAliasing();
+    }
+
+
+    function PreStrokeApply($graph) {
+        if ($graph->legend->HasItems()) {
+            $img = $graph->img;
+            $height = $img->height;
+            $graph->SetMargin($img->left_margin, $img->right_margin, $img->top_margin, $height * 0.25);
+        }
+    }
+
+    function ApplyPlot($plot) {
+
+        switch (get_class($plot))
+        { 
+            case 'GroupBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'AccBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'BarPlot':
+            {
+                $plot->Clear();
+
+                $color = $this->GetNextColor();
+                $plot->SetColor($color);
+                $plot->SetFillColor($color);
+                $plot->SetShadow('red', 3, 4, false);
+                break;
+            }
+
+            case 'LinePlot':
+            {
+                $plot->Clear();
+
+                $plot->SetColor($this->GetNextColor());
+                $plot->SetWeight(2);
+                break;
+            }
+
+            case 'PiePlot':
+            {
+                $plot->ShowBorder(false);
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+
+            case 'PiePlot3D':
+            {
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+    
+            default:
+            {
+            }
+        }
+    }
+}
+
+
+?>
diff --git a/web/classes/jpgraph/themes/OrangeTheme.class.php b/web/classes/jpgraph/themes/OrangeTheme.class.php
new file mode 100755
index 0000000000000000000000000000000000000000..ea26dad856d1c80251dfef5e591155811330002f
--- /dev/null
+++ b/web/classes/jpgraph/themes/OrangeTheme.class.php
@@ -0,0 +1,180 @@
+<?php
+
+/**
+* Orange Theme class
+*/
+class OrangeTheme extends Theme 
+{
+    private $font_color       = '#CC4400';
+    private $background_color = '#FFEEDD';
+    private $axis_color       = '#CC6600';
+    private $grid_color       = '#CC6633';
+
+    function GetColorList() {
+        return array(
+            '#FF9900',
+            '#FFCC00',
+            '#AA6600',
+            '#CCCC00',
+            '#CC6600',
+            '#FFFF66',
+            '#CCFF00',
+            '#CC3300',
+            '#669933',
+            '#EE7700',
+            '#AAEE33',
+            '#77AA00',
+            '#CCFF99',
+            '#FF6633',
+            '#885500',
+            '#AADD00',
+            '#99CC44',
+            '#887711',
+        );
+    }
+
+    function SetupGraph($graph) {
+
+        // graph
+        /*
+        $img = $graph->img;
+        $height = $img->height;
+        $graph->SetMargin($img->left_margin, $img->right_margin, $img->top_margin, $height * 0.25);
+        */
+        $graph->SetFrame(false);
+        $graph->SetMarginColor('white');
+        $graph->SetBackgroundGradient($this->background_color, '#FFFFFF', GRAD_HOR, BGRAD_PLOT);
+
+        // legend
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.85, 'center', 'top');
+        $graph->legend->SetFillColor('white');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(3);
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // xaxis
+        $graph->xaxis->title->SetColor($this->font_color);  
+        $graph->xaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->xaxis->SetTickSide(SIDE_BOTTOM);
+        $graph->xaxis->SetLabelMargin(10);
+                
+        // yaxis
+        $graph->yaxis->title->SetColor($this->font_color);  
+        $graph->yaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->yaxis->SetTickSide(SIDE_LEFT);
+        $graph->yaxis->SetLabelMargin(8);
+        $graph->yaxis->HideLine();
+        $graph->yaxis->HideTicks();
+        $graph->xaxis->SetTitleMargin(15);
+
+        // grid
+        $graph->ygrid->SetColor($this->grid_color);
+        $graph->ygrid->SetLineStyle('dotted');
+
+
+        // font
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+//        $graph->img->SetAntiAliasing();
+    }
+
+
+    function SetupPieGraph($graph) {
+
+        // graph
+        $graph->SetFrame(false);
+
+        // legend
+        $graph->legend->SetFillColor('white');
+        /*
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.85, 'center', 'top');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(3);
+        */
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // title
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+        $graph->SetAntiAliasing();
+    }
+
+
+    function PreStrokeApply($graph) {
+        if ($graph->legend->HasItems()) {
+            $img = $graph->img;
+            $height = $img->height;
+            $graph->SetMargin($img->left_margin, $img->right_margin, $img->top_margin, $height * 0.25);
+        }
+    }
+
+    function ApplyPlot($plot) {
+
+        switch (get_class($plot))
+        { 
+            case 'GroupBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'AccBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'BarPlot':
+            {
+                $plot->Clear();
+
+                $color = $this->GetNextColor();
+                $plot->SetColor($color);
+                $plot->SetFillColor($color);
+                $plot->SetShadow('red', 3, 4, false);
+                break;
+            }
+
+            case 'LinePlot':
+            {
+                $plot->Clear();
+
+                $plot->SetColor($this->GetNextColor().'@0.4');
+                $plot->SetWeight(2);
+                break;
+            }
+
+            case 'PiePlot':
+            {
+                $plot->ShowBorder(false);
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+
+            case 'PiePlot3D':
+            {
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+    
+            default:
+            {
+            }
+        }
+    }
+}
+
+
+?>
diff --git a/web/classes/jpgraph/themes/PastelTheme.class.php b/web/classes/jpgraph/themes/PastelTheme.class.php
new file mode 100755
index 0000000000000000000000000000000000000000..d3f1ddb6a898e44ff7fb263489be1ae6757bde32
--- /dev/null
+++ b/web/classes/jpgraph/themes/PastelTheme.class.php
@@ -0,0 +1,175 @@
+<?php
+
+/**
+* Pastel Theme class
+*/
+class PastelTheme extends Theme 
+{
+    private $font_color       = '#0044CC';
+    private $background_color = '#DDFFFF';
+    private $axis_color       = '#0066CC';
+    private $grid_color       = '#3366CC';
+
+    function GetColorList() {
+        return array(
+            '#FFAACC',
+            '#AAEECC',
+            '#AACCFF',
+            '#CCAAFF',
+            '#EEDDFF',
+            '#FFCCAA',
+            '#CCBBDD',
+            '#CCFFAA',
+            '#C7D7C2',
+            '#FFEEDD',
+            '#FFCCEE',
+            '#BFECFA',
+        );
+    }
+
+    function SetupGraph($graph) {
+
+        // graph
+        /*
+        $img = $graph->img;
+        $height = $img->height;
+        $graph->SetMargin($img->left_margin, $img->right_margin, $img->top_margin, $height * 0.25);
+        */
+        $graph->SetFrame(false);
+        $graph->SetMarginColor('white');
+        $graph->SetBackgroundGradient($this->background_color, '#FFFFFF', GRAD_HOR, BGRAD_PLOT);
+
+        // legend
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.85, 'center', 'top');
+        $graph->legend->SetFillColor('white');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(3);
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // xaxis
+        $graph->xaxis->title->SetColor($this->font_color);  
+        $graph->xaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->xaxis->SetTickSide(SIDE_BOTTOM);
+        $graph->xaxis->SetLabelMargin(10);
+                
+        // yaxis
+        $graph->yaxis->title->SetColor($this->font_color);  
+        $graph->yaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->yaxis->SetTickSide(SIDE_LEFT);
+        $graph->yaxis->SetLabelMargin(8);
+        $graph->yaxis->HideLine();
+        $graph->yaxis->HideTicks();
+        $graph->xaxis->SetTitleMargin(15);
+
+        // grid
+        $graph->ygrid->SetColor($this->grid_color);
+        $graph->ygrid->SetLineStyle('dotted');
+
+
+        // font
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+//        $graph->img->SetAntiAliasing();
+    }
+
+
+    function SetupPieGraph($graph) {
+
+        // graph
+        $graph->SetFrame(false);
+
+        // legend
+        $graph->legend->SetFillColor('white');
+
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.80, 'center', 'top');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(4);
+
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // title
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+        $graph->SetAntiAliasing();
+    }
+
+
+    function PreStrokeApply($graph) {
+        if ($graph->legend->HasItems()) {
+            $img = $graph->img;
+            $height = $img->height;
+            $graph->SetMargin($img->left_margin, $img->right_margin, $img->top_margin, $height * 0.25);
+        }
+    }
+
+    function ApplyPlot($plot) {
+
+        switch (get_class($plot))
+        { 
+            case 'GroupBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'AccBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'BarPlot':
+            {
+                $plot->Clear();
+
+                $color = $this->GetNextColor();
+                $plot->SetColor($color);
+                $plot->SetFillColor($color);
+                $plot->SetShadow('red', 3, 4, false);
+                break;
+            }
+
+            case 'LinePlot':
+            {
+                $plot->Clear();
+                $plot->SetColor($this->GetNextColor().'@0.4');
+                $plot->SetWeight(2);
+//                $plot->SetBarCenter();
+                break;
+            }
+
+            case 'PiePlot':
+            {
+                $plot->SetCenter(0.5, 0.45);
+                $plot->ShowBorder(false);
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+
+            case 'PiePlot3D':
+            {
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+    
+            default:
+            {
+            }
+        }
+    }
+}
+
+
+?>
diff --git a/web/classes/jpgraph/themes/RoseTheme.class.php b/web/classes/jpgraph/themes/RoseTheme.class.php
new file mode 100755
index 0000000000000000000000000000000000000000..5a1463005145e505d033b00aef719304d6f28b7d
--- /dev/null
+++ b/web/classes/jpgraph/themes/RoseTheme.class.php
@@ -0,0 +1,180 @@
+<?php
+
+/**
+* Rose Theme class
+*/
+class RoseTheme extends Theme 
+{
+    private $font_color       = '#CC0044';
+    private $background_color = '#FFDDDD';
+    private $axis_color       = '#CC0000';
+    private $grid_color       = '#CC3333';
+
+    function GetColorList() {
+        return array(
+            '#FF0000',
+            '#FF99FF',
+            '#AA0099',
+            '#FF00FF',
+            '#FF6666',
+            '#FF0099',
+            '#FFBB88',
+            '#AA2211',
+            '#FF6699',
+            '#BBAA88',
+            '#FF2200',
+            '#883333',
+            '#EE7777',
+            '#EE7711',
+            '#FF0066',
+            '#DD7711',
+            '#AA6600',
+            '#EE5500',
+        );
+    }
+
+    function SetupGraph($graph) {
+
+        // graph
+        /*
+        $img = $graph->img;
+        $height = $img->height;
+        $graph->SetMargin($img->left_margin, $img->right_margin, $img->top_margin, $height * 0.25);
+        */
+        $graph->SetFrame(false);
+        $graph->SetMarginColor('white');
+        $graph->SetBackgroundGradient($this->background_color, '#FFFFFF', GRAD_HOR, BGRAD_PLOT);
+
+        // legend
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.85, 'center', 'top');
+        $graph->legend->SetFillColor('white');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(3);
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // xaxis
+        $graph->xaxis->title->SetColor($this->font_color);  
+        $graph->xaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->xaxis->SetTickSide(SIDE_BOTTOM);
+        $graph->xaxis->SetLabelMargin(10);
+                
+        // yaxis
+        $graph->yaxis->title->SetColor($this->font_color);  
+        $graph->yaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->yaxis->SetTickSide(SIDE_LEFT);
+        $graph->yaxis->SetLabelMargin(8);
+        $graph->yaxis->HideLine();
+        $graph->yaxis->HideTicks();
+        $graph->xaxis->SetTitleMargin(15);
+
+        // grid
+        $graph->ygrid->SetColor($this->grid_color);
+        $graph->ygrid->SetLineStyle('dotted');
+
+
+        // font
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+//        $graph->img->SetAntiAliasing();
+    }
+
+
+    function SetupPieGraph($graph) {
+
+        // graph
+        $graph->SetFrame(false);
+
+        // legend
+        $graph->legend->SetFillColor('white');
+        /*
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.85, 'center', 'top');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(3);
+        */
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // title
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+        $graph->SetAntiAliasing();
+    }
+
+
+    function PreStrokeApply($graph) {
+        if ($graph->legend->HasItems()) {
+            $img = $graph->img;
+            $height = $img->height;
+            $graph->SetMargin($img->left_margin, $img->right_margin, $img->top_margin, $height * 0.25);
+        }
+    }
+
+    function ApplyPlot($plot) {
+
+        switch (get_class($plot))
+        { 
+            case 'GroupBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'AccBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'BarPlot':
+            {
+                $plot->Clear();
+
+                $color = $this->GetNextColor();
+                $plot->SetColor($color);
+                $plot->SetFillColor($color);
+                $plot->SetShadow('red', 3, 4, false);
+                break;
+            }
+
+            case 'LinePlot':
+            {
+                $plot->Clear();
+
+                $plot->SetColor($this->GetNextColor().'@0.4');
+                $plot->SetWeight(2);
+                break;
+            }
+
+            case 'PiePlot':
+            {
+                $plot->ShowBorder(false);
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+
+            case 'PiePlot3D':
+            {
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+    
+            default:
+            {
+            }
+        }
+    }
+}
+
+
+?>
diff --git a/web/classes/jpgraph/themes/SoftyTheme.class.php b/web/classes/jpgraph/themes/SoftyTheme.class.php
new file mode 100755
index 0000000000000000000000000000000000000000..222cf85a1652dc09c54678042564d1c6e65f99d7
--- /dev/null
+++ b/web/classes/jpgraph/themes/SoftyTheme.class.php
@@ -0,0 +1,209 @@
+<?php
+
+/**
+* Softy Theme class
+*/
+class SoftyTheme extends Theme 
+{
+    protected $font_color       = '#000000';
+    protected $background_color = '#F7F8F4';
+    protected $axis_color       = '#000000';
+    protected $grid_color       = '#CCCCCC';
+
+    function GetColorList() {
+        return array(
+            '#CFE7FB',
+            '#F9D76F',
+            '#B9D566',
+            '#FFBB90',
+            '#66BBBB',
+            '#E69090',
+            '#BB90BB',
+            '#9AB67C',
+            '#D1CC66',
+
+/*
+
+            '#AFD8F8',
+            '#F6BD0F',
+            '#8BBA00',
+            '#FF8E46',
+            '#008E8E',
+
+            '#D64646',
+            '#8E468E',
+            '#588526',
+            '#B3AA00',
+            '#008ED6',
+
+            '#9D080D',
+            '#A186BE',
+            */
+        );
+    }
+
+    function SetupGraph($graph) {
+
+        // graph
+        $graph->SetFrame(false);
+        $graph->SetMarginColor('white');
+
+        // legend
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.85, 'center', 'top');
+        $graph->legend->SetFillColor('white');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(3);
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // xaxis
+        $graph->xaxis->title->SetColor($this->font_color);  
+        $graph->xaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->xaxis->SetTickSide(SIDE_BOTTOM);
+        $graph->xaxis->SetLabelMargin(10);
+                
+        // yaxis
+        $graph->yaxis->title->SetColor($this->font_color);  
+        $graph->yaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->yaxis->SetTickSide(SIDE_LEFT);
+        $graph->yaxis->SetLabelMargin(8);
+        $graph->yaxis->HideLine();
+        $graph->yaxis->HideTicks();
+        $graph->xaxis->SetTitleMargin(15);
+
+        // y2~
+        if (isset($graph->y2axis)) {
+            $graph->y2axis->title->SetColor($this->font_color);  
+            $graph->y2axis->SetColor($this->axis_color, $this->font_color);    
+            $graph->y2axis->SetTickSide(SIDE_LEFT);
+            $graph->y2axis->SetLabelMargin(8);
+            $graph->y2axis->HideLine();
+            $graph->y2axis->HideTicks();
+        }
+
+        // yn
+        if (isset($graph->y2axis)) {
+            foreach ($graph->ynaxis as $axis) {
+                $axis->title->SetColor($this->font_color);  
+                $axis->SetColor($this->axis_color, $this->font_color);    
+                $axis->SetTickSide(SIDE_LEFT);
+                $axis->SetLabelMargin(8);
+                $axis->HideLine();
+                $axis->HideTicks();
+            }
+        }
+
+        // grid
+        $graph->ygrid->SetColor($this->grid_color);
+        $graph->ygrid->SetLineStyle('dotted');
+        $graph->ygrid->SetFill(true, '#FFFFFF', $this->background_color);
+        $graph->xgrid->Show();
+        $graph->xgrid->SetColor($this->grid_color);
+        $graph->xgrid->SetLineStyle('dotted');
+
+
+        // font
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+//        $graph->img->SetAntiAliasing();
+    }
+
+
+    function SetupPieGraph($graph) {
+
+        // graph
+        $graph->SetFrame(false);
+
+        // title
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+        $graph->SetAntiAliasing();
+    }
+
+
+    function PreStrokeApply($graph) {
+        if ($graph->legend->HasItems()) {
+            $img = $graph->img;
+            $graph->SetMargin($img->left_margin, $img->right_margin, $img->top_margin, $img->height * 0.25);
+//            $graph->SetMargin(200, $img->right_margin, $img->top_margin, $height * 0.25);
+        }
+    }
+
+    function ApplyPlot($plot) {
+
+        switch (get_class($plot))
+        { 
+            case 'BarPlot':
+            {
+                $plot->Clear();
+
+                $color = $this->GetNextColor();
+                $plot->SetColor($color);
+                $plot->SetFillColor($color);
+                $plot->SetShadow('red', 3, 4, false);
+                $plot->value->SetAlign('center', 'center');
+                break;
+            }
+
+            case 'LinePlot':
+            {
+                $plot->Clear();
+
+                $plot->SetColor($this->GetNextColor());
+                $plot->SetWeight(2);
+//                $plot->SetBarCenter();
+                break;
+            }
+
+            case 'PiePlot':
+            {
+                $plot->ShowBorder(false);
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+
+
+            case 'GroupBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'AccBarPlot':
+            {
+                $plot->value->SetAlign('center', 'center');
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                    $_plot->SetValuePos('center');
+                }
+                break;
+            }
+
+            case 'ScatterPlot':
+            {
+                break;
+            }
+
+
+            case 'PiePlot3D':
+            {
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+    
+            default:
+            {
+            }
+        }
+    }
+}
+
+
+?>
diff --git a/web/classes/jpgraph/themes/UniversalTheme.class.php b/web/classes/jpgraph/themes/UniversalTheme.class.php
new file mode 100755
index 0000000000000000000000000000000000000000..44b57a6ea50421e9c824dc390fe63edf1d6abd38
--- /dev/null
+++ b/web/classes/jpgraph/themes/UniversalTheme.class.php
@@ -0,0 +1,188 @@
+<?php
+
+/**
+* Universal Theme class
+*/
+class UniversalTheme extends Theme 
+{
+    private $font_color       = '#444444';
+    private $background_color = '#F4F4F4';
+    private $axis_color       = '#888888';
+    private $grid_color       = '#E3E3E3';
+
+    function GetColorList() {
+        return array(
+            '#61a9f3',#blue
+            '#f381b9',#red
+            '#61E3A9',#green
+
+            #'#D56DE2',
+            '#85eD82',
+            '#F7b7b7',
+            '#CFDF49',
+            '#88d8f2',
+            '#07AF7B',
+            '#B9E3F9',
+            '#FFF3AD',
+            '#EF606A',
+            '#EC8833',
+            '#FFF100',
+            '#87C9A5',
+        );
+    }
+
+    function SetupGraph($graph) {
+
+        // graph
+        /*
+        $img = $graph->img;
+        $height = $img->height;
+        $graph->SetMargin($img->left_margin, $img->right_margin, $img->top_margin, $height * 0.25);
+        */
+        $graph->SetFrame(false);
+        $graph->SetMarginColor('white');
+        $graph->SetBox(true, '#DADADA');
+//        $graph->SetBackgroundGradient($this->background_color, '#FFFFFF', GRAD_HOR, BGRAD_PLOT);
+
+        // legend
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.85, 'center', 'top');
+        $graph->legend->SetFillColor('white');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(3);
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // xaxis
+        $graph->xaxis->title->SetColor($this->font_color);  
+        $graph->xaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->xaxis->SetTickSide(SIDE_BOTTOM);
+        $graph->xaxis->SetLabelMargin(10);
+        $graph->xaxis->HideTicks();
+        $graph->xaxis->SetTitleMargin(15);
+        //$graph->xaxis->SetLabelMargin(30);
+                
+        // yaxis
+        $graph->yaxis->title->SetColor($this->font_color);  
+        $graph->yaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->yaxis->SetTickSide(SIDE_LEFT);
+        $graph->yaxis->SetLabelMargin(8);
+//        $graph->yaxis->SetTickPositions(array(50, 100, 150));
+//        $graph->yaxis->HideLine();
+        $graph->yaxis->HideTicks();
+
+        // grid
+        $graph->ygrid->SetColor($this->grid_color);
+        $graph->ygrid->SetFill(true, '#FFFFFF', $this->background_color);
+ //       $graph->ygrid->SetLineStyle('dotted');
+
+
+        // font
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+        $graph->img->SetAntiAliasing();
+    }
+
+
+    function SetupPieGraph($graph) {
+
+        // graph
+        $graph->SetFrame(false);
+
+        // legend
+        $graph->legend->SetFillColor('white');
+
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.80, 'center', 'top');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(4);
+
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // title
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+        $graph->SetAntiAliasing();
+    }
+
+
+    function PreStrokeApply($graph) {
+        if ($graph->legend->HasItems()) {
+            $img = $graph->img;
+            $height = $img->height;
+            $graph->SetMargin(
+                $img->raw_left_margin, 
+                $img->raw_right_margin, 
+                $img->raw_top_margin, 
+                $height * 0.25
+            );
+        }
+    }
+
+    function ApplyPlot($plot) {
+
+        switch (get_class($plot))
+        { 
+            case 'GroupBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'AccBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'BarPlot':
+            {
+                $plot->Clear();
+
+                $color = $this->GetNextColor();
+                $plot->SetColor($color);
+                $plot->SetFillColor($color);
+                $plot->SetShadow('red', 3, 4, false);
+                break;
+            }
+
+            case 'LinePlot':
+            {
+                $plot->Clear();
+                $plot->SetColor($this->GetNextColor().'@0.4');
+                $plot->SetWeight(2);
+                break;
+            }
+
+            case 'PiePlot':
+            {
+                $plot->SetCenter(0.5, 0.45);
+                $plot->ShowBorder(false);
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+
+            case 'PiePlot3D':
+            {
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+    
+            default:
+            {
+            }
+        }
+    }
+}
+
+
+?>
diff --git a/web/classes/jpgraph/themes/VividTheme.class.php b/web/classes/jpgraph/themes/VividTheme.class.php
new file mode 100755
index 0000000000000000000000000000000000000000..38a7709189e9e0477f6ae958f9ac169283929721
--- /dev/null
+++ b/web/classes/jpgraph/themes/VividTheme.class.php
@@ -0,0 +1,175 @@
+<?php
+
+/**
+* Vivid Theme class
+*/
+class VividTheme extends Theme 
+{
+    private $font_color       = '#0044CC';
+    private $background_color = '#DDFFFF';
+    private $axis_color       = '#0066CC';
+    private $grid_color       = '#3366CC';
+
+    function GetColorList() {
+        return array(
+            '#FFFB11',
+            '#005EBC',
+            '#9AEB67',
+            '#FF4A26',
+            '#FDFF98',
+            '#6B7EFF',
+            '#BCE02E',
+            '#E0642E',
+            '#E0D62E',
+            '#2E97E0',
+            '#02927F',
+            '#FF005A',
+        );
+    }
+
+    function SetupGraph($graph) {
+
+        // graph
+        /*
+        $img = $graph->img;
+        $height = $img->height;
+        $graph->SetMargin($img->left_margin, $img->right_margin, $img->top_margin, $height * 0.25);
+        */
+        $graph->SetFrame(false);
+        $graph->SetMarginColor('white');
+        $graph->SetBackgroundGradient($this->background_color, '#FFFFFF', GRAD_HOR, BGRAD_PLOT);
+
+        // legend
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.85, 'center', 'top');
+        $graph->legend->SetFillColor('white');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(3);
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // xaxis
+        $graph->xaxis->title->SetColor($this->font_color);  
+        $graph->xaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->xaxis->SetTickSide(SIDE_BOTTOM);
+        $graph->xaxis->SetLabelMargin(10);
+                
+        // yaxis
+        $graph->yaxis->title->SetColor($this->font_color);  
+        $graph->yaxis->SetColor($this->axis_color, $this->font_color);    
+        $graph->yaxis->SetTickSide(SIDE_LEFT);
+        $graph->yaxis->SetLabelMargin(8);
+        $graph->yaxis->HideLine();
+        $graph->yaxis->HideTicks();
+        $graph->xaxis->SetTitleMargin(15);
+
+        // grid
+        $graph->ygrid->SetColor($this->grid_color);
+        $graph->ygrid->SetLineStyle('dotted');
+
+
+        // font
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+//        $graph->img->SetAntiAliasing();
+    }
+
+
+    function SetupPieGraph($graph) {
+
+        // graph
+        $graph->SetFrame(false);
+
+        // legend
+        $graph->legend->SetFillColor('white');
+
+        $graph->legend->SetFrameWeight(0);
+        $graph->legend->Pos(0.5, 0.80, 'center', 'top');
+        $graph->legend->SetLayout(LEGEND_HOR);
+        $graph->legend->SetColumns(4);
+
+        $graph->legend->SetShadow(false);
+        $graph->legend->SetMarkAbsSize(5);
+
+        // title
+        $graph->title->SetColor($this->font_color);
+        $graph->subtitle->SetColor($this->font_color);
+        $graph->subsubtitle->SetColor($this->font_color);
+
+        $graph->SetAntiAliasing();
+    }
+
+
+    function PreStrokeApply($graph) {
+        if ($graph->legend->HasItems()) {
+            $img = $graph->img;
+            $height = $img->height;
+            $graph->SetMargin($img->left_margin, $img->right_margin, $img->top_margin, $height * 0.25);
+        }
+    }
+
+    function ApplyPlot($plot) {
+
+        switch (get_class($plot))
+        { 
+            case 'GroupBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'AccBarPlot':
+            {
+                foreach ($plot->plots as $_plot) {
+                    $this->ApplyPlot($_plot);
+                }
+                break;
+            }
+
+            case 'BarPlot':
+            {
+                $plot->Clear();
+
+                $color = $this->GetNextColor();
+                $plot->SetColor($color);
+                $plot->SetFillColor($color);
+                $plot->SetShadow('red', 3, 4, false);
+                break;
+            }
+
+            case 'LinePlot':
+            {
+                $plot->Clear();
+                $plot->SetColor($this->GetNextColor().'@0.4');
+                $plot->SetWeight(2);
+//                $plot->SetBarCenter();
+                break;
+            }
+
+            case 'PiePlot':
+            {
+                $plot->SetCenter(0.5, 0.45);
+                $plot->ShowBorder(false);
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+
+            case 'PiePlot3D':
+            {
+                $plot->SetSliceColors($this->GetThemeColors());
+                break;
+            }
+    
+            default:
+            {
+            }
+        }
+    }
+}
+
+
+?>
diff --git a/web/css/3-col-portfolio.css b/web/css/3-col-portfolio.css
new file mode 100755
index 0000000000000000000000000000000000000000..cf760dd0360ce11bee8c60f5df6d8f32b1f194d9
--- /dev/null
+++ b/web/css/3-col-portfolio.css
@@ -0,0 +1,17 @@
+/*!
+ * Start Bootstrap - 3 Col Portfolio HTML Template (http://startbootstrap.com)
+ * Code licensed under the Apache License v2.0.
+ * For details, see http://www.apache.org/licenses/LICENSE-2.0.
+ */
+
+body {
+    padding-top: 70px; /* Required padding for .navbar-fixed-top. Remove if using .navbar-static-top. Change if height of navigation changes. */
+}
+
+.portfolio-item {
+    margin-bottom: 25px;
+}
+
+footer {
+    margin: 50px 0;
+}
\ No newline at end of file
diff --git a/web/css/bootstrap.css b/web/css/bootstrap.css
new file mode 100755
index 0000000000000000000000000000000000000000..42c79d6e459ece1c606314879146768dad3d2656
--- /dev/null
+++ b/web/css/bootstrap.css
@@ -0,0 +1,6760 @@
+/*!
+ * Bootstrap v3.3.6 (http://getbootstrap.com)
+ * Copyright 2011-2015 Twitter, Inc.
+ * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
+ */
+/*! normalize.css v3.0.3 | MIT License | github.com/necolas/normalize.css */
+html {
+  font-family: sans-serif;
+  -webkit-text-size-adjust: 100%;
+      -ms-text-size-adjust: 100%;
+}
+body {
+  margin: 0;
+}
+article,
+aside,
+details,
+figcaption,
+figure,
+footer,
+header,
+hgroup,
+main,
+menu,
+nav,
+section,
+summary {
+  display: block;
+}
+audio,
+canvas,
+progress,
+video {
+  display: inline-block;
+  vertical-align: baseline;
+}
+audio:not([controls]) {
+  display: none;
+  height: 0;
+}
+[hidden],
+template {
+  display: none;
+}
+a {
+  background-color: transparent;
+}
+a:active,
+a:hover {
+  outline: 0;
+}
+abbr[title] {
+  border-bottom: 1px dotted;
+}
+b,
+strong {
+  font-weight: bold;
+}
+dfn {
+  font-style: italic;
+}
+h1 {
+  margin: .67em 0;
+  font-size: 2em;
+}
+mark {
+  color: #000;
+  background: #ff0;
+}
+small {
+  font-size: 80%;
+}
+sub,
+sup {
+  position: relative;
+  font-size: 75%;
+  line-height: 0;
+  vertical-align: baseline;
+}
+sup {
+  top: -.5em;
+}
+sub {
+  bottom: -.25em;
+}
+img {
+  border: 0;
+}
+svg:not(:root) {
+  overflow: hidden;
+}
+figure {
+  margin: 1em 40px;
+}
+hr {
+  height: 0;
+  -webkit-box-sizing: content-box;
+     -moz-box-sizing: content-box;
+          box-sizing: content-box;
+}
+pre {
+  overflow: auto;
+}
+code,
+kbd,
+pre,
+samp {
+  font-family: monospace, monospace;
+  font-size: 1em;
+}
+button,
+input,
+optgroup,
+select,
+textarea {
+  margin: 0;
+  font: inherit;
+  color: inherit;
+}
+button {
+  overflow: visible;
+}
+button,
+select {
+  text-transform: none;
+}
+button,
+html input[type="button"],
+input[type="reset"],
+input[type="submit"] {
+  -webkit-appearance: button;
+  cursor: pointer;
+}
+button[disabled],
+html input[disabled] {
+  cursor: default;
+}
+button::-moz-focus-inner,
+input::-moz-focus-inner {
+  padding: 0;
+  border: 0;
+}
+input {
+  line-height: normal;
+}
+input[type="checkbox"],
+input[type="radio"] {
+  -webkit-box-sizing: border-box;
+     -moz-box-sizing: border-box;
+          box-sizing: border-box;
+  padding: 0;
+}
+input[type="number"]::-webkit-inner-spin-button,
+input[type="number"]::-webkit-outer-spin-button {
+  height: auto;
+}
+input[type="search"] {
+  -webkit-box-sizing: content-box;
+     -moz-box-sizing: content-box;
+          box-sizing: content-box;
+  -webkit-appearance: textfield;
+}
+input[type="search"]::-webkit-search-cancel-button,
+input[type="search"]::-webkit-search-decoration {
+  -webkit-appearance: none;
+}
+fieldset {
+  padding: .35em .625em .75em;
+  margin: 0 2px;
+  border: 1px solid #c0c0c0;
+}
+legend {
+  padding: 0;
+  border: 0;
+}
+textarea {
+  overflow: auto;
+}
+optgroup {
+  font-weight: bold;
+}
+table {
+  border-spacing: 0;
+  border-collapse: collapse;
+}
+td,
+th {
+  padding: 0;
+}
+/*! Source: https://github.com/h5bp/html5-boilerplate/blob/master/src/css/main.css */
+@media print {
+  *,
+  *:before,
+  *:after {
+    color: #000 !important;
+    text-shadow: none !important;
+    background: transparent !important;
+    -webkit-box-shadow: none !important;
+            box-shadow: none !important;
+  }
+  a,
+  a:visited {
+    text-decoration: underline;
+  }
+  a[href]:after {
+    content: " (" attr(href) ")";
+  }
+  abbr[title]:after {
+    content: " (" attr(title) ")";
+  }
+  a[href^="#"]:after,
+  a[href^="javascript:"]:after {
+    content: "";
+  }
+  pre,
+  blockquote {
+    border: 1px solid #999;
+
+    page-break-inside: avoid;
+  }
+  thead {
+    display: table-header-group;
+  }
+  tr,
+  img {
+    page-break-inside: avoid;
+  }
+  img {
+    max-width: 100% !important;
+  }
+  p,
+  h2,
+  h3 {
+    orphans: 3;
+    widows: 3;
+  }
+  h2,
+  h3 {
+    page-break-after: avoid;
+  }
+  .navbar {
+    display: none;
+  }
+  .btn > .caret,
+  .dropup > .btn > .caret {
+    border-top-color: #000 !important;
+  }
+  .label {
+    border: 1px solid #000;
+  }
+  .table {
+    border-collapse: collapse !important;
+  }
+  .table td,
+  .table th {
+    background-color: #fff !important;
+  }
+  .table-bordered th,
+  .table-bordered td {
+    border: 1px solid #ddd !important;
+  }
+}
+@font-face {
+  font-family: 'Glyphicons Halflings';
+
+  src: url('../fonts/glyphicons-halflings-regular.eot');
+  src: url('../fonts/glyphicons-halflings-regular.eot?#iefix') format('embedded-opentype'), url('../fonts/glyphicons-halflings-regular.woff2') format('woff2'), url('../fonts/glyphicons-halflings-regular.woff') format('woff'), url('../fonts/glyphicons-halflings-regular.ttf') format('truetype'), url('../fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregular') format('svg');
+}
+.glyphicon {
+  position: relative;
+  top: 1px;
+  display: inline-block;
+  font-family: 'Glyphicons Halflings';
+  font-style: normal;
+  font-weight: normal;
+  line-height: 1;
+
+  -webkit-font-smoothing: antialiased;
+  -moz-osx-font-smoothing: grayscale;
+}
+.glyphicon-asterisk:before {
+  content: "\002a";
+}
+.glyphicon-plus:before {
+  content: "\002b";
+}
+.glyphicon-euro:before,
+.glyphicon-eur:before {
+  content: "\20ac";
+}
+.glyphicon-minus:before {
+  content: "\2212";
+}
+.glyphicon-cloud:before {
+  content: "\2601";
+}
+.glyphicon-envelope:before {
+  content: "\2709";
+}
+.glyphicon-pencil:before {
+  content: "\270f";
+}
+.glyphicon-glass:before {
+  content: "\e001";
+}
+.glyphicon-music:before {
+  content: "\e002";
+}
+.glyphicon-search:before {
+  content: "\e003";
+}
+.glyphicon-heart:before {
+  content: "\e005";
+}
+.glyphicon-star:before {
+  content: "\e006";
+}
+.glyphicon-star-empty:before {
+  content: "\e007";
+}
+.glyphicon-user:before {
+  content: "\e008";
+}
+.glyphicon-film:before {
+  content: "\e009";
+}
+.glyphicon-th-large:before {
+  content: "\e010";
+}
+.glyphicon-th:before {
+  content: "\e011";
+}
+.glyphicon-th-list:before {
+  content: "\e012";
+}
+.glyphicon-ok:before {
+  content: "\e013";
+}
+.glyphicon-remove:before {
+  content: "\e014";
+}
+.glyphicon-zoom-in:before {
+  content: "\e015";
+}
+.glyphicon-zoom-out:before {
+  content: "\e016";
+}
+.glyphicon-off:before {
+  content: "\e017";
+}
+.glyphicon-signal:before {
+  content: "\e018";
+}
+.glyphicon-cog:before {
+  content: "\e019";
+}
+.glyphicon-trash:before {
+  content: "\e020";
+}
+.glyphicon-home:before {
+  content: "\e021";
+}
+.glyphicon-file:before {
+  content: "\e022";
+}
+.glyphicon-time:before {
+  content: "\e023";
+}
+.glyphicon-road:before {
+  content: "\e024";
+}
+.glyphicon-download-alt:before {
+  content: "\e025";
+}
+.glyphicon-download:before {
+  content: "\e026";
+}
+.glyphicon-upload:before {
+  content: "\e027";
+}
+.glyphicon-inbox:before {
+  content: "\e028";
+}
+.glyphicon-play-circle:before {
+  content: "\e029";
+}
+.glyphicon-repeat:before {
+  content: "\e030";
+}
+.glyphicon-refresh:before {
+  content: "\e031";
+}
+.glyphicon-list-alt:before {
+  content: "\e032";
+}
+.glyphicon-lock:before {
+  content: "\e033";
+}
+.glyphicon-flag:before {
+  content: "\e034";
+}
+.glyphicon-headphones:before {
+  content: "\e035";
+}
+.glyphicon-volume-off:before {
+  content: "\e036";
+}
+.glyphicon-volume-down:before {
+  content: "\e037";
+}
+.glyphicon-volume-up:before {
+  content: "\e038";
+}
+.glyphicon-qrcode:before {
+  content: "\e039";
+}
+.glyphicon-barcode:before {
+  content: "\e040";
+}
+.glyphicon-tag:before {
+  content: "\e041";
+}
+.glyphicon-tags:before {
+  content: "\e042";
+}
+.glyphicon-book:before {
+  content: "\e043";
+}
+.glyphicon-bookmark:before {
+  content: "\e044";
+}
+.glyphicon-print:before {
+  content: "\e045";
+}
+.glyphicon-camera:before {
+  content: "\e046";
+}
+.glyphicon-font:before {
+  content: "\e047";
+}
+.glyphicon-bold:before {
+  content: "\e048";
+}
+.glyphicon-italic:before {
+  content: "\e049";
+}
+.glyphicon-text-height:before {
+  content: "\e050";
+}
+.glyphicon-text-width:before {
+  content: "\e051";
+}
+.glyphicon-align-left:before {
+  content: "\e052";
+}
+.glyphicon-align-center:before {
+  content: "\e053";
+}
+.glyphicon-align-right:before {
+  content: "\e054";
+}
+.glyphicon-align-justify:before {
+  content: "\e055";
+}
+.glyphicon-list:before {
+  content: "\e056";
+}
+.glyphicon-indent-left:before {
+  content: "\e057";
+}
+.glyphicon-indent-right:before {
+  content: "\e058";
+}
+.glyphicon-facetime-video:before {
+  content: "\e059";
+}
+.glyphicon-picture:before {
+  content: "\e060";
+}
+.glyphicon-map-marker:before {
+  content: "\e062";
+}
+.glyphicon-adjust:before {
+  content: "\e063";
+}
+.glyphicon-tint:before {
+  content: "\e064";
+}
+.glyphicon-edit:before {
+  content: "\e065";
+}
+.glyphicon-share:before {
+  content: "\e066";
+}
+.glyphicon-check:before {
+  content: "\e067";
+}
+.glyphicon-move:before {
+  content: "\e068";
+}
+.glyphicon-step-backward:before {
+  content: "\e069";
+}
+.glyphicon-fast-backward:before {
+  content: "\e070";
+}
+.glyphicon-backward:before {
+  content: "\e071";
+}
+.glyphicon-play:before {
+  content: "\e072";
+}
+.glyphicon-pause:before {
+  content: "\e073";
+}
+.glyphicon-stop:before {
+  content: "\e074";
+}
+.glyphicon-forward:before {
+  content: "\e075";
+}
+.glyphicon-fast-forward:before {
+  content: "\e076";
+}
+.glyphicon-step-forward:before {
+  content: "\e077";
+}
+.glyphicon-eject:before {
+  content: "\e078";
+}
+.glyphicon-chevron-left:before {
+  content: "\e079";
+}
+.glyphicon-chevron-right:before {
+  content: "\e080";
+}
+.glyphicon-plus-sign:before {
+  content: "\e081";
+}
+.glyphicon-minus-sign:before {
+  content: "\e082";
+}
+.glyphicon-remove-sign:before {
+  content: "\e083";
+}
+.glyphicon-ok-sign:before {
+  content: "\e084";
+}
+.glyphicon-question-sign:before {
+  content: "\e085";
+}
+.glyphicon-info-sign:before {
+  content: "\e086";
+}
+.glyphicon-screenshot:before {
+  content: "\e087";
+}
+.glyphicon-remove-circle:before {
+  content: "\e088";
+}
+.glyphicon-ok-circle:before {
+  content: "\e089";
+}
+.glyphicon-ban-circle:before {
+  content: "\e090";
+}
+.glyphicon-arrow-left:before {
+  content: "\e091";
+}
+.glyphicon-arrow-right:before {
+  content: "\e092";
+}
+.glyphicon-arrow-up:before {
+  content: "\e093";
+}
+.glyphicon-arrow-down:before {
+  content: "\e094";
+}
+.glyphicon-share-alt:before {
+  content: "\e095";
+}
+.glyphicon-resize-full:before {
+  content: "\e096";
+}
+.glyphicon-resize-small:before {
+  content: "\e097";
+}
+.glyphicon-exclamation-sign:before {
+  content: "\e101";
+}
+.glyphicon-gift:before {
+  content: "\e102";
+}
+.glyphicon-leaf:before {
+  content: "\e103";
+}
+.glyphicon-fire:before {
+  content: "\e104";
+}
+.glyphicon-eye-open:before {
+  content: "\e105";
+}
+.glyphicon-eye-close:before {
+  content: "\e106";
+}
+.glyphicon-warning-sign:before {
+  content: "\e107";
+}
+.glyphicon-plane:before {
+  content: "\e108";
+}
+.glyphicon-calendar:before {
+  content: "\e109";
+}
+.glyphicon-random:before {
+  content: "\e110";
+}
+.glyphicon-comment:before {
+  content: "\e111";
+}
+.glyphicon-magnet:before {
+  content: "\e112";
+}
+.glyphicon-chevron-up:before {
+  content: "\e113";
+}
+.glyphicon-chevron-down:before {
+  content: "\e114";
+}
+.glyphicon-retweet:before {
+  content: "\e115";
+}
+.glyphicon-shopping-cart:before {
+  content: "\e116";
+}
+.glyphicon-folder-close:before {
+  content: "\e117";
+}
+.glyphicon-folder-open:before {
+  content: "\e118";
+}
+.glyphicon-resize-vertical:before {
+  content: "\e119";
+}
+.glyphicon-resize-horizontal:before {
+  content: "\e120";
+}
+.glyphicon-hdd:before {
+  content: "\e121";
+}
+.glyphicon-bullhorn:before {
+  content: "\e122";
+}
+.glyphicon-bell:before {
+  content: "\e123";
+}
+.glyphicon-certificate:before {
+  content: "\e124";
+}
+.glyphicon-thumbs-up:before {
+  content: "\e125";
+}
+.glyphicon-thumbs-down:before {
+  content: "\e126";
+}
+.glyphicon-hand-right:before {
+  content: "\e127";
+}
+.glyphicon-hand-left:before {
+  content: "\e128";
+}
+.glyphicon-hand-up:before {
+  content: "\e129";
+}
+.glyphicon-hand-down:before {
+  content: "\e130";
+}
+.glyphicon-circle-arrow-right:before {
+  content: "\e131";
+}
+.glyphicon-circle-arrow-left:before {
+  content: "\e132";
+}
+.glyphicon-circle-arrow-up:before {
+  content: "\e133";
+}
+.glyphicon-circle-arrow-down:before {
+  content: "\e134";
+}
+.glyphicon-globe:before {
+  content: "\e135";
+}
+.glyphicon-wrench:before {
+  content: "\e136";
+}
+.glyphicon-tasks:before {
+  content: "\e137";
+}
+.glyphicon-filter:before {
+  content: "\e138";
+}
+.glyphicon-briefcase:before {
+  content: "\e139";
+}
+.glyphicon-fullscreen:before {
+  content: "\e140";
+}
+.glyphicon-dashboard:before {
+  content: "\e141";
+}
+.glyphicon-paperclip:before {
+  content: "\e142";
+}
+.glyphicon-heart-empty:before {
+  content: "\e143";
+}
+.glyphicon-link:before {
+  content: "\e144";
+}
+.glyphicon-phone:before {
+  content: "\e145";
+}
+.glyphicon-pushpin:before {
+  content: "\e146";
+}
+.glyphicon-usd:before {
+  content: "\e148";
+}
+.glyphicon-gbp:before {
+  content: "\e149";
+}
+.glyphicon-sort:before {
+  content: "\e150";
+}
+.glyphicon-sort-by-alphabet:before {
+  content: "\e151";
+}
+.glyphicon-sort-by-alphabet-alt:before {
+  content: "\e152";
+}
+.glyphicon-sort-by-order:before {
+  content: "\e153";
+}
+.glyphicon-sort-by-order-alt:before {
+  content: "\e154";
+}
+.glyphicon-sort-by-attributes:before {
+  content: "\e155";
+}
+.glyphicon-sort-by-attributes-alt:before {
+  content: "\e156";
+}
+.glyphicon-unchecked:before {
+  content: "\e157";
+}
+.glyphicon-expand:before {
+  content: "\e158";
+}
+.glyphicon-collapse-down:before {
+  content: "\e159";
+}
+.glyphicon-collapse-up:before {
+  content: "\e160";
+}
+.glyphicon-log-in:before {
+  content: "\e161";
+}
+.glyphicon-flash:before {
+  content: "\e162";
+}
+.glyphicon-log-out:before {
+  content: "\e163";
+}
+.glyphicon-new-window:before {
+  content: "\e164";
+}
+.glyphicon-record:before {
+  content: "\e165";
+}
+.glyphicon-save:before {
+  content: "\e166";
+}
+.glyphicon-open:before {
+  content: "\e167";
+}
+.glyphicon-saved:before {
+  content: "\e168";
+}
+.glyphicon-import:before {
+  content: "\e169";
+}
+.glyphicon-export:before {
+  content: "\e170";
+}
+.glyphicon-send:before {
+  content: "\e171";
+}
+.glyphicon-floppy-disk:before {
+  content: "\e172";
+}
+.glyphicon-floppy-saved:before {
+  content: "\e173";
+}
+.glyphicon-floppy-remove:before {
+  content: "\e174";
+}
+.glyphicon-floppy-save:before {
+  content: "\e175";
+}
+.glyphicon-floppy-open:before {
+  content: "\e176";
+}
+.glyphicon-credit-card:before {
+  content: "\e177";
+}
+.glyphicon-transfer:before {
+  content: "\e178";
+}
+.glyphicon-cutlery:before {
+  content: "\e179";
+}
+.glyphicon-header:before {
+  content: "\e180";
+}
+.glyphicon-compressed:before {
+  content: "\e181";
+}
+.glyphicon-earphone:before {
+  content: "\e182";
+}
+.glyphicon-phone-alt:before {
+  content: "\e183";
+}
+.glyphicon-tower:before {
+  content: "\e184";
+}
+.glyphicon-stats:before {
+  content: "\e185";
+}
+.glyphicon-sd-video:before {
+  content: "\e186";
+}
+.glyphicon-hd-video:before {
+  content: "\e187";
+}
+.glyphicon-subtitles:before {
+  content: "\e188";
+}
+.glyphicon-sound-stereo:before {
+  content: "\e189";
+}
+.glyphicon-sound-dolby:before {
+  content: "\e190";
+}
+.glyphicon-sound-5-1:before {
+  content: "\e191";
+}
+.glyphicon-sound-6-1:before {
+  content: "\e192";
+}
+.glyphicon-sound-7-1:before {
+  content: "\e193";
+}
+.glyphicon-copyright-mark:before {
+  content: "\e194";
+}
+.glyphicon-registration-mark:before {
+  content: "\e195";
+}
+.glyphicon-cloud-download:before {
+  content: "\e197";
+}
+.glyphicon-cloud-upload:before {
+  content: "\e198";
+}
+.glyphicon-tree-conifer:before {
+  content: "\e199";
+}
+.glyphicon-tree-deciduous:before {
+  content: "\e200";
+}
+.glyphicon-cd:before {
+  content: "\e201";
+}
+.glyphicon-save-file:before {
+  content: "\e202";
+}
+.glyphicon-open-file:before {
+  content: "\e203";
+}
+.glyphicon-level-up:before {
+  content: "\e204";
+}
+.glyphicon-copy:before {
+  content: "\e205";
+}
+.glyphicon-paste:before {
+  content: "\e206";
+}
+.glyphicon-alert:before {
+  content: "\e209";
+}
+.glyphicon-equalizer:before {
+  content: "\e210";
+}
+.glyphicon-king:before {
+  content: "\e211";
+}
+.glyphicon-queen:before {
+  content: "\e212";
+}
+.glyphicon-pawn:before {
+  content: "\e213";
+}
+.glyphicon-bishop:before {
+  content: "\e214";
+}
+.glyphicon-knight:before {
+  content: "\e215";
+}
+.glyphicon-baby-formula:before {
+  content: "\e216";
+}
+.glyphicon-tent:before {
+  content: "\26fa";
+}
+.glyphicon-blackboard:before {
+  content: "\e218";
+}
+.glyphicon-bed:before {
+  content: "\e219";
+}
+.glyphicon-apple:before {
+  content: "\f8ff";
+}
+.glyphicon-erase:before {
+  content: "\e221";
+}
+.glyphicon-hourglass:before {
+  content: "\231b";
+}
+.glyphicon-lamp:before {
+  content: "\e223";
+}
+.glyphicon-duplicate:before {
+  content: "\e224";
+}
+.glyphicon-piggy-bank:before {
+  content: "\e225";
+}
+.glyphicon-scissors:before {
+  content: "\e226";
+}
+.glyphicon-bitcoin:before {
+  content: "\e227";
+}
+.glyphicon-btc:before {
+  content: "\e227";
+}
+.glyphicon-xbt:before {
+  content: "\e227";
+}
+.glyphicon-yen:before {
+  content: "\00a5";
+}
+.glyphicon-jpy:before {
+  content: "\00a5";
+}
+.glyphicon-ruble:before {
+  content: "\20bd";
+}
+.glyphicon-rub:before {
+  content: "\20bd";
+}
+.glyphicon-scale:before {
+  content: "\e230";
+}
+.glyphicon-ice-lolly:before {
+  content: "\e231";
+}
+.glyphicon-ice-lolly-tasted:before {
+  content: "\e232";
+}
+.glyphicon-education:before {
+  content: "\e233";
+}
+.glyphicon-option-horizontal:before {
+  content: "\e234";
+}
+.glyphicon-option-vertical:before {
+  content: "\e235";
+}
+.glyphicon-menu-hamburger:before {
+  content: "\e236";
+}
+.glyphicon-modal-window:before {
+  content: "\e237";
+}
+.glyphicon-oil:before {
+  content: "\e238";
+}
+.glyphicon-grain:before {
+  content: "\e239";
+}
+.glyphicon-sunglasses:before {
+  content: "\e240";
+}
+.glyphicon-text-size:before {
+  content: "\e241";
+}
+.glyphicon-text-color:before {
+  content: "\e242";
+}
+.glyphicon-text-background:before {
+  content: "\e243";
+}
+.glyphicon-object-align-top:before {
+  content: "\e244";
+}
+.glyphicon-object-align-bottom:before {
+  content: "\e245";
+}
+.glyphicon-object-align-horizontal:before {
+  content: "\e246";
+}
+.glyphicon-object-align-left:before {
+  content: "\e247";
+}
+.glyphicon-object-align-vertical:before {
+  content: "\e248";
+}
+.glyphicon-object-align-right:before {
+  content: "\e249";
+}
+.glyphicon-triangle-right:before {
+  content: "\e250";
+}
+.glyphicon-triangle-left:before {
+  content: "\e251";
+}
+.glyphicon-triangle-bottom:before {
+  content: "\e252";
+}
+.glyphicon-triangle-top:before {
+  content: "\e253";
+}
+.glyphicon-console:before {
+  content: "\e254";
+}
+.glyphicon-superscript:before {
+  content: "\e255";
+}
+.glyphicon-subscript:before {
+  content: "\e256";
+}
+.glyphicon-menu-left:before {
+  content: "\e257";
+}
+.glyphicon-menu-right:before {
+  content: "\e258";
+}
+.glyphicon-menu-down:before {
+  content: "\e259";
+}
+.glyphicon-menu-up:before {
+  content: "\e260";
+}
+* {
+  -webkit-box-sizing: border-box;
+     -moz-box-sizing: border-box;
+          box-sizing: border-box;
+}
+*:before,
+*:after {
+  -webkit-box-sizing: border-box;
+     -moz-box-sizing: border-box;
+          box-sizing: border-box;
+}
+html {
+  font-size: 10px;
+
+  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
+}
+body {
+  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
+  font-size: 14px;
+  line-height: 1.42857143;
+  color: #333;
+  background-color: #fff;
+}
+input,
+button,
+select,
+textarea {
+  font-family: inherit;
+  font-size: inherit;
+  line-height: inherit;
+}
+a {
+  color: #337ab7;
+  text-decoration: none;
+}
+a:hover,
+a:focus {
+  color: #23527c;
+  text-decoration: underline;
+}
+a:focus {
+  outline: thin dotted;
+  outline: 5px auto -webkit-focus-ring-color;
+  outline-offset: -2px;
+}
+figure {
+  margin: 0;
+}
+img {
+  vertical-align: middle;
+}
+.img-responsive,
+.thumbnail > img,
+.thumbnail a > img,
+.carousel-inner > .item > img,
+.carousel-inner > .item > a > img {
+  display: block;
+  max-width: 100%;
+  height: auto;
+}
+.img-rounded {
+  border-radius: 6px;
+}
+.img-thumbnail {
+  display: inline-block;
+  max-width: 100%;
+  height: auto;
+  padding: 4px;
+  line-height: 1.42857143;
+  background-color: #fff;
+  border: 1px solid #ddd;
+  border-radius: 4px;
+  -webkit-transition: all .2s ease-in-out;
+       -o-transition: all .2s ease-in-out;
+          transition: all .2s ease-in-out;
+}
+.img-circle {
+  border-radius: 50%;
+}
+hr {
+  margin-top: 20px;
+  margin-bottom: 20px;
+  border: 0;
+  border-top: 1px solid #eee;
+}
+.sr-only {
+  position: absolute;
+  width: 1px;
+  height: 1px;
+  padding: 0;
+  margin: -1px;
+  overflow: hidden;
+  clip: rect(0, 0, 0, 0);
+  border: 0;
+}
+.sr-only-focusable:active,
+.sr-only-focusable:focus {
+  position: static;
+  width: auto;
+  height: auto;
+  margin: 0;
+  overflow: visible;
+  clip: auto;
+}
+[role="button"] {
+  cursor: pointer;
+}
+h1,
+h2,
+h3,
+h4,
+h5,
+h6,
+.h1,
+.h2,
+.h3,
+.h4,
+.h5,
+.h6 {
+  font-family: inherit;
+  font-weight: 500;
+  line-height: 1.1;
+  color: inherit;
+}
+h1 small,
+h2 small,
+h3 small,
+h4 small,
+h5 small,
+h6 small,
+.h1 small,
+.h2 small,
+.h3 small,
+.h4 small,
+.h5 small,
+.h6 small,
+h1 .small,
+h2 .small,
+h3 .small,
+h4 .small,
+h5 .small,
+h6 .small,
+.h1 .small,
+.h2 .small,
+.h3 .small,
+.h4 .small,
+.h5 .small,
+.h6 .small {
+  font-weight: normal;
+  line-height: 1;
+  color: #777;
+}
+h1,
+.h1,
+h2,
+.h2,
+h3,
+.h3 {
+  margin-top: 20px;
+  margin-bottom: 10px;
+}
+h1 small,
+.h1 small,
+h2 small,
+.h2 small,
+h3 small,
+.h3 small,
+h1 .small,
+.h1 .small,
+h2 .small,
+.h2 .small,
+h3 .small,
+.h3 .small {
+  font-size: 65%;
+}
+h4,
+.h4,
+h5,
+.h5,
+h6,
+.h6 {
+  margin-top: 10px;
+  margin-bottom: 10px;
+}
+h4 small,
+.h4 small,
+h5 small,
+.h5 small,
+h6 small,
+.h6 small,
+h4 .small,
+.h4 .small,
+h5 .small,
+.h5 .small,
+h6 .small,
+.h6 .small {
+  font-size: 75%;
+}
+h1,
+.h1 {
+  font-size: 36px;
+}
+h2,
+.h2 {
+  font-size: 30px;
+}
+h3,
+.h3 {
+  font-size: 24px;
+}
+h4,
+.h4 {
+  font-size: 18px;
+}
+h5,
+.h5 {
+  font-size: 14px;
+}
+h6,
+.h6 {
+  font-size: 12px;
+}
+p {
+  margin: 0 0 10px;
+}
+.lead {
+  margin-bottom: 20px;
+  font-size: 16px;
+  font-weight: 300;
+  line-height: 1.4;
+}
+@media (min-width: 768px) {
+  .lead {
+    font-size: 21px;
+  }
+}
+small,
+.small {
+  font-size: 85%;
+}
+mark,
+.mark {
+  padding: .2em;
+  background-color: #fcf8e3;
+}
+.text-left {
+  text-align: left;
+}
+.text-right {
+  text-align: right;
+}
+.text-center {
+  text-align: center;
+}
+.text-justify {
+  text-align: justify;
+}
+.text-nowrap {
+  white-space: nowrap;
+}
+.text-lowercase {
+  text-transform: lowercase;
+}
+.text-uppercase {
+  text-transform: uppercase;
+}
+.text-capitalize {
+  text-transform: capitalize;
+}
+.text-muted {
+  color: #777;
+}
+.text-primary {
+  color: #337ab7;
+}
+a.text-primary:hover,
+a.text-primary:focus {
+  color: #286090;
+}
+.text-success {
+  color: #3c763d;
+}
+a.text-success:hover,
+a.text-success:focus {
+  color: #2b542c;
+}
+.text-info {
+  color: #31708f;
+}
+a.text-info:hover,
+a.text-info:focus {
+  color: #245269;
+}
+.text-warning {
+  color: #8a6d3b;
+}
+a.text-warning:hover,
+a.text-warning:focus {
+  color: #66512c;
+}
+.text-danger {
+  color: #a94442;
+}
+a.text-danger:hover,
+a.text-danger:focus {
+  color: #843534;
+}
+.bg-primary {
+  color: #fff;
+  background-color: #337ab7;
+}
+a.bg-primary:hover,
+a.bg-primary:focus {
+  background-color: #286090;
+}
+.bg-success {
+  background-color: #dff0d8;
+}
+a.bg-success:hover,
+a.bg-success:focus {
+  background-color: #c1e2b3;
+}
+.bg-info {
+  background-color: #d9edf7;
+}
+a.bg-info:hover,
+a.bg-info:focus {
+  background-color: #afd9ee;
+}
+.bg-warning {
+  background-color: #fcf8e3;
+}
+a.bg-warning:hover,
+a.bg-warning:focus {
+  background-color: #f7ecb5;
+}
+.bg-danger {
+  background-color: #f2dede;
+}
+a.bg-danger:hover,
+a.bg-danger:focus {
+  background-color: #e4b9b9;
+}
+.page-header {
+  padding-bottom: 9px;
+  margin: 40px 0 20px;
+  border-bottom: 1px solid #eee;
+}
+ul,
+ol {
+  margin-top: 0;
+  margin-bottom: 10px;
+}
+ul ul,
+ol ul,
+ul ol,
+ol ol {
+  margin-bottom: 0;
+}
+.list-unstyled {
+  padding-left: 0;
+  list-style: none;
+}
+.list-inline {
+  padding-left: 0;
+  margin-left: -5px;
+  list-style: none;
+}
+.list-inline > li {
+  display: inline-block;
+  padding-right: 5px;
+  padding-left: 5px;
+}
+dl {
+  margin-top: 0;
+  margin-bottom: 20px;
+}
+dt,
+dd {
+  line-height: 1.42857143;
+}
+dt {
+  font-weight: bold;
+}
+dd {
+  margin-left: 0;
+}
+@media (min-width: 768px) {
+  .dl-horizontal dt {
+    float: left;
+    width: 160px;
+    overflow: hidden;
+    clear: left;
+    text-align: right;
+    text-overflow: ellipsis;
+    white-space: nowrap;
+  }
+  .dl-horizontal dd {
+    margin-left: 180px;
+  }
+}
+abbr[title],
+abbr[data-original-title] {
+  cursor: help;
+  border-bottom: 1px dotted #777;
+}
+.initialism {
+  font-size: 90%;
+  text-transform: uppercase;
+}
+blockquote {
+  padding: 10px 20px;
+  margin: 0 0 20px;
+  font-size: 17.5px;
+  border-left: 5px solid #eee;
+}
+blockquote p:last-child,
+blockquote ul:last-child,
+blockquote ol:last-child {
+  margin-bottom: 0;
+}
+blockquote footer,
+blockquote small,
+blockquote .small {
+  display: block;
+  font-size: 80%;
+  line-height: 1.42857143;
+  color: #777;
+}
+blockquote footer:before,
+blockquote small:before,
+blockquote .small:before {
+  content: '\2014 \00A0';
+}
+.blockquote-reverse,
+blockquote.pull-right {
+  padding-right: 15px;
+  padding-left: 0;
+  text-align: right;
+  border-right: 5px solid #eee;
+  border-left: 0;
+}
+.blockquote-reverse footer:before,
+blockquote.pull-right footer:before,
+.blockquote-reverse small:before,
+blockquote.pull-right small:before,
+.blockquote-reverse .small:before,
+blockquote.pull-right .small:before {
+  content: '';
+}
+.blockquote-reverse footer:after,
+blockquote.pull-right footer:after,
+.blockquote-reverse small:after,
+blockquote.pull-right small:after,
+.blockquote-reverse .small:after,
+blockquote.pull-right .small:after {
+  content: '\00A0 \2014';
+}
+address {
+  margin-bottom: 20px;
+  font-style: normal;
+  line-height: 1.42857143;
+}
+code,
+kbd,
+pre,
+samp {
+  font-family: Menlo, Monaco, Consolas, "Courier New", monospace;
+}
+code {
+  padding: 2px 4px;
+  font-size: 90%;
+  color: #c7254e;
+  background-color: #f9f2f4;
+  border-radius: 4px;
+}
+kbd {
+  padding: 2px 4px;
+  font-size: 90%;
+  color: #fff;
+  background-color: #333;
+  border-radius: 3px;
+  -webkit-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, .25);
+          box-shadow: inset 0 -1px 0 rgba(0, 0, 0, .25);
+}
+kbd kbd {
+  padding: 0;
+  font-size: 100%;
+  font-weight: bold;
+  -webkit-box-shadow: none;
+          box-shadow: none;
+}
+pre {
+  display: block;
+  padding: 9.5px;
+  margin: 0 0 10px;
+  font-size: 13px;
+  line-height: 1.42857143;
+  color: #333;
+  word-break: break-all;
+  word-wrap: break-word;
+  background-color: #f5f5f5;
+  border: 1px solid #ccc;
+  border-radius: 4px;
+}
+pre code {
+  padding: 0;
+  font-size: inherit;
+  color: inherit;
+  white-space: pre-wrap;
+  background-color: transparent;
+  border-radius: 0;
+}
+.pre-scrollable {
+  max-height: 340px;
+  overflow-y: scroll;
+}
+.container {
+  padding-right: 15px;
+  padding-left: 15px;
+  margin-right: auto;
+  margin-left: auto;
+}
+@media (min-width: 768px) {
+  .container {
+    width: 750px;
+  }
+}
+@media (min-width: 992px) {
+  .container {
+    width: 970px;
+  }
+}
+@media (min-width: 1200px) {
+  .container {
+    width: 1170px;
+  }
+}
+.container-fluid {
+  padding-right: 15px;
+  padding-left: 15px;
+  margin-right: auto;
+  margin-left: auto;
+}
+.row {
+  margin-right: -15px;
+  margin-left: -15px;
+}
+.col-xs-1, .col-sm-1, .col-md-1, .col-lg-1, .col-xs-2, .col-sm-2, .col-md-2, .col-lg-2, .col-xs-3, .col-sm-3, .col-md-3, .col-lg-3, .col-xs-4, .col-sm-4, .col-md-4, .col-lg-4, .col-xs-5, .col-sm-5, .col-md-5, .col-lg-5, .col-xs-6, .col-sm-6, .col-md-6, .col-lg-6, .col-xs-7, .col-sm-7, .col-md-7, .col-lg-7, .col-xs-8, .col-sm-8, .col-md-8, .col-lg-8, .col-xs-9, .col-sm-9, .col-md-9, .col-lg-9, .col-xs-10, .col-sm-10, .col-md-10, .col-lg-10, .col-xs-11, .col-sm-11, .col-md-11, .col-lg-11, .col-xs-12, .col-sm-12, .col-md-12, .col-lg-12 {
+  position: relative;
+  min-height: 1px;
+  padding-right: 15px;
+  padding-left: 15px;
+}
+.col-xs-1, .col-xs-2, .col-xs-3, .col-xs-4, .col-xs-5, .col-xs-6, .col-xs-7, .col-xs-8, .col-xs-9, .col-xs-10, .col-xs-11, .col-xs-12 {
+  float: left;
+}
+.col-xs-12 {
+  width: 100%;
+}
+.col-xs-11 {
+  width: 91.66666667%;
+}
+.col-xs-10 {
+  width: 83.33333333%;
+}
+.col-xs-9 {
+  width: 75%;
+}
+.col-xs-8 {
+  width: 66.66666667%;
+}
+.col-xs-7 {
+  width: 58.33333333%;
+}
+.col-xs-6 {
+  width: 50%;
+}
+.col-xs-5 {
+  width: 41.66666667%;
+}
+.col-xs-4 {
+  width: 33.33333333%;
+}
+.col-xs-3 {
+  width: 25%;
+}
+.col-xs-2 {
+  width: 16.66666667%;
+}
+.col-xs-1 {
+  width: 8.33333333%;
+}
+.col-xs-pull-12 {
+  right: 100%;
+}
+.col-xs-pull-11 {
+  right: 91.66666667%;
+}
+.col-xs-pull-10 {
+  right: 83.33333333%;
+}
+.col-xs-pull-9 {
+  right: 75%;
+}
+.col-xs-pull-8 {
+  right: 66.66666667%;
+}
+.col-xs-pull-7 {
+  right: 58.33333333%;
+}
+.col-xs-pull-6 {
+  right: 50%;
+}
+.col-xs-pull-5 {
+  right: 41.66666667%;
+}
+.col-xs-pull-4 {
+  right: 33.33333333%;
+}
+.col-xs-pull-3 {
+  right: 25%;
+}
+.col-xs-pull-2 {
+  right: 16.66666667%;
+}
+.col-xs-pull-1 {
+  right: 8.33333333%;
+}
+.col-xs-pull-0 {
+  right: auto;
+}
+.col-xs-push-12 {
+  left: 100%;
+}
+.col-xs-push-11 {
+  left: 91.66666667%;
+}
+.col-xs-push-10 {
+  left: 83.33333333%;
+}
+.col-xs-push-9 {
+  left: 75%;
+}
+.col-xs-push-8 {
+  left: 66.66666667%;
+}
+.col-xs-push-7 {
+  left: 58.33333333%;
+}
+.col-xs-push-6 {
+  left: 50%;
+}
+.col-xs-push-5 {
+  left: 41.66666667%;
+}
+.col-xs-push-4 {
+  left: 33.33333333%;
+}
+.col-xs-push-3 {
+  left: 25%;
+}
+.col-xs-push-2 {
+  left: 16.66666667%;
+}
+.col-xs-push-1 {
+  left: 8.33333333%;
+}
+.col-xs-push-0 {
+  left: auto;
+}
+.col-xs-offset-12 {
+  margin-left: 100%;
+}
+.col-xs-offset-11 {
+  margin-left: 91.66666667%;
+}
+.col-xs-offset-10 {
+  margin-left: 83.33333333%;
+}
+.col-xs-offset-9 {
+  margin-left: 75%;
+}
+.col-xs-offset-8 {
+  margin-left: 66.66666667%;
+}
+.col-xs-offset-7 {
+  margin-left: 58.33333333%;
+}
+.col-xs-offset-6 {
+  margin-left: 50%;
+}
+.col-xs-offset-5 {
+  margin-left: 41.66666667%;
+}
+.col-xs-offset-4 {
+  margin-left: 33.33333333%;
+}
+.col-xs-offset-3 {
+  margin-left: 25%;
+}
+.col-xs-offset-2 {
+  margin-left: 16.66666667%;
+}
+.col-xs-offset-1 {
+  margin-left: 8.33333333%;
+}
+.col-xs-offset-0 {
+  margin-left: 0;
+}
+@media (min-width: 768px) {
+  .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12 {
+    float: left;
+  }
+  .col-sm-12 {
+    width: 100%;
+  }
+  .col-sm-11 {
+    width: 91.66666667%;
+  }
+  .col-sm-10 {
+    width: 83.33333333%;
+  }
+  .col-sm-9 {
+    width: 75%;
+  }
+  .col-sm-8 {
+    width: 66.66666667%;
+  }
+  .col-sm-7 {
+    width: 58.33333333%;
+  }
+  .col-sm-6 {
+    width: 50%;
+  }
+  .col-sm-5 {
+    width: 41.66666667%;
+  }
+  .col-sm-4 {
+    width: 33.33333333%;
+  }
+  .col-sm-3 {
+    width: 25%;
+  }
+  .col-sm-2 {
+    width: 16.66666667%;
+  }
+  .col-sm-1 {
+    width: 8.33333333%;
+  }
+  .col-sm-pull-12 {
+    right: 100%;
+  }
+  .col-sm-pull-11 {
+    right: 91.66666667%;
+  }
+  .col-sm-pull-10 {
+    right: 83.33333333%;
+  }
+  .col-sm-pull-9 {
+    right: 75%;
+  }
+  .col-sm-pull-8 {
+    right: 66.66666667%;
+  }
+  .col-sm-pull-7 {
+    right: 58.33333333%;
+  }
+  .col-sm-pull-6 {
+    right: 50%;
+  }
+  .col-sm-pull-5 {
+    right: 41.66666667%;
+  }
+  .col-sm-pull-4 {
+    right: 33.33333333%;
+  }
+  .col-sm-pull-3 {
+    right: 25%;
+  }
+  .col-sm-pull-2 {
+    right: 16.66666667%;
+  }
+  .col-sm-pull-1 {
+    right: 8.33333333%;
+  }
+  .col-sm-pull-0 {
+    right: auto;
+  }
+  .col-sm-push-12 {
+    left: 100%;
+  }
+  .col-sm-push-11 {
+    left: 91.66666667%;
+  }
+  .col-sm-push-10 {
+    left: 83.33333333%;
+  }
+  .col-sm-push-9 {
+    left: 75%;
+  }
+  .col-sm-push-8 {
+    left: 66.66666667%;
+  }
+  .col-sm-push-7 {
+    left: 58.33333333%;
+  }
+  .col-sm-push-6 {
+    left: 50%;
+  }
+  .col-sm-push-5 {
+    left: 41.66666667%;
+  }
+  .col-sm-push-4 {
+    left: 33.33333333%;
+  }
+  .col-sm-push-3 {
+    left: 25%;
+  }
+  .col-sm-push-2 {
+    left: 16.66666667%;
+  }
+  .col-sm-push-1 {
+    left: 8.33333333%;
+  }
+  .col-sm-push-0 {
+    left: auto;
+  }
+  .col-sm-offset-12 {
+    margin-left: 100%;
+  }
+  .col-sm-offset-11 {
+    margin-left: 91.66666667%;
+  }
+  .col-sm-offset-10 {
+    margin-left: 83.33333333%;
+  }
+  .col-sm-offset-9 {
+    margin-left: 75%;
+  }
+  .col-sm-offset-8 {
+    margin-left: 66.66666667%;
+  }
+  .col-sm-offset-7 {
+    margin-left: 58.33333333%;
+  }
+  .col-sm-offset-6 {
+    margin-left: 50%;
+  }
+  .col-sm-offset-5 {
+    margin-left: 41.66666667%;
+  }
+  .col-sm-offset-4 {
+    margin-left: 33.33333333%;
+  }
+  .col-sm-offset-3 {
+    margin-left: 25%;
+  }
+  .col-sm-offset-2 {
+    margin-left: 16.66666667%;
+  }
+  .col-sm-offset-1 {
+    margin-left: 8.33333333%;
+  }
+  .col-sm-offset-0 {
+    margin-left: 0;
+  }
+}
+@media (min-width: 992px) {
+  .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12 {
+    float: left;
+  }
+  .col-md-12 {
+    width: 100%;
+  }
+  .col-md-11 {
+    width: 91.66666667%;
+  }
+  .col-md-10 {
+    width: 83.33333333%;
+  }
+  .col-md-9 {
+    width: 75%;
+  }
+  .col-md-8 {
+    width: 66.66666667%;
+  }
+  .col-md-7 {
+    width: 58.33333333%;
+  }
+  .col-md-6 {
+    width: 50%;
+  }
+  .col-md-5 {
+    width: 41.66666667%;
+  }
+  .col-md-4 {
+    width: 33.33333333%;
+  }
+  .col-md-3 {
+    width: 25%;
+  }
+  .col-md-2 {
+    width: 16.66666667%;
+  }
+  .col-md-1 {
+    width: 8.33333333%;
+  }
+  .col-md-pull-12 {
+    right: 100%;
+  }
+  .col-md-pull-11 {
+    right: 91.66666667%;
+  }
+  .col-md-pull-10 {
+    right: 83.33333333%;
+  }
+  .col-md-pull-9 {
+    right: 75%;
+  }
+  .col-md-pull-8 {
+    right: 66.66666667%;
+  }
+  .col-md-pull-7 {
+    right: 58.33333333%;
+  }
+  .col-md-pull-6 {
+    right: 50%;
+  }
+  .col-md-pull-5 {
+    right: 41.66666667%;
+  }
+  .col-md-pull-4 {
+    right: 33.33333333%;
+  }
+  .col-md-pull-3 {
+    right: 25%;
+  }
+  .col-md-pull-2 {
+    right: 16.66666667%;
+  }
+  .col-md-pull-1 {
+    right: 8.33333333%;
+  }
+  .col-md-pull-0 {
+    right: auto;
+  }
+  .col-md-push-12 {
+    left: 100%;
+  }
+  .col-md-push-11 {
+    left: 91.66666667%;
+  }
+  .col-md-push-10 {
+    left: 83.33333333%;
+  }
+  .col-md-push-9 {
+    left: 75%;
+  }
+  .col-md-push-8 {
+    left: 66.66666667%;
+  }
+  .col-md-push-7 {
+    left: 58.33333333%;
+  }
+  .col-md-push-6 {
+    left: 50%;
+  }
+  .col-md-push-5 {
+    left: 41.66666667%;
+  }
+  .col-md-push-4 {
+    left: 33.33333333%;
+  }
+  .col-md-push-3 {
+    left: 25%;
+  }
+  .col-md-push-2 {
+    left: 16.66666667%;
+  }
+  .col-md-push-1 {
+    left: 8.33333333%;
+  }
+  .col-md-push-0 {
+    left: auto;
+  }
+  .col-md-offset-12 {
+    margin-left: 100%;
+  }
+  .col-md-offset-11 {
+    margin-left: 91.66666667%;
+  }
+  .col-md-offset-10 {
+    margin-left: 83.33333333%;
+  }
+  .col-md-offset-9 {
+    margin-left: 75%;
+  }
+  .col-md-offset-8 {
+    margin-left: 66.66666667%;
+  }
+  .col-md-offset-7 {
+    margin-left: 58.33333333%;
+  }
+  .col-md-offset-6 {
+    margin-left: 50%;
+  }
+  .col-md-offset-5 {
+    margin-left: 41.66666667%;
+  }
+  .col-md-offset-4 {
+    margin-left: 33.33333333%;
+  }
+  .col-md-offset-3 {
+    margin-left: 25%;
+  }
+  .col-md-offset-2 {
+    margin-left: 16.66666667%;
+  }
+  .col-md-offset-1 {
+    margin-left: 8.33333333%;
+  }
+  .col-md-offset-0 {
+    margin-left: 0;
+  }
+}
+@media (min-width: 1200px) {
+  .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12 {
+    float: left;
+  }
+  .col-lg-12 {
+    width: 100%;
+  }
+  .col-lg-11 {
+    width: 91.66666667%;
+  }
+  .col-lg-10 {
+    width: 83.33333333%;
+  }
+  .col-lg-9 {
+    width: 75%;
+  }
+  .col-lg-8 {
+    width: 66.66666667%;
+  }
+  .col-lg-7 {
+    width: 58.33333333%;
+  }
+  .col-lg-6 {
+    width: 50%;
+  }
+  .col-lg-5 {
+    width: 41.66666667%;
+  }
+  .col-lg-4 {
+    width: 33.33333333%;
+  }
+  .col-lg-3 {
+    width: 25%;
+  }
+  .col-lg-2 {
+    width: 16.66666667%;
+  }
+  .col-lg-1 {
+    width: 8.33333333%;
+  }
+  .col-lg-pull-12 {
+    right: 100%;
+  }
+  .col-lg-pull-11 {
+    right: 91.66666667%;
+  }
+  .col-lg-pull-10 {
+    right: 83.33333333%;
+  }
+  .col-lg-pull-9 {
+    right: 75%;
+  }
+  .col-lg-pull-8 {
+    right: 66.66666667%;
+  }
+  .col-lg-pull-7 {
+    right: 58.33333333%;
+  }
+  .col-lg-pull-6 {
+    right: 50%;
+  }
+  .col-lg-pull-5 {
+    right: 41.66666667%;
+  }
+  .col-lg-pull-4 {
+    right: 33.33333333%;
+  }
+  .col-lg-pull-3 {
+    right: 25%;
+  }
+  .col-lg-pull-2 {
+    right: 16.66666667%;
+  }
+  .col-lg-pull-1 {
+    right: 8.33333333%;
+  }
+  .col-lg-pull-0 {
+    right: auto;
+  }
+  .col-lg-push-12 {
+    left: 100%;
+  }
+  .col-lg-push-11 {
+    left: 91.66666667%;
+  }
+  .col-lg-push-10 {
+    left: 83.33333333%;
+  }
+  .col-lg-push-9 {
+    left: 75%;
+  }
+  .col-lg-push-8 {
+    left: 66.66666667%;
+  }
+  .col-lg-push-7 {
+    left: 58.33333333%;
+  }
+  .col-lg-push-6 {
+    left: 50%;
+  }
+  .col-lg-push-5 {
+    left: 41.66666667%;
+  }
+  .col-lg-push-4 {
+    left: 33.33333333%;
+  }
+  .col-lg-push-3 {
+    left: 25%;
+  }
+  .col-lg-push-2 {
+    left: 16.66666667%;
+  }
+  .col-lg-push-1 {
+    left: 8.33333333%;
+  }
+  .col-lg-push-0 {
+    left: auto;
+  }
+  .col-lg-offset-12 {
+    margin-left: 100%;
+  }
+  .col-lg-offset-11 {
+    margin-left: 91.66666667%;
+  }
+  .col-lg-offset-10 {
+    margin-left: 83.33333333%;
+  }
+  .col-lg-offset-9 {
+    margin-left: 75%;
+  }
+  .col-lg-offset-8 {
+    margin-left: 66.66666667%;
+  }
+  .col-lg-offset-7 {
+    margin-left: 58.33333333%;
+  }
+  .col-lg-offset-6 {
+    margin-left: 50%;
+  }
+  .col-lg-offset-5 {
+    margin-left: 41.66666667%;
+  }
+  .col-lg-offset-4 {
+    margin-left: 33.33333333%;
+  }
+  .col-lg-offset-3 {
+    margin-left: 25%;
+  }
+  .col-lg-offset-2 {
+    margin-left: 16.66666667%;
+  }
+  .col-lg-offset-1 {
+    margin-left: 8.33333333%;
+  }
+  .col-lg-offset-0 {
+    margin-left: 0;
+  }
+}
+table {
+  background-color: transparent;
+}
+caption {
+  padding-top: 8px;
+  padding-bottom: 8px;
+  color: #777;
+  text-align: left;
+}
+th {
+  text-align: left;
+}
+.table {
+  width: 100%;
+  max-width: 100%;
+  margin-bottom: 20px;
+}
+.table > thead > tr > th,
+.table > tbody > tr > th,
+.table > tfoot > tr > th,
+.table > thead > tr > td,
+.table > tbody > tr > td,
+.table > tfoot > tr > td {
+  padding: 8px;
+  line-height: 1.42857143;
+  vertical-align: top;
+  border-top: 1px solid #ddd;
+}
+.table > thead > tr > th {
+  vertical-align: bottom;
+  border-bottom: 2px solid #ddd;
+}
+.table > caption + thead > tr:first-child > th,
+.table > colgroup + thead > tr:first-child > th,
+.table > thead:first-child > tr:first-child > th,
+.table > caption + thead > tr:first-child > td,
+.table > colgroup + thead > tr:first-child > td,
+.table > thead:first-child > tr:first-child > td {
+  border-top: 0;
+}
+.table > tbody + tbody {
+  border-top: 2px solid #ddd;
+}
+.table .table {
+  background-color: #fff;
+}
+.table-condensed > thead > tr > th,
+.table-condensed > tbody > tr > th,
+.table-condensed > tfoot > tr > th,
+.table-condensed > thead > tr > td,
+.table-condensed > tbody > tr > td,
+.table-condensed > tfoot > tr > td {
+  padding: 5px;
+}
+.table-bordered {
+  border: 1px solid #ddd;
+}
+.table-bordered > thead > tr > th,
+.table-bordered > tbody > tr > th,
+.table-bordered > tfoot > tr > th,
+.table-bordered > thead > tr > td,
+.table-bordered > tbody > tr > td,
+.table-bordered > tfoot > tr > td {
+  border: 1px solid #ddd;
+}
+.table-bordered > thead > tr > th,
+.table-bordered > thead > tr > td {
+  border-bottom-width: 2px;
+}
+.table-striped > tbody > tr:nth-of-type(odd) {
+  background-color: #f9f9f9;
+}
+.table-hover > tbody > tr:hover {
+  background-color: #f5f5f5;
+}
+table col[class*="col-"] {
+  position: static;
+  display: table-column;
+  float: none;
+}
+table td[class*="col-"],
+table th[class*="col-"] {
+  position: static;
+  display: table-cell;
+  float: none;
+}
+.table > thead > tr > td.active,
+.table > tbody > tr > td.active,
+.table > tfoot > tr > td.active,
+.table > thead > tr > th.active,
+.table > tbody > tr > th.active,
+.table > tfoot > tr > th.active,
+.table > thead > tr.active > td,
+.table > tbody > tr.active > td,
+.table > tfoot > tr.active > td,
+.table > thead > tr.active > th,
+.table > tbody > tr.active > th,
+.table > tfoot > tr.active > th {
+  background-color: #f5f5f5;
+}
+.table-hover > tbody > tr > td.active:hover,
+.table-hover > tbody > tr > th.active:hover,
+.table-hover > tbody > tr.active:hover > td,
+.table-hover > tbody > tr:hover > .active,
+.table-hover > tbody > tr.active:hover > th {
+  background-color: #e8e8e8;
+}
+.table > thead > tr > td.success,
+.table > tbody > tr > td.success,
+.table > tfoot > tr > td.success,
+.table > thead > tr > th.success,
+.table > tbody > tr > th.success,
+.table > tfoot > tr > th.success,
+.table > thead > tr.success > td,
+.table > tbody > tr.success > td,
+.table > tfoot > tr.success > td,
+.table > thead > tr.success > th,
+.table > tbody > tr.success > th,
+.table > tfoot > tr.success > th {
+  background-color: #dff0d8;
+}
+.table-hover > tbody > tr > td.success:hover,
+.table-hover > tbody > tr > th.success:hover,
+.table-hover > tbody > tr.success:hover > td,
+.table-hover > tbody > tr:hover > .success,
+.table-hover > tbody > tr.success:hover > th {
+  background-color: #d0e9c6;
+}
+.table > thead > tr > td.info,
+.table > tbody > tr > td.info,
+.table > tfoot > tr > td.info,
+.table > thead > tr > th.info,
+.table > tbody > tr > th.info,
+.table > tfoot > tr > th.info,
+.table > thead > tr.info > td,
+.table > tbody > tr.info > td,
+.table > tfoot > tr.info > td,
+.table > thead > tr.info > th,
+.table > tbody > tr.info > th,
+.table > tfoot > tr.info > th {
+  background-color: #d9edf7;
+}
+.table-hover > tbody > tr > td.info:hover,
+.table-hover > tbody > tr > th.info:hover,
+.table-hover > tbody > tr.info:hover > td,
+.table-hover > tbody > tr:hover > .info,
+.table-hover > tbody > tr.info:hover > th {
+  background-color: #c4e3f3;
+}
+.table > thead > tr > td.warning,
+.table > tbody > tr > td.warning,
+.table > tfoot > tr > td.warning,
+.table > thead > tr > th.warning,
+.table > tbody > tr > th.warning,
+.table > tfoot > tr > th.warning,
+.table > thead > tr.warning > td,
+.table > tbody > tr.warning > td,
+.table > tfoot > tr.warning > td,
+.table > thead > tr.warning > th,
+.table > tbody > tr.warning > th,
+.table > tfoot > tr.warning > th {
+  background-color: #fcf8e3;
+}
+.table-hover > tbody > tr > td.warning:hover,
+.table-hover > tbody > tr > th.warning:hover,
+.table-hover > tbody > tr.warning:hover > td,
+.table-hover > tbody > tr:hover > .warning,
+.table-hover > tbody > tr.warning:hover > th {
+  background-color: #faf2cc;
+}
+.table > thead > tr > td.danger,
+.table > tbody > tr > td.danger,
+.table > tfoot > tr > td.danger,
+.table > thead > tr > th.danger,
+.table > tbody > tr > th.danger,
+.table > tfoot > tr > th.danger,
+.table > thead > tr.danger > td,
+.table > tbody > tr.danger > td,
+.table > tfoot > tr.danger > td,
+.table > thead > tr.danger > th,
+.table > tbody > tr.danger > th,
+.table > tfoot > tr.danger > th {
+  background-color: #f2dede;
+}
+.table-hover > tbody > tr > td.danger:hover,
+.table-hover > tbody > tr > th.danger:hover,
+.table-hover > tbody > tr.danger:hover > td,
+.table-hover > tbody > tr:hover > .danger,
+.table-hover > tbody > tr.danger:hover > th {
+  background-color: #ebcccc;
+}
+.table-responsive {
+  min-height: .01%;
+  overflow-x: auto;
+}
+@media screen and (max-width: 767px) {
+  .table-responsive {
+    width: 100%;
+    margin-bottom: 15px;
+    overflow-y: hidden;
+    -ms-overflow-style: -ms-autohiding-scrollbar;
+    border: 1px solid #ddd;
+  }
+  .table-responsive > .table {
+    margin-bottom: 0;
+  }
+  .table-responsive > .table > thead > tr > th,
+  .table-responsive > .table > tbody > tr > th,
+  .table-responsive > .table > tfoot > tr > th,
+  .table-responsive > .table > thead > tr > td,
+  .table-responsive > .table > tbody > tr > td,
+  .table-responsive > .table > tfoot > tr > td {
+    white-space: nowrap;
+  }
+  .table-responsive > .table-bordered {
+    border: 0;
+  }
+  .table-responsive > .table-bordered > thead > tr > th:first-child,
+  .table-responsive > .table-bordered > tbody > tr > th:first-child,
+  .table-responsive > .table-bordered > tfoot > tr > th:first-child,
+  .table-responsive > .table-bordered > thead > tr > td:first-child,
+  .table-responsive > .table-bordered > tbody > tr > td:first-child,
+  .table-responsive > .table-bordered > tfoot > tr > td:first-child {
+    border-left: 0;
+  }
+  .table-responsive > .table-bordered > thead > tr > th:last-child,
+  .table-responsive > .table-bordered > tbody > tr > th:last-child,
+  .table-responsive > .table-bordered > tfoot > tr > th:last-child,
+  .table-responsive > .table-bordered > thead > tr > td:last-child,
+  .table-responsive > .table-bordered > tbody > tr > td:last-child,
+  .table-responsive > .table-bordered > tfoot > tr > td:last-child {
+    border-right: 0;
+  }
+  .table-responsive > .table-bordered > tbody > tr:last-child > th,
+  .table-responsive > .table-bordered > tfoot > tr:last-child > th,
+  .table-responsive > .table-bordered > tbody > tr:last-child > td,
+  .table-responsive > .table-bordered > tfoot > tr:last-child > td {
+    border-bottom: 0;
+  }
+}
+fieldset {
+  min-width: 0;
+  padding: 0;
+  margin: 0;
+  border: 0;
+}
+legend {
+  display: block;
+  width: 100%;
+  padding: 0;
+  margin-bottom: 20px;
+  font-size: 21px;
+  line-height: inherit;
+  color: #333;
+  border: 0;
+  border-bottom: 1px solid #e5e5e5;
+}
+label {
+  display: inline-block;
+  max-width: 100%;
+  margin-bottom: 5px;
+  font-weight: bold;
+}
+input[type="search"] {
+  -webkit-box-sizing: border-box;
+     -moz-box-sizing: border-box;
+          box-sizing: border-box;
+}
+input[type="radio"],
+input[type="checkbox"] {
+  margin: 4px 0 0;
+  margin-top: 1px \9;
+  line-height: normal;
+}
+input[type="file"] {
+  display: block;
+}
+input[type="range"] {
+  display: block;
+  width: 100%;
+}
+select[multiple],
+select[size] {
+  height: auto;
+}
+input[type="file"]:focus,
+input[type="radio"]:focus,
+input[type="checkbox"]:focus {
+  outline: thin dotted;
+  outline: 5px auto -webkit-focus-ring-color;
+  outline-offset: -2px;
+}
+output {
+  display: block;
+  padding-top: 7px;
+  font-size: 14px;
+  line-height: 1.42857143;
+  color: #555;
+}
+.form-control {
+  display: block;
+  width: 100%;
+  height: 34px;
+  padding: 6px 12px;
+  font-size: 14px;
+  line-height: 1.42857143;
+  color: #555;
+  background-color: #fff;
+  background-image: none;
+  border: 1px solid #ccc;
+  border-radius: 4px;
+  -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);
+          box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);
+  -webkit-transition: border-color ease-in-out .15s, -webkit-box-shadow ease-in-out .15s;
+       -o-transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;
+          transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;
+}
+.form-control:focus {
+  border-color: #66afe9;
+  outline: 0;
+  -webkit-box-shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 8px rgba(102, 175, 233, .6);
+          box-shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 8px rgba(102, 175, 233, .6);
+}
+.form-control::-moz-placeholder {
+  color: #999;
+  opacity: 1;
+}
+.form-control:-ms-input-placeholder {
+  color: #999;
+}
+.form-control::-webkit-input-placeholder {
+  color: #999;
+}
+.form-control::-ms-expand {
+  background-color: transparent;
+  border: 0;
+}
+.form-control[disabled],
+.form-control[readonly],
+fieldset[disabled] .form-control {
+  background-color: #eee;
+  opacity: 1;
+}
+.form-control[disabled],
+fieldset[disabled] .form-control {
+  cursor: not-allowed;
+}
+textarea.form-control {
+  height: auto;
+}
+input[type="search"] {
+  -webkit-appearance: none;
+}
+@media screen and (-webkit-min-device-pixel-ratio: 0) {
+  input[type="date"].form-control,
+  input[type="time"].form-control,
+  input[type="datetime-local"].form-control,
+  input[type="month"].form-control {
+    line-height: 34px;
+  }
+  input[type="date"].input-sm,
+  input[type="time"].input-sm,
+  input[type="datetime-local"].input-sm,
+  input[type="month"].input-sm,
+  .input-group-sm input[type="date"],
+  .input-group-sm input[type="time"],
+  .input-group-sm input[type="datetime-local"],
+  .input-group-sm input[type="month"] {
+    line-height: 30px;
+  }
+  input[type="date"].input-lg,
+  input[type="time"].input-lg,
+  input[type="datetime-local"].input-lg,
+  input[type="month"].input-lg,
+  .input-group-lg input[type="date"],
+  .input-group-lg input[type="time"],
+  .input-group-lg input[type="datetime-local"],
+  .input-group-lg input[type="month"] {
+    line-height: 46px;
+  }
+}
+.form-group {
+  margin-bottom: 15px;
+}
+.radio,
+.checkbox {
+  position: relative;
+  display: block;
+  margin-top: 10px;
+  margin-bottom: 10px;
+}
+.radio label,
+.checkbox label {
+  min-height: 20px;
+  padding-left: 20px;
+  margin-bottom: 0;
+  font-weight: normal;
+  cursor: pointer;
+}
+.radio input[type="radio"],
+.radio-inline input[type="radio"],
+.checkbox input[type="checkbox"],
+.checkbox-inline input[type="checkbox"] {
+  position: absolute;
+  margin-top: 4px \9;
+  margin-left: -20px;
+}
+.radio + .radio,
+.checkbox + .checkbox {
+  margin-top: -5px;
+}
+.radio-inline,
+.checkbox-inline {
+  position: relative;
+  display: inline-block;
+  padding-left: 20px;
+  margin-bottom: 0;
+  font-weight: normal;
+  vertical-align: middle;
+  cursor: pointer;
+}
+.radio-inline + .radio-inline,
+.checkbox-inline + .checkbox-inline {
+  margin-top: 0;
+  margin-left: 10px;
+}
+input[type="radio"][disabled],
+input[type="checkbox"][disabled],
+input[type="radio"].disabled,
+input[type="checkbox"].disabled,
+fieldset[disabled] input[type="radio"],
+fieldset[disabled] input[type="checkbox"] {
+  cursor: not-allowed;
+}
+.radio-inline.disabled,
+.checkbox-inline.disabled,
+fieldset[disabled] .radio-inline,
+fieldset[disabled] .checkbox-inline {
+  cursor: not-allowed;
+}
+.radio.disabled label,
+.checkbox.disabled label,
+fieldset[disabled] .radio label,
+fieldset[disabled] .checkbox label {
+  cursor: not-allowed;
+}
+.form-control-static {
+  min-height: 34px;
+  padding-top: 7px;
+  padding-bottom: 7px;
+  margin-bottom: 0;
+}
+.form-control-static.input-lg,
+.form-control-static.input-sm {
+  padding-right: 0;
+  padding-left: 0;
+}
+.input-sm {
+  height: 30px;
+  padding: 5px 10px;
+  font-size: 12px;
+  line-height: 1.5;
+  border-radius: 3px;
+}
+select.input-sm {
+  height: 30px;
+  line-height: 30px;
+}
+textarea.input-sm,
+select[multiple].input-sm {
+  height: auto;
+}
+.form-group-sm .form-control {
+  height: 30px;
+  padding: 5px 10px;
+  font-size: 12px;
+  line-height: 1.5;
+  border-radius: 3px;
+}
+.form-group-sm select.form-control {
+  height: 30px;
+  line-height: 30px;
+}
+.form-group-sm textarea.form-control,
+.form-group-sm select[multiple].form-control {
+  height: auto;
+}
+.form-group-sm .form-control-static {
+  height: 30px;
+  min-height: 32px;
+  padding: 6px 10px;
+  font-size: 12px;
+  line-height: 1.5;
+}
+.input-lg {
+  height: 46px;
+  padding: 10px 16px;
+  font-size: 18px;
+  line-height: 1.3333333;
+  border-radius: 6px;
+}
+select.input-lg {
+  height: 46px;
+  line-height: 46px;
+}
+textarea.input-lg,
+select[multiple].input-lg {
+  height: auto;
+}
+.form-group-lg .form-control {
+  height: 46px;
+  padding: 10px 16px;
+  font-size: 18px;
+  line-height: 1.3333333;
+  border-radius: 6px;
+}
+.form-group-lg select.form-control {
+  height: 46px;
+  line-height: 46px;
+}
+.form-group-lg textarea.form-control,
+.form-group-lg select[multiple].form-control {
+  height: auto;
+}
+.form-group-lg .form-control-static {
+  height: 46px;
+  min-height: 38px;
+  padding: 11px 16px;
+  font-size: 18px;
+  line-height: 1.3333333;
+}
+.has-feedback {
+  position: relative;
+}
+.has-feedback .form-control {
+  padding-right: 42.5px;
+}
+.form-control-feedback {
+  position: absolute;
+  top: 0;
+  right: 0;
+  z-index: 2;
+  display: block;
+  width: 34px;
+  height: 34px;
+  line-height: 34px;
+  text-align: center;
+  pointer-events: none;
+}
+.input-lg + .form-control-feedback,
+.input-group-lg + .form-control-feedback,
+.form-group-lg .form-control + .form-control-feedback {
+  width: 46px;
+  height: 46px;
+  line-height: 46px;
+}
+.input-sm + .form-control-feedback,
+.input-group-sm + .form-control-feedback,
+.form-group-sm .form-control + .form-control-feedback {
+  width: 30px;
+  height: 30px;
+  line-height: 30px;
+}
+.has-success .help-block,
+.has-success .control-label,
+.has-success .radio,
+.has-success .checkbox,
+.has-success .radio-inline,
+.has-success .checkbox-inline,
+.has-success.radio label,
+.has-success.checkbox label,
+.has-success.radio-inline label,
+.has-success.checkbox-inline label {
+  color: #3c763d;
+}
+.has-success .form-control {
+  border-color: #3c763d;
+  -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);
+          box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);
+}
+.has-success .form-control:focus {
+  border-color: #2b542c;
+  -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 6px #67b168;
+          box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 6px #67b168;
+}
+.has-success .input-group-addon {
+  color: #3c763d;
+  background-color: #dff0d8;
+  border-color: #3c763d;
+}
+.has-success .form-control-feedback {
+  color: #3c763d;
+}
+.has-warning .help-block,
+.has-warning .control-label,
+.has-warning .radio,
+.has-warning .checkbox,
+.has-warning .radio-inline,
+.has-warning .checkbox-inline,
+.has-warning.radio label,
+.has-warning.checkbox label,
+.has-warning.radio-inline label,
+.has-warning.checkbox-inline label {
+  color: #8a6d3b;
+}
+.has-warning .form-control {
+  border-color: #8a6d3b;
+  -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);
+          box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);
+}
+.has-warning .form-control:focus {
+  border-color: #66512c;
+  -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 6px #c0a16b;
+          box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 6px #c0a16b;
+}
+.has-warning .input-group-addon {
+  color: #8a6d3b;
+  background-color: #fcf8e3;
+  border-color: #8a6d3b;
+}
+.has-warning .form-control-feedback {
+  color: #8a6d3b;
+}
+.has-error .help-block,
+.has-error .control-label,
+.has-error .radio,
+.has-error .checkbox,
+.has-error .radio-inline,
+.has-error .checkbox-inline,
+.has-error.radio label,
+.has-error.checkbox label,
+.has-error.radio-inline label,
+.has-error.checkbox-inline label {
+  color: #a94442;
+}
+.has-error .form-control {
+  border-color: #a94442;
+  -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);
+          box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);
+}
+.has-error .form-control:focus {
+  border-color: #843534;
+  -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 6px #ce8483;
+          box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 6px #ce8483;
+}
+.has-error .input-group-addon {
+  color: #a94442;
+  background-color: #f2dede;
+  border-color: #a94442;
+}
+.has-error .form-control-feedback {
+  color: #a94442;
+}
+.has-feedback label ~ .form-control-feedback {
+  top: 25px;
+}
+.has-feedback label.sr-only ~ .form-control-feedback {
+  top: 0;
+}
+.help-block {
+  display: block;
+  margin-top: 5px;
+  margin-bottom: 10px;
+  color: #737373;
+}
+@media (min-width: 768px) {
+  .form-inline .form-group {
+    display: inline-block;
+    margin-bottom: 0;
+    vertical-align: middle;
+  }
+  .form-inline .form-control {
+    display: inline-block;
+    width: auto;
+    vertical-align: middle;
+  }
+  .form-inline .form-control-static {
+    display: inline-block;
+  }
+  .form-inline .input-group {
+    display: inline-table;
+    vertical-align: middle;
+  }
+  .form-inline .input-group .input-group-addon,
+  .form-inline .input-group .input-group-btn,
+  .form-inline .input-group .form-control {
+    width: auto;
+  }
+  .form-inline .input-group > .form-control {
+    width: 100%;
+  }
+  .form-inline .control-label {
+    margin-bottom: 0;
+    vertical-align: middle;
+  }
+  .form-inline .radio,
+  .form-inline .checkbox {
+    display: inline-block;
+    margin-top: 0;
+    margin-bottom: 0;
+    vertical-align: middle;
+  }
+  .form-inline .radio label,
+  .form-inline .checkbox label {
+    padding-left: 0;
+  }
+  .form-inline .radio input[type="radio"],
+  .form-inline .checkbox input[type="checkbox"] {
+    position: relative;
+    margin-left: 0;
+  }
+  .form-inline .has-feedback .form-control-feedback {
+    top: 0;
+  }
+}
+.form-horizontal .radio,
+.form-horizontal .checkbox,
+.form-horizontal .radio-inline,
+.form-horizontal .checkbox-inline {
+  padding-top: 7px;
+  margin-top: 0;
+  margin-bottom: 0;
+}
+.form-horizontal .radio,
+.form-horizontal .checkbox {
+  min-height: 27px;
+}
+.form-horizontal .form-group {
+  margin-right: -15px;
+  margin-left: -15px;
+}
+@media (min-width: 768px) {
+  .form-horizontal .control-label {
+    padding-top: 7px;
+    margin-bottom: 0;
+    text-align: right;
+  }
+}
+.form-horizontal .has-feedback .form-control-feedback {
+  right: 15px;
+}
+@media (min-width: 768px) {
+  .form-horizontal .form-group-lg .control-label {
+    padding-top: 11px;
+    font-size: 18px;
+  }
+}
+@media (min-width: 768px) {
+  .form-horizontal .form-group-sm .control-label {
+    padding-top: 6px;
+    font-size: 12px;
+  }
+}
+.btn {
+  display: inline-block;
+  padding: 6px 12px;
+  margin-bottom: 0;
+  font-size: 14px;
+  font-weight: normal;
+  line-height: 1.42857143;
+  text-align: center;
+  white-space: nowrap;
+  vertical-align: middle;
+  -ms-touch-action: manipulation;
+      touch-action: manipulation;
+  cursor: pointer;
+  -webkit-user-select: none;
+     -moz-user-select: none;
+      -ms-user-select: none;
+          user-select: none;
+  background-image: none;
+  border: 1px solid transparent;
+  border-radius: 4px;
+}
+.btn:focus,
+.btn:active:focus,
+.btn.active:focus,
+.btn.focus,
+.btn:active.focus,
+.btn.active.focus {
+  outline: thin dotted;
+  outline: 5px auto -webkit-focus-ring-color;
+  outline-offset: -2px;
+}
+.btn:hover,
+.btn:focus,
+.btn.focus {
+  color: #333;
+  text-decoration: none;
+}
+.btn:active,
+.btn.active {
+  background-image: none;
+  outline: 0;
+  -webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
+          box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
+}
+.btn.disabled,
+.btn[disabled],
+fieldset[disabled] .btn {
+  cursor: not-allowed;
+  filter: alpha(opacity=65);
+  -webkit-box-shadow: none;
+          box-shadow: none;
+  opacity: .65;
+}
+a.btn.disabled,
+fieldset[disabled] a.btn {
+  pointer-events: none;
+}
+.btn-default {
+  color: #333;
+  background-color: #fff;
+  border-color: #ccc;
+}
+.btn-default:focus,
+.btn-default.focus {
+  color: #333;
+  background-color: #e6e6e6;
+  border-color: #8c8c8c;
+}
+.btn-default:hover {
+  color: #333;
+  background-color: #e6e6e6;
+  border-color: #adadad;
+}
+.btn-default:active,
+.btn-default.active,
+.open > .dropdown-toggle.btn-default {
+  color: #333;
+  background-color: #e6e6e6;
+  border-color: #adadad;
+}
+.btn-default:active:hover,
+.btn-default.active:hover,
+.open > .dropdown-toggle.btn-default:hover,
+.btn-default:active:focus,
+.btn-default.active:focus,
+.open > .dropdown-toggle.btn-default:focus,
+.btn-default:active.focus,
+.btn-default.active.focus,
+.open > .dropdown-toggle.btn-default.focus {
+  color: #333;
+  background-color: #d4d4d4;
+  border-color: #8c8c8c;
+}
+.btn-default:active,
+.btn-default.active,
+.open > .dropdown-toggle.btn-default {
+  background-image: none;
+}
+.btn-default.disabled:hover,
+.btn-default[disabled]:hover,
+fieldset[disabled] .btn-default:hover,
+.btn-default.disabled:focus,
+.btn-default[disabled]:focus,
+fieldset[disabled] .btn-default:focus,
+.btn-default.disabled.focus,
+.btn-default[disabled].focus,
+fieldset[disabled] .btn-default.focus {
+  background-color: #fff;
+  border-color: #ccc;
+}
+.btn-default .badge {
+  color: #fff;
+  background-color: #333;
+}
+.btn-primary {
+  color: #fff;
+  background-color: #337ab7;
+  border-color: #2e6da4;
+}
+.btn-primary:focus,
+.btn-primary.focus {
+  color: #fff;
+  background-color: #286090;
+  border-color: #122b40;
+}
+.btn-primary:hover {
+  color: #fff;
+  background-color: #286090;
+  border-color: #204d74;
+}
+.btn-primary:active,
+.btn-primary.active,
+.open > .dropdown-toggle.btn-primary {
+  color: #fff;
+  background-color: #286090;
+  border-color: #204d74;
+}
+.btn-primary:active:hover,
+.btn-primary.active:hover,
+.open > .dropdown-toggle.btn-primary:hover,
+.btn-primary:active:focus,
+.btn-primary.active:focus,
+.open > .dropdown-toggle.btn-primary:focus,
+.btn-primary:active.focus,
+.btn-primary.active.focus,
+.open > .dropdown-toggle.btn-primary.focus {
+  color: #fff;
+  background-color: #204d74;
+  border-color: #122b40;
+}
+.btn-primary:active,
+.btn-primary.active,
+.open > .dropdown-toggle.btn-primary {
+  background-image: none;
+}
+.btn-primary.disabled:hover,
+.btn-primary[disabled]:hover,
+fieldset[disabled] .btn-primary:hover,
+.btn-primary.disabled:focus,
+.btn-primary[disabled]:focus,
+fieldset[disabled] .btn-primary:focus,
+.btn-primary.disabled.focus,
+.btn-primary[disabled].focus,
+fieldset[disabled] .btn-primary.focus {
+  background-color: #337ab7;
+  border-color: #2e6da4;
+}
+.btn-primary .badge {
+  color: #337ab7;
+  background-color: #fff;
+}
+.btn-success {
+  color: #fff;
+  background-color: #5cb85c;
+  border-color: #4cae4c;
+}
+.btn-success:focus,
+.btn-success.focus {
+  color: #fff;
+  background-color: #449d44;
+  border-color: #255625;
+}
+.btn-success:hover {
+  color: #fff;
+  background-color: #449d44;
+  border-color: #398439;
+}
+.btn-success:active,
+.btn-success.active,
+.open > .dropdown-toggle.btn-success {
+  color: #fff;
+  background-color: #449d44;
+  border-color: #398439;
+}
+.btn-success:active:hover,
+.btn-success.active:hover,
+.open > .dropdown-toggle.btn-success:hover,
+.btn-success:active:focus,
+.btn-success.active:focus,
+.open > .dropdown-toggle.btn-success:focus,
+.btn-success:active.focus,
+.btn-success.active.focus,
+.open > .dropdown-toggle.btn-success.focus {
+  color: #fff;
+  background-color: #398439;
+  border-color: #255625;
+}
+.btn-success:active,
+.btn-success.active,
+.open > .dropdown-toggle.btn-success {
+  background-image: none;
+}
+.btn-success.disabled:hover,
+.btn-success[disabled]:hover,
+fieldset[disabled] .btn-success:hover,
+.btn-success.disabled:focus,
+.btn-success[disabled]:focus,
+fieldset[disabled] .btn-success:focus,
+.btn-success.disabled.focus,
+.btn-success[disabled].focus,
+fieldset[disabled] .btn-success.focus {
+  background-color: #5cb85c;
+  border-color: #4cae4c;
+}
+.btn-success .badge {
+  color: #5cb85c;
+  background-color: #fff;
+}
+.btn-info {
+  color: #fff;
+  background-color: #5bc0de;
+  border-color: #46b8da;
+}
+.btn-info:focus,
+.btn-info.focus {
+  color: #fff;
+  background-color: #31b0d5;
+  border-color: #1b6d85;
+}
+.btn-info:hover {
+  color: #fff;
+  background-color: #31b0d5;
+  border-color: #269abc;
+}
+.btn-info:active,
+.btn-info.active,
+.open > .dropdown-toggle.btn-info {
+  color: #fff;
+  background-color: #31b0d5;
+  border-color: #269abc;
+}
+.btn-info:active:hover,
+.btn-info.active:hover,
+.open > .dropdown-toggle.btn-info:hover,
+.btn-info:active:focus,
+.btn-info.active:focus,
+.open > .dropdown-toggle.btn-info:focus,
+.btn-info:active.focus,
+.btn-info.active.focus,
+.open > .dropdown-toggle.btn-info.focus {
+  color: #fff;
+  background-color: #269abc;
+  border-color: #1b6d85;
+}
+.btn-info:active,
+.btn-info.active,
+.open > .dropdown-toggle.btn-info {
+  background-image: none;
+}
+.btn-info.disabled:hover,
+.btn-info[disabled]:hover,
+fieldset[disabled] .btn-info:hover,
+.btn-info.disabled:focus,
+.btn-info[disabled]:focus,
+fieldset[disabled] .btn-info:focus,
+.btn-info.disabled.focus,
+.btn-info[disabled].focus,
+fieldset[disabled] .btn-info.focus {
+  background-color: #5bc0de;
+  border-color: #46b8da;
+}
+.btn-info .badge {
+  color: #5bc0de;
+  background-color: #fff;
+}
+.btn-warning {
+  color: #fff;
+  background-color: #f0ad4e;
+  border-color: #eea236;
+}
+.btn-warning:focus,
+.btn-warning.focus {
+  color: #fff;
+  background-color: #ec971f;
+  border-color: #985f0d;
+}
+.btn-warning:hover {
+  color: #fff;
+  background-color: #ec971f;
+  border-color: #d58512;
+}
+.btn-warning:active,
+.btn-warning.active,
+.open > .dropdown-toggle.btn-warning {
+  color: #fff;
+  background-color: #ec971f;
+  border-color: #d58512;
+}
+.btn-warning:active:hover,
+.btn-warning.active:hover,
+.open > .dropdown-toggle.btn-warning:hover,
+.btn-warning:active:focus,
+.btn-warning.active:focus,
+.open > .dropdown-toggle.btn-warning:focus,
+.btn-warning:active.focus,
+.btn-warning.active.focus,
+.open > .dropdown-toggle.btn-warning.focus {
+  color: #fff;
+  background-color: #d58512;
+  border-color: #985f0d;
+}
+.btn-warning:active,
+.btn-warning.active,
+.open > .dropdown-toggle.btn-warning {
+  background-image: none;
+}
+.btn-warning.disabled:hover,
+.btn-warning[disabled]:hover,
+fieldset[disabled] .btn-warning:hover,
+.btn-warning.disabled:focus,
+.btn-warning[disabled]:focus,
+fieldset[disabled] .btn-warning:focus,
+.btn-warning.disabled.focus,
+.btn-warning[disabled].focus,
+fieldset[disabled] .btn-warning.focus {
+  background-color: #f0ad4e;
+  border-color: #eea236;
+}
+.btn-warning .badge {
+  color: #f0ad4e;
+  background-color: #fff;
+}
+.btn-danger {
+  color: #fff;
+  background-color: #d9534f;
+  border-color: #d43f3a;
+}
+.btn-danger:focus,
+.btn-danger.focus {
+  color: #fff;
+  background-color: #c9302c;
+  border-color: #761c19;
+}
+.btn-danger:hover {
+  color: #fff;
+  background-color: #c9302c;
+  border-color: #ac2925;
+}
+.btn-danger:active,
+.btn-danger.active,
+.open > .dropdown-toggle.btn-danger {
+  color: #fff;
+  background-color: #c9302c;
+  border-color: #ac2925;
+}
+.btn-danger:active:hover,
+.btn-danger.active:hover,
+.open > .dropdown-toggle.btn-danger:hover,
+.btn-danger:active:focus,
+.btn-danger.active:focus,
+.open > .dropdown-toggle.btn-danger:focus,
+.btn-danger:active.focus,
+.btn-danger.active.focus,
+.open > .dropdown-toggle.btn-danger.focus {
+  color: #fff;
+  background-color: #ac2925;
+  border-color: #761c19;
+}
+.btn-danger:active,
+.btn-danger.active,
+.open > .dropdown-toggle.btn-danger {
+  background-image: none;
+}
+.btn-danger.disabled:hover,
+.btn-danger[disabled]:hover,
+fieldset[disabled] .btn-danger:hover,
+.btn-danger.disabled:focus,
+.btn-danger[disabled]:focus,
+fieldset[disabled] .btn-danger:focus,
+.btn-danger.disabled.focus,
+.btn-danger[disabled].focus,
+fieldset[disabled] .btn-danger.focus {
+  background-color: #d9534f;
+  border-color: #d43f3a;
+}
+.btn-danger .badge {
+  color: #d9534f;
+  background-color: #fff;
+}
+.btn-link {
+  font-weight: normal;
+  color: #337ab7;
+  border-radius: 0;
+}
+.btn-link,
+.btn-link:active,
+.btn-link.active,
+.btn-link[disabled],
+fieldset[disabled] .btn-link {
+  background-color: transparent;
+  -webkit-box-shadow: none;
+          box-shadow: none;
+}
+.btn-link,
+.btn-link:hover,
+.btn-link:focus,
+.btn-link:active {
+  border-color: transparent;
+}
+.btn-link:hover,
+.btn-link:focus {
+  color: #23527c;
+  text-decoration: underline;
+  background-color: transparent;
+}
+.btn-link[disabled]:hover,
+fieldset[disabled] .btn-link:hover,
+.btn-link[disabled]:focus,
+fieldset[disabled] .btn-link:focus {
+  color: #777;
+  text-decoration: none;
+}
+.btn-lg,
+.btn-group-lg > .btn {
+  padding: 10px 16px;
+  font-size: 18px;
+  line-height: 1.3333333;
+  border-radius: 6px;
+}
+.btn-sm,
+.btn-group-sm > .btn {
+  padding: 5px 10px;
+  font-size: 12px;
+  line-height: 1.5;
+  border-radius: 3px;
+}
+.btn-xs,
+.btn-group-xs > .btn {
+  padding: 1px 5px;
+  font-size: 12px;
+  line-height: 1.5;
+  border-radius: 3px;
+}
+.btn-block {
+  display: block;
+  width: 100%;
+}
+.btn-block + .btn-block {
+  margin-top: 5px;
+}
+input[type="submit"].btn-block,
+input[type="reset"].btn-block,
+input[type="button"].btn-block {
+  width: 100%;
+}
+.fade {
+  opacity: 0;
+  -webkit-transition: opacity .15s linear;
+       -o-transition: opacity .15s linear;
+          transition: opacity .15s linear;
+}
+.fade.in {
+  opacity: 1;
+}
+.collapse {
+  display: none;
+}
+.collapse.in {
+  display: block;
+}
+tr.collapse.in {
+  display: table-row;
+}
+tbody.collapse.in {
+  display: table-row-group;
+}
+.collapsing {
+  position: relative;
+  height: 0;
+  overflow: hidden;
+  -webkit-transition-timing-function: ease;
+       -o-transition-timing-function: ease;
+          transition-timing-function: ease;
+  -webkit-transition-duration: .35s;
+       -o-transition-duration: .35s;
+          transition-duration: .35s;
+  -webkit-transition-property: height, visibility;
+       -o-transition-property: height, visibility;
+          transition-property: height, visibility;
+}
+.caret {
+  display: inline-block;
+  width: 0;
+  height: 0;
+  margin-left: 2px;
+  vertical-align: middle;
+  border-top: 4px dashed;
+  border-top: 4px solid \9;
+  border-right: 4px solid transparent;
+  border-left: 4px solid transparent;
+}
+.dropup,
+.dropdown {
+  position: relative;
+}
+.dropdown-toggle:focus {
+  outline: 0;
+}
+.dropdown-menu {
+  position: absolute;
+  top: 100%;
+  left: 0;
+  z-index: 1000;
+  display: none;
+  float: left;
+  min-width: 160px;
+  padding: 5px 0;
+  margin: 2px 0 0;
+  font-size: 14px;
+  text-align: left;
+  list-style: none;
+  background-color: #fff;
+  -webkit-background-clip: padding-box;
+          background-clip: padding-box;
+  border: 1px solid #ccc;
+  border: 1px solid rgba(0, 0, 0, .15);
+  border-radius: 4px;
+  -webkit-box-shadow: 0 6px 12px rgba(0, 0, 0, .175);
+          box-shadow: 0 6px 12px rgba(0, 0, 0, .175);
+}
+.dropdown-menu.pull-right {
+  right: 0;
+  left: auto;
+}
+.dropdown-menu .divider {
+  height: 1px;
+  margin: 9px 0;
+  overflow: hidden;
+  background-color: #e5e5e5;
+}
+.dropdown-menu > li > a {
+  display: block;
+  padding: 3px 20px;
+  clear: both;
+  font-weight: normal;
+  line-height: 1.42857143;
+  color: #333;
+  white-space: nowrap;
+}
+.dropdown-menu > li > a:hover,
+.dropdown-menu > li > a:focus {
+  color: #262626;
+  text-decoration: none;
+  background-color: #f5f5f5;
+}
+.dropdown-menu > .active > a,
+.dropdown-menu > .active > a:hover,
+.dropdown-menu > .active > a:focus {
+  color: #fff;
+  text-decoration: none;
+  background-color: #337ab7;
+  outline: 0;
+}
+.dropdown-menu > .disabled > a,
+.dropdown-menu > .disabled > a:hover,
+.dropdown-menu > .disabled > a:focus {
+  color: #777;
+}
+.dropdown-menu > .disabled > a:hover,
+.dropdown-menu > .disabled > a:focus {
+  text-decoration: none;
+  cursor: not-allowed;
+  background-color: transparent;
+  background-image: none;
+  filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
+}
+.open > .dropdown-menu {
+  display: block;
+}
+.open > a {
+  outline: 0;
+}
+.dropdown-menu-right {
+  right: 0;
+  left: auto;
+}
+.dropdown-menu-left {
+  right: auto;
+  left: 0;
+}
+.dropdown-header {
+  display: block;
+  padding: 3px 20px;
+  font-size: 12px;
+  line-height: 1.42857143;
+  color: #777;
+  white-space: nowrap;
+}
+.dropdown-backdrop {
+  position: fixed;
+  top: 0;
+  right: 0;
+  bottom: 0;
+  left: 0;
+  z-index: 990;
+}
+.pull-right > .dropdown-menu {
+  right: 0;
+  left: auto;
+}
+.dropup .caret,
+.navbar-fixed-bottom .dropdown .caret {
+  content: "";
+  border-top: 0;
+  border-bottom: 4px dashed;
+  border-bottom: 4px solid \9;
+}
+.dropup .dropdown-menu,
+.navbar-fixed-bottom .dropdown .dropdown-menu {
+  top: auto;
+  bottom: 100%;
+  margin-bottom: 2px;
+}
+@media (min-width: 768px) {
+  .navbar-right .dropdown-menu {
+    right: 0;
+    left: auto;
+  }
+  .navbar-right .dropdown-menu-left {
+    right: auto;
+    left: 0;
+  }
+}
+.btn-group,
+.btn-group-vertical {
+  position: relative;
+  display: inline-block;
+  vertical-align: middle;
+}
+.btn-group > .btn,
+.btn-group-vertical > .btn {
+  position: relative;
+  float: left;
+}
+.btn-group > .btn:hover,
+.btn-group-vertical > .btn:hover,
+.btn-group > .btn:focus,
+.btn-group-vertical > .btn:focus,
+.btn-group > .btn:active,
+.btn-group-vertical > .btn:active,
+.btn-group > .btn.active,
+.btn-group-vertical > .btn.active {
+  z-index: 2;
+}
+.btn-group .btn + .btn,
+.btn-group .btn + .btn-group,
+.btn-group .btn-group + .btn,
+.btn-group .btn-group + .btn-group {
+  margin-left: -1px;
+}
+.btn-toolbar {
+  margin-left: -5px;
+}
+.btn-toolbar .btn,
+.btn-toolbar .btn-group,
+.btn-toolbar .input-group {
+  float: left;
+}
+.btn-toolbar > .btn,
+.btn-toolbar > .btn-group,
+.btn-toolbar > .input-group {
+  margin-left: 5px;
+}
+.btn-group > .btn:not(:first-child):not(:last-child):not(.dropdown-toggle) {
+  border-radius: 0;
+}
+.btn-group > .btn:first-child {
+  margin-left: 0;
+}
+.btn-group > .btn:first-child:not(:last-child):not(.dropdown-toggle) {
+  border-top-right-radius: 0;
+  border-bottom-right-radius: 0;
+}
+.btn-group > .btn:last-child:not(:first-child),
+.btn-group > .dropdown-toggle:not(:first-child) {
+  border-top-left-radius: 0;
+  border-bottom-left-radius: 0;
+}
+.btn-group > .btn-group {
+  float: left;
+}
+.btn-group > .btn-group:not(:first-child):not(:last-child) > .btn {
+  border-radius: 0;
+}
+.btn-group > .btn-group:first-child:not(:last-child) > .btn:last-child,
+.btn-group > .btn-group:first-child:not(:last-child) > .dropdown-toggle {
+  border-top-right-radius: 0;
+  border-bottom-right-radius: 0;
+}
+.btn-group > .btn-group:last-child:not(:first-child) > .btn:first-child {
+  border-top-left-radius: 0;
+  border-bottom-left-radius: 0;
+}
+.btn-group .dropdown-toggle:active,
+.btn-group.open .dropdown-toggle {
+  outline: 0;
+}
+.btn-group > .btn + .dropdown-toggle {
+  padding-right: 8px;
+  padding-left: 8px;
+}
+.btn-group > .btn-lg + .dropdown-toggle {
+  padding-right: 12px;
+  padding-left: 12px;
+}
+.btn-group.open .dropdown-toggle {
+  -webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
+          box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);
+}
+.btn-group.open .dropdown-toggle.btn-link {
+  -webkit-box-shadow: none;
+          box-shadow: none;
+}
+.btn .caret {
+  margin-left: 0;
+}
+.btn-lg .caret {
+  border-width: 5px 5px 0;
+  border-bottom-width: 0;
+}
+.dropup .btn-lg .caret {
+  border-width: 0 5px 5px;
+}
+.btn-group-vertical > .btn,
+.btn-group-vertical > .btn-group,
+.btn-group-vertical > .btn-group > .btn {
+  display: block;
+  float: none;
+  width: 100%;
+  max-width: 100%;
+}
+.btn-group-vertical > .btn-group > .btn {
+  float: none;
+}
+.btn-group-vertical > .btn + .btn,
+.btn-group-vertical > .btn + .btn-group,
+.btn-group-vertical > .btn-group + .btn,
+.btn-group-vertical > .btn-group + .btn-group {
+  margin-top: -1px;
+  margin-left: 0;
+}
+.btn-group-vertical > .btn:not(:first-child):not(:last-child) {
+  border-radius: 0;
+}
+.btn-group-vertical > .btn:first-child:not(:last-child) {
+  border-top-left-radius: 4px;
+  border-top-right-radius: 4px;
+  border-bottom-right-radius: 0;
+  border-bottom-left-radius: 0;
+}
+.btn-group-vertical > .btn:last-child:not(:first-child) {
+  border-top-left-radius: 0;
+  border-top-right-radius: 0;
+  border-bottom-right-radius: 4px;
+  border-bottom-left-radius: 4px;
+}
+.btn-group-vertical > .btn-group:not(:first-child):not(:last-child) > .btn {
+  border-radius: 0;
+}
+.btn-group-vertical > .btn-group:first-child:not(:last-child) > .btn:last-child,
+.btn-group-vertical > .btn-group:first-child:not(:last-child) > .dropdown-toggle {
+  border-bottom-right-radius: 0;
+  border-bottom-left-radius: 0;
+}
+.btn-group-vertical > .btn-group:last-child:not(:first-child) > .btn:first-child {
+  border-top-left-radius: 0;
+  border-top-right-radius: 0;
+}
+.btn-group-justified {
+  display: table;
+  width: 100%;
+  table-layout: fixed;
+  border-collapse: separate;
+}
+.btn-group-justified > .btn,
+.btn-group-justified > .btn-group {
+  display: table-cell;
+  float: none;
+  width: 1%;
+}
+.btn-group-justified > .btn-group .btn {
+  width: 100%;
+}
+.btn-group-justified > .btn-group .dropdown-menu {
+  left: auto;
+}
+[data-toggle="buttons"] > .btn input[type="radio"],
+[data-toggle="buttons"] > .btn-group > .btn input[type="radio"],
+[data-toggle="buttons"] > .btn input[type="checkbox"],
+[data-toggle="buttons"] > .btn-group > .btn input[type="checkbox"] {
+  position: absolute;
+  clip: rect(0, 0, 0, 0);
+  pointer-events: none;
+}
+.input-group {
+  position: relative;
+  display: table;
+  border-collapse: separate;
+}
+.input-group[class*="col-"] {
+  float: none;
+  padding-right: 0;
+  padding-left: 0;
+}
+.input-group .form-control {
+  position: relative;
+  z-index: 2;
+  float: left;
+  width: 100%;
+  margin-bottom: 0;
+}
+.input-group .form-control:focus {
+  z-index: 3;
+}
+.input-group-lg > .form-control,
+.input-group-lg > .input-group-addon,
+.input-group-lg > .input-group-btn > .btn {
+  height: 46px;
+  padding: 10px 16px;
+  font-size: 18px;
+  line-height: 1.3333333;
+  border-radius: 6px;
+}
+select.input-group-lg > .form-control,
+select.input-group-lg > .input-group-addon,
+select.input-group-lg > .input-group-btn > .btn {
+  height: 46px;
+  line-height: 46px;
+}
+textarea.input-group-lg > .form-control,
+textarea.input-group-lg > .input-group-addon,
+textarea.input-group-lg > .input-group-btn > .btn,
+select[multiple].input-group-lg > .form-control,
+select[multiple].input-group-lg > .input-group-addon,
+select[multiple].input-group-lg > .input-group-btn > .btn {
+  height: auto;
+}
+.input-group-sm > .form-control,
+.input-group-sm > .input-group-addon,
+.input-group-sm > .input-group-btn > .btn {
+  height: 30px;
+  padding: 5px 10px;
+  font-size: 12px;
+  line-height: 1.5;
+  border-radius: 3px;
+}
+select.input-group-sm > .form-control,
+select.input-group-sm > .input-group-addon,
+select.input-group-sm > .input-group-btn > .btn {
+  height: 30px;
+  line-height: 30px;
+}
+textarea.input-group-sm > .form-control,
+textarea.input-group-sm > .input-group-addon,
+textarea.input-group-sm > .input-group-btn > .btn,
+select[multiple].input-group-sm > .form-control,
+select[multiple].input-group-sm > .input-group-addon,
+select[multiple].input-group-sm > .input-group-btn > .btn {
+  height: auto;
+}
+.input-group-addon,
+.input-group-btn,
+.input-group .form-control {
+  display: table-cell;
+}
+.input-group-addon:not(:first-child):not(:last-child),
+.input-group-btn:not(:first-child):not(:last-child),
+.input-group .form-control:not(:first-child):not(:last-child) {
+  border-radius: 0;
+}
+.input-group-addon,
+.input-group-btn {
+  width: 1%;
+  white-space: nowrap;
+  vertical-align: middle;
+}
+.input-group-addon {
+  padding: 6px 12px;
+  font-size: 14px;
+  font-weight: normal;
+  line-height: 1;
+  color: #555;
+  text-align: center;
+  background-color: #eee;
+  border: 1px solid #ccc;
+  border-radius: 4px;
+}
+.input-group-addon.input-sm {
+  padding: 5px 10px;
+  font-size: 12px;
+  border-radius: 3px;
+}
+.input-group-addon.input-lg {
+  padding: 10px 16px;
+  font-size: 18px;
+  border-radius: 6px;
+}
+.input-group-addon input[type="radio"],
+.input-group-addon input[type="checkbox"] {
+  margin-top: 0;
+}
+.input-group .form-control:first-child,
+.input-group-addon:first-child,
+.input-group-btn:first-child > .btn,
+.input-group-btn:first-child > .btn-group > .btn,
+.input-group-btn:first-child > .dropdown-toggle,
+.input-group-btn:last-child > .btn:not(:last-child):not(.dropdown-toggle),
+.input-group-btn:last-child > .btn-group:not(:last-child) > .btn {
+  border-top-right-radius: 0;
+  border-bottom-right-radius: 0;
+}
+.input-group-addon:first-child {
+  border-right: 0;
+}
+.input-group .form-control:last-child,
+.input-group-addon:last-child,
+.input-group-btn:last-child > .btn,
+.input-group-btn:last-child > .btn-group > .btn,
+.input-group-btn:last-child > .dropdown-toggle,
+.input-group-btn:first-child > .btn:not(:first-child),
+.input-group-btn:first-child > .btn-group:not(:first-child) > .btn {
+  border-top-left-radius: 0;
+  border-bottom-left-radius: 0;
+}
+.input-group-addon:last-child {
+  border-left: 0;
+}
+.input-group-btn {
+  position: relative;
+  font-size: 0;
+  white-space: nowrap;
+}
+.input-group-btn > .btn {
+  position: relative;
+}
+.input-group-btn > .btn + .btn {
+  margin-left: -1px;
+}
+.input-group-btn > .btn:hover,
+.input-group-btn > .btn:focus,
+.input-group-btn > .btn:active {
+  z-index: 2;
+}
+.input-group-btn:first-child > .btn,
+.input-group-btn:first-child > .btn-group {
+  margin-right: -1px;
+}
+.input-group-btn:last-child > .btn,
+.input-group-btn:last-child > .btn-group {
+  z-index: 2;
+  margin-left: -1px;
+}
+.nav {
+  padding-left: 0;
+  margin-bottom: 0;
+  list-style: none;
+}
+.nav > li {
+  position: relative;
+  display: block;
+}
+.nav > li > a {
+  position: relative;
+  display: block;
+  padding: 10px 15px;
+}
+.nav > li > a:hover,
+.nav > li > a:focus {
+  text-decoration: none;
+  background-color: #eee;
+}
+.nav > li.disabled > a {
+  color: #777;
+}
+.nav > li.disabled > a:hover,
+.nav > li.disabled > a:focus {
+  color: #777;
+  text-decoration: none;
+  cursor: not-allowed;
+  background-color: transparent;
+}
+.nav .open > a,
+.nav .open > a:hover,
+.nav .open > a:focus {
+  background-color: #eee;
+  border-color: #337ab7;
+}
+.nav .nav-divider {
+  height: 1px;
+  margin: 9px 0;
+  overflow: hidden;
+  background-color: #e5e5e5;
+}
+.nav > li > a > img {
+  max-width: none;
+}
+.nav-tabs {
+  border-bottom: 1px solid #ddd;
+}
+.nav-tabs > li {
+  float: left;
+  margin-bottom: -1px;
+}
+.nav-tabs > li > a {
+  margin-right: 2px;
+  line-height: 1.42857143;
+  border: 1px solid transparent;
+  border-radius: 4px 4px 0 0;
+}
+.nav-tabs > li > a:hover {
+  border-color: #eee #eee #ddd;
+}
+.nav-tabs > li.active > a,
+.nav-tabs > li.active > a:hover,
+.nav-tabs > li.active > a:focus {
+  color: #555;
+  cursor: default;
+  background-color: #fff;
+  border: 1px solid #ddd;
+  border-bottom-color: transparent;
+}
+.nav-tabs.nav-justified {
+  width: 100%;
+  border-bottom: 0;
+}
+.nav-tabs.nav-justified > li {
+  float: none;
+}
+.nav-tabs.nav-justified > li > a {
+  margin-bottom: 5px;
+  text-align: center;
+}
+.nav-tabs.nav-justified > .dropdown .dropdown-menu {
+  top: auto;
+  left: auto;
+}
+@media (min-width: 768px) {
+  .nav-tabs.nav-justified > li {
+    display: table-cell;
+    width: 1%;
+  }
+  .nav-tabs.nav-justified > li > a {
+    margin-bottom: 0;
+  }
+}
+.nav-tabs.nav-justified > li > a {
+  margin-right: 0;
+  border-radius: 4px;
+}
+.nav-tabs.nav-justified > .active > a,
+.nav-tabs.nav-justified > .active > a:hover,
+.nav-tabs.nav-justified > .active > a:focus {
+  border: 1px solid #ddd;
+}
+@media (min-width: 768px) {
+  .nav-tabs.nav-justified > li > a {
+    border-bottom: 1px solid #ddd;
+    border-radius: 4px 4px 0 0;
+  }
+  .nav-tabs.nav-justified > .active > a,
+  .nav-tabs.nav-justified > .active > a:hover,
+  .nav-tabs.nav-justified > .active > a:focus {
+    border-bottom-color: #fff;
+  }
+}
+.nav-pills > li {
+  float: left;
+}
+.nav-pills > li > a {
+  border-radius: 4px;
+}
+.nav-pills > li + li {
+  margin-left: 2px;
+}
+.nav-pills > li.active > a,
+.nav-pills > li.active > a:hover,
+.nav-pills > li.active > a:focus {
+  color: #fff;
+  background-color: #337ab7;
+}
+.nav-stacked > li {
+  float: none;
+}
+.nav-stacked > li + li {
+  margin-top: 2px;
+  margin-left: 0;
+}
+.nav-justified {
+  width: 100%;
+}
+.nav-justified > li {
+  float: none;
+}
+.nav-justified > li > a {
+  margin-bottom: 5px;
+  text-align: center;
+}
+.nav-justified > .dropdown .dropdown-menu {
+  top: auto;
+  left: auto;
+}
+@media (min-width: 768px) {
+  .nav-justified > li {
+    display: table-cell;
+    width: 1%;
+  }
+  .nav-justified > li > a {
+    margin-bottom: 0;
+  }
+}
+.nav-tabs-justified {
+  border-bottom: 0;
+}
+.nav-tabs-justified > li > a {
+  margin-right: 0;
+  border-radius: 4px;
+}
+.nav-tabs-justified > .active > a,
+.nav-tabs-justified > .active > a:hover,
+.nav-tabs-justified > .active > a:focus {
+  border: 1px solid #ddd;
+}
+@media (min-width: 768px) {
+  .nav-tabs-justified > li > a {
+    border-bottom: 1px solid #ddd;
+    border-radius: 4px 4px 0 0;
+  }
+  .nav-tabs-justified > .active > a,
+  .nav-tabs-justified > .active > a:hover,
+  .nav-tabs-justified > .active > a:focus {
+    border-bottom-color: #fff;
+  }
+}
+.tab-content > .tab-pane {
+  display: none;
+}
+.tab-content > .active {
+  display: block;
+}
+.nav-tabs .dropdown-menu {
+  margin-top: -1px;
+  border-top-left-radius: 0;
+  border-top-right-radius: 0;
+}
+.navbar {
+  position: relative;
+  min-height: 50px;
+  margin-bottom: 20px;
+  border: 1px solid transparent;
+}
+@media (min-width: 768px) {
+  .navbar {
+    border-radius: 4px;
+  }
+}
+@media (min-width: 768px) {
+  .navbar-header {
+    float: left;
+  }
+}
+.navbar-collapse {
+  padding-right: 15px;
+  padding-left: 15px;
+  overflow-x: visible;
+  -webkit-overflow-scrolling: touch;
+  border-top: 1px solid transparent;
+  -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1);
+          box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1);
+}
+.navbar-collapse.in {
+  overflow-y: auto;
+}
+@media (min-width: 768px) {
+  .navbar-collapse {
+    width: auto;
+    border-top: 0;
+    -webkit-box-shadow: none;
+            box-shadow: none;
+  }
+  .navbar-collapse.collapse {
+    display: block !important;
+    height: auto !important;
+    padding-bottom: 0;
+    overflow: visible !important;
+  }
+  .navbar-collapse.in {
+    overflow-y: visible;
+  }
+  .navbar-fixed-top .navbar-collapse,
+  .navbar-static-top .navbar-collapse,
+  .navbar-fixed-bottom .navbar-collapse {
+    padding-right: 0;
+    padding-left: 0;
+  }
+}
+.navbar-fixed-top .navbar-collapse,
+.navbar-fixed-bottom .navbar-collapse {
+  max-height: 340px;
+}
+@media (max-device-width: 480px) and (orientation: landscape) {
+  .navbar-fixed-top .navbar-collapse,
+  .navbar-fixed-bottom .navbar-collapse {
+    max-height: 200px;
+  }
+}
+.container > .navbar-header,
+.container-fluid > .navbar-header,
+.container > .navbar-collapse,
+.container-fluid > .navbar-collapse {
+  margin-right: -15px;
+  margin-left: -15px;
+}
+@media (min-width: 768px) {
+  .container > .navbar-header,
+  .container-fluid > .navbar-header,
+  .container > .navbar-collapse,
+  .container-fluid > .navbar-collapse {
+    margin-right: 0;
+    margin-left: 0;
+  }
+}
+.navbar-static-top {
+  z-index: 1000;
+  border-width: 0 0 1px;
+}
+@media (min-width: 768px) {
+  .navbar-static-top {
+    border-radius: 0;
+  }
+}
+.navbar-fixed-top,
+.navbar-fixed-bottom {
+  position: fixed;
+  right: 0;
+  left: 0;
+  z-index: 1030;
+}
+@media (min-width: 768px) {
+  .navbar-fixed-top,
+  .navbar-fixed-bottom {
+    border-radius: 0;
+  }
+}
+.navbar-fixed-top {
+  top: 0;
+  border-width: 0 0 1px;
+}
+.navbar-fixed-bottom {
+  bottom: 0;
+  margin-bottom: 0;
+  border-width: 1px 0 0;
+}
+.navbar-brand {
+  float: left;
+  height: 50px;
+  padding: 15px 15px;
+  font-size: 18px;
+  line-height: 20px;
+}
+.navbar-brand:hover,
+.navbar-brand:focus {
+  text-decoration: none;
+}
+.navbar-brand > img {
+  display: block;
+}
+@media (min-width: 768px) {
+  .navbar > .container .navbar-brand,
+  .navbar > .container-fluid .navbar-brand {
+    margin-left: -15px;
+  }
+}
+.navbar-toggle {
+  position: relative;
+  float: right;
+  padding: 9px 10px;
+  margin-top: 8px;
+  margin-right: 15px;
+  margin-bottom: 8px;
+  background-color: transparent;
+  background-image: none;
+  border: 1px solid transparent;
+  border-radius: 4px;
+}
+.navbar-toggle:focus {
+  outline: 0;
+}
+.navbar-toggle .icon-bar {
+  display: block;
+  width: 22px;
+  height: 2px;
+  border-radius: 1px;
+}
+.navbar-toggle .icon-bar + .icon-bar {
+  margin-top: 4px;
+}
+@media (min-width: 768px) {
+  .navbar-toggle {
+    display: none;
+  }
+}
+.navbar-nav {
+  margin: 7.5px -15px;
+}
+.navbar-nav > li > a {
+  padding-top: 10px;
+  padding-bottom: 10px;
+  line-height: 20px;
+}
+@media (max-width: 767px) {
+  .navbar-nav .open .dropdown-menu {
+    position: static;
+    float: none;
+    width: auto;
+    margin-top: 0;
+    background-color: transparent;
+    border: 0;
+    -webkit-box-shadow: none;
+            box-shadow: none;
+  }
+  .navbar-nav .open .dropdown-menu > li > a,
+  .navbar-nav .open .dropdown-menu .dropdown-header {
+    padding: 5px 15px 5px 25px;
+  }
+  .navbar-nav .open .dropdown-menu > li > a {
+    line-height: 20px;
+  }
+  .navbar-nav .open .dropdown-menu > li > a:hover,
+  .navbar-nav .open .dropdown-menu > li > a:focus {
+    background-image: none;
+  }
+}
+@media (min-width: 768px) {
+  .navbar-nav {
+    float: left;
+    margin: 0;
+  }
+  .navbar-nav > li {
+    float: left;
+  }
+  .navbar-nav > li > a {
+    padding-top: 15px;
+    padding-bottom: 15px;
+  }
+}
+.navbar-form {
+  padding: 10px 15px;
+  margin-top: 8px;
+  margin-right: -15px;
+  margin-bottom: 8px;
+  margin-left: -15px;
+  border-top: 1px solid transparent;
+  border-bottom: 1px solid transparent;
+  -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1), 0 1px 0 rgba(255, 255, 255, .1);
+          box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1), 0 1px 0 rgba(255, 255, 255, .1);
+}
+@media (min-width: 768px) {
+  .navbar-form .form-group {
+    display: inline-block;
+    margin-bottom: 0;
+    vertical-align: middle;
+  }
+  .navbar-form .form-control {
+    display: inline-block;
+    width: auto;
+    vertical-align: middle;
+  }
+  .navbar-form .form-control-static {
+    display: inline-block;
+  }
+  .navbar-form .input-group {
+    display: inline-table;
+    vertical-align: middle;
+  }
+  .navbar-form .input-group .input-group-addon,
+  .navbar-form .input-group .input-group-btn,
+  .navbar-form .input-group .form-control {
+    width: auto;
+  }
+  .navbar-form .input-group > .form-control {
+    width: 100%;
+  }
+  .navbar-form .control-label {
+    margin-bottom: 0;
+    vertical-align: middle;
+  }
+  .navbar-form .radio,
+  .navbar-form .checkbox {
+    display: inline-block;
+    margin-top: 0;
+    margin-bottom: 0;
+    vertical-align: middle;
+  }
+  .navbar-form .radio label,
+  .navbar-form .checkbox label {
+    padding-left: 0;
+  }
+  .navbar-form .radio input[type="radio"],
+  .navbar-form .checkbox input[type="checkbox"] {
+    position: relative;
+    margin-left: 0;
+  }
+  .navbar-form .has-feedback .form-control-feedback {
+    top: 0;
+  }
+}
+@media (max-width: 767px) {
+  .navbar-form .form-group {
+    margin-bottom: 5px;
+  }
+  .navbar-form .form-group:last-child {
+    margin-bottom: 0;
+  }
+}
+@media (min-width: 768px) {
+  .navbar-form {
+    width: auto;
+    padding-top: 0;
+    padding-bottom: 0;
+    margin-right: 0;
+    margin-left: 0;
+    border: 0;
+    -webkit-box-shadow: none;
+            box-shadow: none;
+  }
+}
+.navbar-nav > li > .dropdown-menu {
+  margin-top: 0;
+  border-top-left-radius: 0;
+  border-top-right-radius: 0;
+}
+.navbar-fixed-bottom .navbar-nav > li > .dropdown-menu {
+  margin-bottom: 0;
+  border-top-left-radius: 4px;
+  border-top-right-radius: 4px;
+  border-bottom-right-radius: 0;
+  border-bottom-left-radius: 0;
+}
+.navbar-btn {
+  margin-top: 8px;
+  margin-bottom: 8px;
+}
+.navbar-btn.btn-sm {
+  margin-top: 10px;
+  margin-bottom: 10px;
+}
+.navbar-btn.btn-xs {
+  margin-top: 14px;
+  margin-bottom: 14px;
+}
+.navbar-text {
+  margin-top: 15px;
+  margin-bottom: 15px;
+}
+@media (min-width: 768px) {
+  .navbar-text {
+    float: left;
+    margin-right: 15px;
+    margin-left: 15px;
+  }
+}
+@media (min-width: 768px) {
+  .navbar-left {
+    float: left !important;
+  }
+  .navbar-right {
+    float: right !important;
+    margin-right: -15px;
+  }
+  .navbar-right ~ .navbar-right {
+    margin-right: 0;
+  }
+}
+.navbar-default {
+  background-color: #f8f8f8;
+  border-color: #e7e7e7;
+}
+.navbar-default .navbar-brand {
+  color: #777;
+}
+.navbar-default .navbar-brand:hover,
+.navbar-default .navbar-brand:focus {
+  color: #5e5e5e;
+  background-color: transparent;
+}
+.navbar-default .navbar-text {
+  color: #777;
+}
+.navbar-default .navbar-nav > li > a {
+  color: #777;
+}
+.navbar-default .navbar-nav > li > a:hover,
+.navbar-default .navbar-nav > li > a:focus {
+  color: #333;
+  background-color: transparent;
+}
+.navbar-default .navbar-nav > .active > a,
+.navbar-default .navbar-nav > .active > a:hover,
+.navbar-default .navbar-nav > .active > a:focus {
+  color: #555;
+  background-color: #e7e7e7;
+}
+.navbar-default .navbar-nav > .disabled > a,
+.navbar-default .navbar-nav > .disabled > a:hover,
+.navbar-default .navbar-nav > .disabled > a:focus {
+  color: #ccc;
+  background-color: transparent;
+}
+.navbar-default .navbar-toggle {
+  border-color: #ddd;
+}
+.navbar-default .navbar-toggle:hover,
+.navbar-default .navbar-toggle:focus {
+  background-color: #ddd;
+}
+.navbar-default .navbar-toggle .icon-bar {
+  background-color: #888;
+}
+.navbar-default .navbar-collapse,
+.navbar-default .navbar-form {
+  border-color: #e7e7e7;
+}
+.navbar-default .navbar-nav > .open > a,
+.navbar-default .navbar-nav > .open > a:hover,
+.navbar-default .navbar-nav > .open > a:focus {
+  color: #555;
+  background-color: #e7e7e7;
+}
+@media (max-width: 767px) {
+  .navbar-default .navbar-nav .open .dropdown-menu > li > a {
+    color: #777;
+  }
+  .navbar-default .navbar-nav .open .dropdown-menu > li > a:hover,
+  .navbar-default .navbar-nav .open .dropdown-menu > li > a:focus {
+    color: #333;
+    background-color: transparent;
+  }
+  .navbar-default .navbar-nav .open .dropdown-menu > .active > a,
+  .navbar-default .navbar-nav .open .dropdown-menu > .active > a:hover,
+  .navbar-default .navbar-nav .open .dropdown-menu > .active > a:focus {
+    color: #555;
+    background-color: #e7e7e7;
+  }
+  .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a,
+  .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a:hover,
+  .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a:focus {
+    color: #ccc;
+    background-color: transparent;
+  }
+}
+.navbar-default .navbar-link {
+  color: #777;
+}
+.navbar-default .navbar-link:hover {
+  color: #333;
+}
+.navbar-default .btn-link {
+  color: #777;
+}
+.navbar-default .btn-link:hover,
+.navbar-default .btn-link:focus {
+  color: #333;
+}
+.navbar-default .btn-link[disabled]:hover,
+fieldset[disabled] .navbar-default .btn-link:hover,
+.navbar-default .btn-link[disabled]:focus,
+fieldset[disabled] .navbar-default .btn-link:focus {
+  color: #ccc;
+}
+.navbar-inverse {
+  background-color: #222;
+  border-color: #080808;
+}
+.navbar-inverse .navbar-brand {
+  color: #9d9d9d;
+}
+.navbar-inverse .navbar-brand:hover,
+.navbar-inverse .navbar-brand:focus {
+  color: #fff;
+  background-color: transparent;
+}
+.navbar-inverse .navbar-text {
+  color: #9d9d9d;
+}
+.navbar-inverse .navbar-nav > li > a {
+  color: #9d9d9d;
+}
+.navbar-inverse .navbar-nav > li > a:hover,
+.navbar-inverse .navbar-nav > li > a:focus {
+  color: #fff;
+  background-color: transparent;
+}
+.navbar-inverse .navbar-nav > .active > a,
+.navbar-inverse .navbar-nav > .active > a:hover,
+.navbar-inverse .navbar-nav > .active > a:focus {
+  color: #fff;
+  background-color: #080808;
+}
+.navbar-inverse .navbar-nav > .disabled > a,
+.navbar-inverse .navbar-nav > .disabled > a:hover,
+.navbar-inverse .navbar-nav > .disabled > a:focus {
+  color: #444;
+  background-color: transparent;
+}
+.navbar-inverse .navbar-toggle {
+  border-color: #333;
+}
+.navbar-inverse .navbar-toggle:hover,
+.navbar-inverse .navbar-toggle:focus {
+  background-color: #333;
+}
+.navbar-inverse .navbar-toggle .icon-bar {
+  background-color: #fff;
+}
+.navbar-inverse .navbar-collapse,
+.navbar-inverse .navbar-form {
+  border-color: #101010;
+}
+.navbar-inverse .navbar-nav > .open > a,
+.navbar-inverse .navbar-nav > .open > a:hover,
+.navbar-inverse .navbar-nav > .open > a:focus {
+  color: #fff;
+  background-color: #080808;
+}
+@media (max-width: 767px) {
+  .navbar-inverse .navbar-nav .open .dropdown-menu > .dropdown-header {
+    border-color: #080808;
+  }
+  .navbar-inverse .navbar-nav .open .dropdown-menu .divider {
+    background-color: #080808;
+  }
+  .navbar-inverse .navbar-nav .open .dropdown-menu > li > a {
+    color: #9d9d9d;
+  }
+  .navbar-inverse .navbar-nav .open .dropdown-menu > li > a:hover,
+  .navbar-inverse .navbar-nav .open .dropdown-menu > li > a:focus {
+    color: #fff;
+    background-color: transparent;
+  }
+  .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a,
+  .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a:hover,
+  .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a:focus {
+    color: #fff;
+    background-color: #080808;
+  }
+  .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a,
+  .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a:hover,
+  .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a:focus {
+    color: #444;
+    background-color: transparent;
+  }
+}
+.navbar-inverse .navbar-link {
+  color: #9d9d9d;
+}
+.navbar-inverse .navbar-link:hover {
+  color: #fff;
+}
+.navbar-inverse .btn-link {
+  color: #9d9d9d;
+}
+.navbar-inverse .btn-link:hover,
+.navbar-inverse .btn-link:focus {
+  color: #fff;
+}
+.navbar-inverse .btn-link[disabled]:hover,
+fieldset[disabled] .navbar-inverse .btn-link:hover,
+.navbar-inverse .btn-link[disabled]:focus,
+fieldset[disabled] .navbar-inverse .btn-link:focus {
+  color: #444;
+}
+.breadcrumb {
+  padding: 8px 15px;
+  margin-bottom: 20px;
+  list-style: none;
+  background-color: #f5f5f5;
+  border-radius: 4px;
+}
+.breadcrumb > li {
+  display: inline-block;
+}
+.breadcrumb > li + li:before {
+  padding: 0 5px;
+  color: #ccc;
+  content: "/\00a0";
+}
+.breadcrumb > .active {
+  color: #777;
+}
+.pagination {
+  display: inline-block;
+  padding-left: 0;
+  margin: 20px 0;
+  border-radius: 4px;
+}
+.pagination > li {
+  display: inline;
+}
+.pagination > li > a,
+.pagination > li > span {
+  position: relative;
+  float: left;
+  padding: 6px 12px;
+  margin-left: -1px;
+  line-height: 1.42857143;
+  color: #337ab7;
+  text-decoration: none;
+  background-color: #fff;
+  border: 1px solid #ddd;
+}
+.pagination > li:first-child > a,
+.pagination > li:first-child > span {
+  margin-left: 0;
+  border-top-left-radius: 4px;
+  border-bottom-left-radius: 4px;
+}
+.pagination > li:last-child > a,
+.pagination > li:last-child > span {
+  border-top-right-radius: 4px;
+  border-bottom-right-radius: 4px;
+}
+.pagination > li > a:hover,
+.pagination > li > span:hover,
+.pagination > li > a:focus,
+.pagination > li > span:focus {
+  z-index: 2;
+  color: #23527c;
+  background-color: #eee;
+  border-color: #ddd;
+}
+.pagination > .active > a,
+.pagination > .active > span,
+.pagination > .active > a:hover,
+.pagination > .active > span:hover,
+.pagination > .active > a:focus,
+.pagination > .active > span:focus {
+  z-index: 3;
+  color: #fff;
+  cursor: default;
+  background-color: #337ab7;
+  border-color: #337ab7;
+}
+.pagination > .disabled > span,
+.pagination > .disabled > span:hover,
+.pagination > .disabled > span:focus,
+.pagination > .disabled > a,
+.pagination > .disabled > a:hover,
+.pagination > .disabled > a:focus {
+  color: #777;
+  cursor: not-allowed;
+  background-color: #fff;
+  border-color: #ddd;
+}
+.pagination-lg > li > a,
+.pagination-lg > li > span {
+  padding: 10px 16px;
+  font-size: 18px;
+  line-height: 1.3333333;
+}
+.pagination-lg > li:first-child > a,
+.pagination-lg > li:first-child > span {
+  border-top-left-radius: 6px;
+  border-bottom-left-radius: 6px;
+}
+.pagination-lg > li:last-child > a,
+.pagination-lg > li:last-child > span {
+  border-top-right-radius: 6px;
+  border-bottom-right-radius: 6px;
+}
+.pagination-sm > li > a,
+.pagination-sm > li > span {
+  padding: 5px 10px;
+  font-size: 12px;
+  line-height: 1.5;
+}
+.pagination-sm > li:first-child > a,
+.pagination-sm > li:first-child > span {
+  border-top-left-radius: 3px;
+  border-bottom-left-radius: 3px;
+}
+.pagination-sm > li:last-child > a,
+.pagination-sm > li:last-child > span {
+  border-top-right-radius: 3px;
+  border-bottom-right-radius: 3px;
+}
+.pager {
+  padding-left: 0;
+  margin: 20px 0;
+  text-align: center;
+  list-style: none;
+}
+.pager li {
+  display: inline;
+}
+.pager li > a,
+.pager li > span {
+  display: inline-block;
+  padding: 5px 14px;
+  background-color: #fff;
+  border: 1px solid #ddd;
+  border-radius: 15px;
+}
+.pager li > a:hover,
+.pager li > a:focus {
+  text-decoration: none;
+  background-color: #eee;
+}
+.pager .next > a,
+.pager .next > span {
+  float: right;
+}
+.pager .previous > a,
+.pager .previous > span {
+  float: left;
+}
+.pager .disabled > a,
+.pager .disabled > a:hover,
+.pager .disabled > a:focus,
+.pager .disabled > span {
+  color: #777;
+  cursor: not-allowed;
+  background-color: #fff;
+}
+.label {
+  display: inline;
+  padding: .2em .6em .3em;
+  font-size: 75%;
+  font-weight: bold;
+  line-height: 1;
+  color: #fff;
+  text-align: center;
+  white-space: nowrap;
+  vertical-align: baseline;
+  border-radius: .25em;
+}
+a.label:hover,
+a.label:focus {
+  color: #fff;
+  text-decoration: none;
+  cursor: pointer;
+}
+.label:empty {
+  display: none;
+}
+.btn .label {
+  position: relative;
+  top: -1px;
+}
+.label-default {
+  background-color: #777;
+}
+.label-default[href]:hover,
+.label-default[href]:focus {
+  background-color: #5e5e5e;
+}
+.label-primary {
+  background-color: #337ab7;
+}
+.label-primary[href]:hover,
+.label-primary[href]:focus {
+  background-color: #286090;
+}
+.label-success {
+  background-color: #5cb85c;
+}
+.label-success[href]:hover,
+.label-success[href]:focus {
+  background-color: #449d44;
+}
+.label-info {
+  background-color: #5bc0de;
+}
+.label-info[href]:hover,
+.label-info[href]:focus {
+  background-color: #31b0d5;
+}
+.label-warning {
+  background-color: #f0ad4e;
+}
+.label-warning[href]:hover,
+.label-warning[href]:focus {
+  background-color: #ec971f;
+}
+.label-danger {
+  background-color: #d9534f;
+}
+.label-danger[href]:hover,
+.label-danger[href]:focus {
+  background-color: #c9302c;
+}
+.badge {
+  display: inline-block;
+  min-width: 10px;
+  padding: 3px 7px;
+  font-size: 12px;
+  font-weight: bold;
+  line-height: 1;
+  color: #fff;
+  text-align: center;
+  white-space: nowrap;
+  vertical-align: middle;
+  background-color: #777;
+  border-radius: 10px;
+}
+.badge:empty {
+  display: none;
+}
+.btn .badge {
+  position: relative;
+  top: -1px;
+}
+.btn-xs .badge,
+.btn-group-xs > .btn .badge {
+  top: 0;
+  padding: 1px 5px;
+}
+a.badge:hover,
+a.badge:focus {
+  color: #fff;
+  text-decoration: none;
+  cursor: pointer;
+}
+.list-group-item.active > .badge,
+.nav-pills > .active > a > .badge {
+  color: #337ab7;
+  background-color: #fff;
+}
+.list-group-item > .badge {
+  float: right;
+}
+.list-group-item > .badge + .badge {
+  margin-right: 5px;
+}
+.nav-pills > li > a > .badge {
+  margin-left: 3px;
+}
+.jumbotron {
+  padding-top: 30px;
+  padding-bottom: 30px;
+  margin-bottom: 30px;
+  color: inherit;
+  background-color: #eee;
+}
+.jumbotron h1,
+.jumbotron .h1 {
+  color: inherit;
+}
+.jumbotron p {
+  margin-bottom: 15px;
+  font-size: 21px;
+  font-weight: 200;
+}
+.jumbotron > hr {
+  border-top-color: #d5d5d5;
+}
+.container .jumbotron,
+.container-fluid .jumbotron {
+  padding-right: 15px;
+  padding-left: 15px;
+  border-radius: 6px;
+}
+.jumbotron .container {
+  max-width: 100%;
+}
+@media screen and (min-width: 768px) {
+  .jumbotron {
+    padding-top: 48px;
+    padding-bottom: 48px;
+  }
+  .container .jumbotron,
+  .container-fluid .jumbotron {
+    padding-right: 60px;
+    padding-left: 60px;
+  }
+  .jumbotron h1,
+  .jumbotron .h1 {
+    font-size: 63px;
+  }
+}
+.thumbnail {
+  display: block;
+  padding: 4px;
+  margin-bottom: 20px;
+  line-height: 1.42857143;
+  background-color: #fff;
+  border: 1px solid #ddd;
+  border-radius: 4px;
+  -webkit-transition: border .2s ease-in-out;
+       -o-transition: border .2s ease-in-out;
+          transition: border .2s ease-in-out;
+}
+.thumbnail > img,
+.thumbnail a > img {
+  margin-right: auto;
+  margin-left: auto;
+}
+a.thumbnail:hover,
+a.thumbnail:focus,
+a.thumbnail.active {
+  border-color: #337ab7;
+}
+.thumbnail .caption {
+  padding: 9px;
+  color: #333;
+}
+.alert {
+  padding: 15px;
+  margin-bottom: 20px;
+  border: 1px solid transparent;
+  border-radius: 4px;
+}
+.alert h4 {
+  margin-top: 0;
+  color: inherit;
+}
+.alert .alert-link {
+  font-weight: bold;
+}
+.alert > p,
+.alert > ul {
+  margin-bottom: 0;
+}
+.alert > p + p {
+  margin-top: 5px;
+}
+.alert-dismissable,
+.alert-dismissible {
+  padding-right: 35px;
+}
+.alert-dismissable .close,
+.alert-dismissible .close {
+  position: relative;
+  top: -2px;
+  right: -21px;
+  color: inherit;
+}
+.alert-success {
+  color: #3c763d;
+  background-color: #dff0d8;
+  border-color: #d6e9c6;
+}
+.alert-success hr {
+  border-top-color: #c9e2b3;
+}
+.alert-success .alert-link {
+  color: #2b542c;
+}
+.alert-info {
+  color: #31708f;
+  background-color: #d9edf7;
+  border-color: #bce8f1;
+}
+.alert-info hr {
+  border-top-color: #a6e1ec;
+}
+.alert-info .alert-link {
+  color: #245269;
+}
+.alert-warning {
+  color: #8a6d3b;
+  background-color: #fcf8e3;
+  border-color: #faebcc;
+}
+.alert-warning hr {
+  border-top-color: #f7e1b5;
+}
+.alert-warning .alert-link {
+  color: #66512c;
+}
+.alert-danger {
+  color: #a94442;
+  background-color: #f2dede;
+  border-color: #ebccd1;
+}
+.alert-danger hr {
+  border-top-color: #e4b9c0;
+}
+.alert-danger .alert-link {
+  color: #843534;
+}
+@-webkit-keyframes progress-bar-stripes {
+  from {
+    background-position: 40px 0;
+  }
+  to {
+    background-position: 0 0;
+  }
+}
+@-o-keyframes progress-bar-stripes {
+  from {
+    background-position: 40px 0;
+  }
+  to {
+    background-position: 0 0;
+  }
+}
+@keyframes progress-bar-stripes {
+  from {
+    background-position: 40px 0;
+  }
+  to {
+    background-position: 0 0;
+  }
+}
+.progress {
+  height: 20px;
+  margin-bottom: 20px;
+  overflow: hidden;
+  background-color: #f5f5f5;
+  border-radius: 4px;
+  -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, .1);
+          box-shadow: inset 0 1px 2px rgba(0, 0, 0, .1);
+}
+.progress-bar {
+  float: left;
+  width: 0;
+  height: 100%;
+  font-size: 12px;
+  line-height: 20px;
+  color: #fff;
+  text-align: center;
+  background-color: #337ab7;
+  -webkit-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, .15);
+          box-shadow: inset 0 -1px 0 rgba(0, 0, 0, .15);
+  -webkit-transition: width .6s ease;
+       -o-transition: width .6s ease;
+          transition: width .6s ease;
+}
+.progress-striped .progress-bar,
+.progress-bar-striped {
+  background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
+  background-image:      -o-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
+  background-image:         linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
+  -webkit-background-size: 40px 40px;
+          background-size: 40px 40px;
+}
+.progress.active .progress-bar,
+.progress-bar.active {
+  -webkit-animation: progress-bar-stripes 2s linear infinite;
+       -o-animation: progress-bar-stripes 2s linear infinite;
+          animation: progress-bar-stripes 2s linear infinite;
+}
+.progress-bar-success {
+  background-color: #5cb85c;
+}
+.progress-striped .progress-bar-success {
+  background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
+  background-image:      -o-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
+  background-image:         linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
+}
+.progress-bar-info {
+  background-color: #5bc0de;
+}
+.progress-striped .progress-bar-info {
+  background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
+  background-image:      -o-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
+  background-image:         linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
+}
+.progress-bar-warning {
+  background-color: #f0ad4e;
+}
+.progress-striped .progress-bar-warning {
+  background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
+  background-image:      -o-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
+  background-image:         linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
+}
+.progress-bar-danger {
+  background-color: #d9534f;
+}
+.progress-striped .progress-bar-danger {
+  background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
+  background-image:      -o-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
+  background-image:         linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);
+}
+.media {
+  margin-top: 15px;
+}
+.media:first-child {
+  margin-top: 0;
+}
+.media,
+.media-body {
+  overflow: hidden;
+  zoom: 1;
+}
+.media-body {
+  width: 10000px;
+}
+.media-object {
+  display: block;
+}
+.media-object.img-thumbnail {
+  max-width: none;
+}
+.media-right,
+.media > .pull-right {
+  padding-left: 10px;
+}
+.media-left,
+.media > .pull-left {
+  padding-right: 10px;
+}
+.media-left,
+.media-right,
+.media-body {
+  display: table-cell;
+  vertical-align: top;
+}
+.media-middle {
+  vertical-align: middle;
+}
+.media-bottom {
+  vertical-align: bottom;
+}
+.media-heading {
+  margin-top: 0;
+  margin-bottom: 5px;
+}
+.media-list {
+  padding-left: 0;
+  list-style: none;
+}
+.list-group {
+  padding-left: 0;
+  margin-bottom: 20px;
+}
+.list-group-item {
+  position: relative;
+  display: block;
+  padding: 10px 15px;
+  margin-bottom: -1px;
+  background-color: #fff;
+  border: 1px solid #ddd;
+}
+.list-group-item:first-child {
+  border-top-left-radius: 4px;
+  border-top-right-radius: 4px;
+}
+.list-group-item:last-child {
+  margin-bottom: 0;
+  border-bottom-right-radius: 4px;
+  border-bottom-left-radius: 4px;
+}
+a.list-group-item,
+button.list-group-item {
+  color: #555;
+}
+a.list-group-item .list-group-item-heading,
+button.list-group-item .list-group-item-heading {
+  color: #333;
+}
+a.list-group-item:hover,
+button.list-group-item:hover,
+a.list-group-item:focus,
+button.list-group-item:focus {
+  color: #555;
+  text-decoration: none;
+  background-color: #f5f5f5;
+}
+button.list-group-item {
+  width: 100%;
+  text-align: left;
+}
+.list-group-item.disabled,
+.list-group-item.disabled:hover,
+.list-group-item.disabled:focus {
+  color: #777;
+  cursor: not-allowed;
+  background-color: #eee;
+}
+.list-group-item.disabled .list-group-item-heading,
+.list-group-item.disabled:hover .list-group-item-heading,
+.list-group-item.disabled:focus .list-group-item-heading {
+  color: inherit;
+}
+.list-group-item.disabled .list-group-item-text,
+.list-group-item.disabled:hover .list-group-item-text,
+.list-group-item.disabled:focus .list-group-item-text {
+  color: #777;
+}
+.list-group-item.active,
+.list-group-item.active:hover,
+.list-group-item.active:focus {
+  z-index: 2;
+  color: #fff;
+  background-color: #337ab7;
+  border-color: #337ab7;
+}
+.list-group-item.active .list-group-item-heading,
+.list-group-item.active:hover .list-group-item-heading,
+.list-group-item.active:focus .list-group-item-heading,
+.list-group-item.active .list-group-item-heading > small,
+.list-group-item.active:hover .list-group-item-heading > small,
+.list-group-item.active:focus .list-group-item-heading > small,
+.list-group-item.active .list-group-item-heading > .small,
+.list-group-item.active:hover .list-group-item-heading > .small,
+.list-group-item.active:focus .list-group-item-heading > .small {
+  color: inherit;
+}
+.list-group-item.active .list-group-item-text,
+.list-group-item.active:hover .list-group-item-text,
+.list-group-item.active:focus .list-group-item-text {
+  color: #c7ddef;
+}
+.list-group-item-success {
+  color: #3c763d;
+  background-color: #dff0d8;
+}
+a.list-group-item-success,
+button.list-group-item-success {
+  color: #3c763d;
+}
+a.list-group-item-success .list-group-item-heading,
+button.list-group-item-success .list-group-item-heading {
+  color: inherit;
+}
+a.list-group-item-success:hover,
+button.list-group-item-success:hover,
+a.list-group-item-success:focus,
+button.list-group-item-success:focus {
+  color: #3c763d;
+  background-color: #d0e9c6;
+}
+a.list-group-item-success.active,
+button.list-group-item-success.active,
+a.list-group-item-success.active:hover,
+button.list-group-item-success.active:hover,
+a.list-group-item-success.active:focus,
+button.list-group-item-success.active:focus {
+  color: #fff;
+  background-color: #3c763d;
+  border-color: #3c763d;
+}
+.list-group-item-info {
+  color: #31708f;
+  background-color: #d9edf7;
+}
+a.list-group-item-info,
+button.list-group-item-info {
+  color: #31708f;
+}
+a.list-group-item-info .list-group-item-heading,
+button.list-group-item-info .list-group-item-heading {
+  color: inherit;
+}
+a.list-group-item-info:hover,
+button.list-group-item-info:hover,
+a.list-group-item-info:focus,
+button.list-group-item-info:focus {
+  color: #31708f;
+  background-color: #c4e3f3;
+}
+a.list-group-item-info.active,
+button.list-group-item-info.active,
+a.list-group-item-info.active:hover,
+button.list-group-item-info.active:hover,
+a.list-group-item-info.active:focus,
+button.list-group-item-info.active:focus {
+  color: #fff;
+  background-color: #31708f;
+  border-color: #31708f;
+}
+.list-group-item-warning {
+  color: #8a6d3b;
+  background-color: #fcf8e3;
+}
+a.list-group-item-warning,
+button.list-group-item-warning {
+  color: #8a6d3b;
+}
+a.list-group-item-warning .list-group-item-heading,
+button.list-group-item-warning .list-group-item-heading {
+  color: inherit;
+}
+a.list-group-item-warning:hover,
+button.list-group-item-warning:hover,
+a.list-group-item-warning:focus,
+button.list-group-item-warning:focus {
+  color: #8a6d3b;
+  background-color: #faf2cc;
+}
+a.list-group-item-warning.active,
+button.list-group-item-warning.active,
+a.list-group-item-warning.active:hover,
+button.list-group-item-warning.active:hover,
+a.list-group-item-warning.active:focus,
+button.list-group-item-warning.active:focus {
+  color: #fff;
+  background-color: #8a6d3b;
+  border-color: #8a6d3b;
+}
+.list-group-item-danger {
+  color: #a94442;
+  background-color: #f2dede;
+}
+a.list-group-item-danger,
+button.list-group-item-danger {
+  color: #a94442;
+}
+a.list-group-item-danger .list-group-item-heading,
+button.list-group-item-danger .list-group-item-heading {
+  color: inherit;
+}
+a.list-group-item-danger:hover,
+button.list-group-item-danger:hover,
+a.list-group-item-danger:focus,
+button.list-group-item-danger:focus {
+  color: #a94442;
+  background-color: #ebcccc;
+}
+a.list-group-item-danger.active,
+button.list-group-item-danger.active,
+a.list-group-item-danger.active:hover,
+button.list-group-item-danger.active:hover,
+a.list-group-item-danger.active:focus,
+button.list-group-item-danger.active:focus {
+  color: #fff;
+  background-color: #a94442;
+  border-color: #a94442;
+}
+.list-group-item-heading {
+  margin-top: 0;
+  margin-bottom: 5px;
+}
+.list-group-item-text {
+  margin-bottom: 0;
+  line-height: 1.3;
+}
+.panel {
+  margin-bottom: 20px;
+  background-color: #fff;
+  border: 1px solid transparent;
+  border-radius: 4px;
+  -webkit-box-shadow: 0 1px 1px rgba(0, 0, 0, .05);
+          box-shadow: 0 1px 1px rgba(0, 0, 0, .05);
+}
+.panel-body {
+  padding: 15px;
+}
+.panel-heading {
+  padding: 10px 15px;
+  border-bottom: 1px solid transparent;
+  border-top-left-radius: 3px;
+  border-top-right-radius: 3px;
+}
+.panel-heading > .dropdown .dropdown-toggle {
+  color: inherit;
+}
+.panel-title {
+  margin-top: 0;
+  margin-bottom: 0;
+  font-size: 16px;
+  color: inherit;
+}
+.panel-title > a,
+.panel-title > small,
+.panel-title > .small,
+.panel-title > small > a,
+.panel-title > .small > a {
+  color: inherit;
+}
+.panel-footer {
+  padding: 10px 15px;
+  background-color: #f5f5f5;
+  border-top: 1px solid #ddd;
+  border-bottom-right-radius: 3px;
+  border-bottom-left-radius: 3px;
+}
+.panel > .list-group,
+.panel > .panel-collapse > .list-group {
+  margin-bottom: 0;
+}
+.panel > .list-group .list-group-item,
+.panel > .panel-collapse > .list-group .list-group-item {
+  border-width: 1px 0;
+  border-radius: 0;
+}
+.panel > .list-group:first-child .list-group-item:first-child,
+.panel > .panel-collapse > .list-group:first-child .list-group-item:first-child {
+  border-top: 0;
+  border-top-left-radius: 3px;
+  border-top-right-radius: 3px;
+}
+.panel > .list-group:last-child .list-group-item:last-child,
+.panel > .panel-collapse > .list-group:last-child .list-group-item:last-child {
+  border-bottom: 0;
+  border-bottom-right-radius: 3px;
+  border-bottom-left-radius: 3px;
+}
+.panel > .panel-heading + .panel-collapse > .list-group .list-group-item:first-child {
+  border-top-left-radius: 0;
+  border-top-right-radius: 0;
+}
+.panel-heading + .list-group .list-group-item:first-child {
+  border-top-width: 0;
+}
+.list-group + .panel-footer {
+  border-top-width: 0;
+}
+.panel > .table,
+.panel > .table-responsive > .table,
+.panel > .panel-collapse > .table {
+  margin-bottom: 0;
+}
+.panel > .table caption,
+.panel > .table-responsive > .table caption,
+.panel > .panel-collapse > .table caption {
+  padding-right: 15px;
+  padding-left: 15px;
+}
+.panel > .table:first-child,
+.panel > .table-responsive:first-child > .table:first-child {
+  border-top-left-radius: 3px;
+  border-top-right-radius: 3px;
+}
+.panel > .table:first-child > thead:first-child > tr:first-child,
+.panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child,
+.panel > .table:first-child > tbody:first-child > tr:first-child,
+.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child {
+  border-top-left-radius: 3px;
+  border-top-right-radius: 3px;
+}
+.panel > .table:first-child > thead:first-child > tr:first-child td:first-child,
+.panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child td:first-child,
+.panel > .table:first-child > tbody:first-child > tr:first-child td:first-child,
+.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child td:first-child,
+.panel > .table:first-child > thead:first-child > tr:first-child th:first-child,
+.panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child th:first-child,
+.panel > .table:first-child > tbody:first-child > tr:first-child th:first-child,
+.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child th:first-child {
+  border-top-left-radius: 3px;
+}
+.panel > .table:first-child > thead:first-child > tr:first-child td:last-child,
+.panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child td:last-child,
+.panel > .table:first-child > tbody:first-child > tr:first-child td:last-child,
+.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child td:last-child,
+.panel > .table:first-child > thead:first-child > tr:first-child th:last-child,
+.panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child th:last-child,
+.panel > .table:first-child > tbody:first-child > tr:first-child th:last-child,
+.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child th:last-child {
+  border-top-right-radius: 3px;
+}
+.panel > .table:last-child,
+.panel > .table-responsive:last-child > .table:last-child {
+  border-bottom-right-radius: 3px;
+  border-bottom-left-radius: 3px;
+}
+.panel > .table:last-child > tbody:last-child > tr:last-child,
+.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child,
+.panel > .table:last-child > tfoot:last-child > tr:last-child,
+.panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child {
+  border-bottom-right-radius: 3px;
+  border-bottom-left-radius: 3px;
+}
+.panel > .table:last-child > tbody:last-child > tr:last-child td:first-child,
+.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child td:first-child,
+.panel > .table:last-child > tfoot:last-child > tr:last-child td:first-child,
+.panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child td:first-child,
+.panel > .table:last-child > tbody:last-child > tr:last-child th:first-child,
+.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child th:first-child,
+.panel > .table:last-child > tfoot:last-child > tr:last-child th:first-child,
+.panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child th:first-child {
+  border-bottom-left-radius: 3px;
+}
+.panel > .table:last-child > tbody:last-child > tr:last-child td:last-child,
+.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child td:last-child,
+.panel > .table:last-child > tfoot:last-child > tr:last-child td:last-child,
+.panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child td:last-child,
+.panel > .table:last-child > tbody:last-child > tr:last-child th:last-child,
+.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child th:last-child,
+.panel > .table:last-child > tfoot:last-child > tr:last-child th:last-child,
+.panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child th:last-child {
+  border-bottom-right-radius: 3px;
+}
+.panel > .panel-body + .table,
+.panel > .panel-body + .table-responsive,
+.panel > .table + .panel-body,
+.panel > .table-responsive + .panel-body {
+  border-top: 1px solid #ddd;
+}
+.panel > .table > tbody:first-child > tr:first-child th,
+.panel > .table > tbody:first-child > tr:first-child td {
+  border-top: 0;
+}
+.panel > .table-bordered,
+.panel > .table-responsive > .table-bordered {
+  border: 0;
+}
+.panel > .table-bordered > thead > tr > th:first-child,
+.panel > .table-responsive > .table-bordered > thead > tr > th:first-child,
+.panel > .table-bordered > tbody > tr > th:first-child,
+.panel > .table-responsive > .table-bordered > tbody > tr > th:first-child,
+.panel > .table-bordered > tfoot > tr > th:first-child,
+.panel > .table-responsive > .table-bordered > tfoot > tr > th:first-child,
+.panel > .table-bordered > thead > tr > td:first-child,
+.panel > .table-responsive > .table-bordered > thead > tr > td:first-child,
+.panel > .table-bordered > tbody > tr > td:first-child,
+.panel > .table-responsive > .table-bordered > tbody > tr > td:first-child,
+.panel > .table-bordered > tfoot > tr > td:first-child,
+.panel > .table-responsive > .table-bordered > tfoot > tr > td:first-child {
+  border-left: 0;
+}
+.panel > .table-bordered > thead > tr > th:last-child,
+.panel > .table-responsive > .table-bordered > thead > tr > th:last-child,
+.panel > .table-bordered > tbody > tr > th:last-child,
+.panel > .table-responsive > .table-bordered > tbody > tr > th:last-child,
+.panel > .table-bordered > tfoot > tr > th:last-child,
+.panel > .table-responsive > .table-bordered > tfoot > tr > th:last-child,
+.panel > .table-bordered > thead > tr > td:last-child,
+.panel > .table-responsive > .table-bordered > thead > tr > td:last-child,
+.panel > .table-bordered > tbody > tr > td:last-child,
+.panel > .table-responsive > .table-bordered > tbody > tr > td:last-child,
+.panel > .table-bordered > tfoot > tr > td:last-child,
+.panel > .table-responsive > .table-bordered > tfoot > tr > td:last-child {
+  border-right: 0;
+}
+.panel > .table-bordered > thead > tr:first-child > td,
+.panel > .table-responsive > .table-bordered > thead > tr:first-child > td,
+.panel > .table-bordered > tbody > tr:first-child > td,
+.panel > .table-responsive > .table-bordered > tbody > tr:first-child > td,
+.panel > .table-bordered > thead > tr:first-child > th,
+.panel > .table-responsive > .table-bordered > thead > tr:first-child > th,
+.panel > .table-bordered > tbody > tr:first-child > th,
+.panel > .table-responsive > .table-bordered > tbody > tr:first-child > th {
+  border-bottom: 0;
+}
+.panel > .table-bordered > tbody > tr:last-child > td,
+.panel > .table-responsive > .table-bordered > tbody > tr:last-child > td,
+.panel > .table-bordered > tfoot > tr:last-child > td,
+.panel > .table-responsive > .table-bordered > tfoot > tr:last-child > td,
+.panel > .table-bordered > tbody > tr:last-child > th,
+.panel > .table-responsive > .table-bordered > tbody > tr:last-child > th,
+.panel > .table-bordered > tfoot > tr:last-child > th,
+.panel > .table-responsive > .table-bordered > tfoot > tr:last-child > th {
+  border-bottom: 0;
+}
+.panel > .table-responsive {
+  margin-bottom: 0;
+  border: 0;
+}
+.panel-group {
+  margin-bottom: 20px;
+}
+.panel-group .panel {
+  margin-bottom: 0;
+  border-radius: 4px;
+}
+.panel-group .panel + .panel {
+  margin-top: 5px;
+}
+.panel-group .panel-heading {
+  border-bottom: 0;
+}
+.panel-group .panel-heading + .panel-collapse > .panel-body,
+.panel-group .panel-heading + .panel-collapse > .list-group {
+  border-top: 1px solid #ddd;
+}
+.panel-group .panel-footer {
+  border-top: 0;
+}
+.panel-group .panel-footer + .panel-collapse .panel-body {
+  border-bottom: 1px solid #ddd;
+}
+.panel-default {
+  border-color: #ddd;
+}
+.panel-default > .panel-heading {
+  color: #333;
+  background-color: #f5f5f5;
+  border-color: #ddd;
+}
+.panel-default > .panel-heading + .panel-collapse > .panel-body {
+  border-top-color: #ddd;
+}
+.panel-default > .panel-heading .badge {
+  color: #f5f5f5;
+  background-color: #333;
+}
+.panel-default > .panel-footer + .panel-collapse > .panel-body {
+  border-bottom-color: #ddd;
+}
+.panel-primary {
+  border-color: #337ab7;
+}
+.panel-primary > .panel-heading {
+  color: #fff;
+  background-color: #337ab7;
+  border-color: #337ab7;
+}
+.panel-primary > .panel-heading + .panel-collapse > .panel-body {
+  border-top-color: #337ab7;
+}
+.panel-primary > .panel-heading .badge {
+  color: #337ab7;
+  background-color: #fff;
+}
+.panel-primary > .panel-footer + .panel-collapse > .panel-body {
+  border-bottom-color: #337ab7;
+}
+.panel-success {
+  border-color: #d6e9c6;
+}
+.panel-success > .panel-heading {
+  color: #3c763d;
+  background-color: #dff0d8;
+  border-color: #d6e9c6;
+}
+.panel-success > .panel-heading + .panel-collapse > .panel-body {
+  border-top-color: #d6e9c6;
+}
+.panel-success > .panel-heading .badge {
+  color: #dff0d8;
+  background-color: #3c763d;
+}
+.panel-success > .panel-footer + .panel-collapse > .panel-body {
+  border-bottom-color: #d6e9c6;
+}
+.panel-info {
+  border-color: #bce8f1;
+}
+.panel-info > .panel-heading {
+  color: #31708f;
+  background-color: #d9edf7;
+  border-color: #bce8f1;
+}
+.panel-info > .panel-heading + .panel-collapse > .panel-body {
+  border-top-color: #bce8f1;
+}
+.panel-info > .panel-heading .badge {
+  color: #d9edf7;
+  background-color: #31708f;
+}
+.panel-info > .panel-footer + .panel-collapse > .panel-body {
+  border-bottom-color: #bce8f1;
+}
+.panel-warning {
+  border-color: #faebcc;
+}
+.panel-warning > .panel-heading {
+  color: #8a6d3b;
+  background-color: #fcf8e3;
+  border-color: #faebcc;
+}
+.panel-warning > .panel-heading + .panel-collapse > .panel-body {
+  border-top-color: #faebcc;
+}
+.panel-warning > .panel-heading .badge {
+  color: #fcf8e3;
+  background-color: #8a6d3b;
+}
+.panel-warning > .panel-footer + .panel-collapse > .panel-body {
+  border-bottom-color: #faebcc;
+}
+.panel-danger {
+  border-color: #ebccd1;
+}
+.panel-danger > .panel-heading {
+  color: #a94442;
+  background-color: #f2dede;
+  border-color: #ebccd1;
+}
+.panel-danger > .panel-heading + .panel-collapse > .panel-body {
+  border-top-color: #ebccd1;
+}
+.panel-danger > .panel-heading .badge {
+  color: #f2dede;
+  background-color: #a94442;
+}
+.panel-danger > .panel-footer + .panel-collapse > .panel-body {
+  border-bottom-color: #ebccd1;
+}
+.embed-responsive {
+  position: relative;
+  display: block;
+  height: 0;
+  padding: 0;
+  overflow: hidden;
+}
+.embed-responsive .embed-responsive-item,
+.embed-responsive iframe,
+.embed-responsive embed,
+.embed-responsive object,
+.embed-responsive video {
+  position: absolute;
+  top: 0;
+  bottom: 0;
+  left: 0;
+  width: 100%;
+  height: 100%;
+  border: 0;
+}
+.embed-responsive-16by9 {
+  padding-bottom: 56.25%;
+}
+.embed-responsive-4by3 {
+  padding-bottom: 75%;
+}
+.well {
+  min-height: 20px;
+  padding: 19px;
+  margin-bottom: 20px;
+  background-color: #f5f5f5;
+  border: 1px solid #e3e3e3;
+  border-radius: 4px;
+  -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .05);
+          box-shadow: inset 0 1px 1px rgba(0, 0, 0, .05);
+}
+.well blockquote {
+  border-color: #ddd;
+  border-color: rgba(0, 0, 0, .15);
+}
+.well-lg {
+  padding: 24px;
+  border-radius: 6px;
+}
+.well-sm {
+  padding: 9px;
+  border-radius: 3px;
+}
+.close {
+  float: right;
+  font-size: 21px;
+  font-weight: bold;
+  line-height: 1;
+  color: #000;
+  text-shadow: 0 1px 0 #fff;
+  filter: alpha(opacity=20);
+  opacity: .2;
+}
+.close:hover,
+.close:focus {
+  color: #000;
+  text-decoration: none;
+  cursor: pointer;
+  filter: alpha(opacity=50);
+  opacity: .5;
+}
+button.close {
+  -webkit-appearance: none;
+  padding: 0;
+  cursor: pointer;
+  background: transparent;
+  border: 0;
+}
+.modal-open {
+  overflow: hidden;
+}
+.modal {
+  position: fixed;
+  top: 0;
+  right: 0;
+  bottom: 0;
+  left: 0;
+  z-index: 1050;
+  display: none;
+  overflow: hidden;
+  -webkit-overflow-scrolling: touch;
+  outline: 0;
+}
+.modal.fade .modal-dialog {
+  -webkit-transition: -webkit-transform .3s ease-out;
+       -o-transition:      -o-transform .3s ease-out;
+          transition:         transform .3s ease-out;
+  -webkit-transform: translate(0, -25%);
+      -ms-transform: translate(0, -25%);
+       -o-transform: translate(0, -25%);
+          transform: translate(0, -25%);
+}
+.modal.in .modal-dialog {
+  -webkit-transform: translate(0, 0);
+      -ms-transform: translate(0, 0);
+       -o-transform: translate(0, 0);
+          transform: translate(0, 0);
+}
+.modal-open .modal {
+  overflow-x: hidden;
+  overflow-y: auto;
+}
+.modal-dialog {
+  position: relative;
+  width: auto;
+  margin: 10px;
+}
+.modal-content {
+  position: relative;
+  background-color: #fff;
+  -webkit-background-clip: padding-box;
+          background-clip: padding-box;
+  border: 1px solid #999;
+  border: 1px solid rgba(0, 0, 0, .2);
+  border-radius: 6px;
+  outline: 0;
+  -webkit-box-shadow: 0 3px 9px rgba(0, 0, 0, .5);
+          box-shadow: 0 3px 9px rgba(0, 0, 0, .5);
+}
+.modal-backdrop {
+  position: fixed;
+  top: 0;
+  right: 0;
+  bottom: 0;
+  left: 0;
+  z-index: 1040;
+  background-color: #000;
+}
+.modal-backdrop.fade {
+  filter: alpha(opacity=0);
+  opacity: 0;
+}
+.modal-backdrop.in {
+  filter: alpha(opacity=50);
+  opacity: .5;
+}
+.modal-header {
+  padding: 15px;
+  border-bottom: 1px solid #e5e5e5;
+}
+.modal-header .close {
+  margin-top: -2px;
+}
+.modal-title {
+  margin: 0;
+  line-height: 1.42857143;
+}
+.modal-body {
+  position: relative;
+  padding: 15px;
+}
+.modal-footer {
+  padding: 15px;
+  text-align: right;
+  border-top: 1px solid #e5e5e5;
+}
+.modal-footer .btn + .btn {
+  margin-bottom: 0;
+  margin-left: 5px;
+}
+.modal-footer .btn-group .btn + .btn {
+  margin-left: -1px;
+}
+.modal-footer .btn-block + .btn-block {
+  margin-left: 0;
+}
+.modal-scrollbar-measure {
+  position: absolute;
+  top: -9999px;
+  width: 50px;
+  height: 50px;
+  overflow: scroll;
+}
+@media (min-width: 768px) {
+  .modal-dialog {
+    width: 600px;
+    margin: 30px auto;
+  }
+  .modal-content {
+    -webkit-box-shadow: 0 5px 15px rgba(0, 0, 0, .5);
+            box-shadow: 0 5px 15px rgba(0, 0, 0, .5);
+  }
+  .modal-sm {
+    width: 300px;
+  }
+}
+@media (min-width: 992px) {
+  .modal-lg {
+    width: 900px;
+  }
+}
+.tooltip {
+  position: absolute;
+  z-index: 1070;
+  display: block;
+  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
+  font-size: 12px;
+  font-style: normal;
+  font-weight: normal;
+  line-height: 1.42857143;
+  text-align: left;
+  text-align: start;
+  text-decoration: none;
+  text-shadow: none;
+  text-transform: none;
+  letter-spacing: normal;
+  word-break: normal;
+  word-spacing: normal;
+  word-wrap: normal;
+  white-space: normal;
+  filter: alpha(opacity=0);
+  opacity: 0;
+
+  line-break: auto;
+}
+.tooltip.in {
+  filter: alpha(opacity=90);
+  opacity: .9;
+}
+.tooltip.top {
+  padding: 5px 0;
+  margin-top: -3px;
+}
+.tooltip.right {
+  padding: 0 5px;
+  margin-left: 3px;
+}
+.tooltip.bottom {
+  padding: 5px 0;
+  margin-top: 3px;
+}
+.tooltip.left {
+  padding: 0 5px;
+  margin-left: -3px;
+}
+.tooltip-inner {
+  max-width: 200px;
+  padding: 3px 8px;
+  color: #fff;
+  text-align: center;
+  background-color: #000;
+  border-radius: 4px;
+}
+.tooltip-arrow {
+  position: absolute;
+  width: 0;
+  height: 0;
+  border-color: transparent;
+  border-style: solid;
+}
+.tooltip.top .tooltip-arrow {
+  bottom: 0;
+  left: 50%;
+  margin-left: -5px;
+  border-width: 5px 5px 0;
+  border-top-color: #000;
+}
+.tooltip.top-left .tooltip-arrow {
+  right: 5px;
+  bottom: 0;
+  margin-bottom: -5px;
+  border-width: 5px 5px 0;
+  border-top-color: #000;
+}
+.tooltip.top-right .tooltip-arrow {
+  bottom: 0;
+  left: 5px;
+  margin-bottom: -5px;
+  border-width: 5px 5px 0;
+  border-top-color: #000;
+}
+.tooltip.right .tooltip-arrow {
+  top: 50%;
+  left: 0;
+  margin-top: -5px;
+  border-width: 5px 5px 5px 0;
+  border-right-color: #000;
+}
+.tooltip.left .tooltip-arrow {
+  top: 50%;
+  right: 0;
+  margin-top: -5px;
+  border-width: 5px 0 5px 5px;
+  border-left-color: #000;
+}
+.tooltip.bottom .tooltip-arrow {
+  top: 0;
+  left: 50%;
+  margin-left: -5px;
+  border-width: 0 5px 5px;
+  border-bottom-color: #000;
+}
+.tooltip.bottom-left .tooltip-arrow {
+  top: 0;
+  right: 5px;
+  margin-top: -5px;
+  border-width: 0 5px 5px;
+  border-bottom-color: #000;
+}
+.tooltip.bottom-right .tooltip-arrow {
+  top: 0;
+  left: 5px;
+  margin-top: -5px;
+  border-width: 0 5px 5px;
+  border-bottom-color: #000;
+}
+.popover {
+  position: absolute;
+  top: 0;
+  left: 0;
+  z-index: 1060;
+  display: none;
+  max-width: 276px;
+  padding: 1px;
+  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
+  font-size: 14px;
+  font-style: normal;
+  font-weight: normal;
+  line-height: 1.42857143;
+  text-align: left;
+  text-align: start;
+  text-decoration: none;
+  text-shadow: none;
+  text-transform: none;
+  letter-spacing: normal;
+  word-break: normal;
+  word-spacing: normal;
+  word-wrap: normal;
+  white-space: normal;
+  background-color: #fff;
+  -webkit-background-clip: padding-box;
+          background-clip: padding-box;
+  border: 1px solid #ccc;
+  border: 1px solid rgba(0, 0, 0, .2);
+  border-radius: 6px;
+  -webkit-box-shadow: 0 5px 10px rgba(0, 0, 0, .2);
+          box-shadow: 0 5px 10px rgba(0, 0, 0, .2);
+
+  line-break: auto;
+}
+.popover.top {
+  margin-top: -10px;
+}
+.popover.right {
+  margin-left: 10px;
+}
+.popover.bottom {
+  margin-top: 10px;
+}
+.popover.left {
+  margin-left: -10px;
+}
+.popover-title {
+  padding: 8px 14px;
+  margin: 0;
+  font-size: 14px;
+  background-color: #f7f7f7;
+  border-bottom: 1px solid #ebebeb;
+  border-radius: 5px 5px 0 0;
+}
+.popover-content {
+  padding: 9px 14px;
+}
+.popover > .arrow,
+.popover > .arrow:after {
+  position: absolute;
+  display: block;
+  width: 0;
+  height: 0;
+  border-color: transparent;
+  border-style: solid;
+}
+.popover > .arrow {
+  border-width: 11px;
+}
+.popover > .arrow:after {
+  content: "";
+  border-width: 10px;
+}
+.popover.top > .arrow {
+  bottom: -11px;
+  left: 50%;
+  margin-left: -11px;
+  border-top-color: #999;
+  border-top-color: rgba(0, 0, 0, .25);
+  border-bottom-width: 0;
+}
+.popover.top > .arrow:after {
+  bottom: 1px;
+  margin-left: -10px;
+  content: " ";
+  border-top-color: #fff;
+  border-bottom-width: 0;
+}
+.popover.right > .arrow {
+  top: 50%;
+  left: -11px;
+  margin-top: -11px;
+  border-right-color: #999;
+  border-right-color: rgba(0, 0, 0, .25);
+  border-left-width: 0;
+}
+.popover.right > .arrow:after {
+  bottom: -10px;
+  left: 1px;
+  content: " ";
+  border-right-color: #fff;
+  border-left-width: 0;
+}
+.popover.bottom > .arrow {
+  top: -11px;
+  left: 50%;
+  margin-left: -11px;
+  border-top-width: 0;
+  border-bottom-color: #999;
+  border-bottom-color: rgba(0, 0, 0, .25);
+}
+.popover.bottom > .arrow:after {
+  top: 1px;
+  margin-left: -10px;
+  content: " ";
+  border-top-width: 0;
+  border-bottom-color: #fff;
+}
+.popover.left > .arrow {
+  top: 50%;
+  right: -11px;
+  margin-top: -11px;
+  border-right-width: 0;
+  border-left-color: #999;
+  border-left-color: rgba(0, 0, 0, .25);
+}
+.popover.left > .arrow:after {
+  right: 1px;
+  bottom: -10px;
+  content: " ";
+  border-right-width: 0;
+  border-left-color: #fff;
+}
+.carousel {
+  position: relative;
+}
+.carousel-inner {
+  position: relative;
+  width: 100%;
+  overflow: hidden;
+}
+.carousel-inner > .item {
+  position: relative;
+  display: none;
+  -webkit-transition: .6s ease-in-out left;
+       -o-transition: .6s ease-in-out left;
+          transition: .6s ease-in-out left;
+}
+.carousel-inner > .item > img,
+.carousel-inner > .item > a > img {
+  line-height: 1;
+}
+@media all and (transform-3d), (-webkit-transform-3d) {
+  .carousel-inner > .item {
+    -webkit-transition: -webkit-transform .6s ease-in-out;
+         -o-transition:      -o-transform .6s ease-in-out;
+            transition:         transform .6s ease-in-out;
+
+    -webkit-backface-visibility: hidden;
+            backface-visibility: hidden;
+    -webkit-perspective: 1000px;
+            perspective: 1000px;
+  }
+  .carousel-inner > .item.next,
+  .carousel-inner > .item.active.right {
+    left: 0;
+    -webkit-transform: translate3d(100%, 0, 0);
+            transform: translate3d(100%, 0, 0);
+  }
+  .carousel-inner > .item.prev,
+  .carousel-inner > .item.active.left {
+    left: 0;
+    -webkit-transform: translate3d(-100%, 0, 0);
+            transform: translate3d(-100%, 0, 0);
+  }
+  .carousel-inner > .item.next.left,
+  .carousel-inner > .item.prev.right,
+  .carousel-inner > .item.active {
+    left: 0;
+    -webkit-transform: translate3d(0, 0, 0);
+            transform: translate3d(0, 0, 0);
+  }
+}
+.carousel-inner > .active,
+.carousel-inner > .next,
+.carousel-inner > .prev {
+  display: block;
+}
+.carousel-inner > .active {
+  left: 0;
+}
+.carousel-inner > .next,
+.carousel-inner > .prev {
+  position: absolute;
+  top: 0;
+  width: 100%;
+}
+.carousel-inner > .next {
+  left: 100%;
+}
+.carousel-inner > .prev {
+  left: -100%;
+}
+.carousel-inner > .next.left,
+.carousel-inner > .prev.right {
+  left: 0;
+}
+.carousel-inner > .active.left {
+  left: -100%;
+}
+.carousel-inner > .active.right {
+  left: 100%;
+}
+.carousel-control {
+  position: absolute;
+  top: 0;
+  bottom: 0;
+  left: 0;
+  width: 15%;
+  font-size: 20px;
+  color: #fff;
+  text-align: center;
+  text-shadow: 0 1px 2px rgba(0, 0, 0, .6);
+  background-color: rgba(0, 0, 0, 0);
+  filter: alpha(opacity=50);
+  opacity: .5;
+}
+.carousel-control.left {
+  background-image: -webkit-linear-gradient(left, rgba(0, 0, 0, .5) 0%, rgba(0, 0, 0, .0001) 100%);
+  background-image:      -o-linear-gradient(left, rgba(0, 0, 0, .5) 0%, rgba(0, 0, 0, .0001) 100%);
+  background-image: -webkit-gradient(linear, left top, right top, from(rgba(0, 0, 0, .5)), to(rgba(0, 0, 0, .0001)));
+  background-image:         linear-gradient(to right, rgba(0, 0, 0, .5) 0%, rgba(0, 0, 0, .0001) 100%);
+  filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#80000000', endColorstr='#00000000', GradientType=1);
+  background-repeat: repeat-x;
+}
+.carousel-control.right {
+  right: 0;
+  left: auto;
+  background-image: -webkit-linear-gradient(left, rgba(0, 0, 0, .0001) 0%, rgba(0, 0, 0, .5) 100%);
+  background-image:      -o-linear-gradient(left, rgba(0, 0, 0, .0001) 0%, rgba(0, 0, 0, .5) 100%);
+  background-image: -webkit-gradient(linear, left top, right top, from(rgba(0, 0, 0, .0001)), to(rgba(0, 0, 0, .5)));
+  background-image:         linear-gradient(to right, rgba(0, 0, 0, .0001) 0%, rgba(0, 0, 0, .5) 100%);
+  filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#00000000', endColorstr='#80000000', GradientType=1);
+  background-repeat: repeat-x;
+}
+.carousel-control:hover,
+.carousel-control:focus {
+  color: #fff;
+  text-decoration: none;
+  filter: alpha(opacity=90);
+  outline: 0;
+  opacity: .9;
+}
+.carousel-control .icon-prev,
+.carousel-control .icon-next,
+.carousel-control .glyphicon-chevron-left,
+.carousel-control .glyphicon-chevron-right {
+  position: absolute;
+  top: 50%;
+  z-index: 5;
+  display: inline-block;
+  margin-top: -10px;
+}
+.carousel-control .icon-prev,
+.carousel-control .glyphicon-chevron-left {
+  left: 50%;
+  margin-left: -10px;
+}
+.carousel-control .icon-next,
+.carousel-control .glyphicon-chevron-right {
+  right: 50%;
+  margin-right: -10px;
+}
+.carousel-control .icon-prev,
+.carousel-control .icon-next {
+  width: 20px;
+  height: 20px;
+  font-family: serif;
+  line-height: 1;
+}
+.carousel-control .icon-prev:before {
+  content: '\2039';
+}
+.carousel-control .icon-next:before {
+  content: '\203a';
+}
+.carousel-indicators {
+  position: absolute;
+  bottom: 10px;
+  left: 50%;
+  z-index: 15;
+  width: 60%;
+  padding-left: 0;
+  margin-left: -30%;
+  text-align: center;
+  list-style: none;
+}
+.carousel-indicators li {
+  display: inline-block;
+  width: 10px;
+  height: 10px;
+  margin: 1px;
+  text-indent: -999px;
+  cursor: pointer;
+  background-color: #000 \9;
+  background-color: rgba(0, 0, 0, 0);
+  border: 1px solid #fff;
+  border-radius: 10px;
+}
+.carousel-indicators .active {
+  width: 12px;
+  height: 12px;
+  margin: 0;
+  background-color: #fff;
+}
+.carousel-caption {
+  position: absolute;
+  right: 15%;
+  bottom: 20px;
+  left: 15%;
+  z-index: 10;
+  padding-top: 20px;
+  padding-bottom: 20px;
+  color: #fff;
+  text-align: center;
+  text-shadow: 0 1px 2px rgba(0, 0, 0, .6);
+}
+.carousel-caption .btn {
+  text-shadow: none;
+}
+@media screen and (min-width: 768px) {
+  .carousel-control .glyphicon-chevron-left,
+  .carousel-control .glyphicon-chevron-right,
+  .carousel-control .icon-prev,
+  .carousel-control .icon-next {
+    width: 30px;
+    height: 30px;
+    margin-top: -10px;
+    font-size: 30px;
+  }
+  .carousel-control .glyphicon-chevron-left,
+  .carousel-control .icon-prev {
+    margin-left: -10px;
+  }
+  .carousel-control .glyphicon-chevron-right,
+  .carousel-control .icon-next {
+    margin-right: -10px;
+  }
+  .carousel-caption {
+    right: 20%;
+    left: 20%;
+    padding-bottom: 30px;
+  }
+  .carousel-indicators {
+    bottom: 20px;
+  }
+}
+.clearfix:before,
+.clearfix:after,
+.dl-horizontal dd:before,
+.dl-horizontal dd:after,
+.container:before,
+.container:after,
+.container-fluid:before,
+.container-fluid:after,
+.row:before,
+.row:after,
+.form-horizontal .form-group:before,
+.form-horizontal .form-group:after,
+.btn-toolbar:before,
+.btn-toolbar:after,
+.btn-group-vertical > .btn-group:before,
+.btn-group-vertical > .btn-group:after,
+.nav:before,
+.nav:after,
+.navbar:before,
+.navbar:after,
+.navbar-header:before,
+.navbar-header:after,
+.navbar-collapse:before,
+.navbar-collapse:after,
+.pager:before,
+.pager:after,
+.panel-body:before,
+.panel-body:after,
+.modal-header:before,
+.modal-header:after,
+.modal-footer:before,
+.modal-footer:after {
+  display: table;
+  content: " ";
+}
+.clearfix:after,
+.dl-horizontal dd:after,
+.container:after,
+.container-fluid:after,
+.row:after,
+.form-horizontal .form-group:after,
+.btn-toolbar:after,
+.btn-group-vertical > .btn-group:after,
+.nav:after,
+.navbar:after,
+.navbar-header:after,
+.navbar-collapse:after,
+.pager:after,
+.panel-body:after,
+.modal-header:after,
+.modal-footer:after {
+  clear: both;
+}
+.center-block {
+  display: block;
+  margin-right: auto;
+  margin-left: auto;
+}
+.pull-right {
+  float: right !important;
+}
+.pull-left {
+  float: left !important;
+}
+.hide {
+  display: none !important;
+}
+.show {
+  display: block !important;
+}
+.invisible {
+  visibility: hidden;
+}
+.text-hide {
+  font: 0/0 a;
+  color: transparent;
+  text-shadow: none;
+  background-color: transparent;
+  border: 0;
+}
+.hidden {
+  display: none !important;
+}
+.affix {
+  position: fixed;
+}
+@-ms-viewport {
+  width: device-width;
+}
+.visible-xs,
+.visible-sm,
+.visible-md,
+.visible-lg {
+  display: none !important;
+}
+.visible-xs-block,
+.visible-xs-inline,
+.visible-xs-inline-block,
+.visible-sm-block,
+.visible-sm-inline,
+.visible-sm-inline-block,
+.visible-md-block,
+.visible-md-inline,
+.visible-md-inline-block,
+.visible-lg-block,
+.visible-lg-inline,
+.visible-lg-inline-block {
+  display: none !important;
+}
+@media (max-width: 767px) {
+  .visible-xs {
+    display: block !important;
+  }
+  table.visible-xs {
+    display: table !important;
+  }
+  tr.visible-xs {
+    display: table-row !important;
+  }
+  th.visible-xs,
+  td.visible-xs {
+    display: table-cell !important;
+  }
+}
+@media (max-width: 767px) {
+  .visible-xs-block {
+    display: block !important;
+  }
+}
+@media (max-width: 767px) {
+  .visible-xs-inline {
+    display: inline !important;
+  }
+}
+@media (max-width: 767px) {
+  .visible-xs-inline-block {
+    display: inline-block !important;
+  }
+}
+@media (min-width: 768px) and (max-width: 991px) {
+  .visible-sm {
+    display: block !important;
+  }
+  table.visible-sm {
+    display: table !important;
+  }
+  tr.visible-sm {
+    display: table-row !important;
+  }
+  th.visible-sm,
+  td.visible-sm {
+    display: table-cell !important;
+  }
+}
+@media (min-width: 768px) and (max-width: 991px) {
+  .visible-sm-block {
+    display: block !important;
+  }
+}
+@media (min-width: 768px) and (max-width: 991px) {
+  .visible-sm-inline {
+    display: inline !important;
+  }
+}
+@media (min-width: 768px) and (max-width: 991px) {
+  .visible-sm-inline-block {
+    display: inline-block !important;
+  }
+}
+@media (min-width: 992px) and (max-width: 1199px) {
+  .visible-md {
+    display: block !important;
+  }
+  table.visible-md {
+    display: table !important;
+  }
+  tr.visible-md {
+    display: table-row !important;
+  }
+  th.visible-md,
+  td.visible-md {
+    display: table-cell !important;
+  }
+}
+@media (min-width: 992px) and (max-width: 1199px) {
+  .visible-md-block {
+    display: block !important;
+  }
+}
+@media (min-width: 992px) and (max-width: 1199px) {
+  .visible-md-inline {
+    display: inline !important;
+  }
+}
+@media (min-width: 992px) and (max-width: 1199px) {
+  .visible-md-inline-block {
+    display: inline-block !important;
+  }
+}
+@media (min-width: 1200px) {
+  .visible-lg {
+    display: block !important;
+  }
+  table.visible-lg {
+    display: table !important;
+  }
+  tr.visible-lg {
+    display: table-row !important;
+  }
+  th.visible-lg,
+  td.visible-lg {
+    display: table-cell !important;
+  }
+}
+@media (min-width: 1200px) {
+  .visible-lg-block {
+    display: block !important;
+  }
+}
+@media (min-width: 1200px) {
+  .visible-lg-inline {
+    display: inline !important;
+  }
+}
+@media (min-width: 1200px) {
+  .visible-lg-inline-block {
+    display: inline-block !important;
+  }
+}
+@media (max-width: 767px) {
+  .hidden-xs {
+    display: none !important;
+  }
+}
+@media (min-width: 768px) and (max-width: 991px) {
+  .hidden-sm {
+    display: none !important;
+  }
+}
+@media (min-width: 992px) and (max-width: 1199px) {
+  .hidden-md {
+    display: none !important;
+  }
+}
+@media (min-width: 1200px) {
+  .hidden-lg {
+    display: none !important;
+  }
+}
+.visible-print {
+  display: none !important;
+}
+@media print {
+  .visible-print {
+    display: block !important;
+  }
+  table.visible-print {
+    display: table !important;
+  }
+  tr.visible-print {
+    display: table-row !important;
+  }
+  th.visible-print,
+  td.visible-print {
+    display: table-cell !important;
+  }
+}
+.visible-print-block {
+  display: none !important;
+}
+@media print {
+  .visible-print-block {
+    display: block !important;
+  }
+}
+.visible-print-inline {
+  display: none !important;
+}
+@media print {
+  .visible-print-inline {
+    display: inline !important;
+  }
+}
+.visible-print-inline-block {
+  display: none !important;
+}
+@media print {
+  .visible-print-inline-block {
+    display: inline-block !important;
+  }
+}
+@media print {
+  .hidden-print {
+    display: none !important;
+  }
+}
+/*# sourceMappingURL=bootstrap.css.map */
diff --git a/web/css/bootstrap.min.css b/web/css/bootstrap.min.css
new file mode 100755
index 0000000000000000000000000000000000000000..4cf729e4342a51d8b300e8d43f2f78b0a6faf403
--- /dev/null
+++ b/web/css/bootstrap.min.css
@@ -0,0 +1,6 @@
+/*!
+ * Bootstrap v3.3.6 (http://getbootstrap.com)
+ * Copyright 2011-2015 Twitter, Inc.
+ * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
+ *//*! normalize.css v3.0.3 | MIT License | github.com/necolas/normalize.css */html{font-family:sans-serif;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%}body{margin:0}article,aside,details,figcaption,figure,footer,header,hgroup,main,menu,nav,section,summary{display:block}audio,canvas,progress,video{display:inline-block;vertical-align:baseline}audio:not([controls]){display:none;height:0}[hidden],template{display:none}a{background-color:transparent}a:active,a:hover{outline:0}abbr[title]{border-bottom:1px dotted}b,strong{font-weight:700}dfn{font-style:italic}h1{margin:.67em 0;font-size:2em}mark{color:#000;background:#ff0}small{font-size:80%}sub,sup{position:relative;font-size:75%;line-height:0;vertical-align:baseline}sup{top:-.5em}sub{bottom:-.25em}img{border:0}svg:not(:root){overflow:hidden}figure{margin:1em 40px}hr{height:0;-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box}pre{overflow:auto}code,kbd,pre,samp{font-family:monospace,monospace;font-size:1em}button,input,optgroup,select,textarea{margin:0;font:inherit;color:inherit}button{overflow:visible}button,select{text-transform:none}button,html input[type=button],input[type=reset],input[type=submit]{-webkit-appearance:button;cursor:pointer}button[disabled],html input[disabled]{cursor:default}button::-moz-focus-inner,input::-moz-focus-inner{padding:0;border:0}input{line-height:normal}input[type=checkbox],input[type=radio]{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;padding:0}input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{height:auto}input[type=search]{-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;-webkit-appearance:textfield}input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration{-webkit-appearance:none}fieldset{padding:.35em .625em .75em;margin:0 2px;border:1px solid silver}legend{padding:0;border:0}textarea{overflow:auto}optgroup{font-weight:700}table{border-spacing:0;border-collapse:collapse}td,th{padding:0}/*! Source: https://github.com/h5bp/html5-boilerplate/blob/master/src/css/main.css */@media print{*,:after,:before{color:#000!important;text-shadow:none!important;background:0 0!important;-webkit-box-shadow:none!important;box-shadow:none!important}a,a:visited{text-decoration:underline}a[href]:after{content:" (" attr(href) ")"}abbr[title]:after{content:" (" attr(title) ")"}a[href^="javascript:"]:after,a[href^="#"]:after{content:""}blockquote,pre{border:1px solid #999;page-break-inside:avoid}thead{display:table-header-group}img,tr{page-break-inside:avoid}img{max-width:100%!important}h2,h3,p{orphans:3;widows:3}h2,h3{page-break-after:avoid}.navbar{display:none}.btn>.caret,.dropup>.btn>.caret{border-top-color:#000!important}.label{border:1px solid #000}.table{border-collapse:collapse!important}.table td,.table th{background-color:#fff!important}.table-bordered td,.table-bordered th{border:1px solid #ddd!important}}@font-face{font-family:'Glyphicons Halflings';src:url(../fonts/glyphicons-halflings-regular.eot);src:url(../fonts/glyphicons-halflings-regular.eot?#iefix) format('embedded-opentype'),url(../fonts/glyphicons-halflings-regular.woff2) format('woff2'),url(../fonts/glyphicons-halflings-regular.woff) format('woff'),url(../fonts/glyphicons-halflings-regular.ttf) format('truetype'),url(../fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregular) format('svg')}.glyphicon{position:relative;top:1px;display:inline-block;font-family:'Glyphicons Halflings';font-style:normal;font-weight:400;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.glyphicon-asterisk:before{content:"\002a"}.glyphicon-plus:before{content:"\002b"}.glyphicon-eur:before,.glyphicon-euro:before{content:"\20ac"}.glyphicon-minus:before{content:"\2212"}.glyphicon-cloud:before{content:"\2601"}.glyphicon-envelope:before{content:"\2709"}.glyphicon-pencil:before{content:"\270f"}.glyphicon-glass:before{content:"\e001"}.glyphicon-music:before{content:"\e002"}.glyphicon-search:before{content:"\e003"}.glyphicon-heart:before{content:"\e005"}.glyphicon-star:before{content:"\e006"}.glyphicon-star-empty:before{content:"\e007"}.glyphicon-user:before{content:"\e008"}.glyphicon-film:before{content:"\e009"}.glyphicon-th-large:before{content:"\e010"}.glyphicon-th:before{content:"\e011"}.glyphicon-th-list:before{content:"\e012"}.glyphicon-ok:before{content:"\e013"}.glyphicon-remove:before{content:"\e014"}.glyphicon-zoom-in:before{content:"\e015"}.glyphicon-zoom-out:before{content:"\e016"}.glyphicon-off:before{content:"\e017"}.glyphicon-signal:before{content:"\e018"}.glyphicon-cog:before{content:"\e019"}.glyphicon-trash:before{content:"\e020"}.glyphicon-home:before{content:"\e021"}.glyphicon-file:before{content:"\e022"}.glyphicon-time:before{content:"\e023"}.glyphicon-road:before{content:"\e024"}.glyphicon-download-alt:before{content:"\e025"}.glyphicon-download:before{content:"\e026"}.glyphicon-upload:before{content:"\e027"}.glyphicon-inbox:before{content:"\e028"}.glyphicon-play-circle:before{content:"\e029"}.glyphicon-repeat:before{content:"\e030"}.glyphicon-refresh:before{content:"\e031"}.glyphicon-list-alt:before{content:"\e032"}.glyphicon-lock:before{content:"\e033"}.glyphicon-flag:before{content:"\e034"}.glyphicon-headphones:before{content:"\e035"}.glyphicon-volume-off:before{content:"\e036"}.glyphicon-volume-down:before{content:"\e037"}.glyphicon-volume-up:before{content:"\e038"}.glyphicon-qrcode:before{content:"\e039"}.glyphicon-barcode:before{content:"\e040"}.glyphicon-tag:before{content:"\e041"}.glyphicon-tags:before{content:"\e042"}.glyphicon-book:before{content:"\e043"}.glyphicon-bookmark:before{content:"\e044"}.glyphicon-print:before{content:"\e045"}.glyphicon-camera:before{content:"\e046"}.glyphicon-font:before{content:"\e047"}.glyphicon-bold:before{content:"\e048"}.glyphicon-italic:before{content:"\e049"}.glyphicon-text-height:before{content:"\e050"}.glyphicon-text-width:before{content:"\e051"}.glyphicon-align-left:before{content:"\e052"}.glyphicon-align-center:before{content:"\e053"}.glyphicon-align-right:before{content:"\e054"}.glyphicon-align-justify:before{content:"\e055"}.glyphicon-list:before{content:"\e056"}.glyphicon-indent-left:before{content:"\e057"}.glyphicon-indent-right:before{content:"\e058"}.glyphicon-facetime-video:before{content:"\e059"}.glyphicon-picture:before{content:"\e060"}.glyphicon-map-marker:before{content:"\e062"}.glyphicon-adjust:before{content:"\e063"}.glyphicon-tint:before{content:"\e064"}.glyphicon-edit:before{content:"\e065"}.glyphicon-share:before{content:"\e066"}.glyphicon-check:before{content:"\e067"}.glyphicon-move:before{content:"\e068"}.glyphicon-step-backward:before{content:"\e069"}.glyphicon-fast-backward:before{content:"\e070"}.glyphicon-backward:before{content:"\e071"}.glyphicon-play:before{content:"\e072"}.glyphicon-pause:before{content:"\e073"}.glyphicon-stop:before{content:"\e074"}.glyphicon-forward:before{content:"\e075"}.glyphicon-fast-forward:before{content:"\e076"}.glyphicon-step-forward:before{content:"\e077"}.glyphicon-eject:before{content:"\e078"}.glyphicon-chevron-left:before{content:"\e079"}.glyphicon-chevron-right:before{content:"\e080"}.glyphicon-plus-sign:before{content:"\e081"}.glyphicon-minus-sign:before{content:"\e082"}.glyphicon-remove-sign:before{content:"\e083"}.glyphicon-ok-sign:before{content:"\e084"}.glyphicon-question-sign:before{content:"\e085"}.glyphicon-info-sign:before{content:"\e086"}.glyphicon-screenshot:before{content:"\e087"}.glyphicon-remove-circle:before{content:"\e088"}.glyphicon-ok-circle:before{content:"\e089"}.glyphicon-ban-circle:before{content:"\e090"}.glyphicon-arrow-left:before{content:"\e091"}.glyphicon-arrow-right:before{content:"\e092"}.glyphicon-arrow-up:before{content:"\e093"}.glyphicon-arrow-down:before{content:"\e094"}.glyphicon-share-alt:before{content:"\e095"}.glyphicon-resize-full:before{content:"\e096"}.glyphicon-resize-small:before{content:"\e097"}.glyphicon-exclamation-sign:before{content:"\e101"}.glyphicon-gift:before{content:"\e102"}.glyphicon-leaf:before{content:"\e103"}.glyphicon-fire:before{content:"\e104"}.glyphicon-eye-open:before{content:"\e105"}.glyphicon-eye-close:before{content:"\e106"}.glyphicon-warning-sign:before{content:"\e107"}.glyphicon-plane:before{content:"\e108"}.glyphicon-calendar:before{content:"\e109"}.glyphicon-random:before{content:"\e110"}.glyphicon-comment:before{content:"\e111"}.glyphicon-magnet:before{content:"\e112"}.glyphicon-chevron-up:before{content:"\e113"}.glyphicon-chevron-down:before{content:"\e114"}.glyphicon-retweet:before{content:"\e115"}.glyphicon-shopping-cart:before{content:"\e116"}.glyphicon-folder-close:before{content:"\e117"}.glyphicon-folder-open:before{content:"\e118"}.glyphicon-resize-vertical:before{content:"\e119"}.glyphicon-resize-horizontal:before{content:"\e120"}.glyphicon-hdd:before{content:"\e121"}.glyphicon-bullhorn:before{content:"\e122"}.glyphicon-bell:before{content:"\e123"}.glyphicon-certificate:before{content:"\e124"}.glyphicon-thumbs-up:before{content:"\e125"}.glyphicon-thumbs-down:before{content:"\e126"}.glyphicon-hand-right:before{content:"\e127"}.glyphicon-hand-left:before{content:"\e128"}.glyphicon-hand-up:before{content:"\e129"}.glyphicon-hand-down:before{content:"\e130"}.glyphicon-circle-arrow-right:before{content:"\e131"}.glyphicon-circle-arrow-left:before{content:"\e132"}.glyphicon-circle-arrow-up:before{content:"\e133"}.glyphicon-circle-arrow-down:before{content:"\e134"}.glyphicon-globe:before{content:"\e135"}.glyphicon-wrench:before{content:"\e136"}.glyphicon-tasks:before{content:"\e137"}.glyphicon-filter:before{content:"\e138"}.glyphicon-briefcase:before{content:"\e139"}.glyphicon-fullscreen:before{content:"\e140"}.glyphicon-dashboard:before{content:"\e141"}.glyphicon-paperclip:before{content:"\e142"}.glyphicon-heart-empty:before{content:"\e143"}.glyphicon-link:before{content:"\e144"}.glyphicon-phone:before{content:"\e145"}.glyphicon-pushpin:before{content:"\e146"}.glyphicon-usd:before{content:"\e148"}.glyphicon-gbp:before{content:"\e149"}.glyphicon-sort:before{content:"\e150"}.glyphicon-sort-by-alphabet:before{content:"\e151"}.glyphicon-sort-by-alphabet-alt:before{content:"\e152"}.glyphicon-sort-by-order:before{content:"\e153"}.glyphicon-sort-by-order-alt:before{content:"\e154"}.glyphicon-sort-by-attributes:before{content:"\e155"}.glyphicon-sort-by-attributes-alt:before{content:"\e156"}.glyphicon-unchecked:before{content:"\e157"}.glyphicon-expand:before{content:"\e158"}.glyphicon-collapse-down:before{content:"\e159"}.glyphicon-collapse-up:before{content:"\e160"}.glyphicon-log-in:before{content:"\e161"}.glyphicon-flash:before{content:"\e162"}.glyphicon-log-out:before{content:"\e163"}.glyphicon-new-window:before{content:"\e164"}.glyphicon-record:before{content:"\e165"}.glyphicon-save:before{content:"\e166"}.glyphicon-open:before{content:"\e167"}.glyphicon-saved:before{content:"\e168"}.glyphicon-import:before{content:"\e169"}.glyphicon-export:before{content:"\e170"}.glyphicon-send:before{content:"\e171"}.glyphicon-floppy-disk:before{content:"\e172"}.glyphicon-floppy-saved:before{content:"\e173"}.glyphicon-floppy-remove:before{content:"\e174"}.glyphicon-floppy-save:before{content:"\e175"}.glyphicon-floppy-open:before{content:"\e176"}.glyphicon-credit-card:before{content:"\e177"}.glyphicon-transfer:before{content:"\e178"}.glyphicon-cutlery:before{content:"\e179"}.glyphicon-header:before{content:"\e180"}.glyphicon-compressed:before{content:"\e181"}.glyphicon-earphone:before{content:"\e182"}.glyphicon-phone-alt:before{content:"\e183"}.glyphicon-tower:before{content:"\e184"}.glyphicon-stats:before{content:"\e185"}.glyphicon-sd-video:before{content:"\e186"}.glyphicon-hd-video:before{content:"\e187"}.glyphicon-subtitles:before{content:"\e188"}.glyphicon-sound-stereo:before{content:"\e189"}.glyphicon-sound-dolby:before{content:"\e190"}.glyphicon-sound-5-1:before{content:"\e191"}.glyphicon-sound-6-1:before{content:"\e192"}.glyphicon-sound-7-1:before{content:"\e193"}.glyphicon-copyright-mark:before{content:"\e194"}.glyphicon-registration-mark:before{content:"\e195"}.glyphicon-cloud-download:before{content:"\e197"}.glyphicon-cloud-upload:before{content:"\e198"}.glyphicon-tree-conifer:before{content:"\e199"}.glyphicon-tree-deciduous:before{content:"\e200"}.glyphicon-cd:before{content:"\e201"}.glyphicon-save-file:before{content:"\e202"}.glyphicon-open-file:before{content:"\e203"}.glyphicon-level-up:before{content:"\e204"}.glyphicon-copy:before{content:"\e205"}.glyphicon-paste:before{content:"\e206"}.glyphicon-alert:before{content:"\e209"}.glyphicon-equalizer:before{content:"\e210"}.glyphicon-king:before{content:"\e211"}.glyphicon-queen:before{content:"\e212"}.glyphicon-pawn:before{content:"\e213"}.glyphicon-bishop:before{content:"\e214"}.glyphicon-knight:before{content:"\e215"}.glyphicon-baby-formula:before{content:"\e216"}.glyphicon-tent:before{content:"\26fa"}.glyphicon-blackboard:before{content:"\e218"}.glyphicon-bed:before{content:"\e219"}.glyphicon-apple:before{content:"\f8ff"}.glyphicon-erase:before{content:"\e221"}.glyphicon-hourglass:before{content:"\231b"}.glyphicon-lamp:before{content:"\e223"}.glyphicon-duplicate:before{content:"\e224"}.glyphicon-piggy-bank:before{content:"\e225"}.glyphicon-scissors:before{content:"\e226"}.glyphicon-bitcoin:before{content:"\e227"}.glyphicon-btc:before{content:"\e227"}.glyphicon-xbt:before{content:"\e227"}.glyphicon-yen:before{content:"\00a5"}.glyphicon-jpy:before{content:"\00a5"}.glyphicon-ruble:before{content:"\20bd"}.glyphicon-rub:before{content:"\20bd"}.glyphicon-scale:before{content:"\e230"}.glyphicon-ice-lolly:before{content:"\e231"}.glyphicon-ice-lolly-tasted:before{content:"\e232"}.glyphicon-education:before{content:"\e233"}.glyphicon-option-horizontal:before{content:"\e234"}.glyphicon-option-vertical:before{content:"\e235"}.glyphicon-menu-hamburger:before{content:"\e236"}.glyphicon-modal-window:before{content:"\e237"}.glyphicon-oil:before{content:"\e238"}.glyphicon-grain:before{content:"\e239"}.glyphicon-sunglasses:before{content:"\e240"}.glyphicon-text-size:before{content:"\e241"}.glyphicon-text-color:before{content:"\e242"}.glyphicon-text-background:before{content:"\e243"}.glyphicon-object-align-top:before{content:"\e244"}.glyphicon-object-align-bottom:before{content:"\e245"}.glyphicon-object-align-horizontal:before{content:"\e246"}.glyphicon-object-align-left:before{content:"\e247"}.glyphicon-object-align-vertical:before{content:"\e248"}.glyphicon-object-align-right:before{content:"\e249"}.glyphicon-triangle-right:before{content:"\e250"}.glyphicon-triangle-left:before{content:"\e251"}.glyphicon-triangle-bottom:before{content:"\e252"}.glyphicon-triangle-top:before{content:"\e253"}.glyphicon-console:before{content:"\e254"}.glyphicon-superscript:before{content:"\e255"}.glyphicon-subscript:before{content:"\e256"}.glyphicon-menu-left:before{content:"\e257"}.glyphicon-menu-right:before{content:"\e258"}.glyphicon-menu-down:before{content:"\e259"}.glyphicon-menu-up:before{content:"\e260"}*{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}:after,:before{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}html{font-size:10px;-webkit-tap-highlight-color:rgba(0,0,0,0)}body{font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:14px;line-height:1.42857143;color:#333;background-color:#fff}button,input,select,textarea{font-family:inherit;font-size:inherit;line-height:inherit}a{color:#337ab7;text-decoration:none}a:focus,a:hover{color:#23527c;text-decoration:underline}a:focus{outline:thin dotted;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}figure{margin:0}img{vertical-align:middle}.carousel-inner>.item>a>img,.carousel-inner>.item>img,.img-responsive,.thumbnail a>img,.thumbnail>img{display:block;max-width:100%;height:auto}.img-rounded{border-radius:6px}.img-thumbnail{display:inline-block;max-width:100%;height:auto;padding:4px;line-height:1.42857143;background-color:#fff;border:1px solid #ddd;border-radius:4px;-webkit-transition:all .2s ease-in-out;-o-transition:all .2s ease-in-out;transition:all .2s ease-in-out}.img-circle{border-radius:50%}hr{margin-top:20px;margin-bottom:20px;border:0;border-top:1px solid #eee}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);border:0}.sr-only-focusable:active,.sr-only-focusable:focus{position:static;width:auto;height:auto;margin:0;overflow:visible;clip:auto}[role=button]{cursor:pointer}.h1,.h2,.h3,.h4,.h5,.h6,h1,h2,h3,h4,h5,h6{font-family:inherit;font-weight:500;line-height:1.1;color:inherit}.h1 .small,.h1 small,.h2 .small,.h2 small,.h3 .small,.h3 small,.h4 .small,.h4 small,.h5 .small,.h5 small,.h6 .small,.h6 small,h1 .small,h1 small,h2 .small,h2 small,h3 .small,h3 small,h4 .small,h4 small,h5 .small,h5 small,h6 .small,h6 small{font-weight:400;line-height:1;color:#777}.h1,.h2,.h3,h1,h2,h3{margin-top:20px;margin-bottom:10px}.h1 .small,.h1 small,.h2 .small,.h2 small,.h3 .small,.h3 small,h1 .small,h1 small,h2 .small,h2 small,h3 .small,h3 small{font-size:65%}.h4,.h5,.h6,h4,h5,h6{margin-top:10px;margin-bottom:10px}.h4 .small,.h4 small,.h5 .small,.h5 small,.h6 .small,.h6 small,h4 .small,h4 small,h5 .small,h5 small,h6 .small,h6 small{font-size:75%}.h1,h1{font-size:36px}.h2,h2{font-size:30px}.h3,h3{font-size:24px}.h4,h4{font-size:18px}.h5,h5{font-size:14px}.h6,h6{font-size:12px}p{margin:0 0 10px}.lead{margin-bottom:20px;font-size:16px;font-weight:300;line-height:1.4}@media (min-width:768px){.lead{font-size:21px}}.small,small{font-size:85%}.mark,mark{padding:.2em;background-color:#fcf8e3}.text-left{text-align:left}.text-right{text-align:right}.text-center{text-align:center}.text-justify{text-align:justify}.text-nowrap{white-space:nowrap}.text-lowercase{text-transform:lowercase}.text-uppercase{text-transform:uppercase}.text-capitalize{text-transform:capitalize}.text-muted{color:#777}.text-primary{color:#337ab7}a.text-primary:focus,a.text-primary:hover{color:#286090}.text-success{color:#3c763d}a.text-success:focus,a.text-success:hover{color:#2b542c}.text-info{color:#31708f}a.text-info:focus,a.text-info:hover{color:#245269}.text-warning{color:#8a6d3b}a.text-warning:focus,a.text-warning:hover{color:#66512c}.text-danger{color:#a94442}a.text-danger:focus,a.text-danger:hover{color:#843534}.bg-primary{color:#fff;background-color:#337ab7}a.bg-primary:focus,a.bg-primary:hover{background-color:#286090}.bg-success{background-color:#dff0d8}a.bg-success:focus,a.bg-success:hover{background-color:#c1e2b3}.bg-info{background-color:#d9edf7}a.bg-info:focus,a.bg-info:hover{background-color:#afd9ee}.bg-warning{background-color:#fcf8e3}a.bg-warning:focus,a.bg-warning:hover{background-color:#f7ecb5}.bg-danger{background-color:#f2dede}a.bg-danger:focus,a.bg-danger:hover{background-color:#e4b9b9}.page-header{padding-bottom:9px;margin:40px 0 20px;border-bottom:1px solid #eee}ol,ul{margin-top:0;margin-bottom:10px}ol ol,ol ul,ul ol,ul ul{margin-bottom:0}.list-unstyled{padding-left:0;list-style:none}.list-inline{padding-left:0;margin-left:-5px;list-style:none}.list-inline>li{display:inline-block;padding-right:5px;padding-left:5px}dl{margin-top:0;margin-bottom:20px}dd,dt{line-height:1.42857143}dt{font-weight:700}dd{margin-left:0}@media (min-width:768px){.dl-horizontal dt{float:left;width:160px;overflow:hidden;clear:left;text-align:right;text-overflow:ellipsis;white-space:nowrap}.dl-horizontal dd{margin-left:180px}}abbr[data-original-title],abbr[title]{cursor:help;border-bottom:1px dotted #777}.initialism{font-size:90%;text-transform:uppercase}blockquote{padding:10px 20px;margin:0 0 20px;font-size:17.5px;border-left:5px solid #eee}blockquote ol:last-child,blockquote p:last-child,blockquote ul:last-child{margin-bottom:0}blockquote .small,blockquote footer,blockquote small{display:block;font-size:80%;line-height:1.42857143;color:#777}blockquote .small:before,blockquote footer:before,blockquote small:before{content:'\2014 \00A0'}.blockquote-reverse,blockquote.pull-right{padding-right:15px;padding-left:0;text-align:right;border-right:5px solid #eee;border-left:0}.blockquote-reverse .small:before,.blockquote-reverse footer:before,.blockquote-reverse small:before,blockquote.pull-right .small:before,blockquote.pull-right footer:before,blockquote.pull-right small:before{content:''}.blockquote-reverse .small:after,.blockquote-reverse footer:after,.blockquote-reverse small:after,blockquote.pull-right .small:after,blockquote.pull-right footer:after,blockquote.pull-right small:after{content:'\00A0 \2014'}address{margin-bottom:20px;font-style:normal;line-height:1.42857143}code,kbd,pre,samp{font-family:Menlo,Monaco,Consolas,"Courier New",monospace}code{padding:2px 4px;font-size:90%;color:#c7254e;background-color:#f9f2f4;border-radius:4px}kbd{padding:2px 4px;font-size:90%;color:#fff;background-color:#333;border-radius:3px;-webkit-box-shadow:inset 0 -1px 0 rgba(0,0,0,.25);box-shadow:inset 0 -1px 0 rgba(0,0,0,.25)}kbd kbd{padding:0;font-size:100%;font-weight:700;-webkit-box-shadow:none;box-shadow:none}pre{display:block;padding:9.5px;margin:0 0 10px;font-size:13px;line-height:1.42857143;color:#333;word-break:break-all;word-wrap:break-word;background-color:#f5f5f5;border:1px solid #ccc;border-radius:4px}pre code{padding:0;font-size:inherit;color:inherit;white-space:pre-wrap;background-color:transparent;border-radius:0}.pre-scrollable{max-height:340px;overflow-y:scroll}.container{padding-right:15px;padding-left:15px;margin-right:auto;margin-left:auto}@media (min-width:768px){.container{width:750px}}@media (min-width:992px){.container{width:970px}}@media (min-width:1200px){.container{width:1170px}}.container-fluid{padding-right:15px;padding-left:15px;margin-right:auto;margin-left:auto}.row{margin-right:-15px;margin-left:-15px}.col-lg-1,.col-lg-10,.col-lg-11,.col-lg-12,.col-lg-2,.col-lg-3,.col-lg-4,.col-lg-5,.col-lg-6,.col-lg-7,.col-lg-8,.col-lg-9,.col-md-1,.col-md-10,.col-md-11,.col-md-12,.col-md-2,.col-md-3,.col-md-4,.col-md-5,.col-md-6,.col-md-7,.col-md-8,.col-md-9,.col-sm-1,.col-sm-10,.col-sm-11,.col-sm-12,.col-sm-2,.col-sm-3,.col-sm-4,.col-sm-5,.col-sm-6,.col-sm-7,.col-sm-8,.col-sm-9,.col-xs-1,.col-xs-10,.col-xs-11,.col-xs-12,.col-xs-2,.col-xs-3,.col-xs-4,.col-xs-5,.col-xs-6,.col-xs-7,.col-xs-8,.col-xs-9{position:relative;min-height:1px;padding-right:15px;padding-left:15px}.col-xs-1,.col-xs-10,.col-xs-11,.col-xs-12,.col-xs-2,.col-xs-3,.col-xs-4,.col-xs-5,.col-xs-6,.col-xs-7,.col-xs-8,.col-xs-9{float:left}.col-xs-12{width:100%}.col-xs-11{width:91.66666667%}.col-xs-10{width:83.33333333%}.col-xs-9{width:75%}.col-xs-8{width:66.66666667%}.col-xs-7{width:58.33333333%}.col-xs-6{width:50%}.col-xs-5{width:41.66666667%}.col-xs-4{width:33.33333333%}.col-xs-3{width:25%}.col-xs-2{width:16.66666667%}.col-xs-1{width:8.33333333%}.col-xs-pull-12{right:100%}.col-xs-pull-11{right:91.66666667%}.col-xs-pull-10{right:83.33333333%}.col-xs-pull-9{right:75%}.col-xs-pull-8{right:66.66666667%}.col-xs-pull-7{right:58.33333333%}.col-xs-pull-6{right:50%}.col-xs-pull-5{right:41.66666667%}.col-xs-pull-4{right:33.33333333%}.col-xs-pull-3{right:25%}.col-xs-pull-2{right:16.66666667%}.col-xs-pull-1{right:8.33333333%}.col-xs-pull-0{right:auto}.col-xs-push-12{left:100%}.col-xs-push-11{left:91.66666667%}.col-xs-push-10{left:83.33333333%}.col-xs-push-9{left:75%}.col-xs-push-8{left:66.66666667%}.col-xs-push-7{left:58.33333333%}.col-xs-push-6{left:50%}.col-xs-push-5{left:41.66666667%}.col-xs-push-4{left:33.33333333%}.col-xs-push-3{left:25%}.col-xs-push-2{left:16.66666667%}.col-xs-push-1{left:8.33333333%}.col-xs-push-0{left:auto}.col-xs-offset-12{margin-left:100%}.col-xs-offset-11{margin-left:91.66666667%}.col-xs-offset-10{margin-left:83.33333333%}.col-xs-offset-9{margin-left:75%}.col-xs-offset-8{margin-left:66.66666667%}.col-xs-offset-7{margin-left:58.33333333%}.col-xs-offset-6{margin-left:50%}.col-xs-offset-5{margin-left:41.66666667%}.col-xs-offset-4{margin-left:33.33333333%}.col-xs-offset-3{margin-left:25%}.col-xs-offset-2{margin-left:16.66666667%}.col-xs-offset-1{margin-left:8.33333333%}.col-xs-offset-0{margin-left:0}@media (min-width:768px){.col-sm-1,.col-sm-10,.col-sm-11,.col-sm-12,.col-sm-2,.col-sm-3,.col-sm-4,.col-sm-5,.col-sm-6,.col-sm-7,.col-sm-8,.col-sm-9{float:left}.col-sm-12{width:100%}.col-sm-11{width:91.66666667%}.col-sm-10{width:83.33333333%}.col-sm-9{width:75%}.col-sm-8{width:66.66666667%}.col-sm-7{width:58.33333333%}.col-sm-6{width:50%}.col-sm-5{width:41.66666667%}.col-sm-4{width:33.33333333%}.col-sm-3{width:25%}.col-sm-2{width:16.66666667%}.col-sm-1{width:8.33333333%}.col-sm-pull-12{right:100%}.col-sm-pull-11{right:91.66666667%}.col-sm-pull-10{right:83.33333333%}.col-sm-pull-9{right:75%}.col-sm-pull-8{right:66.66666667%}.col-sm-pull-7{right:58.33333333%}.col-sm-pull-6{right:50%}.col-sm-pull-5{right:41.66666667%}.col-sm-pull-4{right:33.33333333%}.col-sm-pull-3{right:25%}.col-sm-pull-2{right:16.66666667%}.col-sm-pull-1{right:8.33333333%}.col-sm-pull-0{right:auto}.col-sm-push-12{left:100%}.col-sm-push-11{left:91.66666667%}.col-sm-push-10{left:83.33333333%}.col-sm-push-9{left:75%}.col-sm-push-8{left:66.66666667%}.col-sm-push-7{left:58.33333333%}.col-sm-push-6{left:50%}.col-sm-push-5{left:41.66666667%}.col-sm-push-4{left:33.33333333%}.col-sm-push-3{left:25%}.col-sm-push-2{left:16.66666667%}.col-sm-push-1{left:8.33333333%}.col-sm-push-0{left:auto}.col-sm-offset-12{margin-left:100%}.col-sm-offset-11{margin-left:91.66666667%}.col-sm-offset-10{margin-left:83.33333333%}.col-sm-offset-9{margin-left:75%}.col-sm-offset-8{margin-left:66.66666667%}.col-sm-offset-7{margin-left:58.33333333%}.col-sm-offset-6{margin-left:50%}.col-sm-offset-5{margin-left:41.66666667%}.col-sm-offset-4{margin-left:33.33333333%}.col-sm-offset-3{margin-left:25%}.col-sm-offset-2{margin-left:16.66666667%}.col-sm-offset-1{margin-left:8.33333333%}.col-sm-offset-0{margin-left:0}}@media (min-width:992px){.col-md-1,.col-md-10,.col-md-11,.col-md-12,.col-md-2,.col-md-3,.col-md-4,.col-md-5,.col-md-6,.col-md-7,.col-md-8,.col-md-9{float:left}.col-md-12{width:100%}.col-md-11{width:91.66666667%}.col-md-10{width:83.33333333%}.col-md-9{width:75%}.col-md-8{width:66.66666667%}.col-md-7{width:58.33333333%}.col-md-6{width:50%}.col-md-5{width:41.66666667%}.col-md-4{width:33.33333333%}.col-md-3{width:25%}.col-md-2{width:16.66666667%}.col-md-1{width:8.33333333%}.col-md-pull-12{right:100%}.col-md-pull-11{right:91.66666667%}.col-md-pull-10{right:83.33333333%}.col-md-pull-9{right:75%}.col-md-pull-8{right:66.66666667%}.col-md-pull-7{right:58.33333333%}.col-md-pull-6{right:50%}.col-md-pull-5{right:41.66666667%}.col-md-pull-4{right:33.33333333%}.col-md-pull-3{right:25%}.col-md-pull-2{right:16.66666667%}.col-md-pull-1{right:8.33333333%}.col-md-pull-0{right:auto}.col-md-push-12{left:100%}.col-md-push-11{left:91.66666667%}.col-md-push-10{left:83.33333333%}.col-md-push-9{left:75%}.col-md-push-8{left:66.66666667%}.col-md-push-7{left:58.33333333%}.col-md-push-6{left:50%}.col-md-push-5{left:41.66666667%}.col-md-push-4{left:33.33333333%}.col-md-push-3{left:25%}.col-md-push-2{left:16.66666667%}.col-md-push-1{left:8.33333333%}.col-md-push-0{left:auto}.col-md-offset-12{margin-left:100%}.col-md-offset-11{margin-left:91.66666667%}.col-md-offset-10{margin-left:83.33333333%}.col-md-offset-9{margin-left:75%}.col-md-offset-8{margin-left:66.66666667%}.col-md-offset-7{margin-left:58.33333333%}.col-md-offset-6{margin-left:50%}.col-md-offset-5{margin-left:41.66666667%}.col-md-offset-4{margin-left:33.33333333%}.col-md-offset-3{margin-left:25%}.col-md-offset-2{margin-left:16.66666667%}.col-md-offset-1{margin-left:8.33333333%}.col-md-offset-0{margin-left:0}}@media (min-width:1200px){.col-lg-1,.col-lg-10,.col-lg-11,.col-lg-12,.col-lg-2,.col-lg-3,.col-lg-4,.col-lg-5,.col-lg-6,.col-lg-7,.col-lg-8,.col-lg-9{float:left}.col-lg-12{width:100%}.col-lg-11{width:91.66666667%}.col-lg-10{width:83.33333333%}.col-lg-9{width:75%}.col-lg-8{width:66.66666667%}.col-lg-7{width:58.33333333%}.col-lg-6{width:50%}.col-lg-5{width:41.66666667%}.col-lg-4{width:33.33333333%}.col-lg-3{width:25%}.col-lg-2{width:16.66666667%}.col-lg-1{width:8.33333333%}.col-lg-pull-12{right:100%}.col-lg-pull-11{right:91.66666667%}.col-lg-pull-10{right:83.33333333%}.col-lg-pull-9{right:75%}.col-lg-pull-8{right:66.66666667%}.col-lg-pull-7{right:58.33333333%}.col-lg-pull-6{right:50%}.col-lg-pull-5{right:41.66666667%}.col-lg-pull-4{right:33.33333333%}.col-lg-pull-3{right:25%}.col-lg-pull-2{right:16.66666667%}.col-lg-pull-1{right:8.33333333%}.col-lg-pull-0{right:auto}.col-lg-push-12{left:100%}.col-lg-push-11{left:91.66666667%}.col-lg-push-10{left:83.33333333%}.col-lg-push-9{left:75%}.col-lg-push-8{left:66.66666667%}.col-lg-push-7{left:58.33333333%}.col-lg-push-6{left:50%}.col-lg-push-5{left:41.66666667%}.col-lg-push-4{left:33.33333333%}.col-lg-push-3{left:25%}.col-lg-push-2{left:16.66666667%}.col-lg-push-1{left:8.33333333%}.col-lg-push-0{left:auto}.col-lg-offset-12{margin-left:100%}.col-lg-offset-11{margin-left:91.66666667%}.col-lg-offset-10{margin-left:83.33333333%}.col-lg-offset-9{margin-left:75%}.col-lg-offset-8{margin-left:66.66666667%}.col-lg-offset-7{margin-left:58.33333333%}.col-lg-offset-6{margin-left:50%}.col-lg-offset-5{margin-left:41.66666667%}.col-lg-offset-4{margin-left:33.33333333%}.col-lg-offset-3{margin-left:25%}.col-lg-offset-2{margin-left:16.66666667%}.col-lg-offset-1{margin-left:8.33333333%}.col-lg-offset-0{margin-left:0}}table{background-color:transparent}caption{padding-top:8px;padding-bottom:8px;color:#777;text-align:left}th{text-align:left}.table{width:100%;max-width:100%;margin-bottom:20px}.table>tbody>tr>td,.table>tbody>tr>th,.table>tfoot>tr>td,.table>tfoot>tr>th,.table>thead>tr>td,.table>thead>tr>th{padding:8px;line-height:1.42857143;vertical-align:top;border-top:1px solid #ddd}.table>thead>tr>th{vertical-align:bottom;border-bottom:2px solid #ddd}.table>caption+thead>tr:first-child>td,.table>caption+thead>tr:first-child>th,.table>colgroup+thead>tr:first-child>td,.table>colgroup+thead>tr:first-child>th,.table>thead:first-child>tr:first-child>td,.table>thead:first-child>tr:first-child>th{border-top:0}.table>tbody+tbody{border-top:2px solid #ddd}.table .table{background-color:#fff}.table-condensed>tbody>tr>td,.table-condensed>tbody>tr>th,.table-condensed>tfoot>tr>td,.table-condensed>tfoot>tr>th,.table-condensed>thead>tr>td,.table-condensed>thead>tr>th{padding:5px}.table-bordered{border:1px solid #ddd}.table-bordered>tbody>tr>td,.table-bordered>tbody>tr>th,.table-bordered>tfoot>tr>td,.table-bordered>tfoot>tr>th,.table-bordered>thead>tr>td,.table-bordered>thead>tr>th{border:1px solid #ddd}.table-bordered>thead>tr>td,.table-bordered>thead>tr>th{border-bottom-width:2px}.table-striped>tbody>tr:nth-of-type(odd){background-color:#f9f9f9}.table-hover>tbody>tr:hover{background-color:#f5f5f5}table col[class*=col-]{position:static;display:table-column;float:none}table td[class*=col-],table th[class*=col-]{position:static;display:table-cell;float:none}.table>tbody>tr.active>td,.table>tbody>tr.active>th,.table>tbody>tr>td.active,.table>tbody>tr>th.active,.table>tfoot>tr.active>td,.table>tfoot>tr.active>th,.table>tfoot>tr>td.active,.table>tfoot>tr>th.active,.table>thead>tr.active>td,.table>thead>tr.active>th,.table>thead>tr>td.active,.table>thead>tr>th.active{background-color:#f5f5f5}.table-hover>tbody>tr.active:hover>td,.table-hover>tbody>tr.active:hover>th,.table-hover>tbody>tr:hover>.active,.table-hover>tbody>tr>td.active:hover,.table-hover>tbody>tr>th.active:hover{background-color:#e8e8e8}.table>tbody>tr.success>td,.table>tbody>tr.success>th,.table>tbody>tr>td.success,.table>tbody>tr>th.success,.table>tfoot>tr.success>td,.table>tfoot>tr.success>th,.table>tfoot>tr>td.success,.table>tfoot>tr>th.success,.table>thead>tr.success>td,.table>thead>tr.success>th,.table>thead>tr>td.success,.table>thead>tr>th.success{background-color:#dff0d8}.table-hover>tbody>tr.success:hover>td,.table-hover>tbody>tr.success:hover>th,.table-hover>tbody>tr:hover>.success,.table-hover>tbody>tr>td.success:hover,.table-hover>tbody>tr>th.success:hover{background-color:#d0e9c6}.table>tbody>tr.info>td,.table>tbody>tr.info>th,.table>tbody>tr>td.info,.table>tbody>tr>th.info,.table>tfoot>tr.info>td,.table>tfoot>tr.info>th,.table>tfoot>tr>td.info,.table>tfoot>tr>th.info,.table>thead>tr.info>td,.table>thead>tr.info>th,.table>thead>tr>td.info,.table>thead>tr>th.info{background-color:#d9edf7}.table-hover>tbody>tr.info:hover>td,.table-hover>tbody>tr.info:hover>th,.table-hover>tbody>tr:hover>.info,.table-hover>tbody>tr>td.info:hover,.table-hover>tbody>tr>th.info:hover{background-color:#c4e3f3}.table>tbody>tr.warning>td,.table>tbody>tr.warning>th,.table>tbody>tr>td.warning,.table>tbody>tr>th.warning,.table>tfoot>tr.warning>td,.table>tfoot>tr.warning>th,.table>tfoot>tr>td.warning,.table>tfoot>tr>th.warning,.table>thead>tr.warning>td,.table>thead>tr.warning>th,.table>thead>tr>td.warning,.table>thead>tr>th.warning{background-color:#fcf8e3}.table-hover>tbody>tr.warning:hover>td,.table-hover>tbody>tr.warning:hover>th,.table-hover>tbody>tr:hover>.warning,.table-hover>tbody>tr>td.warning:hover,.table-hover>tbody>tr>th.warning:hover{background-color:#faf2cc}.table>tbody>tr.danger>td,.table>tbody>tr.danger>th,.table>tbody>tr>td.danger,.table>tbody>tr>th.danger,.table>tfoot>tr.danger>td,.table>tfoot>tr.danger>th,.table>tfoot>tr>td.danger,.table>tfoot>tr>th.danger,.table>thead>tr.danger>td,.table>thead>tr.danger>th,.table>thead>tr>td.danger,.table>thead>tr>th.danger{background-color:#f2dede}.table-hover>tbody>tr.danger:hover>td,.table-hover>tbody>tr.danger:hover>th,.table-hover>tbody>tr:hover>.danger,.table-hover>tbody>tr>td.danger:hover,.table-hover>tbody>tr>th.danger:hover{background-color:#ebcccc}.table-responsive{min-height:.01%;overflow-x:auto}@media screen and (max-width:767px){.table-responsive{width:100%;margin-bottom:15px;overflow-y:hidden;-ms-overflow-style:-ms-autohiding-scrollbar;border:1px solid #ddd}.table-responsive>.table{margin-bottom:0}.table-responsive>.table>tbody>tr>td,.table-responsive>.table>tbody>tr>th,.table-responsive>.table>tfoot>tr>td,.table-responsive>.table>tfoot>tr>th,.table-responsive>.table>thead>tr>td,.table-responsive>.table>thead>tr>th{white-space:nowrap}.table-responsive>.table-bordered{border:0}.table-responsive>.table-bordered>tbody>tr>td:first-child,.table-responsive>.table-bordered>tbody>tr>th:first-child,.table-responsive>.table-bordered>tfoot>tr>td:first-child,.table-responsive>.table-bordered>tfoot>tr>th:first-child,.table-responsive>.table-bordered>thead>tr>td:first-child,.table-responsive>.table-bordered>thead>tr>th:first-child{border-left:0}.table-responsive>.table-bordered>tbody>tr>td:last-child,.table-responsive>.table-bordered>tbody>tr>th:last-child,.table-responsive>.table-bordered>tfoot>tr>td:last-child,.table-responsive>.table-bordered>tfoot>tr>th:last-child,.table-responsive>.table-bordered>thead>tr>td:last-child,.table-responsive>.table-bordered>thead>tr>th:last-child{border-right:0}.table-responsive>.table-bordered>tbody>tr:last-child>td,.table-responsive>.table-bordered>tbody>tr:last-child>th,.table-responsive>.table-bordered>tfoot>tr:last-child>td,.table-responsive>.table-bordered>tfoot>tr:last-child>th{border-bottom:0}}fieldset{min-width:0;padding:0;margin:0;border:0}legend{display:block;width:100%;padding:0;margin-bottom:20px;font-size:21px;line-height:inherit;color:#333;border:0;border-bottom:1px solid #e5e5e5}label{display:inline-block;max-width:100%;margin-bottom:5px;font-weight:700}input[type=search]{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}input[type=checkbox],input[type=radio]{margin:4px 0 0;margin-top:1px\9;line-height:normal}input[type=file]{display:block}input[type=range]{display:block;width:100%}select[multiple],select[size]{height:auto}input[type=file]:focus,input[type=checkbox]:focus,input[type=radio]:focus{outline:thin dotted;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}output{display:block;padding-top:7px;font-size:14px;line-height:1.42857143;color:#555}.form-control{display:block;width:100%;height:34px;padding:6px 12px;font-size:14px;line-height:1.42857143;color:#555;background-color:#fff;background-image:none;border:1px solid #ccc;border-radius:4px;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075);-webkit-transition:border-color ease-in-out .15s,-webkit-box-shadow ease-in-out .15s;-o-transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s;transition:border-color ease-in-out .15s,box-shadow ease-in-out .15s}.form-control:focus{border-color:#66afe9;outline:0;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6);box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6)}.form-control::-moz-placeholder{color:#999;opacity:1}.form-control:-ms-input-placeholder{color:#999}.form-control::-webkit-input-placeholder{color:#999}.form-control::-ms-expand{background-color:transparent;border:0}.form-control[disabled],.form-control[readonly],fieldset[disabled] .form-control{background-color:#eee;opacity:1}.form-control[disabled],fieldset[disabled] .form-control{cursor:not-allowed}textarea.form-control{height:auto}input[type=search]{-webkit-appearance:none}@media screen and (-webkit-min-device-pixel-ratio:0){input[type=date].form-control,input[type=time].form-control,input[type=datetime-local].form-control,input[type=month].form-control{line-height:34px}.input-group-sm input[type=date],.input-group-sm input[type=time],.input-group-sm input[type=datetime-local],.input-group-sm input[type=month],input[type=date].input-sm,input[type=time].input-sm,input[type=datetime-local].input-sm,input[type=month].input-sm{line-height:30px}.input-group-lg input[type=date],.input-group-lg input[type=time],.input-group-lg input[type=datetime-local],.input-group-lg input[type=month],input[type=date].input-lg,input[type=time].input-lg,input[type=datetime-local].input-lg,input[type=month].input-lg{line-height:46px}}.form-group{margin-bottom:15px}.checkbox,.radio{position:relative;display:block;margin-top:10px;margin-bottom:10px}.checkbox label,.radio label{min-height:20px;padding-left:20px;margin-bottom:0;font-weight:400;cursor:pointer}.checkbox input[type=checkbox],.checkbox-inline input[type=checkbox],.radio input[type=radio],.radio-inline input[type=radio]{position:absolute;margin-top:4px\9;margin-left:-20px}.checkbox+.checkbox,.radio+.radio{margin-top:-5px}.checkbox-inline,.radio-inline{position:relative;display:inline-block;padding-left:20px;margin-bottom:0;font-weight:400;vertical-align:middle;cursor:pointer}.checkbox-inline+.checkbox-inline,.radio-inline+.radio-inline{margin-top:0;margin-left:10px}fieldset[disabled] input[type=checkbox],fieldset[disabled] input[type=radio],input[type=checkbox].disabled,input[type=checkbox][disabled],input[type=radio].disabled,input[type=radio][disabled]{cursor:not-allowed}.checkbox-inline.disabled,.radio-inline.disabled,fieldset[disabled] .checkbox-inline,fieldset[disabled] .radio-inline{cursor:not-allowed}.checkbox.disabled label,.radio.disabled label,fieldset[disabled] .checkbox label,fieldset[disabled] .radio label{cursor:not-allowed}.form-control-static{min-height:34px;padding-top:7px;padding-bottom:7px;margin-bottom:0}.form-control-static.input-lg,.form-control-static.input-sm{padding-right:0;padding-left:0}.input-sm{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}select.input-sm{height:30px;line-height:30px}select[multiple].input-sm,textarea.input-sm{height:auto}.form-group-sm .form-control{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}.form-group-sm select.form-control{height:30px;line-height:30px}.form-group-sm select[multiple].form-control,.form-group-sm textarea.form-control{height:auto}.form-group-sm .form-control-static{height:30px;min-height:32px;padding:6px 10px;font-size:12px;line-height:1.5}.input-lg{height:46px;padding:10px 16px;font-size:18px;line-height:1.3333333;border-radius:6px}select.input-lg{height:46px;line-height:46px}select[multiple].input-lg,textarea.input-lg{height:auto}.form-group-lg .form-control{height:46px;padding:10px 16px;font-size:18px;line-height:1.3333333;border-radius:6px}.form-group-lg select.form-control{height:46px;line-height:46px}.form-group-lg select[multiple].form-control,.form-group-lg textarea.form-control{height:auto}.form-group-lg .form-control-static{height:46px;min-height:38px;padding:11px 16px;font-size:18px;line-height:1.3333333}.has-feedback{position:relative}.has-feedback .form-control{padding-right:42.5px}.form-control-feedback{position:absolute;top:0;right:0;z-index:2;display:block;width:34px;height:34px;line-height:34px;text-align:center;pointer-events:none}.form-group-lg .form-control+.form-control-feedback,.input-group-lg+.form-control-feedback,.input-lg+.form-control-feedback{width:46px;height:46px;line-height:46px}.form-group-sm .form-control+.form-control-feedback,.input-group-sm+.form-control-feedback,.input-sm+.form-control-feedback{width:30px;height:30px;line-height:30px}.has-success .checkbox,.has-success .checkbox-inline,.has-success .control-label,.has-success .help-block,.has-success .radio,.has-success .radio-inline,.has-success.checkbox label,.has-success.checkbox-inline label,.has-success.radio label,.has-success.radio-inline label{color:#3c763d}.has-success .form-control{border-color:#3c763d;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-success .form-control:focus{border-color:#2b542c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #67b168}.has-success .input-group-addon{color:#3c763d;background-color:#dff0d8;border-color:#3c763d}.has-success .form-control-feedback{color:#3c763d}.has-warning .checkbox,.has-warning .checkbox-inline,.has-warning .control-label,.has-warning .help-block,.has-warning .radio,.has-warning .radio-inline,.has-warning.checkbox label,.has-warning.checkbox-inline label,.has-warning.radio label,.has-warning.radio-inline label{color:#8a6d3b}.has-warning .form-control{border-color:#8a6d3b;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-warning .form-control:focus{border-color:#66512c;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #c0a16b}.has-warning .input-group-addon{color:#8a6d3b;background-color:#fcf8e3;border-color:#8a6d3b}.has-warning .form-control-feedback{color:#8a6d3b}.has-error .checkbox,.has-error .checkbox-inline,.has-error .control-label,.has-error .help-block,.has-error .radio,.has-error .radio-inline,.has-error.checkbox label,.has-error.checkbox-inline label,.has-error.radio label,.has-error.radio-inline label{color:#a94442}.has-error .form-control{border-color:#a94442;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 1px rgba(0,0,0,.075)}.has-error .form-control:focus{border-color:#843534;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 6px #ce8483}.has-error .input-group-addon{color:#a94442;background-color:#f2dede;border-color:#a94442}.has-error .form-control-feedback{color:#a94442}.has-feedback label~.form-control-feedback{top:25px}.has-feedback label.sr-only~.form-control-feedback{top:0}.help-block{display:block;margin-top:5px;margin-bottom:10px;color:#737373}@media (min-width:768px){.form-inline .form-group{display:inline-block;margin-bottom:0;vertical-align:middle}.form-inline .form-control{display:inline-block;width:auto;vertical-align:middle}.form-inline .form-control-static{display:inline-block}.form-inline .input-group{display:inline-table;vertical-align:middle}.form-inline .input-group .form-control,.form-inline .input-group .input-group-addon,.form-inline .input-group .input-group-btn{width:auto}.form-inline .input-group>.form-control{width:100%}.form-inline .control-label{margin-bottom:0;vertical-align:middle}.form-inline .checkbox,.form-inline .radio{display:inline-block;margin-top:0;margin-bottom:0;vertical-align:middle}.form-inline .checkbox label,.form-inline .radio label{padding-left:0}.form-inline .checkbox input[type=checkbox],.form-inline .radio input[type=radio]{position:relative;margin-left:0}.form-inline .has-feedback .form-control-feedback{top:0}}.form-horizontal .checkbox,.form-horizontal .checkbox-inline,.form-horizontal .radio,.form-horizontal .radio-inline{padding-top:7px;margin-top:0;margin-bottom:0}.form-horizontal .checkbox,.form-horizontal .radio{min-height:27px}.form-horizontal .form-group{margin-right:-15px;margin-left:-15px}@media (min-width:768px){.form-horizontal .control-label{padding-top:7px;margin-bottom:0;text-align:right}}.form-horizontal .has-feedback .form-control-feedback{right:15px}@media (min-width:768px){.form-horizontal .form-group-lg .control-label{padding-top:11px;font-size:18px}}@media (min-width:768px){.form-horizontal .form-group-sm .control-label{padding-top:6px;font-size:12px}}.btn{display:inline-block;padding:6px 12px;margin-bottom:0;font-size:14px;font-weight:400;line-height:1.42857143;text-align:center;white-space:nowrap;vertical-align:middle;-ms-touch-action:manipulation;touch-action:manipulation;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background-image:none;border:1px solid transparent;border-radius:4px}.btn.active.focus,.btn.active:focus,.btn.focus,.btn:active.focus,.btn:active:focus,.btn:focus{outline:thin dotted;outline:5px auto -webkit-focus-ring-color;outline-offset:-2px}.btn.focus,.btn:focus,.btn:hover{color:#333;text-decoration:none}.btn.active,.btn:active{background-image:none;outline:0;-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.btn.disabled,.btn[disabled],fieldset[disabled] .btn{cursor:not-allowed;filter:alpha(opacity=65);-webkit-box-shadow:none;box-shadow:none;opacity:.65}a.btn.disabled,fieldset[disabled] a.btn{pointer-events:none}.btn-default{color:#333;background-color:#fff;border-color:#ccc}.btn-default.focus,.btn-default:focus{color:#333;background-color:#e6e6e6;border-color:#8c8c8c}.btn-default:hover{color:#333;background-color:#e6e6e6;border-color:#adadad}.btn-default.active,.btn-default:active,.open>.dropdown-toggle.btn-default{color:#333;background-color:#e6e6e6;border-color:#adadad}.btn-default.active.focus,.btn-default.active:focus,.btn-default.active:hover,.btn-default:active.focus,.btn-default:active:focus,.btn-default:active:hover,.open>.dropdown-toggle.btn-default.focus,.open>.dropdown-toggle.btn-default:focus,.open>.dropdown-toggle.btn-default:hover{color:#333;background-color:#d4d4d4;border-color:#8c8c8c}.btn-default.active,.btn-default:active,.open>.dropdown-toggle.btn-default{background-image:none}.btn-default.disabled.focus,.btn-default.disabled:focus,.btn-default.disabled:hover,.btn-default[disabled].focus,.btn-default[disabled]:focus,.btn-default[disabled]:hover,fieldset[disabled] .btn-default.focus,fieldset[disabled] .btn-default:focus,fieldset[disabled] .btn-default:hover{background-color:#fff;border-color:#ccc}.btn-default .badge{color:#fff;background-color:#333}.btn-primary{color:#fff;background-color:#337ab7;border-color:#2e6da4}.btn-primary.focus,.btn-primary:focus{color:#fff;background-color:#286090;border-color:#122b40}.btn-primary:hover{color:#fff;background-color:#286090;border-color:#204d74}.btn-primary.active,.btn-primary:active,.open>.dropdown-toggle.btn-primary{color:#fff;background-color:#286090;border-color:#204d74}.btn-primary.active.focus,.btn-primary.active:focus,.btn-primary.active:hover,.btn-primary:active.focus,.btn-primary:active:focus,.btn-primary:active:hover,.open>.dropdown-toggle.btn-primary.focus,.open>.dropdown-toggle.btn-primary:focus,.open>.dropdown-toggle.btn-primary:hover{color:#fff;background-color:#204d74;border-color:#122b40}.btn-primary.active,.btn-primary:active,.open>.dropdown-toggle.btn-primary{background-image:none}.btn-primary.disabled.focus,.btn-primary.disabled:focus,.btn-primary.disabled:hover,.btn-primary[disabled].focus,.btn-primary[disabled]:focus,.btn-primary[disabled]:hover,fieldset[disabled] .btn-primary.focus,fieldset[disabled] .btn-primary:focus,fieldset[disabled] .btn-primary:hover{background-color:#337ab7;border-color:#2e6da4}.btn-primary .badge{color:#337ab7;background-color:#fff}.btn-success{color:#fff;background-color:#5cb85c;border-color:#4cae4c}.btn-success.focus,.btn-success:focus{color:#fff;background-color:#449d44;border-color:#255625}.btn-success:hover{color:#fff;background-color:#449d44;border-color:#398439}.btn-success.active,.btn-success:active,.open>.dropdown-toggle.btn-success{color:#fff;background-color:#449d44;border-color:#398439}.btn-success.active.focus,.btn-success.active:focus,.btn-success.active:hover,.btn-success:active.focus,.btn-success:active:focus,.btn-success:active:hover,.open>.dropdown-toggle.btn-success.focus,.open>.dropdown-toggle.btn-success:focus,.open>.dropdown-toggle.btn-success:hover{color:#fff;background-color:#398439;border-color:#255625}.btn-success.active,.btn-success:active,.open>.dropdown-toggle.btn-success{background-image:none}.btn-success.disabled.focus,.btn-success.disabled:focus,.btn-success.disabled:hover,.btn-success[disabled].focus,.btn-success[disabled]:focus,.btn-success[disabled]:hover,fieldset[disabled] .btn-success.focus,fieldset[disabled] .btn-success:focus,fieldset[disabled] .btn-success:hover{background-color:#5cb85c;border-color:#4cae4c}.btn-success .badge{color:#5cb85c;background-color:#fff}.btn-info{color:#fff;background-color:#5bc0de;border-color:#46b8da}.btn-info.focus,.btn-info:focus{color:#fff;background-color:#31b0d5;border-color:#1b6d85}.btn-info:hover{color:#fff;background-color:#31b0d5;border-color:#269abc}.btn-info.active,.btn-info:active,.open>.dropdown-toggle.btn-info{color:#fff;background-color:#31b0d5;border-color:#269abc}.btn-info.active.focus,.btn-info.active:focus,.btn-info.active:hover,.btn-info:active.focus,.btn-info:active:focus,.btn-info:active:hover,.open>.dropdown-toggle.btn-info.focus,.open>.dropdown-toggle.btn-info:focus,.open>.dropdown-toggle.btn-info:hover{color:#fff;background-color:#269abc;border-color:#1b6d85}.btn-info.active,.btn-info:active,.open>.dropdown-toggle.btn-info{background-image:none}.btn-info.disabled.focus,.btn-info.disabled:focus,.btn-info.disabled:hover,.btn-info[disabled].focus,.btn-info[disabled]:focus,.btn-info[disabled]:hover,fieldset[disabled] .btn-info.focus,fieldset[disabled] .btn-info:focus,fieldset[disabled] .btn-info:hover{background-color:#5bc0de;border-color:#46b8da}.btn-info .badge{color:#5bc0de;background-color:#fff}.btn-warning{color:#fff;background-color:#f0ad4e;border-color:#eea236}.btn-warning.focus,.btn-warning:focus{color:#fff;background-color:#ec971f;border-color:#985f0d}.btn-warning:hover{color:#fff;background-color:#ec971f;border-color:#d58512}.btn-warning.active,.btn-warning:active,.open>.dropdown-toggle.btn-warning{color:#fff;background-color:#ec971f;border-color:#d58512}.btn-warning.active.focus,.btn-warning.active:focus,.btn-warning.active:hover,.btn-warning:active.focus,.btn-warning:active:focus,.btn-warning:active:hover,.open>.dropdown-toggle.btn-warning.focus,.open>.dropdown-toggle.btn-warning:focus,.open>.dropdown-toggle.btn-warning:hover{color:#fff;background-color:#d58512;border-color:#985f0d}.btn-warning.active,.btn-warning:active,.open>.dropdown-toggle.btn-warning{background-image:none}.btn-warning.disabled.focus,.btn-warning.disabled:focus,.btn-warning.disabled:hover,.btn-warning[disabled].focus,.btn-warning[disabled]:focus,.btn-warning[disabled]:hover,fieldset[disabled] .btn-warning.focus,fieldset[disabled] .btn-warning:focus,fieldset[disabled] .btn-warning:hover{background-color:#f0ad4e;border-color:#eea236}.btn-warning .badge{color:#f0ad4e;background-color:#fff}.btn-danger{color:#fff;background-color:#d9534f;border-color:#d43f3a}.btn-danger.focus,.btn-danger:focus{color:#fff;background-color:#c9302c;border-color:#761c19}.btn-danger:hover{color:#fff;background-color:#c9302c;border-color:#ac2925}.btn-danger.active,.btn-danger:active,.open>.dropdown-toggle.btn-danger{color:#fff;background-color:#c9302c;border-color:#ac2925}.btn-danger.active.focus,.btn-danger.active:focus,.btn-danger.active:hover,.btn-danger:active.focus,.btn-danger:active:focus,.btn-danger:active:hover,.open>.dropdown-toggle.btn-danger.focus,.open>.dropdown-toggle.btn-danger:focus,.open>.dropdown-toggle.btn-danger:hover{color:#fff;background-color:#ac2925;border-color:#761c19}.btn-danger.active,.btn-danger:active,.open>.dropdown-toggle.btn-danger{background-image:none}.btn-danger.disabled.focus,.btn-danger.disabled:focus,.btn-danger.disabled:hover,.btn-danger[disabled].focus,.btn-danger[disabled]:focus,.btn-danger[disabled]:hover,fieldset[disabled] .btn-danger.focus,fieldset[disabled] .btn-danger:focus,fieldset[disabled] .btn-danger:hover{background-color:#d9534f;border-color:#d43f3a}.btn-danger .badge{color:#d9534f;background-color:#fff}.btn-link{font-weight:400;color:#337ab7;border-radius:0}.btn-link,.btn-link.active,.btn-link:active,.btn-link[disabled],fieldset[disabled] .btn-link{background-color:transparent;-webkit-box-shadow:none;box-shadow:none}.btn-link,.btn-link:active,.btn-link:focus,.btn-link:hover{border-color:transparent}.btn-link:focus,.btn-link:hover{color:#23527c;text-decoration:underline;background-color:transparent}.btn-link[disabled]:focus,.btn-link[disabled]:hover,fieldset[disabled] .btn-link:focus,fieldset[disabled] .btn-link:hover{color:#777;text-decoration:none}.btn-group-lg>.btn,.btn-lg{padding:10px 16px;font-size:18px;line-height:1.3333333;border-radius:6px}.btn-group-sm>.btn,.btn-sm{padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}.btn-group-xs>.btn,.btn-xs{padding:1px 5px;font-size:12px;line-height:1.5;border-radius:3px}.btn-block{display:block;width:100%}.btn-block+.btn-block{margin-top:5px}input[type=button].btn-block,input[type=reset].btn-block,input[type=submit].btn-block{width:100%}.fade{opacity:0;-webkit-transition:opacity .15s linear;-o-transition:opacity .15s linear;transition:opacity .15s linear}.fade.in{opacity:1}.collapse{display:none}.collapse.in{display:block}tr.collapse.in{display:table-row}tbody.collapse.in{display:table-row-group}.collapsing{position:relative;height:0;overflow:hidden;-webkit-transition-timing-function:ease;-o-transition-timing-function:ease;transition-timing-function:ease;-webkit-transition-duration:.35s;-o-transition-duration:.35s;transition-duration:.35s;-webkit-transition-property:height,visibility;-o-transition-property:height,visibility;transition-property:height,visibility}.caret{display:inline-block;width:0;height:0;margin-left:2px;vertical-align:middle;border-top:4px dashed;border-top:4px solid\9;border-right:4px solid transparent;border-left:4px solid transparent}.dropdown,.dropup{position:relative}.dropdown-toggle:focus{outline:0}.dropdown-menu{position:absolute;top:100%;left:0;z-index:1000;display:none;float:left;min-width:160px;padding:5px 0;margin:2px 0 0;font-size:14px;text-align:left;list-style:none;background-color:#fff;-webkit-background-clip:padding-box;background-clip:padding-box;border:1px solid #ccc;border:1px solid rgba(0,0,0,.15);border-radius:4px;-webkit-box-shadow:0 6px 12px rgba(0,0,0,.175);box-shadow:0 6px 12px rgba(0,0,0,.175)}.dropdown-menu.pull-right{right:0;left:auto}.dropdown-menu .divider{height:1px;margin:9px 0;overflow:hidden;background-color:#e5e5e5}.dropdown-menu>li>a{display:block;padding:3px 20px;clear:both;font-weight:400;line-height:1.42857143;color:#333;white-space:nowrap}.dropdown-menu>li>a:focus,.dropdown-menu>li>a:hover{color:#262626;text-decoration:none;background-color:#f5f5f5}.dropdown-menu>.active>a,.dropdown-menu>.active>a:focus,.dropdown-menu>.active>a:hover{color:#fff;text-decoration:none;background-color:#337ab7;outline:0}.dropdown-menu>.disabled>a,.dropdown-menu>.disabled>a:focus,.dropdown-menu>.disabled>a:hover{color:#777}.dropdown-menu>.disabled>a:focus,.dropdown-menu>.disabled>a:hover{text-decoration:none;cursor:not-allowed;background-color:transparent;background-image:none;filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.open>.dropdown-menu{display:block}.open>a{outline:0}.dropdown-menu-right{right:0;left:auto}.dropdown-menu-left{right:auto;left:0}.dropdown-header{display:block;padding:3px 20px;font-size:12px;line-height:1.42857143;color:#777;white-space:nowrap}.dropdown-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;z-index:990}.pull-right>.dropdown-menu{right:0;left:auto}.dropup .caret,.navbar-fixed-bottom .dropdown .caret{content:"";border-top:0;border-bottom:4px dashed;border-bottom:4px solid\9}.dropup .dropdown-menu,.navbar-fixed-bottom .dropdown .dropdown-menu{top:auto;bottom:100%;margin-bottom:2px}@media (min-width:768px){.navbar-right .dropdown-menu{right:0;left:auto}.navbar-right .dropdown-menu-left{right:auto;left:0}}.btn-group,.btn-group-vertical{position:relative;display:inline-block;vertical-align:middle}.btn-group-vertical>.btn,.btn-group>.btn{position:relative;float:left}.btn-group-vertical>.btn.active,.btn-group-vertical>.btn:active,.btn-group-vertical>.btn:focus,.btn-group-vertical>.btn:hover,.btn-group>.btn.active,.btn-group>.btn:active,.btn-group>.btn:focus,.btn-group>.btn:hover{z-index:2}.btn-group .btn+.btn,.btn-group .btn+.btn-group,.btn-group .btn-group+.btn,.btn-group .btn-group+.btn-group{margin-left:-1px}.btn-toolbar{margin-left:-5px}.btn-toolbar .btn,.btn-toolbar .btn-group,.btn-toolbar .input-group{float:left}.btn-toolbar>.btn,.btn-toolbar>.btn-group,.btn-toolbar>.input-group{margin-left:5px}.btn-group>.btn:not(:first-child):not(:last-child):not(.dropdown-toggle){border-radius:0}.btn-group>.btn:first-child{margin-left:0}.btn-group>.btn:first-child:not(:last-child):not(.dropdown-toggle){border-top-right-radius:0;border-bottom-right-radius:0}.btn-group>.btn:last-child:not(:first-child),.btn-group>.dropdown-toggle:not(:first-child){border-top-left-radius:0;border-bottom-left-radius:0}.btn-group>.btn-group{float:left}.btn-group>.btn-group:not(:first-child):not(:last-child)>.btn{border-radius:0}.btn-group>.btn-group:first-child:not(:last-child)>.btn:last-child,.btn-group>.btn-group:first-child:not(:last-child)>.dropdown-toggle{border-top-right-radius:0;border-bottom-right-radius:0}.btn-group>.btn-group:last-child:not(:first-child)>.btn:first-child{border-top-left-radius:0;border-bottom-left-radius:0}.btn-group .dropdown-toggle:active,.btn-group.open .dropdown-toggle{outline:0}.btn-group>.btn+.dropdown-toggle{padding-right:8px;padding-left:8px}.btn-group>.btn-lg+.dropdown-toggle{padding-right:12px;padding-left:12px}.btn-group.open .dropdown-toggle{-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.btn-group.open .dropdown-toggle.btn-link{-webkit-box-shadow:none;box-shadow:none}.btn .caret{margin-left:0}.btn-lg .caret{border-width:5px 5px 0;border-bottom-width:0}.dropup .btn-lg .caret{border-width:0 5px 5px}.btn-group-vertical>.btn,.btn-group-vertical>.btn-group,.btn-group-vertical>.btn-group>.btn{display:block;float:none;width:100%;max-width:100%}.btn-group-vertical>.btn-group>.btn{float:none}.btn-group-vertical>.btn+.btn,.btn-group-vertical>.btn+.btn-group,.btn-group-vertical>.btn-group+.btn,.btn-group-vertical>.btn-group+.btn-group{margin-top:-1px;margin-left:0}.btn-group-vertical>.btn:not(:first-child):not(:last-child){border-radius:0}.btn-group-vertical>.btn:first-child:not(:last-child){border-top-left-radius:4px;border-top-right-radius:4px;border-bottom-right-radius:0;border-bottom-left-radius:0}.btn-group-vertical>.btn:last-child:not(:first-child){border-top-left-radius:0;border-top-right-radius:0;border-bottom-right-radius:4px;border-bottom-left-radius:4px}.btn-group-vertical>.btn-group:not(:first-child):not(:last-child)>.btn{border-radius:0}.btn-group-vertical>.btn-group:first-child:not(:last-child)>.btn:last-child,.btn-group-vertical>.btn-group:first-child:not(:last-child)>.dropdown-toggle{border-bottom-right-radius:0;border-bottom-left-radius:0}.btn-group-vertical>.btn-group:last-child:not(:first-child)>.btn:first-child{border-top-left-radius:0;border-top-right-radius:0}.btn-group-justified{display:table;width:100%;table-layout:fixed;border-collapse:separate}.btn-group-justified>.btn,.btn-group-justified>.btn-group{display:table-cell;float:none;width:1%}.btn-group-justified>.btn-group .btn{width:100%}.btn-group-justified>.btn-group .dropdown-menu{left:auto}[data-toggle=buttons]>.btn input[type=checkbox],[data-toggle=buttons]>.btn input[type=radio],[data-toggle=buttons]>.btn-group>.btn input[type=checkbox],[data-toggle=buttons]>.btn-group>.btn input[type=radio]{position:absolute;clip:rect(0,0,0,0);pointer-events:none}.input-group{position:relative;display:table;border-collapse:separate}.input-group[class*=col-]{float:none;padding-right:0;padding-left:0}.input-group .form-control{position:relative;z-index:2;float:left;width:100%;margin-bottom:0}.input-group .form-control:focus{z-index:3}.input-group-lg>.form-control,.input-group-lg>.input-group-addon,.input-group-lg>.input-group-btn>.btn{height:46px;padding:10px 16px;font-size:18px;line-height:1.3333333;border-radius:6px}select.input-group-lg>.form-control,select.input-group-lg>.input-group-addon,select.input-group-lg>.input-group-btn>.btn{height:46px;line-height:46px}select[multiple].input-group-lg>.form-control,select[multiple].input-group-lg>.input-group-addon,select[multiple].input-group-lg>.input-group-btn>.btn,textarea.input-group-lg>.form-control,textarea.input-group-lg>.input-group-addon,textarea.input-group-lg>.input-group-btn>.btn{height:auto}.input-group-sm>.form-control,.input-group-sm>.input-group-addon,.input-group-sm>.input-group-btn>.btn{height:30px;padding:5px 10px;font-size:12px;line-height:1.5;border-radius:3px}select.input-group-sm>.form-control,select.input-group-sm>.input-group-addon,select.input-group-sm>.input-group-btn>.btn{height:30px;line-height:30px}select[multiple].input-group-sm>.form-control,select[multiple].input-group-sm>.input-group-addon,select[multiple].input-group-sm>.input-group-btn>.btn,textarea.input-group-sm>.form-control,textarea.input-group-sm>.input-group-addon,textarea.input-group-sm>.input-group-btn>.btn{height:auto}.input-group .form-control,.input-group-addon,.input-group-btn{display:table-cell}.input-group .form-control:not(:first-child):not(:last-child),.input-group-addon:not(:first-child):not(:last-child),.input-group-btn:not(:first-child):not(:last-child){border-radius:0}.input-group-addon,.input-group-btn{width:1%;white-space:nowrap;vertical-align:middle}.input-group-addon{padding:6px 12px;font-size:14px;font-weight:400;line-height:1;color:#555;text-align:center;background-color:#eee;border:1px solid #ccc;border-radius:4px}.input-group-addon.input-sm{padding:5px 10px;font-size:12px;border-radius:3px}.input-group-addon.input-lg{padding:10px 16px;font-size:18px;border-radius:6px}.input-group-addon input[type=checkbox],.input-group-addon input[type=radio]{margin-top:0}.input-group .form-control:first-child,.input-group-addon:first-child,.input-group-btn:first-child>.btn,.input-group-btn:first-child>.btn-group>.btn,.input-group-btn:first-child>.dropdown-toggle,.input-group-btn:last-child>.btn-group:not(:last-child)>.btn,.input-group-btn:last-child>.btn:not(:last-child):not(.dropdown-toggle){border-top-right-radius:0;border-bottom-right-radius:0}.input-group-addon:first-child{border-right:0}.input-group .form-control:last-child,.input-group-addon:last-child,.input-group-btn:first-child>.btn-group:not(:first-child)>.btn,.input-group-btn:first-child>.btn:not(:first-child),.input-group-btn:last-child>.btn,.input-group-btn:last-child>.btn-group>.btn,.input-group-btn:last-child>.dropdown-toggle{border-top-left-radius:0;border-bottom-left-radius:0}.input-group-addon:last-child{border-left:0}.input-group-btn{position:relative;font-size:0;white-space:nowrap}.input-group-btn>.btn{position:relative}.input-group-btn>.btn+.btn{margin-left:-1px}.input-group-btn>.btn:active,.input-group-btn>.btn:focus,.input-group-btn>.btn:hover{z-index:2}.input-group-btn:first-child>.btn,.input-group-btn:first-child>.btn-group{margin-right:-1px}.input-group-btn:last-child>.btn,.input-group-btn:last-child>.btn-group{z-index:2;margin-left:-1px}.nav{padding-left:0;margin-bottom:0;list-style:none}.nav>li{position:relative;display:block}.nav>li>a{position:relative;display:block;padding:10px 15px}.nav>li>a:focus,.nav>li>a:hover{text-decoration:none;background-color:#eee}.nav>li.disabled>a{color:#777}.nav>li.disabled>a:focus,.nav>li.disabled>a:hover{color:#777;text-decoration:none;cursor:not-allowed;background-color:transparent}.nav .open>a,.nav .open>a:focus,.nav .open>a:hover{background-color:#eee;border-color:#337ab7}.nav .nav-divider{height:1px;margin:9px 0;overflow:hidden;background-color:#e5e5e5}.nav>li>a>img{max-width:none}.nav-tabs{border-bottom:1px solid #ddd}.nav-tabs>li{float:left;margin-bottom:-1px}.nav-tabs>li>a{margin-right:2px;line-height:1.42857143;border:1px solid transparent;border-radius:4px 4px 0 0}.nav-tabs>li>a:hover{border-color:#eee #eee #ddd}.nav-tabs>li.active>a,.nav-tabs>li.active>a:focus,.nav-tabs>li.active>a:hover{color:#555;cursor:default;background-color:#fff;border:1px solid #ddd;border-bottom-color:transparent}.nav-tabs.nav-justified{width:100%;border-bottom:0}.nav-tabs.nav-justified>li{float:none}.nav-tabs.nav-justified>li>a{margin-bottom:5px;text-align:center}.nav-tabs.nav-justified>.dropdown .dropdown-menu{top:auto;left:auto}@media (min-width:768px){.nav-tabs.nav-justified>li{display:table-cell;width:1%}.nav-tabs.nav-justified>li>a{margin-bottom:0}}.nav-tabs.nav-justified>li>a{margin-right:0;border-radius:4px}.nav-tabs.nav-justified>.active>a,.nav-tabs.nav-justified>.active>a:focus,.nav-tabs.nav-justified>.active>a:hover{border:1px solid #ddd}@media (min-width:768px){.nav-tabs.nav-justified>li>a{border-bottom:1px solid #ddd;border-radius:4px 4px 0 0}.nav-tabs.nav-justified>.active>a,.nav-tabs.nav-justified>.active>a:focus,.nav-tabs.nav-justified>.active>a:hover{border-bottom-color:#fff}}.nav-pills>li{float:left}.nav-pills>li>a{border-radius:4px}.nav-pills>li+li{margin-left:2px}.nav-pills>li.active>a,.nav-pills>li.active>a:focus,.nav-pills>li.active>a:hover{color:#fff;background-color:#337ab7}.nav-stacked>li{float:none}.nav-stacked>li+li{margin-top:2px;margin-left:0}.nav-justified{width:100%}.nav-justified>li{float:none}.nav-justified>li>a{margin-bottom:5px;text-align:center}.nav-justified>.dropdown .dropdown-menu{top:auto;left:auto}@media (min-width:768px){.nav-justified>li{display:table-cell;width:1%}.nav-justified>li>a{margin-bottom:0}}.nav-tabs-justified{border-bottom:0}.nav-tabs-justified>li>a{margin-right:0;border-radius:4px}.nav-tabs-justified>.active>a,.nav-tabs-justified>.active>a:focus,.nav-tabs-justified>.active>a:hover{border:1px solid #ddd}@media (min-width:768px){.nav-tabs-justified>li>a{border-bottom:1px solid #ddd;border-radius:4px 4px 0 0}.nav-tabs-justified>.active>a,.nav-tabs-justified>.active>a:focus,.nav-tabs-justified>.active>a:hover{border-bottom-color:#fff}}.tab-content>.tab-pane{display:none}.tab-content>.active{display:block}.nav-tabs .dropdown-menu{margin-top:-1px;border-top-left-radius:0;border-top-right-radius:0}.navbar{position:relative;min-height:50px;margin-bottom:20px;border:1px solid transparent}@media (min-width:768px){.navbar{border-radius:4px}}@media (min-width:768px){.navbar-header{float:left}}.navbar-collapse{padding-right:15px;padding-left:15px;overflow-x:visible;-webkit-overflow-scrolling:touch;border-top:1px solid transparent;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.1);box-shadow:inset 0 1px 0 rgba(255,255,255,.1)}.navbar-collapse.in{overflow-y:auto}@media (min-width:768px){.navbar-collapse{width:auto;border-top:0;-webkit-box-shadow:none;box-shadow:none}.navbar-collapse.collapse{display:block!important;height:auto!important;padding-bottom:0;overflow:visible!important}.navbar-collapse.in{overflow-y:visible}.navbar-fixed-bottom .navbar-collapse,.navbar-fixed-top .navbar-collapse,.navbar-static-top .navbar-collapse{padding-right:0;padding-left:0}}.navbar-fixed-bottom .navbar-collapse,.navbar-fixed-top .navbar-collapse{max-height:340px}@media (max-device-width:480px) and (orientation:landscape){.navbar-fixed-bottom .navbar-collapse,.navbar-fixed-top .navbar-collapse{max-height:200px}}.container-fluid>.navbar-collapse,.container-fluid>.navbar-header,.container>.navbar-collapse,.container>.navbar-header{margin-right:-15px;margin-left:-15px}@media (min-width:768px){.container-fluid>.navbar-collapse,.container-fluid>.navbar-header,.container>.navbar-collapse,.container>.navbar-header{margin-right:0;margin-left:0}}.navbar-static-top{z-index:1000;border-width:0 0 1px}@media (min-width:768px){.navbar-static-top{border-radius:0}}.navbar-fixed-bottom,.navbar-fixed-top{position:fixed;right:0;left:0;z-index:1030}@media (min-width:768px){.navbar-fixed-bottom,.navbar-fixed-top{border-radius:0}}.navbar-fixed-top{top:0;border-width:0 0 1px}.navbar-fixed-bottom{bottom:0;margin-bottom:0;border-width:1px 0 0}.navbar-brand{float:left;height:50px;padding:15px 15px;font-size:18px;line-height:20px}.navbar-brand:focus,.navbar-brand:hover{text-decoration:none}.navbar-brand>img{display:block}@media (min-width:768px){.navbar>.container .navbar-brand,.navbar>.container-fluid .navbar-brand{margin-left:-15px}}.navbar-toggle{position:relative;float:right;padding:9px 10px;margin-top:8px;margin-right:15px;margin-bottom:8px;background-color:transparent;background-image:none;border:1px solid transparent;border-radius:4px}.navbar-toggle:focus{outline:0}.navbar-toggle .icon-bar{display:block;width:22px;height:2px;border-radius:1px}.navbar-toggle .icon-bar+.icon-bar{margin-top:4px}@media (min-width:768px){.navbar-toggle{display:none}}.navbar-nav{margin:7.5px -15px}.navbar-nav>li>a{padding-top:10px;padding-bottom:10px;line-height:20px}@media (max-width:767px){.navbar-nav .open .dropdown-menu{position:static;float:none;width:auto;margin-top:0;background-color:transparent;border:0;-webkit-box-shadow:none;box-shadow:none}.navbar-nav .open .dropdown-menu .dropdown-header,.navbar-nav .open .dropdown-menu>li>a{padding:5px 15px 5px 25px}.navbar-nav .open .dropdown-menu>li>a{line-height:20px}.navbar-nav .open .dropdown-menu>li>a:focus,.navbar-nav .open .dropdown-menu>li>a:hover{background-image:none}}@media (min-width:768px){.navbar-nav{float:left;margin:0}.navbar-nav>li{float:left}.navbar-nav>li>a{padding-top:15px;padding-bottom:15px}}.navbar-form{padding:10px 15px;margin-top:8px;margin-right:-15px;margin-bottom:8px;margin-left:-15px;border-top:1px solid transparent;border-bottom:1px solid transparent;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.1),0 1px 0 rgba(255,255,255,.1);box-shadow:inset 0 1px 0 rgba(255,255,255,.1),0 1px 0 rgba(255,255,255,.1)}@media (min-width:768px){.navbar-form .form-group{display:inline-block;margin-bottom:0;vertical-align:middle}.navbar-form .form-control{display:inline-block;width:auto;vertical-align:middle}.navbar-form .form-control-static{display:inline-block}.navbar-form .input-group{display:inline-table;vertical-align:middle}.navbar-form .input-group .form-control,.navbar-form .input-group .input-group-addon,.navbar-form .input-group .input-group-btn{width:auto}.navbar-form .input-group>.form-control{width:100%}.navbar-form .control-label{margin-bottom:0;vertical-align:middle}.navbar-form .checkbox,.navbar-form .radio{display:inline-block;margin-top:0;margin-bottom:0;vertical-align:middle}.navbar-form .checkbox label,.navbar-form .radio label{padding-left:0}.navbar-form .checkbox input[type=checkbox],.navbar-form .radio input[type=radio]{position:relative;margin-left:0}.navbar-form .has-feedback .form-control-feedback{top:0}}@media (max-width:767px){.navbar-form .form-group{margin-bottom:5px}.navbar-form .form-group:last-child{margin-bottom:0}}@media (min-width:768px){.navbar-form{width:auto;padding-top:0;padding-bottom:0;margin-right:0;margin-left:0;border:0;-webkit-box-shadow:none;box-shadow:none}}.navbar-nav>li>.dropdown-menu{margin-top:0;border-top-left-radius:0;border-top-right-radius:0}.navbar-fixed-bottom .navbar-nav>li>.dropdown-menu{margin-bottom:0;border-top-left-radius:4px;border-top-right-radius:4px;border-bottom-right-radius:0;border-bottom-left-radius:0}.navbar-btn{margin-top:8px;margin-bottom:8px}.navbar-btn.btn-sm{margin-top:10px;margin-bottom:10px}.navbar-btn.btn-xs{margin-top:14px;margin-bottom:14px}.navbar-text{margin-top:15px;margin-bottom:15px}@media (min-width:768px){.navbar-text{float:left;margin-right:15px;margin-left:15px}}@media (min-width:768px){.navbar-left{float:left!important}.navbar-right{float:right!important;margin-right:-15px}.navbar-right~.navbar-right{margin-right:0}}.navbar-default{background-color:#f8f8f8;border-color:#e7e7e7}.navbar-default .navbar-brand{color:#777}.navbar-default .navbar-brand:focus,.navbar-default .navbar-brand:hover{color:#5e5e5e;background-color:transparent}.navbar-default .navbar-text{color:#777}.navbar-default .navbar-nav>li>a{color:#777}.navbar-default .navbar-nav>li>a:focus,.navbar-default .navbar-nav>li>a:hover{color:#333;background-color:transparent}.navbar-default .navbar-nav>.active>a,.navbar-default .navbar-nav>.active>a:focus,.navbar-default .navbar-nav>.active>a:hover{color:#555;background-color:#e7e7e7}.navbar-default .navbar-nav>.disabled>a,.navbar-default .navbar-nav>.disabled>a:focus,.navbar-default .navbar-nav>.disabled>a:hover{color:#ccc;background-color:transparent}.navbar-default .navbar-toggle{border-color:#ddd}.navbar-default .navbar-toggle:focus,.navbar-default .navbar-toggle:hover{background-color:#ddd}.navbar-default .navbar-toggle .icon-bar{background-color:#888}.navbar-default .navbar-collapse,.navbar-default .navbar-form{border-color:#e7e7e7}.navbar-default .navbar-nav>.open>a,.navbar-default .navbar-nav>.open>a:focus,.navbar-default .navbar-nav>.open>a:hover{color:#555;background-color:#e7e7e7}@media (max-width:767px){.navbar-default .navbar-nav .open .dropdown-menu>li>a{color:#777}.navbar-default .navbar-nav .open .dropdown-menu>li>a:focus,.navbar-default .navbar-nav .open .dropdown-menu>li>a:hover{color:#333;background-color:transparent}.navbar-default .navbar-nav .open .dropdown-menu>.active>a,.navbar-default .navbar-nav .open .dropdown-menu>.active>a:focus,.navbar-default .navbar-nav .open .dropdown-menu>.active>a:hover{color:#555;background-color:#e7e7e7}.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a,.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a:focus,.navbar-default .navbar-nav .open .dropdown-menu>.disabled>a:hover{color:#ccc;background-color:transparent}}.navbar-default .navbar-link{color:#777}.navbar-default .navbar-link:hover{color:#333}.navbar-default .btn-link{color:#777}.navbar-default .btn-link:focus,.navbar-default .btn-link:hover{color:#333}.navbar-default .btn-link[disabled]:focus,.navbar-default .btn-link[disabled]:hover,fieldset[disabled] .navbar-default .btn-link:focus,fieldset[disabled] .navbar-default .btn-link:hover{color:#ccc}.navbar-inverse{background-color:#222;border-color:#080808}.navbar-inverse .navbar-brand{color:#9d9d9d}.navbar-inverse .navbar-brand:focus,.navbar-inverse .navbar-brand:hover{color:#fff;background-color:transparent}.navbar-inverse .navbar-text{color:#9d9d9d}.navbar-inverse .navbar-nav>li>a{color:#9d9d9d}.navbar-inverse .navbar-nav>li>a:focus,.navbar-inverse .navbar-nav>li>a:hover{color:#fff;background-color:transparent}.navbar-inverse .navbar-nav>.active>a,.navbar-inverse .navbar-nav>.active>a:focus,.navbar-inverse .navbar-nav>.active>a:hover{color:#fff;background-color:#080808}.navbar-inverse .navbar-nav>.disabled>a,.navbar-inverse .navbar-nav>.disabled>a:focus,.navbar-inverse .navbar-nav>.disabled>a:hover{color:#444;background-color:transparent}.navbar-inverse .navbar-toggle{border-color:#333}.navbar-inverse .navbar-toggle:focus,.navbar-inverse .navbar-toggle:hover{background-color:#333}.navbar-inverse .navbar-toggle .icon-bar{background-color:#fff}.navbar-inverse .navbar-collapse,.navbar-inverse .navbar-form{border-color:#101010}.navbar-inverse .navbar-nav>.open>a,.navbar-inverse .navbar-nav>.open>a:focus,.navbar-inverse .navbar-nav>.open>a:hover{color:#fff;background-color:#080808}@media (max-width:767px){.navbar-inverse .navbar-nav .open .dropdown-menu>.dropdown-header{border-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu .divider{background-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu>li>a{color:#9d9d9d}.navbar-inverse .navbar-nav .open .dropdown-menu>li>a:focus,.navbar-inverse .navbar-nav .open .dropdown-menu>li>a:hover{color:#fff;background-color:transparent}.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a,.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a:focus,.navbar-inverse .navbar-nav .open .dropdown-menu>.active>a:hover{color:#fff;background-color:#080808}.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a,.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a:focus,.navbar-inverse .navbar-nav .open .dropdown-menu>.disabled>a:hover{color:#444;background-color:transparent}}.navbar-inverse .navbar-link{color:#9d9d9d}.navbar-inverse .navbar-link:hover{color:#fff}.navbar-inverse .btn-link{color:#9d9d9d}.navbar-inverse .btn-link:focus,.navbar-inverse .btn-link:hover{color:#fff}.navbar-inverse .btn-link[disabled]:focus,.navbar-inverse .btn-link[disabled]:hover,fieldset[disabled] .navbar-inverse .btn-link:focus,fieldset[disabled] .navbar-inverse .btn-link:hover{color:#444}.breadcrumb{padding:8px 15px;margin-bottom:20px;list-style:none;background-color:#f5f5f5;border-radius:4px}.breadcrumb>li{display:inline-block}.breadcrumb>li+li:before{padding:0 5px;color:#ccc;content:"/\00a0"}.breadcrumb>.active{color:#777}.pagination{display:inline-block;padding-left:0;margin:20px 0;border-radius:4px}.pagination>li{display:inline}.pagination>li>a,.pagination>li>span{position:relative;float:left;padding:6px 12px;margin-left:-1px;line-height:1.42857143;color:#337ab7;text-decoration:none;background-color:#fff;border:1px solid #ddd}.pagination>li:first-child>a,.pagination>li:first-child>span{margin-left:0;border-top-left-radius:4px;border-bottom-left-radius:4px}.pagination>li:last-child>a,.pagination>li:last-child>span{border-top-right-radius:4px;border-bottom-right-radius:4px}.pagination>li>a:focus,.pagination>li>a:hover,.pagination>li>span:focus,.pagination>li>span:hover{z-index:2;color:#23527c;background-color:#eee;border-color:#ddd}.pagination>.active>a,.pagination>.active>a:focus,.pagination>.active>a:hover,.pagination>.active>span,.pagination>.active>span:focus,.pagination>.active>span:hover{z-index:3;color:#fff;cursor:default;background-color:#337ab7;border-color:#337ab7}.pagination>.disabled>a,.pagination>.disabled>a:focus,.pagination>.disabled>a:hover,.pagination>.disabled>span,.pagination>.disabled>span:focus,.pagination>.disabled>span:hover{color:#777;cursor:not-allowed;background-color:#fff;border-color:#ddd}.pagination-lg>li>a,.pagination-lg>li>span{padding:10px 16px;font-size:18px;line-height:1.3333333}.pagination-lg>li:first-child>a,.pagination-lg>li:first-child>span{border-top-left-radius:6px;border-bottom-left-radius:6px}.pagination-lg>li:last-child>a,.pagination-lg>li:last-child>span{border-top-right-radius:6px;border-bottom-right-radius:6px}.pagination-sm>li>a,.pagination-sm>li>span{padding:5px 10px;font-size:12px;line-height:1.5}.pagination-sm>li:first-child>a,.pagination-sm>li:first-child>span{border-top-left-radius:3px;border-bottom-left-radius:3px}.pagination-sm>li:last-child>a,.pagination-sm>li:last-child>span{border-top-right-radius:3px;border-bottom-right-radius:3px}.pager{padding-left:0;margin:20px 0;text-align:center;list-style:none}.pager li{display:inline}.pager li>a,.pager li>span{display:inline-block;padding:5px 14px;background-color:#fff;border:1px solid #ddd;border-radius:15px}.pager li>a:focus,.pager li>a:hover{text-decoration:none;background-color:#eee}.pager .next>a,.pager .next>span{float:right}.pager .previous>a,.pager .previous>span{float:left}.pager .disabled>a,.pager .disabled>a:focus,.pager .disabled>a:hover,.pager .disabled>span{color:#777;cursor:not-allowed;background-color:#fff}.label{display:inline;padding:.2em .6em .3em;font-size:75%;font-weight:700;line-height:1;color:#fff;text-align:center;white-space:nowrap;vertical-align:baseline;border-radius:.25em}a.label:focus,a.label:hover{color:#fff;text-decoration:none;cursor:pointer}.label:empty{display:none}.btn .label{position:relative;top:-1px}.label-default{background-color:#777}.label-default[href]:focus,.label-default[href]:hover{background-color:#5e5e5e}.label-primary{background-color:#337ab7}.label-primary[href]:focus,.label-primary[href]:hover{background-color:#286090}.label-success{background-color:#5cb85c}.label-success[href]:focus,.label-success[href]:hover{background-color:#449d44}.label-info{background-color:#5bc0de}.label-info[href]:focus,.label-info[href]:hover{background-color:#31b0d5}.label-warning{background-color:#f0ad4e}.label-warning[href]:focus,.label-warning[href]:hover{background-color:#ec971f}.label-danger{background-color:#d9534f}.label-danger[href]:focus,.label-danger[href]:hover{background-color:#c9302c}.badge{display:inline-block;min-width:10px;padding:3px 7px;font-size:12px;font-weight:700;line-height:1;color:#fff;text-align:center;white-space:nowrap;vertical-align:middle;background-color:#777;border-radius:10px}.badge:empty{display:none}.btn .badge{position:relative;top:-1px}.btn-group-xs>.btn .badge,.btn-xs .badge{top:0;padding:1px 5px}a.badge:focus,a.badge:hover{color:#fff;text-decoration:none;cursor:pointer}.list-group-item.active>.badge,.nav-pills>.active>a>.badge{color:#337ab7;background-color:#fff}.list-group-item>.badge{float:right}.list-group-item>.badge+.badge{margin-right:5px}.nav-pills>li>a>.badge{margin-left:3px}.jumbotron{padding-top:30px;padding-bottom:30px;margin-bottom:30px;color:inherit;background-color:#eee}.jumbotron .h1,.jumbotron h1{color:inherit}.jumbotron p{margin-bottom:15px;font-size:21px;font-weight:200}.jumbotron>hr{border-top-color:#d5d5d5}.container .jumbotron,.container-fluid .jumbotron{padding-right:15px;padding-left:15px;border-radius:6px}.jumbotron .container{max-width:100%}@media screen and (min-width:768px){.jumbotron{padding-top:48px;padding-bottom:48px}.container .jumbotron,.container-fluid .jumbotron{padding-right:60px;padding-left:60px}.jumbotron .h1,.jumbotron h1{font-size:63px}}.thumbnail{display:block;padding:4px;margin-bottom:20px;line-height:1.42857143;background-color:#fff;border:1px solid #ddd;border-radius:4px;-webkit-transition:border .2s ease-in-out;-o-transition:border .2s ease-in-out;transition:border .2s ease-in-out}.thumbnail a>img,.thumbnail>img{margin-right:auto;margin-left:auto}a.thumbnail.active,a.thumbnail:focus,a.thumbnail:hover{border-color:#337ab7}.thumbnail .caption{padding:9px;color:#333}.alert{padding:15px;margin-bottom:20px;border:1px solid transparent;border-radius:4px}.alert h4{margin-top:0;color:inherit}.alert .alert-link{font-weight:700}.alert>p,.alert>ul{margin-bottom:0}.alert>p+p{margin-top:5px}.alert-dismissable,.alert-dismissible{padding-right:35px}.alert-dismissable .close,.alert-dismissible .close{position:relative;top:-2px;right:-21px;color:inherit}.alert-success{color:#3c763d;background-color:#dff0d8;border-color:#d6e9c6}.alert-success hr{border-top-color:#c9e2b3}.alert-success .alert-link{color:#2b542c}.alert-info{color:#31708f;background-color:#d9edf7;border-color:#bce8f1}.alert-info hr{border-top-color:#a6e1ec}.alert-info .alert-link{color:#245269}.alert-warning{color:#8a6d3b;background-color:#fcf8e3;border-color:#faebcc}.alert-warning hr{border-top-color:#f7e1b5}.alert-warning .alert-link{color:#66512c}.alert-danger{color:#a94442;background-color:#f2dede;border-color:#ebccd1}.alert-danger hr{border-top-color:#e4b9c0}.alert-danger .alert-link{color:#843534}@-webkit-keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}@-o-keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}@keyframes progress-bar-stripes{from{background-position:40px 0}to{background-position:0 0}}.progress{height:20px;margin-bottom:20px;overflow:hidden;background-color:#f5f5f5;border-radius:4px;-webkit-box-shadow:inset 0 1px 2px rgba(0,0,0,.1);box-shadow:inset 0 1px 2px rgba(0,0,0,.1)}.progress-bar{float:left;width:0;height:100%;font-size:12px;line-height:20px;color:#fff;text-align:center;background-color:#337ab7;-webkit-box-shadow:inset 0 -1px 0 rgba(0,0,0,.15);box-shadow:inset 0 -1px 0 rgba(0,0,0,.15);-webkit-transition:width .6s ease;-o-transition:width .6s ease;transition:width .6s ease}.progress-bar-striped,.progress-striped .progress-bar{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);-webkit-background-size:40px 40px;background-size:40px 40px}.progress-bar.active,.progress.active .progress-bar{-webkit-animation:progress-bar-stripes 2s linear infinite;-o-animation:progress-bar-stripes 2s linear infinite;animation:progress-bar-stripes 2s linear infinite}.progress-bar-success{background-color:#5cb85c}.progress-striped .progress-bar-success{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-info{background-color:#5bc0de}.progress-striped .progress-bar-info{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-warning{background-color:#f0ad4e}.progress-striped .progress-bar-warning{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.progress-bar-danger{background-color:#d9534f}.progress-striped .progress-bar-danger{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.media{margin-top:15px}.media:first-child{margin-top:0}.media,.media-body{overflow:hidden;zoom:1}.media-body{width:10000px}.media-object{display:block}.media-object.img-thumbnail{max-width:none}.media-right,.media>.pull-right{padding-left:10px}.media-left,.media>.pull-left{padding-right:10px}.media-body,.media-left,.media-right{display:table-cell;vertical-align:top}.media-middle{vertical-align:middle}.media-bottom{vertical-align:bottom}.media-heading{margin-top:0;margin-bottom:5px}.media-list{padding-left:0;list-style:none}.list-group{padding-left:0;margin-bottom:20px}.list-group-item{position:relative;display:block;padding:10px 15px;margin-bottom:-1px;background-color:#fff;border:1px solid #ddd}.list-group-item:first-child{border-top-left-radius:4px;border-top-right-radius:4px}.list-group-item:last-child{margin-bottom:0;border-bottom-right-radius:4px;border-bottom-left-radius:4px}a.list-group-item,button.list-group-item{color:#555}a.list-group-item .list-group-item-heading,button.list-group-item .list-group-item-heading{color:#333}a.list-group-item:focus,a.list-group-item:hover,button.list-group-item:focus,button.list-group-item:hover{color:#555;text-decoration:none;background-color:#f5f5f5}button.list-group-item{width:100%;text-align:left}.list-group-item.disabled,.list-group-item.disabled:focus,.list-group-item.disabled:hover{color:#777;cursor:not-allowed;background-color:#eee}.list-group-item.disabled .list-group-item-heading,.list-group-item.disabled:focus .list-group-item-heading,.list-group-item.disabled:hover .list-group-item-heading{color:inherit}.list-group-item.disabled .list-group-item-text,.list-group-item.disabled:focus .list-group-item-text,.list-group-item.disabled:hover .list-group-item-text{color:#777}.list-group-item.active,.list-group-item.active:focus,.list-group-item.active:hover{z-index:2;color:#fff;background-color:#337ab7;border-color:#337ab7}.list-group-item.active .list-group-item-heading,.list-group-item.active .list-group-item-heading>.small,.list-group-item.active .list-group-item-heading>small,.list-group-item.active:focus .list-group-item-heading,.list-group-item.active:focus .list-group-item-heading>.small,.list-group-item.active:focus .list-group-item-heading>small,.list-group-item.active:hover .list-group-item-heading,.list-group-item.active:hover .list-group-item-heading>.small,.list-group-item.active:hover .list-group-item-heading>small{color:inherit}.list-group-item.active .list-group-item-text,.list-group-item.active:focus .list-group-item-text,.list-group-item.active:hover .list-group-item-text{color:#c7ddef}.list-group-item-success{color:#3c763d;background-color:#dff0d8}a.list-group-item-success,button.list-group-item-success{color:#3c763d}a.list-group-item-success .list-group-item-heading,button.list-group-item-success .list-group-item-heading{color:inherit}a.list-group-item-success:focus,a.list-group-item-success:hover,button.list-group-item-success:focus,button.list-group-item-success:hover{color:#3c763d;background-color:#d0e9c6}a.list-group-item-success.active,a.list-group-item-success.active:focus,a.list-group-item-success.active:hover,button.list-group-item-success.active,button.list-group-item-success.active:focus,button.list-group-item-success.active:hover{color:#fff;background-color:#3c763d;border-color:#3c763d}.list-group-item-info{color:#31708f;background-color:#d9edf7}a.list-group-item-info,button.list-group-item-info{color:#31708f}a.list-group-item-info .list-group-item-heading,button.list-group-item-info .list-group-item-heading{color:inherit}a.list-group-item-info:focus,a.list-group-item-info:hover,button.list-group-item-info:focus,button.list-group-item-info:hover{color:#31708f;background-color:#c4e3f3}a.list-group-item-info.active,a.list-group-item-info.active:focus,a.list-group-item-info.active:hover,button.list-group-item-info.active,button.list-group-item-info.active:focus,button.list-group-item-info.active:hover{color:#fff;background-color:#31708f;border-color:#31708f}.list-group-item-warning{color:#8a6d3b;background-color:#fcf8e3}a.list-group-item-warning,button.list-group-item-warning{color:#8a6d3b}a.list-group-item-warning .list-group-item-heading,button.list-group-item-warning .list-group-item-heading{color:inherit}a.list-group-item-warning:focus,a.list-group-item-warning:hover,button.list-group-item-warning:focus,button.list-group-item-warning:hover{color:#8a6d3b;background-color:#faf2cc}a.list-group-item-warning.active,a.list-group-item-warning.active:focus,a.list-group-item-warning.active:hover,button.list-group-item-warning.active,button.list-group-item-warning.active:focus,button.list-group-item-warning.active:hover{color:#fff;background-color:#8a6d3b;border-color:#8a6d3b}.list-group-item-danger{color:#a94442;background-color:#f2dede}a.list-group-item-danger,button.list-group-item-danger{color:#a94442}a.list-group-item-danger .list-group-item-heading,button.list-group-item-danger .list-group-item-heading{color:inherit}a.list-group-item-danger:focus,a.list-group-item-danger:hover,button.list-group-item-danger:focus,button.list-group-item-danger:hover{color:#a94442;background-color:#ebcccc}a.list-group-item-danger.active,a.list-group-item-danger.active:focus,a.list-group-item-danger.active:hover,button.list-group-item-danger.active,button.list-group-item-danger.active:focus,button.list-group-item-danger.active:hover{color:#fff;background-color:#a94442;border-color:#a94442}.list-group-item-heading{margin-top:0;margin-bottom:5px}.list-group-item-text{margin-bottom:0;line-height:1.3}.panel{margin-bottom:20px;background-color:#fff;border:1px solid transparent;border-radius:4px;-webkit-box-shadow:0 1px 1px rgba(0,0,0,.05);box-shadow:0 1px 1px rgba(0,0,0,.05)}.panel-body{padding:15px}.panel-heading{padding:10px 15px;border-bottom:1px solid transparent;border-top-left-radius:3px;border-top-right-radius:3px}.panel-heading>.dropdown .dropdown-toggle{color:inherit}.panel-title{margin-top:0;margin-bottom:0;font-size:16px;color:inherit}.panel-title>.small,.panel-title>.small>a,.panel-title>a,.panel-title>small,.panel-title>small>a{color:inherit}.panel-footer{padding:10px 15px;background-color:#f5f5f5;border-top:1px solid #ddd;border-bottom-right-radius:3px;border-bottom-left-radius:3px}.panel>.list-group,.panel>.panel-collapse>.list-group{margin-bottom:0}.panel>.list-group .list-group-item,.panel>.panel-collapse>.list-group .list-group-item{border-width:1px 0;border-radius:0}.panel>.list-group:first-child .list-group-item:first-child,.panel>.panel-collapse>.list-group:first-child .list-group-item:first-child{border-top:0;border-top-left-radius:3px;border-top-right-radius:3px}.panel>.list-group:last-child .list-group-item:last-child,.panel>.panel-collapse>.list-group:last-child .list-group-item:last-child{border-bottom:0;border-bottom-right-radius:3px;border-bottom-left-radius:3px}.panel>.panel-heading+.panel-collapse>.list-group .list-group-item:first-child{border-top-left-radius:0;border-top-right-radius:0}.panel-heading+.list-group .list-group-item:first-child{border-top-width:0}.list-group+.panel-footer{border-top-width:0}.panel>.panel-collapse>.table,.panel>.table,.panel>.table-responsive>.table{margin-bottom:0}.panel>.panel-collapse>.table caption,.panel>.table caption,.panel>.table-responsive>.table caption{padding-right:15px;padding-left:15px}.panel>.table-responsive:first-child>.table:first-child,.panel>.table:first-child{border-top-left-radius:3px;border-top-right-radius:3px}.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child,.panel>.table:first-child>tbody:first-child>tr:first-child,.panel>.table:first-child>thead:first-child>tr:first-child{border-top-left-radius:3px;border-top-right-radius:3px}.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child td:first-child,.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child th:first-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child td:first-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child th:first-child,.panel>.table:first-child>tbody:first-child>tr:first-child td:first-child,.panel>.table:first-child>tbody:first-child>tr:first-child th:first-child,.panel>.table:first-child>thead:first-child>tr:first-child td:first-child,.panel>.table:first-child>thead:first-child>tr:first-child th:first-child{border-top-left-radius:3px}.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child td:last-child,.panel>.table-responsive:first-child>.table:first-child>tbody:first-child>tr:first-child th:last-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child td:last-child,.panel>.table-responsive:first-child>.table:first-child>thead:first-child>tr:first-child th:last-child,.panel>.table:first-child>tbody:first-child>tr:first-child td:last-child,.panel>.table:first-child>tbody:first-child>tr:first-child th:last-child,.panel>.table:first-child>thead:first-child>tr:first-child td:last-child,.panel>.table:first-child>thead:first-child>tr:first-child th:last-child{border-top-right-radius:3px}.panel>.table-responsive:last-child>.table:last-child,.panel>.table:last-child{border-bottom-right-radius:3px;border-bottom-left-radius:3px}.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child,.panel>.table:last-child>tbody:last-child>tr:last-child,.panel>.table:last-child>tfoot:last-child>tr:last-child{border-bottom-right-radius:3px;border-bottom-left-radius:3px}.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child td:first-child,.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child th:first-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child td:first-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child th:first-child,.panel>.table:last-child>tbody:last-child>tr:last-child td:first-child,.panel>.table:last-child>tbody:last-child>tr:last-child th:first-child,.panel>.table:last-child>tfoot:last-child>tr:last-child td:first-child,.panel>.table:last-child>tfoot:last-child>tr:last-child th:first-child{border-bottom-left-radius:3px}.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child td:last-child,.panel>.table-responsive:last-child>.table:last-child>tbody:last-child>tr:last-child th:last-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child td:last-child,.panel>.table-responsive:last-child>.table:last-child>tfoot:last-child>tr:last-child th:last-child,.panel>.table:last-child>tbody:last-child>tr:last-child td:last-child,.panel>.table:last-child>tbody:last-child>tr:last-child th:last-child,.panel>.table:last-child>tfoot:last-child>tr:last-child td:last-child,.panel>.table:last-child>tfoot:last-child>tr:last-child th:last-child{border-bottom-right-radius:3px}.panel>.panel-body+.table,.panel>.panel-body+.table-responsive,.panel>.table+.panel-body,.panel>.table-responsive+.panel-body{border-top:1px solid #ddd}.panel>.table>tbody:first-child>tr:first-child td,.panel>.table>tbody:first-child>tr:first-child th{border-top:0}.panel>.table-bordered,.panel>.table-responsive>.table-bordered{border:0}.panel>.table-bordered>tbody>tr>td:first-child,.panel>.table-bordered>tbody>tr>th:first-child,.panel>.table-bordered>tfoot>tr>td:first-child,.panel>.table-bordered>tfoot>tr>th:first-child,.panel>.table-bordered>thead>tr>td:first-child,.panel>.table-bordered>thead>tr>th:first-child,.panel>.table-responsive>.table-bordered>tbody>tr>td:first-child,.panel>.table-responsive>.table-bordered>tbody>tr>th:first-child,.panel>.table-responsive>.table-bordered>tfoot>tr>td:first-child,.panel>.table-responsive>.table-bordered>tfoot>tr>th:first-child,.panel>.table-responsive>.table-bordered>thead>tr>td:first-child,.panel>.table-responsive>.table-bordered>thead>tr>th:first-child{border-left:0}.panel>.table-bordered>tbody>tr>td:last-child,.panel>.table-bordered>tbody>tr>th:last-child,.panel>.table-bordered>tfoot>tr>td:last-child,.panel>.table-bordered>tfoot>tr>th:last-child,.panel>.table-bordered>thead>tr>td:last-child,.panel>.table-bordered>thead>tr>th:last-child,.panel>.table-responsive>.table-bordered>tbody>tr>td:last-child,.panel>.table-responsive>.table-bordered>tbody>tr>th:last-child,.panel>.table-responsive>.table-bordered>tfoot>tr>td:last-child,.panel>.table-responsive>.table-bordered>tfoot>tr>th:last-child,.panel>.table-responsive>.table-bordered>thead>tr>td:last-child,.panel>.table-responsive>.table-bordered>thead>tr>th:last-child{border-right:0}.panel>.table-bordered>tbody>tr:first-child>td,.panel>.table-bordered>tbody>tr:first-child>th,.panel>.table-bordered>thead>tr:first-child>td,.panel>.table-bordered>thead>tr:first-child>th,.panel>.table-responsive>.table-bordered>tbody>tr:first-child>td,.panel>.table-responsive>.table-bordered>tbody>tr:first-child>th,.panel>.table-responsive>.table-bordered>thead>tr:first-child>td,.panel>.table-responsive>.table-bordered>thead>tr:first-child>th{border-bottom:0}.panel>.table-bordered>tbody>tr:last-child>td,.panel>.table-bordered>tbody>tr:last-child>th,.panel>.table-bordered>tfoot>tr:last-child>td,.panel>.table-bordered>tfoot>tr:last-child>th,.panel>.table-responsive>.table-bordered>tbody>tr:last-child>td,.panel>.table-responsive>.table-bordered>tbody>tr:last-child>th,.panel>.table-responsive>.table-bordered>tfoot>tr:last-child>td,.panel>.table-responsive>.table-bordered>tfoot>tr:last-child>th{border-bottom:0}.panel>.table-responsive{margin-bottom:0;border:0}.panel-group{margin-bottom:20px}.panel-group .panel{margin-bottom:0;border-radius:4px}.panel-group .panel+.panel{margin-top:5px}.panel-group .panel-heading{border-bottom:0}.panel-group .panel-heading+.panel-collapse>.list-group,.panel-group .panel-heading+.panel-collapse>.panel-body{border-top:1px solid #ddd}.panel-group .panel-footer{border-top:0}.panel-group .panel-footer+.panel-collapse .panel-body{border-bottom:1px solid #ddd}.panel-default{border-color:#ddd}.panel-default>.panel-heading{color:#333;background-color:#f5f5f5;border-color:#ddd}.panel-default>.panel-heading+.panel-collapse>.panel-body{border-top-color:#ddd}.panel-default>.panel-heading .badge{color:#f5f5f5;background-color:#333}.panel-default>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#ddd}.panel-primary{border-color:#337ab7}.panel-primary>.panel-heading{color:#fff;background-color:#337ab7;border-color:#337ab7}.panel-primary>.panel-heading+.panel-collapse>.panel-body{border-top-color:#337ab7}.panel-primary>.panel-heading .badge{color:#337ab7;background-color:#fff}.panel-primary>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#337ab7}.panel-success{border-color:#d6e9c6}.panel-success>.panel-heading{color:#3c763d;background-color:#dff0d8;border-color:#d6e9c6}.panel-success>.panel-heading+.panel-collapse>.panel-body{border-top-color:#d6e9c6}.panel-success>.panel-heading .badge{color:#dff0d8;background-color:#3c763d}.panel-success>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#d6e9c6}.panel-info{border-color:#bce8f1}.panel-info>.panel-heading{color:#31708f;background-color:#d9edf7;border-color:#bce8f1}.panel-info>.panel-heading+.panel-collapse>.panel-body{border-top-color:#bce8f1}.panel-info>.panel-heading .badge{color:#d9edf7;background-color:#31708f}.panel-info>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#bce8f1}.panel-warning{border-color:#faebcc}.panel-warning>.panel-heading{color:#8a6d3b;background-color:#fcf8e3;border-color:#faebcc}.panel-warning>.panel-heading+.panel-collapse>.panel-body{border-top-color:#faebcc}.panel-warning>.panel-heading .badge{color:#fcf8e3;background-color:#8a6d3b}.panel-warning>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#faebcc}.panel-danger{border-color:#ebccd1}.panel-danger>.panel-heading{color:#a94442;background-color:#f2dede;border-color:#ebccd1}.panel-danger>.panel-heading+.panel-collapse>.panel-body{border-top-color:#ebccd1}.panel-danger>.panel-heading .badge{color:#f2dede;background-color:#a94442}.panel-danger>.panel-footer+.panel-collapse>.panel-body{border-bottom-color:#ebccd1}.embed-responsive{position:relative;display:block;height:0;padding:0;overflow:hidden}.embed-responsive .embed-responsive-item,.embed-responsive embed,.embed-responsive iframe,.embed-responsive object,.embed-responsive video{position:absolute;top:0;bottom:0;left:0;width:100%;height:100%;border:0}.embed-responsive-16by9{padding-bottom:56.25%}.embed-responsive-4by3{padding-bottom:75%}.well{min-height:20px;padding:19px;margin-bottom:20px;background-color:#f5f5f5;border:1px solid #e3e3e3;border-radius:4px;-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.05);box-shadow:inset 0 1px 1px rgba(0,0,0,.05)}.well blockquote{border-color:#ddd;border-color:rgba(0,0,0,.15)}.well-lg{padding:24px;border-radius:6px}.well-sm{padding:9px;border-radius:3px}.close{float:right;font-size:21px;font-weight:700;line-height:1;color:#000;text-shadow:0 1px 0 #fff;filter:alpha(opacity=20);opacity:.2}.close:focus,.close:hover{color:#000;text-decoration:none;cursor:pointer;filter:alpha(opacity=50);opacity:.5}button.close{-webkit-appearance:none;padding:0;cursor:pointer;background:0 0;border:0}.modal-open{overflow:hidden}.modal{position:fixed;top:0;right:0;bottom:0;left:0;z-index:1050;display:none;overflow:hidden;-webkit-overflow-scrolling:touch;outline:0}.modal.fade .modal-dialog{-webkit-transition:-webkit-transform .3s ease-out;-o-transition:-o-transform .3s ease-out;transition:transform .3s ease-out;-webkit-transform:translate(0,-25%);-ms-transform:translate(0,-25%);-o-transform:translate(0,-25%);transform:translate(0,-25%)}.modal.in .modal-dialog{-webkit-transform:translate(0,0);-ms-transform:translate(0,0);-o-transform:translate(0,0);transform:translate(0,0)}.modal-open .modal{overflow-x:hidden;overflow-y:auto}.modal-dialog{position:relative;width:auto;margin:10px}.modal-content{position:relative;background-color:#fff;-webkit-background-clip:padding-box;background-clip:padding-box;border:1px solid #999;border:1px solid rgba(0,0,0,.2);border-radius:6px;outline:0;-webkit-box-shadow:0 3px 9px rgba(0,0,0,.5);box-shadow:0 3px 9px rgba(0,0,0,.5)}.modal-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;z-index:1040;background-color:#000}.modal-backdrop.fade{filter:alpha(opacity=0);opacity:0}.modal-backdrop.in{filter:alpha(opacity=50);opacity:.5}.modal-header{padding:15px;border-bottom:1px solid #e5e5e5}.modal-header .close{margin-top:-2px}.modal-title{margin:0;line-height:1.42857143}.modal-body{position:relative;padding:15px}.modal-footer{padding:15px;text-align:right;border-top:1px solid #e5e5e5}.modal-footer .btn+.btn{margin-bottom:0;margin-left:5px}.modal-footer .btn-group .btn+.btn{margin-left:-1px}.modal-footer .btn-block+.btn-block{margin-left:0}.modal-scrollbar-measure{position:absolute;top:-9999px;width:50px;height:50px;overflow:scroll}@media (min-width:768px){.modal-dialog{width:600px;margin:30px auto}.modal-content{-webkit-box-shadow:0 5px 15px rgba(0,0,0,.5);box-shadow:0 5px 15px rgba(0,0,0,.5)}.modal-sm{width:300px}}@media (min-width:992px){.modal-lg{width:900px}}.tooltip{position:absolute;z-index:1070;display:block;font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:12px;font-style:normal;font-weight:400;line-height:1.42857143;text-align:left;text-align:start;text-decoration:none;text-shadow:none;text-transform:none;letter-spacing:normal;word-break:normal;word-spacing:normal;word-wrap:normal;white-space:normal;filter:alpha(opacity=0);opacity:0;line-break:auto}.tooltip.in{filter:alpha(opacity=90);opacity:.9}.tooltip.top{padding:5px 0;margin-top:-3px}.tooltip.right{padding:0 5px;margin-left:3px}.tooltip.bottom{padding:5px 0;margin-top:3px}.tooltip.left{padding:0 5px;margin-left:-3px}.tooltip-inner{max-width:200px;padding:3px 8px;color:#fff;text-align:center;background-color:#000;border-radius:4px}.tooltip-arrow{position:absolute;width:0;height:0;border-color:transparent;border-style:solid}.tooltip.top .tooltip-arrow{bottom:0;left:50%;margin-left:-5px;border-width:5px 5px 0;border-top-color:#000}.tooltip.top-left .tooltip-arrow{right:5px;bottom:0;margin-bottom:-5px;border-width:5px 5px 0;border-top-color:#000}.tooltip.top-right .tooltip-arrow{bottom:0;left:5px;margin-bottom:-5px;border-width:5px 5px 0;border-top-color:#000}.tooltip.right .tooltip-arrow{top:50%;left:0;margin-top:-5px;border-width:5px 5px 5px 0;border-right-color:#000}.tooltip.left .tooltip-arrow{top:50%;right:0;margin-top:-5px;border-width:5px 0 5px 5px;border-left-color:#000}.tooltip.bottom .tooltip-arrow{top:0;left:50%;margin-left:-5px;border-width:0 5px 5px;border-bottom-color:#000}.tooltip.bottom-left .tooltip-arrow{top:0;right:5px;margin-top:-5px;border-width:0 5px 5px;border-bottom-color:#000}.tooltip.bottom-right .tooltip-arrow{top:0;left:5px;margin-top:-5px;border-width:0 5px 5px;border-bottom-color:#000}.popover{position:absolute;top:0;left:0;z-index:1060;display:none;max-width:276px;padding:1px;font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:14px;font-style:normal;font-weight:400;line-height:1.42857143;text-align:left;text-align:start;text-decoration:none;text-shadow:none;text-transform:none;letter-spacing:normal;word-break:normal;word-spacing:normal;word-wrap:normal;white-space:normal;background-color:#fff;-webkit-background-clip:padding-box;background-clip:padding-box;border:1px solid #ccc;border:1px solid rgba(0,0,0,.2);border-radius:6px;-webkit-box-shadow:0 5px 10px rgba(0,0,0,.2);box-shadow:0 5px 10px rgba(0,0,0,.2);line-break:auto}.popover.top{margin-top:-10px}.popover.right{margin-left:10px}.popover.bottom{margin-top:10px}.popover.left{margin-left:-10px}.popover-title{padding:8px 14px;margin:0;font-size:14px;background-color:#f7f7f7;border-bottom:1px solid #ebebeb;border-radius:5px 5px 0 0}.popover-content{padding:9px 14px}.popover>.arrow,.popover>.arrow:after{position:absolute;display:block;width:0;height:0;border-color:transparent;border-style:solid}.popover>.arrow{border-width:11px}.popover>.arrow:after{content:"";border-width:10px}.popover.top>.arrow{bottom:-11px;left:50%;margin-left:-11px;border-top-color:#999;border-top-color:rgba(0,0,0,.25);border-bottom-width:0}.popover.top>.arrow:after{bottom:1px;margin-left:-10px;content:" ";border-top-color:#fff;border-bottom-width:0}.popover.right>.arrow{top:50%;left:-11px;margin-top:-11px;border-right-color:#999;border-right-color:rgba(0,0,0,.25);border-left-width:0}.popover.right>.arrow:after{bottom:-10px;left:1px;content:" ";border-right-color:#fff;border-left-width:0}.popover.bottom>.arrow{top:-11px;left:50%;margin-left:-11px;border-top-width:0;border-bottom-color:#999;border-bottom-color:rgba(0,0,0,.25)}.popover.bottom>.arrow:after{top:1px;margin-left:-10px;content:" ";border-top-width:0;border-bottom-color:#fff}.popover.left>.arrow{top:50%;right:-11px;margin-top:-11px;border-right-width:0;border-left-color:#999;border-left-color:rgba(0,0,0,.25)}.popover.left>.arrow:after{right:1px;bottom:-10px;content:" ";border-right-width:0;border-left-color:#fff}.carousel{position:relative}.carousel-inner{position:relative;width:100%;overflow:hidden}.carousel-inner>.item{position:relative;display:none;-webkit-transition:.6s ease-in-out left;-o-transition:.6s ease-in-out left;transition:.6s ease-in-out left}.carousel-inner>.item>a>img,.carousel-inner>.item>img{line-height:1}@media all and (transform-3d),(-webkit-transform-3d){.carousel-inner>.item{-webkit-transition:-webkit-transform .6s ease-in-out;-o-transition:-o-transform .6s ease-in-out;transition:transform .6s ease-in-out;-webkit-backface-visibility:hidden;backface-visibility:hidden;-webkit-perspective:1000px;perspective:1000px}.carousel-inner>.item.active.right,.carousel-inner>.item.next{left:0;-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0)}.carousel-inner>.item.active.left,.carousel-inner>.item.prev{left:0;-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0)}.carousel-inner>.item.active,.carousel-inner>.item.next.left,.carousel-inner>.item.prev.right{left:0;-webkit-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}}.carousel-inner>.active,.carousel-inner>.next,.carousel-inner>.prev{display:block}.carousel-inner>.active{left:0}.carousel-inner>.next,.carousel-inner>.prev{position:absolute;top:0;width:100%}.carousel-inner>.next{left:100%}.carousel-inner>.prev{left:-100%}.carousel-inner>.next.left,.carousel-inner>.prev.right{left:0}.carousel-inner>.active.left{left:-100%}.carousel-inner>.active.right{left:100%}.carousel-control{position:absolute;top:0;bottom:0;left:0;width:15%;font-size:20px;color:#fff;text-align:center;text-shadow:0 1px 2px rgba(0,0,0,.6);background-color:rgba(0,0,0,0);filter:alpha(opacity=50);opacity:.5}.carousel-control.left{background-image:-webkit-linear-gradient(left,rgba(0,0,0,.5) 0,rgba(0,0,0,.0001) 100%);background-image:-o-linear-gradient(left,rgba(0,0,0,.5) 0,rgba(0,0,0,.0001) 100%);background-image:-webkit-gradient(linear,left top,right top,from(rgba(0,0,0,.5)),to(rgba(0,0,0,.0001)));background-image:linear-gradient(to right,rgba(0,0,0,.5) 0,rgba(0,0,0,.0001) 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#80000000', endColorstr='#00000000', GradientType=1);background-repeat:repeat-x}.carousel-control.right{right:0;left:auto;background-image:-webkit-linear-gradient(left,rgba(0,0,0,.0001) 0,rgba(0,0,0,.5) 100%);background-image:-o-linear-gradient(left,rgba(0,0,0,.0001) 0,rgba(0,0,0,.5) 100%);background-image:-webkit-gradient(linear,left top,right top,from(rgba(0,0,0,.0001)),to(rgba(0,0,0,.5)));background-image:linear-gradient(to right,rgba(0,0,0,.0001) 0,rgba(0,0,0,.5) 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#00000000', endColorstr='#80000000', GradientType=1);background-repeat:repeat-x}.carousel-control:focus,.carousel-control:hover{color:#fff;text-decoration:none;filter:alpha(opacity=90);outline:0;opacity:.9}.carousel-control .glyphicon-chevron-left,.carousel-control .glyphicon-chevron-right,.carousel-control .icon-next,.carousel-control .icon-prev{position:absolute;top:50%;z-index:5;display:inline-block;margin-top:-10px}.carousel-control .glyphicon-chevron-left,.carousel-control .icon-prev{left:50%;margin-left:-10px}.carousel-control .glyphicon-chevron-right,.carousel-control .icon-next{right:50%;margin-right:-10px}.carousel-control .icon-next,.carousel-control .icon-prev{width:20px;height:20px;font-family:serif;line-height:1}.carousel-control .icon-prev:before{content:'\2039'}.carousel-control .icon-next:before{content:'\203a'}.carousel-indicators{position:absolute;bottom:10px;left:50%;z-index:15;width:60%;padding-left:0;margin-left:-30%;text-align:center;list-style:none}.carousel-indicators li{display:inline-block;width:10px;height:10px;margin:1px;text-indent:-999px;cursor:pointer;background-color:#000\9;background-color:rgba(0,0,0,0);border:1px solid #fff;border-radius:10px}.carousel-indicators .active{width:12px;height:12px;margin:0;background-color:#fff}.carousel-caption{position:absolute;right:15%;bottom:20px;left:15%;z-index:10;padding-top:20px;padding-bottom:20px;color:#fff;text-align:center;text-shadow:0 1px 2px rgba(0,0,0,.6)}.carousel-caption .btn{text-shadow:none}@media screen and (min-width:768px){.carousel-control .glyphicon-chevron-left,.carousel-control .glyphicon-chevron-right,.carousel-control .icon-next,.carousel-control .icon-prev{width:30px;height:30px;margin-top:-10px;font-size:30px}.carousel-control .glyphicon-chevron-left,.carousel-control .icon-prev{margin-left:-10px}.carousel-control .glyphicon-chevron-right,.carousel-control .icon-next{margin-right:-10px}.carousel-caption{right:20%;left:20%;padding-bottom:30px}.carousel-indicators{bottom:20px}}.btn-group-vertical>.btn-group:after,.btn-group-vertical>.btn-group:before,.btn-toolbar:after,.btn-toolbar:before,.clearfix:after,.clearfix:before,.container-fluid:after,.container-fluid:before,.container:after,.container:before,.dl-horizontal dd:after,.dl-horizontal dd:before,.form-horizontal .form-group:after,.form-horizontal .form-group:before,.modal-footer:after,.modal-footer:before,.modal-header:after,.modal-header:before,.nav:after,.nav:before,.navbar-collapse:after,.navbar-collapse:before,.navbar-header:after,.navbar-header:before,.navbar:after,.navbar:before,.pager:after,.pager:before,.panel-body:after,.panel-body:before,.row:after,.row:before{display:table;content:" "}.btn-group-vertical>.btn-group:after,.btn-toolbar:after,.clearfix:after,.container-fluid:after,.container:after,.dl-horizontal dd:after,.form-horizontal .form-group:after,.modal-footer:after,.modal-header:after,.nav:after,.navbar-collapse:after,.navbar-header:after,.navbar:after,.pager:after,.panel-body:after,.row:after{clear:both}.center-block{display:block;margin-right:auto;margin-left:auto}.pull-right{float:right!important}.pull-left{float:left!important}.hide{display:none!important}.show{display:block!important}.invisible{visibility:hidden}.text-hide{font:0/0 a;color:transparent;text-shadow:none;background-color:transparent;border:0}.hidden{display:none!important}.affix{position:fixed}@-ms-viewport{width:device-width}.visible-lg,.visible-md,.visible-sm,.visible-xs{display:none!important}.visible-lg-block,.visible-lg-inline,.visible-lg-inline-block,.visible-md-block,.visible-md-inline,.visible-md-inline-block,.visible-sm-block,.visible-sm-inline,.visible-sm-inline-block,.visible-xs-block,.visible-xs-inline,.visible-xs-inline-block{display:none!important}@media (max-width:767px){.visible-xs{display:block!important}table.visible-xs{display:table!important}tr.visible-xs{display:table-row!important}td.visible-xs,th.visible-xs{display:table-cell!important}}@media (max-width:767px){.visible-xs-block{display:block!important}}@media (max-width:767px){.visible-xs-inline{display:inline!important}}@media (max-width:767px){.visible-xs-inline-block{display:inline-block!important}}@media (min-width:768px) and (max-width:991px){.visible-sm{display:block!important}table.visible-sm{display:table!important}tr.visible-sm{display:table-row!important}td.visible-sm,th.visible-sm{display:table-cell!important}}@media (min-width:768px) and (max-width:991px){.visible-sm-block{display:block!important}}@media (min-width:768px) and (max-width:991px){.visible-sm-inline{display:inline!important}}@media (min-width:768px) and (max-width:991px){.visible-sm-inline-block{display:inline-block!important}}@media (min-width:992px) and (max-width:1199px){.visible-md{display:block!important}table.visible-md{display:table!important}tr.visible-md{display:table-row!important}td.visible-md,th.visible-md{display:table-cell!important}}@media (min-width:992px) and (max-width:1199px){.visible-md-block{display:block!important}}@media (min-width:992px) and (max-width:1199px){.visible-md-inline{display:inline!important}}@media (min-width:992px) and (max-width:1199px){.visible-md-inline-block{display:inline-block!important}}@media (min-width:1200px){.visible-lg{display:block!important}table.visible-lg{display:table!important}tr.visible-lg{display:table-row!important}td.visible-lg,th.visible-lg{display:table-cell!important}}@media (min-width:1200px){.visible-lg-block{display:block!important}}@media (min-width:1200px){.visible-lg-inline{display:inline!important}}@media (min-width:1200px){.visible-lg-inline-block{display:inline-block!important}}@media (max-width:767px){.hidden-xs{display:none!important}}@media (min-width:768px) and (max-width:991px){.hidden-sm{display:none!important}}@media (min-width:992px) and (max-width:1199px){.hidden-md{display:none!important}}@media (min-width:1200px){.hidden-lg{display:none!important}}.visible-print{display:none!important}@media print{.visible-print{display:block!important}table.visible-print{display:table!important}tr.visible-print{display:table-row!important}td.visible-print,th.visible-print{display:table-cell!important}}.visible-print-block{display:none!important}@media print{.visible-print-block{display:block!important}}.visible-print-inline{display:none!important}@media print{.visible-print-inline{display:inline!important}}.visible-print-inline-block{display:none!important}@media print{.visible-print-inline-block{display:inline-block!important}}@media print{.hidden-print{display:none!important}}
+/*# sourceMappingURL=bootstrap.min.css.map */
\ No newline at end of file
diff --git a/web/details.php b/web/details.php
new file mode 100644
index 0000000000000000000000000000000000000000..65cbbce9d7a09f57cd3e8b67d536c31f5466e455
--- /dev/null
+++ b/web/details.php
@@ -0,0 +1,94 @@
+<?php
+require_once("classes/SQL.php");
+include("include/_head.php");
+?>
+
+<?php
+$sql = new SQL();
+$link = $sql->getLink();
+
+if (isset($_GET["param"])){
+    $query = "SELECT * FROM (tbl_register INNER JOIN tbl_parameter ON tbl_register.id = tbl_parameter.fid_register) INNER JOIN tbl_data ON tbl_parameter.id = tbl_data.fid_parameter WHERE tbl_data.fid_parameter = ".$_GET["param"]." LIMIT 1";
+
+        $result = $link->query($query);
+        while($row = $result->fetch_assoc()) {
+            $name = $row["name"];
+            $param = $row["param"];
+            $type = $row["type"];
+        }
+        echo '
+        <!-- Page Header -->
+        <div class="row">
+            <div class="col-lg-12">
+                <h1 class="page-header">'.$name.' <small>'.$param.'</small>
+                </h1>
+            </div>
+        </div>';
+
+
+        echo '
+        <div class="row">
+            <div class="col-md-12 text-center">
+                <a href="index.php" class="btn btn-success" role="button">back</a>
+                <br><br>
+            </div>
+        </div>
+        ';
+
+        if ($type != "string"){
+            echo '
+        <div class="row">
+            <div class="col-md-12 portfolio-item">
+                <img class="img-responsive" src="graph.php?param='.$_GET["param"].'&details=yes">
+            </div>
+        </div>';
+        }
+
+        echo '
+        <div class="table-responsive">          
+          <table class="table table-striped">
+            <thead>
+              <tr>
+                <th>'.$param.'</th>
+                <th>Date</th>
+              </tr>
+            </thead>
+            <tbody>
+        ';
+        
+        
+
+        $query = "SELECT tbl_data.id as id, tbl_parameter.param as param, tbl_data.value as value, DATE_FORMAT(tbl_data.timestamp, '%d.%m.%Y %H:%i:%s') as date FROM (tbl_register INNER JOIN tbl_parameter ON tbl_register.id = tbl_parameter.fid_register) INNER JOIN tbl_data ON tbl_parameter.id = tbl_data.fid_parameter WHERE tbl_data.fid_parameter = ".$_GET["param"]." ORDER BY tbl_data.id DESC";
+
+        $result = $link->query($query);
+        while($row = $result->fetch_assoc()) {
+        echo '    
+              <tr>
+                <td>'.$row["value"].'</td>
+                <td>'.$row["date"].'</td>
+              </tr>';
+        }
+
+        echo '
+            </tbody>
+          </table>
+        </div>
+        
+
+         <div class="row">
+            <div class="col-md-12 text-center">
+                <a href="index.php" class="btn btn-success" role="button">back</a>
+                <br><br>
+            </div>
+        </div>'
+        ;
+        
+}
+?>
+        
+
+
+
+<?php
+include("include/_foot.php");
+?>
\ No newline at end of file
diff --git a/web/fonts/glyphicons-halflings-regular.eot b/web/fonts/glyphicons-halflings-regular.eot
new file mode 100755
index 0000000000000000000000000000000000000000..b93a4953fff68df523aa7656497ee339d6026d64
Binary files /dev/null and b/web/fonts/glyphicons-halflings-regular.eot differ
diff --git a/web/fonts/glyphicons-halflings-regular.svg b/web/fonts/glyphicons-halflings-regular.svg
new file mode 100755
index 0000000000000000000000000000000000000000..94fb5490a2ed10b2c69a4a567a4fd2e4f706d841
--- /dev/null
+++ b/web/fonts/glyphicons-halflings-regular.svg
@@ -0,0 +1,288 @@
+<?xml version="1.0" standalone="no"?>
+<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" >
+<svg xmlns="http://www.w3.org/2000/svg">
+<metadata></metadata>
+<defs>
+<font id="glyphicons_halflingsregular" horiz-adv-x="1200" >
+<font-face units-per-em="1200" ascent="960" descent="-240" />
+<missing-glyph horiz-adv-x="500" />
+<glyph horiz-adv-x="0" />
+<glyph horiz-adv-x="400" />
+<glyph unicode=" " />
+<glyph unicode="*" d="M600 1100q15 0 34 -1.5t30 -3.5l11 -1q10 -2 17.5 -10.5t7.5 -18.5v-224l158 158q7 7 18 8t19 -6l106 -106q7 -8 6 -19t-8 -18l-158 -158h224q10 0 18.5 -7.5t10.5 -17.5q6 -41 6 -75q0 -15 -1.5 -34t-3.5 -30l-1 -11q-2 -10 -10.5 -17.5t-18.5 -7.5h-224l158 -158 q7 -7 8 -18t-6 -19l-106 -106q-8 -7 -19 -6t-18 8l-158 158v-224q0 -10 -7.5 -18.5t-17.5 -10.5q-41 -6 -75 -6q-15 0 -34 1.5t-30 3.5l-11 1q-10 2 -17.5 10.5t-7.5 18.5v224l-158 -158q-7 -7 -18 -8t-19 6l-106 106q-7 8 -6 19t8 18l158 158h-224q-10 0 -18.5 7.5 t-10.5 17.5q-6 41 -6 75q0 15 1.5 34t3.5 30l1 11q2 10 10.5 17.5t18.5 7.5h224l-158 158q-7 7 -8 18t6 19l106 106q8 7 19 6t18 -8l158 -158v224q0 10 7.5 18.5t17.5 10.5q41 6 75 6z" />
+<glyph unicode="+" d="M450 1100h200q21 0 35.5 -14.5t14.5 -35.5v-350h350q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-350v-350q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v350h-350q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5 h350v350q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xa0;" />
+<glyph unicode="&#xa5;" d="M825 1100h250q10 0 12.5 -5t-5.5 -13l-364 -364q-6 -6 -11 -18h268q10 0 13 -6t-3 -14l-120 -160q-6 -8 -18 -14t-22 -6h-125v-100h275q10 0 13 -6t-3 -14l-120 -160q-6 -8 -18 -14t-22 -6h-125v-174q0 -11 -7.5 -18.5t-18.5 -7.5h-148q-11 0 -18.5 7.5t-7.5 18.5v174 h-275q-10 0 -13 6t3 14l120 160q6 8 18 14t22 6h125v100h-275q-10 0 -13 6t3 14l120 160q6 8 18 14t22 6h118q-5 12 -11 18l-364 364q-8 8 -5.5 13t12.5 5h250q25 0 43 -18l164 -164q8 -8 18 -8t18 8l164 164q18 18 43 18z" />
+<glyph unicode="&#x2000;" horiz-adv-x="650" />
+<glyph unicode="&#x2001;" horiz-adv-x="1300" />
+<glyph unicode="&#x2002;" horiz-adv-x="650" />
+<glyph unicode="&#x2003;" horiz-adv-x="1300" />
+<glyph unicode="&#x2004;" horiz-adv-x="433" />
+<glyph unicode="&#x2005;" horiz-adv-x="325" />
+<glyph unicode="&#x2006;" horiz-adv-x="216" />
+<glyph unicode="&#x2007;" horiz-adv-x="216" />
+<glyph unicode="&#x2008;" horiz-adv-x="162" />
+<glyph unicode="&#x2009;" horiz-adv-x="260" />
+<glyph unicode="&#x200a;" horiz-adv-x="72" />
+<glyph unicode="&#x202f;" horiz-adv-x="260" />
+<glyph unicode="&#x205f;" horiz-adv-x="325" />
+<glyph unicode="&#x20ac;" d="M744 1198q242 0 354 -189q60 -104 66 -209h-181q0 45 -17.5 82.5t-43.5 61.5t-58 40.5t-60.5 24t-51.5 7.5q-19 0 -40.5 -5.5t-49.5 -20.5t-53 -38t-49 -62.5t-39 -89.5h379l-100 -100h-300q-6 -50 -6 -100h406l-100 -100h-300q9 -74 33 -132t52.5 -91t61.5 -54.5t59 -29 t47 -7.5q22 0 50.5 7.5t60.5 24.5t58 41t43.5 61t17.5 80h174q-30 -171 -128 -278q-107 -117 -274 -117q-206 0 -324 158q-36 48 -69 133t-45 204h-217l100 100h112q1 47 6 100h-218l100 100h134q20 87 51 153.5t62 103.5q117 141 297 141z" />
+<glyph unicode="&#x20bd;" d="M428 1200h350q67 0 120 -13t86 -31t57 -49.5t35 -56.5t17 -64.5t6.5 -60.5t0.5 -57v-16.5v-16.5q0 -36 -0.5 -57t-6.5 -61t-17 -65t-35 -57t-57 -50.5t-86 -31.5t-120 -13h-178l-2 -100h288q10 0 13 -6t-3 -14l-120 -160q-6 -8 -18 -14t-22 -6h-138v-175q0 -11 -5.5 -18 t-15.5 -7h-149q-10 0 -17.5 7.5t-7.5 17.5v175h-267q-10 0 -13 6t3 14l120 160q6 8 18 14t22 6h117v100h-267q-10 0 -13 6t3 14l120 160q6 8 18 14t22 6h117v475q0 10 7.5 17.5t17.5 7.5zM600 1000v-300h203q64 0 86.5 33t22.5 119q0 84 -22.5 116t-86.5 32h-203z" />
+<glyph unicode="&#x2212;" d="M250 700h800q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-800q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#x231b;" d="M1000 1200v-150q0 -21 -14.5 -35.5t-35.5 -14.5h-50v-100q0 -91 -49.5 -165.5t-130.5 -109.5q81 -35 130.5 -109.5t49.5 -165.5v-150h50q21 0 35.5 -14.5t14.5 -35.5v-150h-800v150q0 21 14.5 35.5t35.5 14.5h50v150q0 91 49.5 165.5t130.5 109.5q-81 35 -130.5 109.5 t-49.5 165.5v100h-50q-21 0 -35.5 14.5t-14.5 35.5v150h800zM400 1000v-100q0 -60 32.5 -109.5t87.5 -73.5q28 -12 44 -37t16 -55t-16 -55t-44 -37q-55 -24 -87.5 -73.5t-32.5 -109.5v-150h400v150q0 60 -32.5 109.5t-87.5 73.5q-28 12 -44 37t-16 55t16 55t44 37 q55 24 87.5 73.5t32.5 109.5v100h-400z" />
+<glyph unicode="&#x25fc;" horiz-adv-x="500" d="M0 0z" />
+<glyph unicode="&#x2601;" d="M503 1089q110 0 200.5 -59.5t134.5 -156.5q44 14 90 14q120 0 205 -86.5t85 -206.5q0 -121 -85 -207.5t-205 -86.5h-750q-79 0 -135.5 57t-56.5 137q0 69 42.5 122.5t108.5 67.5q-2 12 -2 37q0 153 108 260.5t260 107.5z" />
+<glyph unicode="&#x26fa;" d="M774 1193.5q16 -9.5 20.5 -27t-5.5 -33.5l-136 -187l467 -746h30q20 0 35 -18.5t15 -39.5v-42h-1200v42q0 21 15 39.5t35 18.5h30l468 746l-135 183q-10 16 -5.5 34t20.5 28t34 5.5t28 -20.5l111 -148l112 150q9 16 27 20.5t34 -5zM600 200h377l-182 112l-195 534v-646z " />
+<glyph unicode="&#x2709;" d="M25 1100h1150q10 0 12.5 -5t-5.5 -13l-564 -567q-8 -8 -18 -8t-18 8l-564 567q-8 8 -5.5 13t12.5 5zM18 882l264 -264q8 -8 8 -18t-8 -18l-264 -264q-8 -8 -13 -5.5t-5 12.5v550q0 10 5 12.5t13 -5.5zM918 618l264 264q8 8 13 5.5t5 -12.5v-550q0 -10 -5 -12.5t-13 5.5 l-264 264q-8 8 -8 18t8 18zM818 482l364 -364q8 -8 5.5 -13t-12.5 -5h-1150q-10 0 -12.5 5t5.5 13l364 364q8 8 18 8t18 -8l164 -164q8 -8 18 -8t18 8l164 164q8 8 18 8t18 -8z" />
+<glyph unicode="&#x270f;" d="M1011 1210q19 0 33 -13l153 -153q13 -14 13 -33t-13 -33l-99 -92l-214 214l95 96q13 14 32 14zM1013 800l-615 -614l-214 214l614 614zM317 96l-333 -112l110 335z" />
+<glyph unicode="&#xe001;" d="M700 650v-550h250q21 0 35.5 -14.5t14.5 -35.5v-50h-800v50q0 21 14.5 35.5t35.5 14.5h250v550l-500 550h1200z" />
+<glyph unicode="&#xe002;" d="M368 1017l645 163q39 15 63 0t24 -49v-831q0 -55 -41.5 -95.5t-111.5 -63.5q-79 -25 -147 -4.5t-86 75t25.5 111.5t122.5 82q72 24 138 8v521l-600 -155v-606q0 -42 -44 -90t-109 -69q-79 -26 -147 -5.5t-86 75.5t25.5 111.5t122.5 82.5q72 24 138 7v639q0 38 14.5 59 t53.5 34z" />
+<glyph unicode="&#xe003;" d="M500 1191q100 0 191 -39t156.5 -104.5t104.5 -156.5t39 -191l-1 -2l1 -5q0 -141 -78 -262l275 -274q23 -26 22.5 -44.5t-22.5 -42.5l-59 -58q-26 -20 -46.5 -20t-39.5 20l-275 274q-119 -77 -261 -77l-5 1l-2 -1q-100 0 -191 39t-156.5 104.5t-104.5 156.5t-39 191 t39 191t104.5 156.5t156.5 104.5t191 39zM500 1022q-88 0 -162 -43t-117 -117t-43 -162t43 -162t117 -117t162 -43t162 43t117 117t43 162t-43 162t-117 117t-162 43z" />
+<glyph unicode="&#xe005;" d="M649 949q48 68 109.5 104t121.5 38.5t118.5 -20t102.5 -64t71 -100.5t27 -123q0 -57 -33.5 -117.5t-94 -124.5t-126.5 -127.5t-150 -152.5t-146 -174q-62 85 -145.5 174t-150 152.5t-126.5 127.5t-93.5 124.5t-33.5 117.5q0 64 28 123t73 100.5t104 64t119 20 t120.5 -38.5t104.5 -104z" />
+<glyph unicode="&#xe006;" d="M407 800l131 353q7 19 17.5 19t17.5 -19l129 -353h421q21 0 24 -8.5t-14 -20.5l-342 -249l130 -401q7 -20 -0.5 -25.5t-24.5 6.5l-343 246l-342 -247q-17 -12 -24.5 -6.5t-0.5 25.5l130 400l-347 251q-17 12 -14 20.5t23 8.5h429z" />
+<glyph unicode="&#xe007;" d="M407 800l131 353q7 19 17.5 19t17.5 -19l129 -353h421q21 0 24 -8.5t-14 -20.5l-342 -249l130 -401q7 -20 -0.5 -25.5t-24.5 6.5l-343 246l-342 -247q-17 -12 -24.5 -6.5t-0.5 25.5l130 400l-347 251q-17 12 -14 20.5t23 8.5h429zM477 700h-240l197 -142l-74 -226 l193 139l195 -140l-74 229l192 140h-234l-78 211z" />
+<glyph unicode="&#xe008;" d="M600 1200q124 0 212 -88t88 -212v-250q0 -46 -31 -98t-69 -52v-75q0 -10 6 -21.5t15 -17.5l358 -230q9 -5 15 -16.5t6 -21.5v-93q0 -10 -7.5 -17.5t-17.5 -7.5h-1150q-10 0 -17.5 7.5t-7.5 17.5v93q0 10 6 21.5t15 16.5l358 230q9 6 15 17.5t6 21.5v75q-38 0 -69 52 t-31 98v250q0 124 88 212t212 88z" />
+<glyph unicode="&#xe009;" d="M25 1100h1150q10 0 17.5 -7.5t7.5 -17.5v-1050q0 -10 -7.5 -17.5t-17.5 -7.5h-1150q-10 0 -17.5 7.5t-7.5 17.5v1050q0 10 7.5 17.5t17.5 7.5zM100 1000v-100h100v100h-100zM875 1000h-550q-10 0 -17.5 -7.5t-7.5 -17.5v-350q0 -10 7.5 -17.5t17.5 -7.5h550 q10 0 17.5 7.5t7.5 17.5v350q0 10 -7.5 17.5t-17.5 7.5zM1000 1000v-100h100v100h-100zM100 800v-100h100v100h-100zM1000 800v-100h100v100h-100zM100 600v-100h100v100h-100zM1000 600v-100h100v100h-100zM875 500h-550q-10 0 -17.5 -7.5t-7.5 -17.5v-350q0 -10 7.5 -17.5 t17.5 -7.5h550q10 0 17.5 7.5t7.5 17.5v350q0 10 -7.5 17.5t-17.5 7.5zM100 400v-100h100v100h-100zM1000 400v-100h100v100h-100zM100 200v-100h100v100h-100zM1000 200v-100h100v100h-100z" />
+<glyph unicode="&#xe010;" d="M50 1100h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5zM650 1100h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v400 q0 21 14.5 35.5t35.5 14.5zM50 500h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5zM650 500h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-400 q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe011;" d="M50 1100h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM450 1100h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200 q0 21 14.5 35.5t35.5 14.5zM850 1100h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM50 700h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200 q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM450 700h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM850 700h200q21 0 35.5 -14.5t14.5 -35.5v-200 q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM50 300h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM450 300h200 q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM850 300h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5 t35.5 14.5z" />
+<glyph unicode="&#xe012;" d="M50 1100h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM450 1100h700q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-700q-21 0 -35.5 14.5t-14.5 35.5v200 q0 21 14.5 35.5t35.5 14.5zM50 700h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM450 700h700q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-700 q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM50 300h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM450 300h700q21 0 35.5 -14.5t14.5 -35.5v-200 q0 -21 -14.5 -35.5t-35.5 -14.5h-700q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe013;" d="M465 477l571 571q8 8 18 8t17 -8l177 -177q8 -7 8 -17t-8 -18l-783 -784q-7 -8 -17.5 -8t-17.5 8l-384 384q-8 8 -8 18t8 17l177 177q7 8 17 8t18 -8l171 -171q7 -7 18 -7t18 7z" />
+<glyph unicode="&#xe014;" d="M904 1083l178 -179q8 -8 8 -18.5t-8 -17.5l-267 -268l267 -268q8 -7 8 -17.5t-8 -18.5l-178 -178q-8 -8 -18.5 -8t-17.5 8l-268 267l-268 -267q-7 -8 -17.5 -8t-18.5 8l-178 178q-8 8 -8 18.5t8 17.5l267 268l-267 268q-8 7 -8 17.5t8 18.5l178 178q8 8 18.5 8t17.5 -8 l268 -267l268 268q7 7 17.5 7t18.5 -7z" />
+<glyph unicode="&#xe015;" d="M507 1177q98 0 187.5 -38.5t154.5 -103.5t103.5 -154.5t38.5 -187.5q0 -141 -78 -262l300 -299q8 -8 8 -18.5t-8 -18.5l-109 -108q-7 -8 -17.5 -8t-18.5 8l-300 299q-119 -77 -261 -77q-98 0 -188 38.5t-154.5 103t-103 154.5t-38.5 188t38.5 187.5t103 154.5 t154.5 103.5t188 38.5zM506.5 1023q-89.5 0 -165.5 -44t-120 -120.5t-44 -166t44 -165.5t120 -120t165.5 -44t166 44t120.5 120t44 165.5t-44 166t-120.5 120.5t-166 44zM425 900h150q10 0 17.5 -7.5t7.5 -17.5v-75h75q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5 t-17.5 -7.5h-75v-75q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v75h-75q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5h75v75q0 10 7.5 17.5t17.5 7.5z" />
+<glyph unicode="&#xe016;" d="M507 1177q98 0 187.5 -38.5t154.5 -103.5t103.5 -154.5t38.5 -187.5q0 -141 -78 -262l300 -299q8 -8 8 -18.5t-8 -18.5l-109 -108q-7 -8 -17.5 -8t-18.5 8l-300 299q-119 -77 -261 -77q-98 0 -188 38.5t-154.5 103t-103 154.5t-38.5 188t38.5 187.5t103 154.5 t154.5 103.5t188 38.5zM506.5 1023q-89.5 0 -165.5 -44t-120 -120.5t-44 -166t44 -165.5t120 -120t165.5 -44t166 44t120.5 120t44 165.5t-44 166t-120.5 120.5t-166 44zM325 800h350q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-350q-10 0 -17.5 7.5 t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5z" />
+<glyph unicode="&#xe017;" d="M550 1200h100q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5zM800 975v166q167 -62 272 -209.5t105 -331.5q0 -117 -45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5 t-184.5 123t-123 184.5t-45.5 224q0 184 105 331.5t272 209.5v-166q-103 -55 -165 -155t-62 -220q0 -116 57 -214.5t155.5 -155.5t214.5 -57t214.5 57t155.5 155.5t57 214.5q0 120 -62 220t-165 155z" />
+<glyph unicode="&#xe018;" d="M1025 1200h150q10 0 17.5 -7.5t7.5 -17.5v-1150q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v1150q0 10 7.5 17.5t17.5 7.5zM725 800h150q10 0 17.5 -7.5t7.5 -17.5v-750q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v750 q0 10 7.5 17.5t17.5 7.5zM425 500h150q10 0 17.5 -7.5t7.5 -17.5v-450q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v450q0 10 7.5 17.5t17.5 7.5zM125 300h150q10 0 17.5 -7.5t7.5 -17.5v-250q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5 v250q0 10 7.5 17.5t17.5 7.5z" />
+<glyph unicode="&#xe019;" d="M600 1174q33 0 74 -5l38 -152l5 -1q49 -14 94 -39l5 -2l134 80q61 -48 104 -105l-80 -134l3 -5q25 -44 39 -93l1 -6l152 -38q5 -43 5 -73q0 -34 -5 -74l-152 -38l-1 -6q-15 -49 -39 -93l-3 -5l80 -134q-48 -61 -104 -105l-134 81l-5 -3q-44 -25 -94 -39l-5 -2l-38 -151 q-43 -5 -74 -5q-33 0 -74 5l-38 151l-5 2q-49 14 -94 39l-5 3l-134 -81q-60 48 -104 105l80 134l-3 5q-25 45 -38 93l-2 6l-151 38q-6 42 -6 74q0 33 6 73l151 38l2 6q13 48 38 93l3 5l-80 134q47 61 105 105l133 -80l5 2q45 25 94 39l5 1l38 152q43 5 74 5zM600 815 q-89 0 -152 -63t-63 -151.5t63 -151.5t152 -63t152 63t63 151.5t-63 151.5t-152 63z" />
+<glyph unicode="&#xe020;" d="M500 1300h300q41 0 70.5 -29.5t29.5 -70.5v-100h275q10 0 17.5 -7.5t7.5 -17.5v-75h-1100v75q0 10 7.5 17.5t17.5 7.5h275v100q0 41 29.5 70.5t70.5 29.5zM500 1200v-100h300v100h-300zM1100 900v-800q0 -41 -29.5 -70.5t-70.5 -29.5h-700q-41 0 -70.5 29.5t-29.5 70.5 v800h900zM300 800v-700h100v700h-100zM500 800v-700h100v700h-100zM700 800v-700h100v700h-100zM900 800v-700h100v700h-100z" />
+<glyph unicode="&#xe021;" d="M18 618l620 608q8 7 18.5 7t17.5 -7l608 -608q8 -8 5.5 -13t-12.5 -5h-175v-575q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v375h-300v-375q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v575h-175q-10 0 -12.5 5t5.5 13z" />
+<glyph unicode="&#xe022;" d="M600 1200v-400q0 -41 29.5 -70.5t70.5 -29.5h300v-650q0 -21 -14.5 -35.5t-35.5 -14.5h-800q-21 0 -35.5 14.5t-14.5 35.5v1100q0 21 14.5 35.5t35.5 14.5h450zM1000 800h-250q-21 0 -35.5 14.5t-14.5 35.5v250z" />
+<glyph unicode="&#xe023;" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM600 1027q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5t57 -214.5 t155.5 -155.5t214.5 -57t214.5 57t155.5 155.5t57 214.5t-57 214.5t-155.5 155.5t-214.5 57zM525 900h50q10 0 17.5 -7.5t7.5 -17.5v-275h175q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v350q0 10 7.5 17.5t17.5 7.5z" />
+<glyph unicode="&#xe024;" d="M1300 0h-538l-41 400h-242l-41 -400h-538l431 1200h209l-21 -300h162l-20 300h208zM515 800l-27 -300h224l-27 300h-170z" />
+<glyph unicode="&#xe025;" d="M550 1200h200q21 0 35.5 -14.5t14.5 -35.5v-450h191q20 0 25.5 -11.5t-7.5 -27.5l-327 -400q-13 -16 -32 -16t-32 16l-327 400q-13 16 -7.5 27.5t25.5 11.5h191v450q0 21 14.5 35.5t35.5 14.5zM1125 400h50q10 0 17.5 -7.5t7.5 -17.5v-350q0 -10 -7.5 -17.5t-17.5 -7.5 h-1050q-10 0 -17.5 7.5t-7.5 17.5v350q0 10 7.5 17.5t17.5 7.5h50q10 0 17.5 -7.5t7.5 -17.5v-175h900v175q0 10 7.5 17.5t17.5 7.5z" />
+<glyph unicode="&#xe026;" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM600 1027q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5t57 -214.5 t155.5 -155.5t214.5 -57t214.5 57t155.5 155.5t57 214.5t-57 214.5t-155.5 155.5t-214.5 57zM525 900h150q10 0 17.5 -7.5t7.5 -17.5v-275h137q21 0 26 -11.5t-8 -27.5l-223 -275q-13 -16 -32 -16t-32 16l-223 275q-13 16 -8 27.5t26 11.5h137v275q0 10 7.5 17.5t17.5 7.5z " />
+<glyph unicode="&#xe027;" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM600 1027q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5t57 -214.5 t155.5 -155.5t214.5 -57t214.5 57t155.5 155.5t57 214.5t-57 214.5t-155.5 155.5t-214.5 57zM632 914l223 -275q13 -16 8 -27.5t-26 -11.5h-137v-275q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v275h-137q-21 0 -26 11.5t8 27.5l223 275q13 16 32 16 t32 -16z" />
+<glyph unicode="&#xe028;" d="M225 1200h750q10 0 19.5 -7t12.5 -17l186 -652q7 -24 7 -49v-425q0 -12 -4 -27t-9 -17q-12 -6 -37 -6h-1100q-12 0 -27 4t-17 8q-6 13 -6 38l1 425q0 25 7 49l185 652q3 10 12.5 17t19.5 7zM878 1000h-556q-10 0 -19 -7t-11 -18l-87 -450q-2 -11 4 -18t16 -7h150 q10 0 19.5 -7t11.5 -17l38 -152q2 -10 11.5 -17t19.5 -7h250q10 0 19.5 7t11.5 17l38 152q2 10 11.5 17t19.5 7h150q10 0 16 7t4 18l-87 450q-2 11 -11 18t-19 7z" />
+<glyph unicode="&#xe029;" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM600 1027q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5t57 -214.5 t155.5 -155.5t214.5 -57t214.5 57t155.5 155.5t57 214.5t-57 214.5t-155.5 155.5t-214.5 57zM540 820l253 -190q17 -12 17 -30t-17 -30l-253 -190q-16 -12 -28 -6.5t-12 26.5v400q0 21 12 26.5t28 -6.5z" />
+<glyph unicode="&#xe030;" d="M947 1060l135 135q7 7 12.5 5t5.5 -13v-362q0 -10 -7.5 -17.5t-17.5 -7.5h-362q-11 0 -13 5.5t5 12.5l133 133q-109 76 -238 76q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5t57 -214.5t155.5 -155.5t214.5 -57t214.5 57t155.5 155.5t57 214.5h150q0 -117 -45.5 -224 t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5q192 0 347 -117z" />
+<glyph unicode="&#xe031;" d="M947 1060l135 135q7 7 12.5 5t5.5 -13v-361q0 -11 -7.5 -18.5t-18.5 -7.5h-361q-11 0 -13 5.5t5 12.5l134 134q-110 75 -239 75q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5h-150q0 117 45.5 224t123 184.5t184.5 123t224 45.5q192 0 347 -117zM1027 600h150 q0 -117 -45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5q-192 0 -348 118l-134 -134q-7 -8 -12.5 -5.5t-5.5 12.5v360q0 11 7.5 18.5t18.5 7.5h360q10 0 12.5 -5.5t-5.5 -12.5l-133 -133q110 -76 240 -76q116 0 214.5 57t155.5 155.5t57 214.5z" />
+<glyph unicode="&#xe032;" d="M125 1200h1050q10 0 17.5 -7.5t7.5 -17.5v-1150q0 -10 -7.5 -17.5t-17.5 -7.5h-1050q-10 0 -17.5 7.5t-7.5 17.5v1150q0 10 7.5 17.5t17.5 7.5zM1075 1000h-850q-10 0 -17.5 -7.5t-7.5 -17.5v-850q0 -10 7.5 -17.5t17.5 -7.5h850q10 0 17.5 7.5t7.5 17.5v850 q0 10 -7.5 17.5t-17.5 7.5zM325 900h50q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-50q-10 0 -17.5 7.5t-7.5 17.5v50q0 10 7.5 17.5t17.5 7.5zM525 900h450q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-450q-10 0 -17.5 7.5t-7.5 17.5v50 q0 10 7.5 17.5t17.5 7.5zM325 700h50q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-50q-10 0 -17.5 7.5t-7.5 17.5v50q0 10 7.5 17.5t17.5 7.5zM525 700h450q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-450q-10 0 -17.5 7.5t-7.5 17.5v50 q0 10 7.5 17.5t17.5 7.5zM325 500h50q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-50q-10 0 -17.5 7.5t-7.5 17.5v50q0 10 7.5 17.5t17.5 7.5zM525 500h450q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-450q-10 0 -17.5 7.5t-7.5 17.5v50 q0 10 7.5 17.5t17.5 7.5zM325 300h50q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-50q-10 0 -17.5 7.5t-7.5 17.5v50q0 10 7.5 17.5t17.5 7.5zM525 300h450q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-450q-10 0 -17.5 7.5t-7.5 17.5v50 q0 10 7.5 17.5t17.5 7.5z" />
+<glyph unicode="&#xe033;" d="M900 800v200q0 83 -58.5 141.5t-141.5 58.5h-300q-82 0 -141 -59t-59 -141v-200h-100q-41 0 -70.5 -29.5t-29.5 -70.5v-600q0 -41 29.5 -70.5t70.5 -29.5h900q41 0 70.5 29.5t29.5 70.5v600q0 41 -29.5 70.5t-70.5 29.5h-100zM400 800v150q0 21 15 35.5t35 14.5h200 q20 0 35 -14.5t15 -35.5v-150h-300z" />
+<glyph unicode="&#xe034;" d="M125 1100h50q10 0 17.5 -7.5t7.5 -17.5v-1075h-100v1075q0 10 7.5 17.5t17.5 7.5zM1075 1052q4 0 9 -2q16 -6 16 -23v-421q0 -6 -3 -12q-33 -59 -66.5 -99t-65.5 -58t-56.5 -24.5t-52.5 -6.5q-26 0 -57.5 6.5t-52.5 13.5t-60 21q-41 15 -63 22.5t-57.5 15t-65.5 7.5 q-85 0 -160 -57q-7 -5 -15 -5q-6 0 -11 3q-14 7 -14 22v438q22 55 82 98.5t119 46.5q23 2 43 0.5t43 -7t32.5 -8.5t38 -13t32.5 -11q41 -14 63.5 -21t57 -14t63.5 -7q103 0 183 87q7 8 18 8z" />
+<glyph unicode="&#xe035;" d="M600 1175q116 0 227 -49.5t192.5 -131t131 -192.5t49.5 -227v-300q0 -10 -7.5 -17.5t-17.5 -7.5h-50q-10 0 -17.5 7.5t-7.5 17.5v300q0 127 -70.5 231.5t-184.5 161.5t-245 57t-245 -57t-184.5 -161.5t-70.5 -231.5v-300q0 -10 -7.5 -17.5t-17.5 -7.5h-50 q-10 0 -17.5 7.5t-7.5 17.5v300q0 116 49.5 227t131 192.5t192.5 131t227 49.5zM220 500h160q8 0 14 -6t6 -14v-460q0 -8 -6 -14t-14 -6h-160q-8 0 -14 6t-6 14v460q0 8 6 14t14 6zM820 500h160q8 0 14 -6t6 -14v-460q0 -8 -6 -14t-14 -6h-160q-8 0 -14 6t-6 14v460 q0 8 6 14t14 6z" />
+<glyph unicode="&#xe036;" d="M321 814l258 172q9 6 15 2.5t6 -13.5v-750q0 -10 -6 -13.5t-15 2.5l-258 172q-21 14 -46 14h-250q-10 0 -17.5 7.5t-7.5 17.5v350q0 10 7.5 17.5t17.5 7.5h250q25 0 46 14zM900 668l120 120q7 7 17 7t17 -7l34 -34q7 -7 7 -17t-7 -17l-120 -120l120 -120q7 -7 7 -17 t-7 -17l-34 -34q-7 -7 -17 -7t-17 7l-120 119l-120 -119q-7 -7 -17 -7t-17 7l-34 34q-7 7 -7 17t7 17l119 120l-119 120q-7 7 -7 17t7 17l34 34q7 8 17 8t17 -8z" />
+<glyph unicode="&#xe037;" d="M321 814l258 172q9 6 15 2.5t6 -13.5v-750q0 -10 -6 -13.5t-15 2.5l-258 172q-21 14 -46 14h-250q-10 0 -17.5 7.5t-7.5 17.5v350q0 10 7.5 17.5t17.5 7.5h250q25 0 46 14zM766 900h4q10 -1 16 -10q96 -129 96 -290q0 -154 -90 -281q-6 -9 -17 -10l-3 -1q-9 0 -16 6 l-29 23q-7 7 -8.5 16.5t4.5 17.5q72 103 72 229q0 132 -78 238q-6 8 -4.5 18t9.5 17l29 22q7 5 15 5z" />
+<glyph unicode="&#xe038;" d="M967 1004h3q11 -1 17 -10q135 -179 135 -396q0 -105 -34 -206.5t-98 -185.5q-7 -9 -17 -10h-3q-9 0 -16 6l-42 34q-8 6 -9 16t5 18q111 150 111 328q0 90 -29.5 176t-84.5 157q-6 9 -5 19t10 16l42 33q7 5 15 5zM321 814l258 172q9 6 15 2.5t6 -13.5v-750q0 -10 -6 -13.5 t-15 2.5l-258 172q-21 14 -46 14h-250q-10 0 -17.5 7.5t-7.5 17.5v350q0 10 7.5 17.5t17.5 7.5h250q25 0 46 14zM766 900h4q10 -1 16 -10q96 -129 96 -290q0 -154 -90 -281q-6 -9 -17 -10l-3 -1q-9 0 -16 6l-29 23q-7 7 -8.5 16.5t4.5 17.5q72 103 72 229q0 132 -78 238 q-6 8 -4.5 18.5t9.5 16.5l29 22q7 5 15 5z" />
+<glyph unicode="&#xe039;" d="M500 900h100v-100h-100v-100h-400v-100h-100v600h500v-300zM1200 700h-200v-100h200v-200h-300v300h-200v300h-100v200h600v-500zM100 1100v-300h300v300h-300zM800 1100v-300h300v300h-300zM300 900h-100v100h100v-100zM1000 900h-100v100h100v-100zM300 500h200v-500 h-500v500h200v100h100v-100zM800 300h200v-100h-100v-100h-200v100h-100v100h100v200h-200v100h300v-300zM100 400v-300h300v300h-300zM300 200h-100v100h100v-100zM1200 200h-100v100h100v-100zM700 0h-100v100h100v-100zM1200 0h-300v100h300v-100z" />
+<glyph unicode="&#xe040;" d="M100 200h-100v1000h100v-1000zM300 200h-100v1000h100v-1000zM700 200h-200v1000h200v-1000zM900 200h-100v1000h100v-1000zM1200 200h-200v1000h200v-1000zM400 0h-300v100h300v-100zM600 0h-100v91h100v-91zM800 0h-100v91h100v-91zM1100 0h-200v91h200v-91z" />
+<glyph unicode="&#xe041;" d="M500 1200l682 -682q8 -8 8 -18t-8 -18l-464 -464q-8 -8 -18 -8t-18 8l-682 682l1 475q0 10 7.5 17.5t17.5 7.5h474zM319.5 1024.5q-29.5 29.5 -71 29.5t-71 -29.5t-29.5 -71.5t29.5 -71.5t71 -29.5t71 29.5t29.5 71.5t-29.5 71.5z" />
+<glyph unicode="&#xe042;" d="M500 1200l682 -682q8 -8 8 -18t-8 -18l-464 -464q-8 -8 -18 -8t-18 8l-682 682l1 475q0 10 7.5 17.5t17.5 7.5h474zM800 1200l682 -682q8 -8 8 -18t-8 -18l-464 -464q-8 -8 -18 -8t-18 8l-56 56l424 426l-700 700h150zM319.5 1024.5q-29.5 29.5 -71 29.5t-71 -29.5 t-29.5 -71.5t29.5 -71.5t71 -29.5t71 29.5t29.5 71.5t-29.5 71.5z" />
+<glyph unicode="&#xe043;" d="M300 1200h825q75 0 75 -75v-900q0 -25 -18 -43l-64 -64q-8 -8 -13 -5.5t-5 12.5v950q0 10 -7.5 17.5t-17.5 7.5h-700q-25 0 -43 -18l-64 -64q-8 -8 -5.5 -13t12.5 -5h700q10 0 17.5 -7.5t7.5 -17.5v-950q0 -10 -7.5 -17.5t-17.5 -7.5h-850q-10 0 -17.5 7.5t-7.5 17.5v975 q0 25 18 43l139 139q18 18 43 18z" />
+<glyph unicode="&#xe044;" d="M250 1200h800q21 0 35.5 -14.5t14.5 -35.5v-1150l-450 444l-450 -445v1151q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe045;" d="M822 1200h-444q-11 0 -19 -7.5t-9 -17.5l-78 -301q-7 -24 7 -45l57 -108q6 -9 17.5 -15t21.5 -6h450q10 0 21.5 6t17.5 15l62 108q14 21 7 45l-83 301q-1 10 -9 17.5t-19 7.5zM1175 800h-150q-10 0 -21 -6.5t-15 -15.5l-78 -156q-4 -9 -15 -15.5t-21 -6.5h-550 q-10 0 -21 6.5t-15 15.5l-78 156q-4 9 -15 15.5t-21 6.5h-150q-10 0 -17.5 -7.5t-7.5 -17.5v-650q0 -10 7.5 -17.5t17.5 -7.5h150q10 0 17.5 7.5t7.5 17.5v150q0 10 7.5 17.5t17.5 7.5h750q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 7.5 -17.5t17.5 -7.5h150q10 0 17.5 7.5 t7.5 17.5v650q0 10 -7.5 17.5t-17.5 7.5zM850 200h-500q-10 0 -19.5 -7t-11.5 -17l-38 -152q-2 -10 3.5 -17t15.5 -7h600q10 0 15.5 7t3.5 17l-38 152q-2 10 -11.5 17t-19.5 7z" />
+<glyph unicode="&#xe046;" d="M500 1100h200q56 0 102.5 -20.5t72.5 -50t44 -59t25 -50.5l6 -20h150q41 0 70.5 -29.5t29.5 -70.5v-600q0 -41 -29.5 -70.5t-70.5 -29.5h-1000q-41 0 -70.5 29.5t-29.5 70.5v600q0 41 29.5 70.5t70.5 29.5h150q2 8 6.5 21.5t24 48t45 61t72 48t102.5 21.5zM900 800v-100 h100v100h-100zM600 730q-95 0 -162.5 -67.5t-67.5 -162.5t67.5 -162.5t162.5 -67.5t162.5 67.5t67.5 162.5t-67.5 162.5t-162.5 67.5zM600 603q43 0 73 -30t30 -73t-30 -73t-73 -30t-73 30t-30 73t30 73t73 30z" />
+<glyph unicode="&#xe047;" d="M681 1199l385 -998q20 -50 60 -92q18 -19 36.5 -29.5t27.5 -11.5l10 -2v-66h-417v66q53 0 75 43.5t5 88.5l-82 222h-391q-58 -145 -92 -234q-11 -34 -6.5 -57t25.5 -37t46 -20t55 -6v-66h-365v66q56 24 84 52q12 12 25 30.5t20 31.5l7 13l399 1006h93zM416 521h340 l-162 457z" />
+<glyph unicode="&#xe048;" d="M753 641q5 -1 14.5 -4.5t36 -15.5t50.5 -26.5t53.5 -40t50.5 -54.5t35.5 -70t14.5 -87q0 -67 -27.5 -125.5t-71.5 -97.5t-98.5 -66.5t-108.5 -40.5t-102 -13h-500v89q41 7 70.5 32.5t29.5 65.5v827q0 24 -0.5 34t-3.5 24t-8.5 19.5t-17 13.5t-28 12.5t-42.5 11.5v71 l471 -1q57 0 115.5 -20.5t108 -57t80.5 -94t31 -124.5q0 -51 -15.5 -96.5t-38 -74.5t-45 -50.5t-38.5 -30.5zM400 700h139q78 0 130.5 48.5t52.5 122.5q0 41 -8.5 70.5t-29.5 55.5t-62.5 39.5t-103.5 13.5h-118v-350zM400 200h216q80 0 121 50.5t41 130.5q0 90 -62.5 154.5 t-156.5 64.5h-159v-400z" />
+<glyph unicode="&#xe049;" d="M877 1200l2 -57q-83 -19 -116 -45.5t-40 -66.5l-132 -839q-9 -49 13 -69t96 -26v-97h-500v97q186 16 200 98l173 832q3 17 3 30t-1.5 22.5t-9 17.5t-13.5 12.5t-21.5 10t-26 8.5t-33.5 10q-13 3 -19 5v57h425z" />
+<glyph unicode="&#xe050;" d="M1300 900h-50q0 21 -4 37t-9.5 26.5t-18 17.5t-22 11t-28.5 5.5t-31 2t-37 0.5h-200v-850q0 -22 25 -34.5t50 -13.5l25 -2v-100h-400v100q4 0 11 0.5t24 3t30 7t24 15t11 24.5v850h-200q-25 0 -37 -0.5t-31 -2t-28.5 -5.5t-22 -11t-18 -17.5t-9.5 -26.5t-4 -37h-50v300 h1000v-300zM175 1000h-75v-800h75l-125 -167l-125 167h75v800h-75l125 167z" />
+<glyph unicode="&#xe051;" d="M1100 900h-50q0 21 -4 37t-9.5 26.5t-18 17.5t-22 11t-28.5 5.5t-31 2t-37 0.5h-200v-650q0 -22 25 -34.5t50 -13.5l25 -2v-100h-400v100q4 0 11 0.5t24 3t30 7t24 15t11 24.5v650h-200q-25 0 -37 -0.5t-31 -2t-28.5 -5.5t-22 -11t-18 -17.5t-9.5 -26.5t-4 -37h-50v300 h1000v-300zM1167 50l-167 -125v75h-800v-75l-167 125l167 125v-75h800v75z" />
+<glyph unicode="&#xe052;" d="M50 1100h600q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-600q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 800h1000q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1000q-21 0 -35.5 14.5t-14.5 35.5v100 q0 21 14.5 35.5t35.5 14.5zM50 500h800q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-800q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 200h1100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1100 q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe053;" d="M250 1100h700q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-700q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 800h1100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1100q-21 0 -35.5 14.5t-14.5 35.5v100 q0 21 14.5 35.5t35.5 14.5zM250 500h700q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-700q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 200h1100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1100 q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe054;" d="M500 950v100q0 21 14.5 35.5t35.5 14.5h600q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-600q-21 0 -35.5 14.5t-14.5 35.5zM100 650v100q0 21 14.5 35.5t35.5 14.5h1000q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1000 q-21 0 -35.5 14.5t-14.5 35.5zM300 350v100q0 21 14.5 35.5t35.5 14.5h800q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-800q-21 0 -35.5 14.5t-14.5 35.5zM0 50v100q0 21 14.5 35.5t35.5 14.5h1100q21 0 35.5 -14.5t14.5 -35.5v-100 q0 -21 -14.5 -35.5t-35.5 -14.5h-1100q-21 0 -35.5 14.5t-14.5 35.5z" />
+<glyph unicode="&#xe055;" d="M50 1100h1100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1100q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 800h1100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1100q-21 0 -35.5 14.5t-14.5 35.5v100 q0 21 14.5 35.5t35.5 14.5zM50 500h1100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1100q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 200h1100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1100 q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe056;" d="M50 1100h100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM350 1100h800q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-800q-21 0 -35.5 14.5t-14.5 35.5v100 q0 21 14.5 35.5t35.5 14.5zM50 800h100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM350 800h800q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-800 q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 500h100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM350 500h800q21 0 35.5 -14.5t14.5 -35.5v-100 q0 -21 -14.5 -35.5t-35.5 -14.5h-800q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 200h100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM350 200h800 q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-800q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe057;" d="M400 0h-100v1100h100v-1100zM550 1100h100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM550 800h500q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-500 q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM267 550l-167 -125v75h-200v100h200v75zM550 500h300q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-300q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM550 200h600 q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-600q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe058;" d="M50 1100h100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM900 0h-100v1100h100v-1100zM50 800h500q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-500 q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM1100 600h200v-100h-200v-75l-167 125l167 125v-75zM50 500h300q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-300q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 200h600 q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-600q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe059;" d="M75 1000h750q31 0 53 -22t22 -53v-650q0 -31 -22 -53t-53 -22h-750q-31 0 -53 22t-22 53v650q0 31 22 53t53 22zM1200 300l-300 300l300 300v-600z" />
+<glyph unicode="&#xe060;" d="M44 1100h1112q18 0 31 -13t13 -31v-1012q0 -18 -13 -31t-31 -13h-1112q-18 0 -31 13t-13 31v1012q0 18 13 31t31 13zM100 1000v-737l247 182l298 -131l-74 156l293 318l236 -288v500h-1000zM342 884q56 0 95 -39t39 -94.5t-39 -95t-95 -39.5t-95 39.5t-39 95t39 94.5 t95 39z" />
+<glyph unicode="&#xe062;" d="M648 1169q117 0 216 -60t156.5 -161t57.5 -218q0 -115 -70 -258q-69 -109 -158 -225.5t-143 -179.5l-54 -62q-9 8 -25.5 24.5t-63.5 67.5t-91 103t-98.5 128t-95.5 148q-60 132 -60 249q0 88 34 169.5t91.5 142t137 96.5t166.5 36zM652.5 974q-91.5 0 -156.5 -65 t-65 -157t65 -156.5t156.5 -64.5t156.5 64.5t65 156.5t-65 157t-156.5 65z" />
+<glyph unicode="&#xe063;" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM600 173v854q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5t57 -214.5 t155.5 -155.5t214.5 -57z" />
+<glyph unicode="&#xe064;" d="M554 1295q21 -72 57.5 -143.5t76 -130t83 -118t82.5 -117t70 -116t49.5 -126t18.5 -136.5q0 -71 -25.5 -135t-68.5 -111t-99 -82t-118.5 -54t-125.5 -23q-84 5 -161.5 34t-139.5 78.5t-99 125t-37 164.5q0 69 18 136.5t49.5 126.5t69.5 116.5t81.5 117.5t83.5 119 t76.5 131t58.5 143zM344 710q-23 -33 -43.5 -70.5t-40.5 -102.5t-17 -123q1 -37 14.5 -69.5t30 -52t41 -37t38.5 -24.5t33 -15q21 -7 32 -1t13 22l6 34q2 10 -2.5 22t-13.5 19q-5 4 -14 12t-29.5 40.5t-32.5 73.5q-26 89 6 271q2 11 -6 11q-8 1 -15 -10z" />
+<glyph unicode="&#xe065;" d="M1000 1013l108 115q2 1 5 2t13 2t20.5 -1t25 -9.5t28.5 -21.5q22 -22 27 -43t0 -32l-6 -10l-108 -115zM350 1100h400q50 0 105 -13l-187 -187h-368q-41 0 -70.5 -29.5t-29.5 -70.5v-500q0 -41 29.5 -70.5t70.5 -29.5h500q41 0 70.5 29.5t29.5 70.5v182l200 200v-332 q0 -165 -93.5 -257.5t-256.5 -92.5h-400q-165 0 -257.5 92.5t-92.5 257.5v400q0 165 92.5 257.5t257.5 92.5zM1009 803l-362 -362l-161 -50l55 170l355 355z" />
+<glyph unicode="&#xe066;" d="M350 1100h361q-164 -146 -216 -200h-195q-41 0 -70.5 -29.5t-29.5 -70.5v-500q0 -41 29.5 -70.5t70.5 -29.5h500q41 0 70.5 29.5t29.5 70.5l200 153v-103q0 -165 -92.5 -257.5t-257.5 -92.5h-400q-165 0 -257.5 92.5t-92.5 257.5v400q0 165 92.5 257.5t257.5 92.5z M824 1073l339 -301q8 -7 8 -17.5t-8 -17.5l-340 -306q-7 -6 -12.5 -4t-6.5 11v203q-26 1 -54.5 0t-78.5 -7.5t-92 -17.5t-86 -35t-70 -57q10 59 33 108t51.5 81.5t65 58.5t68.5 40.5t67 24.5t56 13.5t40 4.5v210q1 10 6.5 12.5t13.5 -4.5z" />
+<glyph unicode="&#xe067;" d="M350 1100h350q60 0 127 -23l-178 -177h-349q-41 0 -70.5 -29.5t-29.5 -70.5v-500q0 -41 29.5 -70.5t70.5 -29.5h500q41 0 70.5 29.5t29.5 70.5v69l200 200v-219q0 -165 -92.5 -257.5t-257.5 -92.5h-400q-165 0 -257.5 92.5t-92.5 257.5v400q0 165 92.5 257.5t257.5 92.5z M643 639l395 395q7 7 17.5 7t17.5 -7l101 -101q7 -7 7 -17.5t-7 -17.5l-531 -532q-7 -7 -17.5 -7t-17.5 7l-248 248q-7 7 -7 17.5t7 17.5l101 101q7 7 17.5 7t17.5 -7l111 -111q8 -7 18 -7t18 7z" />
+<glyph unicode="&#xe068;" d="M318 918l264 264q8 8 18 8t18 -8l260 -264q7 -8 4.5 -13t-12.5 -5h-170v-200h200v173q0 10 5 12t13 -5l264 -260q8 -7 8 -17.5t-8 -17.5l-264 -265q-8 -7 -13 -5t-5 12v173h-200v-200h170q10 0 12.5 -5t-4.5 -13l-260 -264q-8 -8 -18 -8t-18 8l-264 264q-8 8 -5.5 13 t12.5 5h175v200h-200v-173q0 -10 -5 -12t-13 5l-264 265q-8 7 -8 17.5t8 17.5l264 260q8 7 13 5t5 -12v-173h200v200h-175q-10 0 -12.5 5t5.5 13z" />
+<glyph unicode="&#xe069;" d="M250 1100h100q21 0 35.5 -14.5t14.5 -35.5v-438l464 453q15 14 25.5 10t10.5 -25v-1000q0 -21 -10.5 -25t-25.5 10l-464 453v-438q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v1000q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe070;" d="M50 1100h100q21 0 35.5 -14.5t14.5 -35.5v-438l464 453q15 14 25.5 10t10.5 -25v-438l464 453q15 14 25.5 10t10.5 -25v-1000q0 -21 -10.5 -25t-25.5 10l-464 453v-438q0 -21 -10.5 -25t-25.5 10l-464 453v-438q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5 t-14.5 35.5v1000q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe071;" d="M1200 1050v-1000q0 -21 -10.5 -25t-25.5 10l-464 453v-438q0 -21 -10.5 -25t-25.5 10l-492 480q-15 14 -15 35t15 35l492 480q15 14 25.5 10t10.5 -25v-438l464 453q15 14 25.5 10t10.5 -25z" />
+<glyph unicode="&#xe072;" d="M243 1074l814 -498q18 -11 18 -26t-18 -26l-814 -498q-18 -11 -30.5 -4t-12.5 28v1000q0 21 12.5 28t30.5 -4z" />
+<glyph unicode="&#xe073;" d="M250 1000h200q21 0 35.5 -14.5t14.5 -35.5v-800q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v800q0 21 14.5 35.5t35.5 14.5zM650 1000h200q21 0 35.5 -14.5t14.5 -35.5v-800q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v800 q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe074;" d="M1100 950v-800q0 -21 -14.5 -35.5t-35.5 -14.5h-800q-21 0 -35.5 14.5t-14.5 35.5v800q0 21 14.5 35.5t35.5 14.5h800q21 0 35.5 -14.5t14.5 -35.5z" />
+<glyph unicode="&#xe075;" d="M500 612v438q0 21 10.5 25t25.5 -10l492 -480q15 -14 15 -35t-15 -35l-492 -480q-15 -14 -25.5 -10t-10.5 25v438l-464 -453q-15 -14 -25.5 -10t-10.5 25v1000q0 21 10.5 25t25.5 -10z" />
+<glyph unicode="&#xe076;" d="M1048 1102l100 1q20 0 35 -14.5t15 -35.5l5 -1000q0 -21 -14.5 -35.5t-35.5 -14.5l-100 -1q-21 0 -35.5 14.5t-14.5 35.5l-2 437l-463 -454q-14 -15 -24.5 -10.5t-10.5 25.5l-2 437l-462 -455q-15 -14 -25.5 -9.5t-10.5 24.5l-5 1000q0 21 10.5 25.5t25.5 -10.5l466 -450 l-2 438q0 20 10.5 24.5t25.5 -9.5l466 -451l-2 438q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe077;" d="M850 1100h100q21 0 35.5 -14.5t14.5 -35.5v-1000q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v438l-464 -453q-15 -14 -25.5 -10t-10.5 25v1000q0 21 10.5 25t25.5 -10l464 -453v438q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe078;" d="M686 1081l501 -540q15 -15 10.5 -26t-26.5 -11h-1042q-22 0 -26.5 11t10.5 26l501 540q15 15 36 15t36 -15zM150 400h1000q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1000q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe079;" d="M885 900l-352 -353l352 -353l-197 -198l-552 552l552 550z" />
+<glyph unicode="&#xe080;" d="M1064 547l-551 -551l-198 198l353 353l-353 353l198 198z" />
+<glyph unicode="&#xe081;" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM650 900h-100q-21 0 -35.5 -14.5t-14.5 -35.5v-150h-150 q-21 0 -35.5 -14.5t-14.5 -35.5v-100q0 -21 14.5 -35.5t35.5 -14.5h150v-150q0 -21 14.5 -35.5t35.5 -14.5h100q21 0 35.5 14.5t14.5 35.5v150h150q21 0 35.5 14.5t14.5 35.5v100q0 21 -14.5 35.5t-35.5 14.5h-150v150q0 21 -14.5 35.5t-35.5 14.5z" />
+<glyph unicode="&#xe082;" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM850 700h-500q-21 0 -35.5 -14.5t-14.5 -35.5v-100q0 -21 14.5 -35.5 t35.5 -14.5h500q21 0 35.5 14.5t14.5 35.5v100q0 21 -14.5 35.5t-35.5 14.5z" />
+<glyph unicode="&#xe083;" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM741.5 913q-12.5 0 -21.5 -9l-120 -120l-120 120q-9 9 -21.5 9 t-21.5 -9l-141 -141q-9 -9 -9 -21.5t9 -21.5l120 -120l-120 -120q-9 -9 -9 -21.5t9 -21.5l141 -141q9 -9 21.5 -9t21.5 9l120 120l120 -120q9 -9 21.5 -9t21.5 9l141 141q9 9 9 21.5t-9 21.5l-120 120l120 120q9 9 9 21.5t-9 21.5l-141 141q-9 9 -21.5 9z" />
+<glyph unicode="&#xe084;" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM546 623l-84 85q-7 7 -17.5 7t-18.5 -7l-139 -139q-7 -8 -7 -18t7 -18 l242 -241q7 -8 17.5 -8t17.5 8l375 375q7 7 7 17.5t-7 18.5l-139 139q-7 7 -17.5 7t-17.5 -7z" />
+<glyph unicode="&#xe085;" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM588 941q-29 0 -59 -5.5t-63 -20.5t-58 -38.5t-41.5 -63t-16.5 -89.5 q0 -25 20 -25h131q30 -5 35 11q6 20 20.5 28t45.5 8q20 0 31.5 -10.5t11.5 -28.5q0 -23 -7 -34t-26 -18q-1 0 -13.5 -4t-19.5 -7.5t-20 -10.5t-22 -17t-18.5 -24t-15.5 -35t-8 -46q-1 -8 5.5 -16.5t20.5 -8.5h173q7 0 22 8t35 28t37.5 48t29.5 74t12 100q0 47 -17 83 t-42.5 57t-59.5 34.5t-64 18t-59 4.5zM675 400h-150q-10 0 -17.5 -7.5t-7.5 -17.5v-150q0 -10 7.5 -17.5t17.5 -7.5h150q10 0 17.5 7.5t7.5 17.5v150q0 10 -7.5 17.5t-17.5 7.5z" />
+<glyph unicode="&#xe086;" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM675 1000h-150q-10 0 -17.5 -7.5t-7.5 -17.5v-150q0 -10 7.5 -17.5 t17.5 -7.5h150q10 0 17.5 7.5t7.5 17.5v150q0 10 -7.5 17.5t-17.5 7.5zM675 700h-250q-10 0 -17.5 -7.5t-7.5 -17.5v-50q0 -10 7.5 -17.5t17.5 -7.5h75v-200h-75q-10 0 -17.5 -7.5t-7.5 -17.5v-50q0 -10 7.5 -17.5t17.5 -7.5h350q10 0 17.5 7.5t7.5 17.5v50q0 10 -7.5 17.5 t-17.5 7.5h-75v275q0 10 -7.5 17.5t-17.5 7.5z" />
+<glyph unicode="&#xe087;" d="M525 1200h150q10 0 17.5 -7.5t7.5 -17.5v-194q103 -27 178.5 -102.5t102.5 -178.5h194q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-194q-27 -103 -102.5 -178.5t-178.5 -102.5v-194q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v194 q-103 27 -178.5 102.5t-102.5 178.5h-194q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5h194q27 103 102.5 178.5t178.5 102.5v194q0 10 7.5 17.5t17.5 7.5zM700 893v-168q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v168q-68 -23 -119 -74 t-74 -119h168q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-168q23 -68 74 -119t119 -74v168q0 10 7.5 17.5t17.5 7.5h150q10 0 17.5 -7.5t7.5 -17.5v-168q68 23 119 74t74 119h-168q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5h168 q-23 68 -74 119t-119 74z" />
+<glyph unicode="&#xe088;" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM600 1027q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5t57 -214.5 t155.5 -155.5t214.5 -57t214.5 57t155.5 155.5t57 214.5t-57 214.5t-155.5 155.5t-214.5 57zM759 823l64 -64q7 -7 7 -17.5t-7 -17.5l-124 -124l124 -124q7 -7 7 -17.5t-7 -17.5l-64 -64q-7 -7 -17.5 -7t-17.5 7l-124 124l-124 -124q-7 -7 -17.5 -7t-17.5 7l-64 64 q-7 7 -7 17.5t7 17.5l124 124l-124 124q-7 7 -7 17.5t7 17.5l64 64q7 7 17.5 7t17.5 -7l124 -124l124 124q7 7 17.5 7t17.5 -7z" />
+<glyph unicode="&#xe089;" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM600 1027q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5t57 -214.5 t155.5 -155.5t214.5 -57t214.5 57t155.5 155.5t57 214.5t-57 214.5t-155.5 155.5t-214.5 57zM782 788l106 -106q7 -7 7 -17.5t-7 -17.5l-320 -321q-8 -7 -18 -7t-18 7l-202 203q-8 7 -8 17.5t8 17.5l106 106q7 8 17.5 8t17.5 -8l79 -79l197 197q7 7 17.5 7t17.5 -7z" />
+<glyph unicode="&#xe090;" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM600 1027q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5q0 -120 65 -225 l587 587q-105 65 -225 65zM965 819l-584 -584q104 -62 219 -62q116 0 214.5 57t155.5 155.5t57 214.5q0 115 -62 219z" />
+<glyph unicode="&#xe091;" d="M39 582l522 427q16 13 27.5 8t11.5 -26v-291h550q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-550v-291q0 -21 -11.5 -26t-27.5 8l-522 427q-16 13 -16 32t16 32z" />
+<glyph unicode="&#xe092;" d="M639 1009l522 -427q16 -13 16 -32t-16 -32l-522 -427q-16 -13 -27.5 -8t-11.5 26v291h-550q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5h550v291q0 21 11.5 26t27.5 -8z" />
+<glyph unicode="&#xe093;" d="M682 1161l427 -522q13 -16 8 -27.5t-26 -11.5h-291v-550q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v550h-291q-21 0 -26 11.5t8 27.5l427 522q13 16 32 16t32 -16z" />
+<glyph unicode="&#xe094;" d="M550 1200h200q21 0 35.5 -14.5t14.5 -35.5v-550h291q21 0 26 -11.5t-8 -27.5l-427 -522q-13 -16 -32 -16t-32 16l-427 522q-13 16 -8 27.5t26 11.5h291v550q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe095;" d="M639 1109l522 -427q16 -13 16 -32t-16 -32l-522 -427q-16 -13 -27.5 -8t-11.5 26v291q-94 -2 -182 -20t-170.5 -52t-147 -92.5t-100.5 -135.5q5 105 27 193.5t67.5 167t113 135t167 91.5t225.5 42v262q0 21 11.5 26t27.5 -8z" />
+<glyph unicode="&#xe096;" d="M850 1200h300q21 0 35.5 -14.5t14.5 -35.5v-300q0 -21 -10.5 -25t-24.5 10l-94 94l-249 -249q-8 -7 -18 -7t-18 7l-106 106q-7 8 -7 18t7 18l249 249l-94 94q-14 14 -10 24.5t25 10.5zM350 0h-300q-21 0 -35.5 14.5t-14.5 35.5v300q0 21 10.5 25t24.5 -10l94 -94l249 249 q8 7 18 7t18 -7l106 -106q7 -8 7 -18t-7 -18l-249 -249l94 -94q14 -14 10 -24.5t-25 -10.5z" />
+<glyph unicode="&#xe097;" d="M1014 1120l106 -106q7 -8 7 -18t-7 -18l-249 -249l94 -94q14 -14 10 -24.5t-25 -10.5h-300q-21 0 -35.5 14.5t-14.5 35.5v300q0 21 10.5 25t24.5 -10l94 -94l249 249q8 7 18 7t18 -7zM250 600h300q21 0 35.5 -14.5t14.5 -35.5v-300q0 -21 -10.5 -25t-24.5 10l-94 94 l-249 -249q-8 -7 -18 -7t-18 7l-106 106q-7 8 -7 18t7 18l249 249l-94 94q-14 14 -10 24.5t25 10.5z" />
+<glyph unicode="&#xe101;" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM704 900h-208q-20 0 -32 -14.5t-8 -34.5l58 -302q4 -20 21.5 -34.5 t37.5 -14.5h54q20 0 37.5 14.5t21.5 34.5l58 302q4 20 -8 34.5t-32 14.5zM675 400h-150q-10 0 -17.5 -7.5t-7.5 -17.5v-150q0 -10 7.5 -17.5t17.5 -7.5h150q10 0 17.5 7.5t7.5 17.5v150q0 10 -7.5 17.5t-17.5 7.5z" />
+<glyph unicode="&#xe102;" d="M260 1200q9 0 19 -2t15 -4l5 -2q22 -10 44 -23l196 -118q21 -13 36 -24q29 -21 37 -12q11 13 49 35l196 118q22 13 45 23q17 7 38 7q23 0 47 -16.5t37 -33.5l13 -16q14 -21 18 -45l25 -123l8 -44q1 -9 8.5 -14.5t17.5 -5.5h61q10 0 17.5 -7.5t7.5 -17.5v-50 q0 -10 -7.5 -17.5t-17.5 -7.5h-50q-10 0 -17.5 -7.5t-7.5 -17.5v-175h-400v300h-200v-300h-400v175q0 10 -7.5 17.5t-17.5 7.5h-50q-10 0 -17.5 7.5t-7.5 17.5v50q0 10 7.5 17.5t17.5 7.5h61q11 0 18 3t7 8q0 4 9 52l25 128q5 25 19 45q2 3 5 7t13.5 15t21.5 19.5t26.5 15.5 t29.5 7zM915 1079l-166 -162q-7 -7 -5 -12t12 -5h219q10 0 15 7t2 17l-51 149q-3 10 -11 12t-15 -6zM463 917l-177 157q-8 7 -16 5t-11 -12l-51 -143q-3 -10 2 -17t15 -7h231q11 0 12.5 5t-5.5 12zM500 0h-375q-10 0 -17.5 7.5t-7.5 17.5v375h400v-400zM1100 400v-375 q0 -10 -7.5 -17.5t-17.5 -7.5h-375v400h400z" />
+<glyph unicode="&#xe103;" d="M1165 1190q8 3 21 -6.5t13 -17.5q-2 -178 -24.5 -323.5t-55.5 -245.5t-87 -174.5t-102.5 -118.5t-118 -68.5t-118.5 -33t-120 -4.5t-105 9.5t-90 16.5q-61 12 -78 11q-4 1 -12.5 0t-34 -14.5t-52.5 -40.5l-153 -153q-26 -24 -37 -14.5t-11 43.5q0 64 42 102q8 8 50.5 45 t66.5 58q19 17 35 47t13 61q-9 55 -10 102.5t7 111t37 130t78 129.5q39 51 80 88t89.5 63.5t94.5 45t113.5 36t129 31t157.5 37t182 47.5zM1116 1098q-8 9 -22.5 -3t-45.5 -50q-38 -47 -119 -103.5t-142 -89.5l-62 -33q-56 -30 -102 -57t-104 -68t-102.5 -80.5t-85.5 -91 t-64 -104.5q-24 -56 -31 -86t2 -32t31.5 17.5t55.5 59.5q25 30 94 75.5t125.5 77.5t147.5 81q70 37 118.5 69t102 79.5t99 111t86.5 148.5q22 50 24 60t-6 19z" />
+<glyph unicode="&#xe104;" d="M653 1231q-39 -67 -54.5 -131t-10.5 -114.5t24.5 -96.5t47.5 -80t63.5 -62.5t68.5 -46.5t65 -30q-4 7 -17.5 35t-18.5 39.5t-17 39.5t-17 43t-13 42t-9.5 44.5t-2 42t4 43t13.5 39t23 38.5q96 -42 165 -107.5t105 -138t52 -156t13 -159t-19 -149.5q-13 -55 -44 -106.5 t-68 -87t-78.5 -64.5t-72.5 -45t-53 -22q-72 -22 -127 -11q-31 6 -13 19q6 3 17 7q13 5 32.5 21t41 44t38.5 63.5t21.5 81.5t-6.5 94.5t-50 107t-104 115.5q10 -104 -0.5 -189t-37 -140.5t-65 -93t-84 -52t-93.5 -11t-95 24.5q-80 36 -131.5 114t-53.5 171q-2 23 0 49.5 t4.5 52.5t13.5 56t27.5 60t46 64.5t69.5 68.5q-8 -53 -5 -102.5t17.5 -90t34 -68.5t44.5 -39t49 -2q31 13 38.5 36t-4.5 55t-29 64.5t-36 75t-26 75.5q-15 85 2 161.5t53.5 128.5t85.5 92.5t93.5 61t81.5 25.5z" />
+<glyph unicode="&#xe105;" d="M600 1094q82 0 160.5 -22.5t140 -59t116.5 -82.5t94.5 -95t68 -95t42.5 -82.5t14 -57.5t-14 -57.5t-43 -82.5t-68.5 -95t-94.5 -95t-116.5 -82.5t-140 -59t-159.5 -22.5t-159.5 22.5t-140 59t-116.5 82.5t-94.5 95t-68.5 95t-43 82.5t-14 57.5t14 57.5t42.5 82.5t68 95 t94.5 95t116.5 82.5t140 59t160.5 22.5zM888 829q-15 15 -18 12t5 -22q25 -57 25 -119q0 -124 -88 -212t-212 -88t-212 88t-88 212q0 59 23 114q8 19 4.5 22t-17.5 -12q-70 -69 -160 -184q-13 -16 -15 -40.5t9 -42.5q22 -36 47 -71t70 -82t92.5 -81t113 -58.5t133.5 -24.5 t133.5 24t113 58.5t92.5 81.5t70 81.5t47 70.5q11 18 9 42.5t-14 41.5q-90 117 -163 189zM448 727l-35 -36q-15 -15 -19.5 -38.5t4.5 -41.5q37 -68 93 -116q16 -13 38.5 -11t36.5 17l35 34q14 15 12.5 33.5t-16.5 33.5q-44 44 -89 117q-11 18 -28 20t-32 -12z" />
+<glyph unicode="&#xe106;" d="M592 0h-148l31 120q-91 20 -175.5 68.5t-143.5 106.5t-103.5 119t-66.5 110t-22 76q0 21 14 57.5t42.5 82.5t68 95t94.5 95t116.5 82.5t140 59t160.5 22.5q61 0 126 -15l32 121h148zM944 770l47 181q108 -85 176.5 -192t68.5 -159q0 -26 -19.5 -71t-59.5 -102t-93 -112 t-129 -104.5t-158 -75.5l46 173q77 49 136 117t97 131q11 18 9 42.5t-14 41.5q-54 70 -107 130zM310 824q-70 -69 -160 -184q-13 -16 -15 -40.5t9 -42.5q18 -30 39 -60t57 -70.5t74 -73t90 -61t105 -41.5l41 154q-107 18 -178.5 101.5t-71.5 193.5q0 59 23 114q8 19 4.5 22 t-17.5 -12zM448 727l-35 -36q-15 -15 -19.5 -38.5t4.5 -41.5q37 -68 93 -116q16 -13 38.5 -11t36.5 17l12 11l22 86l-3 4q-44 44 -89 117q-11 18 -28 20t-32 -12z" />
+<glyph unicode="&#xe107;" d="M-90 100l642 1066q20 31 48 28.5t48 -35.5l642 -1056q21 -32 7.5 -67.5t-50.5 -35.5h-1294q-37 0 -50.5 34t7.5 66zM155 200h345v75q0 10 7.5 17.5t17.5 7.5h150q10 0 17.5 -7.5t7.5 -17.5v-75h345l-445 723zM496 700h208q20 0 32 -14.5t8 -34.5l-58 -252 q-4 -20 -21.5 -34.5t-37.5 -14.5h-54q-20 0 -37.5 14.5t-21.5 34.5l-58 252q-4 20 8 34.5t32 14.5z" />
+<glyph unicode="&#xe108;" d="M650 1200q62 0 106 -44t44 -106v-339l363 -325q15 -14 26 -38.5t11 -44.5v-41q0 -20 -12 -26.5t-29 5.5l-359 249v-263q100 -93 100 -113v-64q0 -21 -13 -29t-32 1l-205 128l-205 -128q-19 -9 -32 -1t-13 29v64q0 20 100 113v263l-359 -249q-17 -12 -29 -5.5t-12 26.5v41 q0 20 11 44.5t26 38.5l363 325v339q0 62 44 106t106 44z" />
+<glyph unicode="&#xe109;" d="M850 1200h100q21 0 35.5 -14.5t14.5 -35.5v-50h50q21 0 35.5 -14.5t14.5 -35.5v-150h-1100v150q0 21 14.5 35.5t35.5 14.5h50v50q0 21 14.5 35.5t35.5 14.5h100q21 0 35.5 -14.5t14.5 -35.5v-50h500v50q0 21 14.5 35.5t35.5 14.5zM1100 800v-750q0 -21 -14.5 -35.5 t-35.5 -14.5h-1000q-21 0 -35.5 14.5t-14.5 35.5v750h1100zM100 600v-100h100v100h-100zM300 600v-100h100v100h-100zM500 600v-100h100v100h-100zM700 600v-100h100v100h-100zM900 600v-100h100v100h-100zM100 400v-100h100v100h-100zM300 400v-100h100v100h-100zM500 400 v-100h100v100h-100zM700 400v-100h100v100h-100zM900 400v-100h100v100h-100zM100 200v-100h100v100h-100zM300 200v-100h100v100h-100zM500 200v-100h100v100h-100zM700 200v-100h100v100h-100zM900 200v-100h100v100h-100z" />
+<glyph unicode="&#xe110;" d="M1135 1165l249 -230q15 -14 15 -35t-15 -35l-249 -230q-14 -14 -24.5 -10t-10.5 25v150h-159l-600 -600h-291q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5h209l600 600h241v150q0 21 10.5 25t24.5 -10zM522 819l-141 -141l-122 122h-209q-21 0 -35.5 14.5 t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5h291zM1135 565l249 -230q15 -14 15 -35t-15 -35l-249 -230q-14 -14 -24.5 -10t-10.5 25v150h-241l-181 181l141 141l122 -122h159v150q0 21 10.5 25t24.5 -10z" />
+<glyph unicode="&#xe111;" d="M100 1100h1000q41 0 70.5 -29.5t29.5 -70.5v-600q0 -41 -29.5 -70.5t-70.5 -29.5h-596l-304 -300v300h-100q-41 0 -70.5 29.5t-29.5 70.5v600q0 41 29.5 70.5t70.5 29.5z" />
+<glyph unicode="&#xe112;" d="M150 1200h200q21 0 35.5 -14.5t14.5 -35.5v-250h-300v250q0 21 14.5 35.5t35.5 14.5zM850 1200h200q21 0 35.5 -14.5t14.5 -35.5v-250h-300v250q0 21 14.5 35.5t35.5 14.5zM1100 800v-300q0 -41 -3 -77.5t-15 -89.5t-32 -96t-58 -89t-89 -77t-129 -51t-174 -20t-174 20 t-129 51t-89 77t-58 89t-32 96t-15 89.5t-3 77.5v300h300v-250v-27v-42.5t1.5 -41t5 -38t10 -35t16.5 -30t25.5 -24.5t35 -19t46.5 -12t60 -4t60 4.5t46.5 12.5t35 19.5t25 25.5t17 30.5t10 35t5 38t2 40.5t-0.5 42v25v250h300z" />
+<glyph unicode="&#xe113;" d="M1100 411l-198 -199l-353 353l-353 -353l-197 199l551 551z" />
+<glyph unicode="&#xe114;" d="M1101 789l-550 -551l-551 551l198 199l353 -353l353 353z" />
+<glyph unicode="&#xe115;" d="M404 1000h746q21 0 35.5 -14.5t14.5 -35.5v-551h150q21 0 25 -10.5t-10 -24.5l-230 -249q-14 -15 -35 -15t-35 15l-230 249q-14 14 -10 24.5t25 10.5h150v401h-381zM135 984l230 -249q14 -14 10 -24.5t-25 -10.5h-150v-400h385l215 -200h-750q-21 0 -35.5 14.5 t-14.5 35.5v550h-150q-21 0 -25 10.5t10 24.5l230 249q14 15 35 15t35 -15z" />
+<glyph unicode="&#xe116;" d="M56 1200h94q17 0 31 -11t18 -27l38 -162h896q24 0 39 -18.5t10 -42.5l-100 -475q-5 -21 -27 -42.5t-55 -21.5h-633l48 -200h535q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-50v-50q0 -21 -14.5 -35.5t-35.5 -14.5t-35.5 14.5t-14.5 35.5v50h-300v-50 q0 -21 -14.5 -35.5t-35.5 -14.5t-35.5 14.5t-14.5 35.5v50h-31q-18 0 -32.5 10t-20.5 19l-5 10l-201 961h-54q-20 0 -35 14.5t-15 35.5t15 35.5t35 14.5z" />
+<glyph unicode="&#xe117;" d="M1200 1000v-100h-1200v100h200q0 41 29.5 70.5t70.5 29.5h300q41 0 70.5 -29.5t29.5 -70.5h500zM0 800h1200v-800h-1200v800z" />
+<glyph unicode="&#xe118;" d="M200 800l-200 -400v600h200q0 41 29.5 70.5t70.5 29.5h300q42 0 71 -29.5t29 -70.5h500v-200h-1000zM1500 700l-300 -700h-1200l300 700h1200z" />
+<glyph unicode="&#xe119;" d="M635 1184l230 -249q14 -14 10 -24.5t-25 -10.5h-150v-601h150q21 0 25 -10.5t-10 -24.5l-230 -249q-14 -15 -35 -15t-35 15l-230 249q-14 14 -10 24.5t25 10.5h150v601h-150q-21 0 -25 10.5t10 24.5l230 249q14 15 35 15t35 -15z" />
+<glyph unicode="&#xe120;" d="M936 864l249 -229q14 -15 14 -35.5t-14 -35.5l-249 -229q-15 -15 -25.5 -10.5t-10.5 24.5v151h-600v-151q0 -20 -10.5 -24.5t-25.5 10.5l-249 229q-14 15 -14 35.5t14 35.5l249 229q15 15 25.5 10.5t10.5 -25.5v-149h600v149q0 21 10.5 25.5t25.5 -10.5z" />
+<glyph unicode="&#xe121;" d="M1169 400l-172 732q-5 23 -23 45.5t-38 22.5h-672q-20 0 -38 -20t-23 -41l-172 -739h1138zM1100 300h-1000q-41 0 -70.5 -29.5t-29.5 -70.5v-100q0 -41 29.5 -70.5t70.5 -29.5h1000q41 0 70.5 29.5t29.5 70.5v100q0 41 -29.5 70.5t-70.5 29.5zM800 100v100h100v-100h-100 zM1000 100v100h100v-100h-100z" />
+<glyph unicode="&#xe122;" d="M1150 1100q21 0 35.5 -14.5t14.5 -35.5v-850q0 -21 -14.5 -35.5t-35.5 -14.5t-35.5 14.5t-14.5 35.5v850q0 21 14.5 35.5t35.5 14.5zM1000 200l-675 200h-38l47 -276q3 -16 -5.5 -20t-29.5 -4h-7h-84q-20 0 -34.5 14t-18.5 35q-55 337 -55 351v250v6q0 16 1 23.5t6.5 14 t17.5 6.5h200l675 250v-850zM0 750v-250q-4 0 -11 0.5t-24 6t-30 15t-24 30t-11 48.5v50q0 26 10.5 46t25 30t29 16t25.5 7z" />
+<glyph unicode="&#xe123;" d="M553 1200h94q20 0 29 -10.5t3 -29.5l-18 -37q83 -19 144 -82.5t76 -140.5l63 -327l118 -173h17q19 0 33 -14.5t14 -35t-13 -40.5t-31 -27q-8 -4 -23 -9.5t-65 -19.5t-103 -25t-132.5 -20t-158.5 -9q-57 0 -115 5t-104 12t-88.5 15.5t-73.5 17.5t-54.5 16t-35.5 12l-11 4 q-18 8 -31 28t-13 40.5t14 35t33 14.5h17l118 173l63 327q15 77 76 140t144 83l-18 32q-6 19 3.5 32t28.5 13zM498 110q50 -6 102 -6q53 0 102 6q-12 -49 -39.5 -79.5t-62.5 -30.5t-63 30.5t-39 79.5z" />
+<glyph unicode="&#xe124;" d="M800 946l224 78l-78 -224l234 -45l-180 -155l180 -155l-234 -45l78 -224l-224 78l-45 -234l-155 180l-155 -180l-45 234l-224 -78l78 224l-234 45l180 155l-180 155l234 45l-78 224l224 -78l45 234l155 -180l155 180z" />
+<glyph unicode="&#xe125;" d="M650 1200h50q40 0 70 -40.5t30 -84.5v-150l-28 -125h328q40 0 70 -40.5t30 -84.5v-100q0 -45 -29 -74l-238 -344q-16 -24 -38 -40.5t-45 -16.5h-250q-7 0 -42 25t-66 50l-31 25h-61q-45 0 -72.5 18t-27.5 57v400q0 36 20 63l145 196l96 198q13 28 37.5 48t51.5 20z M650 1100l-100 -212l-150 -213v-375h100l136 -100h214l250 375v125h-450l50 225v175h-50zM50 800h100q21 0 35.5 -14.5t14.5 -35.5v-500q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v500q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe126;" d="M600 1100h250q23 0 45 -16.5t38 -40.5l238 -344q29 -29 29 -74v-100q0 -44 -30 -84.5t-70 -40.5h-328q28 -118 28 -125v-150q0 -44 -30 -84.5t-70 -40.5h-50q-27 0 -51.5 20t-37.5 48l-96 198l-145 196q-20 27 -20 63v400q0 39 27.5 57t72.5 18h61q124 100 139 100z M50 1000h100q21 0 35.5 -14.5t14.5 -35.5v-500q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v500q0 21 14.5 35.5t35.5 14.5zM636 1000l-136 -100h-100v-375l150 -213l100 -212h50v175l-50 225h450v125l-250 375h-214z" />
+<glyph unicode="&#xe127;" d="M356 873l363 230q31 16 53 -6l110 -112q13 -13 13.5 -32t-11.5 -34l-84 -121h302q84 0 138 -38t54 -110t-55 -111t-139 -39h-106l-131 -339q-6 -21 -19.5 -41t-28.5 -20h-342q-7 0 -90 81t-83 94v525q0 17 14 35.5t28 28.5zM400 792v-503l100 -89h293l131 339 q6 21 19.5 41t28.5 20h203q21 0 30.5 25t0.5 50t-31 25h-456h-7h-6h-5.5t-6 0.5t-5 1.5t-5 2t-4 2.5t-4 4t-2.5 4.5q-12 25 5 47l146 183l-86 83zM50 800h100q21 0 35.5 -14.5t14.5 -35.5v-500q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v500 q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe128;" d="M475 1103l366 -230q2 -1 6 -3.5t14 -10.5t18 -16.5t14.5 -20t6.5 -22.5v-525q0 -13 -86 -94t-93 -81h-342q-15 0 -28.5 20t-19.5 41l-131 339h-106q-85 0 -139.5 39t-54.5 111t54 110t138 38h302l-85 121q-11 15 -10.5 34t13.5 32l110 112q22 22 53 6zM370 945l146 -183 q17 -22 5 -47q-2 -2 -3.5 -4.5t-4 -4t-4 -2.5t-5 -2t-5 -1.5t-6 -0.5h-6h-6.5h-6h-475v-100h221q15 0 29 -20t20 -41l130 -339h294l106 89v503l-342 236zM1050 800h100q21 0 35.5 -14.5t14.5 -35.5v-500q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5 v500q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe129;" d="M550 1294q72 0 111 -55t39 -139v-106l339 -131q21 -6 41 -19.5t20 -28.5v-342q0 -7 -81 -90t-94 -83h-525q-17 0 -35.5 14t-28.5 28l-9 14l-230 363q-16 31 6 53l112 110q13 13 32 13.5t34 -11.5l121 -84v302q0 84 38 138t110 54zM600 972v203q0 21 -25 30.5t-50 0.5 t-25 -31v-456v-7v-6v-5.5t-0.5 -6t-1.5 -5t-2 -5t-2.5 -4t-4 -4t-4.5 -2.5q-25 -12 -47 5l-183 146l-83 -86l236 -339h503l89 100v293l-339 131q-21 6 -41 19.5t-20 28.5zM450 200h500q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-500 q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe130;" d="M350 1100h500q21 0 35.5 14.5t14.5 35.5v100q0 21 -14.5 35.5t-35.5 14.5h-500q-21 0 -35.5 -14.5t-14.5 -35.5v-100q0 -21 14.5 -35.5t35.5 -14.5zM600 306v-106q0 -84 -39 -139t-111 -55t-110 54t-38 138v302l-121 -84q-15 -12 -34 -11.5t-32 13.5l-112 110 q-22 22 -6 53l230 363q1 2 3.5 6t10.5 13.5t16.5 17t20 13.5t22.5 6h525q13 0 94 -83t81 -90v-342q0 -15 -20 -28.5t-41 -19.5zM308 900l-236 -339l83 -86l183 146q22 17 47 5q2 -1 4.5 -2.5t4 -4t2.5 -4t2 -5t1.5 -5t0.5 -6v-5.5v-6v-7v-456q0 -22 25 -31t50 0.5t25 30.5 v203q0 15 20 28.5t41 19.5l339 131v293l-89 100h-503z" />
+<glyph unicode="&#xe131;" d="M600 1178q118 0 225 -45.5t184.5 -123t123 -184.5t45.5 -225t-45.5 -225t-123 -184.5t-184.5 -123t-225 -45.5t-225 45.5t-184.5 123t-123 184.5t-45.5 225t45.5 225t123 184.5t184.5 123t225 45.5zM914 632l-275 223q-16 13 -27.5 8t-11.5 -26v-137h-275 q-10 0 -17.5 -7.5t-7.5 -17.5v-150q0 -10 7.5 -17.5t17.5 -7.5h275v-137q0 -21 11.5 -26t27.5 8l275 223q16 13 16 32t-16 32z" />
+<glyph unicode="&#xe132;" d="M600 1178q118 0 225 -45.5t184.5 -123t123 -184.5t45.5 -225t-45.5 -225t-123 -184.5t-184.5 -123t-225 -45.5t-225 45.5t-184.5 123t-123 184.5t-45.5 225t45.5 225t123 184.5t184.5 123t225 45.5zM561 855l-275 -223q-16 -13 -16 -32t16 -32l275 -223q16 -13 27.5 -8 t11.5 26v137h275q10 0 17.5 7.5t7.5 17.5v150q0 10 -7.5 17.5t-17.5 7.5h-275v137q0 21 -11.5 26t-27.5 -8z" />
+<glyph unicode="&#xe133;" d="M600 1178q118 0 225 -45.5t184.5 -123t123 -184.5t45.5 -225t-45.5 -225t-123 -184.5t-184.5 -123t-225 -45.5t-225 45.5t-184.5 123t-123 184.5t-45.5 225t45.5 225t123 184.5t184.5 123t225 45.5zM855 639l-223 275q-13 16 -32 16t-32 -16l-223 -275q-13 -16 -8 -27.5 t26 -11.5h137v-275q0 -10 7.5 -17.5t17.5 -7.5h150q10 0 17.5 7.5t7.5 17.5v275h137q21 0 26 11.5t-8 27.5z" />
+<glyph unicode="&#xe134;" d="M600 1178q118 0 225 -45.5t184.5 -123t123 -184.5t45.5 -225t-45.5 -225t-123 -184.5t-184.5 -123t-225 -45.5t-225 45.5t-184.5 123t-123 184.5t-45.5 225t45.5 225t123 184.5t184.5 123t225 45.5zM675 900h-150q-10 0 -17.5 -7.5t-7.5 -17.5v-275h-137q-21 0 -26 -11.5 t8 -27.5l223 -275q13 -16 32 -16t32 16l223 275q13 16 8 27.5t-26 11.5h-137v275q0 10 -7.5 17.5t-17.5 7.5z" />
+<glyph unicode="&#xe135;" d="M600 1176q116 0 222.5 -46t184 -123.5t123.5 -184t46 -222.5t-46 -222.5t-123.5 -184t-184 -123.5t-222.5 -46t-222.5 46t-184 123.5t-123.5 184t-46 222.5t46 222.5t123.5 184t184 123.5t222.5 46zM627 1101q-15 -12 -36.5 -20.5t-35.5 -12t-43 -8t-39 -6.5 q-15 -3 -45.5 0t-45.5 -2q-20 -7 -51.5 -26.5t-34.5 -34.5q-3 -11 6.5 -22.5t8.5 -18.5q-3 -34 -27.5 -91t-29.5 -79q-9 -34 5 -93t8 -87q0 -9 17 -44.5t16 -59.5q12 0 23 -5t23.5 -15t19.5 -14q16 -8 33 -15t40.5 -15t34.5 -12q21 -9 52.5 -32t60 -38t57.5 -11 q7 -15 -3 -34t-22.5 -40t-9.5 -38q13 -21 23 -34.5t27.5 -27.5t36.5 -18q0 -7 -3.5 -16t-3.5 -14t5 -17q104 -2 221 112q30 29 46.5 47t34.5 49t21 63q-13 8 -37 8.5t-36 7.5q-15 7 -49.5 15t-51.5 19q-18 0 -41 -0.5t-43 -1.5t-42 -6.5t-38 -16.5q-51 -35 -66 -12 q-4 1 -3.5 25.5t0.5 25.5q-6 13 -26.5 17.5t-24.5 6.5q1 15 -0.5 30.5t-7 28t-18.5 11.5t-31 -21q-23 -25 -42 4q-19 28 -8 58q6 16 22 22q6 -1 26 -1.5t33.5 -4t19.5 -13.5q7 -12 18 -24t21.5 -20.5t20 -15t15.5 -10.5l5 -3q2 12 7.5 30.5t8 34.5t-0.5 32q-3 18 3.5 29 t18 22.5t15.5 24.5q6 14 10.5 35t8 31t15.5 22.5t34 22.5q-6 18 10 36q8 0 24 -1.5t24.5 -1.5t20 4.5t20.5 15.5q-10 23 -31 42.5t-37.5 29.5t-49 27t-43.5 23q0 1 2 8t3 11.5t1.5 10.5t-1 9.5t-4.5 4.5q31 -13 58.5 -14.5t38.5 2.5l12 5q5 28 -9.5 46t-36.5 24t-50 15 t-41 20q-18 -4 -37 0zM613 994q0 -17 8 -42t17 -45t9 -23q-8 1 -39.5 5.5t-52.5 10t-37 16.5q3 11 16 29.5t16 25.5q10 -10 19 -10t14 6t13.5 14.5t16.5 12.5z" />
+<glyph unicode="&#xe136;" d="M756 1157q164 92 306 -9l-259 -138l145 -232l251 126q6 -89 -34 -156.5t-117 -110.5q-60 -34 -127 -39.5t-126 16.5l-596 -596q-15 -16 -36.5 -16t-36.5 16l-111 110q-15 15 -15 36.5t15 37.5l600 599q-34 101 5.5 201.5t135.5 154.5z" />
+<glyph unicode="&#xe137;" horiz-adv-x="1220" d="M100 1196h1000q41 0 70.5 -29.5t29.5 -70.5v-100q0 -41 -29.5 -70.5t-70.5 -29.5h-1000q-41 0 -70.5 29.5t-29.5 70.5v100q0 41 29.5 70.5t70.5 29.5zM1100 1096h-200v-100h200v100zM100 796h1000q41 0 70.5 -29.5t29.5 -70.5v-100q0 -41 -29.5 -70.5t-70.5 -29.5h-1000 q-41 0 -70.5 29.5t-29.5 70.5v100q0 41 29.5 70.5t70.5 29.5zM1100 696h-500v-100h500v100zM100 396h1000q41 0 70.5 -29.5t29.5 -70.5v-100q0 -41 -29.5 -70.5t-70.5 -29.5h-1000q-41 0 -70.5 29.5t-29.5 70.5v100q0 41 29.5 70.5t70.5 29.5zM1100 296h-300v-100h300v100z " />
+<glyph unicode="&#xe138;" d="M150 1200h900q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-900q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5zM700 500v-300l-200 -200v500l-350 500h900z" />
+<glyph unicode="&#xe139;" d="M500 1200h200q41 0 70.5 -29.5t29.5 -70.5v-100h300q41 0 70.5 -29.5t29.5 -70.5v-400h-500v100h-200v-100h-500v400q0 41 29.5 70.5t70.5 29.5h300v100q0 41 29.5 70.5t70.5 29.5zM500 1100v-100h200v100h-200zM1200 400v-200q0 -41 -29.5 -70.5t-70.5 -29.5h-1000 q-41 0 -70.5 29.5t-29.5 70.5v200h1200z" />
+<glyph unicode="&#xe140;" d="M50 1200h300q21 0 25 -10.5t-10 -24.5l-94 -94l199 -199q7 -8 7 -18t-7 -18l-106 -106q-8 -7 -18 -7t-18 7l-199 199l-94 -94q-14 -14 -24.5 -10t-10.5 25v300q0 21 14.5 35.5t35.5 14.5zM850 1200h300q21 0 35.5 -14.5t14.5 -35.5v-300q0 -21 -10.5 -25t-24.5 10l-94 94 l-199 -199q-8 -7 -18 -7t-18 7l-106 106q-7 8 -7 18t7 18l199 199l-94 94q-14 14 -10 24.5t25 10.5zM364 470l106 -106q7 -8 7 -18t-7 -18l-199 -199l94 -94q14 -14 10 -24.5t-25 -10.5h-300q-21 0 -35.5 14.5t-14.5 35.5v300q0 21 10.5 25t24.5 -10l94 -94l199 199 q8 7 18 7t18 -7zM1071 271l94 94q14 14 24.5 10t10.5 -25v-300q0 -21 -14.5 -35.5t-35.5 -14.5h-300q-21 0 -25 10.5t10 24.5l94 94l-199 199q-7 8 -7 18t7 18l106 106q8 7 18 7t18 -7z" />
+<glyph unicode="&#xe141;" d="M596 1192q121 0 231.5 -47.5t190 -127t127 -190t47.5 -231.5t-47.5 -231.5t-127 -190.5t-190 -127t-231.5 -47t-231.5 47t-190.5 127t-127 190.5t-47 231.5t47 231.5t127 190t190.5 127t231.5 47.5zM596 1010q-112 0 -207.5 -55.5t-151 -151t-55.5 -207.5t55.5 -207.5 t151 -151t207.5 -55.5t207.5 55.5t151 151t55.5 207.5t-55.5 207.5t-151 151t-207.5 55.5zM454.5 905q22.5 0 38.5 -16t16 -38.5t-16 -39t-38.5 -16.5t-38.5 16.5t-16 39t16 38.5t38.5 16zM754.5 905q22.5 0 38.5 -16t16 -38.5t-16 -39t-38 -16.5q-14 0 -29 10l-55 -145 q17 -23 17 -51q0 -36 -25.5 -61.5t-61.5 -25.5t-61.5 25.5t-25.5 61.5q0 32 20.5 56.5t51.5 29.5l122 126l1 1q-9 14 -9 28q0 23 16 39t38.5 16zM345.5 709q22.5 0 38.5 -16t16 -38.5t-16 -38.5t-38.5 -16t-38.5 16t-16 38.5t16 38.5t38.5 16zM854.5 709q22.5 0 38.5 -16 t16 -38.5t-16 -38.5t-38.5 -16t-38.5 16t-16 38.5t16 38.5t38.5 16z" />
+<glyph unicode="&#xe142;" d="M546 173l469 470q91 91 99 192q7 98 -52 175.5t-154 94.5q-22 4 -47 4q-34 0 -66.5 -10t-56.5 -23t-55.5 -38t-48 -41.5t-48.5 -47.5q-376 -375 -391 -390q-30 -27 -45 -41.5t-37.5 -41t-32 -46.5t-16 -47.5t-1.5 -56.5q9 -62 53.5 -95t99.5 -33q74 0 125 51l548 548 q36 36 20 75q-7 16 -21.5 26t-32.5 10q-26 0 -50 -23q-13 -12 -39 -38l-341 -338q-15 -15 -35.5 -15.5t-34.5 13.5t-14 34.5t14 34.5q327 333 361 367q35 35 67.5 51.5t78.5 16.5q14 0 29 -1q44 -8 74.5 -35.5t43.5 -68.5q14 -47 2 -96.5t-47 -84.5q-12 -11 -32 -32 t-79.5 -81t-114.5 -115t-124.5 -123.5t-123 -119.5t-96.5 -89t-57 -45q-56 -27 -120 -27q-70 0 -129 32t-93 89q-48 78 -35 173t81 163l511 511q71 72 111 96q91 55 198 55q80 0 152 -33q78 -36 129.5 -103t66.5 -154q17 -93 -11 -183.5t-94 -156.5l-482 -476 q-15 -15 -36 -16t-37 14t-17.5 34t14.5 35z" />
+<glyph unicode="&#xe143;" d="M649 949q48 68 109.5 104t121.5 38.5t118.5 -20t102.5 -64t71 -100.5t27 -123q0 -57 -33.5 -117.5t-94 -124.5t-126.5 -127.5t-150 -152.5t-146 -174q-62 85 -145.5 174t-150 152.5t-126.5 127.5t-93.5 124.5t-33.5 117.5q0 64 28 123t73 100.5t104 64t119 20 t120.5 -38.5t104.5 -104zM896 972q-33 0 -64.5 -19t-56.5 -46t-47.5 -53.5t-43.5 -45.5t-37.5 -19t-36 19t-40 45.5t-43 53.5t-54 46t-65.5 19q-67 0 -122.5 -55.5t-55.5 -132.5q0 -23 13.5 -51t46 -65t57.5 -63t76 -75l22 -22q15 -14 44 -44t50.5 -51t46 -44t41 -35t23 -12 t23.5 12t42.5 36t46 44t52.5 52t44 43q4 4 12 13q43 41 63.5 62t52 55t46 55t26 46t11.5 44q0 79 -53 133.5t-120 54.5z" />
+<glyph unicode="&#xe144;" d="M776.5 1214q93.5 0 159.5 -66l141 -141q66 -66 66 -160q0 -42 -28 -95.5t-62 -87.5l-29 -29q-31 53 -77 99l-18 18l95 95l-247 248l-389 -389l212 -212l-105 -106l-19 18l-141 141q-66 66 -66 159t66 159l283 283q65 66 158.5 66zM600 706l105 105q10 -8 19 -17l141 -141 q66 -66 66 -159t-66 -159l-283 -283q-66 -66 -159 -66t-159 66l-141 141q-66 66 -66 159.5t66 159.5l55 55q29 -55 75 -102l18 -17l-95 -95l247 -248l389 389z" />
+<glyph unicode="&#xe145;" d="M603 1200q85 0 162 -15t127 -38t79 -48t29 -46v-953q0 -41 -29.5 -70.5t-70.5 -29.5h-600q-41 0 -70.5 29.5t-29.5 70.5v953q0 21 30 46.5t81 48t129 37.5t163 15zM300 1000v-700h600v700h-600zM600 254q-43 0 -73.5 -30.5t-30.5 -73.5t30.5 -73.5t73.5 -30.5t73.5 30.5 t30.5 73.5t-30.5 73.5t-73.5 30.5z" />
+<glyph unicode="&#xe146;" d="M902 1185l283 -282q15 -15 15 -36t-14.5 -35.5t-35.5 -14.5t-35 15l-36 35l-279 -267v-300l-212 210l-308 -307l-280 -203l203 280l307 308l-210 212h300l267 279l-35 36q-15 14 -15 35t14.5 35.5t35.5 14.5t35 -15z" />
+<glyph unicode="&#xe148;" d="M700 1248v-78q38 -5 72.5 -14.5t75.5 -31.5t71 -53.5t52 -84t24 -118.5h-159q-4 36 -10.5 59t-21 45t-40 35.5t-64.5 20.5v-307l64 -13q34 -7 64 -16.5t70 -32t67.5 -52.5t47.5 -80t20 -112q0 -139 -89 -224t-244 -97v-77h-100v79q-150 16 -237 103q-40 40 -52.5 93.5 t-15.5 139.5h139q5 -77 48.5 -126t117.5 -65v335l-27 8q-46 14 -79 26.5t-72 36t-63 52t-40 72.5t-16 98q0 70 25 126t67.5 92t94.5 57t110 27v77h100zM600 754v274q-29 -4 -50 -11t-42 -21.5t-31.5 -41.5t-10.5 -65q0 -29 7 -50.5t16.5 -34t28.5 -22.5t31.5 -14t37.5 -10 q9 -3 13 -4zM700 547v-310q22 2 42.5 6.5t45 15.5t41.5 27t29 42t12 59.5t-12.5 59.5t-38 44.5t-53 31t-66.5 24.5z" />
+<glyph unicode="&#xe149;" d="M561 1197q84 0 160.5 -40t123.5 -109.5t47 -147.5h-153q0 40 -19.5 71.5t-49.5 48.5t-59.5 26t-55.5 9q-37 0 -79 -14.5t-62 -35.5q-41 -44 -41 -101q0 -26 13.5 -63t26.5 -61t37 -66q6 -9 9 -14h241v-100h-197q8 -50 -2.5 -115t-31.5 -95q-45 -62 -99 -112 q34 10 83 17.5t71 7.5q32 1 102 -16t104 -17q83 0 136 30l50 -147q-31 -19 -58 -30.5t-55 -15.5t-42 -4.5t-46 -0.5q-23 0 -76 17t-111 32.5t-96 11.5q-39 -3 -82 -16t-67 -25l-23 -11l-55 145q4 3 16 11t15.5 10.5t13 9t15.5 12t14.5 14t17.5 18.5q48 55 54 126.5 t-30 142.5h-221v100h166q-23 47 -44 104q-7 20 -12 41.5t-6 55.5t6 66.5t29.5 70.5t58.5 71q97 88 263 88z" />
+<glyph unicode="&#xe150;" d="M400 300h150q21 0 25 -11t-10 -25l-230 -250q-14 -15 -35 -15t-35 15l-230 250q-14 14 -10 25t25 11h150v900h200v-900zM935 1184l230 -249q14 -14 10 -24.5t-25 -10.5h-150v-900h-200v900h-150q-21 0 -25 10.5t10 24.5l230 249q14 15 35 15t35 -15z" />
+<glyph unicode="&#xe151;" d="M1000 700h-100v100h-100v-100h-100v500h300v-500zM400 300h150q21 0 25 -11t-10 -25l-230 -250q-14 -15 -35 -15t-35 15l-230 250q-14 14 -10 25t25 11h150v900h200v-900zM801 1100v-200h100v200h-100zM1000 350l-200 -250h200v-100h-300v150l200 250h-200v100h300v-150z " />
+<glyph unicode="&#xe152;" d="M400 300h150q21 0 25 -11t-10 -25l-230 -250q-14 -15 -35 -15t-35 15l-230 250q-14 14 -10 25t25 11h150v900h200v-900zM1000 1050l-200 -250h200v-100h-300v150l200 250h-200v100h300v-150zM1000 0h-100v100h-100v-100h-100v500h300v-500zM801 400v-200h100v200h-100z " />
+<glyph unicode="&#xe153;" d="M400 300h150q21 0 25 -11t-10 -25l-230 -250q-14 -15 -35 -15t-35 15l-230 250q-14 14 -10 25t25 11h150v900h200v-900zM1000 700h-100v400h-100v100h200v-500zM1100 0h-100v100h-200v400h300v-500zM901 400v-200h100v200h-100z" />
+<glyph unicode="&#xe154;" d="M400 300h150q21 0 25 -11t-10 -25l-230 -250q-14 -15 -35 -15t-35 15l-230 250q-14 14 -10 25t25 11h150v900h200v-900zM1100 700h-100v100h-200v400h300v-500zM901 1100v-200h100v200h-100zM1000 0h-100v400h-100v100h200v-500z" />
+<glyph unicode="&#xe155;" d="M400 300h150q21 0 25 -11t-10 -25l-230 -250q-14 -15 -35 -15t-35 15l-230 250q-14 14 -10 25t25 11h150v900h200v-900zM900 1000h-200v200h200v-200zM1000 700h-300v200h300v-200zM1100 400h-400v200h400v-200zM1200 100h-500v200h500v-200z" />
+<glyph unicode="&#xe156;" d="M400 300h150q21 0 25 -11t-10 -25l-230 -250q-14 -15 -35 -15t-35 15l-230 250q-14 14 -10 25t25 11h150v900h200v-900zM1200 1000h-500v200h500v-200zM1100 700h-400v200h400v-200zM1000 400h-300v200h300v-200zM900 100h-200v200h200v-200z" />
+<glyph unicode="&#xe157;" d="M350 1100h400q162 0 256 -93.5t94 -256.5v-400q0 -165 -93.5 -257.5t-256.5 -92.5h-400q-165 0 -257.5 92.5t-92.5 257.5v400q0 165 92.5 257.5t257.5 92.5zM800 900h-500q-41 0 -70.5 -29.5t-29.5 -70.5v-500q0 -41 29.5 -70.5t70.5 -29.5h500q41 0 70.5 29.5t29.5 70.5 v500q0 41 -29.5 70.5t-70.5 29.5z" />
+<glyph unicode="&#xe158;" d="M350 1100h400q165 0 257.5 -92.5t92.5 -257.5v-400q0 -165 -92.5 -257.5t-257.5 -92.5h-400q-163 0 -256.5 92.5t-93.5 257.5v400q0 163 94 256.5t256 93.5zM800 900h-500q-41 0 -70.5 -29.5t-29.5 -70.5v-500q0 -41 29.5 -70.5t70.5 -29.5h500q41 0 70.5 29.5t29.5 70.5 v500q0 41 -29.5 70.5t-70.5 29.5zM440 770l253 -190q17 -12 17 -30t-17 -30l-253 -190q-16 -12 -28 -6.5t-12 26.5v400q0 21 12 26.5t28 -6.5z" />
+<glyph unicode="&#xe159;" d="M350 1100h400q163 0 256.5 -94t93.5 -256v-400q0 -165 -92.5 -257.5t-257.5 -92.5h-400q-165 0 -257.5 92.5t-92.5 257.5v400q0 163 92.5 256.5t257.5 93.5zM800 900h-500q-41 0 -70.5 -29.5t-29.5 -70.5v-500q0 -41 29.5 -70.5t70.5 -29.5h500q41 0 70.5 29.5t29.5 70.5 v500q0 41 -29.5 70.5t-70.5 29.5zM350 700h400q21 0 26.5 -12t-6.5 -28l-190 -253q-12 -17 -30 -17t-30 17l-190 253q-12 16 -6.5 28t26.5 12z" />
+<glyph unicode="&#xe160;" d="M350 1100h400q165 0 257.5 -92.5t92.5 -257.5v-400q0 -163 -92.5 -256.5t-257.5 -93.5h-400q-163 0 -256.5 94t-93.5 256v400q0 165 92.5 257.5t257.5 92.5zM800 900h-500q-41 0 -70.5 -29.5t-29.5 -70.5v-500q0 -41 29.5 -70.5t70.5 -29.5h500q41 0 70.5 29.5t29.5 70.5 v500q0 41 -29.5 70.5t-70.5 29.5zM580 693l190 -253q12 -16 6.5 -28t-26.5 -12h-400q-21 0 -26.5 12t6.5 28l190 253q12 17 30 17t30 -17z" />
+<glyph unicode="&#xe161;" d="M550 1100h400q165 0 257.5 -92.5t92.5 -257.5v-400q0 -165 -92.5 -257.5t-257.5 -92.5h-400q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5h450q41 0 70.5 29.5t29.5 70.5v500q0 41 -29.5 70.5t-70.5 29.5h-450q-21 0 -35.5 14.5t-14.5 35.5v100 q0 21 14.5 35.5t35.5 14.5zM338 867l324 -284q16 -14 16 -33t-16 -33l-324 -284q-16 -14 -27 -9t-11 26v150h-250q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5h250v150q0 21 11 26t27 -9z" />
+<glyph unicode="&#xe162;" d="M793 1182l9 -9q8 -10 5 -27q-3 -11 -79 -225.5t-78 -221.5l300 1q24 0 32.5 -17.5t-5.5 -35.5q-1 0 -133.5 -155t-267 -312.5t-138.5 -162.5q-12 -15 -26 -15h-9l-9 8q-9 11 -4 32q2 9 42 123.5t79 224.5l39 110h-302q-23 0 -31 19q-10 21 6 41q75 86 209.5 237.5 t228 257t98.5 111.5q9 16 25 16h9z" />
+<glyph unicode="&#xe163;" d="M350 1100h400q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-450q-41 0 -70.5 -29.5t-29.5 -70.5v-500q0 -41 29.5 -70.5t70.5 -29.5h450q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-165 0 -257.5 92.5t-92.5 257.5v400 q0 165 92.5 257.5t257.5 92.5zM938 867l324 -284q16 -14 16 -33t-16 -33l-324 -284q-16 -14 -27 -9t-11 26v150h-250q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5h250v150q0 21 11 26t27 -9z" />
+<glyph unicode="&#xe164;" d="M750 1200h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -10.5 -25t-24.5 10l-109 109l-312 -312q-15 -15 -35.5 -15t-35.5 15l-141 141q-15 15 -15 35.5t15 35.5l312 312l-109 109q-14 14 -10 24.5t25 10.5zM456 900h-156q-41 0 -70.5 -29.5t-29.5 -70.5v-500 q0 -41 29.5 -70.5t70.5 -29.5h500q41 0 70.5 29.5t29.5 70.5v148l200 200v-298q0 -165 -93.5 -257.5t-256.5 -92.5h-400q-165 0 -257.5 92.5t-92.5 257.5v400q0 165 92.5 257.5t257.5 92.5h300z" />
+<glyph unicode="&#xe165;" d="M600 1186q119 0 227.5 -46.5t187 -125t125 -187t46.5 -227.5t-46.5 -227.5t-125 -187t-187 -125t-227.5 -46.5t-227.5 46.5t-187 125t-125 187t-46.5 227.5t46.5 227.5t125 187t187 125t227.5 46.5zM600 1022q-115 0 -212 -56.5t-153.5 -153.5t-56.5 -212t56.5 -212 t153.5 -153.5t212 -56.5t212 56.5t153.5 153.5t56.5 212t-56.5 212t-153.5 153.5t-212 56.5zM600 794q80 0 137 -57t57 -137t-57 -137t-137 -57t-137 57t-57 137t57 137t137 57z" />
+<glyph unicode="&#xe166;" d="M450 1200h200q21 0 35.5 -14.5t14.5 -35.5v-350h245q20 0 25 -11t-9 -26l-383 -426q-14 -15 -33.5 -15t-32.5 15l-379 426q-13 15 -8.5 26t25.5 11h250v350q0 21 14.5 35.5t35.5 14.5zM50 300h1000q21 0 35.5 -14.5t14.5 -35.5v-250h-1100v250q0 21 14.5 35.5t35.5 14.5z M900 200v-50h100v50h-100z" />
+<glyph unicode="&#xe167;" d="M583 1182l378 -435q14 -15 9 -31t-26 -16h-244v-250q0 -20 -17 -35t-39 -15h-200q-20 0 -32 14.5t-12 35.5v250h-250q-20 0 -25.5 16.5t8.5 31.5l383 431q14 16 33.5 17t33.5 -14zM50 300h1000q21 0 35.5 -14.5t14.5 -35.5v-250h-1100v250q0 21 14.5 35.5t35.5 14.5z M900 200v-50h100v50h-100z" />
+<glyph unicode="&#xe168;" d="M396 723l369 369q7 7 17.5 7t17.5 -7l139 -139q7 -8 7 -18.5t-7 -17.5l-525 -525q-7 -8 -17.5 -8t-17.5 8l-292 291q-7 8 -7 18t7 18l139 139q8 7 18.5 7t17.5 -7zM50 300h1000q21 0 35.5 -14.5t14.5 -35.5v-250h-1100v250q0 21 14.5 35.5t35.5 14.5zM900 200v-50h100v50 h-100z" />
+<glyph unicode="&#xe169;" d="M135 1023l142 142q14 14 35 14t35 -14l77 -77l-212 -212l-77 76q-14 15 -14 36t14 35zM655 855l210 210q14 14 24.5 10t10.5 -25l-2 -599q-1 -20 -15.5 -35t-35.5 -15l-597 -1q-21 0 -25 10.5t10 24.5l208 208l-154 155l212 212zM50 300h1000q21 0 35.5 -14.5t14.5 -35.5 v-250h-1100v250q0 21 14.5 35.5t35.5 14.5zM900 200v-50h100v50h-100z" />
+<glyph unicode="&#xe170;" d="M350 1200l599 -2q20 -1 35 -15.5t15 -35.5l1 -597q0 -21 -10.5 -25t-24.5 10l-208 208l-155 -154l-212 212l155 154l-210 210q-14 14 -10 24.5t25 10.5zM524 512l-76 -77q-15 -14 -36 -14t-35 14l-142 142q-14 14 -14 35t14 35l77 77zM50 300h1000q21 0 35.5 -14.5 t14.5 -35.5v-250h-1100v250q0 21 14.5 35.5t35.5 14.5zM900 200v-50h100v50h-100z" />
+<glyph unicode="&#xe171;" d="M1200 103l-483 276l-314 -399v423h-399l1196 796v-1096zM483 424v-230l683 953z" />
+<glyph unicode="&#xe172;" d="M1100 1000v-850q0 -21 -14.5 -35.5t-35.5 -14.5h-150v400h-700v-400h-150q-21 0 -35.5 14.5t-14.5 35.5v1000q0 20 14.5 35t35.5 15h250v-300h500v300h100zM700 1000h-100v200h100v-200z" />
+<glyph unicode="&#xe173;" d="M1100 1000l-2 -149l-299 -299l-95 95q-9 9 -21.5 9t-21.5 -9l-149 -147h-312v-400h-150q-21 0 -35.5 14.5t-14.5 35.5v1000q0 20 14.5 35t35.5 15h250v-300h500v300h100zM700 1000h-100v200h100v-200zM1132 638l106 -106q7 -7 7 -17.5t-7 -17.5l-420 -421q-8 -7 -18 -7 t-18 7l-202 203q-8 7 -8 17.5t8 17.5l106 106q7 8 17.5 8t17.5 -8l79 -79l297 297q7 7 17.5 7t17.5 -7z" />
+<glyph unicode="&#xe174;" d="M1100 1000v-269l-103 -103l-134 134q-15 15 -33.5 16.5t-34.5 -12.5l-266 -266h-329v-400h-150q-21 0 -35.5 14.5t-14.5 35.5v1000q0 20 14.5 35t35.5 15h250v-300h500v300h100zM700 1000h-100v200h100v-200zM1202 572l70 -70q15 -15 15 -35.5t-15 -35.5l-131 -131 l131 -131q15 -15 15 -35.5t-15 -35.5l-70 -70q-15 -15 -35.5 -15t-35.5 15l-131 131l-131 -131q-15 -15 -35.5 -15t-35.5 15l-70 70q-15 15 -15 35.5t15 35.5l131 131l-131 131q-15 15 -15 35.5t15 35.5l70 70q15 15 35.5 15t35.5 -15l131 -131l131 131q15 15 35.5 15 t35.5 -15z" />
+<glyph unicode="&#xe175;" d="M1100 1000v-300h-350q-21 0 -35.5 -14.5t-14.5 -35.5v-150h-500v-400h-150q-21 0 -35.5 14.5t-14.5 35.5v1000q0 20 14.5 35t35.5 15h250v-300h500v300h100zM700 1000h-100v200h100v-200zM850 600h100q21 0 35.5 -14.5t14.5 -35.5v-250h150q21 0 25 -10.5t-10 -24.5 l-230 -230q-14 -14 -35 -14t-35 14l-230 230q-14 14 -10 24.5t25 10.5h150v250q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe176;" d="M1100 1000v-400l-165 165q-14 15 -35 15t-35 -15l-263 -265h-402v-400h-150q-21 0 -35.5 14.5t-14.5 35.5v1000q0 20 14.5 35t35.5 15h250v-300h500v300h100zM700 1000h-100v200h100v-200zM935 565l230 -229q14 -15 10 -25.5t-25 -10.5h-150v-250q0 -20 -14.5 -35 t-35.5 -15h-100q-21 0 -35.5 15t-14.5 35v250h-150q-21 0 -25 10.5t10 25.5l230 229q14 15 35 15t35 -15z" />
+<glyph unicode="&#xe177;" d="M50 1100h1100q21 0 35.5 -14.5t14.5 -35.5v-150h-1200v150q0 21 14.5 35.5t35.5 14.5zM1200 800v-550q0 -21 -14.5 -35.5t-35.5 -14.5h-1100q-21 0 -35.5 14.5t-14.5 35.5v550h1200zM100 500v-200h400v200h-400z" />
+<glyph unicode="&#xe178;" d="M935 1165l248 -230q14 -14 14 -35t-14 -35l-248 -230q-14 -14 -24.5 -10t-10.5 25v150h-400v200h400v150q0 21 10.5 25t24.5 -10zM200 800h-50q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5h50v-200zM400 800h-100v200h100v-200zM18 435l247 230 q14 14 24.5 10t10.5 -25v-150h400v-200h-400v-150q0 -21 -10.5 -25t-24.5 10l-247 230q-15 14 -15 35t15 35zM900 300h-100v200h100v-200zM1000 500h51q20 0 34.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-34.5 -14.5h-51v200z" />
+<glyph unicode="&#xe179;" d="M862 1073l276 116q25 18 43.5 8t18.5 -41v-1106q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v397q-4 1 -11 5t-24 17.5t-30 29t-24 42t-11 56.5v359q0 31 18.5 65t43.5 52zM550 1200q22 0 34.5 -12.5t14.5 -24.5l1 -13v-450q0 -28 -10.5 -59.5 t-25 -56t-29 -45t-25.5 -31.5l-10 -11v-447q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v447q-4 4 -11 11.5t-24 30.5t-30 46t-24 55t-11 60v450q0 2 0.5 5.5t4 12t8.5 15t14.5 12t22.5 5.5q20 0 32.5 -12.5t14.5 -24.5l3 -13v-350h100v350v5.5t2.5 12 t7 15t15 12t25.5 5.5q23 0 35.5 -12.5t13.5 -24.5l1 -13v-350h100v350q0 2 0.5 5.5t3 12t7 15t15 12t24.5 5.5z" />
+<glyph unicode="&#xe180;" d="M1200 1100v-56q-4 0 -11 -0.5t-24 -3t-30 -7.5t-24 -15t-11 -24v-888q0 -22 25 -34.5t50 -13.5l25 -2v-56h-400v56q75 0 87.5 6.5t12.5 43.5v394h-500v-394q0 -37 12.5 -43.5t87.5 -6.5v-56h-400v56q4 0 11 0.5t24 3t30 7.5t24 15t11 24v888q0 22 -25 34.5t-50 13.5 l-25 2v56h400v-56q-75 0 -87.5 -6.5t-12.5 -43.5v-394h500v394q0 37 -12.5 43.5t-87.5 6.5v56h400z" />
+<glyph unicode="&#xe181;" d="M675 1000h375q21 0 35.5 -14.5t14.5 -35.5v-150h-105l-295 -98v98l-200 200h-400l100 100h375zM100 900h300q41 0 70.5 -29.5t29.5 -70.5v-500q0 -41 -29.5 -70.5t-70.5 -29.5h-300q-41 0 -70.5 29.5t-29.5 70.5v500q0 41 29.5 70.5t70.5 29.5zM100 800v-200h300v200 h-300zM1100 535l-400 -133v163l400 133v-163zM100 500v-200h300v200h-300zM1100 398v-248q0 -21 -14.5 -35.5t-35.5 -14.5h-375l-100 -100h-375l-100 100h400l200 200h105z" />
+<glyph unicode="&#xe182;" d="M17 1007l162 162q17 17 40 14t37 -22l139 -194q14 -20 11 -44.5t-20 -41.5l-119 -118q102 -142 228 -268t267 -227l119 118q17 17 42.5 19t44.5 -12l192 -136q19 -14 22.5 -37.5t-13.5 -40.5l-163 -162q-3 -1 -9.5 -1t-29.5 2t-47.5 6t-62.5 14.5t-77.5 26.5t-90 42.5 t-101.5 60t-111 83t-119 108.5q-74 74 -133.5 150.5t-94.5 138.5t-60 119.5t-34.5 100t-15 74.5t-4.5 48z" />
+<glyph unicode="&#xe183;" d="M600 1100q92 0 175 -10.5t141.5 -27t108.5 -36.5t81.5 -40t53.5 -37t31 -27l9 -10v-200q0 -21 -14.5 -33t-34.5 -9l-202 34q-20 3 -34.5 20t-14.5 38v146q-141 24 -300 24t-300 -24v-146q0 -21 -14.5 -38t-34.5 -20l-202 -34q-20 -3 -34.5 9t-14.5 33v200q3 4 9.5 10.5 t31 26t54 37.5t80.5 39.5t109 37.5t141 26.5t175 10.5zM600 795q56 0 97 -9.5t60 -23.5t30 -28t12 -24l1 -10v-50l365 -303q14 -15 24.5 -40t10.5 -45v-212q0 -21 -14.5 -35.5t-35.5 -14.5h-1100q-21 0 -35.5 14.5t-14.5 35.5v212q0 20 10.5 45t24.5 40l365 303v50 q0 4 1 10.5t12 23t30 29t60 22.5t97 10z" />
+<glyph unicode="&#xe184;" d="M1100 700l-200 -200h-600l-200 200v500h200v-200h200v200h200v-200h200v200h200v-500zM250 400h700q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-12l137 -100h-950l137 100h-12q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5zM50 100h1100q21 0 35.5 -14.5 t14.5 -35.5v-50h-1200v50q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe185;" d="M700 1100h-100q-41 0 -70.5 -29.5t-29.5 -70.5v-1000h300v1000q0 41 -29.5 70.5t-70.5 29.5zM1100 800h-100q-41 0 -70.5 -29.5t-29.5 -70.5v-700h300v700q0 41 -29.5 70.5t-70.5 29.5zM400 0h-300v400q0 41 29.5 70.5t70.5 29.5h100q41 0 70.5 -29.5t29.5 -70.5v-400z " />
+<glyph unicode="&#xe186;" d="M200 1100h700q124 0 212 -88t88 -212v-500q0 -124 -88 -212t-212 -88h-700q-124 0 -212 88t-88 212v500q0 124 88 212t212 88zM100 900v-700h900v700h-900zM500 700h-200v-100h200v-300h-300v100h200v100h-200v300h300v-100zM900 700v-300l-100 -100h-200v500h200z M700 700v-300h100v300h-100z" />
+<glyph unicode="&#xe187;" d="M200 1100h700q124 0 212 -88t88 -212v-500q0 -124 -88 -212t-212 -88h-700q-124 0 -212 88t-88 212v500q0 124 88 212t212 88zM100 900v-700h900v700h-900zM500 300h-100v200h-100v-200h-100v500h100v-200h100v200h100v-500zM900 700v-300l-100 -100h-200v500h200z M700 700v-300h100v300h-100z" />
+<glyph unicode="&#xe188;" d="M200 1100h700q124 0 212 -88t88 -212v-500q0 -124 -88 -212t-212 -88h-700q-124 0 -212 88t-88 212v500q0 124 88 212t212 88zM100 900v-700h900v700h-900zM500 700h-200v-300h200v-100h-300v500h300v-100zM900 700h-200v-300h200v-100h-300v500h300v-100z" />
+<glyph unicode="&#xe189;" d="M200 1100h700q124 0 212 -88t88 -212v-500q0 -124 -88 -212t-212 -88h-700q-124 0 -212 88t-88 212v500q0 124 88 212t212 88zM100 900v-700h900v700h-900zM500 400l-300 150l300 150v-300zM900 550l-300 -150v300z" />
+<glyph unicode="&#xe190;" d="M200 1100h700q124 0 212 -88t88 -212v-500q0 -124 -88 -212t-212 -88h-700q-124 0 -212 88t-88 212v500q0 124 88 212t212 88zM100 900v-700h900v700h-900zM900 300h-700v500h700v-500zM800 700h-130q-38 0 -66.5 -43t-28.5 -108t27 -107t68 -42h130v300zM300 700v-300 h130q41 0 68 42t27 107t-28.5 108t-66.5 43h-130z" />
+<glyph unicode="&#xe191;" d="M200 1100h700q124 0 212 -88t88 -212v-500q0 -124 -88 -212t-212 -88h-700q-124 0 -212 88t-88 212v500q0 124 88 212t212 88zM100 900v-700h900v700h-900zM500 700h-200v-100h200v-300h-300v100h200v100h-200v300h300v-100zM900 300h-100v400h-100v100h200v-500z M700 300h-100v100h100v-100z" />
+<glyph unicode="&#xe192;" d="M200 1100h700q124 0 212 -88t88 -212v-500q0 -124 -88 -212t-212 -88h-700q-124 0 -212 88t-88 212v500q0 124 88 212t212 88zM100 900v-700h900v700h-900zM300 700h200v-400h-300v500h100v-100zM900 300h-100v400h-100v100h200v-500zM300 600v-200h100v200h-100z M700 300h-100v100h100v-100z" />
+<glyph unicode="&#xe193;" d="M200 1100h700q124 0 212 -88t88 -212v-500q0 -124 -88 -212t-212 -88h-700q-124 0 -212 88t-88 212v500q0 124 88 212t212 88zM100 900v-700h900v700h-900zM500 500l-199 -200h-100v50l199 200v150h-200v100h300v-300zM900 300h-100v400h-100v100h200v-500zM701 300h-100 v100h100v-100z" />
+<glyph unicode="&#xe194;" d="M600 1191q120 0 229.5 -47t188.5 -126t126 -188.5t47 -229.5t-47 -229.5t-126 -188.5t-188.5 -126t-229.5 -47t-229.5 47t-188.5 126t-126 188.5t-47 229.5t47 229.5t126 188.5t188.5 126t229.5 47zM600 1021q-114 0 -211 -56.5t-153.5 -153.5t-56.5 -211t56.5 -211 t153.5 -153.5t211 -56.5t211 56.5t153.5 153.5t56.5 211t-56.5 211t-153.5 153.5t-211 56.5zM800 700h-300v-200h300v-100h-300l-100 100v200l100 100h300v-100z" />
+<glyph unicode="&#xe195;" d="M600 1191q120 0 229.5 -47t188.5 -126t126 -188.5t47 -229.5t-47 -229.5t-126 -188.5t-188.5 -126t-229.5 -47t-229.5 47t-188.5 126t-126 188.5t-47 229.5t47 229.5t126 188.5t188.5 126t229.5 47zM600 1021q-114 0 -211 -56.5t-153.5 -153.5t-56.5 -211t56.5 -211 t153.5 -153.5t211 -56.5t211 56.5t153.5 153.5t56.5 211t-56.5 211t-153.5 153.5t-211 56.5zM800 700v-100l-50 -50l100 -100v-50h-100l-100 100h-150v-100h-100v400h300zM500 700v-100h200v100h-200z" />
+<glyph unicode="&#xe197;" d="M503 1089q110 0 200.5 -59.5t134.5 -156.5q44 14 90 14q120 0 205 -86.5t85 -207t-85 -207t-205 -86.5h-128v250q0 21 -14.5 35.5t-35.5 14.5h-300q-21 0 -35.5 -14.5t-14.5 -35.5v-250h-222q-80 0 -136 57.5t-56 136.5q0 69 43 122.5t108 67.5q-2 19 -2 37q0 100 49 185 t134 134t185 49zM525 500h150q10 0 17.5 -7.5t7.5 -17.5v-275h137q21 0 26 -11.5t-8 -27.5l-223 -244q-13 -16 -32 -16t-32 16l-223 244q-13 16 -8 27.5t26 11.5h137v275q0 10 7.5 17.5t17.5 7.5z" />
+<glyph unicode="&#xe198;" d="M502 1089q110 0 201 -59.5t135 -156.5q43 15 89 15q121 0 206 -86.5t86 -206.5q0 -99 -60 -181t-150 -110l-378 360q-13 16 -31.5 16t-31.5 -16l-381 -365h-9q-79 0 -135.5 57.5t-56.5 136.5q0 69 43 122.5t108 67.5q-2 19 -2 38q0 100 49 184.5t133.5 134t184.5 49.5z M632 467l223 -228q13 -16 8 -27.5t-26 -11.5h-137v-275q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v275h-137q-21 0 -26 11.5t8 27.5q199 204 223 228q19 19 31.5 19t32.5 -19z" />
+<glyph unicode="&#xe199;" d="M700 100v100h400l-270 300h170l-270 300h170l-300 333l-300 -333h170l-270 -300h170l-270 -300h400v-100h-50q-21 0 -35.5 -14.5t-14.5 -35.5v-50h400v50q0 21 -14.5 35.5t-35.5 14.5h-50z" />
+<glyph unicode="&#xe200;" d="M600 1179q94 0 167.5 -56.5t99.5 -145.5q89 -6 150.5 -71.5t61.5 -155.5q0 -61 -29.5 -112.5t-79.5 -82.5q9 -29 9 -55q0 -74 -52.5 -126.5t-126.5 -52.5q-55 0 -100 30v-251q21 0 35.5 -14.5t14.5 -35.5v-50h-300v50q0 21 14.5 35.5t35.5 14.5v251q-45 -30 -100 -30 q-74 0 -126.5 52.5t-52.5 126.5q0 18 4 38q-47 21 -75.5 65t-28.5 97q0 74 52.5 126.5t126.5 52.5q5 0 23 -2q0 2 -1 10t-1 13q0 116 81.5 197.5t197.5 81.5z" />
+<glyph unicode="&#xe201;" d="M1010 1010q111 -111 150.5 -260.5t0 -299t-150.5 -260.5q-83 -83 -191.5 -126.5t-218.5 -43.5t-218.5 43.5t-191.5 126.5q-111 111 -150.5 260.5t0 299t150.5 260.5q83 83 191.5 126.5t218.5 43.5t218.5 -43.5t191.5 -126.5zM476 1065q-4 0 -8 -1q-121 -34 -209.5 -122.5 t-122.5 -209.5q-4 -12 2.5 -23t18.5 -14l36 -9q3 -1 7 -1q23 0 29 22q27 96 98 166q70 71 166 98q11 3 17.5 13.5t3.5 22.5l-9 35q-3 13 -14 19q-7 4 -15 4zM512 920q-4 0 -9 -2q-80 -24 -138.5 -82.5t-82.5 -138.5q-4 -13 2 -24t19 -14l34 -9q4 -1 8 -1q22 0 28 21 q18 58 58.5 98.5t97.5 58.5q12 3 18 13.5t3 21.5l-9 35q-3 12 -14 19q-7 4 -15 4zM719.5 719.5q-49.5 49.5 -119.5 49.5t-119.5 -49.5t-49.5 -119.5t49.5 -119.5t119.5 -49.5t119.5 49.5t49.5 119.5t-49.5 119.5zM855 551q-22 0 -28 -21q-18 -58 -58.5 -98.5t-98.5 -57.5 q-11 -4 -17 -14.5t-3 -21.5l9 -35q3 -12 14 -19q7 -4 15 -4q4 0 9 2q80 24 138.5 82.5t82.5 138.5q4 13 -2.5 24t-18.5 14l-34 9q-4 1 -8 1zM1000 515q-23 0 -29 -22q-27 -96 -98 -166q-70 -71 -166 -98q-11 -3 -17.5 -13.5t-3.5 -22.5l9 -35q3 -13 14 -19q7 -4 15 -4 q4 0 8 1q121 34 209.5 122.5t122.5 209.5q4 12 -2.5 23t-18.5 14l-36 9q-3 1 -7 1z" />
+<glyph unicode="&#xe202;" d="M700 800h300v-380h-180v200h-340v-200h-380v755q0 10 7.5 17.5t17.5 7.5h575v-400zM1000 900h-200v200zM700 300h162l-212 -212l-212 212h162v200h100v-200zM520 0h-395q-10 0 -17.5 7.5t-7.5 17.5v395zM1000 220v-195q0 -10 -7.5 -17.5t-17.5 -7.5h-195z" />
+<glyph unicode="&#xe203;" d="M700 800h300v-520l-350 350l-550 -550v1095q0 10 7.5 17.5t17.5 7.5h575v-400zM1000 900h-200v200zM862 200h-162v-200h-100v200h-162l212 212zM480 0h-355q-10 0 -17.5 7.5t-7.5 17.5v55h380v-80zM1000 80v-55q0 -10 -7.5 -17.5t-17.5 -7.5h-155v80h180z" />
+<glyph unicode="&#xe204;" d="M1162 800h-162v-200h100l100 -100h-300v300h-162l212 212zM200 800h200q27 0 40 -2t29.5 -10.5t23.5 -30t7 -57.5h300v-100h-600l-200 -350v450h100q0 36 7 57.5t23.5 30t29.5 10.5t40 2zM800 400h240l-240 -400h-800l300 500h500v-100z" />
+<glyph unicode="&#xe205;" d="M650 1100h100q21 0 35.5 -14.5t14.5 -35.5v-50h50q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-300q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5h50v50q0 21 14.5 35.5t35.5 14.5zM1000 850v150q41 0 70.5 -29.5t29.5 -70.5v-800 q0 -41 -29.5 -70.5t-70.5 -29.5h-600q-1 0 -20 4l246 246l-326 326v324q0 41 29.5 70.5t70.5 29.5v-150q0 -62 44 -106t106 -44h300q62 0 106 44t44 106zM412 250l-212 -212v162h-200v100h200v162z" />
+<glyph unicode="&#xe206;" d="M450 1100h100q21 0 35.5 -14.5t14.5 -35.5v-50h50q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-300q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5h50v50q0 21 14.5 35.5t35.5 14.5zM800 850v150q41 0 70.5 -29.5t29.5 -70.5v-500 h-200v-300h200q0 -36 -7 -57.5t-23.5 -30t-29.5 -10.5t-40 -2h-600q-41 0 -70.5 29.5t-29.5 70.5v800q0 41 29.5 70.5t70.5 29.5v-150q0 -62 44 -106t106 -44h300q62 0 106 44t44 106zM1212 250l-212 -212v162h-200v100h200v162z" />
+<glyph unicode="&#xe209;" d="M658 1197l637 -1104q23 -38 7 -65.5t-60 -27.5h-1276q-44 0 -60 27.5t7 65.5l637 1104q22 39 54 39t54 -39zM704 800h-208q-20 0 -32 -14.5t-8 -34.5l58 -302q4 -20 21.5 -34.5t37.5 -14.5h54q20 0 37.5 14.5t21.5 34.5l58 302q4 20 -8 34.5t-32 14.5zM500 300v-100h200 v100h-200z" />
+<glyph unicode="&#xe210;" d="M425 1100h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5zM425 800h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5 t17.5 7.5zM825 800h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5zM25 500h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v150 q0 10 7.5 17.5t17.5 7.5zM425 500h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5zM825 500h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5 v150q0 10 7.5 17.5t17.5 7.5zM25 200h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5zM425 200h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5 t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5zM825 200h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5z" />
+<glyph unicode="&#xe211;" d="M700 1200h100v-200h-100v-100h350q62 0 86.5 -39.5t-3.5 -94.5l-66 -132q-41 -83 -81 -134h-772q-40 51 -81 134l-66 132q-28 55 -3.5 94.5t86.5 39.5h350v100h-100v200h100v100h200v-100zM250 400h700q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-12l137 -100 h-950l138 100h-13q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5zM50 100h1100q21 0 35.5 -14.5t14.5 -35.5v-50h-1200v50q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe212;" d="M600 1300q40 0 68.5 -29.5t28.5 -70.5h-194q0 41 28.5 70.5t68.5 29.5zM443 1100h314q18 -37 18 -75q0 -8 -3 -25h328q41 0 44.5 -16.5t-30.5 -38.5l-175 -145h-678l-178 145q-34 22 -29 38.5t46 16.5h328q-3 17 -3 25q0 38 18 75zM250 700h700q21 0 35.5 -14.5 t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-150v-200l275 -200h-950l275 200v200h-150q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5zM50 100h1100q21 0 35.5 -14.5t14.5 -35.5v-50h-1200v50q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe213;" d="M600 1181q75 0 128 -53t53 -128t-53 -128t-128 -53t-128 53t-53 128t53 128t128 53zM602 798h46q34 0 55.5 -28.5t21.5 -86.5q0 -76 39 -183h-324q39 107 39 183q0 58 21.5 86.5t56.5 28.5h45zM250 400h700q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-13 l138 -100h-950l137 100h-12q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5zM50 100h1100q21 0 35.5 -14.5t14.5 -35.5v-50h-1200v50q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe214;" d="M600 1300q47 0 92.5 -53.5t71 -123t25.5 -123.5q0 -78 -55.5 -133.5t-133.5 -55.5t-133.5 55.5t-55.5 133.5q0 62 34 143l144 -143l111 111l-163 163q34 26 63 26zM602 798h46q34 0 55.5 -28.5t21.5 -86.5q0 -76 39 -183h-324q39 107 39 183q0 58 21.5 86.5t56.5 28.5h45 zM250 400h700q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-13l138 -100h-950l137 100h-12q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5zM50 100h1100q21 0 35.5 -14.5t14.5 -35.5v-50h-1200v50q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe215;" d="M600 1200l300 -161v-139h-300q0 -57 18.5 -108t50 -91.5t63 -72t70 -67.5t57.5 -61h-530q-60 83 -90.5 177.5t-30.5 178.5t33 164.5t87.5 139.5t126 96.5t145.5 41.5v-98zM250 400h700q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-13l138 -100h-950l137 100 h-12q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5zM50 100h1100q21 0 35.5 -14.5t14.5 -35.5v-50h-1200v50q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe216;" d="M600 1300q41 0 70.5 -29.5t29.5 -70.5v-78q46 -26 73 -72t27 -100v-50h-400v50q0 54 27 100t73 72v78q0 41 29.5 70.5t70.5 29.5zM400 800h400q54 0 100 -27t72 -73h-172v-100h200v-100h-200v-100h200v-100h-200v-100h200q0 -83 -58.5 -141.5t-141.5 -58.5h-400 q-83 0 -141.5 58.5t-58.5 141.5v400q0 83 58.5 141.5t141.5 58.5z" />
+<glyph unicode="&#xe218;" d="M150 1100h900q21 0 35.5 -14.5t14.5 -35.5v-500q0 -21 -14.5 -35.5t-35.5 -14.5h-900q-21 0 -35.5 14.5t-14.5 35.5v500q0 21 14.5 35.5t35.5 14.5zM125 400h950q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-283l224 -224q13 -13 13 -31.5t-13 -32 t-31.5 -13.5t-31.5 13l-88 88h-524l-87 -88q-13 -13 -32 -13t-32 13.5t-13 32t13 31.5l224 224h-289q-10 0 -17.5 7.5t-7.5 17.5v50q0 10 7.5 17.5t17.5 7.5zM541 300l-100 -100h324l-100 100h-124z" />
+<glyph unicode="&#xe219;" d="M200 1100h800q83 0 141.5 -58.5t58.5 -141.5v-200h-100q0 41 -29.5 70.5t-70.5 29.5h-250q-41 0 -70.5 -29.5t-29.5 -70.5h-100q0 41 -29.5 70.5t-70.5 29.5h-250q-41 0 -70.5 -29.5t-29.5 -70.5h-100v200q0 83 58.5 141.5t141.5 58.5zM100 600h1000q41 0 70.5 -29.5 t29.5 -70.5v-300h-1200v300q0 41 29.5 70.5t70.5 29.5zM300 100v-50q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v50h200zM1100 100v-50q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v50h200z" />
+<glyph unicode="&#xe221;" d="M480 1165l682 -683q31 -31 31 -75.5t-31 -75.5l-131 -131h-481l-517 518q-32 31 -32 75.5t32 75.5l295 296q31 31 75.5 31t76.5 -31zM108 794l342 -342l303 304l-341 341zM250 100h800q21 0 35.5 -14.5t14.5 -35.5v-50h-900v50q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe223;" d="M1057 647l-189 506q-8 19 -27.5 33t-40.5 14h-400q-21 0 -40.5 -14t-27.5 -33l-189 -506q-8 -19 1.5 -33t30.5 -14h625v-150q0 -21 14.5 -35.5t35.5 -14.5t35.5 14.5t14.5 35.5v150h125q21 0 30.5 14t1.5 33zM897 0h-595v50q0 21 14.5 35.5t35.5 14.5h50v50 q0 21 14.5 35.5t35.5 14.5h48v300h200v-300h47q21 0 35.5 -14.5t14.5 -35.5v-50h50q21 0 35.5 -14.5t14.5 -35.5v-50z" />
+<glyph unicode="&#xe224;" d="M900 800h300v-575q0 -10 -7.5 -17.5t-17.5 -7.5h-375v591l-300 300v84q0 10 7.5 17.5t17.5 7.5h375v-400zM1200 900h-200v200zM400 600h300v-575q0 -10 -7.5 -17.5t-17.5 -7.5h-650q-10 0 -17.5 7.5t-7.5 17.5v950q0 10 7.5 17.5t17.5 7.5h375v-400zM700 700h-200v200z " />
+<glyph unicode="&#xe225;" d="M484 1095h195q75 0 146 -32.5t124 -86t89.5 -122.5t48.5 -142q18 -14 35 -20q31 -10 64.5 6.5t43.5 48.5q10 34 -15 71q-19 27 -9 43q5 8 12.5 11t19 -1t23.5 -16q41 -44 39 -105q-3 -63 -46 -106.5t-104 -43.5h-62q-7 -55 -35 -117t-56 -100l-39 -234q-3 -20 -20 -34.5 t-38 -14.5h-100q-21 0 -33 14.5t-9 34.5l12 70q-49 -14 -91 -14h-195q-24 0 -65 8l-11 -64q-3 -20 -20 -34.5t-38 -14.5h-100q-21 0 -33 14.5t-9 34.5l26 157q-84 74 -128 175l-159 53q-19 7 -33 26t-14 40v50q0 21 14.5 35.5t35.5 14.5h124q11 87 56 166l-111 95 q-16 14 -12.5 23.5t24.5 9.5h203q116 101 250 101zM675 1000h-250q-10 0 -17.5 -7.5t-7.5 -17.5v-50q0 -10 7.5 -17.5t17.5 -7.5h250q10 0 17.5 7.5t7.5 17.5v50q0 10 -7.5 17.5t-17.5 7.5z" />
+<glyph unicode="&#xe226;" d="M641 900l423 247q19 8 42 2.5t37 -21.5l32 -38q14 -15 12.5 -36t-17.5 -34l-139 -120h-390zM50 1100h106q67 0 103 -17t66 -71l102 -212h823q21 0 35.5 -14.5t14.5 -35.5v-50q0 -21 -14 -40t-33 -26l-737 -132q-23 -4 -40 6t-26 25q-42 67 -100 67h-300q-62 0 -106 44 t-44 106v200q0 62 44 106t106 44zM173 928h-80q-19 0 -28 -14t-9 -35v-56q0 -51 42 -51h134q16 0 21.5 8t5.5 24q0 11 -16 45t-27 51q-18 28 -43 28zM550 727q-32 0 -54.5 -22.5t-22.5 -54.5t22.5 -54.5t54.5 -22.5t54.5 22.5t22.5 54.5t-22.5 54.5t-54.5 22.5zM130 389 l152 130q18 19 34 24t31 -3.5t24.5 -17.5t25.5 -28q28 -35 50.5 -51t48.5 -13l63 5l48 -179q13 -61 -3.5 -97.5t-67.5 -79.5l-80 -69q-47 -40 -109 -35.5t-103 51.5l-130 151q-40 47 -35.5 109.5t51.5 102.5zM380 377l-102 -88q-31 -27 2 -65l37 -43q13 -15 27.5 -19.5 t31.5 6.5l61 53q19 16 14 49q-2 20 -12 56t-17 45q-11 12 -19 14t-23 -8z" />
+<glyph unicode="&#xe227;" d="M625 1200h150q10 0 17.5 -7.5t7.5 -17.5v-109q79 -33 131 -87.5t53 -128.5q1 -46 -15 -84.5t-39 -61t-46 -38t-39 -21.5l-17 -6q6 0 15 -1.5t35 -9t50 -17.5t53 -30t50 -45t35.5 -64t14.5 -84q0 -59 -11.5 -105.5t-28.5 -76.5t-44 -51t-49.5 -31.5t-54.5 -16t-49.5 -6.5 t-43.5 -1v-75q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v75h-100v-75q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v75h-175q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5h75v600h-75q-10 0 -17.5 7.5t-7.5 17.5v150 q0 10 7.5 17.5t17.5 7.5h175v75q0 10 7.5 17.5t17.5 7.5h150q10 0 17.5 -7.5t7.5 -17.5v-75h100v75q0 10 7.5 17.5t17.5 7.5zM400 900v-200h263q28 0 48.5 10.5t30 25t15 29t5.5 25.5l1 10q0 4 -0.5 11t-6 24t-15 30t-30 24t-48.5 11h-263zM400 500v-200h363q28 0 48.5 10.5 t30 25t15 29t5.5 25.5l1 10q0 4 -0.5 11t-6 24t-15 30t-30 24t-48.5 11h-363z" />
+<glyph unicode="&#xe230;" d="M212 1198h780q86 0 147 -61t61 -147v-416q0 -51 -18 -142.5t-36 -157.5l-18 -66q-29 -87 -93.5 -146.5t-146.5 -59.5h-572q-82 0 -147 59t-93 147q-8 28 -20 73t-32 143.5t-20 149.5v416q0 86 61 147t147 61zM600 1045q-70 0 -132.5 -11.5t-105.5 -30.5t-78.5 -41.5 t-57 -45t-36 -41t-20.5 -30.5l-6 -12l156 -243h560l156 243q-2 5 -6 12.5t-20 29.5t-36.5 42t-57 44.5t-79 42t-105 29.5t-132.5 12zM762 703h-157l195 261z" />
+<glyph unicode="&#xe231;" d="M475 1300h150q103 0 189 -86t86 -189v-500q0 -41 -42 -83t-83 -42h-450q-41 0 -83 42t-42 83v500q0 103 86 189t189 86zM700 300v-225q0 -21 -27 -48t-48 -27h-150q-21 0 -48 27t-27 48v225h300z" />
+<glyph unicode="&#xe232;" d="M475 1300h96q0 -150 89.5 -239.5t239.5 -89.5v-446q0 -41 -42 -83t-83 -42h-450q-41 0 -83 42t-42 83v500q0 103 86 189t189 86zM700 300v-225q0 -21 -27 -48t-48 -27h-150q-21 0 -48 27t-27 48v225h300z" />
+<glyph unicode="&#xe233;" d="M1294 767l-638 -283l-378 170l-78 -60v-224l100 -150v-199l-150 148l-150 -149v200l100 150v250q0 4 -0.5 10.5t0 9.5t1 8t3 8t6.5 6l47 40l-147 65l642 283zM1000 380l-350 -166l-350 166v147l350 -165l350 165v-147z" />
+<glyph unicode="&#xe234;" d="M250 800q62 0 106 -44t44 -106t-44 -106t-106 -44t-106 44t-44 106t44 106t106 44zM650 800q62 0 106 -44t44 -106t-44 -106t-106 -44t-106 44t-44 106t44 106t106 44zM1050 800q62 0 106 -44t44 -106t-44 -106t-106 -44t-106 44t-44 106t44 106t106 44z" />
+<glyph unicode="&#xe235;" d="M550 1100q62 0 106 -44t44 -106t-44 -106t-106 -44t-106 44t-44 106t44 106t106 44zM550 700q62 0 106 -44t44 -106t-44 -106t-106 -44t-106 44t-44 106t44 106t106 44zM550 300q62 0 106 -44t44 -106t-44 -106t-106 -44t-106 44t-44 106t44 106t106 44z" />
+<glyph unicode="&#xe236;" d="M125 1100h950q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-950q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5zM125 700h950q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-950q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5 t17.5 7.5zM125 300h950q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-950q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5z" />
+<glyph unicode="&#xe237;" d="M350 1200h500q162 0 256 -93.5t94 -256.5v-500q0 -165 -93.5 -257.5t-256.5 -92.5h-500q-165 0 -257.5 92.5t-92.5 257.5v500q0 165 92.5 257.5t257.5 92.5zM900 1000h-600q-41 0 -70.5 -29.5t-29.5 -70.5v-600q0 -41 29.5 -70.5t70.5 -29.5h600q41 0 70.5 29.5 t29.5 70.5v600q0 41 -29.5 70.5t-70.5 29.5zM350 900h500q21 0 35.5 -14.5t14.5 -35.5v-300q0 -21 -14.5 -35.5t-35.5 -14.5h-500q-21 0 -35.5 14.5t-14.5 35.5v300q0 21 14.5 35.5t35.5 14.5zM400 800v-200h400v200h-400z" />
+<glyph unicode="&#xe238;" d="M150 1100h1000q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-50v-200h50q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-50v-200h50q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-50v-200h50q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5 t-35.5 -14.5h-1000q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5h50v200h-50q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5h50v200h-50q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5h50v200h-50q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe239;" d="M650 1187q87 -67 118.5 -156t0 -178t-118.5 -155q-87 66 -118.5 155t0 178t118.5 156zM300 800q124 0 212 -88t88 -212q-124 0 -212 88t-88 212zM1000 800q0 -124 -88 -212t-212 -88q0 124 88 212t212 88zM300 500q124 0 212 -88t88 -212q-124 0 -212 88t-88 212z M1000 500q0 -124 -88 -212t-212 -88q0 124 88 212t212 88zM700 199v-144q0 -21 -14.5 -35.5t-35.5 -14.5t-35.5 14.5t-14.5 35.5v142q40 -4 43 -4q17 0 57 6z" />
+<glyph unicode="&#xe240;" d="M745 878l69 19q25 6 45 -12l298 -295q11 -11 15 -26.5t-2 -30.5q-5 -14 -18 -23.5t-28 -9.5h-8q1 0 1 -13q0 -29 -2 -56t-8.5 -62t-20 -63t-33 -53t-51 -39t-72.5 -14h-146q-184 0 -184 288q0 24 10 47q-20 4 -62 4t-63 -4q11 -24 11 -47q0 -288 -184 -288h-142 q-48 0 -84.5 21t-56 51t-32 71.5t-16 75t-3.5 68.5q0 13 2 13h-7q-15 0 -27.5 9.5t-18.5 23.5q-6 15 -2 30.5t15 25.5l298 296q20 18 46 11l76 -19q20 -5 30.5 -22.5t5.5 -37.5t-22.5 -31t-37.5 -5l-51 12l-182 -193h891l-182 193l-44 -12q-20 -5 -37.5 6t-22.5 31t6 37.5 t31 22.5z" />
+<glyph unicode="&#xe241;" d="M1200 900h-50q0 21 -4 37t-9.5 26.5t-18 17.5t-22 11t-28.5 5.5t-31 2t-37 0.5h-200v-850q0 -22 25 -34.5t50 -13.5l25 -2v-100h-400v100q4 0 11 0.5t24 3t30 7t24 15t11 24.5v850h-200q-25 0 -37 -0.5t-31 -2t-28.5 -5.5t-22 -11t-18 -17.5t-9.5 -26.5t-4 -37h-50v300 h1000v-300zM500 450h-25q0 15 -4 24.5t-9 14.5t-17 7.5t-20 3t-25 0.5h-100v-425q0 -11 12.5 -17.5t25.5 -7.5h12v-50h-200v50q50 0 50 25v425h-100q-17 0 -25 -0.5t-20 -3t-17 -7.5t-9 -14.5t-4 -24.5h-25v150h500v-150z" />
+<glyph unicode="&#xe242;" d="M1000 300v50q-25 0 -55 32q-14 14 -25 31t-16 27l-4 11l-289 747h-69l-300 -754q-18 -35 -39 -56q-9 -9 -24.5 -18.5t-26.5 -14.5l-11 -5v-50h273v50q-49 0 -78.5 21.5t-11.5 67.5l69 176h293l61 -166q13 -34 -3.5 -66.5t-55.5 -32.5v-50h312zM412 691l134 342l121 -342 h-255zM1100 150v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1000q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5h1000q21 0 35.5 -14.5t14.5 -35.5z" />
+<glyph unicode="&#xe243;" d="M50 1200h1100q21 0 35.5 -14.5t14.5 -35.5v-1100q0 -21 -14.5 -35.5t-35.5 -14.5h-1100q-21 0 -35.5 14.5t-14.5 35.5v1100q0 21 14.5 35.5t35.5 14.5zM611 1118h-70q-13 0 -18 -12l-299 -753q-17 -32 -35 -51q-18 -18 -56 -34q-12 -5 -12 -18v-50q0 -8 5.5 -14t14.5 -6 h273q8 0 14 6t6 14v50q0 8 -6 14t-14 6q-55 0 -71 23q-10 14 0 39l63 163h266l57 -153q11 -31 -6 -55q-12 -17 -36 -17q-8 0 -14 -6t-6 -14v-50q0 -8 6 -14t14 -6h313q8 0 14 6t6 14v50q0 7 -5.5 13t-13.5 7q-17 0 -42 25q-25 27 -40 63h-1l-288 748q-5 12 -19 12zM639 611 h-197l103 264z" />
+<glyph unicode="&#xe244;" d="M1200 1100h-1200v100h1200v-100zM50 1000h400q21 0 35.5 -14.5t14.5 -35.5v-900q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v900q0 21 14.5 35.5t35.5 14.5zM650 1000h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-400 q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5zM700 900v-300h300v300h-300z" />
+<glyph unicode="&#xe245;" d="M50 1200h400q21 0 35.5 -14.5t14.5 -35.5v-900q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v900q0 21 14.5 35.5t35.5 14.5zM650 700h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v400 q0 21 14.5 35.5t35.5 14.5zM700 600v-300h300v300h-300zM1200 0h-1200v100h1200v-100z" />
+<glyph unicode="&#xe246;" d="M50 1000h400q21 0 35.5 -14.5t14.5 -35.5v-350h100v150q0 21 14.5 35.5t35.5 14.5h400q21 0 35.5 -14.5t14.5 -35.5v-150h100v-100h-100v-150q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v150h-100v-350q0 -21 -14.5 -35.5t-35.5 -14.5h-400 q-21 0 -35.5 14.5t-14.5 35.5v800q0 21 14.5 35.5t35.5 14.5zM700 700v-300h300v300h-300z" />
+<glyph unicode="&#xe247;" d="M100 0h-100v1200h100v-1200zM250 1100h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5zM300 1000v-300h300v300h-300zM250 500h900q21 0 35.5 -14.5t14.5 -35.5v-400 q0 -21 -14.5 -35.5t-35.5 -14.5h-900q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe248;" d="M600 1100h150q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-150v-100h450q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-900q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5h350v100h-150q-21 0 -35.5 14.5 t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5h150v100h100v-100zM400 1000v-300h300v300h-300z" />
+<glyph unicode="&#xe249;" d="M1200 0h-100v1200h100v-1200zM550 1100h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5zM600 1000v-300h300v300h-300zM50 500h900q21 0 35.5 -14.5t14.5 -35.5v-400 q0 -21 -14.5 -35.5t-35.5 -14.5h-900q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5z" />
+<glyph unicode="&#xe250;" d="M865 565l-494 -494q-23 -23 -41 -23q-14 0 -22 13.5t-8 38.5v1000q0 25 8 38.5t22 13.5q18 0 41 -23l494 -494q14 -14 14 -35t-14 -35z" />
+<glyph unicode="&#xe251;" d="M335 635l494 494q29 29 50 20.5t21 -49.5v-1000q0 -41 -21 -49.5t-50 20.5l-494 494q-14 14 -14 35t14 35z" />
+<glyph unicode="&#xe252;" d="M100 900h1000q41 0 49.5 -21t-20.5 -50l-494 -494q-14 -14 -35 -14t-35 14l-494 494q-29 29 -20.5 50t49.5 21z" />
+<glyph unicode="&#xe253;" d="M635 865l494 -494q29 -29 20.5 -50t-49.5 -21h-1000q-41 0 -49.5 21t20.5 50l494 494q14 14 35 14t35 -14z" />
+<glyph unicode="&#xe254;" d="M700 741v-182l-692 -323v221l413 193l-413 193v221zM1200 0h-800v200h800v-200z" />
+<glyph unicode="&#xe255;" d="M1200 900h-200v-100h200v-100h-300v300h200v100h-200v100h300v-300zM0 700h50q0 21 4 37t9.5 26.5t18 17.5t22 11t28.5 5.5t31 2t37 0.5h100v-550q0 -22 -25 -34.5t-50 -13.5l-25 -2v-100h400v100q-4 0 -11 0.5t-24 3t-30 7t-24 15t-11 24.5v550h100q25 0 37 -0.5t31 -2 t28.5 -5.5t22 -11t18 -17.5t9.5 -26.5t4 -37h50v300h-800v-300z" />
+<glyph unicode="&#xe256;" d="M800 700h-50q0 21 -4 37t-9.5 26.5t-18 17.5t-22 11t-28.5 5.5t-31 2t-37 0.5h-100v-550q0 -22 25 -34.5t50 -14.5l25 -1v-100h-400v100q4 0 11 0.5t24 3t30 7t24 15t11 24.5v550h-100q-25 0 -37 -0.5t-31 -2t-28.5 -5.5t-22 -11t-18 -17.5t-9.5 -26.5t-4 -37h-50v300 h800v-300zM1100 200h-200v-100h200v-100h-300v300h200v100h-200v100h300v-300z" />
+<glyph unicode="&#xe257;" d="M701 1098h160q16 0 21 -11t-7 -23l-464 -464l464 -464q12 -12 7 -23t-21 -11h-160q-13 0 -23 9l-471 471q-7 8 -7 18t7 18l471 471q10 9 23 9z" />
+<glyph unicode="&#xe258;" d="M339 1098h160q13 0 23 -9l471 -471q7 -8 7 -18t-7 -18l-471 -471q-10 -9 -23 -9h-160q-16 0 -21 11t7 23l464 464l-464 464q-12 12 -7 23t21 11z" />
+<glyph unicode="&#xe259;" d="M1087 882q11 -5 11 -21v-160q0 -13 -9 -23l-471 -471q-8 -7 -18 -7t-18 7l-471 471q-9 10 -9 23v160q0 16 11 21t23 -7l464 -464l464 464q12 12 23 7z" />
+<glyph unicode="&#xe260;" d="M618 993l471 -471q9 -10 9 -23v-160q0 -16 -11 -21t-23 7l-464 464l-464 -464q-12 -12 -23 -7t-11 21v160q0 13 9 23l471 471q8 7 18 7t18 -7z" />
+<glyph unicode="&#xf8ff;" d="M1000 1200q0 -124 -88 -212t-212 -88q0 124 88 212t212 88zM450 1000h100q21 0 40 -14t26 -33l79 -194q5 1 16 3q34 6 54 9.5t60 7t65.5 1t61 -10t56.5 -23t42.5 -42t29 -64t5 -92t-19.5 -121.5q-1 -7 -3 -19.5t-11 -50t-20.5 -73t-32.5 -81.5t-46.5 -83t-64 -70 t-82.5 -50q-13 -5 -42 -5t-65.5 2.5t-47.5 2.5q-14 0 -49.5 -3.5t-63 -3.5t-43.5 7q-57 25 -104.5 78.5t-75 111.5t-46.5 112t-26 90l-7 35q-15 63 -18 115t4.5 88.5t26 64t39.5 43.5t52 25.5t58.5 13t62.5 2t59.5 -4.5t55.5 -8l-147 192q-12 18 -5.5 30t27.5 12z" />
+<glyph unicode="&#x1f511;" d="M250 1200h600q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-150v-500l-255 -178q-19 -9 -32 -1t-13 29v650h-150q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5zM400 1100v-100h300v100h-300z" />
+<glyph unicode="&#x1f6aa;" d="M250 1200h750q39 0 69.5 -40.5t30.5 -84.5v-933l-700 -117v950l600 125h-700v-1000h-100v1025q0 23 15.5 49t34.5 26zM500 525v-100l100 20v100z" />
+</font>
+</defs></svg> 
\ No newline at end of file
diff --git a/web/fonts/glyphicons-halflings-regular.ttf b/web/fonts/glyphicons-halflings-regular.ttf
new file mode 100755
index 0000000000000000000000000000000000000000..1413fc609ab6f21774de0cb7e01360095584f65b
Binary files /dev/null and b/web/fonts/glyphicons-halflings-regular.ttf differ
diff --git a/web/fonts/glyphicons-halflings-regular.woff b/web/fonts/glyphicons-halflings-regular.woff
new file mode 100755
index 0000000000000000000000000000000000000000..9e612858f802245ddcbf59788a0db942224bab35
Binary files /dev/null and b/web/fonts/glyphicons-halflings-regular.woff differ
diff --git a/web/fonts/glyphicons-halflings-regular.woff2 b/web/fonts/glyphicons-halflings-regular.woff2
new file mode 100755
index 0000000000000000000000000000000000000000..64539b54c3751a6d9adb44c8e3a45ba5a73b77f0
Binary files /dev/null and b/web/fonts/glyphicons-halflings-regular.woff2 differ
diff --git a/web/graph.php b/web/graph.php
new file mode 100644
index 0000000000000000000000000000000000000000..ef2418933d1755cbeba704b3a938845ea3298aed
--- /dev/null
+++ b/web/graph.php
@@ -0,0 +1,123 @@
+<?php // content="text/plain; charset=utf-8"
+require_once ('classes/jpgraph/jpgraph.php');
+require_once ('classes/jpgraph/jpgraph_line.php');
+require_once ('classes/SQL.php');
+require_once ('include/config.php');
+
+if (isset($_GET["param"])){
+	if (isset($_GET["details"]) && $_GET["details"] == "yes"){
+		$showDetails = true;
+	}else{
+		$showDetails = false;
+	}
+
+		$sql = new SQL();
+		$link = $sql->getLink();
+
+		$dataY = array();
+		$dataX = array();
+
+		$result = $link->query("SELECT * FROM ".$TBL_PARAMETER." INNER JOIN ".$TBL_REGISTER." ON ".$TBL_PARAMETER.".fid_register = ".$TBL_REGISTER.".id WHERE ".$TBL_PARAMETER.".id = ".$_GET["param"]);
+		while($row = $result->fetch_assoc()) {
+			$name = $row["name"];
+			$param = $row["param"];
+		}
+
+		$result = $link->query("SELECT fid_parameter, value, DATE_FORMAT(timestamp, '%d.%m.%Y %H:%i:%s') as date FROM ".$TBL_DATA." WHERE fid_parameter = ".$_GET["param"]);
+		while($row = $result->fetch_assoc()) {
+			array_push($dataY, $row["value"]);
+			array_push($dataX, $row["date"]);
+		}
+
+		// Beschränke die Anzahl der Punkte auf X Achse 
+		$dataY = array_slice($dataY, $GRAPHPOINTS);
+		$dataX = array_slice($dataX, $GRAPHPOINTS);
+
+		// Reduziere Anzahl der Daten auf X-Achse
+		// 10 Prozent der Gesamtanzahl sind die Marken, die zwischen der ersten und letzten Marke hinzugefügt werden sollen.
+		// Beispiel: 20 Messungen => 
+		if (count($dataX) > 3){
+			// 10% an weiteren Markern
+
+			// Bestimme 10 Prozent. Beispiel: 20 Messungen => 2 => Aufteilung in 3 gleichgroße Teile
+			// 20 / 3 = 7. Marker bei 7 und 14.
+			$teile = round(0.1 * count($dataX)) + 1; // = 3
+			$anzahl = round(count($dataX) / $teile); // = 7
+			$marker = $anzahl;
+
+			for ($i = 1; $i<count($dataX)-1; $i++){
+				if ($showDetails){
+					if ($i == $marker){
+					$marker = $marker + $anzahl;
+					}else{
+						$dataX[$i] = "";
+					}
+				}else{
+					$dataX[$i] = "";
+				}
+				
+			}
+		}
+		if (!$showDetails) {
+			$dataX[0] = "";
+			$dataX[count($dataX)-1] = "";
+		}
+		
+
+		// Setup the graph
+		$graph = new Graph(1024,600);
+		$graph->SetScale("textlin");
+
+		$theme_class=new UniversalTheme;
+
+		$graph->SetTheme($theme_class);
+		
+		$graph->SetBox(true);
+		
+
+
+		
+		$graph->img->SetAntiAliasing(false);
+
+		$graph->yaxis->HideZeroLabel();
+		$graph->yaxis->HideLine(false);
+		$graph->yaxis->HideTicks(true,true);
+
+		$graph->xgrid->Show();
+		$graph->xgrid->SetLineStyle("solid");
+		$graph->ygrid->SetLineStyle('dotted');
+		$graph->xaxis->SetLabelAngle(35);
+		$graph->xaxis->SetTickLabels($dataX);
+		$graph->xgrid->SetColor('#E3E3E3');
+
+		// Create the first line
+		$p1 = new LinePlot($dataY);
+		$graph->Add($p1);
+		$p1->SetColor("#6495ED");
+		$p1->SetWeight(5); 
+		
+
+		
+
+		$graph->legend->SetFrameWeight(1);
+
+
+		if ($showDetails){
+			$graph->title->Set($name);
+			$graph->SetMargin(130,100,40,0);
+			$graph->yaxis->HideTicks(false,false);
+			$graph->xgrid->SetLineStyle("solid");
+			$graph->img->SetAntiAliasing(true);
+			$p1->SetLegend($param);
+
+		}
+
+		// Output line
+		if (count($dataY) > 1){
+			$graph->Stroke();
+		}else{
+			header('Content-type: image/png');
+			readfile("img/nodata.png");
+		}
+}
+?>
\ No newline at end of file
diff --git a/web/img/blank.png b/web/img/blank.png
new file mode 100644
index 0000000000000000000000000000000000000000..41c89a5fe186bab68ddd182939999e248806b400
Binary files /dev/null and b/web/img/blank.png differ
diff --git a/web/img/blank2.png b/web/img/blank2.png
new file mode 100644
index 0000000000000000000000000000000000000000..0a6fe34123713bb5256dc923551d5c18ff80fb50
Binary files /dev/null and b/web/img/blank2.png differ
diff --git a/web/img/nodata.png b/web/img/nodata.png
new file mode 100644
index 0000000000000000000000000000000000000000..fd3c4d877d0818697377544cf91cd9b4bb0e3bd6
Binary files /dev/null and b/web/img/nodata.png differ
diff --git a/web/img/table.png b/web/img/table.png
new file mode 100644
index 0000000000000000000000000000000000000000..d52abe5c79e4bde3cf29cbb119c702f5e1cf921f
Binary files /dev/null and b/web/img/table.png differ
diff --git a/web/include/_foot.php b/web/include/_foot.php
new file mode 100644
index 0000000000000000000000000000000000000000..9c2c241a8d3e1bccf9e887cb78f0fda7fe5a187a
--- /dev/null
+++ b/web/include/_foot.php
@@ -0,0 +1,24 @@
+<hr>
+
+        <!-- Footer -->
+        <footer>
+            <div class="row">
+                <div class="col-lg-12">
+                    <p>&copy; Philip Jakob - SWP Telematik SS 2016</p>
+                </div>
+            </div>
+            <!-- /.row -->
+        </footer>
+
+    </div>
+    <!-- /.container -->
+
+    <!-- jQuery -->
+    <script src="js/jquery.js"></script>
+
+    <!-- Bootstrap Core JavaScript -->
+    <script src="js/bootstrap.min.js"></script>
+
+</body>
+
+</html>
diff --git a/web/include/_head.php b/web/include/_head.php
new file mode 100644
index 0000000000000000000000000000000000000000..4902939d7a4ddd831ea81ad807cd67bb43eee00d
--- /dev/null
+++ b/web/include/_head.php
@@ -0,0 +1,67 @@
+<!DOCTYPE html>
+<html lang="en">
+
+<head>
+
+    <meta charset="utf-8">
+    <meta http-equiv="X-UA-Compatible" content="IE=edge">
+    <meta name="viewport" content="width=device-width, initial-scale=1">
+    <meta name="description" content="">
+    <meta name="author" content="">
+
+    <title>SWP Telematik: Border Gateway - Dashboard</title>
+
+    <!-- Bootstrap Core CSS -->
+    <link href="css/bootstrap.min.css" rel="stylesheet">
+
+    <!-- Custom CSS -->
+    <link href="css/3-col-portfolio.css" rel="stylesheet">
+
+    <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
+    <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
+    <!--[if lt IE 9]>
+        <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
+        <script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script>
+    <![endif]-->
+
+</head>
+
+<body>
+
+    <!-- Navigation -->
+    <nav class="navbar navbar-inverse navbar-fixed-top" role="navigation">
+        <div class="container">
+            <!-- Brand and toggle get grouped for better mobile display -->
+            <div class="navbar-header">
+                <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1">
+                    <span class="sr-only">Toggle navigation</span>
+                    <span class="icon-bar"></span>
+                    <span class="icon-bar"></span>
+                    <span class="icon-bar"></span>
+                </button>
+                <a class="navbar-brand" href="">SWP Telematik</a>
+            </div>
+            <!-- Collect the nav links, forms, and other content for toggling -->
+            <div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
+                <ul class="nav navbar-nav">
+                    <li>
+                        <a href="#">About</a>
+                    </li>
+                    <li>
+                        <a href="#">Services</a>
+                    </li>
+                    <li>
+                        <a href="#">Contact</a>
+                    </li>
+                </ul>
+            </div>
+            <!-- /.navbar-collapse -->
+        </div>
+        <!-- /.container -->
+    </nav>
+
+    <!-- Page Content -->
+    <div class="container">
+
+        
+        <!-- /.row -->
\ No newline at end of file
diff --git a/web/include/config.php b/web/include/config.php
new file mode 100644
index 0000000000000000000000000000000000000000..1a4f4a7f5afa9afc8fc9b1dc04821ed2c9651361
--- /dev/null
+++ b/web/include/config.php
@@ -0,0 +1,8 @@
+<?php
+
+$TBL_PARAMETER = "tbl_parameter";
+$TBL_REGISTER = "tbl_register";
+$TBL_DATA = "tbl_data";
+$GRAPHPOINTS = -50;
+
+?>
\ No newline at end of file
diff --git a/web/index.php b/web/index.php
new file mode 100755
index 0000000000000000000000000000000000000000..39d7d2d2e888f0e53c9f0bd150fdab49c627ffa5
--- /dev/null
+++ b/web/index.php
@@ -0,0 +1,76 @@
+<?php
+require_once("classes/SQL.php");
+include("include/_head.php");
+?>
+
+<!-- Page Header -->
+        <div class="row">
+            <div class="col-lg-12">
+                <h1 class="page-header">Dashboard
+                </h1>
+            </div>
+        </div>
+
+<?php
+$sql = new SQL();
+$link = $sql->getLink();
+
+$query = "SELECT * FROM (tbl_register INNER JOIN tbl_parameter ON tbl_register.id = tbl_parameter.fid_register) INNER JOIN tbl_data ON tbl_parameter.id = tbl_data.fid_parameter WHERE tbl_register.id IN (SELECT max(id) FROM tbl_register group by clientAddress) AND tbl_data.id IN (SELECT max(id) FROM tbl_data group by fid_parameter) GROUP BY name";
+
+
+
+
+$result = $link->query($query);
+while($row = $result->fetch_assoc()) {
+
+    echo '<!-- Projects Row -->
+        <div class="row">
+            <div class="col-lg-12">
+                <h3 class="page-header">'.$row["name"].'
+                    <small>Secondary Text</small>
+                </h3>
+            </div>
+        </div>
+        <div class="row">';
+
+    
+    $query2 = "SELECT * FROM (tbl_register INNER JOIN tbl_parameter ON tbl_register.id = tbl_parameter.fid_register) INNER JOIN tbl_data ON tbl_parameter.id = tbl_data.fid_parameter WHERE tbl_register.id = ".$row["fid_register"]." AND tbl_data.id IN (SELECT max(id) FROM tbl_data group by fid_parameter)";
+    $result2 = $link->query($query2);
+
+    while($row2 = $result2->fetch_assoc()) {
+
+
+        echo '
+            <div class="col-md-4 portfolio-item">';
+
+            if ($row2["type"] == "string"){
+                echo '
+                <a href="details.php?param='.$row2["fid_parameter"].'">
+                    <img class="img-responsive" src="img/table.png" alt="">
+                </a>';
+            }else{
+                echo '
+                <a href="details.php?param='.$row2["fid_parameter"].'">
+                    <img class="img-responsive" src="graph.php?param='.$row2["fid_parameter"].'" alt="">
+                </a>';
+            }
+                echo '
+                <h3>
+                    <a href="details.php?param='.$row2["fid_parameter"].'">'.$row2["param"].'</a>
+                </h3>
+                <p>'.$row2["value"].'</p>
+            </div>';
+    }
+
+    echo '</div>
+        <!-- /.row -->';
+}
+
+?>
+        
+
+
+
+<?php
+include("include/_foot.php");
+?>
\ No newline at end of file
diff --git a/web/js/bootstrap.js b/web/js/bootstrap.js
new file mode 100755
index 0000000000000000000000000000000000000000..01fbbcbaa9fd750c456258ebc4a305ceb94adafd
--- /dev/null
+++ b/web/js/bootstrap.js
@@ -0,0 +1,2363 @@
+/*!
+ * Bootstrap v3.3.6 (http://getbootstrap.com)
+ * Copyright 2011-2015 Twitter, Inc.
+ * Licensed under the MIT license
+ */
+
+if (typeof jQuery === 'undefined') {
+  throw new Error('Bootstrap\'s JavaScript requires jQuery')
+}
+
++function ($) {
+  'use strict';
+  var version = $.fn.jquery.split(' ')[0].split('.')
+  if ((version[0] < 2 && version[1] < 9) || (version[0] == 1 && version[1] == 9 && version[2] < 1) || (version[0] > 2)) {
+    throw new Error('Bootstrap\'s JavaScript requires jQuery version 1.9.1 or higher, but lower than version 3')
+  }
+}(jQuery);
+
+/* ========================================================================
+ * Bootstrap: transition.js v3.3.6
+ * http://getbootstrap.com/javascript/#transitions
+ * ========================================================================
+ * Copyright 2011-2015 Twitter, Inc.
+ * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
+ * ======================================================================== */
+
+
++function ($) {
+  'use strict';
+
+  // CSS TRANSITION SUPPORT (Shoutout: http://www.modernizr.com/)
+  // ============================================================
+
+  function transitionEnd() {
+    var el = document.createElement('bootstrap')
+
+    var transEndEventNames = {
+      WebkitTransition : 'webkitTransitionEnd',
+      MozTransition    : 'transitionend',
+      OTransition      : 'oTransitionEnd otransitionend',
+      transition       : 'transitionend'
+    }
+
+    for (var name in transEndEventNames) {
+      if (el.style[name] !== undefined) {
+        return { end: transEndEventNames[name] }
+      }
+    }
+
+    return false // explicit for ie8 (  ._.)
+  }
+
+  // http://blog.alexmaccaw.com/css-transitions
+  $.fn.emulateTransitionEnd = function (duration) {
+    var called = false
+    var $el = this
+    $(this).one('bsTransitionEnd', function () { called = true })
+    var callback = function () { if (!called) $($el).trigger($.support.transition.end) }
+    setTimeout(callback, duration)
+    return this
+  }
+
+  $(function () {
+    $.support.transition = transitionEnd()
+
+    if (!$.support.transition) return
+
+    $.event.special.bsTransitionEnd = {
+      bindType: $.support.transition.end,
+      delegateType: $.support.transition.end,
+      handle: function (e) {
+        if ($(e.target).is(this)) return e.handleObj.handler.apply(this, arguments)
+      }
+    }
+  })
+
+}(jQuery);
+
+/* ========================================================================
+ * Bootstrap: alert.js v3.3.6
+ * http://getbootstrap.com/javascript/#alerts
+ * ========================================================================
+ * Copyright 2011-2015 Twitter, Inc.
+ * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
+ * ======================================================================== */
+
+
++function ($) {
+  'use strict';
+
+  // ALERT CLASS DEFINITION
+  // ======================
+
+  var dismiss = '[data-dismiss="alert"]'
+  var Alert   = function (el) {
+    $(el).on('click', dismiss, this.close)
+  }
+
+  Alert.VERSION = '3.3.6'
+
+  Alert.TRANSITION_DURATION = 150
+
+  Alert.prototype.close = function (e) {
+    var $this    = $(this)
+    var selector = $this.attr('data-target')
+
+    if (!selector) {
+      selector = $this.attr('href')
+      selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7
+    }
+
+    var $parent = $(selector)
+
+    if (e) e.preventDefault()
+
+    if (!$parent.length) {
+      $parent = $this.closest('.alert')
+    }
+
+    $parent.trigger(e = $.Event('close.bs.alert'))
+
+    if (e.isDefaultPrevented()) return
+
+    $parent.removeClass('in')
+
+    function removeElement() {
+      // detach from parent, fire event then clean up data
+      $parent.detach().trigger('closed.bs.alert').remove()
+    }
+
+    $.support.transition && $parent.hasClass('fade') ?
+      $parent
+        .one('bsTransitionEnd', removeElement)
+        .emulateTransitionEnd(Alert.TRANSITION_DURATION) :
+      removeElement()
+  }
+
+
+  // ALERT PLUGIN DEFINITION
+  // =======================
+
+  function Plugin(option) {
+    return this.each(function () {
+      var $this = $(this)
+      var data  = $this.data('bs.alert')
+
+      if (!data) $this.data('bs.alert', (data = new Alert(this)))
+      if (typeof option == 'string') data[option].call($this)
+    })
+  }
+
+  var old = $.fn.alert
+
+  $.fn.alert             = Plugin
+  $.fn.alert.Constructor = Alert
+
+
+  // ALERT NO CONFLICT
+  // =================
+
+  $.fn.alert.noConflict = function () {
+    $.fn.alert = old
+    return this
+  }
+
+
+  // ALERT DATA-API
+  // ==============
+
+  $(document).on('click.bs.alert.data-api', dismiss, Alert.prototype.close)
+
+}(jQuery);
+
+/* ========================================================================
+ * Bootstrap: button.js v3.3.6
+ * http://getbootstrap.com/javascript/#buttons
+ * ========================================================================
+ * Copyright 2011-2015 Twitter, Inc.
+ * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
+ * ======================================================================== */
+
+
++function ($) {
+  'use strict';
+
+  // BUTTON PUBLIC CLASS DEFINITION
+  // ==============================
+
+  var Button = function (element, options) {
+    this.$element  = $(element)
+    this.options   = $.extend({}, Button.DEFAULTS, options)
+    this.isLoading = false
+  }
+
+  Button.VERSION  = '3.3.6'
+
+  Button.DEFAULTS = {
+    loadingText: 'loading...'
+  }
+
+  Button.prototype.setState = function (state) {
+    var d    = 'disabled'
+    var $el  = this.$element
+    var val  = $el.is('input') ? 'val' : 'html'
+    var data = $el.data()
+
+    state += 'Text'
+
+    if (data.resetText == null) $el.data('resetText', $el[val]())
+
+    // push to event loop to allow forms to submit
+    setTimeout($.proxy(function () {
+      $el[val](data[state] == null ? this.options[state] : data[state])
+
+      if (state == 'loadingText') {
+        this.isLoading = true
+        $el.addClass(d).attr(d, d)
+      } else if (this.isLoading) {
+        this.isLoading = false
+        $el.removeClass(d).removeAttr(d)
+      }
+    }, this), 0)
+  }
+
+  Button.prototype.toggle = function () {
+    var changed = true
+    var $parent = this.$element.closest('[data-toggle="buttons"]')
+
+    if ($parent.length) {
+      var $input = this.$element.find('input')
+      if ($input.prop('type') == 'radio') {
+        if ($input.prop('checked')) changed = false
+        $parent.find('.active').removeClass('active')
+        this.$element.addClass('active')
+      } else if ($input.prop('type') == 'checkbox') {
+        if (($input.prop('checked')) !== this.$element.hasClass('active')) changed = false
+        this.$element.toggleClass('active')
+      }
+      $input.prop('checked', this.$element.hasClass('active'))
+      if (changed) $input.trigger('change')
+    } else {
+      this.$element.attr('aria-pressed', !this.$element.hasClass('active'))
+      this.$element.toggleClass('active')
+    }
+  }
+
+
+  // BUTTON PLUGIN DEFINITION
+  // ========================
+
+  function Plugin(option) {
+    return this.each(function () {
+      var $this   = $(this)
+      var data    = $this.data('bs.button')
+      var options = typeof option == 'object' && option
+
+      if (!data) $this.data('bs.button', (data = new Button(this, options)))
+
+      if (option == 'toggle') data.toggle()
+      else if (option) data.setState(option)
+    })
+  }
+
+  var old = $.fn.button
+
+  $.fn.button             = Plugin
+  $.fn.button.Constructor = Button
+
+
+  // BUTTON NO CONFLICT
+  // ==================
+
+  $.fn.button.noConflict = function () {
+    $.fn.button = old
+    return this
+  }
+
+
+  // BUTTON DATA-API
+  // ===============
+
+  $(document)
+    .on('click.bs.button.data-api', '[data-toggle^="button"]', function (e) {
+      var $btn = $(e.target)
+      if (!$btn.hasClass('btn')) $btn = $btn.closest('.btn')
+      Plugin.call($btn, 'toggle')
+      if (!($(e.target).is('input[type="radio"]') || $(e.target).is('input[type="checkbox"]'))) e.preventDefault()
+    })
+    .on('focus.bs.button.data-api blur.bs.button.data-api', '[data-toggle^="button"]', function (e) {
+      $(e.target).closest('.btn').toggleClass('focus', /^focus(in)?$/.test(e.type))
+    })
+
+}(jQuery);
+
+/* ========================================================================
+ * Bootstrap: carousel.js v3.3.6
+ * http://getbootstrap.com/javascript/#carousel
+ * ========================================================================
+ * Copyright 2011-2015 Twitter, Inc.
+ * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
+ * ======================================================================== */
+
+
++function ($) {
+  'use strict';
+
+  // CAROUSEL CLASS DEFINITION
+  // =========================
+
+  var Carousel = function (element, options) {
+    this.$element    = $(element)
+    this.$indicators = this.$element.find('.carousel-indicators')
+    this.options     = options
+    this.paused      = null
+    this.sliding     = null
+    this.interval    = null
+    this.$active     = null
+    this.$items      = null
+
+    this.options.keyboard && this.$element.on('keydown.bs.carousel', $.proxy(this.keydown, this))
+
+    this.options.pause == 'hover' && !('ontouchstart' in document.documentElement) && this.$element
+      .on('mouseenter.bs.carousel', $.proxy(this.pause, this))
+      .on('mouseleave.bs.carousel', $.proxy(this.cycle, this))
+  }
+
+  Carousel.VERSION  = '3.3.6'
+
+  Carousel.TRANSITION_DURATION = 600
+
+  Carousel.DEFAULTS = {
+    interval: 5000,
+    pause: 'hover',
+    wrap: true,
+    keyboard: true
+  }
+
+  Carousel.prototype.keydown = function (e) {
+    if (/input|textarea/i.test(e.target.tagName)) return
+    switch (e.which) {
+      case 37: this.prev(); break
+      case 39: this.next(); break
+      default: return
+    }
+
+    e.preventDefault()
+  }
+
+  Carousel.prototype.cycle = function (e) {
+    e || (this.paused = false)
+
+    this.interval && clearInterval(this.interval)
+
+    this.options.interval
+      && !this.paused
+      && (this.interval = setInterval($.proxy(this.next, this), this.options.interval))
+
+    return this
+  }
+
+  Carousel.prototype.getItemIndex = function (item) {
+    this.$items = item.parent().children('.item')
+    return this.$items.index(item || this.$active)
+  }
+
+  Carousel.prototype.getItemForDirection = function (direction, active) {
+    var activeIndex = this.getItemIndex(active)
+    var willWrap = (direction == 'prev' && activeIndex === 0)
+                || (direction == 'next' && activeIndex == (this.$items.length - 1))
+    if (willWrap && !this.options.wrap) return active
+    var delta = direction == 'prev' ? -1 : 1
+    var itemIndex = (activeIndex + delta) % this.$items.length
+    return this.$items.eq(itemIndex)
+  }
+
+  Carousel.prototype.to = function (pos) {
+    var that        = this
+    var activeIndex = this.getItemIndex(this.$active = this.$element.find('.item.active'))
+
+    if (pos > (this.$items.length - 1) || pos < 0) return
+
+    if (this.sliding)       return this.$element.one('slid.bs.carousel', function () { that.to(pos) }) // yes, "slid"
+    if (activeIndex == pos) return this.pause().cycle()
+
+    return this.slide(pos > activeIndex ? 'next' : 'prev', this.$items.eq(pos))
+  }
+
+  Carousel.prototype.pause = function (e) {
+    e || (this.paused = true)
+
+    if (this.$element.find('.next, .prev').length && $.support.transition) {
+      this.$element.trigger($.support.transition.end)
+      this.cycle(true)
+    }
+
+    this.interval = clearInterval(this.interval)
+
+    return this
+  }
+
+  Carousel.prototype.next = function () {
+    if (this.sliding) return
+    return this.slide('next')
+  }
+
+  Carousel.prototype.prev = function () {
+    if (this.sliding) return
+    return this.slide('prev')
+  }
+
+  Carousel.prototype.slide = function (type, next) {
+    var $active   = this.$element.find('.item.active')
+    var $next     = next || this.getItemForDirection(type, $active)
+    var isCycling = this.interval
+    var direction = type == 'next' ? 'left' : 'right'
+    var that      = this
+
+    if ($next.hasClass('active')) return (this.sliding = false)
+
+    var relatedTarget = $next[0]
+    var slideEvent = $.Event('slide.bs.carousel', {
+      relatedTarget: relatedTarget,
+      direction: direction
+    })
+    this.$element.trigger(slideEvent)
+    if (slideEvent.isDefaultPrevented()) return
+
+    this.sliding = true
+
+    isCycling && this.pause()
+
+    if (this.$indicators.length) {
+      this.$indicators.find('.active').removeClass('active')
+      var $nextIndicator = $(this.$indicators.children()[this.getItemIndex($next)])
+      $nextIndicator && $nextIndicator.addClass('active')
+    }
+
+    var slidEvent = $.Event('slid.bs.carousel', { relatedTarget: relatedTarget, direction: direction }) // yes, "slid"
+    if ($.support.transition && this.$element.hasClass('slide')) {
+      $next.addClass(type)
+      $next[0].offsetWidth // force reflow
+      $active.addClass(direction)
+      $next.addClass(direction)
+      $active
+        .one('bsTransitionEnd', function () {
+          $next.removeClass([type, direction].join(' ')).addClass('active')
+          $active.removeClass(['active', direction].join(' '))
+          that.sliding = false
+          setTimeout(function () {
+            that.$element.trigger(slidEvent)
+          }, 0)
+        })
+        .emulateTransitionEnd(Carousel.TRANSITION_DURATION)
+    } else {
+      $active.removeClass('active')
+      $next.addClass('active')
+      this.sliding = false
+      this.$element.trigger(slidEvent)
+    }
+
+    isCycling && this.cycle()
+
+    return this
+  }
+
+
+  // CAROUSEL PLUGIN DEFINITION
+  // ==========================
+
+  function Plugin(option) {
+    return this.each(function () {
+      var $this   = $(this)
+      var data    = $this.data('bs.carousel')
+      var options = $.extend({}, Carousel.DEFAULTS, $this.data(), typeof option == 'object' && option)
+      var action  = typeof option == 'string' ? option : options.slide
+
+      if (!data) $this.data('bs.carousel', (data = new Carousel(this, options)))
+      if (typeof option == 'number') data.to(option)
+      else if (action) data[action]()
+      else if (options.interval) data.pause().cycle()
+    })
+  }
+
+  var old = $.fn.carousel
+
+  $.fn.carousel             = Plugin
+  $.fn.carousel.Constructor = Carousel
+
+
+  // CAROUSEL NO CONFLICT
+  // ====================
+
+  $.fn.carousel.noConflict = function () {
+    $.fn.carousel = old
+    return this
+  }
+
+
+  // CAROUSEL DATA-API
+  // =================
+
+  var clickHandler = function (e) {
+    var href
+    var $this   = $(this)
+    var $target = $($this.attr('data-target') || (href = $this.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '')) // strip for ie7
+    if (!$target.hasClass('carousel')) return
+    var options = $.extend({}, $target.data(), $this.data())
+    var slideIndex = $this.attr('data-slide-to')
+    if (slideIndex) options.interval = false
+
+    Plugin.call($target, options)
+
+    if (slideIndex) {
+      $target.data('bs.carousel').to(slideIndex)
+    }
+
+    e.preventDefault()
+  }
+
+  $(document)
+    .on('click.bs.carousel.data-api', '[data-slide]', clickHandler)
+    .on('click.bs.carousel.data-api', '[data-slide-to]', clickHandler)
+
+  $(window).on('load', function () {
+    $('[data-ride="carousel"]').each(function () {
+      var $carousel = $(this)
+      Plugin.call($carousel, $carousel.data())
+    })
+  })
+
+}(jQuery);
+
+/* ========================================================================
+ * Bootstrap: collapse.js v3.3.6
+ * http://getbootstrap.com/javascript/#collapse
+ * ========================================================================
+ * Copyright 2011-2015 Twitter, Inc.
+ * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
+ * ======================================================================== */
+
+
++function ($) {
+  'use strict';
+
+  // COLLAPSE PUBLIC CLASS DEFINITION
+  // ================================
+
+  var Collapse = function (element, options) {
+    this.$element      = $(element)
+    this.options       = $.extend({}, Collapse.DEFAULTS, options)
+    this.$trigger      = $('[data-toggle="collapse"][href="#' + element.id + '"],' +
+                           '[data-toggle="collapse"][data-target="#' + element.id + '"]')
+    this.transitioning = null
+
+    if (this.options.parent) {
+      this.$parent = this.getParent()
+    } else {
+      this.addAriaAndCollapsedClass(this.$element, this.$trigger)
+    }
+
+    if (this.options.toggle) this.toggle()
+  }
+
+  Collapse.VERSION  = '3.3.6'
+
+  Collapse.TRANSITION_DURATION = 350
+
+  Collapse.DEFAULTS = {
+    toggle: true
+  }
+
+  Collapse.prototype.dimension = function () {
+    var hasWidth = this.$element.hasClass('width')
+    return hasWidth ? 'width' : 'height'
+  }
+
+  Collapse.prototype.show = function () {
+    if (this.transitioning || this.$element.hasClass('in')) return
+
+    var activesData
+    var actives = this.$parent && this.$parent.children('.panel').children('.in, .collapsing')
+
+    if (actives && actives.length) {
+      activesData = actives.data('bs.collapse')
+      if (activesData && activesData.transitioning) return
+    }
+
+    var startEvent = $.Event('show.bs.collapse')
+    this.$element.trigger(startEvent)
+    if (startEvent.isDefaultPrevented()) return
+
+    if (actives && actives.length) {
+      Plugin.call(actives, 'hide')
+      activesData || actives.data('bs.collapse', null)
+    }
+
+    var dimension = this.dimension()
+
+    this.$element
+      .removeClass('collapse')
+      .addClass('collapsing')[dimension](0)
+      .attr('aria-expanded', true)
+
+    this.$trigger
+      .removeClass('collapsed')
+      .attr('aria-expanded', true)
+
+    this.transitioning = 1
+
+    var complete = function () {
+      this.$element
+        .removeClass('collapsing')
+        .addClass('collapse in')[dimension]('')
+      this.transitioning = 0
+      this.$element
+        .trigger('shown.bs.collapse')
+    }
+
+    if (!$.support.transition) return complete.call(this)
+
+    var scrollSize = $.camelCase(['scroll', dimension].join('-'))
+
+    this.$element
+      .one('bsTransitionEnd', $.proxy(complete, this))
+      .emulateTransitionEnd(Collapse.TRANSITION_DURATION)[dimension](this.$element[0][scrollSize])
+  }
+
+  Collapse.prototype.hide = function () {
+    if (this.transitioning || !this.$element.hasClass('in')) return
+
+    var startEvent = $.Event('hide.bs.collapse')
+    this.$element.trigger(startEvent)
+    if (startEvent.isDefaultPrevented()) return
+
+    var dimension = this.dimension()
+
+    this.$element[dimension](this.$element[dimension]())[0].offsetHeight
+
+    this.$element
+      .addClass('collapsing')
+      .removeClass('collapse in')
+      .attr('aria-expanded', false)
+
+    this.$trigger
+      .addClass('collapsed')
+      .attr('aria-expanded', false)
+
+    this.transitioning = 1
+
+    var complete = function () {
+      this.transitioning = 0
+      this.$element
+        .removeClass('collapsing')
+        .addClass('collapse')
+        .trigger('hidden.bs.collapse')
+    }
+
+    if (!$.support.transition) return complete.call(this)
+
+    this.$element
+      [dimension](0)
+      .one('bsTransitionEnd', $.proxy(complete, this))
+      .emulateTransitionEnd(Collapse.TRANSITION_DURATION)
+  }
+
+  Collapse.prototype.toggle = function () {
+    this[this.$element.hasClass('in') ? 'hide' : 'show']()
+  }
+
+  Collapse.prototype.getParent = function () {
+    return $(this.options.parent)
+      .find('[data-toggle="collapse"][data-parent="' + this.options.parent + '"]')
+      .each($.proxy(function (i, element) {
+        var $element = $(element)
+        this.addAriaAndCollapsedClass(getTargetFromTrigger($element), $element)
+      }, this))
+      .end()
+  }
+
+  Collapse.prototype.addAriaAndCollapsedClass = function ($element, $trigger) {
+    var isOpen = $element.hasClass('in')
+
+    $element.attr('aria-expanded', isOpen)
+    $trigger
+      .toggleClass('collapsed', !isOpen)
+      .attr('aria-expanded', isOpen)
+  }
+
+  function getTargetFromTrigger($trigger) {
+    var href
+    var target = $trigger.attr('data-target')
+      || (href = $trigger.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '') // strip for ie7
+
+    return $(target)
+  }
+
+
+  // COLLAPSE PLUGIN DEFINITION
+  // ==========================
+
+  function Plugin(option) {
+    return this.each(function () {
+      var $this   = $(this)
+      var data    = $this.data('bs.collapse')
+      var options = $.extend({}, Collapse.DEFAULTS, $this.data(), typeof option == 'object' && option)
+
+      if (!data && options.toggle && /show|hide/.test(option)) options.toggle = false
+      if (!data) $this.data('bs.collapse', (data = new Collapse(this, options)))
+      if (typeof option == 'string') data[option]()
+    })
+  }
+
+  var old = $.fn.collapse
+
+  $.fn.collapse             = Plugin
+  $.fn.collapse.Constructor = Collapse
+
+
+  // COLLAPSE NO CONFLICT
+  // ====================
+
+  $.fn.collapse.noConflict = function () {
+    $.fn.collapse = old
+    return this
+  }
+
+
+  // COLLAPSE DATA-API
+  // =================
+
+  $(document).on('click.bs.collapse.data-api', '[data-toggle="collapse"]', function (e) {
+    var $this   = $(this)
+
+    if (!$this.attr('data-target')) e.preventDefault()
+
+    var $target = getTargetFromTrigger($this)
+    var data    = $target.data('bs.collapse')
+    var option  = data ? 'toggle' : $this.data()
+
+    Plugin.call($target, option)
+  })
+
+}(jQuery);
+
+/* ========================================================================
+ * Bootstrap: dropdown.js v3.3.6
+ * http://getbootstrap.com/javascript/#dropdowns
+ * ========================================================================
+ * Copyright 2011-2015 Twitter, Inc.
+ * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
+ * ======================================================================== */
+
+
++function ($) {
+  'use strict';
+
+  // DROPDOWN CLASS DEFINITION
+  // =========================
+
+  var backdrop = '.dropdown-backdrop'
+  var toggle   = '[data-toggle="dropdown"]'
+  var Dropdown = function (element) {
+    $(element).on('click.bs.dropdown', this.toggle)
+  }
+
+  Dropdown.VERSION = '3.3.6'
+
+  function getParent($this) {
+    var selector = $this.attr('data-target')
+
+    if (!selector) {
+      selector = $this.attr('href')
+      selector = selector && /#[A-Za-z]/.test(selector) && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7
+    }
+
+    var $parent = selector && $(selector)
+
+    return $parent && $parent.length ? $parent : $this.parent()
+  }
+
+  function clearMenus(e) {
+    if (e && e.which === 3) return
+    $(backdrop).remove()
+    $(toggle).each(function () {
+      var $this         = $(this)
+      var $parent       = getParent($this)
+      var relatedTarget = { relatedTarget: this }
+
+      if (!$parent.hasClass('open')) return
+
+      if (e && e.type == 'click' && /input|textarea/i.test(e.target.tagName) && $.contains($parent[0], e.target)) return
+
+      $parent.trigger(e = $.Event('hide.bs.dropdown', relatedTarget))
+
+      if (e.isDefaultPrevented()) return
+
+      $this.attr('aria-expanded', 'false')
+      $parent.removeClass('open').trigger($.Event('hidden.bs.dropdown', relatedTarget))
+    })
+  }
+
+  Dropdown.prototype.toggle = function (e) {
+    var $this = $(this)
+
+    if ($this.is('.disabled, :disabled')) return
+
+    var $parent  = getParent($this)
+    var isActive = $parent.hasClass('open')
+
+    clearMenus()
+
+    if (!isActive) {
+      if ('ontouchstart' in document.documentElement && !$parent.closest('.navbar-nav').length) {
+        // if mobile we use a backdrop because click events don't delegate
+        $(document.createElement('div'))
+          .addClass('dropdown-backdrop')
+          .insertAfter($(this))
+          .on('click', clearMenus)
+      }
+
+      var relatedTarget = { relatedTarget: this }
+      $parent.trigger(e = $.Event('show.bs.dropdown', relatedTarget))
+
+      if (e.isDefaultPrevented()) return
+
+      $this
+        .trigger('focus')
+        .attr('aria-expanded', 'true')
+
+      $parent
+        .toggleClass('open')
+        .trigger($.Event('shown.bs.dropdown', relatedTarget))
+    }
+
+    return false
+  }
+
+  Dropdown.prototype.keydown = function (e) {
+    if (!/(38|40|27|32)/.test(e.which) || /input|textarea/i.test(e.target.tagName)) return
+
+    var $this = $(this)
+
+    e.preventDefault()
+    e.stopPropagation()
+
+    if ($this.is('.disabled, :disabled')) return
+
+    var $parent  = getParent($this)
+    var isActive = $parent.hasClass('open')
+
+    if (!isActive && e.which != 27 || isActive && e.which == 27) {
+      if (e.which == 27) $parent.find(toggle).trigger('focus')
+      return $this.trigger('click')
+    }
+
+    var desc = ' li:not(.disabled):visible a'
+    var $items = $parent.find('.dropdown-menu' + desc)
+
+    if (!$items.length) return
+
+    var index = $items.index(e.target)
+
+    if (e.which == 38 && index > 0)                 index--         // up
+    if (e.which == 40 && index < $items.length - 1) index++         // down
+    if (!~index)                                    index = 0
+
+    $items.eq(index).trigger('focus')
+  }
+
+
+  // DROPDOWN PLUGIN DEFINITION
+  // ==========================
+
+  function Plugin(option) {
+    return this.each(function () {
+      var $this = $(this)
+      var data  = $this.data('bs.dropdown')
+
+      if (!data) $this.data('bs.dropdown', (data = new Dropdown(this)))
+      if (typeof option == 'string') data[option].call($this)
+    })
+  }
+
+  var old = $.fn.dropdown
+
+  $.fn.dropdown             = Plugin
+  $.fn.dropdown.Constructor = Dropdown
+
+
+  // DROPDOWN NO CONFLICT
+  // ====================
+
+  $.fn.dropdown.noConflict = function () {
+    $.fn.dropdown = old
+    return this
+  }
+
+
+  // APPLY TO STANDARD DROPDOWN ELEMENTS
+  // ===================================
+
+  $(document)
+    .on('click.bs.dropdown.data-api', clearMenus)
+    .on('click.bs.dropdown.data-api', '.dropdown form', function (e) { e.stopPropagation() })
+    .on('click.bs.dropdown.data-api', toggle, Dropdown.prototype.toggle)
+    .on('keydown.bs.dropdown.data-api', toggle, Dropdown.prototype.keydown)
+    .on('keydown.bs.dropdown.data-api', '.dropdown-menu', Dropdown.prototype.keydown)
+
+}(jQuery);
+
+/* ========================================================================
+ * Bootstrap: modal.js v3.3.6
+ * http://getbootstrap.com/javascript/#modals
+ * ========================================================================
+ * Copyright 2011-2015 Twitter, Inc.
+ * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
+ * ======================================================================== */
+
+
++function ($) {
+  'use strict';
+
+  // MODAL CLASS DEFINITION
+  // ======================
+
+  var Modal = function (element, options) {
+    this.options             = options
+    this.$body               = $(document.body)
+    this.$element            = $(element)
+    this.$dialog             = this.$element.find('.modal-dialog')
+    this.$backdrop           = null
+    this.isShown             = null
+    this.originalBodyPad     = null
+    this.scrollbarWidth      = 0
+    this.ignoreBackdropClick = false
+
+    if (this.options.remote) {
+      this.$element
+        .find('.modal-content')
+        .load(this.options.remote, $.proxy(function () {
+          this.$element.trigger('loaded.bs.modal')
+        }, this))
+    }
+  }
+
+  Modal.VERSION  = '3.3.6'
+
+  Modal.TRANSITION_DURATION = 300
+  Modal.BACKDROP_TRANSITION_DURATION = 150
+
+  Modal.DEFAULTS = {
+    backdrop: true,
+    keyboard: true,
+    show: true
+  }
+
+  Modal.prototype.toggle = function (_relatedTarget) {
+    return this.isShown ? this.hide() : this.show(_relatedTarget)
+  }
+
+  Modal.prototype.show = function (_relatedTarget) {
+    var that = this
+    var e    = $.Event('show.bs.modal', { relatedTarget: _relatedTarget })
+
+    this.$element.trigger(e)
+
+    if (this.isShown || e.isDefaultPrevented()) return
+
+    this.isShown = true
+
+    this.checkScrollbar()
+    this.setScrollbar()
+    this.$body.addClass('modal-open')
+
+    this.escape()
+    this.resize()
+
+    this.$element.on('click.dismiss.bs.modal', '[data-dismiss="modal"]', $.proxy(this.hide, this))
+
+    this.$dialog.on('mousedown.dismiss.bs.modal', function () {
+      that.$element.one('mouseup.dismiss.bs.modal', function (e) {
+        if ($(e.target).is(that.$element)) that.ignoreBackdropClick = true
+      })
+    })
+
+    this.backdrop(function () {
+      var transition = $.support.transition && that.$element.hasClass('fade')
+
+      if (!that.$element.parent().length) {
+        that.$element.appendTo(that.$body) // don't move modals dom position
+      }
+
+      that.$element
+        .show()
+        .scrollTop(0)
+
+      that.adjustDialog()
+
+      if (transition) {
+        that.$element[0].offsetWidth // force reflow
+      }
+
+      that.$element.addClass('in')
+
+      that.enforceFocus()
+
+      var e = $.Event('shown.bs.modal', { relatedTarget: _relatedTarget })
+
+      transition ?
+        that.$dialog // wait for modal to slide in
+          .one('bsTransitionEnd', function () {
+            that.$element.trigger('focus').trigger(e)
+          })
+          .emulateTransitionEnd(Modal.TRANSITION_DURATION) :
+        that.$element.trigger('focus').trigger(e)
+    })
+  }
+
+  Modal.prototype.hide = function (e) {
+    if (e) e.preventDefault()
+
+    e = $.Event('hide.bs.modal')
+
+    this.$element.trigger(e)
+
+    if (!this.isShown || e.isDefaultPrevented()) return
+
+    this.isShown = false
+
+    this.escape()
+    this.resize()
+
+    $(document).off('focusin.bs.modal')
+
+    this.$element
+      .removeClass('in')
+      .off('click.dismiss.bs.modal')
+      .off('mouseup.dismiss.bs.modal')
+
+    this.$dialog.off('mousedown.dismiss.bs.modal')
+
+    $.support.transition && this.$element.hasClass('fade') ?
+      this.$element
+        .one('bsTransitionEnd', $.proxy(this.hideModal, this))
+        .emulateTransitionEnd(Modal.TRANSITION_DURATION) :
+      this.hideModal()
+  }
+
+  Modal.prototype.enforceFocus = function () {
+    $(document)
+      .off('focusin.bs.modal') // guard against infinite focus loop
+      .on('focusin.bs.modal', $.proxy(function (e) {
+        if (this.$element[0] !== e.target && !this.$element.has(e.target).length) {
+          this.$element.trigger('focus')
+        }
+      }, this))
+  }
+
+  Modal.prototype.escape = function () {
+    if (this.isShown && this.options.keyboard) {
+      this.$element.on('keydown.dismiss.bs.modal', $.proxy(function (e) {
+        e.which == 27 && this.hide()
+      }, this))
+    } else if (!this.isShown) {
+      this.$element.off('keydown.dismiss.bs.modal')
+    }
+  }
+
+  Modal.prototype.resize = function () {
+    if (this.isShown) {
+      $(window).on('resize.bs.modal', $.proxy(this.handleUpdate, this))
+    } else {
+      $(window).off('resize.bs.modal')
+    }
+  }
+
+  Modal.prototype.hideModal = function () {
+    var that = this
+    this.$element.hide()
+    this.backdrop(function () {
+      that.$body.removeClass('modal-open')
+      that.resetAdjustments()
+      that.resetScrollbar()
+      that.$element.trigger('hidden.bs.modal')
+    })
+  }
+
+  Modal.prototype.removeBackdrop = function () {
+    this.$backdrop && this.$backdrop.remove()
+    this.$backdrop = null
+  }
+
+  Modal.prototype.backdrop = function (callback) {
+    var that = this
+    var animate = this.$element.hasClass('fade') ? 'fade' : ''
+
+    if (this.isShown && this.options.backdrop) {
+      var doAnimate = $.support.transition && animate
+
+      this.$backdrop = $(document.createElement('div'))
+        .addClass('modal-backdrop ' + animate)
+        .appendTo(this.$body)
+
+      this.$element.on('click.dismiss.bs.modal', $.proxy(function (e) {
+        if (this.ignoreBackdropClick) {
+          this.ignoreBackdropClick = false
+          return
+        }
+        if (e.target !== e.currentTarget) return
+        this.options.backdrop == 'static'
+          ? this.$element[0].focus()
+          : this.hide()
+      }, this))
+
+      if (doAnimate) this.$backdrop[0].offsetWidth // force reflow
+
+      this.$backdrop.addClass('in')
+
+      if (!callback) return
+
+      doAnimate ?
+        this.$backdrop
+          .one('bsTransitionEnd', callback)
+          .emulateTransitionEnd(Modal.BACKDROP_TRANSITION_DURATION) :
+        callback()
+
+    } else if (!this.isShown && this.$backdrop) {
+      this.$backdrop.removeClass('in')
+
+      var callbackRemove = function () {
+        that.removeBackdrop()
+        callback && callback()
+      }
+      $.support.transition && this.$element.hasClass('fade') ?
+        this.$backdrop
+          .one('bsTransitionEnd', callbackRemove)
+          .emulateTransitionEnd(Modal.BACKDROP_TRANSITION_DURATION) :
+        callbackRemove()
+
+    } else if (callback) {
+      callback()
+    }
+  }
+
+  // these following methods are used to handle overflowing modals
+
+  Modal.prototype.handleUpdate = function () {
+    this.adjustDialog()
+  }
+
+  Modal.prototype.adjustDialog = function () {
+    var modalIsOverflowing = this.$element[0].scrollHeight > document.documentElement.clientHeight
+
+    this.$element.css({
+      paddingLeft:  !this.bodyIsOverflowing && modalIsOverflowing ? this.scrollbarWidth : '',
+      paddingRight: this.bodyIsOverflowing && !modalIsOverflowing ? this.scrollbarWidth : ''
+    })
+  }
+
+  Modal.prototype.resetAdjustments = function () {
+    this.$element.css({
+      paddingLeft: '',
+      paddingRight: ''
+    })
+  }
+
+  Modal.prototype.checkScrollbar = function () {
+    var fullWindowWidth = window.innerWidth
+    if (!fullWindowWidth) { // workaround for missing window.innerWidth in IE8
+      var documentElementRect = document.documentElement.getBoundingClientRect()
+      fullWindowWidth = documentElementRect.right - Math.abs(documentElementRect.left)
+    }
+    this.bodyIsOverflowing = document.body.clientWidth < fullWindowWidth
+    this.scrollbarWidth = this.measureScrollbar()
+  }
+
+  Modal.prototype.setScrollbar = function () {
+    var bodyPad = parseInt((this.$body.css('padding-right') || 0), 10)
+    this.originalBodyPad = document.body.style.paddingRight || ''
+    if (this.bodyIsOverflowing) this.$body.css('padding-right', bodyPad + this.scrollbarWidth)
+  }
+
+  Modal.prototype.resetScrollbar = function () {
+    this.$body.css('padding-right', this.originalBodyPad)
+  }
+
+  Modal.prototype.measureScrollbar = function () { // thx walsh
+    var scrollDiv = document.createElement('div')
+    scrollDiv.className = 'modal-scrollbar-measure'
+    this.$body.append(scrollDiv)
+    var scrollbarWidth = scrollDiv.offsetWidth - scrollDiv.clientWidth
+    this.$body[0].removeChild(scrollDiv)
+    return scrollbarWidth
+  }
+
+
+  // MODAL PLUGIN DEFINITION
+  // =======================
+
+  function Plugin(option, _relatedTarget) {
+    return this.each(function () {
+      var $this   = $(this)
+      var data    = $this.data('bs.modal')
+      var options = $.extend({}, Modal.DEFAULTS, $this.data(), typeof option == 'object' && option)
+
+      if (!data) $this.data('bs.modal', (data = new Modal(this, options)))
+      if (typeof option == 'string') data[option](_relatedTarget)
+      else if (options.show) data.show(_relatedTarget)
+    })
+  }
+
+  var old = $.fn.modal
+
+  $.fn.modal             = Plugin
+  $.fn.modal.Constructor = Modal
+
+
+  // MODAL NO CONFLICT
+  // =================
+
+  $.fn.modal.noConflict = function () {
+    $.fn.modal = old
+    return this
+  }
+
+
+  // MODAL DATA-API
+  // ==============
+
+  $(document).on('click.bs.modal.data-api', '[data-toggle="modal"]', function (e) {
+    var $this   = $(this)
+    var href    = $this.attr('href')
+    var $target = $($this.attr('data-target') || (href && href.replace(/.*(?=#[^\s]+$)/, ''))) // strip for ie7
+    var option  = $target.data('bs.modal') ? 'toggle' : $.extend({ remote: !/#/.test(href) && href }, $target.data(), $this.data())
+
+    if ($this.is('a')) e.preventDefault()
+
+    $target.one('show.bs.modal', function (showEvent) {
+      if (showEvent.isDefaultPrevented()) return // only register focus restorer if modal will actually get shown
+      $target.one('hidden.bs.modal', function () {
+        $this.is(':visible') && $this.trigger('focus')
+      })
+    })
+    Plugin.call($target, option, this)
+  })
+
+}(jQuery);
+
+/* ========================================================================
+ * Bootstrap: tooltip.js v3.3.6
+ * http://getbootstrap.com/javascript/#tooltip
+ * Inspired by the original jQuery.tipsy by Jason Frame
+ * ========================================================================
+ * Copyright 2011-2015 Twitter, Inc.
+ * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
+ * ======================================================================== */
+
+
++function ($) {
+  'use strict';
+
+  // TOOLTIP PUBLIC CLASS DEFINITION
+  // ===============================
+
+  var Tooltip = function (element, options) {
+    this.type       = null
+    this.options    = null
+    this.enabled    = null
+    this.timeout    = null
+    this.hoverState = null
+    this.$element   = null
+    this.inState    = null
+
+    this.init('tooltip', element, options)
+  }
+
+  Tooltip.VERSION  = '3.3.6'
+
+  Tooltip.TRANSITION_DURATION = 150
+
+  Tooltip.DEFAULTS = {
+    animation: true,
+    placement: 'top',
+    selector: false,
+    template: '<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',
+    trigger: 'hover focus',
+    title: '',
+    delay: 0,
+    html: false,
+    container: false,
+    viewport: {
+      selector: 'body',
+      padding: 0
+    }
+  }
+
+  Tooltip.prototype.init = function (type, element, options) {
+    this.enabled   = true
+    this.type      = type
+    this.$element  = $(element)
+    this.options   = this.getOptions(options)
+    this.$viewport = this.options.viewport && $($.isFunction(this.options.viewport) ? this.options.viewport.call(this, this.$element) : (this.options.viewport.selector || this.options.viewport))
+    this.inState   = { click: false, hover: false, focus: false }
+
+    if (this.$element[0] instanceof document.constructor && !this.options.selector) {
+      throw new Error('`selector` option must be specified when initializing ' + this.type + ' on the window.document object!')
+    }
+
+    var triggers = this.options.trigger.split(' ')
+
+    for (var i = triggers.length; i--;) {
+      var trigger = triggers[i]
+
+      if (trigger == 'click') {
+        this.$element.on('click.' + this.type, this.options.selector, $.proxy(this.toggle, this))
+      } else if (trigger != 'manual') {
+        var eventIn  = trigger == 'hover' ? 'mouseenter' : 'focusin'
+        var eventOut = trigger == 'hover' ? 'mouseleave' : 'focusout'
+
+        this.$element.on(eventIn  + '.' + this.type, this.options.selector, $.proxy(this.enter, this))
+        this.$element.on(eventOut + '.' + this.type, this.options.selector, $.proxy(this.leave, this))
+      }
+    }
+
+    this.options.selector ?
+      (this._options = $.extend({}, this.options, { trigger: 'manual', selector: '' })) :
+      this.fixTitle()
+  }
+
+  Tooltip.prototype.getDefaults = function () {
+    return Tooltip.DEFAULTS
+  }
+
+  Tooltip.prototype.getOptions = function (options) {
+    options = $.extend({}, this.getDefaults(), this.$element.data(), options)
+
+    if (options.delay && typeof options.delay == 'number') {
+      options.delay = {
+        show: options.delay,
+        hide: options.delay
+      }
+    }
+
+    return options
+  }
+
+  Tooltip.prototype.getDelegateOptions = function () {
+    var options  = {}
+    var defaults = this.getDefaults()
+
+    this._options && $.each(this._options, function (key, value) {
+      if (defaults[key] != value) options[key] = value
+    })
+
+    return options
+  }
+
+  Tooltip.prototype.enter = function (obj) {
+    var self = obj instanceof this.constructor ?
+      obj : $(obj.currentTarget).data('bs.' + this.type)
+
+    if (!self) {
+      self = new this.constructor(obj.currentTarget, this.getDelegateOptions())
+      $(obj.currentTarget).data('bs.' + this.type, self)
+    }
+
+    if (obj instanceof $.Event) {
+      self.inState[obj.type == 'focusin' ? 'focus' : 'hover'] = true
+    }
+
+    if (self.tip().hasClass('in') || self.hoverState == 'in') {
+      self.hoverState = 'in'
+      return
+    }
+
+    clearTimeout(self.timeout)
+
+    self.hoverState = 'in'
+
+    if (!self.options.delay || !self.options.delay.show) return self.show()
+
+    self.timeout = setTimeout(function () {
+      if (self.hoverState == 'in') self.show()
+    }, self.options.delay.show)
+  }
+
+  Tooltip.prototype.isInStateTrue = function () {
+    for (var key in this.inState) {
+      if (this.inState[key]) return true
+    }
+
+    return false
+  }
+
+  Tooltip.prototype.leave = function (obj) {
+    var self = obj instanceof this.constructor ?
+      obj : $(obj.currentTarget).data('bs.' + this.type)
+
+    if (!self) {
+      self = new this.constructor(obj.currentTarget, this.getDelegateOptions())
+      $(obj.currentTarget).data('bs.' + this.type, self)
+    }
+
+    if (obj instanceof $.Event) {
+      self.inState[obj.type == 'focusout' ? 'focus' : 'hover'] = false
+    }
+
+    if (self.isInStateTrue()) return
+
+    clearTimeout(self.timeout)
+
+    self.hoverState = 'out'
+
+    if (!self.options.delay || !self.options.delay.hide) return self.hide()
+
+    self.timeout = setTimeout(function () {
+      if (self.hoverState == 'out') self.hide()
+    }, self.options.delay.hide)
+  }
+
+  Tooltip.prototype.show = function () {
+    var e = $.Event('show.bs.' + this.type)
+
+    if (this.hasContent() && this.enabled) {
+      this.$element.trigger(e)
+
+      var inDom = $.contains(this.$element[0].ownerDocument.documentElement, this.$element[0])
+      if (e.isDefaultPrevented() || !inDom) return
+      var that = this
+
+      var $tip = this.tip()
+
+      var tipId = this.getUID(this.type)
+
+      this.setContent()
+      $tip.attr('id', tipId)
+      this.$element.attr('aria-describedby', tipId)
+
+      if (this.options.animation) $tip.addClass('fade')
+
+      var placement = typeof this.options.placement == 'function' ?
+        this.options.placement.call(this, $tip[0], this.$element[0]) :
+        this.options.placement
+
+      var autoToken = /\s?auto?\s?/i
+      var autoPlace = autoToken.test(placement)
+      if (autoPlace) placement = placement.replace(autoToken, '') || 'top'
+
+      $tip
+        .detach()
+        .css({ top: 0, left: 0, display: 'block' })
+        .addClass(placement)
+        .data('bs.' + this.type, this)
+
+      this.options.container ? $tip.appendTo(this.options.container) : $tip.insertAfter(this.$element)
+      this.$element.trigger('inserted.bs.' + this.type)
+
+      var pos          = this.getPosition()
+      var actualWidth  = $tip[0].offsetWidth
+      var actualHeight = $tip[0].offsetHeight
+
+      if (autoPlace) {
+        var orgPlacement = placement
+        var viewportDim = this.getPosition(this.$viewport)
+
+        placement = placement == 'bottom' && pos.bottom + actualHeight > viewportDim.bottom ? 'top'    :
+                    placement == 'top'    && pos.top    - actualHeight < viewportDim.top    ? 'bottom' :
+                    placement == 'right'  && pos.right  + actualWidth  > viewportDim.width  ? 'left'   :
+                    placement == 'left'   && pos.left   - actualWidth  < viewportDim.left   ? 'right'  :
+                    placement
+
+        $tip
+          .removeClass(orgPlacement)
+          .addClass(placement)
+      }
+
+      var calculatedOffset = this.getCalculatedOffset(placement, pos, actualWidth, actualHeight)
+
+      this.applyPlacement(calculatedOffset, placement)
+
+      var complete = function () {
+        var prevHoverState = that.hoverState
+        that.$element.trigger('shown.bs.' + that.type)
+        that.hoverState = null
+
+        if (prevHoverState == 'out') that.leave(that)
+      }
+
+      $.support.transition && this.$tip.hasClass('fade') ?
+        $tip
+          .one('bsTransitionEnd', complete)
+          .emulateTransitionEnd(Tooltip.TRANSITION_DURATION) :
+        complete()
+    }
+  }
+
+  Tooltip.prototype.applyPlacement = function (offset, placement) {
+    var $tip   = this.tip()
+    var width  = $tip[0].offsetWidth
+    var height = $tip[0].offsetHeight
+
+    // manually read margins because getBoundingClientRect includes difference
+    var marginTop = parseInt($tip.css('margin-top'), 10)
+    var marginLeft = parseInt($tip.css('margin-left'), 10)
+
+    // we must check for NaN for ie 8/9
+    if (isNaN(marginTop))  marginTop  = 0
+    if (isNaN(marginLeft)) marginLeft = 0
+
+    offset.top  += marginTop
+    offset.left += marginLeft
+
+    // $.fn.offset doesn't round pixel values
+    // so we use setOffset directly with our own function B-0
+    $.offset.setOffset($tip[0], $.extend({
+      using: function (props) {
+        $tip.css({
+          top: Math.round(props.top),
+          left: Math.round(props.left)
+        })
+      }
+    }, offset), 0)
+
+    $tip.addClass('in')
+
+    // check to see if placing tip in new offset caused the tip to resize itself
+    var actualWidth  = $tip[0].offsetWidth
+    var actualHeight = $tip[0].offsetHeight
+
+    if (placement == 'top' && actualHeight != height) {
+      offset.top = offset.top + height - actualHeight
+    }
+
+    var delta = this.getViewportAdjustedDelta(placement, offset, actualWidth, actualHeight)
+
+    if (delta.left) offset.left += delta.left
+    else offset.top += delta.top
+
+    var isVertical          = /top|bottom/.test(placement)
+    var arrowDelta          = isVertical ? delta.left * 2 - width + actualWidth : delta.top * 2 - height + actualHeight
+    var arrowOffsetPosition = isVertical ? 'offsetWidth' : 'offsetHeight'
+
+    $tip.offset(offset)
+    this.replaceArrow(arrowDelta, $tip[0][arrowOffsetPosition], isVertical)
+  }
+
+  Tooltip.prototype.replaceArrow = function (delta, dimension, isVertical) {
+    this.arrow()
+      .css(isVertical ? 'left' : 'top', 50 * (1 - delta / dimension) + '%')
+      .css(isVertical ? 'top' : 'left', '')
+  }
+
+  Tooltip.prototype.setContent = function () {
+    var $tip  = this.tip()
+    var title = this.getTitle()
+
+    $tip.find('.tooltip-inner')[this.options.html ? 'html' : 'text'](title)
+    $tip.removeClass('fade in top bottom left right')
+  }
+
+  Tooltip.prototype.hide = function (callback) {
+    var that = this
+    var $tip = $(this.$tip)
+    var e    = $.Event('hide.bs.' + this.type)
+
+    function complete() {
+      if (that.hoverState != 'in') $tip.detach()
+      that.$element
+        .removeAttr('aria-describedby')
+        .trigger('hidden.bs.' + that.type)
+      callback && callback()
+    }
+
+    this.$element.trigger(e)
+
+    if (e.isDefaultPrevented()) return
+
+    $tip.removeClass('in')
+
+    $.support.transition && $tip.hasClass('fade') ?
+      $tip
+        .one('bsTransitionEnd', complete)
+        .emulateTransitionEnd(Tooltip.TRANSITION_DURATION) :
+      complete()
+
+    this.hoverState = null
+
+    return this
+  }
+
+  Tooltip.prototype.fixTitle = function () {
+    var $e = this.$element
+    if ($e.attr('title') || typeof $e.attr('data-original-title') != 'string') {
+      $e.attr('data-original-title', $e.attr('title') || '').attr('title', '')
+    }
+  }
+
+  Tooltip.prototype.hasContent = function () {
+    return this.getTitle()
+  }
+
+  Tooltip.prototype.getPosition = function ($element) {
+    $element   = $element || this.$element
+
+    var el     = $element[0]
+    var isBody = el.tagName == 'BODY'
+
+    var elRect    = el.getBoundingClientRect()
+    if (elRect.width == null) {
+      // width and height are missing in IE8, so compute them manually; see https://github.com/twbs/bootstrap/issues/14093
+      elRect = $.extend({}, elRect, { width: elRect.right - elRect.left, height: elRect.bottom - elRect.top })
+    }
+    var elOffset  = isBody ? { top: 0, left: 0 } : $element.offset()
+    var scroll    = { scroll: isBody ? document.documentElement.scrollTop || document.body.scrollTop : $element.scrollTop() }
+    var outerDims = isBody ? { width: $(window).width(), height: $(window).height() } : null
+
+    return $.extend({}, elRect, scroll, outerDims, elOffset)
+  }
+
+  Tooltip.prototype.getCalculatedOffset = function (placement, pos, actualWidth, actualHeight) {
+    return placement == 'bottom' ? { top: pos.top + pos.height,   left: pos.left + pos.width / 2 - actualWidth / 2 } :
+           placement == 'top'    ? { top: pos.top - actualHeight, left: pos.left + pos.width / 2 - actualWidth / 2 } :
+           placement == 'left'   ? { top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left - actualWidth } :
+        /* placement == 'right' */ { top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left + pos.width }
+
+  }
+
+  Tooltip.prototype.getViewportAdjustedDelta = function (placement, pos, actualWidth, actualHeight) {
+    var delta = { top: 0, left: 0 }
+    if (!this.$viewport) return delta
+
+    var viewportPadding = this.options.viewport && this.options.viewport.padding || 0
+    var viewportDimensions = this.getPosition(this.$viewport)
+
+    if (/right|left/.test(placement)) {
+      var topEdgeOffset    = pos.top - viewportPadding - viewportDimensions.scroll
+      var bottomEdgeOffset = pos.top + viewportPadding - viewportDimensions.scroll + actualHeight
+      if (topEdgeOffset < viewportDimensions.top) { // top overflow
+        delta.top = viewportDimensions.top - topEdgeOffset
+      } else if (bottomEdgeOffset > viewportDimensions.top + viewportDimensions.height) { // bottom overflow
+        delta.top = viewportDimensions.top + viewportDimensions.height - bottomEdgeOffset
+      }
+    } else {
+      var leftEdgeOffset  = pos.left - viewportPadding
+      var rightEdgeOffset = pos.left + viewportPadding + actualWidth
+      if (leftEdgeOffset < viewportDimensions.left) { // left overflow
+        delta.left = viewportDimensions.left - leftEdgeOffset
+      } else if (rightEdgeOffset > viewportDimensions.right) { // right overflow
+        delta.left = viewportDimensions.left + viewportDimensions.width - rightEdgeOffset
+      }
+    }
+
+    return delta
+  }
+
+  Tooltip.prototype.getTitle = function () {
+    var title
+    var $e = this.$element
+    var o  = this.options
+
+    title = $e.attr('data-original-title')
+      || (typeof o.title == 'function' ? o.title.call($e[0]) :  o.title)
+
+    return title
+  }
+
+  Tooltip.prototype.getUID = function (prefix) {
+    do prefix += ~~(Math.random() * 1000000)
+    while (document.getElementById(prefix))
+    return prefix
+  }
+
+  Tooltip.prototype.tip = function () {
+    if (!this.$tip) {
+      this.$tip = $(this.options.template)
+      if (this.$tip.length != 1) {
+        throw new Error(this.type + ' `template` option must consist of exactly 1 top-level element!')
+      }
+    }
+    return this.$tip
+  }
+
+  Tooltip.prototype.arrow = function () {
+    return (this.$arrow = this.$arrow || this.tip().find('.tooltip-arrow'))
+  }
+
+  Tooltip.prototype.enable = function () {
+    this.enabled = true
+  }
+
+  Tooltip.prototype.disable = function () {
+    this.enabled = false
+  }
+
+  Tooltip.prototype.toggleEnabled = function () {
+    this.enabled = !this.enabled
+  }
+
+  Tooltip.prototype.toggle = function (e) {
+    var self = this
+    if (e) {
+      self = $(e.currentTarget).data('bs.' + this.type)
+      if (!self) {
+        self = new this.constructor(e.currentTarget, this.getDelegateOptions())
+        $(e.currentTarget).data('bs.' + this.type, self)
+      }
+    }
+
+    if (e) {
+      self.inState.click = !self.inState.click
+      if (self.isInStateTrue()) self.enter(self)
+      else self.leave(self)
+    } else {
+      self.tip().hasClass('in') ? self.leave(self) : self.enter(self)
+    }
+  }
+
+  Tooltip.prototype.destroy = function () {
+    var that = this
+    clearTimeout(this.timeout)
+    this.hide(function () {
+      that.$element.off('.' + that.type).removeData('bs.' + that.type)
+      if (that.$tip) {
+        that.$tip.detach()
+      }
+      that.$tip = null
+      that.$arrow = null
+      that.$viewport = null
+    })
+  }
+
+
+  // TOOLTIP PLUGIN DEFINITION
+  // =========================
+
+  function Plugin(option) {
+    return this.each(function () {
+      var $this   = $(this)
+      var data    = $this.data('bs.tooltip')
+      var options = typeof option == 'object' && option
+
+      if (!data && /destroy|hide/.test(option)) return
+      if (!data) $this.data('bs.tooltip', (data = new Tooltip(this, options)))
+      if (typeof option == 'string') data[option]()
+    })
+  }
+
+  var old = $.fn.tooltip
+
+  $.fn.tooltip             = Plugin
+  $.fn.tooltip.Constructor = Tooltip
+
+
+  // TOOLTIP NO CONFLICT
+  // ===================
+
+  $.fn.tooltip.noConflict = function () {
+    $.fn.tooltip = old
+    return this
+  }
+
+}(jQuery);
+
+/* ========================================================================
+ * Bootstrap: popover.js v3.3.6
+ * http://getbootstrap.com/javascript/#popovers
+ * ========================================================================
+ * Copyright 2011-2015 Twitter, Inc.
+ * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
+ * ======================================================================== */
+
+
++function ($) {
+  'use strict';
+
+  // POPOVER PUBLIC CLASS DEFINITION
+  // ===============================
+
+  var Popover = function (element, options) {
+    this.init('popover', element, options)
+  }
+
+  if (!$.fn.tooltip) throw new Error('Popover requires tooltip.js')
+
+  Popover.VERSION  = '3.3.6'
+
+  Popover.DEFAULTS = $.extend({}, $.fn.tooltip.Constructor.DEFAULTS, {
+    placement: 'right',
+    trigger: 'click',
+    content: '',
+    template: '<div class="popover" role="tooltip"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'
+  })
+
+
+  // NOTE: POPOVER EXTENDS tooltip.js
+  // ================================
+
+  Popover.prototype = $.extend({}, $.fn.tooltip.Constructor.prototype)
+
+  Popover.prototype.constructor = Popover
+
+  Popover.prototype.getDefaults = function () {
+    return Popover.DEFAULTS
+  }
+
+  Popover.prototype.setContent = function () {
+    var $tip    = this.tip()
+    var title   = this.getTitle()
+    var content = this.getContent()
+
+    $tip.find('.popover-title')[this.options.html ? 'html' : 'text'](title)
+    $tip.find('.popover-content').children().detach().end()[ // we use append for html objects to maintain js events
+      this.options.html ? (typeof content == 'string' ? 'html' : 'append') : 'text'
+    ](content)
+
+    $tip.removeClass('fade top bottom left right in')
+
+    // IE8 doesn't accept hiding via the `:empty` pseudo selector, we have to do
+    // this manually by checking the contents.
+    if (!$tip.find('.popover-title').html()) $tip.find('.popover-title').hide()
+  }
+
+  Popover.prototype.hasContent = function () {
+    return this.getTitle() || this.getContent()
+  }
+
+  Popover.prototype.getContent = function () {
+    var $e = this.$element
+    var o  = this.options
+
+    return $e.attr('data-content')
+      || (typeof o.content == 'function' ?
+            o.content.call($e[0]) :
+            o.content)
+  }
+
+  Popover.prototype.arrow = function () {
+    return (this.$arrow = this.$arrow || this.tip().find('.arrow'))
+  }
+
+
+  // POPOVER PLUGIN DEFINITION
+  // =========================
+
+  function Plugin(option) {
+    return this.each(function () {
+      var $this   = $(this)
+      var data    = $this.data('bs.popover')
+      var options = typeof option == 'object' && option
+
+      if (!data && /destroy|hide/.test(option)) return
+      if (!data) $this.data('bs.popover', (data = new Popover(this, options)))
+      if (typeof option == 'string') data[option]()
+    })
+  }
+
+  var old = $.fn.popover
+
+  $.fn.popover             = Plugin
+  $.fn.popover.Constructor = Popover
+
+
+  // POPOVER NO CONFLICT
+  // ===================
+
+  $.fn.popover.noConflict = function () {
+    $.fn.popover = old
+    return this
+  }
+
+}(jQuery);
+
+/* ========================================================================
+ * Bootstrap: scrollspy.js v3.3.6
+ * http://getbootstrap.com/javascript/#scrollspy
+ * ========================================================================
+ * Copyright 2011-2015 Twitter, Inc.
+ * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
+ * ======================================================================== */
+
+
++function ($) {
+  'use strict';
+
+  // SCROLLSPY CLASS DEFINITION
+  // ==========================
+
+  function ScrollSpy(element, options) {
+    this.$body          = $(document.body)
+    this.$scrollElement = $(element).is(document.body) ? $(window) : $(element)
+    this.options        = $.extend({}, ScrollSpy.DEFAULTS, options)
+    this.selector       = (this.options.target || '') + ' .nav li > a'
+    this.offsets        = []
+    this.targets        = []
+    this.activeTarget   = null
+    this.scrollHeight   = 0
+
+    this.$scrollElement.on('scroll.bs.scrollspy', $.proxy(this.process, this))
+    this.refresh()
+    this.process()
+  }
+
+  ScrollSpy.VERSION  = '3.3.6'
+
+  ScrollSpy.DEFAULTS = {
+    offset: 10
+  }
+
+  ScrollSpy.prototype.getScrollHeight = function () {
+    return this.$scrollElement[0].scrollHeight || Math.max(this.$body[0].scrollHeight, document.documentElement.scrollHeight)
+  }
+
+  ScrollSpy.prototype.refresh = function () {
+    var that          = this
+    var offsetMethod  = 'offset'
+    var offsetBase    = 0
+
+    this.offsets      = []
+    this.targets      = []
+    this.scrollHeight = this.getScrollHeight()
+
+    if (!$.isWindow(this.$scrollElement[0])) {
+      offsetMethod = 'position'
+      offsetBase   = this.$scrollElement.scrollTop()
+    }
+
+    this.$body
+      .find(this.selector)
+      .map(function () {
+        var $el   = $(this)
+        var href  = $el.data('target') || $el.attr('href')
+        var $href = /^#./.test(href) && $(href)
+
+        return ($href
+          && $href.length
+          && $href.is(':visible')
+          && [[$href[offsetMethod]().top + offsetBase, href]]) || null
+      })
+      .sort(function (a, b) { return a[0] - b[0] })
+      .each(function () {
+        that.offsets.push(this[0])
+        that.targets.push(this[1])
+      })
+  }
+
+  ScrollSpy.prototype.process = function () {
+    var scrollTop    = this.$scrollElement.scrollTop() + this.options.offset
+    var scrollHeight = this.getScrollHeight()
+    var maxScroll    = this.options.offset + scrollHeight - this.$scrollElement.height()
+    var offsets      = this.offsets
+    var targets      = this.targets
+    var activeTarget = this.activeTarget
+    var i
+
+    if (this.scrollHeight != scrollHeight) {
+      this.refresh()
+    }
+
+    if (scrollTop >= maxScroll) {
+      return activeTarget != (i = targets[targets.length - 1]) && this.activate(i)
+    }
+
+    if (activeTarget && scrollTop < offsets[0]) {
+      this.activeTarget = null
+      return this.clear()
+    }
+
+    for (i = offsets.length; i--;) {
+      activeTarget != targets[i]
+        && scrollTop >= offsets[i]
+        && (offsets[i + 1] === undefined || scrollTop < offsets[i + 1])
+        && this.activate(targets[i])
+    }
+  }
+
+  ScrollSpy.prototype.activate = function (target) {
+    this.activeTarget = target
+
+    this.clear()
+
+    var selector = this.selector +
+      '[data-target="' + target + '"],' +
+      this.selector + '[href="' + target + '"]'
+
+    var active = $(selector)
+      .parents('li')
+      .addClass('active')
+
+    if (active.parent('.dropdown-menu').length) {
+      active = active
+        .closest('li.dropdown')
+        .addClass('active')
+    }
+
+    active.trigger('activate.bs.scrollspy')
+  }
+
+  ScrollSpy.prototype.clear = function () {
+    $(this.selector)
+      .parentsUntil(this.options.target, '.active')
+      .removeClass('active')
+  }
+
+
+  // SCROLLSPY PLUGIN DEFINITION
+  // ===========================
+
+  function Plugin(option) {
+    return this.each(function () {
+      var $this   = $(this)
+      var data    = $this.data('bs.scrollspy')
+      var options = typeof option == 'object' && option
+
+      if (!data) $this.data('bs.scrollspy', (data = new ScrollSpy(this, options)))
+      if (typeof option == 'string') data[option]()
+    })
+  }
+
+  var old = $.fn.scrollspy
+
+  $.fn.scrollspy             = Plugin
+  $.fn.scrollspy.Constructor = ScrollSpy
+
+
+  // SCROLLSPY NO CONFLICT
+  // =====================
+
+  $.fn.scrollspy.noConflict = function () {
+    $.fn.scrollspy = old
+    return this
+  }
+
+
+  // SCROLLSPY DATA-API
+  // ==================
+
+  $(window).on('load.bs.scrollspy.data-api', function () {
+    $('[data-spy="scroll"]').each(function () {
+      var $spy = $(this)
+      Plugin.call($spy, $spy.data())
+    })
+  })
+
+}(jQuery);
+
+/* ========================================================================
+ * Bootstrap: tab.js v3.3.6
+ * http://getbootstrap.com/javascript/#tabs
+ * ========================================================================
+ * Copyright 2011-2015 Twitter, Inc.
+ * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
+ * ======================================================================== */
+
+
++function ($) {
+  'use strict';
+
+  // TAB CLASS DEFINITION
+  // ====================
+
+  var Tab = function (element) {
+    // jscs:disable requireDollarBeforejQueryAssignment
+    this.element = $(element)
+    // jscs:enable requireDollarBeforejQueryAssignment
+  }
+
+  Tab.VERSION = '3.3.6'
+
+  Tab.TRANSITION_DURATION = 150
+
+  Tab.prototype.show = function () {
+    var $this    = this.element
+    var $ul      = $this.closest('ul:not(.dropdown-menu)')
+    var selector = $this.data('target')
+
+    if (!selector) {
+      selector = $this.attr('href')
+      selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7
+    }
+
+    if ($this.parent('li').hasClass('active')) return
+
+    var $previous = $ul.find('.active:last a')
+    var hideEvent = $.Event('hide.bs.tab', {
+      relatedTarget: $this[0]
+    })
+    var showEvent = $.Event('show.bs.tab', {
+      relatedTarget: $previous[0]
+    })
+
+    $previous.trigger(hideEvent)
+    $this.trigger(showEvent)
+
+    if (showEvent.isDefaultPrevented() || hideEvent.isDefaultPrevented()) return
+
+    var $target = $(selector)
+
+    this.activate($this.closest('li'), $ul)
+    this.activate($target, $target.parent(), function () {
+      $previous.trigger({
+        type: 'hidden.bs.tab',
+        relatedTarget: $this[0]
+      })
+      $this.trigger({
+        type: 'shown.bs.tab',
+        relatedTarget: $previous[0]
+      })
+    })
+  }
+
+  Tab.prototype.activate = function (element, container, callback) {
+    var $active    = container.find('> .active')
+    var transition = callback
+      && $.support.transition
+      && ($active.length && $active.hasClass('fade') || !!container.find('> .fade').length)
+
+    function next() {
+      $active
+        .removeClass('active')
+        .find('> .dropdown-menu > .active')
+          .removeClass('active')
+        .end()
+        .find('[data-toggle="tab"]')
+          .attr('aria-expanded', false)
+
+      element
+        .addClass('active')
+        .find('[data-toggle="tab"]')
+          .attr('aria-expanded', true)
+
+      if (transition) {
+        element[0].offsetWidth // reflow for transition
+        element.addClass('in')
+      } else {
+        element.removeClass('fade')
+      }
+
+      if (element.parent('.dropdown-menu').length) {
+        element
+          .closest('li.dropdown')
+            .addClass('active')
+          .end()
+          .find('[data-toggle="tab"]')
+            .attr('aria-expanded', true)
+      }
+
+      callback && callback()
+    }
+
+    $active.length && transition ?
+      $active
+        .one('bsTransitionEnd', next)
+        .emulateTransitionEnd(Tab.TRANSITION_DURATION) :
+      next()
+
+    $active.removeClass('in')
+  }
+
+
+  // TAB PLUGIN DEFINITION
+  // =====================
+
+  function Plugin(option) {
+    return this.each(function () {
+      var $this = $(this)
+      var data  = $this.data('bs.tab')
+
+      if (!data) $this.data('bs.tab', (data = new Tab(this)))
+      if (typeof option == 'string') data[option]()
+    })
+  }
+
+  var old = $.fn.tab
+
+  $.fn.tab             = Plugin
+  $.fn.tab.Constructor = Tab
+
+
+  // TAB NO CONFLICT
+  // ===============
+
+  $.fn.tab.noConflict = function () {
+    $.fn.tab = old
+    return this
+  }
+
+
+  // TAB DATA-API
+  // ============
+
+  var clickHandler = function (e) {
+    e.preventDefault()
+    Plugin.call($(this), 'show')
+  }
+
+  $(document)
+    .on('click.bs.tab.data-api', '[data-toggle="tab"]', clickHandler)
+    .on('click.bs.tab.data-api', '[data-toggle="pill"]', clickHandler)
+
+}(jQuery);
+
+/* ========================================================================
+ * Bootstrap: affix.js v3.3.6
+ * http://getbootstrap.com/javascript/#affix
+ * ========================================================================
+ * Copyright 2011-2015 Twitter, Inc.
+ * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
+ * ======================================================================== */
+
+
++function ($) {
+  'use strict';
+
+  // AFFIX CLASS DEFINITION
+  // ======================
+
+  var Affix = function (element, options) {
+    this.options = $.extend({}, Affix.DEFAULTS, options)
+
+    this.$target = $(this.options.target)
+      .on('scroll.bs.affix.data-api', $.proxy(this.checkPosition, this))
+      .on('click.bs.affix.data-api',  $.proxy(this.checkPositionWithEventLoop, this))
+
+    this.$element     = $(element)
+    this.affixed      = null
+    this.unpin        = null
+    this.pinnedOffset = null
+
+    this.checkPosition()
+  }
+
+  Affix.VERSION  = '3.3.6'
+
+  Affix.RESET    = 'affix affix-top affix-bottom'
+
+  Affix.DEFAULTS = {
+    offset: 0,
+    target: window
+  }
+
+  Affix.prototype.getState = function (scrollHeight, height, offsetTop, offsetBottom) {
+    var scrollTop    = this.$target.scrollTop()
+    var position     = this.$element.offset()
+    var targetHeight = this.$target.height()
+
+    if (offsetTop != null && this.affixed == 'top') return scrollTop < offsetTop ? 'top' : false
+
+    if (this.affixed == 'bottom') {
+      if (offsetTop != null) return (scrollTop + this.unpin <= position.top) ? false : 'bottom'
+      return (scrollTop + targetHeight <= scrollHeight - offsetBottom) ? false : 'bottom'
+    }
+
+    var initializing   = this.affixed == null
+    var colliderTop    = initializing ? scrollTop : position.top
+    var colliderHeight = initializing ? targetHeight : height
+
+    if (offsetTop != null && scrollTop <= offsetTop) return 'top'
+    if (offsetBottom != null && (colliderTop + colliderHeight >= scrollHeight - offsetBottom)) return 'bottom'
+
+    return false
+  }
+
+  Affix.prototype.getPinnedOffset = function () {
+    if (this.pinnedOffset) return this.pinnedOffset
+    this.$element.removeClass(Affix.RESET).addClass('affix')
+    var scrollTop = this.$target.scrollTop()
+    var position  = this.$element.offset()
+    return (this.pinnedOffset = position.top - scrollTop)
+  }
+
+  Affix.prototype.checkPositionWithEventLoop = function () {
+    setTimeout($.proxy(this.checkPosition, this), 1)
+  }
+
+  Affix.prototype.checkPosition = function () {
+    if (!this.$element.is(':visible')) return
+
+    var height       = this.$element.height()
+    var offset       = this.options.offset
+    var offsetTop    = offset.top
+    var offsetBottom = offset.bottom
+    var scrollHeight = Math.max($(document).height(), $(document.body).height())
+
+    if (typeof offset != 'object')         offsetBottom = offsetTop = offset
+    if (typeof offsetTop == 'function')    offsetTop    = offset.top(this.$element)
+    if (typeof offsetBottom == 'function') offsetBottom = offset.bottom(this.$element)
+
+    var affix = this.getState(scrollHeight, height, offsetTop, offsetBottom)
+
+    if (this.affixed != affix) {
+      if (this.unpin != null) this.$element.css('top', '')
+
+      var affixType = 'affix' + (affix ? '-' + affix : '')
+      var e         = $.Event(affixType + '.bs.affix')
+
+      this.$element.trigger(e)
+
+      if (e.isDefaultPrevented()) return
+
+      this.affixed = affix
+      this.unpin = affix == 'bottom' ? this.getPinnedOffset() : null
+
+      this.$element
+        .removeClass(Affix.RESET)
+        .addClass(affixType)
+        .trigger(affixType.replace('affix', 'affixed') + '.bs.affix')
+    }
+
+    if (affix == 'bottom') {
+      this.$element.offset({
+        top: scrollHeight - height - offsetBottom
+      })
+    }
+  }
+
+
+  // AFFIX PLUGIN DEFINITION
+  // =======================
+
+  function Plugin(option) {
+    return this.each(function () {
+      var $this   = $(this)
+      var data    = $this.data('bs.affix')
+      var options = typeof option == 'object' && option
+
+      if (!data) $this.data('bs.affix', (data = new Affix(this, options)))
+      if (typeof option == 'string') data[option]()
+    })
+  }
+
+  var old = $.fn.affix
+
+  $.fn.affix             = Plugin
+  $.fn.affix.Constructor = Affix
+
+
+  // AFFIX NO CONFLICT
+  // =================
+
+  $.fn.affix.noConflict = function () {
+    $.fn.affix = old
+    return this
+  }
+
+
+  // AFFIX DATA-API
+  // ==============
+
+  $(window).on('load', function () {
+    $('[data-spy="affix"]').each(function () {
+      var $spy = $(this)
+      var data = $spy.data()
+
+      data.offset = data.offset || {}
+
+      if (data.offsetBottom != null) data.offset.bottom = data.offsetBottom
+      if (data.offsetTop    != null) data.offset.top    = data.offsetTop
+
+      Plugin.call($spy, data)
+    })
+  })
+
+}(jQuery);
diff --git a/web/js/bootstrap.min.js b/web/js/bootstrap.min.js
new file mode 100755
index 0000000000000000000000000000000000000000..e79c065134f2cfcf3e44a59cffcb5f090232f98f
--- /dev/null
+++ b/web/js/bootstrap.min.js
@@ -0,0 +1,7 @@
+/*!
+ * Bootstrap v3.3.6 (http://getbootstrap.com)
+ * Copyright 2011-2015 Twitter, Inc.
+ * Licensed under the MIT license
+ */
+if("undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");+function(a){"use strict";var b=a.fn.jquery.split(" ")[0].split(".");if(b[0]<2&&b[1]<9||1==b[0]&&9==b[1]&&b[2]<1||b[0]>2)throw new Error("Bootstrap's JavaScript requires jQuery version 1.9.1 or higher, but lower than version 3")}(jQuery),+function(a){"use strict";function b(){var a=document.createElement("bootstrap"),b={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(var c in b)if(void 0!==a.style[c])return{end:b[c]};return!1}a.fn.emulateTransitionEnd=function(b){var c=!1,d=this;a(this).one("bsTransitionEnd",function(){c=!0});var e=function(){c||a(d).trigger(a.support.transition.end)};return setTimeout(e,b),this},a(function(){a.support.transition=b(),a.support.transition&&(a.event.special.bsTransitionEnd={bindType:a.support.transition.end,delegateType:a.support.transition.end,handle:function(b){return a(b.target).is(this)?b.handleObj.handler.apply(this,arguments):void 0}})})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var c=a(this),e=c.data("bs.alert");e||c.data("bs.alert",e=new d(this)),"string"==typeof b&&e[b].call(c)})}var c='[data-dismiss="alert"]',d=function(b){a(b).on("click",c,this.close)};d.VERSION="3.3.6",d.TRANSITION_DURATION=150,d.prototype.close=function(b){function c(){g.detach().trigger("closed.bs.alert").remove()}var e=a(this),f=e.attr("data-target");f||(f=e.attr("href"),f=f&&f.replace(/.*(?=#[^\s]*$)/,""));var g=a(f);b&&b.preventDefault(),g.length||(g=e.closest(".alert")),g.trigger(b=a.Event("close.bs.alert")),b.isDefaultPrevented()||(g.removeClass("in"),a.support.transition&&g.hasClass("fade")?g.one("bsTransitionEnd",c).emulateTransitionEnd(d.TRANSITION_DURATION):c())};var e=a.fn.alert;a.fn.alert=b,a.fn.alert.Constructor=d,a.fn.alert.noConflict=function(){return a.fn.alert=e,this},a(document).on("click.bs.alert.data-api",c,d.prototype.close)}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.button"),f="object"==typeof b&&b;e||d.data("bs.button",e=new c(this,f)),"toggle"==b?e.toggle():b&&e.setState(b)})}var c=function(b,d){this.$element=a(b),this.options=a.extend({},c.DEFAULTS,d),this.isLoading=!1};c.VERSION="3.3.6",c.DEFAULTS={loadingText:"loading..."},c.prototype.setState=function(b){var c="disabled",d=this.$element,e=d.is("input")?"val":"html",f=d.data();b+="Text",null==f.resetText&&d.data("resetText",d[e]()),setTimeout(a.proxy(function(){d[e](null==f[b]?this.options[b]:f[b]),"loadingText"==b?(this.isLoading=!0,d.addClass(c).attr(c,c)):this.isLoading&&(this.isLoading=!1,d.removeClass(c).removeAttr(c))},this),0)},c.prototype.toggle=function(){var a=!0,b=this.$element.closest('[data-toggle="buttons"]');if(b.length){var c=this.$element.find("input");"radio"==c.prop("type")?(c.prop("checked")&&(a=!1),b.find(".active").removeClass("active"),this.$element.addClass("active")):"checkbox"==c.prop("type")&&(c.prop("checked")!==this.$element.hasClass("active")&&(a=!1),this.$element.toggleClass("active")),c.prop("checked",this.$element.hasClass("active")),a&&c.trigger("change")}else this.$element.attr("aria-pressed",!this.$element.hasClass("active")),this.$element.toggleClass("active")};var d=a.fn.button;a.fn.button=b,a.fn.button.Constructor=c,a.fn.button.noConflict=function(){return a.fn.button=d,this},a(document).on("click.bs.button.data-api",'[data-toggle^="button"]',function(c){var d=a(c.target);d.hasClass("btn")||(d=d.closest(".btn")),b.call(d,"toggle"),a(c.target).is('input[type="radio"]')||a(c.target).is('input[type="checkbox"]')||c.preventDefault()}).on("focus.bs.button.data-api blur.bs.button.data-api",'[data-toggle^="button"]',function(b){a(b.target).closest(".btn").toggleClass("focus",/^focus(in)?$/.test(b.type))})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.carousel"),f=a.extend({},c.DEFAULTS,d.data(),"object"==typeof b&&b),g="string"==typeof b?b:f.slide;e||d.data("bs.carousel",e=new c(this,f)),"number"==typeof b?e.to(b):g?e[g]():f.interval&&e.pause().cycle()})}var c=function(b,c){this.$element=a(b),this.$indicators=this.$element.find(".carousel-indicators"),this.options=c,this.paused=null,this.sliding=null,this.interval=null,this.$active=null,this.$items=null,this.options.keyboard&&this.$element.on("keydown.bs.carousel",a.proxy(this.keydown,this)),"hover"==this.options.pause&&!("ontouchstart"in document.documentElement)&&this.$element.on("mouseenter.bs.carousel",a.proxy(this.pause,this)).on("mouseleave.bs.carousel",a.proxy(this.cycle,this))};c.VERSION="3.3.6",c.TRANSITION_DURATION=600,c.DEFAULTS={interval:5e3,pause:"hover",wrap:!0,keyboard:!0},c.prototype.keydown=function(a){if(!/input|textarea/i.test(a.target.tagName)){switch(a.which){case 37:this.prev();break;case 39:this.next();break;default:return}a.preventDefault()}},c.prototype.cycle=function(b){return b||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(a.proxy(this.next,this),this.options.interval)),this},c.prototype.getItemIndex=function(a){return this.$items=a.parent().children(".item"),this.$items.index(a||this.$active)},c.prototype.getItemForDirection=function(a,b){var c=this.getItemIndex(b),d="prev"==a&&0===c||"next"==a&&c==this.$items.length-1;if(d&&!this.options.wrap)return b;var e="prev"==a?-1:1,f=(c+e)%this.$items.length;return this.$items.eq(f)},c.prototype.to=function(a){var b=this,c=this.getItemIndex(this.$active=this.$element.find(".item.active"));return a>this.$items.length-1||0>a?void 0:this.sliding?this.$element.one("slid.bs.carousel",function(){b.to(a)}):c==a?this.pause().cycle():this.slide(a>c?"next":"prev",this.$items.eq(a))},c.prototype.pause=function(b){return b||(this.paused=!0),this.$element.find(".next, .prev").length&&a.support.transition&&(this.$element.trigger(a.support.transition.end),this.cycle(!0)),this.interval=clearInterval(this.interval),this},c.prototype.next=function(){return this.sliding?void 0:this.slide("next")},c.prototype.prev=function(){return this.sliding?void 0:this.slide("prev")},c.prototype.slide=function(b,d){var e=this.$element.find(".item.active"),f=d||this.getItemForDirection(b,e),g=this.interval,h="next"==b?"left":"right",i=this;if(f.hasClass("active"))return this.sliding=!1;var j=f[0],k=a.Event("slide.bs.carousel",{relatedTarget:j,direction:h});if(this.$element.trigger(k),!k.isDefaultPrevented()){if(this.sliding=!0,g&&this.pause(),this.$indicators.length){this.$indicators.find(".active").removeClass("active");var l=a(this.$indicators.children()[this.getItemIndex(f)]);l&&l.addClass("active")}var m=a.Event("slid.bs.carousel",{relatedTarget:j,direction:h});return a.support.transition&&this.$element.hasClass("slide")?(f.addClass(b),f[0].offsetWidth,e.addClass(h),f.addClass(h),e.one("bsTransitionEnd",function(){f.removeClass([b,h].join(" ")).addClass("active"),e.removeClass(["active",h].join(" ")),i.sliding=!1,setTimeout(function(){i.$element.trigger(m)},0)}).emulateTransitionEnd(c.TRANSITION_DURATION)):(e.removeClass("active"),f.addClass("active"),this.sliding=!1,this.$element.trigger(m)),g&&this.cycle(),this}};var d=a.fn.carousel;a.fn.carousel=b,a.fn.carousel.Constructor=c,a.fn.carousel.noConflict=function(){return a.fn.carousel=d,this};var e=function(c){var d,e=a(this),f=a(e.attr("data-target")||(d=e.attr("href"))&&d.replace(/.*(?=#[^\s]+$)/,""));if(f.hasClass("carousel")){var g=a.extend({},f.data(),e.data()),h=e.attr("data-slide-to");h&&(g.interval=!1),b.call(f,g),h&&f.data("bs.carousel").to(h),c.preventDefault()}};a(document).on("click.bs.carousel.data-api","[data-slide]",e).on("click.bs.carousel.data-api","[data-slide-to]",e),a(window).on("load",function(){a('[data-ride="carousel"]').each(function(){var c=a(this);b.call(c,c.data())})})}(jQuery),+function(a){"use strict";function b(b){var c,d=b.attr("data-target")||(c=b.attr("href"))&&c.replace(/.*(?=#[^\s]+$)/,"");return a(d)}function c(b){return this.each(function(){var c=a(this),e=c.data("bs.collapse"),f=a.extend({},d.DEFAULTS,c.data(),"object"==typeof b&&b);!e&&f.toggle&&/show|hide/.test(b)&&(f.toggle=!1),e||c.data("bs.collapse",e=new d(this,f)),"string"==typeof b&&e[b]()})}var d=function(b,c){this.$element=a(b),this.options=a.extend({},d.DEFAULTS,c),this.$trigger=a('[data-toggle="collapse"][href="#'+b.id+'"],[data-toggle="collapse"][data-target="#'+b.id+'"]'),this.transitioning=null,this.options.parent?this.$parent=this.getParent():this.addAriaAndCollapsedClass(this.$element,this.$trigger),this.options.toggle&&this.toggle()};d.VERSION="3.3.6",d.TRANSITION_DURATION=350,d.DEFAULTS={toggle:!0},d.prototype.dimension=function(){var a=this.$element.hasClass("width");return a?"width":"height"},d.prototype.show=function(){if(!this.transitioning&&!this.$element.hasClass("in")){var b,e=this.$parent&&this.$parent.children(".panel").children(".in, .collapsing");if(!(e&&e.length&&(b=e.data("bs.collapse"),b&&b.transitioning))){var f=a.Event("show.bs.collapse");if(this.$element.trigger(f),!f.isDefaultPrevented()){e&&e.length&&(c.call(e,"hide"),b||e.data("bs.collapse",null));var g=this.dimension();this.$element.removeClass("collapse").addClass("collapsing")[g](0).attr("aria-expanded",!0),this.$trigger.removeClass("collapsed").attr("aria-expanded",!0),this.transitioning=1;var h=function(){this.$element.removeClass("collapsing").addClass("collapse in")[g](""),this.transitioning=0,this.$element.trigger("shown.bs.collapse")};if(!a.support.transition)return h.call(this);var i=a.camelCase(["scroll",g].join("-"));this.$element.one("bsTransitionEnd",a.proxy(h,this)).emulateTransitionEnd(d.TRANSITION_DURATION)[g](this.$element[0][i])}}}},d.prototype.hide=function(){if(!this.transitioning&&this.$element.hasClass("in")){var b=a.Event("hide.bs.collapse");if(this.$element.trigger(b),!b.isDefaultPrevented()){var c=this.dimension();this.$element[c](this.$element[c]())[0].offsetHeight,this.$element.addClass("collapsing").removeClass("collapse in").attr("aria-expanded",!1),this.$trigger.addClass("collapsed").attr("aria-expanded",!1),this.transitioning=1;var e=function(){this.transitioning=0,this.$element.removeClass("collapsing").addClass("collapse").trigger("hidden.bs.collapse")};return a.support.transition?void this.$element[c](0).one("bsTransitionEnd",a.proxy(e,this)).emulateTransitionEnd(d.TRANSITION_DURATION):e.call(this)}}},d.prototype.toggle=function(){this[this.$element.hasClass("in")?"hide":"show"]()},d.prototype.getParent=function(){return a(this.options.parent).find('[data-toggle="collapse"][data-parent="'+this.options.parent+'"]').each(a.proxy(function(c,d){var e=a(d);this.addAriaAndCollapsedClass(b(e),e)},this)).end()},d.prototype.addAriaAndCollapsedClass=function(a,b){var c=a.hasClass("in");a.attr("aria-expanded",c),b.toggleClass("collapsed",!c).attr("aria-expanded",c)};var e=a.fn.collapse;a.fn.collapse=c,a.fn.collapse.Constructor=d,a.fn.collapse.noConflict=function(){return a.fn.collapse=e,this},a(document).on("click.bs.collapse.data-api",'[data-toggle="collapse"]',function(d){var e=a(this);e.attr("data-target")||d.preventDefault();var f=b(e),g=f.data("bs.collapse"),h=g?"toggle":e.data();c.call(f,h)})}(jQuery),+function(a){"use strict";function b(b){var c=b.attr("data-target");c||(c=b.attr("href"),c=c&&/#[A-Za-z]/.test(c)&&c.replace(/.*(?=#[^\s]*$)/,""));var d=c&&a(c);return d&&d.length?d:b.parent()}function c(c){c&&3===c.which||(a(e).remove(),a(f).each(function(){var d=a(this),e=b(d),f={relatedTarget:this};e.hasClass("open")&&(c&&"click"==c.type&&/input|textarea/i.test(c.target.tagName)&&a.contains(e[0],c.target)||(e.trigger(c=a.Event("hide.bs.dropdown",f)),c.isDefaultPrevented()||(d.attr("aria-expanded","false"),e.removeClass("open").trigger(a.Event("hidden.bs.dropdown",f)))))}))}function d(b){return this.each(function(){var c=a(this),d=c.data("bs.dropdown");d||c.data("bs.dropdown",d=new g(this)),"string"==typeof b&&d[b].call(c)})}var e=".dropdown-backdrop",f='[data-toggle="dropdown"]',g=function(b){a(b).on("click.bs.dropdown",this.toggle)};g.VERSION="3.3.6",g.prototype.toggle=function(d){var e=a(this);if(!e.is(".disabled, :disabled")){var f=b(e),g=f.hasClass("open");if(c(),!g){"ontouchstart"in document.documentElement&&!f.closest(".navbar-nav").length&&a(document.createElement("div")).addClass("dropdown-backdrop").insertAfter(a(this)).on("click",c);var h={relatedTarget:this};if(f.trigger(d=a.Event("show.bs.dropdown",h)),d.isDefaultPrevented())return;e.trigger("focus").attr("aria-expanded","true"),f.toggleClass("open").trigger(a.Event("shown.bs.dropdown",h))}return!1}},g.prototype.keydown=function(c){if(/(38|40|27|32)/.test(c.which)&&!/input|textarea/i.test(c.target.tagName)){var d=a(this);if(c.preventDefault(),c.stopPropagation(),!d.is(".disabled, :disabled")){var e=b(d),g=e.hasClass("open");if(!g&&27!=c.which||g&&27==c.which)return 27==c.which&&e.find(f).trigger("focus"),d.trigger("click");var h=" li:not(.disabled):visible a",i=e.find(".dropdown-menu"+h);if(i.length){var j=i.index(c.target);38==c.which&&j>0&&j--,40==c.which&&j<i.length-1&&j++,~j||(j=0),i.eq(j).trigger("focus")}}}};var h=a.fn.dropdown;a.fn.dropdown=d,a.fn.dropdown.Constructor=g,a.fn.dropdown.noConflict=function(){return a.fn.dropdown=h,this},a(document).on("click.bs.dropdown.data-api",c).on("click.bs.dropdown.data-api",".dropdown form",function(a){a.stopPropagation()}).on("click.bs.dropdown.data-api",f,g.prototype.toggle).on("keydown.bs.dropdown.data-api",f,g.prototype.keydown).on("keydown.bs.dropdown.data-api",".dropdown-menu",g.prototype.keydown)}(jQuery),+function(a){"use strict";function b(b,d){return this.each(function(){var e=a(this),f=e.data("bs.modal"),g=a.extend({},c.DEFAULTS,e.data(),"object"==typeof b&&b);f||e.data("bs.modal",f=new c(this,g)),"string"==typeof b?f[b](d):g.show&&f.show(d)})}var c=function(b,c){this.options=c,this.$body=a(document.body),this.$element=a(b),this.$dialog=this.$element.find(".modal-dialog"),this.$backdrop=null,this.isShown=null,this.originalBodyPad=null,this.scrollbarWidth=0,this.ignoreBackdropClick=!1,this.options.remote&&this.$element.find(".modal-content").load(this.options.remote,a.proxy(function(){this.$element.trigger("loaded.bs.modal")},this))};c.VERSION="3.3.6",c.TRANSITION_DURATION=300,c.BACKDROP_TRANSITION_DURATION=150,c.DEFAULTS={backdrop:!0,keyboard:!0,show:!0},c.prototype.toggle=function(a){return this.isShown?this.hide():this.show(a)},c.prototype.show=function(b){var d=this,e=a.Event("show.bs.modal",{relatedTarget:b});this.$element.trigger(e),this.isShown||e.isDefaultPrevented()||(this.isShown=!0,this.checkScrollbar(),this.setScrollbar(),this.$body.addClass("modal-open"),this.escape(),this.resize(),this.$element.on("click.dismiss.bs.modal",'[data-dismiss="modal"]',a.proxy(this.hide,this)),this.$dialog.on("mousedown.dismiss.bs.modal",function(){d.$element.one("mouseup.dismiss.bs.modal",function(b){a(b.target).is(d.$element)&&(d.ignoreBackdropClick=!0)})}),this.backdrop(function(){var e=a.support.transition&&d.$element.hasClass("fade");d.$element.parent().length||d.$element.appendTo(d.$body),d.$element.show().scrollTop(0),d.adjustDialog(),e&&d.$element[0].offsetWidth,d.$element.addClass("in"),d.enforceFocus();var f=a.Event("shown.bs.modal",{relatedTarget:b});e?d.$dialog.one("bsTransitionEnd",function(){d.$element.trigger("focus").trigger(f)}).emulateTransitionEnd(c.TRANSITION_DURATION):d.$element.trigger("focus").trigger(f)}))},c.prototype.hide=function(b){b&&b.preventDefault(),b=a.Event("hide.bs.modal"),this.$element.trigger(b),this.isShown&&!b.isDefaultPrevented()&&(this.isShown=!1,this.escape(),this.resize(),a(document).off("focusin.bs.modal"),this.$element.removeClass("in").off("click.dismiss.bs.modal").off("mouseup.dismiss.bs.modal"),this.$dialog.off("mousedown.dismiss.bs.modal"),a.support.transition&&this.$element.hasClass("fade")?this.$element.one("bsTransitionEnd",a.proxy(this.hideModal,this)).emulateTransitionEnd(c.TRANSITION_DURATION):this.hideModal())},c.prototype.enforceFocus=function(){a(document).off("focusin.bs.modal").on("focusin.bs.modal",a.proxy(function(a){this.$element[0]===a.target||this.$element.has(a.target).length||this.$element.trigger("focus")},this))},c.prototype.escape=function(){this.isShown&&this.options.keyboard?this.$element.on("keydown.dismiss.bs.modal",a.proxy(function(a){27==a.which&&this.hide()},this)):this.isShown||this.$element.off("keydown.dismiss.bs.modal")},c.prototype.resize=function(){this.isShown?a(window).on("resize.bs.modal",a.proxy(this.handleUpdate,this)):a(window).off("resize.bs.modal")},c.prototype.hideModal=function(){var a=this;this.$element.hide(),this.backdrop(function(){a.$body.removeClass("modal-open"),a.resetAdjustments(),a.resetScrollbar(),a.$element.trigger("hidden.bs.modal")})},c.prototype.removeBackdrop=function(){this.$backdrop&&this.$backdrop.remove(),this.$backdrop=null},c.prototype.backdrop=function(b){var d=this,e=this.$element.hasClass("fade")?"fade":"";if(this.isShown&&this.options.backdrop){var f=a.support.transition&&e;if(this.$backdrop=a(document.createElement("div")).addClass("modal-backdrop "+e).appendTo(this.$body),this.$element.on("click.dismiss.bs.modal",a.proxy(function(a){return this.ignoreBackdropClick?void(this.ignoreBackdropClick=!1):void(a.target===a.currentTarget&&("static"==this.options.backdrop?this.$element[0].focus():this.hide()))},this)),f&&this.$backdrop[0].offsetWidth,this.$backdrop.addClass("in"),!b)return;f?this.$backdrop.one("bsTransitionEnd",b).emulateTransitionEnd(c.BACKDROP_TRANSITION_DURATION):b()}else if(!this.isShown&&this.$backdrop){this.$backdrop.removeClass("in");var g=function(){d.removeBackdrop(),b&&b()};a.support.transition&&this.$element.hasClass("fade")?this.$backdrop.one("bsTransitionEnd",g).emulateTransitionEnd(c.BACKDROP_TRANSITION_DURATION):g()}else b&&b()},c.prototype.handleUpdate=function(){this.adjustDialog()},c.prototype.adjustDialog=function(){var a=this.$element[0].scrollHeight>document.documentElement.clientHeight;this.$element.css({paddingLeft:!this.bodyIsOverflowing&&a?this.scrollbarWidth:"",paddingRight:this.bodyIsOverflowing&&!a?this.scrollbarWidth:""})},c.prototype.resetAdjustments=function(){this.$element.css({paddingLeft:"",paddingRight:""})},c.prototype.checkScrollbar=function(){var a=window.innerWidth;if(!a){var b=document.documentElement.getBoundingClientRect();a=b.right-Math.abs(b.left)}this.bodyIsOverflowing=document.body.clientWidth<a,this.scrollbarWidth=this.measureScrollbar()},c.prototype.setScrollbar=function(){var a=parseInt(this.$body.css("padding-right")||0,10);this.originalBodyPad=document.body.style.paddingRight||"",this.bodyIsOverflowing&&this.$body.css("padding-right",a+this.scrollbarWidth)},c.prototype.resetScrollbar=function(){this.$body.css("padding-right",this.originalBodyPad)},c.prototype.measureScrollbar=function(){var a=document.createElement("div");a.className="modal-scrollbar-measure",this.$body.append(a);var b=a.offsetWidth-a.clientWidth;return this.$body[0].removeChild(a),b};var d=a.fn.modal;a.fn.modal=b,a.fn.modal.Constructor=c,a.fn.modal.noConflict=function(){return a.fn.modal=d,this},a(document).on("click.bs.modal.data-api",'[data-toggle="modal"]',function(c){var d=a(this),e=d.attr("href"),f=a(d.attr("data-target")||e&&e.replace(/.*(?=#[^\s]+$)/,"")),g=f.data("bs.modal")?"toggle":a.extend({remote:!/#/.test(e)&&e},f.data(),d.data());d.is("a")&&c.preventDefault(),f.one("show.bs.modal",function(a){a.isDefaultPrevented()||f.one("hidden.bs.modal",function(){d.is(":visible")&&d.trigger("focus")})}),b.call(f,g,this)})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.tooltip"),f="object"==typeof b&&b;(e||!/destroy|hide/.test(b))&&(e||d.data("bs.tooltip",e=new c(this,f)),"string"==typeof b&&e[b]())})}var c=function(a,b){this.type=null,this.options=null,this.enabled=null,this.timeout=null,this.hoverState=null,this.$element=null,this.inState=null,this.init("tooltip",a,b)};c.VERSION="3.3.6",c.TRANSITION_DURATION=150,c.DEFAULTS={animation:!0,placement:"top",selector:!1,template:'<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',trigger:"hover focus",title:"",delay:0,html:!1,container:!1,viewport:{selector:"body",padding:0}},c.prototype.init=function(b,c,d){if(this.enabled=!0,this.type=b,this.$element=a(c),this.options=this.getOptions(d),this.$viewport=this.options.viewport&&a(a.isFunction(this.options.viewport)?this.options.viewport.call(this,this.$element):this.options.viewport.selector||this.options.viewport),this.inState={click:!1,hover:!1,focus:!1},this.$element[0]instanceof document.constructor&&!this.options.selector)throw new Error("`selector` option must be specified when initializing "+this.type+" on the window.document object!");for(var e=this.options.trigger.split(" "),f=e.length;f--;){var g=e[f];if("click"==g)this.$element.on("click."+this.type,this.options.selector,a.proxy(this.toggle,this));else if("manual"!=g){var h="hover"==g?"mouseenter":"focusin",i="hover"==g?"mouseleave":"focusout";this.$element.on(h+"."+this.type,this.options.selector,a.proxy(this.enter,this)),this.$element.on(i+"."+this.type,this.options.selector,a.proxy(this.leave,this))}}this.options.selector?this._options=a.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},c.prototype.getDefaults=function(){return c.DEFAULTS},c.prototype.getOptions=function(b){return b=a.extend({},this.getDefaults(),this.$element.data(),b),b.delay&&"number"==typeof b.delay&&(b.delay={show:b.delay,hide:b.delay}),b},c.prototype.getDelegateOptions=function(){var b={},c=this.getDefaults();return this._options&&a.each(this._options,function(a,d){c[a]!=d&&(b[a]=d)}),b},c.prototype.enter=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget).data("bs."+this.type);return c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c)),b instanceof a.Event&&(c.inState["focusin"==b.type?"focus":"hover"]=!0),c.tip().hasClass("in")||"in"==c.hoverState?void(c.hoverState="in"):(clearTimeout(c.timeout),c.hoverState="in",c.options.delay&&c.options.delay.show?void(c.timeout=setTimeout(function(){"in"==c.hoverState&&c.show()},c.options.delay.show)):c.show())},c.prototype.isInStateTrue=function(){for(var a in this.inState)if(this.inState[a])return!0;return!1},c.prototype.leave=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget).data("bs."+this.type);return c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c)),b instanceof a.Event&&(c.inState["focusout"==b.type?"focus":"hover"]=!1),c.isInStateTrue()?void 0:(clearTimeout(c.timeout),c.hoverState="out",c.options.delay&&c.options.delay.hide?void(c.timeout=setTimeout(function(){"out"==c.hoverState&&c.hide()},c.options.delay.hide)):c.hide())},c.prototype.show=function(){var b=a.Event("show.bs."+this.type);if(this.hasContent()&&this.enabled){this.$element.trigger(b);var d=a.contains(this.$element[0].ownerDocument.documentElement,this.$element[0]);if(b.isDefaultPrevented()||!d)return;var e=this,f=this.tip(),g=this.getUID(this.type);this.setContent(),f.attr("id",g),this.$element.attr("aria-describedby",g),this.options.animation&&f.addClass("fade");var h="function"==typeof this.options.placement?this.options.placement.call(this,f[0],this.$element[0]):this.options.placement,i=/\s?auto?\s?/i,j=i.test(h);j&&(h=h.replace(i,"")||"top"),f.detach().css({top:0,left:0,display:"block"}).addClass(h).data("bs."+this.type,this),this.options.container?f.appendTo(this.options.container):f.insertAfter(this.$element),this.$element.trigger("inserted.bs."+this.type);var k=this.getPosition(),l=f[0].offsetWidth,m=f[0].offsetHeight;if(j){var n=h,o=this.getPosition(this.$viewport);h="bottom"==h&&k.bottom+m>o.bottom?"top":"top"==h&&k.top-m<o.top?"bottom":"right"==h&&k.right+l>o.width?"left":"left"==h&&k.left-l<o.left?"right":h,f.removeClass(n).addClass(h)}var p=this.getCalculatedOffset(h,k,l,m);this.applyPlacement(p,h);var q=function(){var a=e.hoverState;e.$element.trigger("shown.bs."+e.type),e.hoverState=null,"out"==a&&e.leave(e)};a.support.transition&&this.$tip.hasClass("fade")?f.one("bsTransitionEnd",q).emulateTransitionEnd(c.TRANSITION_DURATION):q()}},c.prototype.applyPlacement=function(b,c){var d=this.tip(),e=d[0].offsetWidth,f=d[0].offsetHeight,g=parseInt(d.css("margin-top"),10),h=parseInt(d.css("margin-left"),10);isNaN(g)&&(g=0),isNaN(h)&&(h=0),b.top+=g,b.left+=h,a.offset.setOffset(d[0],a.extend({using:function(a){d.css({top:Math.round(a.top),left:Math.round(a.left)})}},b),0),d.addClass("in");var i=d[0].offsetWidth,j=d[0].offsetHeight;"top"==c&&j!=f&&(b.top=b.top+f-j);var k=this.getViewportAdjustedDelta(c,b,i,j);k.left?b.left+=k.left:b.top+=k.top;var l=/top|bottom/.test(c),m=l?2*k.left-e+i:2*k.top-f+j,n=l?"offsetWidth":"offsetHeight";d.offset(b),this.replaceArrow(m,d[0][n],l)},c.prototype.replaceArrow=function(a,b,c){this.arrow().css(c?"left":"top",50*(1-a/b)+"%").css(c?"top":"left","")},c.prototype.setContent=function(){var a=this.tip(),b=this.getTitle();a.find(".tooltip-inner")[this.options.html?"html":"text"](b),a.removeClass("fade in top bottom left right")},c.prototype.hide=function(b){function d(){"in"!=e.hoverState&&f.detach(),e.$element.removeAttr("aria-describedby").trigger("hidden.bs."+e.type),b&&b()}var e=this,f=a(this.$tip),g=a.Event("hide.bs."+this.type);return this.$element.trigger(g),g.isDefaultPrevented()?void 0:(f.removeClass("in"),a.support.transition&&f.hasClass("fade")?f.one("bsTransitionEnd",d).emulateTransitionEnd(c.TRANSITION_DURATION):d(),this.hoverState=null,this)},c.prototype.fixTitle=function(){var a=this.$element;(a.attr("title")||"string"!=typeof a.attr("data-original-title"))&&a.attr("data-original-title",a.attr("title")||"").attr("title","")},c.prototype.hasContent=function(){return this.getTitle()},c.prototype.getPosition=function(b){b=b||this.$element;var c=b[0],d="BODY"==c.tagName,e=c.getBoundingClientRect();null==e.width&&(e=a.extend({},e,{width:e.right-e.left,height:e.bottom-e.top}));var f=d?{top:0,left:0}:b.offset(),g={scroll:d?document.documentElement.scrollTop||document.body.scrollTop:b.scrollTop()},h=d?{width:a(window).width(),height:a(window).height()}:null;return a.extend({},e,g,h,f)},c.prototype.getCalculatedOffset=function(a,b,c,d){return"bottom"==a?{top:b.top+b.height,left:b.left+b.width/2-c/2}:"top"==a?{top:b.top-d,left:b.left+b.width/2-c/2}:"left"==a?{top:b.top+b.height/2-d/2,left:b.left-c}:{top:b.top+b.height/2-d/2,left:b.left+b.width}},c.prototype.getViewportAdjustedDelta=function(a,b,c,d){var e={top:0,left:0};if(!this.$viewport)return e;var f=this.options.viewport&&this.options.viewport.padding||0,g=this.getPosition(this.$viewport);if(/right|left/.test(a)){var h=b.top-f-g.scroll,i=b.top+f-g.scroll+d;h<g.top?e.top=g.top-h:i>g.top+g.height&&(e.top=g.top+g.height-i)}else{var j=b.left-f,k=b.left+f+c;j<g.left?e.left=g.left-j:k>g.right&&(e.left=g.left+g.width-k)}return e},c.prototype.getTitle=function(){var a,b=this.$element,c=this.options;return a=b.attr("data-original-title")||("function"==typeof c.title?c.title.call(b[0]):c.title)},c.prototype.getUID=function(a){do a+=~~(1e6*Math.random());while(document.getElementById(a));return a},c.prototype.tip=function(){if(!this.$tip&&(this.$tip=a(this.options.template),1!=this.$tip.length))throw new Error(this.type+" `template` option must consist of exactly 1 top-level element!");return this.$tip},c.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},c.prototype.enable=function(){this.enabled=!0},c.prototype.disable=function(){this.enabled=!1},c.prototype.toggleEnabled=function(){this.enabled=!this.enabled},c.prototype.toggle=function(b){var c=this;b&&(c=a(b.currentTarget).data("bs."+this.type),c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c))),b?(c.inState.click=!c.inState.click,c.isInStateTrue()?c.enter(c):c.leave(c)):c.tip().hasClass("in")?c.leave(c):c.enter(c)},c.prototype.destroy=function(){var a=this;clearTimeout(this.timeout),this.hide(function(){a.$element.off("."+a.type).removeData("bs."+a.type),a.$tip&&a.$tip.detach(),a.$tip=null,a.$arrow=null,a.$viewport=null})};var d=a.fn.tooltip;a.fn.tooltip=b,a.fn.tooltip.Constructor=c,a.fn.tooltip.noConflict=function(){return a.fn.tooltip=d,this}}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.popover"),f="object"==typeof b&&b;(e||!/destroy|hide/.test(b))&&(e||d.data("bs.popover",e=new c(this,f)),"string"==typeof b&&e[b]())})}var c=function(a,b){this.init("popover",a,b)};if(!a.fn.tooltip)throw new Error("Popover requires tooltip.js");c.VERSION="3.3.6",c.DEFAULTS=a.extend({},a.fn.tooltip.Constructor.DEFAULTS,{placement:"right",trigger:"click",content:"",template:'<div class="popover" role="tooltip"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'}),c.prototype=a.extend({},a.fn.tooltip.Constructor.prototype),c.prototype.constructor=c,c.prototype.getDefaults=function(){return c.DEFAULTS},c.prototype.setContent=function(){var a=this.tip(),b=this.getTitle(),c=this.getContent();a.find(".popover-title")[this.options.html?"html":"text"](b),a.find(".popover-content").children().detach().end()[this.options.html?"string"==typeof c?"html":"append":"text"](c),a.removeClass("fade top bottom left right in"),a.find(".popover-title").html()||a.find(".popover-title").hide()},c.prototype.hasContent=function(){return this.getTitle()||this.getContent()},c.prototype.getContent=function(){var a=this.$element,b=this.options;return a.attr("data-content")||("function"==typeof b.content?b.content.call(a[0]):b.content)},c.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".arrow")};var d=a.fn.popover;a.fn.popover=b,a.fn.popover.Constructor=c,a.fn.popover.noConflict=function(){return a.fn.popover=d,this}}(jQuery),+function(a){"use strict";function b(c,d){this.$body=a(document.body),this.$scrollElement=a(a(c).is(document.body)?window:c),this.options=a.extend({},b.DEFAULTS,d),this.selector=(this.options.target||"")+" .nav li > a",this.offsets=[],this.targets=[],this.activeTarget=null,this.scrollHeight=0,this.$scrollElement.on("scroll.bs.scrollspy",a.proxy(this.process,this)),this.refresh(),this.process()}function c(c){return this.each(function(){var d=a(this),e=d.data("bs.scrollspy"),f="object"==typeof c&&c;e||d.data("bs.scrollspy",e=new b(this,f)),"string"==typeof c&&e[c]()})}b.VERSION="3.3.6",b.DEFAULTS={offset:10},b.prototype.getScrollHeight=function(){return this.$scrollElement[0].scrollHeight||Math.max(this.$body[0].scrollHeight,document.documentElement.scrollHeight)},b.prototype.refresh=function(){var b=this,c="offset",d=0;this.offsets=[],this.targets=[],this.scrollHeight=this.getScrollHeight(),a.isWindow(this.$scrollElement[0])||(c="position",d=this.$scrollElement.scrollTop()),this.$body.find(this.selector).map(function(){var b=a(this),e=b.data("target")||b.attr("href"),f=/^#./.test(e)&&a(e);return f&&f.length&&f.is(":visible")&&[[f[c]().top+d,e]]||null}).sort(function(a,b){return a[0]-b[0]}).each(function(){b.offsets.push(this[0]),b.targets.push(this[1])})},b.prototype.process=function(){var a,b=this.$scrollElement.scrollTop()+this.options.offset,c=this.getScrollHeight(),d=this.options.offset+c-this.$scrollElement.height(),e=this.offsets,f=this.targets,g=this.activeTarget;if(this.scrollHeight!=c&&this.refresh(),b>=d)return g!=(a=f[f.length-1])&&this.activate(a);if(g&&b<e[0])return this.activeTarget=null,this.clear();for(a=e.length;a--;)g!=f[a]&&b>=e[a]&&(void 0===e[a+1]||b<e[a+1])&&this.activate(f[a])},b.prototype.activate=function(b){this.activeTarget=b,this.clear();var c=this.selector+'[data-target="'+b+'"],'+this.selector+'[href="'+b+'"]',d=a(c).parents("li").addClass("active");
+d.parent(".dropdown-menu").length&&(d=d.closest("li.dropdown").addClass("active")),d.trigger("activate.bs.scrollspy")},b.prototype.clear=function(){a(this.selector).parentsUntil(this.options.target,".active").removeClass("active")};var d=a.fn.scrollspy;a.fn.scrollspy=c,a.fn.scrollspy.Constructor=b,a.fn.scrollspy.noConflict=function(){return a.fn.scrollspy=d,this},a(window).on("load.bs.scrollspy.data-api",function(){a('[data-spy="scroll"]').each(function(){var b=a(this);c.call(b,b.data())})})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.tab");e||d.data("bs.tab",e=new c(this)),"string"==typeof b&&e[b]()})}var c=function(b){this.element=a(b)};c.VERSION="3.3.6",c.TRANSITION_DURATION=150,c.prototype.show=function(){var b=this.element,c=b.closest("ul:not(.dropdown-menu)"),d=b.data("target");if(d||(d=b.attr("href"),d=d&&d.replace(/.*(?=#[^\s]*$)/,"")),!b.parent("li").hasClass("active")){var e=c.find(".active:last a"),f=a.Event("hide.bs.tab",{relatedTarget:b[0]}),g=a.Event("show.bs.tab",{relatedTarget:e[0]});if(e.trigger(f),b.trigger(g),!g.isDefaultPrevented()&&!f.isDefaultPrevented()){var h=a(d);this.activate(b.closest("li"),c),this.activate(h,h.parent(),function(){e.trigger({type:"hidden.bs.tab",relatedTarget:b[0]}),b.trigger({type:"shown.bs.tab",relatedTarget:e[0]})})}}},c.prototype.activate=function(b,d,e){function f(){g.removeClass("active").find("> .dropdown-menu > .active").removeClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!1),b.addClass("active").find('[data-toggle="tab"]').attr("aria-expanded",!0),h?(b[0].offsetWidth,b.addClass("in")):b.removeClass("fade"),b.parent(".dropdown-menu").length&&b.closest("li.dropdown").addClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!0),e&&e()}var g=d.find("> .active"),h=e&&a.support.transition&&(g.length&&g.hasClass("fade")||!!d.find("> .fade").length);g.length&&h?g.one("bsTransitionEnd",f).emulateTransitionEnd(c.TRANSITION_DURATION):f(),g.removeClass("in")};var d=a.fn.tab;a.fn.tab=b,a.fn.tab.Constructor=c,a.fn.tab.noConflict=function(){return a.fn.tab=d,this};var e=function(c){c.preventDefault(),b.call(a(this),"show")};a(document).on("click.bs.tab.data-api",'[data-toggle="tab"]',e).on("click.bs.tab.data-api",'[data-toggle="pill"]',e)}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.affix"),f="object"==typeof b&&b;e||d.data("bs.affix",e=new c(this,f)),"string"==typeof b&&e[b]()})}var c=function(b,d){this.options=a.extend({},c.DEFAULTS,d),this.$target=a(this.options.target).on("scroll.bs.affix.data-api",a.proxy(this.checkPosition,this)).on("click.bs.affix.data-api",a.proxy(this.checkPositionWithEventLoop,this)),this.$element=a(b),this.affixed=null,this.unpin=null,this.pinnedOffset=null,this.checkPosition()};c.VERSION="3.3.6",c.RESET="affix affix-top affix-bottom",c.DEFAULTS={offset:0,target:window},c.prototype.getState=function(a,b,c,d){var e=this.$target.scrollTop(),f=this.$element.offset(),g=this.$target.height();if(null!=c&&"top"==this.affixed)return c>e?"top":!1;if("bottom"==this.affixed)return null!=c?e+this.unpin<=f.top?!1:"bottom":a-d>=e+g?!1:"bottom";var h=null==this.affixed,i=h?e:f.top,j=h?g:b;return null!=c&&c>=e?"top":null!=d&&i+j>=a-d?"bottom":!1},c.prototype.getPinnedOffset=function(){if(this.pinnedOffset)return this.pinnedOffset;this.$element.removeClass(c.RESET).addClass("affix");var a=this.$target.scrollTop(),b=this.$element.offset();return this.pinnedOffset=b.top-a},c.prototype.checkPositionWithEventLoop=function(){setTimeout(a.proxy(this.checkPosition,this),1)},c.prototype.checkPosition=function(){if(this.$element.is(":visible")){var b=this.$element.height(),d=this.options.offset,e=d.top,f=d.bottom,g=Math.max(a(document).height(),a(document.body).height());"object"!=typeof d&&(f=e=d),"function"==typeof e&&(e=d.top(this.$element)),"function"==typeof f&&(f=d.bottom(this.$element));var h=this.getState(g,b,e,f);if(this.affixed!=h){null!=this.unpin&&this.$element.css("top","");var i="affix"+(h?"-"+h:""),j=a.Event(i+".bs.affix");if(this.$element.trigger(j),j.isDefaultPrevented())return;this.affixed=h,this.unpin="bottom"==h?this.getPinnedOffset():null,this.$element.removeClass(c.RESET).addClass(i).trigger(i.replace("affix","affixed")+".bs.affix")}"bottom"==h&&this.$element.offset({top:g-b-f})}};var d=a.fn.affix;a.fn.affix=b,a.fn.affix.Constructor=c,a.fn.affix.noConflict=function(){return a.fn.affix=d,this},a(window).on("load",function(){a('[data-spy="affix"]').each(function(){var c=a(this),d=c.data();d.offset=d.offset||{},null!=d.offsetBottom&&(d.offset.bottom=d.offsetBottom),null!=d.offsetTop&&(d.offset.top=d.offsetTop),b.call(c,d)})})}(jQuery);
\ No newline at end of file
diff --git a/web/js/jquery.js b/web/js/jquery.js
new file mode 100755
index 0000000000000000000000000000000000000000..d1608e37ffa979b8689bfb868ad8b061b191f6f6
--- /dev/null
+++ b/web/js/jquery.js
@@ -0,0 +1,4 @@
+/*! jQuery v1.11.1 | (c) 2005, 2014 jQuery Foundation, Inc. | jquery.org/license */
+!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){var c=[],d=c.slice,e=c.concat,f=c.push,g=c.indexOf,h={},i=h.toString,j=h.hasOwnProperty,k={},l="1.11.1",m=function(a,b){return new m.fn.init(a,b)},n=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,o=/^-ms-/,p=/-([\da-z])/gi,q=function(a,b){return b.toUpperCase()};m.fn=m.prototype={jquery:l,constructor:m,selector:"",length:0,toArray:function(){return d.call(this)},get:function(a){return null!=a?0>a?this[a+this.length]:this[a]:d.call(this)},pushStack:function(a){var b=m.merge(this.constructor(),a);return b.prevObject=this,b.context=this.context,b},each:function(a,b){return m.each(this,a,b)},map:function(a){return this.pushStack(m.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(d.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(0>a?b:0);return this.pushStack(c>=0&&b>c?[this[c]]:[])},end:function(){return this.prevObject||this.constructor(null)},push:f,sort:c.sort,splice:c.splice},m.extend=m.fn.extend=function(){var a,b,c,d,e,f,g=arguments[0]||{},h=1,i=arguments.length,j=!1;for("boolean"==typeof g&&(j=g,g=arguments[h]||{},h++),"object"==typeof g||m.isFunction(g)||(g={}),h===i&&(g=this,h--);i>h;h++)if(null!=(e=arguments[h]))for(d in e)a=g[d],c=e[d],g!==c&&(j&&c&&(m.isPlainObject(c)||(b=m.isArray(c)))?(b?(b=!1,f=a&&m.isArray(a)?a:[]):f=a&&m.isPlainObject(a)?a:{},g[d]=m.extend(j,f,c)):void 0!==c&&(g[d]=c));return g},m.extend({expando:"jQuery"+(l+Math.random()).replace(/\D/g,""),isReady:!0,error:function(a){throw new Error(a)},noop:function(){},isFunction:function(a){return"function"===m.type(a)},isArray:Array.isArray||function(a){return"array"===m.type(a)},isWindow:function(a){return null!=a&&a==a.window},isNumeric:function(a){return!m.isArray(a)&&a-parseFloat(a)>=0},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},isPlainObject:function(a){var b;if(!a||"object"!==m.type(a)||a.nodeType||m.isWindow(a))return!1;try{if(a.constructor&&!j.call(a,"constructor")&&!j.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}if(k.ownLast)for(b in a)return j.call(a,b);for(b in a);return void 0===b||j.call(a,b)},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?h[i.call(a)]||"object":typeof a},globalEval:function(b){b&&m.trim(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(o,"ms-").replace(p,q)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,b,c){var d,e=0,f=a.length,g=r(a);if(c){if(g){for(;f>e;e++)if(d=b.apply(a[e],c),d===!1)break}else for(e in a)if(d=b.apply(a[e],c),d===!1)break}else if(g){for(;f>e;e++)if(d=b.call(a[e],e,a[e]),d===!1)break}else for(e in a)if(d=b.call(a[e],e,a[e]),d===!1)break;return a},trim:function(a){return null==a?"":(a+"").replace(n,"")},makeArray:function(a,b){var c=b||[];return null!=a&&(r(Object(a))?m.merge(c,"string"==typeof a?[a]:a):f.call(c,a)),c},inArray:function(a,b,c){var d;if(b){if(g)return g.call(b,a,c);for(d=b.length,c=c?0>c?Math.max(0,d+c):c:0;d>c;c++)if(c in b&&b[c]===a)return c}return-1},merge:function(a,b){var c=+b.length,d=0,e=a.length;while(c>d)a[e++]=b[d++];if(c!==c)while(void 0!==b[d])a[e++]=b[d++];return a.length=e,a},grep:function(a,b,c){for(var d,e=[],f=0,g=a.length,h=!c;g>f;f++)d=!b(a[f],f),d!==h&&e.push(a[f]);return e},map:function(a,b,c){var d,f=0,g=a.length,h=r(a),i=[];if(h)for(;g>f;f++)d=b(a[f],f,c),null!=d&&i.push(d);else for(f in a)d=b(a[f],f,c),null!=d&&i.push(d);return e.apply([],i)},guid:1,proxy:function(a,b){var c,e,f;return"string"==typeof b&&(f=a[b],b=a,a=f),m.isFunction(a)?(c=d.call(arguments,2),e=function(){return a.apply(b||this,c.concat(d.call(arguments)))},e.guid=a.guid=a.guid||m.guid++,e):void 0},now:function(){return+new Date},support:k}),m.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(a,b){h["[object "+b+"]"]=b.toLowerCase()});function r(a){var b=a.length,c=m.type(a);return"function"===c||m.isWindow(a)?!1:1===a.nodeType&&b?!0:"array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a}var s=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u="sizzle"+-new Date,v=a.document,w=0,x=0,y=gb(),z=gb(),A=gb(),B=function(a,b){return a===b&&(l=!0),0},C="undefined",D=1<<31,E={}.hasOwnProperty,F=[],G=F.pop,H=F.push,I=F.push,J=F.slice,K=F.indexOf||function(a){for(var b=0,c=this.length;c>b;b++)if(this[b]===a)return b;return-1},L="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",M="[\\x20\\t\\r\\n\\f]",N="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",O=N.replace("w","w#"),P="\\["+M+"*("+N+")(?:"+M+"*([*^$|!~]?=)"+M+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+O+"))|)"+M+"*\\]",Q=":("+N+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+P+")*)|.*)\\)|)",R=new RegExp("^"+M+"+|((?:^|[^\\\\])(?:\\\\.)*)"+M+"+$","g"),S=new RegExp("^"+M+"*,"+M+"*"),T=new RegExp("^"+M+"*([>+~]|"+M+")"+M+"*"),U=new RegExp("="+M+"*([^\\]'\"]*?)"+M+"*\\]","g"),V=new RegExp(Q),W=new RegExp("^"+O+"$"),X={ID:new RegExp("^#("+N+")"),CLASS:new RegExp("^\\.("+N+")"),TAG:new RegExp("^("+N.replace("w","w*")+")"),ATTR:new RegExp("^"+P),PSEUDO:new RegExp("^"+Q),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+L+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/^(?:input|select|textarea|button)$/i,Z=/^h\d$/i,$=/^[^{]+\{\s*\[native \w/,_=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ab=/[+~]/,bb=/'|\\/g,cb=new RegExp("\\\\([\\da-f]{1,6}"+M+"?|("+M+")|.)","ig"),db=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:0>d?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)};try{I.apply(F=J.call(v.childNodes),v.childNodes),F[v.childNodes.length].nodeType}catch(eb){I={apply:F.length?function(a,b){H.apply(a,J.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function fb(a,b,d,e){var f,h,j,k,l,o,r,s,w,x;if((b?b.ownerDocument||b:v)!==n&&m(b),b=b||n,d=d||[],!a||"string"!=typeof a)return d;if(1!==(k=b.nodeType)&&9!==k)return[];if(p&&!e){if(f=_.exec(a))if(j=f[1]){if(9===k){if(h=b.getElementById(j),!h||!h.parentNode)return d;if(h.id===j)return d.push(h),d}else if(b.ownerDocument&&(h=b.ownerDocument.getElementById(j))&&t(b,h)&&h.id===j)return d.push(h),d}else{if(f[2])return I.apply(d,b.getElementsByTagName(a)),d;if((j=f[3])&&c.getElementsByClassName&&b.getElementsByClassName)return I.apply(d,b.getElementsByClassName(j)),d}if(c.qsa&&(!q||!q.test(a))){if(s=r=u,w=b,x=9===k&&a,1===k&&"object"!==b.nodeName.toLowerCase()){o=g(a),(r=b.getAttribute("id"))?s=r.replace(bb,"\\$&"):b.setAttribute("id",s),s="[id='"+s+"'] ",l=o.length;while(l--)o[l]=s+qb(o[l]);w=ab.test(a)&&ob(b.parentNode)||b,x=o.join(",")}if(x)try{return I.apply(d,w.querySelectorAll(x)),d}catch(y){}finally{r||b.removeAttribute("id")}}}return i(a.replace(R,"$1"),b,d,e)}function gb(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function hb(a){return a[u]=!0,a}function ib(a){var b=n.createElement("div");try{return!!a(b)}catch(c){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function jb(a,b){var c=a.split("|"),e=a.length;while(e--)d.attrHandle[c[e]]=b}function kb(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&(~b.sourceIndex||D)-(~a.sourceIndex||D);if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function lb(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function mb(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function nb(a){return hb(function(b){return b=+b,hb(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function ob(a){return a&&typeof a.getElementsByTagName!==C&&a}c=fb.support={},f=fb.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return b?"HTML"!==b.nodeName:!1},m=fb.setDocument=function(a){var b,e=a?a.ownerDocument||a:v,g=e.defaultView;return e!==n&&9===e.nodeType&&e.documentElement?(n=e,o=e.documentElement,p=!f(e),g&&g!==g.top&&(g.addEventListener?g.addEventListener("unload",function(){m()},!1):g.attachEvent&&g.attachEvent("onunload",function(){m()})),c.attributes=ib(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=ib(function(a){return a.appendChild(e.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=$.test(e.getElementsByClassName)&&ib(function(a){return a.innerHTML="<div class='a'></div><div class='a i'></div>",a.firstChild.className="i",2===a.getElementsByClassName("i").length}),c.getById=ib(function(a){return o.appendChild(a).id=u,!e.getElementsByName||!e.getElementsByName(u).length}),c.getById?(d.find.ID=function(a,b){if(typeof b.getElementById!==C&&p){var c=b.getElementById(a);return c&&c.parentNode?[c]:[]}},d.filter.ID=function(a){var b=a.replace(cb,db);return function(a){return a.getAttribute("id")===b}}):(delete d.find.ID,d.filter.ID=function(a){var b=a.replace(cb,db);return function(a){var c=typeof a.getAttributeNode!==C&&a.getAttributeNode("id");return c&&c.value===b}}),d.find.TAG=c.getElementsByTagName?function(a,b){return typeof b.getElementsByTagName!==C?b.getElementsByTagName(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){return typeof b.getElementsByClassName!==C&&p?b.getElementsByClassName(a):void 0},r=[],q=[],(c.qsa=$.test(e.querySelectorAll))&&(ib(function(a){a.innerHTML="<select msallowclip=''><option selected=''></option></select>",a.querySelectorAll("[msallowclip^='']").length&&q.push("[*^$]="+M+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||q.push("\\["+M+"*(?:value|"+L+")"),a.querySelectorAll(":checked").length||q.push(":checked")}),ib(function(a){var b=e.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&q.push("name"+M+"*[*^$|!~]?="),a.querySelectorAll(":enabled").length||q.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),q.push(",.*:")})),(c.matchesSelector=$.test(s=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&ib(function(a){c.disconnectedMatch=s.call(a,"div"),s.call(a,"[s!='']:x"),r.push("!=",Q)}),q=q.length&&new RegExp(q.join("|")),r=r.length&&new RegExp(r.join("|")),b=$.test(o.compareDocumentPosition),t=b||$.test(o.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},B=b?function(a,b){if(a===b)return l=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d?d:(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===e||a.ownerDocument===v&&t(v,a)?-1:b===e||b.ownerDocument===v&&t(v,b)?1:k?K.call(k,a)-K.call(k,b):0:4&d?-1:1)}:function(a,b){if(a===b)return l=!0,0;var c,d=0,f=a.parentNode,g=b.parentNode,h=[a],i=[b];if(!f||!g)return a===e?-1:b===e?1:f?-1:g?1:k?K.call(k,a)-K.call(k,b):0;if(f===g)return kb(a,b);c=a;while(c=c.parentNode)h.unshift(c);c=b;while(c=c.parentNode)i.unshift(c);while(h[d]===i[d])d++;return d?kb(h[d],i[d]):h[d]===v?-1:i[d]===v?1:0},e):n},fb.matches=function(a,b){return fb(a,null,null,b)},fb.matchesSelector=function(a,b){if((a.ownerDocument||a)!==n&&m(a),b=b.replace(U,"='$1']"),!(!c.matchesSelector||!p||r&&r.test(b)||q&&q.test(b)))try{var d=s.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(e){}return fb(b,n,null,[a]).length>0},fb.contains=function(a,b){return(a.ownerDocument||a)!==n&&m(a),t(a,b)},fb.attr=function(a,b){(a.ownerDocument||a)!==n&&m(a);var e=d.attrHandle[b.toLowerCase()],f=e&&E.call(d.attrHandle,b.toLowerCase())?e(a,b,!p):void 0;return void 0!==f?f:c.attributes||!p?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},fb.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},fb.uniqueSort=function(a){var b,d=[],e=0,f=0;if(l=!c.detectDuplicates,k=!c.sortStable&&a.slice(0),a.sort(B),l){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return k=null,a},e=fb.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=fb.selectors={cacheLength:50,createPseudo:hb,match:X,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(cb,db),a[3]=(a[3]||a[4]||a[5]||"").replace(cb,db),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||fb.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&fb.error(a[0]),a},PSEUDO:function(a){var b,c=!a[6]&&a[2];return X.CHILD.test(a[0])?null:(a[3]?a[2]=a[4]||a[5]||"":c&&V.test(c)&&(b=g(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(cb,db).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=y[a+" "];return b||(b=new RegExp("(^|"+M+")"+a+"("+M+"|$)"))&&y(a,function(a){return b.test("string"==typeof a.className&&a.className||typeof a.getAttribute!==C&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=fb.attr(d,a);return null==e?"!="===b:b?(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e+" ").indexOf(c)>-1:"|="===b?e===c||e.slice(0,c.length+1)===c+"-":!1):!0}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),s=!i&&!h;if(q){if(f){while(p){l=b;while(l=l[p])if(h?l.nodeName.toLowerCase()===r:1===l.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&s){k=q[u]||(q[u]={}),j=k[a]||[],n=j[0]===w&&j[1],m=j[0]===w&&j[2],l=n&&q.childNodes[n];while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if(1===l.nodeType&&++m&&l===b){k[a]=[w,n,m];break}}else if(s&&(j=(b[u]||(b[u]={}))[a])&&j[0]===w)m=j[1];else while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if((h?l.nodeName.toLowerCase()===r:1===l.nodeType)&&++m&&(s&&((l[u]||(l[u]={}))[a]=[w,m]),l===b))break;return m-=e,m===d||m%d===0&&m/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||fb.error("unsupported pseudo: "+a);return e[u]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?hb(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=K.call(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:hb(function(a){var b=[],c=[],d=h(a.replace(R,"$1"));return d[u]?hb(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),!c.pop()}}),has:hb(function(a){return function(b){return fb(a,b).length>0}}),contains:hb(function(a){return function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:hb(function(a){return W.test(a||"")||fb.error("unsupported lang: "+a),a=a.replace(cb,db).toLowerCase(),function(b){var c;do if(c=p?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return c=c.toLowerCase(),c===a||0===c.indexOf(a+"-");while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===o},focus:function(a){return a===n.activeElement&&(!n.hasFocus||n.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return Z.test(a.nodeName)},input:function(a){return Y.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:nb(function(){return[0]}),last:nb(function(a,b){return[b-1]}),eq:nb(function(a,b,c){return[0>c?c+b:c]}),even:nb(function(a,b){for(var c=0;b>c;c+=2)a.push(c);return a}),odd:nb(function(a,b){for(var c=1;b>c;c+=2)a.push(c);return a}),lt:nb(function(a,b,c){for(var d=0>c?c+b:c;--d>=0;)a.push(d);return a}),gt:nb(function(a,b,c){for(var d=0>c?c+b:c;++d<b;)a.push(d);return a})}},d.pseudos.nth=d.pseudos.eq;for(b in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})d.pseudos[b]=lb(b);for(b in{submit:!0,reset:!0})d.pseudos[b]=mb(b);function pb(){}pb.prototype=d.filters=d.pseudos,d.setFilters=new pb,g=fb.tokenize=function(a,b){var c,e,f,g,h,i,j,k=z[a+" "];if(k)return b?0:k.slice(0);h=a,i=[],j=d.preFilter;while(h){(!c||(e=S.exec(h)))&&(e&&(h=h.slice(e[0].length)||h),i.push(f=[])),c=!1,(e=T.exec(h))&&(c=e.shift(),f.push({value:c,type:e[0].replace(R," ")}),h=h.slice(c.length));for(g in d.filter)!(e=X[g].exec(h))||j[g]&&!(e=j[g](e))||(c=e.shift(),f.push({value:c,type:g,matches:e}),h=h.slice(c.length));if(!c)break}return b?h.length:h?fb.error(a):z(a,i).slice(0)};function qb(a){for(var b=0,c=a.length,d="";c>b;b++)d+=a[b].value;return d}function rb(a,b,c){var d=b.dir,e=c&&"parentNode"===d,f=x++;return b.first?function(b,c,f){while(b=b[d])if(1===b.nodeType||e)return a(b,c,f)}:function(b,c,g){var h,i,j=[w,f];if(g){while(b=b[d])if((1===b.nodeType||e)&&a(b,c,g))return!0}else while(b=b[d])if(1===b.nodeType||e){if(i=b[u]||(b[u]={}),(h=i[d])&&h[0]===w&&h[1]===f)return j[2]=h[2];if(i[d]=j,j[2]=a(b,c,g))return!0}}}function sb(a){return a.length>1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function tb(a,b,c){for(var d=0,e=b.length;e>d;d++)fb(a,b[d],c);return c}function ub(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;i>h;h++)(f=a[h])&&(!c||c(f,d,e))&&(g.push(f),j&&b.push(h));return g}function vb(a,b,c,d,e,f){return d&&!d[u]&&(d=vb(d)),e&&!e[u]&&(e=vb(e,f)),hb(function(f,g,h,i){var j,k,l,m=[],n=[],o=g.length,p=f||tb(b||"*",h.nodeType?[h]:h,[]),q=!a||!f&&b?p:ub(p,m,a,h,i),r=c?e||(f?a:o||d)?[]:g:q;if(c&&c(q,r,h,i),d){j=ub(r,n),d(j,[],h,i),k=j.length;while(k--)(l=j[k])&&(r[n[k]]=!(q[n[k]]=l))}if(f){if(e||a){if(e){j=[],k=r.length;while(k--)(l=r[k])&&j.push(q[k]=l);e(null,r=[],j,i)}k=r.length;while(k--)(l=r[k])&&(j=e?K.call(f,l):m[k])>-1&&(f[j]=!(g[j]=l))}}else r=ub(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):I.apply(g,r)})}function wb(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],h=g||d.relative[" "],i=g?1:0,k=rb(function(a){return a===b},h,!0),l=rb(function(a){return K.call(b,a)>-1},h,!0),m=[function(a,c,d){return!g&&(d||c!==j)||((b=c).nodeType?k(a,c,d):l(a,c,d))}];f>i;i++)if(c=d.relative[a[i].type])m=[rb(sb(m),c)];else{if(c=d.filter[a[i].type].apply(null,a[i].matches),c[u]){for(e=++i;f>e;e++)if(d.relative[a[e].type])break;return vb(i>1&&sb(m),i>1&&qb(a.slice(0,i-1).concat({value:" "===a[i-2].type?"*":""})).replace(R,"$1"),c,e>i&&wb(a.slice(i,e)),f>e&&wb(a=a.slice(e)),f>e&&qb(a))}m.push(c)}return sb(m)}function xb(a,b){var c=b.length>0,e=a.length>0,f=function(f,g,h,i,k){var l,m,o,p=0,q="0",r=f&&[],s=[],t=j,u=f||e&&d.find.TAG("*",k),v=w+=null==t?1:Math.random()||.1,x=u.length;for(k&&(j=g!==n&&g);q!==x&&null!=(l=u[q]);q++){if(e&&l){m=0;while(o=a[m++])if(o(l,g,h)){i.push(l);break}k&&(w=v)}c&&((l=!o&&l)&&p--,f&&r.push(l))}if(p+=q,c&&q!==p){m=0;while(o=b[m++])o(r,s,g,h);if(f){if(p>0)while(q--)r[q]||s[q]||(s[q]=G.call(i));s=ub(s)}I.apply(i,s),k&&!f&&s.length>0&&p+b.length>1&&fb.uniqueSort(i)}return k&&(w=v,j=t),r};return c?hb(f):f}return h=fb.compile=function(a,b){var c,d=[],e=[],f=A[a+" "];if(!f){b||(b=g(a)),c=b.length;while(c--)f=wb(b[c]),f[u]?d.push(f):e.push(f);f=A(a,xb(e,d)),f.selector=a}return f},i=fb.select=function(a,b,e,f){var i,j,k,l,m,n="function"==typeof a&&a,o=!f&&g(a=n.selector||a);if(e=e||[],1===o.length){if(j=o[0]=o[0].slice(0),j.length>2&&"ID"===(k=j[0]).type&&c.getById&&9===b.nodeType&&p&&d.relative[j[1].type]){if(b=(d.find.ID(k.matches[0].replace(cb,db),b)||[])[0],!b)return e;n&&(b=b.parentNode),a=a.slice(j.shift().value.length)}i=X.needsContext.test(a)?0:j.length;while(i--){if(k=j[i],d.relative[l=k.type])break;if((m=d.find[l])&&(f=m(k.matches[0].replace(cb,db),ab.test(j[0].type)&&ob(b.parentNode)||b))){if(j.splice(i,1),a=f.length&&qb(j),!a)return I.apply(e,f),e;break}}}return(n||h(a,o))(f,b,!p,e,ab.test(a)&&ob(b.parentNode)||b),e},c.sortStable=u.split("").sort(B).join("")===u,c.detectDuplicates=!!l,m(),c.sortDetached=ib(function(a){return 1&a.compareDocumentPosition(n.createElement("div"))}),ib(function(a){return a.innerHTML="<a href='#'></a>","#"===a.firstChild.getAttribute("href")})||jb("type|href|height|width",function(a,b,c){return c?void 0:a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&ib(function(a){return a.innerHTML="<input/>",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||jb("value",function(a,b,c){return c||"input"!==a.nodeName.toLowerCase()?void 0:a.defaultValue}),ib(function(a){return null==a.getAttribute("disabled")})||jb(L,function(a,b,c){var d;return c?void 0:a[b]===!0?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),fb}(a);m.find=s,m.expr=s.selectors,m.expr[":"]=m.expr.pseudos,m.unique=s.uniqueSort,m.text=s.getText,m.isXMLDoc=s.isXML,m.contains=s.contains;var t=m.expr.match.needsContext,u=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,v=/^.[^:#\[\.,]*$/;function w(a,b,c){if(m.isFunction(b))return m.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return m.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(v.test(b))return m.filter(b,a,c);b=m.filter(b,a)}return m.grep(a,function(a){return m.inArray(a,b)>=0!==c})}m.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?m.find.matchesSelector(d,a)?[d]:[]:m.find.matches(a,m.grep(b,function(a){return 1===a.nodeType}))},m.fn.extend({find:function(a){var b,c=[],d=this,e=d.length;if("string"!=typeof a)return this.pushStack(m(a).filter(function(){for(b=0;e>b;b++)if(m.contains(d[b],this))return!0}));for(b=0;e>b;b++)m.find(a,d[b],c);return c=this.pushStack(e>1?m.unique(c):c),c.selector=this.selector?this.selector+" "+a:a,c},filter:function(a){return this.pushStack(w(this,a||[],!1))},not:function(a){return this.pushStack(w(this,a||[],!0))},is:function(a){return!!w(this,"string"==typeof a&&t.test(a)?m(a):a||[],!1).length}});var x,y=a.document,z=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,A=m.fn.init=function(a,b){var c,d;if(!a)return this;if("string"==typeof a){if(c="<"===a.charAt(0)&&">"===a.charAt(a.length-1)&&a.length>=3?[null,a,null]:z.exec(a),!c||!c[1]&&b)return!b||b.jquery?(b||x).find(a):this.constructor(b).find(a);if(c[1]){if(b=b instanceof m?b[0]:b,m.merge(this,m.parseHTML(c[1],b&&b.nodeType?b.ownerDocument||b:y,!0)),u.test(c[1])&&m.isPlainObject(b))for(c in b)m.isFunction(this[c])?this[c](b[c]):this.attr(c,b[c]);return this}if(d=y.getElementById(c[2]),d&&d.parentNode){if(d.id!==c[2])return x.find(a);this.length=1,this[0]=d}return this.context=y,this.selector=a,this}return a.nodeType?(this.context=this[0]=a,this.length=1,this):m.isFunction(a)?"undefined"!=typeof x.ready?x.ready(a):a(m):(void 0!==a.selector&&(this.selector=a.selector,this.context=a.context),m.makeArray(a,this))};A.prototype=m.fn,x=m(y);var B=/^(?:parents|prev(?:Until|All))/,C={children:!0,contents:!0,next:!0,prev:!0};m.extend({dir:function(a,b,c){var d=[],e=a[b];while(e&&9!==e.nodeType&&(void 0===c||1!==e.nodeType||!m(e).is(c)))1===e.nodeType&&d.push(e),e=e[b];return d},sibling:function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c}}),m.fn.extend({has:function(a){var b,c=m(a,this),d=c.length;return this.filter(function(){for(b=0;d>b;b++)if(m.contains(this,c[b]))return!0})},closest:function(a,b){for(var c,d=0,e=this.length,f=[],g=t.test(a)||"string"!=typeof a?m(a,b||this.context):0;e>d;d++)for(c=this[d];c&&c!==b;c=c.parentNode)if(c.nodeType<11&&(g?g.index(c)>-1:1===c.nodeType&&m.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?m.unique(f):f)},index:function(a){return a?"string"==typeof a?m.inArray(this[0],m(a)):m.inArray(a.jquery?a[0]:a,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(m.unique(m.merge(this.get(),m(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function D(a,b){do a=a[b];while(a&&1!==a.nodeType);return a}m.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return m.dir(a,"parentNode")},parentsUntil:function(a,b,c){return m.dir(a,"parentNode",c)},next:function(a){return D(a,"nextSibling")},prev:function(a){return D(a,"previousSibling")},nextAll:function(a){return m.dir(a,"nextSibling")},prevAll:function(a){return m.dir(a,"previousSibling")},nextUntil:function(a,b,c){return m.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return m.dir(a,"previousSibling",c)},siblings:function(a){return m.sibling((a.parentNode||{}).firstChild,a)},children:function(a){return m.sibling(a.firstChild)},contents:function(a){return m.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:m.merge([],a.childNodes)}},function(a,b){m.fn[a]=function(c,d){var e=m.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=m.filter(d,e)),this.length>1&&(C[a]||(e=m.unique(e)),B.test(a)&&(e=e.reverse())),this.pushStack(e)}});var E=/\S+/g,F={};function G(a){var b=F[a]={};return m.each(a.match(E)||[],function(a,c){b[c]=!0}),b}m.Callbacks=function(a){a="string"==typeof a?F[a]||G(a):m.extend({},a);var b,c,d,e,f,g,h=[],i=!a.once&&[],j=function(l){for(c=a.memory&&l,d=!0,f=g||0,g=0,e=h.length,b=!0;h&&e>f;f++)if(h[f].apply(l[0],l[1])===!1&&a.stopOnFalse){c=!1;break}b=!1,h&&(i?i.length&&j(i.shift()):c?h=[]:k.disable())},k={add:function(){if(h){var d=h.length;!function f(b){m.each(b,function(b,c){var d=m.type(c);"function"===d?a.unique&&k.has(c)||h.push(c):c&&c.length&&"string"!==d&&f(c)})}(arguments),b?e=h.length:c&&(g=d,j(c))}return this},remove:function(){return h&&m.each(arguments,function(a,c){var d;while((d=m.inArray(c,h,d))>-1)h.splice(d,1),b&&(e>=d&&e--,f>=d&&f--)}),this},has:function(a){return a?m.inArray(a,h)>-1:!(!h||!h.length)},empty:function(){return h=[],e=0,this},disable:function(){return h=i=c=void 0,this},disabled:function(){return!h},lock:function(){return i=void 0,c||k.disable(),this},locked:function(){return!i},fireWith:function(a,c){return!h||d&&!i||(c=c||[],c=[a,c.slice?c.slice():c],b?i.push(c):j(c)),this},fire:function(){return k.fireWith(this,arguments),this},fired:function(){return!!d}};return k},m.extend({Deferred:function(a){var b=[["resolve","done",m.Callbacks("once memory"),"resolved"],["reject","fail",m.Callbacks("once memory"),"rejected"],["notify","progress",m.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return m.Deferred(function(c){m.each(b,function(b,f){var g=m.isFunction(a[b])&&a[b];e[f[1]](function(){var a=g&&g.apply(this,arguments);a&&m.isFunction(a.promise)?a.promise().done(c.resolve).fail(c.reject).progress(c.notify):c[f[0]+"With"](this===d?c.promise():this,g?[a]:arguments)})}),a=null}).promise()},promise:function(a){return null!=a?m.extend(a,d):d}},e={};return d.pipe=d.then,m.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=function(){return e[f[0]+"With"](this===e?d:this,arguments),this},e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b=0,c=d.call(arguments),e=c.length,f=1!==e||a&&m.isFunction(a.promise)?e:0,g=1===f?a:m.Deferred(),h=function(a,b,c){return function(e){b[a]=this,c[a]=arguments.length>1?d.call(arguments):e,c===i?g.notifyWith(b,c):--f||g.resolveWith(b,c)}},i,j,k;if(e>1)for(i=new Array(e),j=new Array(e),k=new Array(e);e>b;b++)c[b]&&m.isFunction(c[b].promise)?c[b].promise().done(h(b,k,c)).fail(g.reject).progress(h(b,j,i)):--f;return f||g.resolveWith(k,c),g.promise()}});var H;m.fn.ready=function(a){return m.ready.promise().done(a),this},m.extend({isReady:!1,readyWait:1,holdReady:function(a){a?m.readyWait++:m.ready(!0)},ready:function(a){if(a===!0?!--m.readyWait:!m.isReady){if(!y.body)return setTimeout(m.ready);m.isReady=!0,a!==!0&&--m.readyWait>0||(H.resolveWith(y,[m]),m.fn.triggerHandler&&(m(y).triggerHandler("ready"),m(y).off("ready")))}}});function I(){y.addEventListener?(y.removeEventListener("DOMContentLoaded",J,!1),a.removeEventListener("load",J,!1)):(y.detachEvent("onreadystatechange",J),a.detachEvent("onload",J))}function J(){(y.addEventListener||"load"===event.type||"complete"===y.readyState)&&(I(),m.ready())}m.ready.promise=function(b){if(!H)if(H=m.Deferred(),"complete"===y.readyState)setTimeout(m.ready);else if(y.addEventListener)y.addEventListener("DOMContentLoaded",J,!1),a.addEventListener("load",J,!1);else{y.attachEvent("onreadystatechange",J),a.attachEvent("onload",J);var c=!1;try{c=null==a.frameElement&&y.documentElement}catch(d){}c&&c.doScroll&&!function e(){if(!m.isReady){try{c.doScroll("left")}catch(a){return setTimeout(e,50)}I(),m.ready()}}()}return H.promise(b)};var K="undefined",L;for(L in m(k))break;k.ownLast="0"!==L,k.inlineBlockNeedsLayout=!1,m(function(){var a,b,c,d;c=y.getElementsByTagName("body")[0],c&&c.style&&(b=y.createElement("div"),d=y.createElement("div"),d.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",c.appendChild(d).appendChild(b),typeof b.style.zoom!==K&&(b.style.cssText="display:inline;margin:0;border:0;padding:1px;width:1px;zoom:1",k.inlineBlockNeedsLayout=a=3===b.offsetWidth,a&&(c.style.zoom=1)),c.removeChild(d))}),function(){var a=y.createElement("div");if(null==k.deleteExpando){k.deleteExpando=!0;try{delete a.test}catch(b){k.deleteExpando=!1}}a=null}(),m.acceptData=function(a){var b=m.noData[(a.nodeName+" ").toLowerCase()],c=+a.nodeType||1;return 1!==c&&9!==c?!1:!b||b!==!0&&a.getAttribute("classid")===b};var M=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,N=/([A-Z])/g;function O(a,b,c){if(void 0===c&&1===a.nodeType){var d="data-"+b.replace(N,"-$1").toLowerCase();if(c=a.getAttribute(d),"string"==typeof c){try{c="true"===c?!0:"false"===c?!1:"null"===c?null:+c+""===c?+c:M.test(c)?m.parseJSON(c):c}catch(e){}m.data(a,b,c)}else c=void 0}return c}function P(a){var b;for(b in a)if(("data"!==b||!m.isEmptyObject(a[b]))&&"toJSON"!==b)return!1;return!0}function Q(a,b,d,e){if(m.acceptData(a)){var f,g,h=m.expando,i=a.nodeType,j=i?m.cache:a,k=i?a[h]:a[h]&&h;
+if(k&&j[k]&&(e||j[k].data)||void 0!==d||"string"!=typeof b)return k||(k=i?a[h]=c.pop()||m.guid++:h),j[k]||(j[k]=i?{}:{toJSON:m.noop}),("object"==typeof b||"function"==typeof b)&&(e?j[k]=m.extend(j[k],b):j[k].data=m.extend(j[k].data,b)),g=j[k],e||(g.data||(g.data={}),g=g.data),void 0!==d&&(g[m.camelCase(b)]=d),"string"==typeof b?(f=g[b],null==f&&(f=g[m.camelCase(b)])):f=g,f}}function R(a,b,c){if(m.acceptData(a)){var d,e,f=a.nodeType,g=f?m.cache:a,h=f?a[m.expando]:m.expando;if(g[h]){if(b&&(d=c?g[h]:g[h].data)){m.isArray(b)?b=b.concat(m.map(b,m.camelCase)):b in d?b=[b]:(b=m.camelCase(b),b=b in d?[b]:b.split(" ")),e=b.length;while(e--)delete d[b[e]];if(c?!P(d):!m.isEmptyObject(d))return}(c||(delete g[h].data,P(g[h])))&&(f?m.cleanData([a],!0):k.deleteExpando||g!=g.window?delete g[h]:g[h]=null)}}}m.extend({cache:{},noData:{"applet ":!0,"embed ":!0,"object ":"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(a){return a=a.nodeType?m.cache[a[m.expando]]:a[m.expando],!!a&&!P(a)},data:function(a,b,c){return Q(a,b,c)},removeData:function(a,b){return R(a,b)},_data:function(a,b,c){return Q(a,b,c,!0)},_removeData:function(a,b){return R(a,b,!0)}}),m.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=m.data(f),1===f.nodeType&&!m._data(f,"parsedAttrs"))){c=g.length;while(c--)g[c]&&(d=g[c].name,0===d.indexOf("data-")&&(d=m.camelCase(d.slice(5)),O(f,d,e[d])));m._data(f,"parsedAttrs",!0)}return e}return"object"==typeof a?this.each(function(){m.data(this,a)}):arguments.length>1?this.each(function(){m.data(this,a,b)}):f?O(f,a,m.data(f,a)):void 0},removeData:function(a){return this.each(function(){m.removeData(this,a)})}}),m.extend({queue:function(a,b,c){var d;return a?(b=(b||"fx")+"queue",d=m._data(a,b),c&&(!d||m.isArray(c)?d=m._data(a,b,m.makeArray(c)):d.push(c)),d||[]):void 0},dequeue:function(a,b){b=b||"fx";var c=m.queue(a,b),d=c.length,e=c.shift(),f=m._queueHooks(a,b),g=function(){m.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return m._data(a,c)||m._data(a,c,{empty:m.Callbacks("once memory").add(function(){m._removeData(a,b+"queue"),m._removeData(a,c)})})}}),m.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.length<c?m.queue(this[0],a):void 0===b?this:this.each(function(){var c=m.queue(this,a,b);m._queueHooks(this,a),"fx"===a&&"inprogress"!==c[0]&&m.dequeue(this,a)})},dequeue:function(a){return this.each(function(){m.dequeue(this,a)})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,b){var c,d=1,e=m.Deferred(),f=this,g=this.length,h=function(){--d||e.resolveWith(f,[f])};"string"!=typeof a&&(b=a,a=void 0),a=a||"fx";while(g--)c=m._data(f[g],a+"queueHooks"),c&&c.empty&&(d++,c.empty.add(h));return h(),e.promise(b)}});var S=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,T=["Top","Right","Bottom","Left"],U=function(a,b){return a=b||a,"none"===m.css(a,"display")||!m.contains(a.ownerDocument,a)},V=m.access=function(a,b,c,d,e,f,g){var h=0,i=a.length,j=null==c;if("object"===m.type(c)){e=!0;for(h in c)m.access(a,b,h,c[h],!0,f,g)}else if(void 0!==d&&(e=!0,m.isFunction(d)||(g=!0),j&&(g?(b.call(a,d),b=null):(j=b,b=function(a,b,c){return j.call(m(a),c)})),b))for(;i>h;h++)b(a[h],c,g?d:d.call(a[h],h,b(a[h],c)));return e?a:j?b.call(a):i?b(a[0],c):f},W=/^(?:checkbox|radio)$/i;!function(){var a=y.createElement("input"),b=y.createElement("div"),c=y.createDocumentFragment();if(b.innerHTML="  <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",k.leadingWhitespace=3===b.firstChild.nodeType,k.tbody=!b.getElementsByTagName("tbody").length,k.htmlSerialize=!!b.getElementsByTagName("link").length,k.html5Clone="<:nav></:nav>"!==y.createElement("nav").cloneNode(!0).outerHTML,a.type="checkbox",a.checked=!0,c.appendChild(a),k.appendChecked=a.checked,b.innerHTML="<textarea>x</textarea>",k.noCloneChecked=!!b.cloneNode(!0).lastChild.defaultValue,c.appendChild(b),b.innerHTML="<input type='radio' checked='checked' name='t'/>",k.checkClone=b.cloneNode(!0).cloneNode(!0).lastChild.checked,k.noCloneEvent=!0,b.attachEvent&&(b.attachEvent("onclick",function(){k.noCloneEvent=!1}),b.cloneNode(!0).click()),null==k.deleteExpando){k.deleteExpando=!0;try{delete b.test}catch(d){k.deleteExpando=!1}}}(),function(){var b,c,d=y.createElement("div");for(b in{submit:!0,change:!0,focusin:!0})c="on"+b,(k[b+"Bubbles"]=c in a)||(d.setAttribute(c,"t"),k[b+"Bubbles"]=d.attributes[c].expando===!1);d=null}();var X=/^(?:input|select|textarea)$/i,Y=/^key/,Z=/^(?:mouse|pointer|contextmenu)|click/,$=/^(?:focusinfocus|focusoutblur)$/,_=/^([^.]*)(?:\.(.+)|)$/;function ab(){return!0}function bb(){return!1}function cb(){try{return y.activeElement}catch(a){}}m.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,n,o,p,q,r=m._data(a);if(r){c.handler&&(i=c,c=i.handler,e=i.selector),c.guid||(c.guid=m.guid++),(g=r.events)||(g=r.events={}),(k=r.handle)||(k=r.handle=function(a){return typeof m===K||a&&m.event.triggered===a.type?void 0:m.event.dispatch.apply(k.elem,arguments)},k.elem=a),b=(b||"").match(E)||[""],h=b.length;while(h--)f=_.exec(b[h])||[],o=q=f[1],p=(f[2]||"").split(".").sort(),o&&(j=m.event.special[o]||{},o=(e?j.delegateType:j.bindType)||o,j=m.event.special[o]||{},l=m.extend({type:o,origType:q,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&m.expr.match.needsContext.test(e),namespace:p.join(".")},i),(n=g[o])||(n=g[o]=[],n.delegateCount=0,j.setup&&j.setup.call(a,d,p,k)!==!1||(a.addEventListener?a.addEventListener(o,k,!1):a.attachEvent&&a.attachEvent("on"+o,k))),j.add&&(j.add.call(a,l),l.handler.guid||(l.handler.guid=c.guid)),e?n.splice(n.delegateCount++,0,l):n.push(l),m.event.global[o]=!0);a=null}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,n,o,p,q,r=m.hasData(a)&&m._data(a);if(r&&(k=r.events)){b=(b||"").match(E)||[""],j=b.length;while(j--)if(h=_.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o){l=m.event.special[o]||{},o=(d?l.delegateType:l.bindType)||o,n=k[o]||[],h=h[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),i=f=n.length;while(f--)g=n[f],!e&&q!==g.origType||c&&c.guid!==g.guid||h&&!h.test(g.namespace)||d&&d!==g.selector&&("**"!==d||!g.selector)||(n.splice(f,1),g.selector&&n.delegateCount--,l.remove&&l.remove.call(a,g));i&&!n.length&&(l.teardown&&l.teardown.call(a,p,r.handle)!==!1||m.removeEvent(a,o,r.handle),delete k[o])}else for(o in k)m.event.remove(a,o+b[j],c,d,!0);m.isEmptyObject(k)&&(delete r.handle,m._removeData(a,"events"))}},trigger:function(b,c,d,e){var f,g,h,i,k,l,n,o=[d||y],p=j.call(b,"type")?b.type:b,q=j.call(b,"namespace")?b.namespace.split("."):[];if(h=l=d=d||y,3!==d.nodeType&&8!==d.nodeType&&!$.test(p+m.event.triggered)&&(p.indexOf(".")>=0&&(q=p.split("."),p=q.shift(),q.sort()),g=p.indexOf(":")<0&&"on"+p,b=b[m.expando]?b:new m.Event(p,"object"==typeof b&&b),b.isTrigger=e?2:3,b.namespace=q.join("."),b.namespace_re=b.namespace?new RegExp("(^|\\.)"+q.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,b.result=void 0,b.target||(b.target=d),c=null==c?[b]:m.makeArray(c,[b]),k=m.event.special[p]||{},e||!k.trigger||k.trigger.apply(d,c)!==!1)){if(!e&&!k.noBubble&&!m.isWindow(d)){for(i=k.delegateType||p,$.test(i+p)||(h=h.parentNode);h;h=h.parentNode)o.push(h),l=h;l===(d.ownerDocument||y)&&o.push(l.defaultView||l.parentWindow||a)}n=0;while((h=o[n++])&&!b.isPropagationStopped())b.type=n>1?i:k.bindType||p,f=(m._data(h,"events")||{})[b.type]&&m._data(h,"handle"),f&&f.apply(h,c),f=g&&h[g],f&&f.apply&&m.acceptData(h)&&(b.result=f.apply(h,c),b.result===!1&&b.preventDefault());if(b.type=p,!e&&!b.isDefaultPrevented()&&(!k._default||k._default.apply(o.pop(),c)===!1)&&m.acceptData(d)&&g&&d[p]&&!m.isWindow(d)){l=d[g],l&&(d[g]=null),m.event.triggered=p;try{d[p]()}catch(r){}m.event.triggered=void 0,l&&(d[g]=l)}return b.result}},dispatch:function(a){a=m.event.fix(a);var b,c,e,f,g,h=[],i=d.call(arguments),j=(m._data(this,"events")||{})[a.type]||[],k=m.event.special[a.type]||{};if(i[0]=a,a.delegateTarget=this,!k.preDispatch||k.preDispatch.call(this,a)!==!1){h=m.event.handlers.call(this,a,j),b=0;while((f=h[b++])&&!a.isPropagationStopped()){a.currentTarget=f.elem,g=0;while((e=f.handlers[g++])&&!a.isImmediatePropagationStopped())(!a.namespace_re||a.namespace_re.test(e.namespace))&&(a.handleObj=e,a.data=e.data,c=((m.event.special[e.origType]||{}).handle||e.handler).apply(f.elem,i),void 0!==c&&(a.result=c)===!1&&(a.preventDefault(),a.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,a),a.result}},handlers:function(a,b){var c,d,e,f,g=[],h=b.delegateCount,i=a.target;if(h&&i.nodeType&&(!a.button||"click"!==a.type))for(;i!=this;i=i.parentNode||this)if(1===i.nodeType&&(i.disabled!==!0||"click"!==a.type)){for(e=[],f=0;h>f;f++)d=b[f],c=d.selector+" ",void 0===e[c]&&(e[c]=d.needsContext?m(c,this).index(i)>=0:m.find(c,this,null,[i]).length),e[c]&&e.push(d);e.length&&g.push({elem:i,handlers:e})}return h<b.length&&g.push({elem:this,handlers:b.slice(h)}),g},fix:function(a){if(a[m.expando])return a;var b,c,d,e=a.type,f=a,g=this.fixHooks[e];g||(this.fixHooks[e]=g=Z.test(e)?this.mouseHooks:Y.test(e)?this.keyHooks:{}),d=g.props?this.props.concat(g.props):this.props,a=new m.Event(f),b=d.length;while(b--)c=d[b],a[c]=f[c];return a.target||(a.target=f.srcElement||y),3===a.target.nodeType&&(a.target=a.target.parentNode),a.metaKey=!!a.metaKey,g.filter?g.filter(a,f):a},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(a,b){return null==a.which&&(a.which=null!=b.charCode?b.charCode:b.keyCode),a}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(a,b){var c,d,e,f=b.button,g=b.fromElement;return null==a.pageX&&null!=b.clientX&&(d=a.target.ownerDocument||y,e=d.documentElement,c=d.body,a.pageX=b.clientX+(e&&e.scrollLeft||c&&c.scrollLeft||0)-(e&&e.clientLeft||c&&c.clientLeft||0),a.pageY=b.clientY+(e&&e.scrollTop||c&&c.scrollTop||0)-(e&&e.clientTop||c&&c.clientTop||0)),!a.relatedTarget&&g&&(a.relatedTarget=g===a.target?b.toElement:g),a.which||void 0===f||(a.which=1&f?1:2&f?3:4&f?2:0),a}},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==cb()&&this.focus)try{return this.focus(),!1}catch(a){}},delegateType:"focusin"},blur:{trigger:function(){return this===cb()&&this.blur?(this.blur(),!1):void 0},delegateType:"focusout"},click:{trigger:function(){return m.nodeName(this,"input")&&"checkbox"===this.type&&this.click?(this.click(),!1):void 0},_default:function(a){return m.nodeName(a.target,"a")}},beforeunload:{postDispatch:function(a){void 0!==a.result&&a.originalEvent&&(a.originalEvent.returnValue=a.result)}}},simulate:function(a,b,c,d){var e=m.extend(new m.Event,c,{type:a,isSimulated:!0,originalEvent:{}});d?m.event.trigger(e,null,b):m.event.dispatch.call(b,e),e.isDefaultPrevented()&&c.preventDefault()}},m.removeEvent=y.removeEventListener?function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c,!1)}:function(a,b,c){var d="on"+b;a.detachEvent&&(typeof a[d]===K&&(a[d]=null),a.detachEvent(d,c))},m.Event=function(a,b){return this instanceof m.Event?(a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||void 0===a.defaultPrevented&&a.returnValue===!1?ab:bb):this.type=a,b&&m.extend(this,b),this.timeStamp=a&&a.timeStamp||m.now(),void(this[m.expando]=!0)):new m.Event(a,b)},m.Event.prototype={isDefaultPrevented:bb,isPropagationStopped:bb,isImmediatePropagationStopped:bb,preventDefault:function(){var a=this.originalEvent;this.isDefaultPrevented=ab,a&&(a.preventDefault?a.preventDefault():a.returnValue=!1)},stopPropagation:function(){var a=this.originalEvent;this.isPropagationStopped=ab,a&&(a.stopPropagation&&a.stopPropagation(),a.cancelBubble=!0)},stopImmediatePropagation:function(){var a=this.originalEvent;this.isImmediatePropagationStopped=ab,a&&a.stopImmediatePropagation&&a.stopImmediatePropagation(),this.stopPropagation()}},m.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(a,b){m.event.special[a]={delegateType:b,bindType:b,handle:function(a){var c,d=this,e=a.relatedTarget,f=a.handleObj;return(!e||e!==d&&!m.contains(d,e))&&(a.type=f.origType,c=f.handler.apply(this,arguments),a.type=b),c}}}),k.submitBubbles||(m.event.special.submit={setup:function(){return m.nodeName(this,"form")?!1:void m.event.add(this,"click._submit keypress._submit",function(a){var b=a.target,c=m.nodeName(b,"input")||m.nodeName(b,"button")?b.form:void 0;c&&!m._data(c,"submitBubbles")&&(m.event.add(c,"submit._submit",function(a){a._submit_bubble=!0}),m._data(c,"submitBubbles",!0))})},postDispatch:function(a){a._submit_bubble&&(delete a._submit_bubble,this.parentNode&&!a.isTrigger&&m.event.simulate("submit",this.parentNode,a,!0))},teardown:function(){return m.nodeName(this,"form")?!1:void m.event.remove(this,"._submit")}}),k.changeBubbles||(m.event.special.change={setup:function(){return X.test(this.nodeName)?(("checkbox"===this.type||"radio"===this.type)&&(m.event.add(this,"propertychange._change",function(a){"checked"===a.originalEvent.propertyName&&(this._just_changed=!0)}),m.event.add(this,"click._change",function(a){this._just_changed&&!a.isTrigger&&(this._just_changed=!1),m.event.simulate("change",this,a,!0)})),!1):void m.event.add(this,"beforeactivate._change",function(a){var b=a.target;X.test(b.nodeName)&&!m._data(b,"changeBubbles")&&(m.event.add(b,"change._change",function(a){!this.parentNode||a.isSimulated||a.isTrigger||m.event.simulate("change",this.parentNode,a,!0)}),m._data(b,"changeBubbles",!0))})},handle:function(a){var b=a.target;return this!==b||a.isSimulated||a.isTrigger||"radio"!==b.type&&"checkbox"!==b.type?a.handleObj.handler.apply(this,arguments):void 0},teardown:function(){return m.event.remove(this,"._change"),!X.test(this.nodeName)}}),k.focusinBubbles||m.each({focus:"focusin",blur:"focusout"},function(a,b){var c=function(a){m.event.simulate(b,a.target,m.event.fix(a),!0)};m.event.special[b]={setup:function(){var d=this.ownerDocument||this,e=m._data(d,b);e||d.addEventListener(a,c,!0),m._data(d,b,(e||0)+1)},teardown:function(){var d=this.ownerDocument||this,e=m._data(d,b)-1;e?m._data(d,b,e):(d.removeEventListener(a,c,!0),m._removeData(d,b))}}}),m.fn.extend({on:function(a,b,c,d,e){var f,g;if("object"==typeof a){"string"!=typeof b&&(c=c||b,b=void 0);for(f in a)this.on(f,b,c,a[f],e);return this}if(null==c&&null==d?(d=b,c=b=void 0):null==d&&("string"==typeof b?(d=c,c=void 0):(d=c,c=b,b=void 0)),d===!1)d=bb;else if(!d)return this;return 1===e&&(g=d,d=function(a){return m().off(a),g.apply(this,arguments)},d.guid=g.guid||(g.guid=m.guid++)),this.each(function(){m.event.add(this,a,d,c,b)})},one:function(a,b,c,d){return this.on(a,b,c,d,1)},off:function(a,b,c){var d,e;if(a&&a.preventDefault&&a.handleObj)return d=a.handleObj,m(a.delegateTarget).off(d.namespace?d.origType+"."+d.namespace:d.origType,d.selector,d.handler),this;if("object"==typeof a){for(e in a)this.off(e,b,a[e]);return this}return(b===!1||"function"==typeof b)&&(c=b,b=void 0),c===!1&&(c=bb),this.each(function(){m.event.remove(this,a,c,b)})},trigger:function(a,b){return this.each(function(){m.event.trigger(a,b,this)})},triggerHandler:function(a,b){var c=this[0];return c?m.event.trigger(a,b,c,!0):void 0}});function db(a){var b=eb.split("|"),c=a.createDocumentFragment();if(c.createElement)while(b.length)c.createElement(b.pop());return c}var eb="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",fb=/ jQuery\d+="(?:null|\d+)"/g,gb=new RegExp("<(?:"+eb+")[\\s/>]","i"),hb=/^\s+/,ib=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,jb=/<([\w:]+)/,kb=/<tbody/i,lb=/<|&#?\w+;/,mb=/<(?:script|style|link)/i,nb=/checked\s*(?:[^=]|=\s*.checked.)/i,ob=/^$|\/(?:java|ecma)script/i,pb=/^true\/(.*)/,qb=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,rb={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],area:[1,"<map>","</map>"],param:[1,"<object>","</object>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:k.htmlSerialize?[0,"",""]:[1,"X<div>","</div>"]},sb=db(y),tb=sb.appendChild(y.createElement("div"));rb.optgroup=rb.option,rb.tbody=rb.tfoot=rb.colgroup=rb.caption=rb.thead,rb.th=rb.td;function ub(a,b){var c,d,e=0,f=typeof a.getElementsByTagName!==K?a.getElementsByTagName(b||"*"):typeof a.querySelectorAll!==K?a.querySelectorAll(b||"*"):void 0;if(!f)for(f=[],c=a.childNodes||a;null!=(d=c[e]);e++)!b||m.nodeName(d,b)?f.push(d):m.merge(f,ub(d,b));return void 0===b||b&&m.nodeName(a,b)?m.merge([a],f):f}function vb(a){W.test(a.type)&&(a.defaultChecked=a.checked)}function wb(a,b){return m.nodeName(a,"table")&&m.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function xb(a){return a.type=(null!==m.find.attr(a,"type"))+"/"+a.type,a}function yb(a){var b=pb.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function zb(a,b){for(var c,d=0;null!=(c=a[d]);d++)m._data(c,"globalEval",!b||m._data(b[d],"globalEval"))}function Ab(a,b){if(1===b.nodeType&&m.hasData(a)){var c,d,e,f=m._data(a),g=m._data(b,f),h=f.events;if(h){delete g.handle,g.events={};for(c in h)for(d=0,e=h[c].length;e>d;d++)m.event.add(b,c,h[c][d])}g.data&&(g.data=m.extend({},g.data))}}function Bb(a,b){var c,d,e;if(1===b.nodeType){if(c=b.nodeName.toLowerCase(),!k.noCloneEvent&&b[m.expando]){e=m._data(b);for(d in e.events)m.removeEvent(b,d,e.handle);b.removeAttribute(m.expando)}"script"===c&&b.text!==a.text?(xb(b).text=a.text,yb(b)):"object"===c?(b.parentNode&&(b.outerHTML=a.outerHTML),k.html5Clone&&a.innerHTML&&!m.trim(b.innerHTML)&&(b.innerHTML=a.innerHTML)):"input"===c&&W.test(a.type)?(b.defaultChecked=b.checked=a.checked,b.value!==a.value&&(b.value=a.value)):"option"===c?b.defaultSelected=b.selected=a.defaultSelected:("input"===c||"textarea"===c)&&(b.defaultValue=a.defaultValue)}}m.extend({clone:function(a,b,c){var d,e,f,g,h,i=m.contains(a.ownerDocument,a);if(k.html5Clone||m.isXMLDoc(a)||!gb.test("<"+a.nodeName+">")?f=a.cloneNode(!0):(tb.innerHTML=a.outerHTML,tb.removeChild(f=tb.firstChild)),!(k.noCloneEvent&&k.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||m.isXMLDoc(a)))for(d=ub(f),h=ub(a),g=0;null!=(e=h[g]);++g)d[g]&&Bb(e,d[g]);if(b)if(c)for(h=h||ub(a),d=d||ub(f),g=0;null!=(e=h[g]);g++)Ab(e,d[g]);else Ab(a,f);return d=ub(f,"script"),d.length>0&&zb(d,!i&&ub(a,"script")),d=h=e=null,f},buildFragment:function(a,b,c,d){for(var e,f,g,h,i,j,l,n=a.length,o=db(b),p=[],q=0;n>q;q++)if(f=a[q],f||0===f)if("object"===m.type(f))m.merge(p,f.nodeType?[f]:f);else if(lb.test(f)){h=h||o.appendChild(b.createElement("div")),i=(jb.exec(f)||["",""])[1].toLowerCase(),l=rb[i]||rb._default,h.innerHTML=l[1]+f.replace(ib,"<$1></$2>")+l[2],e=l[0];while(e--)h=h.lastChild;if(!k.leadingWhitespace&&hb.test(f)&&p.push(b.createTextNode(hb.exec(f)[0])),!k.tbody){f="table"!==i||kb.test(f)?"<table>"!==l[1]||kb.test(f)?0:h:h.firstChild,e=f&&f.childNodes.length;while(e--)m.nodeName(j=f.childNodes[e],"tbody")&&!j.childNodes.length&&f.removeChild(j)}m.merge(p,h.childNodes),h.textContent="";while(h.firstChild)h.removeChild(h.firstChild);h=o.lastChild}else p.push(b.createTextNode(f));h&&o.removeChild(h),k.appendChecked||m.grep(ub(p,"input"),vb),q=0;while(f=p[q++])if((!d||-1===m.inArray(f,d))&&(g=m.contains(f.ownerDocument,f),h=ub(o.appendChild(f),"script"),g&&zb(h),c)){e=0;while(f=h[e++])ob.test(f.type||"")&&c.push(f)}return h=null,o},cleanData:function(a,b){for(var d,e,f,g,h=0,i=m.expando,j=m.cache,l=k.deleteExpando,n=m.event.special;null!=(d=a[h]);h++)if((b||m.acceptData(d))&&(f=d[i],g=f&&j[f])){if(g.events)for(e in g.events)n[e]?m.event.remove(d,e):m.removeEvent(d,e,g.handle);j[f]&&(delete j[f],l?delete d[i]:typeof d.removeAttribute!==K?d.removeAttribute(i):d[i]=null,c.push(f))}}}),m.fn.extend({text:function(a){return V(this,function(a){return void 0===a?m.text(this):this.empty().append((this[0]&&this[0].ownerDocument||y).createTextNode(a))},null,a,arguments.length)},append:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=wb(this,a);b.appendChild(a)}})},prepend:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=wb(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},remove:function(a,b){for(var c,d=a?m.filter(a,this):this,e=0;null!=(c=d[e]);e++)b||1!==c.nodeType||m.cleanData(ub(c)),c.parentNode&&(b&&m.contains(c.ownerDocument,c)&&zb(ub(c,"script")),c.parentNode.removeChild(c));return this},empty:function(){for(var a,b=0;null!=(a=this[b]);b++){1===a.nodeType&&m.cleanData(ub(a,!1));while(a.firstChild)a.removeChild(a.firstChild);a.options&&m.nodeName(a,"select")&&(a.options.length=0)}return this},clone:function(a,b){return a=null==a?!1:a,b=null==b?a:b,this.map(function(){return m.clone(this,a,b)})},html:function(a){return V(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a)return 1===b.nodeType?b.innerHTML.replace(fb,""):void 0;if(!("string"!=typeof a||mb.test(a)||!k.htmlSerialize&&gb.test(a)||!k.leadingWhitespace&&hb.test(a)||rb[(jb.exec(a)||["",""])[1].toLowerCase()])){a=a.replace(ib,"<$1></$2>");try{for(;d>c;c++)b=this[c]||{},1===b.nodeType&&(m.cleanData(ub(b,!1)),b.innerHTML=a);b=0}catch(e){}}b&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(){var a=arguments[0];return this.domManip(arguments,function(b){a=this.parentNode,m.cleanData(ub(this)),a&&a.replaceChild(b,this)}),a&&(a.length||a.nodeType)?this:this.remove()},detach:function(a){return this.remove(a,!0)},domManip:function(a,b){a=e.apply([],a);var c,d,f,g,h,i,j=0,l=this.length,n=this,o=l-1,p=a[0],q=m.isFunction(p);if(q||l>1&&"string"==typeof p&&!k.checkClone&&nb.test(p))return this.each(function(c){var d=n.eq(c);q&&(a[0]=p.call(this,c,d.html())),d.domManip(a,b)});if(l&&(i=m.buildFragment(a,this[0].ownerDocument,!1,this),c=i.firstChild,1===i.childNodes.length&&(i=c),c)){for(g=m.map(ub(i,"script"),xb),f=g.length;l>j;j++)d=i,j!==o&&(d=m.clone(d,!0,!0),f&&m.merge(g,ub(d,"script"))),b.call(this[j],d,j);if(f)for(h=g[g.length-1].ownerDocument,m.map(g,yb),j=0;f>j;j++)d=g[j],ob.test(d.type||"")&&!m._data(d,"globalEval")&&m.contains(h,d)&&(d.src?m._evalUrl&&m._evalUrl(d.src):m.globalEval((d.text||d.textContent||d.innerHTML||"").replace(qb,"")));i=c=null}return this}}),m.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){m.fn[a]=function(a){for(var c,d=0,e=[],g=m(a),h=g.length-1;h>=d;d++)c=d===h?this:this.clone(!0),m(g[d])[b](c),f.apply(e,c.get());return this.pushStack(e)}});var Cb,Db={};function Eb(b,c){var d,e=m(c.createElement(b)).appendTo(c.body),f=a.getDefaultComputedStyle&&(d=a.getDefaultComputedStyle(e[0]))?d.display:m.css(e[0],"display");return e.detach(),f}function Fb(a){var b=y,c=Db[a];return c||(c=Eb(a,b),"none"!==c&&c||(Cb=(Cb||m("<iframe frameborder='0' width='0' height='0'/>")).appendTo(b.documentElement),b=(Cb[0].contentWindow||Cb[0].contentDocument).document,b.write(),b.close(),c=Eb(a,b),Cb.detach()),Db[a]=c),c}!function(){var a;k.shrinkWrapBlocks=function(){if(null!=a)return a;a=!1;var b,c,d;return c=y.getElementsByTagName("body")[0],c&&c.style?(b=y.createElement("div"),d=y.createElement("div"),d.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",c.appendChild(d).appendChild(b),typeof b.style.zoom!==K&&(b.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:1px;width:1px;zoom:1",b.appendChild(y.createElement("div")).style.width="5px",a=3!==b.offsetWidth),c.removeChild(d),a):void 0}}();var Gb=/^margin/,Hb=new RegExp("^("+S+")(?!px)[a-z%]+$","i"),Ib,Jb,Kb=/^(top|right|bottom|left)$/;a.getComputedStyle?(Ib=function(a){return a.ownerDocument.defaultView.getComputedStyle(a,null)},Jb=function(a,b,c){var d,e,f,g,h=a.style;return c=c||Ib(a),g=c?c.getPropertyValue(b)||c[b]:void 0,c&&(""!==g||m.contains(a.ownerDocument,a)||(g=m.style(a,b)),Hb.test(g)&&Gb.test(b)&&(d=h.width,e=h.minWidth,f=h.maxWidth,h.minWidth=h.maxWidth=h.width=g,g=c.width,h.width=d,h.minWidth=e,h.maxWidth=f)),void 0===g?g:g+""}):y.documentElement.currentStyle&&(Ib=function(a){return a.currentStyle},Jb=function(a,b,c){var d,e,f,g,h=a.style;return c=c||Ib(a),g=c?c[b]:void 0,null==g&&h&&h[b]&&(g=h[b]),Hb.test(g)&&!Kb.test(b)&&(d=h.left,e=a.runtimeStyle,f=e&&e.left,f&&(e.left=a.currentStyle.left),h.left="fontSize"===b?"1em":g,g=h.pixelLeft+"px",h.left=d,f&&(e.left=f)),void 0===g?g:g+""||"auto"});function Lb(a,b){return{get:function(){var c=a();if(null!=c)return c?void delete this.get:(this.get=b).apply(this,arguments)}}}!function(){var b,c,d,e,f,g,h;if(b=y.createElement("div"),b.innerHTML="  <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",d=b.getElementsByTagName("a")[0],c=d&&d.style){c.cssText="float:left;opacity:.5",k.opacity="0.5"===c.opacity,k.cssFloat=!!c.cssFloat,b.style.backgroundClip="content-box",b.cloneNode(!0).style.backgroundClip="",k.clearCloneStyle="content-box"===b.style.backgroundClip,k.boxSizing=""===c.boxSizing||""===c.MozBoxSizing||""===c.WebkitBoxSizing,m.extend(k,{reliableHiddenOffsets:function(){return null==g&&i(),g},boxSizingReliable:function(){return null==f&&i(),f},pixelPosition:function(){return null==e&&i(),e},reliableMarginRight:function(){return null==h&&i(),h}});function i(){var b,c,d,i;c=y.getElementsByTagName("body")[0],c&&c.style&&(b=y.createElement("div"),d=y.createElement("div"),d.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",c.appendChild(d).appendChild(b),b.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;display:block;margin-top:1%;top:1%;border:1px;padding:1px;width:4px;position:absolute",e=f=!1,h=!0,a.getComputedStyle&&(e="1%"!==(a.getComputedStyle(b,null)||{}).top,f="4px"===(a.getComputedStyle(b,null)||{width:"4px"}).width,i=b.appendChild(y.createElement("div")),i.style.cssText=b.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",i.style.marginRight=i.style.width="0",b.style.width="1px",h=!parseFloat((a.getComputedStyle(i,null)||{}).marginRight)),b.innerHTML="<table><tr><td></td><td>t</td></tr></table>",i=b.getElementsByTagName("td"),i[0].style.cssText="margin:0;border:0;padding:0;display:none",g=0===i[0].offsetHeight,g&&(i[0].style.display="",i[1].style.display="none",g=0===i[0].offsetHeight),c.removeChild(d))}}}(),m.swap=function(a,b,c,d){var e,f,g={};for(f in b)g[f]=a.style[f],a.style[f]=b[f];e=c.apply(a,d||[]);for(f in b)a.style[f]=g[f];return e};var Mb=/alpha\([^)]*\)/i,Nb=/opacity\s*=\s*([^)]*)/,Ob=/^(none|table(?!-c[ea]).+)/,Pb=new RegExp("^("+S+")(.*)$","i"),Qb=new RegExp("^([+-])=("+S+")","i"),Rb={position:"absolute",visibility:"hidden",display:"block"},Sb={letterSpacing:"0",fontWeight:"400"},Tb=["Webkit","O","Moz","ms"];function Ub(a,b){if(b in a)return b;var c=b.charAt(0).toUpperCase()+b.slice(1),d=b,e=Tb.length;while(e--)if(b=Tb[e]+c,b in a)return b;return d}function Vb(a,b){for(var c,d,e,f=[],g=0,h=a.length;h>g;g++)d=a[g],d.style&&(f[g]=m._data(d,"olddisplay"),c=d.style.display,b?(f[g]||"none"!==c||(d.style.display=""),""===d.style.display&&U(d)&&(f[g]=m._data(d,"olddisplay",Fb(d.nodeName)))):(e=U(d),(c&&"none"!==c||!e)&&m._data(d,"olddisplay",e?c:m.css(d,"display"))));for(g=0;h>g;g++)d=a[g],d.style&&(b&&"none"!==d.style.display&&""!==d.style.display||(d.style.display=b?f[g]||"":"none"));return a}function Wb(a,b,c){var d=Pb.exec(b);return d?Math.max(0,d[1]-(c||0))+(d[2]||"px"):b}function Xb(a,b,c,d,e){for(var f=c===(d?"border":"content")?4:"width"===b?1:0,g=0;4>f;f+=2)"margin"===c&&(g+=m.css(a,c+T[f],!0,e)),d?("content"===c&&(g-=m.css(a,"padding"+T[f],!0,e)),"margin"!==c&&(g-=m.css(a,"border"+T[f]+"Width",!0,e))):(g+=m.css(a,"padding"+T[f],!0,e),"padding"!==c&&(g+=m.css(a,"border"+T[f]+"Width",!0,e)));return g}function Yb(a,b,c){var d=!0,e="width"===b?a.offsetWidth:a.offsetHeight,f=Ib(a),g=k.boxSizing&&"border-box"===m.css(a,"boxSizing",!1,f);if(0>=e||null==e){if(e=Jb(a,b,f),(0>e||null==e)&&(e=a.style[b]),Hb.test(e))return e;d=g&&(k.boxSizingReliable()||e===a.style[b]),e=parseFloat(e)||0}return e+Xb(a,b,c||(g?"border":"content"),d,f)+"px"}m.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=Jb(a,"opacity");return""===c?"1":c}}}},cssNumber:{columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":k.cssFloat?"cssFloat":"styleFloat"},style:function(a,b,c,d){if(a&&3!==a.nodeType&&8!==a.nodeType&&a.style){var e,f,g,h=m.camelCase(b),i=a.style;if(b=m.cssProps[h]||(m.cssProps[h]=Ub(i,h)),g=m.cssHooks[b]||m.cssHooks[h],void 0===c)return g&&"get"in g&&void 0!==(e=g.get(a,!1,d))?e:i[b];if(f=typeof c,"string"===f&&(e=Qb.exec(c))&&(c=(e[1]+1)*e[2]+parseFloat(m.css(a,b)),f="number"),null!=c&&c===c&&("number"!==f||m.cssNumber[h]||(c+="px"),k.clearCloneStyle||""!==c||0!==b.indexOf("background")||(i[b]="inherit"),!(g&&"set"in g&&void 0===(c=g.set(a,c,d)))))try{i[b]=c}catch(j){}}},css:function(a,b,c,d){var e,f,g,h=m.camelCase(b);return b=m.cssProps[h]||(m.cssProps[h]=Ub(a.style,h)),g=m.cssHooks[b]||m.cssHooks[h],g&&"get"in g&&(f=g.get(a,!0,c)),void 0===f&&(f=Jb(a,b,d)),"normal"===f&&b in Sb&&(f=Sb[b]),""===c||c?(e=parseFloat(f),c===!0||m.isNumeric(e)?e||0:f):f}}),m.each(["height","width"],function(a,b){m.cssHooks[b]={get:function(a,c,d){return c?Ob.test(m.css(a,"display"))&&0===a.offsetWidth?m.swap(a,Rb,function(){return Yb(a,b,d)}):Yb(a,b,d):void 0},set:function(a,c,d){var e=d&&Ib(a);return Wb(a,c,d?Xb(a,b,d,k.boxSizing&&"border-box"===m.css(a,"boxSizing",!1,e),e):0)}}}),k.opacity||(m.cssHooks.opacity={get:function(a,b){return Nb.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":b?"1":""},set:function(a,b){var c=a.style,d=a.currentStyle,e=m.isNumeric(b)?"alpha(opacity="+100*b+")":"",f=d&&d.filter||c.filter||"";c.zoom=1,(b>=1||""===b)&&""===m.trim(f.replace(Mb,""))&&c.removeAttribute&&(c.removeAttribute("filter"),""===b||d&&!d.filter)||(c.filter=Mb.test(f)?f.replace(Mb,e):f+" "+e)}}),m.cssHooks.marginRight=Lb(k.reliableMarginRight,function(a,b){return b?m.swap(a,{display:"inline-block"},Jb,[a,"marginRight"]):void 0}),m.each({margin:"",padding:"",border:"Width"},function(a,b){m.cssHooks[a+b]={expand:function(c){for(var d=0,e={},f="string"==typeof c?c.split(" "):[c];4>d;d++)e[a+T[d]+b]=f[d]||f[d-2]||f[0];return e}},Gb.test(a)||(m.cssHooks[a+b].set=Wb)}),m.fn.extend({css:function(a,b){return V(this,function(a,b,c){var d,e,f={},g=0;if(m.isArray(b)){for(d=Ib(a),e=b.length;e>g;g++)f[b[g]]=m.css(a,b[g],!1,d);return f}return void 0!==c?m.style(a,b,c):m.css(a,b)},a,b,arguments.length>1)},show:function(){return Vb(this,!0)},hide:function(){return Vb(this)},toggle:function(a){return"boolean"==typeof a?a?this.show():this.hide():this.each(function(){U(this)?m(this).show():m(this).hide()})}});function Zb(a,b,c,d,e){return new Zb.prototype.init(a,b,c,d,e)}m.Tween=Zb,Zb.prototype={constructor:Zb,init:function(a,b,c,d,e,f){this.elem=a,this.prop=c,this.easing=e||"swing",this.options=b,this.start=this.now=this.cur(),this.end=d,this.unit=f||(m.cssNumber[c]?"":"px")
+},cur:function(){var a=Zb.propHooks[this.prop];return a&&a.get?a.get(this):Zb.propHooks._default.get(this)},run:function(a){var b,c=Zb.propHooks[this.prop];return this.pos=b=this.options.duration?m.easing[this.easing](a,this.options.duration*a,0,1,this.options.duration):a,this.now=(this.end-this.start)*b+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),c&&c.set?c.set(this):Zb.propHooks._default.set(this),this}},Zb.prototype.init.prototype=Zb.prototype,Zb.propHooks={_default:{get:function(a){var b;return null==a.elem[a.prop]||a.elem.style&&null!=a.elem.style[a.prop]?(b=m.css(a.elem,a.prop,""),b&&"auto"!==b?b:0):a.elem[a.prop]},set:function(a){m.fx.step[a.prop]?m.fx.step[a.prop](a):a.elem.style&&(null!=a.elem.style[m.cssProps[a.prop]]||m.cssHooks[a.prop])?m.style(a.elem,a.prop,a.now+a.unit):a.elem[a.prop]=a.now}}},Zb.propHooks.scrollTop=Zb.propHooks.scrollLeft={set:function(a){a.elem.nodeType&&a.elem.parentNode&&(a.elem[a.prop]=a.now)}},m.easing={linear:function(a){return a},swing:function(a){return.5-Math.cos(a*Math.PI)/2}},m.fx=Zb.prototype.init,m.fx.step={};var $b,_b,ac=/^(?:toggle|show|hide)$/,bc=new RegExp("^(?:([+-])=|)("+S+")([a-z%]*)$","i"),cc=/queueHooks$/,dc=[ic],ec={"*":[function(a,b){var c=this.createTween(a,b),d=c.cur(),e=bc.exec(b),f=e&&e[3]||(m.cssNumber[a]?"":"px"),g=(m.cssNumber[a]||"px"!==f&&+d)&&bc.exec(m.css(c.elem,a)),h=1,i=20;if(g&&g[3]!==f){f=f||g[3],e=e||[],g=+d||1;do h=h||".5",g/=h,m.style(c.elem,a,g+f);while(h!==(h=c.cur()/d)&&1!==h&&--i)}return e&&(g=c.start=+g||+d||0,c.unit=f,c.end=e[1]?g+(e[1]+1)*e[2]:+e[2]),c}]};function fc(){return setTimeout(function(){$b=void 0}),$b=m.now()}function gc(a,b){var c,d={height:a},e=0;for(b=b?1:0;4>e;e+=2-b)c=T[e],d["margin"+c]=d["padding"+c]=a;return b&&(d.opacity=d.width=a),d}function hc(a,b,c){for(var d,e=(ec[b]||[]).concat(ec["*"]),f=0,g=e.length;g>f;f++)if(d=e[f].call(c,b,a))return d}function ic(a,b,c){var d,e,f,g,h,i,j,l,n=this,o={},p=a.style,q=a.nodeType&&U(a),r=m._data(a,"fxshow");c.queue||(h=m._queueHooks(a,"fx"),null==h.unqueued&&(h.unqueued=0,i=h.empty.fire,h.empty.fire=function(){h.unqueued||i()}),h.unqueued++,n.always(function(){n.always(function(){h.unqueued--,m.queue(a,"fx").length||h.empty.fire()})})),1===a.nodeType&&("height"in b||"width"in b)&&(c.overflow=[p.overflow,p.overflowX,p.overflowY],j=m.css(a,"display"),l="none"===j?m._data(a,"olddisplay")||Fb(a.nodeName):j,"inline"===l&&"none"===m.css(a,"float")&&(k.inlineBlockNeedsLayout&&"inline"!==Fb(a.nodeName)?p.zoom=1:p.display="inline-block")),c.overflow&&(p.overflow="hidden",k.shrinkWrapBlocks()||n.always(function(){p.overflow=c.overflow[0],p.overflowX=c.overflow[1],p.overflowY=c.overflow[2]}));for(d in b)if(e=b[d],ac.exec(e)){if(delete b[d],f=f||"toggle"===e,e===(q?"hide":"show")){if("show"!==e||!r||void 0===r[d])continue;q=!0}o[d]=r&&r[d]||m.style(a,d)}else j=void 0;if(m.isEmptyObject(o))"inline"===("none"===j?Fb(a.nodeName):j)&&(p.display=j);else{r?"hidden"in r&&(q=r.hidden):r=m._data(a,"fxshow",{}),f&&(r.hidden=!q),q?m(a).show():n.done(function(){m(a).hide()}),n.done(function(){var b;m._removeData(a,"fxshow");for(b in o)m.style(a,b,o[b])});for(d in o)g=hc(q?r[d]:0,d,n),d in r||(r[d]=g.start,q&&(g.end=g.start,g.start="width"===d||"height"===d?1:0))}}function jc(a,b){var c,d,e,f,g;for(c in a)if(d=m.camelCase(c),e=b[d],f=a[c],m.isArray(f)&&(e=f[1],f=a[c]=f[0]),c!==d&&(a[d]=f,delete a[c]),g=m.cssHooks[d],g&&"expand"in g){f=g.expand(f),delete a[d];for(c in f)c in a||(a[c]=f[c],b[c]=e)}else b[d]=e}function kc(a,b,c){var d,e,f=0,g=dc.length,h=m.Deferred().always(function(){delete i.elem}),i=function(){if(e)return!1;for(var b=$b||fc(),c=Math.max(0,j.startTime+j.duration-b),d=c/j.duration||0,f=1-d,g=0,i=j.tweens.length;i>g;g++)j.tweens[g].run(f);return h.notifyWith(a,[j,f,c]),1>f&&i?c:(h.resolveWith(a,[j]),!1)},j=h.promise({elem:a,props:m.extend({},b),opts:m.extend(!0,{specialEasing:{}},c),originalProperties:b,originalOptions:c,startTime:$b||fc(),duration:c.duration,tweens:[],createTween:function(b,c){var d=m.Tween(a,j.opts,b,c,j.opts.specialEasing[b]||j.opts.easing);return j.tweens.push(d),d},stop:function(b){var c=0,d=b?j.tweens.length:0;if(e)return this;for(e=!0;d>c;c++)j.tweens[c].run(1);return b?h.resolveWith(a,[j,b]):h.rejectWith(a,[j,b]),this}}),k=j.props;for(jc(k,j.opts.specialEasing);g>f;f++)if(d=dc[f].call(j,a,k,j.opts))return d;return m.map(k,hc,j),m.isFunction(j.opts.start)&&j.opts.start.call(a,j),m.fx.timer(m.extend(i,{elem:a,anim:j,queue:j.opts.queue})),j.progress(j.opts.progress).done(j.opts.done,j.opts.complete).fail(j.opts.fail).always(j.opts.always)}m.Animation=m.extend(kc,{tweener:function(a,b){m.isFunction(a)?(b=a,a=["*"]):a=a.split(" ");for(var c,d=0,e=a.length;e>d;d++)c=a[d],ec[c]=ec[c]||[],ec[c].unshift(b)},prefilter:function(a,b){b?dc.unshift(a):dc.push(a)}}),m.speed=function(a,b,c){var d=a&&"object"==typeof a?m.extend({},a):{complete:c||!c&&b||m.isFunction(a)&&a,duration:a,easing:c&&b||b&&!m.isFunction(b)&&b};return d.duration=m.fx.off?0:"number"==typeof d.duration?d.duration:d.duration in m.fx.speeds?m.fx.speeds[d.duration]:m.fx.speeds._default,(null==d.queue||d.queue===!0)&&(d.queue="fx"),d.old=d.complete,d.complete=function(){m.isFunction(d.old)&&d.old.call(this),d.queue&&m.dequeue(this,d.queue)},d},m.fn.extend({fadeTo:function(a,b,c,d){return this.filter(U).css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=m.isEmptyObject(a),f=m.speed(b,c,d),g=function(){var b=kc(this,m.extend({},a),f);(e||m._data(this,"finish"))&&b.stop(!0)};return g.finish=g,e||f.queue===!1?this.each(g):this.queue(f.queue,g)},stop:function(a,b,c){var d=function(a){var b=a.stop;delete a.stop,b(c)};return"string"!=typeof a&&(c=b,b=a,a=void 0),b&&a!==!1&&this.queue(a||"fx",[]),this.each(function(){var b=!0,e=null!=a&&a+"queueHooks",f=m.timers,g=m._data(this);if(e)g[e]&&g[e].stop&&d(g[e]);else for(e in g)g[e]&&g[e].stop&&cc.test(e)&&d(g[e]);for(e=f.length;e--;)f[e].elem!==this||null!=a&&f[e].queue!==a||(f[e].anim.stop(c),b=!1,f.splice(e,1));(b||!c)&&m.dequeue(this,a)})},finish:function(a){return a!==!1&&(a=a||"fx"),this.each(function(){var b,c=m._data(this),d=c[a+"queue"],e=c[a+"queueHooks"],f=m.timers,g=d?d.length:0;for(c.finish=!0,m.queue(this,a,[]),e&&e.stop&&e.stop.call(this,!0),b=f.length;b--;)f[b].elem===this&&f[b].queue===a&&(f[b].anim.stop(!0),f.splice(b,1));for(b=0;g>b;b++)d[b]&&d[b].finish&&d[b].finish.call(this);delete c.finish})}}),m.each(["toggle","show","hide"],function(a,b){var c=m.fn[b];m.fn[b]=function(a,d,e){return null==a||"boolean"==typeof a?c.apply(this,arguments):this.animate(gc(b,!0),a,d,e)}}),m.each({slideDown:gc("show"),slideUp:gc("hide"),slideToggle:gc("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){m.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),m.timers=[],m.fx.tick=function(){var a,b=m.timers,c=0;for($b=m.now();c<b.length;c++)a=b[c],a()||b[c]!==a||b.splice(c--,1);b.length||m.fx.stop(),$b=void 0},m.fx.timer=function(a){m.timers.push(a),a()?m.fx.start():m.timers.pop()},m.fx.interval=13,m.fx.start=function(){_b||(_b=setInterval(m.fx.tick,m.fx.interval))},m.fx.stop=function(){clearInterval(_b),_b=null},m.fx.speeds={slow:600,fast:200,_default:400},m.fn.delay=function(a,b){return a=m.fx?m.fx.speeds[a]||a:a,b=b||"fx",this.queue(b,function(b,c){var d=setTimeout(b,a);c.stop=function(){clearTimeout(d)}})},function(){var a,b,c,d,e;b=y.createElement("div"),b.setAttribute("className","t"),b.innerHTML="  <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",d=b.getElementsByTagName("a")[0],c=y.createElement("select"),e=c.appendChild(y.createElement("option")),a=b.getElementsByTagName("input")[0],d.style.cssText="top:1px",k.getSetAttribute="t"!==b.className,k.style=/top/.test(d.getAttribute("style")),k.hrefNormalized="/a"===d.getAttribute("href"),k.checkOn=!!a.value,k.optSelected=e.selected,k.enctype=!!y.createElement("form").enctype,c.disabled=!0,k.optDisabled=!e.disabled,a=y.createElement("input"),a.setAttribute("value",""),k.input=""===a.getAttribute("value"),a.value="t",a.setAttribute("type","radio"),k.radioValue="t"===a.value}();var lc=/\r/g;m.fn.extend({val:function(a){var b,c,d,e=this[0];{if(arguments.length)return d=m.isFunction(a),this.each(function(c){var e;1===this.nodeType&&(e=d?a.call(this,c,m(this).val()):a,null==e?e="":"number"==typeof e?e+="":m.isArray(e)&&(e=m.map(e,function(a){return null==a?"":a+""})),b=m.valHooks[this.type]||m.valHooks[this.nodeName.toLowerCase()],b&&"set"in b&&void 0!==b.set(this,e,"value")||(this.value=e))});if(e)return b=m.valHooks[e.type]||m.valHooks[e.nodeName.toLowerCase()],b&&"get"in b&&void 0!==(c=b.get(e,"value"))?c:(c=e.value,"string"==typeof c?c.replace(lc,""):null==c?"":c)}}}),m.extend({valHooks:{option:{get:function(a){var b=m.find.attr(a,"value");return null!=b?b:m.trim(m.text(a))}},select:{get:function(a){for(var b,c,d=a.options,e=a.selectedIndex,f="select-one"===a.type||0>e,g=f?null:[],h=f?e+1:d.length,i=0>e?h:f?e:0;h>i;i++)if(c=d[i],!(!c.selected&&i!==e||(k.optDisabled?c.disabled:null!==c.getAttribute("disabled"))||c.parentNode.disabled&&m.nodeName(c.parentNode,"optgroup"))){if(b=m(c).val(),f)return b;g.push(b)}return g},set:function(a,b){var c,d,e=a.options,f=m.makeArray(b),g=e.length;while(g--)if(d=e[g],m.inArray(m.valHooks.option.get(d),f)>=0)try{d.selected=c=!0}catch(h){d.scrollHeight}else d.selected=!1;return c||(a.selectedIndex=-1),e}}}}),m.each(["radio","checkbox"],function(){m.valHooks[this]={set:function(a,b){return m.isArray(b)?a.checked=m.inArray(m(a).val(),b)>=0:void 0}},k.checkOn||(m.valHooks[this].get=function(a){return null===a.getAttribute("value")?"on":a.value})});var mc,nc,oc=m.expr.attrHandle,pc=/^(?:checked|selected)$/i,qc=k.getSetAttribute,rc=k.input;m.fn.extend({attr:function(a,b){return V(this,m.attr,a,b,arguments.length>1)},removeAttr:function(a){return this.each(function(){m.removeAttr(this,a)})}}),m.extend({attr:function(a,b,c){var d,e,f=a.nodeType;if(a&&3!==f&&8!==f&&2!==f)return typeof a.getAttribute===K?m.prop(a,b,c):(1===f&&m.isXMLDoc(a)||(b=b.toLowerCase(),d=m.attrHooks[b]||(m.expr.match.bool.test(b)?nc:mc)),void 0===c?d&&"get"in d&&null!==(e=d.get(a,b))?e:(e=m.find.attr(a,b),null==e?void 0:e):null!==c?d&&"set"in d&&void 0!==(e=d.set(a,c,b))?e:(a.setAttribute(b,c+""),c):void m.removeAttr(a,b))},removeAttr:function(a,b){var c,d,e=0,f=b&&b.match(E);if(f&&1===a.nodeType)while(c=f[e++])d=m.propFix[c]||c,m.expr.match.bool.test(c)?rc&&qc||!pc.test(c)?a[d]=!1:a[m.camelCase("default-"+c)]=a[d]=!1:m.attr(a,c,""),a.removeAttribute(qc?c:d)},attrHooks:{type:{set:function(a,b){if(!k.radioValue&&"radio"===b&&m.nodeName(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}}}}),nc={set:function(a,b,c){return b===!1?m.removeAttr(a,c):rc&&qc||!pc.test(c)?a.setAttribute(!qc&&m.propFix[c]||c,c):a[m.camelCase("default-"+c)]=a[c]=!0,c}},m.each(m.expr.match.bool.source.match(/\w+/g),function(a,b){var c=oc[b]||m.find.attr;oc[b]=rc&&qc||!pc.test(b)?function(a,b,d){var e,f;return d||(f=oc[b],oc[b]=e,e=null!=c(a,b,d)?b.toLowerCase():null,oc[b]=f),e}:function(a,b,c){return c?void 0:a[m.camelCase("default-"+b)]?b.toLowerCase():null}}),rc&&qc||(m.attrHooks.value={set:function(a,b,c){return m.nodeName(a,"input")?void(a.defaultValue=b):mc&&mc.set(a,b,c)}}),qc||(mc={set:function(a,b,c){var d=a.getAttributeNode(c);return d||a.setAttributeNode(d=a.ownerDocument.createAttribute(c)),d.value=b+="","value"===c||b===a.getAttribute(c)?b:void 0}},oc.id=oc.name=oc.coords=function(a,b,c){var d;return c?void 0:(d=a.getAttributeNode(b))&&""!==d.value?d.value:null},m.valHooks.button={get:function(a,b){var c=a.getAttributeNode(b);return c&&c.specified?c.value:void 0},set:mc.set},m.attrHooks.contenteditable={set:function(a,b,c){mc.set(a,""===b?!1:b,c)}},m.each(["width","height"],function(a,b){m.attrHooks[b]={set:function(a,c){return""===c?(a.setAttribute(b,"auto"),c):void 0}}})),k.style||(m.attrHooks.style={get:function(a){return a.style.cssText||void 0},set:function(a,b){return a.style.cssText=b+""}});var sc=/^(?:input|select|textarea|button|object)$/i,tc=/^(?:a|area)$/i;m.fn.extend({prop:function(a,b){return V(this,m.prop,a,b,arguments.length>1)},removeProp:function(a){return a=m.propFix[a]||a,this.each(function(){try{this[a]=void 0,delete this[a]}catch(b){}})}}),m.extend({propFix:{"for":"htmlFor","class":"className"},prop:function(a,b,c){var d,e,f,g=a.nodeType;if(a&&3!==g&&8!==g&&2!==g)return f=1!==g||!m.isXMLDoc(a),f&&(b=m.propFix[b]||b,e=m.propHooks[b]),void 0!==c?e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:a[b]=c:e&&"get"in e&&null!==(d=e.get(a,b))?d:a[b]},propHooks:{tabIndex:{get:function(a){var b=m.find.attr(a,"tabindex");return b?parseInt(b,10):sc.test(a.nodeName)||tc.test(a.nodeName)&&a.href?0:-1}}}}),k.hrefNormalized||m.each(["href","src"],function(a,b){m.propHooks[b]={get:function(a){return a.getAttribute(b,4)}}}),k.optSelected||(m.propHooks.selected={get:function(a){var b=a.parentNode;return b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex),null}}),m.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){m.propFix[this.toLowerCase()]=this}),k.enctype||(m.propFix.enctype="encoding");var uc=/[\t\r\n\f]/g;m.fn.extend({addClass:function(a){var b,c,d,e,f,g,h=0,i=this.length,j="string"==typeof a&&a;if(m.isFunction(a))return this.each(function(b){m(this).addClass(a.call(this,b,this.className))});if(j)for(b=(a||"").match(E)||[];i>h;h++)if(c=this[h],d=1===c.nodeType&&(c.className?(" "+c.className+" ").replace(uc," "):" ")){f=0;while(e=b[f++])d.indexOf(" "+e+" ")<0&&(d+=e+" ");g=m.trim(d),c.className!==g&&(c.className=g)}return this},removeClass:function(a){var b,c,d,e,f,g,h=0,i=this.length,j=0===arguments.length||"string"==typeof a&&a;if(m.isFunction(a))return this.each(function(b){m(this).removeClass(a.call(this,b,this.className))});if(j)for(b=(a||"").match(E)||[];i>h;h++)if(c=this[h],d=1===c.nodeType&&(c.className?(" "+c.className+" ").replace(uc," "):"")){f=0;while(e=b[f++])while(d.indexOf(" "+e+" ")>=0)d=d.replace(" "+e+" "," ");g=a?m.trim(d):"",c.className!==g&&(c.className=g)}return this},toggleClass:function(a,b){var c=typeof a;return"boolean"==typeof b&&"string"===c?b?this.addClass(a):this.removeClass(a):this.each(m.isFunction(a)?function(c){m(this).toggleClass(a.call(this,c,this.className,b),b)}:function(){if("string"===c){var b,d=0,e=m(this),f=a.match(E)||[];while(b=f[d++])e.hasClass(b)?e.removeClass(b):e.addClass(b)}else(c===K||"boolean"===c)&&(this.className&&m._data(this,"__className__",this.className),this.className=this.className||a===!1?"":m._data(this,"__className__")||"")})},hasClass:function(a){for(var b=" "+a+" ",c=0,d=this.length;d>c;c++)if(1===this[c].nodeType&&(" "+this[c].className+" ").replace(uc," ").indexOf(b)>=0)return!0;return!1}}),m.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(a,b){m.fn[b]=function(a,c){return arguments.length>0?this.on(b,null,a,c):this.trigger(b)}}),m.fn.extend({hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)},bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return 1===arguments.length?this.off(a,"**"):this.off(b,a||"**",c)}});var vc=m.now(),wc=/\?/,xc=/(,)|(\[|{)|(}|])|"(?:[^"\\\r\n]|\\["\\\/bfnrt]|\\u[\da-fA-F]{4})*"\s*:?|true|false|null|-?(?!0\d)\d+(?:\.\d+|)(?:[eE][+-]?\d+|)/g;m.parseJSON=function(b){if(a.JSON&&a.JSON.parse)return a.JSON.parse(b+"");var c,d=null,e=m.trim(b+"");return e&&!m.trim(e.replace(xc,function(a,b,e,f){return c&&b&&(d=0),0===d?a:(c=e||b,d+=!f-!e,"")}))?Function("return "+e)():m.error("Invalid JSON: "+b)},m.parseXML=function(b){var c,d;if(!b||"string"!=typeof b)return null;try{a.DOMParser?(d=new DOMParser,c=d.parseFromString(b,"text/xml")):(c=new ActiveXObject("Microsoft.XMLDOM"),c.async="false",c.loadXML(b))}catch(e){c=void 0}return c&&c.documentElement&&!c.getElementsByTagName("parsererror").length||m.error("Invalid XML: "+b),c};var yc,zc,Ac=/#.*$/,Bc=/([?&])_=[^&]*/,Cc=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,Dc=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Ec=/^(?:GET|HEAD)$/,Fc=/^\/\//,Gc=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,Hc={},Ic={},Jc="*/".concat("*");try{zc=location.href}catch(Kc){zc=y.createElement("a"),zc.href="",zc=zc.href}yc=Gc.exec(zc.toLowerCase())||[];function Lc(a){return function(b,c){"string"!=typeof b&&(c=b,b="*");var d,e=0,f=b.toLowerCase().match(E)||[];if(m.isFunction(c))while(d=f[e++])"+"===d.charAt(0)?(d=d.slice(1)||"*",(a[d]=a[d]||[]).unshift(c)):(a[d]=a[d]||[]).push(c)}}function Mc(a,b,c,d){var e={},f=a===Ic;function g(h){var i;return e[h]=!0,m.each(a[h]||[],function(a,h){var j=h(b,c,d);return"string"!=typeof j||f||e[j]?f?!(i=j):void 0:(b.dataTypes.unshift(j),g(j),!1)}),i}return g(b.dataTypes[0])||!e["*"]&&g("*")}function Nc(a,b){var c,d,e=m.ajaxSettings.flatOptions||{};for(d in b)void 0!==b[d]&&((e[d]?a:c||(c={}))[d]=b[d]);return c&&m.extend(!0,a,c),a}function Oc(a,b,c){var d,e,f,g,h=a.contents,i=a.dataTypes;while("*"===i[0])i.shift(),void 0===e&&(e=a.mimeType||b.getResponseHeader("Content-Type"));if(e)for(g in h)if(h[g]&&h[g].test(e)){i.unshift(g);break}if(i[0]in c)f=i[0];else{for(g in c){if(!i[0]||a.converters[g+" "+i[0]]){f=g;break}d||(d=g)}f=f||d}return f?(f!==i[0]&&i.unshift(f),c[f]):void 0}function Pc(a,b,c,d){var e,f,g,h,i,j={},k=a.dataTypes.slice();if(k[1])for(g in a.converters)j[g.toLowerCase()]=a.converters[g];f=k.shift();while(f)if(a.responseFields[f]&&(c[a.responseFields[f]]=b),!i&&d&&a.dataFilter&&(b=a.dataFilter(b,a.dataType)),i=f,f=k.shift())if("*"===f)f=i;else if("*"!==i&&i!==f){if(g=j[i+" "+f]||j["* "+f],!g)for(e in j)if(h=e.split(" "),h[1]===f&&(g=j[i+" "+h[0]]||j["* "+h[0]])){g===!0?g=j[e]:j[e]!==!0&&(f=h[0],k.unshift(h[1]));break}if(g!==!0)if(g&&a["throws"])b=g(b);else try{b=g(b)}catch(l){return{state:"parsererror",error:g?l:"No conversion from "+i+" to "+f}}}return{state:"success",data:b}}m.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:zc,type:"GET",isLocal:Dc.test(yc[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Jc,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":m.parseJSON,"text xml":m.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(a,b){return b?Nc(Nc(a,m.ajaxSettings),b):Nc(m.ajaxSettings,a)},ajaxPrefilter:Lc(Hc),ajaxTransport:Lc(Ic),ajax:function(a,b){"object"==typeof a&&(b=a,a=void 0),b=b||{};var c,d,e,f,g,h,i,j,k=m.ajaxSetup({},b),l=k.context||k,n=k.context&&(l.nodeType||l.jquery)?m(l):m.event,o=m.Deferred(),p=m.Callbacks("once memory"),q=k.statusCode||{},r={},s={},t=0,u="canceled",v={readyState:0,getResponseHeader:function(a){var b;if(2===t){if(!j){j={};while(b=Cc.exec(f))j[b[1].toLowerCase()]=b[2]}b=j[a.toLowerCase()]}return null==b?null:b},getAllResponseHeaders:function(){return 2===t?f:null},setRequestHeader:function(a,b){var c=a.toLowerCase();return t||(a=s[c]=s[c]||a,r[a]=b),this},overrideMimeType:function(a){return t||(k.mimeType=a),this},statusCode:function(a){var b;if(a)if(2>t)for(b in a)q[b]=[q[b],a[b]];else v.always(a[v.status]);return this},abort:function(a){var b=a||u;return i&&i.abort(b),x(0,b),this}};if(o.promise(v).complete=p.add,v.success=v.done,v.error=v.fail,k.url=((a||k.url||zc)+"").replace(Ac,"").replace(Fc,yc[1]+"//"),k.type=b.method||b.type||k.method||k.type,k.dataTypes=m.trim(k.dataType||"*").toLowerCase().match(E)||[""],null==k.crossDomain&&(c=Gc.exec(k.url.toLowerCase()),k.crossDomain=!(!c||c[1]===yc[1]&&c[2]===yc[2]&&(c[3]||("http:"===c[1]?"80":"443"))===(yc[3]||("http:"===yc[1]?"80":"443")))),k.data&&k.processData&&"string"!=typeof k.data&&(k.data=m.param(k.data,k.traditional)),Mc(Hc,k,b,v),2===t)return v;h=k.global,h&&0===m.active++&&m.event.trigger("ajaxStart"),k.type=k.type.toUpperCase(),k.hasContent=!Ec.test(k.type),e=k.url,k.hasContent||(k.data&&(e=k.url+=(wc.test(e)?"&":"?")+k.data,delete k.data),k.cache===!1&&(k.url=Bc.test(e)?e.replace(Bc,"$1_="+vc++):e+(wc.test(e)?"&":"?")+"_="+vc++)),k.ifModified&&(m.lastModified[e]&&v.setRequestHeader("If-Modified-Since",m.lastModified[e]),m.etag[e]&&v.setRequestHeader("If-None-Match",m.etag[e])),(k.data&&k.hasContent&&k.contentType!==!1||b.contentType)&&v.setRequestHeader("Content-Type",k.contentType),v.setRequestHeader("Accept",k.dataTypes[0]&&k.accepts[k.dataTypes[0]]?k.accepts[k.dataTypes[0]]+("*"!==k.dataTypes[0]?", "+Jc+"; q=0.01":""):k.accepts["*"]);for(d in k.headers)v.setRequestHeader(d,k.headers[d]);if(k.beforeSend&&(k.beforeSend.call(l,v,k)===!1||2===t))return v.abort();u="abort";for(d in{success:1,error:1,complete:1})v[d](k[d]);if(i=Mc(Ic,k,b,v)){v.readyState=1,h&&n.trigger("ajaxSend",[v,k]),k.async&&k.timeout>0&&(g=setTimeout(function(){v.abort("timeout")},k.timeout));try{t=1,i.send(r,x)}catch(w){if(!(2>t))throw w;x(-1,w)}}else x(-1,"No Transport");function x(a,b,c,d){var j,r,s,u,w,x=b;2!==t&&(t=2,g&&clearTimeout(g),i=void 0,f=d||"",v.readyState=a>0?4:0,j=a>=200&&300>a||304===a,c&&(u=Oc(k,v,c)),u=Pc(k,u,v,j),j?(k.ifModified&&(w=v.getResponseHeader("Last-Modified"),w&&(m.lastModified[e]=w),w=v.getResponseHeader("etag"),w&&(m.etag[e]=w)),204===a||"HEAD"===k.type?x="nocontent":304===a?x="notmodified":(x=u.state,r=u.data,s=u.error,j=!s)):(s=x,(a||!x)&&(x="error",0>a&&(a=0))),v.status=a,v.statusText=(b||x)+"",j?o.resolveWith(l,[r,x,v]):o.rejectWith(l,[v,x,s]),v.statusCode(q),q=void 0,h&&n.trigger(j?"ajaxSuccess":"ajaxError",[v,k,j?r:s]),p.fireWith(l,[v,x]),h&&(n.trigger("ajaxComplete",[v,k]),--m.active||m.event.trigger("ajaxStop")))}return v},getJSON:function(a,b,c){return m.get(a,b,c,"json")},getScript:function(a,b){return m.get(a,void 0,b,"script")}}),m.each(["get","post"],function(a,b){m[b]=function(a,c,d,e){return m.isFunction(c)&&(e=e||d,d=c,c=void 0),m.ajax({url:a,type:b,dataType:e,data:c,success:d})}}),m.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(a,b){m.fn[b]=function(a){return this.on(b,a)}}),m._evalUrl=function(a){return m.ajax({url:a,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})},m.fn.extend({wrapAll:function(a){if(m.isFunction(a))return this.each(function(b){m(this).wrapAll(a.call(this,b))});if(this[0]){var b=m(a,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstChild&&1===a.firstChild.nodeType)a=a.firstChild;return a}).append(this)}return this},wrapInner:function(a){return this.each(m.isFunction(a)?function(b){m(this).wrapInner(a.call(this,b))}:function(){var b=m(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=m.isFunction(a);return this.each(function(c){m(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){m.nodeName(this,"body")||m(this).replaceWith(this.childNodes)}).end()}}),m.expr.filters.hidden=function(a){return a.offsetWidth<=0&&a.offsetHeight<=0||!k.reliableHiddenOffsets()&&"none"===(a.style&&a.style.display||m.css(a,"display"))},m.expr.filters.visible=function(a){return!m.expr.filters.hidden(a)};var Qc=/%20/g,Rc=/\[\]$/,Sc=/\r?\n/g,Tc=/^(?:submit|button|image|reset|file)$/i,Uc=/^(?:input|select|textarea|keygen)/i;function Vc(a,b,c,d){var e;if(m.isArray(b))m.each(b,function(b,e){c||Rc.test(a)?d(a,e):Vc(a+"["+("object"==typeof e?b:"")+"]",e,c,d)});else if(c||"object"!==m.type(b))d(a,b);else for(e in b)Vc(a+"["+e+"]",b[e],c,d)}m.param=function(a,b){var c,d=[],e=function(a,b){b=m.isFunction(b)?b():null==b?"":b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};if(void 0===b&&(b=m.ajaxSettings&&m.ajaxSettings.traditional),m.isArray(a)||a.jquery&&!m.isPlainObject(a))m.each(a,function(){e(this.name,this.value)});else for(c in a)Vc(c,a[c],b,e);return d.join("&").replace(Qc,"+")},m.fn.extend({serialize:function(){return m.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var a=m.prop(this,"elements");return a?m.makeArray(a):this}).filter(function(){var a=this.type;return this.name&&!m(this).is(":disabled")&&Uc.test(this.nodeName)&&!Tc.test(a)&&(this.checked||!W.test(a))}).map(function(a,b){var c=m(this).val();return null==c?null:m.isArray(c)?m.map(c,function(a){return{name:b.name,value:a.replace(Sc,"\r\n")}}):{name:b.name,value:c.replace(Sc,"\r\n")}}).get()}}),m.ajaxSettings.xhr=void 0!==a.ActiveXObject?function(){return!this.isLocal&&/^(get|post|head|put|delete|options)$/i.test(this.type)&&Zc()||$c()}:Zc;var Wc=0,Xc={},Yc=m.ajaxSettings.xhr();a.ActiveXObject&&m(a).on("unload",function(){for(var a in Xc)Xc[a](void 0,!0)}),k.cors=!!Yc&&"withCredentials"in Yc,Yc=k.ajax=!!Yc,Yc&&m.ajaxTransport(function(a){if(!a.crossDomain||k.cors){var b;return{send:function(c,d){var e,f=a.xhr(),g=++Wc;if(f.open(a.type,a.url,a.async,a.username,a.password),a.xhrFields)for(e in a.xhrFields)f[e]=a.xhrFields[e];a.mimeType&&f.overrideMimeType&&f.overrideMimeType(a.mimeType),a.crossDomain||c["X-Requested-With"]||(c["X-Requested-With"]="XMLHttpRequest");for(e in c)void 0!==c[e]&&f.setRequestHeader(e,c[e]+"");f.send(a.hasContent&&a.data||null),b=function(c,e){var h,i,j;if(b&&(e||4===f.readyState))if(delete Xc[g],b=void 0,f.onreadystatechange=m.noop,e)4!==f.readyState&&f.abort();else{j={},h=f.status,"string"==typeof f.responseText&&(j.text=f.responseText);try{i=f.statusText}catch(k){i=""}h||!a.isLocal||a.crossDomain?1223===h&&(h=204):h=j.text?200:404}j&&d(h,i,j,f.getAllResponseHeaders())},a.async?4===f.readyState?setTimeout(b):f.onreadystatechange=Xc[g]=b:b()},abort:function(){b&&b(void 0,!0)}}}});function Zc(){try{return new a.XMLHttpRequest}catch(b){}}function $c(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}m.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(a){return m.globalEval(a),a}}}),m.ajaxPrefilter("script",function(a){void 0===a.cache&&(a.cache=!1),a.crossDomain&&(a.type="GET",a.global=!1)}),m.ajaxTransport("script",function(a){if(a.crossDomain){var b,c=y.head||m("head")[0]||y.documentElement;return{send:function(d,e){b=y.createElement("script"),b.async=!0,a.scriptCharset&&(b.charset=a.scriptCharset),b.src=a.url,b.onload=b.onreadystatechange=function(a,c){(c||!b.readyState||/loaded|complete/.test(b.readyState))&&(b.onload=b.onreadystatechange=null,b.parentNode&&b.parentNode.removeChild(b),b=null,c||e(200,"success"))},c.insertBefore(b,c.firstChild)},abort:function(){b&&b.onload(void 0,!0)}}}});var _c=[],ad=/(=)\?(?=&|$)|\?\?/;m.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var a=_c.pop()||m.expando+"_"+vc++;return this[a]=!0,a}}),m.ajaxPrefilter("json jsonp",function(b,c,d){var e,f,g,h=b.jsonp!==!1&&(ad.test(b.url)?"url":"string"==typeof b.data&&!(b.contentType||"").indexOf("application/x-www-form-urlencoded")&&ad.test(b.data)&&"data");return h||"jsonp"===b.dataTypes[0]?(e=b.jsonpCallback=m.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,h?b[h]=b[h].replace(ad,"$1"+e):b.jsonp!==!1&&(b.url+=(wc.test(b.url)?"&":"?")+b.jsonp+"="+e),b.converters["script json"]=function(){return g||m.error(e+" was not called"),g[0]},b.dataTypes[0]="json",f=a[e],a[e]=function(){g=arguments},d.always(function(){a[e]=f,b[e]&&(b.jsonpCallback=c.jsonpCallback,_c.push(e)),g&&m.isFunction(f)&&f(g[0]),g=f=void 0}),"script"):void 0}),m.parseHTML=function(a,b,c){if(!a||"string"!=typeof a)return null;"boolean"==typeof b&&(c=b,b=!1),b=b||y;var d=u.exec(a),e=!c&&[];return d?[b.createElement(d[1])]:(d=m.buildFragment([a],b,e),e&&e.length&&m(e).remove(),m.merge([],d.childNodes))};var bd=m.fn.load;m.fn.load=function(a,b,c){if("string"!=typeof a&&bd)return bd.apply(this,arguments);var d,e,f,g=this,h=a.indexOf(" ");return h>=0&&(d=m.trim(a.slice(h,a.length)),a=a.slice(0,h)),m.isFunction(b)?(c=b,b=void 0):b&&"object"==typeof b&&(f="POST"),g.length>0&&m.ajax({url:a,type:f,dataType:"html",data:b}).done(function(a){e=arguments,g.html(d?m("<div>").append(m.parseHTML(a)).find(d):a)}).complete(c&&function(a,b){g.each(c,e||[a.responseText,b,a])}),this},m.expr.filters.animated=function(a){return m.grep(m.timers,function(b){return a===b.elem}).length};var cd=a.document.documentElement;function dd(a){return m.isWindow(a)?a:9===a.nodeType?a.defaultView||a.parentWindow:!1}m.offset={setOffset:function(a,b,c){var d,e,f,g,h,i,j,k=m.css(a,"position"),l=m(a),n={};"static"===k&&(a.style.position="relative"),h=l.offset(),f=m.css(a,"top"),i=m.css(a,"left"),j=("absolute"===k||"fixed"===k)&&m.inArray("auto",[f,i])>-1,j?(d=l.position(),g=d.top,e=d.left):(g=parseFloat(f)||0,e=parseFloat(i)||0),m.isFunction(b)&&(b=b.call(a,c,h)),null!=b.top&&(n.top=b.top-h.top+g),null!=b.left&&(n.left=b.left-h.left+e),"using"in b?b.using.call(a,n):l.css(n)}},m.fn.extend({offset:function(a){if(arguments.length)return void 0===a?this:this.each(function(b){m.offset.setOffset(this,a,b)});var b,c,d={top:0,left:0},e=this[0],f=e&&e.ownerDocument;if(f)return b=f.documentElement,m.contains(b,e)?(typeof e.getBoundingClientRect!==K&&(d=e.getBoundingClientRect()),c=dd(f),{top:d.top+(c.pageYOffset||b.scrollTop)-(b.clientTop||0),left:d.left+(c.pageXOffset||b.scrollLeft)-(b.clientLeft||0)}):d},position:function(){if(this[0]){var a,b,c={top:0,left:0},d=this[0];return"fixed"===m.css(d,"position")?b=d.getBoundingClientRect():(a=this.offsetParent(),b=this.offset(),m.nodeName(a[0],"html")||(c=a.offset()),c.top+=m.css(a[0],"borderTopWidth",!0),c.left+=m.css(a[0],"borderLeftWidth",!0)),{top:b.top-c.top-m.css(d,"marginTop",!0),left:b.left-c.left-m.css(d,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var a=this.offsetParent||cd;while(a&&!m.nodeName(a,"html")&&"static"===m.css(a,"position"))a=a.offsetParent;return a||cd})}}),m.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(a,b){var c=/Y/.test(b);m.fn[a]=function(d){return V(this,function(a,d,e){var f=dd(a);return void 0===e?f?b in f?f[b]:f.document.documentElement[d]:a[d]:void(f?f.scrollTo(c?m(f).scrollLeft():e,c?e:m(f).scrollTop()):a[d]=e)},a,d,arguments.length,null)}}),m.each(["top","left"],function(a,b){m.cssHooks[b]=Lb(k.pixelPosition,function(a,c){return c?(c=Jb(a,b),Hb.test(c)?m(a).position()[b]+"px":c):void 0})}),m.each({Height:"height",Width:"width"},function(a,b){m.each({padding:"inner"+a,content:b,"":"outer"+a},function(c,d){m.fn[d]=function(d,e){var f=arguments.length&&(c||"boolean"!=typeof d),g=c||(d===!0||e===!0?"margin":"border");return V(this,function(b,c,d){var e;return m.isWindow(b)?b.document.documentElement["client"+a]:9===b.nodeType?(e=b.documentElement,Math.max(b.body["scroll"+a],e["scroll"+a],b.body["offset"+a],e["offset"+a],e["client"+a])):void 0===d?m.css(b,c,g):m.style(b,c,d,g)},b,f?d:void 0,f,null)}})}),m.fn.size=function(){return this.length},m.fn.andSelf=m.fn.addBack,"function"==typeof define&&define.amd&&define("jquery",[],function(){return m});var ed=a.jQuery,fd=a.$;return m.noConflict=function(b){return a.$===m&&(a.$=fd),b&&a.jQuery===m&&(a.jQuery=ed),m},typeof b===K&&(a.jQuery=a.$=m),m});
\ No newline at end of file