printConnection($onchange); } /** * Searches for a named database object */ function doFind() { global $data, $misc; global $lang, $conf; if (!isset($_REQUEST['term'])) $_REQUEST['term'] = ''; if (!isset($_REQUEST['filter'])) $_REQUEST['filter'] = ''; $misc->printHeader($lang['strfind']); // Bring to the front always echo "\n"; $misc->printTabs($misc->getNavTabs('popup'), 'find'); echo "
\n"; _printConnection(); echo "

_maxNameLen}\" />\n"; // Output list of filters. This is complex due to all the 'has' and 'conf' feature possibilities echo "\n"; echo "\n"; echo "

\n"; echo "
\n"; // Default focus $misc->setFocus('forms[0].term'); } /** * Allow execution of arbitrary SQL statements on a database */ function doDefault() { global $data, $misc; global $lang; if (!isset($_SESSION['sqlquery'])) $_SESSION['sqlquery'] = ''; $misc->printHeader($lang['strsql']); // Bring to the front always echo "\n"; $misc->printTabs($misc->getNavTabs('popup'), 'sql'); echo "
\n"; _printConnection(); echo "\n"; if (!isset($_REQUEST['search_path'])) $_REQUEST['search_path'] = implode(',',$data->getSearchPath()); echo "

\n"; echo "\n"; echo "

\n"; echo "

\n"; echo "

\n"; echo "
\n"; // Default focus $misc->setFocus('forms[0].query'); } switch ($action) { case 'find': doFind(); break; case 'sql': default: doDefault(); break; } // Set the name of the window $misc->setWindowName('sqledit'); $misc->printFooter(); ?>