<?php
-/* This file is part of Syj, Copyright (c) 2010 Arnaud Renevier,
+/* This file is part of Syj, Copyright (c) 2010-2011 Arnaud Renevier,
and is published under the AGPL license. */
class Syj_Form_Login extends Syj_Form_TableAbstract
$user = array('Text', 'login_user', array( 'label' => __("user"), 'required' => true));
$pass = array('Password', 'login_password', array( 'label' => __("password")));
-
$this->setMainElements(array($user, $pass))
+ ->addElement('Checkbox', 'login_rememberme', array( 'label' => __("remember me"), 'checked' => true))
->addElement('Hidden', 'login_geom_id', array( 'decorators' => array('ViewHelper')));
- $currentUri = Zend_Controller_Front::getInstance()->getRequest()->getRequestUri();
- if (strpos($currentUri, '?') !== false) {
- $currentUri = strstr($currentUri, '?', true);
- }
+ $currentUri = $this->getView()->UriPath(true);
$href = $this->getView()->addParamToUrl('newpwd', 'redirect', $currentUri, true);
$anchor = $this->getView()->Anchor($href,