Skip to content

Commit

Permalink
XHTML compliance.
Browse files Browse the repository at this point in the history
  • Loading branch information
soranzo committed Apr 23, 2007
1 parent 6e6e146 commit 5d508f4
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 22 deletions.
32 changes: 16 additions & 16 deletions roles.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
/**
* Manage roles in a database cluster
*
* $Id: roles.php
* $Id: roles.php,v 1.5 2007/04/23 15:10:30 soranzo Exp $
*/

// Include application functions
Expand Down Expand Up @@ -34,7 +34,6 @@ function doCreate($msg = '') {
$misc->printMsg($msg);

echo "<form action=\"$PHP_SELF\" method=\"post\">\n";
echo $misc->form;
echo "<table>\n";
echo "\t<tr>\n\t\t<th class=\"data left required\" style=\"width: 130px\">{$lang['strname']}</th>\n";
echo "\t\t<td class=\"data1\"><input size=\"15\" maxlength=\"15\" name=\"formRolename\" value=\"", htmlspecialchars($_POST['formRolename']), "\" /></td>\n\t</tr>\n";
Expand All @@ -49,9 +48,9 @@ function doCreate($msg = '') {
echo "\t\t<td class=\"data1\"><input type=\"checkbox\" id=\"formCreateDB\" name=\"formCreateDB\"",
(isset($_POST['formCreateDB'])) ? ' checked="checked"' : '', " /></td>\n\t</tr>\n";
echo "\t<tr>\n\t\t<th class=\"data left\"><label for=\"formCreateRole\">{$lang['strcancreaterole']}</label></th>\n";
echo "\t\t<td class=\"data1\"><input type=\"checkbox\" id=\"formCreateDB\" name=\"formCreateRole\"",
echo "\t\t<td class=\"data1\"><input type=\"checkbox\" id=\"formCreateRole\" name=\"formCreateRole\"",
(isset($_POST['formCreateRole'])) ? ' checked="checked"' : '', " /></td>\n\t</tr>\n";
echo "\t<tr>\n\t\t<th class=\"data left\"><label for=\"formCreateDB\">{$lang['strinheritsprivs']}</label></th>\n";
echo "\t<tr>\n\t\t<th class=\"data left\"><label for=\"formInherits\">{$lang['strinheritsprivs']}</label></th>\n";
echo "\t\t<td class=\"data1\"><input type=\"checkbox\" id=\"formInherits\" name=\"formInherits\"",
(isset($_POST['formInherits'])) ? ' checked="checked"' : '', " /></td>\n\t</tr>\n";
echo "\t<tr>\n\t\t<th class=\"data left\"><label for=\"formCanLogin\">{$lang['strcanlogin']}</label></th>\n";
Expand Down Expand Up @@ -105,6 +104,7 @@ function doCreate($msg = '') {

echo "</table>\n";
echo "<p><input type=\"hidden\" name=\"action\" value=\"save_create\" />\n";
echo $misc->form;
echo "<input type=\"submit\" name=\"create\" value=\"{$lang['strcreate']}\" />\n";
echo "<input type=\"submit\" name=\"cancel\" value=\"{$lang['strcancel']}\" /></p>\n";
echo "</form>\n";
Expand Down Expand Up @@ -145,7 +145,7 @@ function doAlter($msg = '') {
global $PHP_SELF, $lang;

$misc->printTrail('role');
$misc->printTitle($lang['stralterrole'],'pg.role.alter');
$misc->printTitle($lang['stralter'],'pg.role.alter');
$misc->printMsg($msg);

$roledata = $data->getRole($_REQUEST['rolename']);
Expand All @@ -172,7 +172,6 @@ function doAlter($msg = '') {
}

echo "<form action=\"$PHP_SELF\" method=\"post\">\n";
echo $misc->form;
echo "<table>\n";
echo "\t<tr>\n\t\t<th class=\"data left\" style=\"width: 130px\">{$lang['strname']}</th>\n";
echo "\t\t<td class=\"data1\">", ($canRename ? "<input name=\"formNewRoleName\" size=\"15\" maxlength=\"15\" value=\"" . htmlspecialchars($_POST['formNewRoleName']) . "\" />" : $misc->printVal($roledata->fields['rolname'])), "</td>\n\t</tr>\n";
Expand Down Expand Up @@ -290,6 +289,7 @@ function doAlter($msg = '') {
echo "<input type=\"hidden\" name=\"memberofold\" value=\"", isset($_POST['memberofold']) ? $_POST['memberofold'] : htmlspecialchars($memberofold), "\" />\n";
echo "<input type=\"hidden\" name=\"membersold\" value=\"", isset($_POST['membersold']) ? $_POST['membersold'] : htmlspecialchars($membersold), "\" />\n";
echo "<input type=\"hidden\" name=\"adminmembersold\" value=\"", isset($_POST['adminmembersold']) ? $_POST['adminmembersold'] : htmlspecialchars($adminmembersold), "\" />\n";
echo $misc->form;
echo "<input type=\"submit\" name=\"alter\" value=\"{$lang['stralter']}\" />\n";
echo "<input type=\"submit\" name=\"cancel\" value=\"{$lang['strcancel']}\" /></p>\n";
echo "</form>\n";
Expand Down Expand Up @@ -336,11 +336,11 @@ function doDrop($confirm) {
echo "<p>", sprintf($lang['strconfdroprole'], $misc->printVal($_REQUEST['rolename'])), "</p>\n";

echo "<form action=\"$PHP_SELF\" method=\"post\">\n";
echo $misc->form;
echo "<input type=\"hidden\" name=\"action\" value=\"drop\" />\n";
echo "<p><input type=\"hidden\" name=\"action\" value=\"drop\" />\n";
echo "<input type=\"hidden\" name=\"rolename\" value=\"", htmlspecialchars($_REQUEST['rolename']), "\" />\n";
echo $misc->form;
echo "<input type=\"submit\" name=\"drop\" value=\"{$lang['strdrop']}\" />\n";
echo "<input type=\"submit\" name=\"cancel\" value=\"{$lang['strcancel']}\" />\n";
echo "<input type=\"submit\" name=\"cancel\" value=\"{$lang['strcancel']}\" /></p>\n";
echo "</form>\n";
}
else {
Expand Down Expand Up @@ -468,11 +468,11 @@ function doAccount($msg = '') {
echo "\t\t<th class=\"data\">{$lang['strsessiondefaults']}</th>\n";
echo "\t</tr>\n";
echo "\t<tr>\n\t\t<td class=\"data1\">", $misc->printVal($roledata->fields['rolname']), "</td>\n";
echo "\t\t<td class=\"data1\" id=\"center\">", (($roledata->fields['rolsuper']) ? $lang['stryes'] : $lang['strno']), "</td>\n";
echo "\t\t<td class=\"data1\" id=\"center\">", (($roledata->fields['rolcreatedb']) ? $lang['stryes'] : $lang['strno']), "</td>\n";
echo "\t\t<td class=\"data1\" id=\"center\">", (($roledata->fields['rolcreaterole']) ? $lang['stryes'] : $lang['strno']), "</td>\n";
echo "\t\t<td class=\"data1\" id=\"center\">", (($roledata->fields['rolinherit']) ? $lang['stryes'] : $lang['strno']), "</td>\n";
echo "\t\t<td class=\"data1\" id=\"center\">", ($roledata->fields['rolconnlimit'] == '-1' ? $lang['strnolimit'] : $misc->printVal($roledata->fields['rolconnlimit'])), "</td>\n";
echo "\t\t<td class=\"data1\">", $misc->printVal($roledata->fields['rolsuper'], 'yesno'), "</td>\n";
echo "\t\t<td class=\"data1\">", $misc->printVal($roledata->fields['rolcreatedb'], 'yesno'), "</td>\n";
echo "\t\t<td class=\"data1\">", $misc->printVal($roledata->fields['rolcreaterole'], 'yesno'), "</td>\n";
echo "\t\t<td class=\"data1\">", $misc->printVal($roledata->fields['rolinherit'], 'yesno'), "</td>\n";
echo "\t\t<td class=\"data1\">", ($roledata->fields['rolconnlimit'] == '-1' ? $lang['strnolimit'] : $misc->printVal($roledata->fields['rolconnlimit'])), "</td>\n";
echo "\t\t<td class=\"data1\">", ($roledata->fields['rolvaliduntil'] == 'infinity' || is_null($roledata->fields['rolvaliduntil']) ? $lang['strnever'] : $misc->printVal($roledata->fields['rolvaliduntil'])), "</td>\n";
echo "\t\t<td class=\"data1\">", $misc->printVal($roledata->fields['rolconfig']), "</td>\n";
echo "\t</tr>\n</table>\n";
Expand Down Expand Up @@ -501,15 +501,15 @@ function doChangePassword($confirm, $msg = '') {
if (!isset($_POST['confirm'])) $_POST['confirm'] = '';

echo "<form action=\"$PHP_SELF\" method=\"post\">\n";
echo $misc->form;
echo "<table>\n";
echo "\t<tr>\n\t\t<th class=\"data left required\">{$lang['strpassword']}</th>\n";
echo "\t\t<td><input type=\"password\" name=\"password\" size=\"32\" value=\"",
htmlspecialchars($_POST['password']), "\" /></td>\n\t</tr>\n";
echo "\t<tr>\n\t\t<th class=\"data left required\">{$lang['strconfirm']}</th>\n";
echo "\t\t<td><input type=\"password\" name=\"confirm\" size=\"32\" value=\"\" /></td>\n\t</tr>\n";
echo "<table>\n";
echo "</table>\n";
echo "<p><input type=\"hidden\" name=\"action\" value=\"changepassword\" />\n";
echo $misc->form;
echo "<input type=\"submit\" name=\"ok\" value=\"{$lang['strok']}\" />\n";
echo "<input type=\"submit\" name=\"cancel\" value=\"{$lang['strcancel']}\" />\n";
echo "</p></form>\n";
Expand Down
7 changes: 1 addition & 6 deletions themes/default/global.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* Default style sheet
*
* $Id: global.css,v 1.42 2007/04/16 19:24:28 ioguix Exp $
* $Id: global.css,v 1.43 2007/04/23 15:10:30 soranzo Exp $
*/

/** ELEMENTS */
Expand Down Expand Up @@ -126,11 +126,6 @@ th.data a:active, th.data a:link, th.data a:visited, th.data a:hover
text-align: left;
}

#center
{
text-align: center;
}

td.dat
{
color: #ff0;
Expand Down

0 comments on commit 5d508f4

Please sign in to comment.