summaryrefslogtreecommitdiffstats
path: root/application/forms/Login.php
diff options
context:
space:
mode:
Diffstat (limited to 'application/forms/Login.php')
-rw-r--r--application/forms/Login.php38
1 files changed, 38 insertions, 0 deletions
diff --git a/application/forms/Login.php b/application/forms/Login.php
new file mode 100644
index 0000000..170b100
--- /dev/null
+++ b/application/forms/Login.php
@@ -0,0 +1,38 @@
+<?php
+
+class Application_Form_Login extends Zend_Form
+{
+
+ public function init()
+ {
+ $this->setName("Login");
+ $this->setMethod('post');
+
+ $this->addElement('text', 'username', array(
+ 'filters' => array('StringTrim', 'StringToLower'),
+ 'validators' => array(
+ array('StringLength', false, array(0, 50)),
+ ),
+ 'required' => true,
+ 'label' => 'Username:',
+ ));
+
+ $this->addElement('password', 'password', array(
+ 'filters' => array('StringTrim'),
+ 'validators' => array(
+ array('StringLength', false, array(0, 50)),
+ ),
+ 'required' => true,
+ 'label' => 'Password:',
+ ));
+
+ $this->addElement('submit', 'login', array(
+ 'required' => false,
+ 'ignore' => true,
+ 'label' => 'Login',
+ ));
+ }
+
+
+}
+