Merge pull request #8 from LDAPAccountManager/responsive_config

responsive
This commit is contained in:
gruberroland 2016-12-18 13:11:09 +01:00 committed by GitHub
commit 184b0e5b82
1 changed files with 35 additions and 21 deletions

View File

@ -70,11 +70,14 @@ echo $_SESSION['header'];
?> ?>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title> <title>
<?php <?php
echo _("Login"); echo _("Login");
?> ?>
</title> </title>
<link rel="stylesheet" type="text/css" href="../../style/responsive/105_normalize.css">
<link rel="stylesheet" type="text/css" href="../../style/responsive/110_foundation.css">
<?php <?php
// include all CSS files // include all CSS files
$cssDirName = dirname(__FILE__) . '/../../style'; $cssDirName = dirname(__FILE__) . '/../../style';
@ -94,7 +97,7 @@ echo $_SESSION['header'];
?> ?>
<link rel="shortcut icon" type="image/x-icon" href="../../graphics/favicon.ico"> <link rel="shortcut icon" type="image/x-icon" href="../../graphics/favicon.ico">
</head> </head>
<body> <body class="admin">
<?php <?php
// set focus on password field // set focus on password field
echo "<script type=\"text/javascript\" language=\"javascript\">\n"; echo "<script type=\"text/javascript\" language=\"javascript\">\n";
@ -118,6 +121,8 @@ echo $_SESSION['header'];
echo "<script type=\"text/javascript\" src=\"../lib/" . $jsEntry . "\"></script>\n"; echo "<script type=\"text/javascript\" src=\"../lib/" . $jsEntry . "\"></script>\n";
} }
?> ?>
<script type="text/javascript" src="../lib/extra/responsive/200_modernizr.js"></script>
<script type="text/javascript" src="../lib/extra/responsive/250_foundation.js"></script>
<table border=0 width="100%" class="lamHeader ui-corner-all"> <table border=0 width="100%" class="lamHeader ui-corner-all">
<tr> <tr>
<td align="left" height="30"> <td align="left" height="30">
@ -147,35 +152,44 @@ echo $_SESSION['header'];
<tr><td> <tr><td>
<?php <?php
$spacer = new htmlSpacer('20px', '20px'); $spacer = new htmlSpacer('20px', '20px');
$table = new htmlTable(); $group = new htmlGroup();
$caption = new htmlOutputText(_("Please enter the master password to change the general preferences:")); $row = new htmlResponsiveRow();
$table->addElement($caption, true); $row->add(new htmlOutputText(_("Please enter the master password to change the general preferences:")), 12);
$table->addElement($spacer, true); $group->addElement($row);
// print message if login was incorrect or no config profiles are present // print message if login was incorrect or no config profiles are present
if (isset($message)) { // $message is set by confmain.php (requires conflogin.php then) if (isset($message)) {
$messageField = new htmlStatusMessage('ERROR', $message); $messageField = new htmlStatusMessage('ERROR', $message);
$table->addElement($messageField, true); $row = new htmlResponsiveRow();
$table->addElement($spacer, true); $row->add($messageField, 12);
$group->addElement($spacer);
$group->addElement($row);
} }
// password field $group->addElement($spacer);
$gap = new htmlSpacer('1px', null); // password input
$label = new htmlOutputText(_('Master password'));
$passwordGroup = new htmlGroup(); $passwordGroup = new htmlGroup();
$passwordGroup->alignment = htmlElement::ALIGN_CENTER;
$passwordGroup->addElement(new htmlOutputText(_('Master password')));
$passwordGroup->addElement($gap);
$passwordField = new htmlInputField('passwd'); $passwordField = new htmlInputField('passwd');
$passwordField->setFieldSize(15); $passwordField->setFieldSize(15);
$passwordField->setIsPassword(true); $passwordField->setIsPassword(true);
$passwordGroup->addElement($passwordField); $passwordGroup->addElement($passwordField);
$passwordGroup->addElement($gap);
$passwordGroup->addElement(new htmlButton('submit', _("Ok")));
$passwordGroup->addElement($gap);
$passwordGroup->addElement(new htmlHelpLink('236')); $passwordGroup->addElement(new htmlHelpLink('236'));
$table->addElement($passwordGroup, true); $passwordDiv = new htmlDiv(null, $passwordGroup);
$passwordDiv->setCSSClasses(array('nowrap'));
$row = new htmlResponsiveRow($label, $passwordDiv);
$group->addElement($row);
// button
$group->addElement($spacer);
$okButton = new htmlButton('submit', _("Ok"));
$row = new htmlResponsiveRow();
$row->add($okButton, 12);
$row->setCSSClasses(array(''));
$group->addElement($row);
$div = new htmlDiv(null, $group);
$div->setCSSClasses(array('centeredTable'));
$tabindex = 1; $tabindex = 1;
parseHtml(null, $table, array(), false, $tabindex, 'user'); parseHtml(null, $div, array(), false, $tabindex, 'user');
?> ?>
</td></tr> </td></tr>
</table> </table>