1) { /** * @todo if there are more than one table name in the Select: * - do not extract the first table name * - do not show a table name in the page header * - do not display the sub-pages links) */ $table = ''; } else { $table = $analyzed_sql_results['select_tables'][0][0]; if (!empty($analyzed_sql_results['select_tables'][0][1])) { $db = $analyzed_sql_results['select_tables'][0][1]; } } // There is no point checking if a reload is required if we already decided // to reload. Also, no reload is required for AJAX requests. $response = Response::getInstance(); if (empty($reload) && ! $response->isAjax()) { // NOTE: Database names are case-insensitive. $reload = strcasecmp($db, $prev_db) != 0; } // Updating the array. $analyzed_sql_results['reload'] = $reload; } return array($analyzed_sql_results, $db, $table); } }