1
0
mirror of https://github.com/DataTables/DataTables.git synced 2025-02-19 17:54:14 +01:00

Fix: With all warnings enabled in PHP, there were certain DataTables initialisations which could trigger warnings in the example server porecessing script.

This commit is contained in:
Allan Jardine 2011-03-01 21:44:43 +00:00
parent 25840887e4
commit 07b3557c53

View File

@ -53,6 +53,7 @@
/* /*
* Ordering * Ordering
*/ */
$sOrder = "";
if ( isset( $_GET['iSortCol_0'] ) ) if ( isset( $_GET['iSortCol_0'] ) )
{ {
$sOrder = "ORDER BY "; $sOrder = "ORDER BY ";
@ -80,7 +81,7 @@
* on very large tables, and MySQL's regex functionality is very limited * on very large tables, and MySQL's regex functionality is very limited
*/ */
$sWhere = ""; $sWhere = "";
if ( $_GET['sSearch'] != "" ) if ( isset($_GET['sSearch']) && $_GET['sSearch'] != "" )
{ {
$sWhere = "WHERE ("; $sWhere = "WHERE (";
for ( $i=0 ; $i<count($aColumns) ; $i++ ) for ( $i=0 ; $i<count($aColumns) ; $i++ )
@ -94,7 +95,7 @@
/* Individual column filtering */ /* Individual column filtering */
for ( $i=0 ; $i<count($aColumns) ; $i++ ) for ( $i=0 ; $i<count($aColumns) ; $i++ )
{ {
if ( $_GET['bSearchable_'.$i] == "true" && $_GET['sSearch_'.$i] != '' ) if ( isset($_GET['bSearchable_'.$i]) && $_GET['bSearchable_'.$i] == "true" && $_GET['sSearch_'.$i] != '' )
{ {
if ( $sWhere == "" ) if ( $sWhere == "" )
{ {