
"nav"-frame to the "queryframe"-frame, altered the way the form is submitted in LeftFrameLight mode to keep the queryframe. Only if JavaScript is usable, otherwise it's not necessary to keep the 'opener' pointer.
66 lines
1.7 KiB
PHP
66 lines
1.7 KiB
PHP
<?php
|
|
/* $Id$ */
|
|
// vim: expandtab sw=4 ts=4 sts=4:
|
|
|
|
/**
|
|
* Gets some core libraries
|
|
*/
|
|
if (!defined('PMA_GRAB_GLOBALS_INCLUDED')) {
|
|
include('./libraries/grab_globals.lib.php3');
|
|
}
|
|
if (!defined('PMA_COMMON_LIB_INCLUDED')) {
|
|
include('./libraries/common.lib.php3');
|
|
}
|
|
if (!defined('PMA_BOOKMARK_LIB_INCLUDED')) {
|
|
include('./libraries/bookmark.lib.php3');
|
|
}
|
|
|
|
|
|
/**
|
|
* Defines the urls to return to in case of error in a sql statement
|
|
*/
|
|
$err_url_0 = 'main.php3?' . PMA_generate_common_url();
|
|
$err_url = $cfg['DefaultTabDatabase'] . '?' . PMA_generate_common_url($db);
|
|
|
|
|
|
/**
|
|
* Ensures the database exists (else move to the "parent" script) and displays
|
|
* headers
|
|
*/
|
|
if (!isset($is_db) || !$is_db) {
|
|
// Not a valid db name -> back to the welcome page
|
|
if (!empty($db)) {
|
|
$is_db = @PMA_mysql_select_db($db);
|
|
}
|
|
if (empty($db) || !$is_db) {
|
|
header('Location: ' . $cfg['PmaAbsoluteUri'] . 'main.php3?' . PMA_generate_common_url('', '', '&') . (isset($message) ? '&message=' . urlencode($message) : '') . '&reload=1');
|
|
exit();
|
|
}
|
|
} // end if (ensures db exists)
|
|
// Displays headers
|
|
if (!isset($message)) {
|
|
$js_to_run = 'functions.js';
|
|
include('./header.inc.php3');
|
|
// Reloads the navigation frame via JavaScript if required
|
|
if (isset($reload) && $reload) {
|
|
echo "\n";
|
|
?>
|
|
<script type="text/javascript" language="javascript1.2">
|
|
<!--
|
|
window.parent.frames['nav'].location.replace('./left.php3?<?php echo PMA_generate_common_url($db, '', '&'); ?>');
|
|
//-->
|
|
</script>
|
|
<?php
|
|
}
|
|
echo "\n";
|
|
} else {
|
|
PMA_showMessage($message);
|
|
}
|
|
|
|
/**
|
|
* Set parameters for links
|
|
*/
|
|
$url_query = PMA_generate_common_url($db);
|
|
|
|
?>
|