/**
* List constraints on a table
*
- * $Id: constraints.php,v 1.23 2003/12/10 16:03:29 chriskl Exp $
+ * $Id: constraints.php,v 1.24 2003/12/15 15:42:45 chriskl Exp $
*/
// Include application functions
echo "<form action=\"$PHP_SELF\" method=\"post\">\n";
echo "<table>\n";
echo "<tr><th class=\"data\">{$lang['strname']}</th>\n";
- echo "<th class=\"data\">{$lang['strdefinition']}</th></tr>\n";
+ echo "<th class=\"data required\">{$lang['strdefinition']}</th></tr>\n";
echo "<tr><td class=\"data1\"><input name=\"name\" size=\"16\" maxlength=\"{$data->_maxNameLen}\" value=\"",
htmlspecialchars($_POST['name']), "\" /></td>\n";
echo "<input type=\"hidden\" name=\"action\" value=\"save_add_check\" />\n";
echo "<input type=\"hidden\" name=\"table\" value=\"", htmlspecialchars($_REQUEST['table']), "\" />\n";
echo $misc->form;
- echo "<p><input type=\"submit\" name=\"ok\" value=\"{$lang['strok']}\" /> <input type=\"submit\" name=\"cancel\" value=\"{$lang['strcancel']}\" /></p>\n";
+ echo "<p><input type=\"submit\" name=\"ok\" value=\"{$lang['stradd']}\" />\n";
+ echo "<input type=\"submit\" name=\"cancel\" value=\"{$lang['strcancel']}\" /></p>\n";
echo "</form>\n";
}
/**
* List tables in a database
*
- * $Id: tables.php,v 1.41 2003/12/13 16:17:09 chriskl Exp $
+ * $Id: tables.php,v 1.42 2003/12/15 15:42:45 chriskl Exp $
*/
// Include application functions
echo "<form action=\"$PHP_SELF\" method=\"post\">\n";
echo "<table>\n";
- echo "<tr><th class=\"data\">{$lang['strname']}</th></tr>\n";
- echo "<tr><td class=\"data1\"><input name=\"name\" size=\"32\" maxlength=\"{$data->_maxNameLen}\" value=\"",
+ echo "<tr><th class=\"data left required\">{$lang['strname']}</th>\n";
+ echo "<td class=\"data\"><input name=\"name\" size=\"32\" maxlength=\"{$data->_maxNameLen}\" value=\"",
htmlspecialchars($_REQUEST['name']), "\" /></td></tr>\n";
- echo "<tr><th class=\"data\">{$lang['strnumfields']}</th></tr>\n";
- echo "<tr><td class=\"data1\"><input name=\"fields\" size=\"5\" maxlength=\"{$data->_maxNameLen}\" value=\"",
+ echo "<tr><th class=\"data left required\">{$lang['strnumfields']}</th>\n";
+ echo "<td class=\"data\"><input name=\"fields\" size=\"5\" maxlength=\"{$data->_maxNameLen}\" value=\"",
htmlspecialchars($_REQUEST['fields']), "\" /></td></tr>\n";
if ($data->hasWithoutOIDs()) {
- echo "<tr><th class=\"data\">{$lang['stroptions']}</th></tr>\n";
- echo "<tr><td class=\"data1\"><input type=\"checkbox\" name=\"withoutoids\"",
+ echo "<tr><th class=\"data left\">{$lang['stroptions']}</th>\n";
+ echo "<td class=\"data\"><input type=\"checkbox\" name=\"withoutoids\"",
(isset($_REQUEST['withoutoids']) ? ' checked="checked"' : ''), " />WITHOUT OIDS</td></tr>\n";
}
echo "</table>\n";
* Ask for select parameters and perform select
*/
function doSelectRows($confirm, $msg = '') {
- global $database, $misc;
+ global $data, $misc;
global $lang;
global $PHP_SELF;
* Show confirmation of empty and perform actual empty
*/
function doEmpty($confirm) {
- global $database, $misc;
+ global $data, $misc;
global $lang;
global $PHP_SELF;
* Show confirmation of drop and perform actual drop
*/
function doDrop($confirm) {
- global $database, $misc;
+ global $data, $misc;
global $lang, $_reload_browser;
global $PHP_SELF;
/**
* List tables in a database
*
- * $Id: tblproperties.php,v 1.31 2003/12/10 16:03:29 chriskl Exp $
+ * $Id: tblproperties.php,v 1.32 2003/12/15 15:42:45 chriskl Exp $
*/
// Include application functions
echo "<form action=\"$PHP_SELF\" method=\"post\">\n";
echo "<table>\n";
- echo "<tr><th class=\"data\">{$lang['strname']}</th>\n";
+ echo "<tr><th class=\"data required\">{$lang['strname']}</th>\n";
echo "<td class=\"data1\">";
echo "<input name=\"name\" size=\"32\" maxlength=\"{$data->_maxNameLen}\" value=\"",
htmlspecialchars($_POST['name']), "\" /></td></tr>\n";
if ($data->hasAlterTableOwner()) {
- echo "<tr><th class=\"data\">{$lang['strowner']}</th>\n";
+ echo "<tr><th class=\"data required\">{$lang['strowner']}</th>\n";
echo "<td class=\"data1\"><select name=\"owner\">";
while (!$users->EOF) {
$uname = $users->f[$data->uFields['uname']];
// Output table header
echo "<table>\n<tr>";
- echo "<tr><th class=\"data\">{$lang['strfield']}</th><th class=\"data\">{$lang['strtype']}</th><th class=\"data\">{$lang['strlength']}</th></tr>";
+ echo "<tr><th class=\"data required\">{$lang['strfield']}</th><th class=\"data required\">{$lang['strtype']}</th><th class=\"data\">{$lang['strlength']}</th></tr>";
echo "<tr><td><input name=\"field\" size=\"32\" maxlength=\"{$data->_maxNameLen}\" value=\"",
htmlspecialchars($_POST['field']), "\" /></td>";
// Output table header
echo "<table>\n<tr>";
- echo "<tr><th class=\"data\">{$lang['strfield']}</th><th class=\"data\">{$lang['strtype']}</th><th class=\"data\">{$lang['strnotnull']}</th><th class=\"data\">{$lang['strdefault']}</th></tr>";
+ echo "<tr><th class=\"data required\">{$lang['strname']}</th><th class=\"data required\">{$lang['strtype']}</th><th class=\"data\">{$lang['strnotnull']}</th><th class=\"data\">{$lang['strdefault']}</th></tr>";
$column = &$data->getTableAttributes($_REQUEST['table'], $_REQUEST['column']);
$column->f['attnotnull'] = $data->phpBool($column->f['attnotnull']);
/**
* List triggers on a table
*
- * $Id: triggers.php,v 1.17 2003/12/10 16:03:29 chriskl Exp $
+ * $Id: triggers.php,v 1.18 2003/12/15 15:42:45 chriskl Exp $
*/
// Include application functions
echo "<td class=\"data1\">(<input type=\"text\" name=\"formTriggerArgs\" size=\"32\" />)</td>\n";
echo "</tr></table>\n";
echo "<p><input type=\"submit\" value=\"{$lang['strcreate']}\" />\n";
- echo "<input type=\"reset\" value=\"{$lang['strreset']}\" /></p>\n";
+ echo "<input type=\"submit\" name=\"cancel\" value=\"{$lang['strcancel']}\" /></p>\n";
echo "<input type=\"hidden\" name=\"action\" value=\"save_create\" />\n";
echo "<input type=\"hidden\" name=\"table\" value=\"", htmlspecialchars($_REQUEST['table']), "\" />\n";
echo $misc->form;
doAlter();
break;
case 'save_create':
- doSaveCreate();
+ if (isset($_POST['cancel'])) doDefault();
+ else doSaveCreate();
break;
case 'create':
doCreate();