From 90af8e9dc5abdb30dc18a5e709ba9f008fb16849 Mon Sep 17 00:00:00 2001 From: Rouslan Placella Date: Fri, 10 Jun 2011 17:56:20 +0100 Subject: [PATCH] Moved some code in db_routines.inc.php to logically separate arbitrary code from functions. --- libraries/db_routines.inc.php | 60 +++++++++++++++++------------------ 1 file changed, 30 insertions(+), 30 deletions(-) diff --git a/libraries/db_routines.inc.php b/libraries/db_routines.inc.php index 61dc47cba5..293f479e35 100644 --- a/libraries/db_routines.inc.php +++ b/libraries/db_routines.inc.php @@ -7,36 +7,6 @@ if (! defined('PHPMYADMIN')) { exit; } -// Some definitions -$param_directions = array('IN', - 'OUT', - 'INOUT'); -$param_opts_num = array('UNSIGNED', - 'ZEROFILL', - 'UNSIGNED ZEROFILL'); -$param_sqldataaccess = array('NO SQL', - 'CONTAINS SQL', - 'READS SQL DATA', - 'MODIFIES SQL DATA'); - -/** - * Generate the conditional classes that will be used to attach jQuery events to links. - */ -$ajax_class = array( - 'add' => '', - 'edit' => '', - 'exec' => '', - 'drop' => '', - 'export' => '' - ); -if ($GLOBALS['cfg']['AjaxEnable']) { - $ajax_class['add'] = 'class="add_routine_anchor"'; - $ajax_class['edit'] = 'class="edit_routine_anchor"'; - $ajax_class['exec'] = 'class="exec_routine_anchor"'; - $ajax_class['drop'] = 'class="drop_routine_anchor"'; - $ajax_class['export'] = 'class="export_routine_anchor"'; -} - /** * This function processes the datatypes supported by the DB, as specified in * $cfg['ColumnTypes'] and either returns an array (useful for quickly checking @@ -1214,6 +1184,36 @@ function routineMakeRowForList($routine, $ct = 0) { // $url_query .= '&goto=db_routines.php' . rawurlencode("?db=$db"); // FIXME +// Some definitions +$param_directions = array('IN', + 'OUT', + 'INOUT'); +$param_opts_num = array('UNSIGNED', + 'ZEROFILL', + 'UNSIGNED ZEROFILL'); +$param_sqldataaccess = array('NO SQL', + 'CONTAINS SQL', + 'READS SQL DATA', + 'MODIFIES SQL DATA'); + +/** + * Generate the conditional classes that will be used to attach jQuery events to links. + */ +$ajax_class = array( + 'add' => '', + 'edit' => '', + 'exec' => '', + 'drop' => '', + 'export' => '' + ); +if ($GLOBALS['cfg']['AjaxEnable']) { + $ajax_class['add'] = 'class="add_routine_anchor"'; + $ajax_class['edit'] = 'class="edit_routine_anchor"'; + $ajax_class['exec'] = 'class="exec_routine_anchor"'; + $ajax_class['drop'] = 'class="drop_routine_anchor"'; + $ajax_class['export'] = 'class="export_routine_anchor"'; +} + /** * Keep a list of errors that occured while processing an 'Add' or 'Edit' operation. */