Depreciate MySQL and GD image graphs
[contractdashboard.git] / lib / common.inc.php
blob:a/lib/common.inc.php -> blob:b/lib/common.inc.php
--- a/lib/common.inc.php
+++ b/lib/common.inc.php
@@ -13,7 +13,7 @@
 //    $conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);

 function databaseError($errMsg)

 {

-	die($errMsg);

+	die(print_r($errMsg,true));

 }

 

 function ucsmart($str) {

@@ -57,7 +57,7 @@
 $year = filter_var($_REQUEST['year'], FILTER_SANITIZE_NUMBER_INT);

 if ($year != "") $yearQ = "YEAR(publishDate) = " . $year . " AND ";

 

-$standardQ = ' "childCN" = 0 '; // AND YEAR(contractStart) >= 2007 AND YEAR(contractStart) <= 2010';

+$standardQ = ' "childCN" is null '; // AND YEAR(contractStart) >= 2007 AND YEAR(contractStart) <= 2010';

 $start =0.0;

 

 function include_header($title) {

@@ -207,5 +207,6 @@
    echo '<div id="ft"><p>'."Processing time: ". sprintf("%.4f", ($end-$start))." seconds".'</p></div>'; 

    echo '</div> </body> </html>';

 } 

+include ("graphs.inc.php");

 ?>