/**
* Class to hold various commonly used functions
*
- * $Id: Misc.php,v 1.65 2004/06/07 11:38:38 soranzo Exp $
+ * $Id: Misc.php,v 1.66 2004/06/11 05:08:26 xzilla Exp $
*/
class Misc {
if (!is_array($arr) || sizeof($arr) == 0) return;
if ($help !== null && isset($data->help_page[$help])) {
- echo "<table border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">\n";
+ echo "<br /><table border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">\n";
echo "<tr><td><h2>";
// Join array with separator character
echo implode($lang['strseparator'], $arr);
* A class that implements the DB interface for Postgres
* Note: This class uses ADODB and returns RecordSets.
*
- * $Id: Postgres.php,v 1.222 2004/06/07 11:38:39 soranzo Exp $
+ * $Id: Postgres.php,v 1.223 2004/06/11 05:08:26 xzilla Exp $
*/
// @@@ THOUGHT: What about inherits? ie. use of ONLY???
var $joinOps = array('INNER JOIN' => 'INNER JOIN');
// Default help URL
- var $help_base = 'http://www.postgresql.org/docs/7/static/';
+ var $help_base = 'http://www.postgresql.org/docs/7/interactive/';
// Help sub pages
var $help_page = array(
'create_table' => 'sql-createtable.htm'
+ 'drop_table' => 'sql-droptable.htm',
+ 'insert' => 'sql-insert.htm',
+ 'select' => 'sql-select.htm',
+ 'tables' => 'ddl.htm#DDL-BASICS',
+ 'schemas' => 'ddl-schemas.htm',
+ 'create_schema' => 'sql-createschema.htm',
+ 'alter_schema' => 'sql-alterschema.htm',
+ 'drop_schema' => 'sql-dropschema.htm',
+ 'runtime_config' => 'runtime-config.htm',
+ 'processes' => 'monitoring-stats.htm#MONITORING-STATS-VIEWS-TABLE',
+ 'sql' => 'sql-syntax.htm',
);
/**
* A class that implements the DB interface for Postgres
* Note: This class uses ADODB and returns RecordSets.
*
- * $Id: Postgres71.php,v 1.59 2004/06/06 08:50:28 chriskl Exp $
+ * $Id: Postgres71.php,v 1.60 2004/06/11 05:08:26 xzilla Exp $
*/
// @@@ THOUGHT: What about inherits? ie. use of ONLY???
var $joinOps = array('INNER JOIN' => 'INNER JOIN', 'LEFT JOIN' => 'LEFT JOIN', 'RIGHT JOIN' => 'RIGHT JOIN', 'FULL JOIN' => 'FULL JOIN');
// Default help URL
- var $help_base = 'http://www.postgresql.org/docs/7.1/static/';
+ var $help_base = 'http://www.postgresql.org/docs/7.1/interactive/';
// Help sub pages (alphabetical order)
var $help_page = array(
'drop_table' => 'sql-droptable.html',
'insert' => 'sql-insert.html',
'select' => 'sql-select.html',
- 'tables' => 'ddl.html#DDL-BASICS'
+ 'tables' => 'ddl.html#DDL-BASICS',
+ 'schemas' => 'ddl-schemas.html',
+ 'create_schema' => 'sql-createschema.html',
+ 'alter_schema' => 'sql-alterschema.html',
+ 'drop_schema' => 'sql-dropschema.html',
+ 'runtime_config' => 'runtime-config.html',
+ 'processes' => 'monitoring-stats.html#MONITORING-STATS-VIEWS-TABLE',
+ 'sql' => 'sql-syntax.html',
);
/**
* A class that implements the DB interface for Postgres
* Note: This class uses ADODB and returns RecordSets.
*
- * $Id: Postgres72.php,v 1.69 2004/06/06 08:50:28 chriskl Exp $
+ * $Id: Postgres72.php,v 1.70 2004/06/11 05:08:26 xzilla Exp $
*/
var $extraTypes = array('SERIAL', 'BIGSERIAL');
// Default help URL
- var $help_base = 'http://www.postgresql.org/docs/7.2/static/';
+ var $help_base = 'http://www.postgresql.org/docs/7.2/interactive/';
/**
* Constructor
* A class that implements the DB interface for Postgres
* Note: This class uses ADODB and returns RecordSets.
*
- * $Id: Postgres73.php,v 1.120 2004/06/07 11:38:39 soranzo Exp $
+ * $Id: Postgres73.php,v 1.121 2004/06/11 05:08:27 xzilla Exp $
*/
// @@@ THOUGHT: What about inherits? ie. use of ONLY???
'IN' => 'x', 'NOT IN' => 'x');
// Default help URL
- var $help_base = 'http://www.postgresql.org/docs/7.3/static/';
+ var $help_base = 'http://www.postgresql.org/docs/7.3/interactive/';
/**
* Constructor
* A class that implements the DB interface for Postgres
* Note: This class uses ADODB and returns RecordSets.
*
- * $Id: Postgres74.php,v 1.33 2004/06/06 08:50:28 chriskl Exp $
+ * $Id: Postgres74.php,v 1.34 2004/06/11 05:08:27 xzilla Exp $
*/
include_once('./classes/database/Postgres73.php');
var $_maxNameLen = 63;
// Default help URL
- var $help_base = 'http://www.postgresql.org/docs/7.4/static/';
+ var $help_base = 'http://www.postgresql.org/docs/7.4/interactive/';
/**
* Constructor
/**
* Manage schemas within a database
*
- * $Id: database.php,v 1.47 2004/06/03 07:34:56 chriskl Exp $
+ * $Id: database.php,v 1.48 2004/06/11 05:08:19 xzilla Exp $
*/
// Include application functions
if (!isset($_GET['term'])) $_GET['term'] = '';
$misc->printDatabaseNav();
- echo "<h2>", $misc->printVal($_REQUEST['database']), ": {$lang['strfind']}</h2>\n";
+ $misc->printTitle(array($misc->printVal($_REQUEST['database']),$lang['strfind']));
$misc->printMsg($msg);
echo "<form action=\"$PHP_SELF\" method=\"get\">\n";
else {
if ($curr != '') echo "</ul>\n";
$curr = $rs->f['type'];
- echo "<h2>";
+ echo "<h3>";
switch ($curr) {
case 'SCHEMA':
echo $lang['strschemas'];
echo $lang['stropclasses'];
break;
}
- echo "</h2>";
+ echo "</h3>";
echo "<ul>\n";
}
}
global $PHP_SELF, $lang;
$misc->printDatabaseNav();
- echo "<h2>", $misc->printVal($_REQUEST['database']), ": {$lang['strexport']}</h2>\n";
+ $misc->printTitle(array($misc->printVal($_REQUEST['database']),$lang['strexport']));
$misc->printMsg($msg);
echo "<form action=\"dbexport.php\" method=\"post\">\n";
$variables = &$data->getVariables();
$misc->printDatabaseNav();
- echo "<h2>", $misc->printVal($_REQUEST['database']), ": {$lang['strvariables']}</h2>\n";
+
+ $misc->printTitle(array($misc->printVal($_REQUEST['database']),$lang['strvariables']),'runtime_config');
if ($variables->recordCount() > 0) {
echo "<table>\n";
$processes = &$data->getProcesses($_REQUEST['database']);
$misc->printDatabaseNav();
- echo "<h2>", $misc->printVal($_REQUEST['database']), ": {$lang['strprocesses']}</h2>\n";
+ $misc->printTitle(array($misc->printVal($_REQUEST['database']),$lang['strprocesses']),'processes');
if ($processes->recordCount() > 0) {
echo "<table>\n";
break;
default:
$misc->printDatabaseNav();
- echo "<h2>", $misc->printVal($_REQUEST['database']), ": {$lang['stradmin']}</h2>\n";
+ $misc->printTitle(array($misc->printVal($_REQUEST['database']),$lang['stradmin']));
$misc->printMsg($msg);
// Vacuum
if (!isset($_REQUEST['query'])) $_REQUEST['query'] = '';
$misc->printDatabaseNav();
- echo "<h2>", $misc->printVal($_REQUEST['database']), ": {$lang['strsql']}</h2>\n";
+ $misc->printTitle(array($misc->printVal($_REQUEST['database']),$lang['strsql']),'sql');
echo "<p>{$lang['strentersql']}</p>\n";
echo "<form action=\"sql.php\" method=\"post\" enctype=\"multipart/form-data\">\n";
global $lang, $_reload_browser;
if ($confirm) {
- echo "<h2>", $misc->printVal($_REQUEST['database']), ": ",
- $misc->printVal($_REQUEST['schema']), ": {$lang['strdrop']}</h2>\n";
+ $misc->printTitle(array($misc->printVal($_REQUEST['database']),$misc->printVal($_REQUEST['schema']),$lang['strdrop']),'drop_schema');
echo "<p>", sprintf($lang['strconfdropschema'], $misc->printVal($_REQUEST['schema'])), "</p>\n";
// Fetch all users from the database
$users = &$data->getUsers();
- echo "<h2>", $misc->printVal($_REQUEST['database']), ": {$lang['strcreateschema']}</h2>\n";
+ $misc->printTitle(array($misc->printVal($_REQUEST['database']),$lang['strcreateschema']),'create_schema');
$misc->printMsg($msg);
echo "<form action=\"$PHP_SELF\" method=\"post\">\n";
global $PHP_SELF, $lang;
$misc->printDatabaseNav();
- echo "<h2>", $misc->printVal($_REQUEST['database']), ": {$lang['strschemas']}</h2>\n";
+ $misc->printTitle(array($misc->printVal($_REQUEST['database']),$lang['strschemas']),'schemas');
$misc->printMsg($msg);
// Check that the DB actually supports schemas
/**
* Display properties of a schema
*
- * $Id: schema.php,v 1.16 2004/05/31 13:25:49 chriskl Exp $
+ * $Id: schema.php,v 1.17 2004/06/11 05:08:25 xzilla Exp $
*/
include_once('./libraries/lib.inc.php');
$schema = &$data->getSchemaByName($_REQUEST['schema']);
- echo "<h2>", $misc->printVal($_REQUEST['database']), ": {$lang['strschemas']}: ",
- $misc->printVal($_REQUEST['schema']), "</h2>\n";
+ $misc->printTitle(array($misc->printVal($_REQUEST['database']),$lang['strschemas'],$misc->printVal($_REQUEST['schema'])),'schemas');
// Show comment if any
if ($schema->f[$data->nspFields['nspcomment']] !== null)
function doAlter($msg = '') {
global $data, $misc,$PHP_SELF, $lang;
- echo "<h2>", $misc->printVal($_REQUEST['database']), ": ", $misc->printVal($_REQUEST['schema']), ": {$lang['stralter']}</h2>\n";
+ $misc->printTitle(array($misc->printVal($_REQUEST['database']),$misc->printVal($_REQUEST['schema']),$lang['stralter']),'alter_schema');
$misc->printMsg($msg);
$schema = &$data->getSchemaByName($_REQUEST['schema']);