fixing login form

skala
Julio Montoya 13 years ago
parent d621b81d5b
commit 2aa97eb963
  1. 4
      main/css/base.css
  2. 8
      main/inc/lib/formvalidator/FormValidator.class.php
  3. 8
      main/inc/lib/userportal.lib.php

@ -28,7 +28,9 @@ legend {
margin-bottom: 10px;
}
#formLogin input {
width:165px;
}
/* Fixing old chamilo forms */

@ -57,8 +57,14 @@ class FormValidator extends HTML_QuickForm {
// Modify the default templates
$renderer = & $this->defaultRenderer();
//default form class
if (!isset($attributes['class'])) {
$attributes['class'] = 'form-horizontal';
}
$form_template = <<<EOT
<form class="form-horizontal" {attributes}>
<form {attributes}>
<fieldset>
{content}
<div class="clear"></div>

@ -739,12 +739,10 @@ class IndexManager {
* @version 1.1
*/
function display_login_form() {
$form = new FormValidator('formLogin', 'POST', null, null, array('class'=>'form-stacked'));
$form = new FormValidator('formLogin', 'POST', null, null, array('class'=>'form-vertical'));
$form->addElement('text', 'login', get_lang('UserName'), array('size' => 17));
$form->addElement('password', 'password', get_lang('Pass'), array('size' => 17));
$form->addElement('style_submit_button','submitAuth', get_lang('LoginEnter'), array('class' => 'a_button gray'));
$renderer =& $form->defaultRenderer();
$renderer->setElementTemplate('<div class="row"><div class="label">{label}</div><div class="formw">{element}</div></div>');
$form->addElement('style_submit_button','submitAuth', get_lang('LoginEnter'), array('class' => 'a_button gray'));
$html = $form->return_form();
if (api_get_setting('openid_authentication') == 'true') {
include_once 'main/auth/openid/login.php';
@ -753,8 +751,6 @@ class IndexManager {
return $html;
}
function return_search_block() {
$html = '';

Loading…
Cancel
Save