当前位置: 首页>>代码示例>>PHP>>正文


PHP Zend_Form_Element_Submit::setIgnore方法代码示例

本文整理汇总了PHP中Zend_Form_Element_Submit::setIgnore方法的典型用法代码示例。如果您正苦于以下问题:PHP Zend_Form_Element_Submit::setIgnore方法的具体用法?PHP Zend_Form_Element_Submit::setIgnore怎么用?PHP Zend_Form_Element_Submit::setIgnore使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Zend_Form_Element_Submit的用法示例。


在下文中一共展示了Zend_Form_Element_Submit::setIgnore方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: init

 /**
  * Creates the form to edit a user profile.
  * @see Zend_Form::init()
  */
 public function init()
 {
     $em = Zend_Registry::getInstance()->entitymanager;
     $defaultNamespace = new Zend_Session_Namespace('Default');
     $this->setMethod('post');
     $usernameElement = new Zend_Form_Element_Text('username');
     $usernameElement->setLabel("Benutzername");
     $usernameElement->addValidator(new Unplagged_Validate_NoRecordExists('Application_Model_Personnel', 'username'));
     $usernameElement->setIgnore(true);
     $emailElement = new Zend_Form_Element_Text('email');
     $emailElement->setLabel("E-Mail");
     $emailElement->addValidator(new Unplagged_Validate_NoRecordExists('Application_Model_Personnel', 'email'));
     $emailElement->setIgnore(true);
     $firstnameElement = new Zend_Form_Element_Text('firstname');
     $firstnameElement->setLabel("Vorname");
     $firstnameElement->addValidator('stringLength', false, array(2, 64));
     $firstnameElement->setAttrib('maxLength', 64);
     $firstnameElement->setRequired(true);
     $lastnameElement = new Zend_Form_Element_Text('lastname');
     $lastnameElement->setLabel("Nachname");
     $lastnameElement->addValidator('stringLength', false, array(2, 64));
     $lastnameElement->setAttrib('maxLength', 64);
     $lastnameElement->setRequired(true);
     $submitElement = new Zend_Form_Element_Submit('submit');
     $submitElement->setLabel('Speichern');
     $submitElement->setIgnore(true);
     $submitElement->setAttrib('class', 'submit');
     $submitElement->removeDecorator('DtDdWrapper');
     $this->addElements(array($emailElement, $usernameElement, $firstnameElement, $lastnameElement));
     $this->addDisplayGroup(array('email', 'username', 'firstname', 'lastname'), 'personalGoup', array('legend' => 'Persönliche Informationen'));
     $this->addElements(array($submitElement));
 }
开发者ID:rusli-nasir,项目名称:iHealth,代码行数:36,代码来源:Profile.php

示例2: init

 /**
  * Creates the form to log in.
  * @see Zend_Form::init()
  */
 public function init()
 {
     $this->setMethod('post');
     $this->setAction("/auth/login/");
     $usernameElement = new Zend_Form_Element_Text('username');
     $usernameElement->setLabel("Benutzername");
     $usernameElement->addValidator('regex', false, array('/^[a-z0-9]/i'));
     $usernameElement->addValidator('stringLength', false, array(2, 64));
     $usernameElement->setAttrib('maxLength', 64);
     $usernameElement->setRequired(true);
     $passwordElement = new Zend_Form_Element_Password('password');
     $passwordElement->setLabel("Passwort");
     $passwordElement->addValidator('regex', false, array('/^[a-z0-9]/i'));
     $passwordElement->addValidator('stringLength', false, array(8, 32));
     $passwordElement->setAttrib('maxLength', 32);
     $passwordElement->setRequired(true);
     $submitElement = new Zend_Form_Element_Submit('submit');
     $submitElement->setLabel('Anmelden');
     $submitElement->setIgnore(true);
     $submitElement->setAttrib('class', 'submit');
     $submitElement->removeDecorator('DtDdWrapper');
     $this->addElements(array($usernameElement, $passwordElement));
     $this->addDisplayGroup(array('username', 'password'), 'credentialGroup', array('legend' => 'Zugangsdaten'));
     $this->addElements(array($submitElement));
 }
开发者ID:rusli-nasir,项目名称:iHealth,代码行数:29,代码来源:Login.php

示例3: init

 public function init()
 {
     $this->setName('send-tweet');
     $e = new Zend_Form_Element_Text('latitude');
     $e->setLabel('Latitude');
     $e->addFilter('StringTrim');
     $e->setAttrib('onblur', 'setMarkerFromForm()');
     $e->addValidator(new Zend_Validate_Regex('/[-+0-9.]/'));
     $e->setTranslator(new Zend_Translate_Adapter_Array(array('regexNotMatch' => 'Latitude is not valid'), 'en'));
     $this->addElement($e);
     $e = new Zend_Form_Element_Text('longitude');
     $e->setLabel('Longitude');
     $e->addFilter('StringTrim');
     $e->setAttrib('onblur', 'setMarkerFromForm()');
     $e->addValidator(new Zend_Validate_Regex('/[-+0-9.]/'));
     $e->setTranslator(new Zend_Translate_Adapter_Array(array('regexNotMatch' => 'Longitude is not valid'), 'en'));
     $this->addElement($e);
     $e = new Zend_Form_Element_Textarea('tweet');
     $e->setLabel('Tweet');
     $e->setRequired(true);
     $e->addFilter('StripTags');
     $e->addFilter('StringTrim');
     $e->addValidator(new Zend_Validate_StringLength(array('max' => 140)));
     $e->setTranslator(new Zend_Translate_Adapter_Array(array('isEmpty' => 'Please supply the message to be tweeted', 'stringLengthTooLong' => 'No more than 140 characters please!'), 'en'));
     $this->addElement($e);
     $e = new Zend_Form_Element_Submit('send');
     $e->setIgnore(true);
     $e->setLabel('Tweet!');
     $this->addElement($e);
 }
开发者ID:akrabat,项目名称:TweetGT,代码行数:30,代码来源:Tweet.php

示例4: init

 function init()
 {
     // Set the method for the display form to POST
     $this->setMethod('post');
     $this->addAttribs(array('id' => 'addGroup', 'class' => ''));
     $this->setEnctype(Zend_Form::ENCTYPE_MULTIPART);
     $control = new Zend_Form_Element_Hidden('control');
     $control->setValue('addGroup');
     $this->addElement($control);
     // begin inputs
     $name = new Zend_Form_Element_Text('name');
     $name->setAttribs(array('class' => 'text validate[required] rightAdd', 'placeholder' => Zend_Registry::get('translate')->_('admin_category_name')));
     $name->setRequired(true);
     $this->addElement($name);
     // begin inputs
     $color = new Zend_Form_Element_Text('color');
     $color->setAttribs(array('class' => 'text validate[required] rightAdd', 'placeholder' => Zend_Registry::get('translate')->_('admin_color_for_charts')));
     $color->setRequired(true);
     $this->addElement($color);
     // begin inputs
     $type = new Zend_Form_Element_Select('type');
     $options = array('' => Zend_Registry::get('translate')->_('admin_category_select_type'), '0' => Zend_Registry::get('translate')->_('admin_expenses'), '1' => Zend_Registry::get('translate')->_('admin_income'));
     $type->setMultiOptions($options);
     $type->addValidator(new Zend_Validate_InArray(array_keys($options)));
     $type->setAttribs(array('class' => 'select', 'id' => 'type'));
     $type->setRequired(true);
     $this->addElement($type);
     $submit = new Zend_Form_Element_Submit('submit');
     $submit->setValue(Zend_Registry::get('translate')->_('admin_add'));
     $submit->setAttribs(array('class' => 'submit'));
     $submit->setIgnore(true);
     $this->addElement($submit);
 }
开发者ID:valizr,项目名称:MMA,代码行数:33,代码来源:Groups.php

示例5: editUserPassword

 function editUserPassword()
 {
     $this->setMethod('post');
     $this->addAttribs(array('id' => 'formAccountEditPassword', 'class' => ''));
     $filters = array(new Zend_Filter_StringTrim(), new Zend_Filter_StripTags());
     $control = new Zend_Form_Element_Hidden('control');
     $control->setValue('editPassword');
     $this->addElement($control);
     $oldPassword = new Zend_Form_Element_Password('oldPassword');
     $oldPassword->setLabel('Old password');
     $oldPassword->addValidator(new Zend_Validate_StringLength(6, 32));
     $oldPassword->setAttribs(array('class' => 'text validate[required,minSize[6],maxSize[32]] rightAdd', 'minlenght' => '6', 'maxlenght' => '32', 'autocomplete' => 'off', 'oncontextmenu' => 'return false', 'data-prompt-position' => 'topLeft:0'));
     $oldPassword->setRequired(true);
     $this->addElement($oldPassword);
     $password = new Zend_Form_Element_Password('password');
     $password->setLabel(Zend_Registry::get('translate')->_('admin_administrators_new_password'));
     $password->addValidator(new Zend_Validate_StringLength(6, 32));
     $password->setAttribs(array('class' => 'text validate[required] rightAdd', 'maxlenght' => '32', 'autocomplete' => 'off', 'oncontextmenu' => 'return false', 'ondrop' => 'return false', 'onpaste' => 'return false'));
     $password->setRequired(true);
     $this->addElement($password);
     $retypePassword = new Zend_Form_Element_Password('retypePassword');
     $retypePassword->setLabel(Zend_Registry::get('translate')->_('admin_administrators_retype_new_password'));
     $retypePassword->addValidator(new Zend_Validate_Identical('password'));
     $retypePassword->addValidator(new Zend_Validate_StringLength(6, 32));
     $retypePassword->setAttribs(array('class' => 'text validate[required] rightAdd', 'maxlenght' => '32', 'autocomplete' => 'off', 'oncontextmenu' => 'return false', 'ondrop' => 'return false', 'onpaste' => 'return false'));
     $retypePassword->setRequired(true);
     $retypePassword->setIgnore(true);
     $this->addElement($retypePassword);
     $submit = new Zend_Form_Element_Submit('savePassword');
     $submit->setValue(Zend_Registry::get('translate')->_('apply_password'));
     $submit->setAttribs(array('class' => 'submit tsSubmitLogin fL'));
     $submit->setIgnore(true);
     $this->addElement($submit);
     $this->setElementFilters($filters);
 }
开发者ID:valizr,项目名称:MMA,代码行数:35,代码来源:EditPassword.php

示例6: init

 /**
  * Creates the form to create a new case.
  * @see Zend_Form::init()
  */
 public function init()
 {
     $em = Zend_Registry::getInstance()->entitymanager;
     $this->setMethod('post');
     $sexElement = new Zend_Form_Element_Select('sex');
     $sexElement->setLabel("Geschlecht");
     $sexElement->addMultiOption("", "Bitte wählen");
     $sexElement->addMultiOption("male", "männlich");
     $sexElement->addMultiOption("female", "weiblich");
     $sexElement->setRequired(true);
     $firstnameElement = new Zend_Form_Element_Text('firstname');
     $firstnameElement->setLabel("Vorname");
     $firstnameElement->addValidator('regex', false, array('/^[a-z0-9ßöäüâáàéèñ]/i'));
     $firstnameElement->addValidator('stringLength', false, array(2, 64));
     $firstnameElement->setRequired(true);
     $lastnameElement = new Zend_Form_Element_Text('lastname');
     $lastnameElement->setLabel("Nachname");
     $lastnameElement->addValidator('regex', false, array('/^[a-z0-9ßöäüâáàéèñ]/i'));
     $lastnameElement->addValidator('stringLength', false, array(2, 64));
     $lastnameElement->setRequired(true);
     $birthdayElement = new Zend_Form_Element_Text('birthday');
     $birthdayElement->setLabel("Geburtstag");
     $birthdayElement->addValidator(new Zend_Validate_Date());
     $sizeElement = new Zend_Form_Element_Text('size');
     $sizeElement->setLabel("Körpergröße in cm");
     $sizeElement->addValidator('regex', false, array('/^[a-z0-9ßöäüâáàéèñ]/i'));
     $sizeElement->addValidator('stringLength', false, array(2, 64));
     $weightElement = new Zend_Form_Element_Text('weight');
     $weightElement->setLabel("Gewicht in kg");
     $weightElement->addValidator('regex', false, array('/^[a-z0-9ßöäüâáàéèñ]/i'));
     $weightElement->addValidator('stringLength', false, array(2, 64));
     $bloodGroupElement = new Zend_Form_Element_Text('bloodGroup');
     $bloodGroupElement->setLabel("Blutgruppe");
     $bloodGroupElement->addValidator('regex', false, array('/^[a-z0-9ßöäüâáàéèñ]/i'));
     $bloodGroupElement->addValidator('stringLength', false, array(2, 64));
     $streetElement = new Zend_Form_Element_Text('street');
     $streetElement->setLabel("Straße");
     $streetElement->addValidator('regex', false, array('/^[a-z0-9ßöäüâáàéèñ]/i'));
     $streetElement->addValidator('stringLength', false, array(2, 64));
     $zipcodeElement = new Zend_Form_Element_Text('zipcode');
     $zipcodeElement->setLabel("Postleitzahl");
     $zipcodeElement->addValidator('regex', false, array('/^[a-z0-9ßöäüâáàéèñ]/i'));
     $zipcodeElement->addValidator('stringLength', false, array(2, 64));
     $cityElement = new Zend_Form_Element_Text('city');
     $cityElement->setLabel("Stadt");
     $cityElement->addValidator('regex', false, array('/^[a-z0-9ßöäüâáàéèñ]/i'));
     $cityElement->addValidator('stringLength', false, array(2, 64));
     $submitElement = new Zend_Form_Element_Submit('submit');
     $submitElement->setLabel('Speichern');
     $submitElement->setIgnore(true);
     $submitElement->setAttrib('class', 'submit');
     $submitElement->removeDecorator('DtDdWrapper');
     $this->addElements(array($firstnameElement, $lastnameElement, $sizeElement, $weightElement, $bloodGroupElement, $streetElement, $zipcodeElement, $cityElement, $sexElement, $birthdayElement));
     $this->addDisplayGroup(array('sex', 'firstname', 'lastname', 'birthday'), 'informationGroup', array('legend' => 'Allgemeine Informationen'));
     $this->addDisplayGroup(array('size', 'weight', 'bloodGroup'), 'vitalGroup', array('legend' => 'Vital Informationen'));
     $this->addDisplayGroup(array('street', 'zipcode', 'city'), 'addressGroup', array('legend' => 'Adresse'));
     $this->addElements(array($submitElement));
 }
开发者ID:rusli-nasir,项目名称:iHealth,代码行数:62,代码来源:Modify.php

示例7: init

 function init()
 {
     $this->setMethod('post');
     $this->addAttribs(array('id' => 'addUser', 'class' => ''));
     $this->setEnctype(Zend_Form::ENCTYPE_MULTIPART);
     $action = new Zend_Form_Element_Hidden('action');
     $action->setValue('add');
     $this->addElement($action);
     // BEGIN: Name
     $name = new Zend_Form_Element_Text('name');
     $name->setAttribs(array('class' => 'text large rightAdd', 'placeholder' => Zend_Registry::get('translate')->_('admin_full_name'), 'id' => 'name'));
     $name->setRequired(true);
     $this->addElement($name);
     // END: Name
     // BEGIN: Account Name
     $accountName = new Zend_Form_Element_Text('accountName');
     $accountName->setAttribs(array('class' => 'text large rightAdd', 'placeholder' => Zend_Registry::get('translate')->_('admin_account_name'), 'id' => 'accountName'));
     $accountName->setRequired(true);
     $this->addElement($accountName);
     // END: Account Name
     // BEGIN: Email
     $email = new Zend_Form_Element_Text('email');
     $email->setAttribs(array('class' => 'text large rightAdd', 'placeholder' => Zend_Registry::get('translate')->_('admin_email_address'), 'id' => 'email'));
     $validatorEmail = new Zend_Validate_Db_NoRecordExists('users', 'email');
     $email->addValidator($validatorEmail);
     $email->setRequired(true);
     $this->addElement($email);
     // END: Email
     //BEGIN:Level
     $idLevel = new Zend_Form_Element_Select('idRole');
     $options = array('' => Zend_Registry::get('translate')->_('admin_select_user_level'));
     $levels = new Default_Model_Role();
     $select = $levels->getMapper()->getDbTable()->select()->where('id != ?', 1)->where('NOT deleted')->order('id DESC');
     $result = $levels->fetchAll($select);
     if (NULL != $result) {
         foreach ($result as $value) {
             $options[$value->getId()] = $value->getName();
         }
     }
     $idLevel->addMultiOptions($options);
     $idLevel->addValidator(new Zend_Validate_InArray(array_keys($options)));
     $idLevel->setAttribs(array('class' => 'rightAdd', 'id' => 'idRole'));
     $idLevel->setRequired(false);
     $this->addElement($idLevel);
     //END:Level
     $add = new Zend_Form_Element_Submit('add');
     $add->setValue(Zend_Registry::get('translate')->_('admin_add_user'));
     $add->setAttribs(array('class' => 'submit', 'id' => ''));
     $add->setIgnore(true);
     $this->addElement($add);
 }
开发者ID:valizr,项目名称:MMA,代码行数:51,代码来源:Users.php

示例8: init

 public function init()
 {
     $country_list = Application_Model_Preference::GetCountryList();
     $isSass = Application_Model_Preference::GetPlanLevel() == 'disabled' ? false : true;
     $this->isSass = $isSass;
     $this->setDecorators(array(array('ViewScript', array('viewScript' => 'form/support-setting.phtml', "isSaas" => $isSass)), array('File', array('viewScript' => 'form/support-setting.phtml', 'placement' => false))));
     //Station name
     $this->addElement('text', 'stationName', array('class' => 'input_text', 'label' => 'Station Name', 'required' => true, 'filters' => array('StringTrim'), 'validator' => array('NotEmpty'), 'value' => Application_Model_Preference::GetStationName(), 'decorators' => array('ViewHelper')));
     // Phone number
     $this->addElement('text', 'Phone', array('class' => 'input_text', 'label' => 'Phone:', 'required' => false, 'filters' => array('StringTrim'), 'value' => Application_Model_Preference::GetPhone(), 'decorators' => array('ViewHelper')));
     //Email
     $this->addElement('text', 'Email', array('class' => 'input_text', 'label' => 'Email:', 'required' => false, 'filters' => array('StringTrim'), 'value' => Application_Model_Preference::GetEmail(), 'decorators' => array('ViewHelper')));
     // Station Web Site
     $this->addElement('text', 'StationWebSite', array('label' => 'Station Web Site:', 'required' => false, 'class' => 'input_text', 'value' => Application_Model_Preference::GetStationWebSite(), 'decorators' => array('ViewHelper')));
     // county list dropdown
     $this->addElement('select', 'Country', array('label' => 'Country:', 'required' => false, 'value' => Application_Model_Preference::GetStationCountry(), 'multiOptions' => $country_list, 'decorators' => array('ViewHelper')));
     // Station city
     $this->addElement('text', 'City', array('label' => 'City:', 'required' => false, 'class' => 'input_text', 'value' => Application_Model_Preference::GetStationCity(), 'decorators' => array('ViewHelper')));
     // Station Description
     $description = new Zend_Form_Element_Textarea('Description');
     $description->class = 'input_text_area';
     $description->setLabel('Station Description:')->setRequired(false)->setValue(Application_Model_Preference::GetStationDescription())->setDecorators(array('ViewHelper'))->setAttrib('ROWS', '2')->setAttrib('COLS', '58');
     $this->addElement($description);
     // Station Logo
     $upload = new Zend_Form_Element_File('Logo');
     $upload->setLabel('Station Logo:')->setRequired(false)->setDecorators(array('File'))->addValidator('Count', false, 1)->addValidator('Extension', false, 'jpg,jpeg,png,gif')->addFilter('ImageSize');
     $upload->setAttrib('accept', 'image/*');
     $this->addElement($upload);
     if (!$isSass) {
         //enable support feedback
         $this->addElement('checkbox', 'SupportFeedback', array('label' => 'Send support feedback', 'required' => false, 'value' => Application_Model_Preference::GetSupportFeedback(), 'decorators' => array('ViewHelper')));
         // checkbox for publicise
         $checkboxPublicise = new Zend_Form_Element_Checkbox("Publicise");
         $checkboxPublicise->setLabel('Promote my station on Sourcefabric.org')->setRequired(false)->setDecorators(array('ViewHelper'))->setValue(Application_Model_Preference::GetPublicise());
         if (Application_Model_Preference::GetSupportFeedback() == '0') {
             $checkboxPublicise->setAttrib("disabled", "disabled");
         }
         $this->addElement($checkboxPublicise);
         // text area for sending detail
         $this->addElement('textarea', 'SendInfo', array('class' => 'sending_textarea', 'required' => false, 'filters' => array('StringTrim'), 'readonly' => true, 'cols' => 61, 'rows' => 5, 'value' => Application_Model_Preference::GetSystemInfo(false, true), 'decorators' => array('ViewHelper')));
         // checkbox for privacy policy
         $checkboxPrivacy = new Zend_Form_Element_Checkbox("Privacy");
         $checkboxPrivacy->setLabel("By checking this box, I agree to Sourcefabric's <a id=\"link_to_privacy\" href=\"http://www.sourcefabric.org/en/about/policy/\" onclick=\"window.open(this.href); return false;\">privacy policy</a>.")->setDecorators(array('ViewHelper'));
         $this->addElement($checkboxPrivacy);
     }
     // submit button
     $submit = new Zend_Form_Element_Submit("submit");
     $submit->class = 'ui-button ui-state-default right-floated';
     $submit->setIgnore(true)->setLabel("Save")->setDecorators(array('ViewHelper'));
     $this->addElement($submit);
 }
开发者ID:nidzix,项目名称:Airtime,代码行数:51,代码来源:SupportSettings.php

示例9: init

 function init()
 {
     // Set the method for the display form to POST
     $this->setMethod('post');
     $this->setAction(WEBROOT . 'logs');
     $this->addAttribs(array('id' => 'searchLogs', 'class' => ''));
     $this->setEnctype(Zend_Form::ENCTYPE_MULTIPART);
     //BEGIN:Module
     $id = new Zend_Form_Element_Select('modul');
     $options = array('' => 'Selectati modulul');
     $module = new Default_Model_Logs();
     $select = $module->getMapper()->getDbTable()->select()->group('modul')->order('created DESC');
     $result = $module->fetchAll($select);
     if (NULL != $result) {
         foreach ($result as $value) {
             $options[$value->getModul()] = $value->getModul();
         }
     }
     $id->addMultiOptions($options);
     $this->addElement($id);
     //END:Module
     //BEGIN:ActionType
     $id = new Zend_Form_Element_Select('actionType');
     $options = array('' => 'Selectati tipul actiunii');
     $module = new Default_Model_Logs();
     $select = $module->getMapper()->getDbTable()->select()->group('actionType')->order('created DESC');
     $result = $module->fetchAll($select);
     if (NULL != $result) {
         foreach ($result as $value) {
             $options[$value->getActionType()] = $value->getActionType();
         }
     }
     $id->addMultiOptions($options);
     $this->addElement($id);
     //END:ActionType
     // BEGIN: data
     $data_inceput = new Zend_Form_Element_Text('data_inceput');
     $data_inceput->setAttribs(array('class' => 'data_inceput', 'placeholder' => 'Data inceput'));
     $this->addElement($data_inceput);
     $data_sfarsit = new Zend_Form_Element_Text('data_sfarsit');
     $data_sfarsit->setAttribs(array('class' => 'data_sfarsit', 'placeholder' => 'Data sfarsit'));
     $this->addElement($data_sfarsit);
     // END: data
     $submit = new Zend_Form_Element_Submit('submit');
     $submit->setValue('Cauta');
     $submit->setAttribs(array('class' => 'submit'));
     $submit->setIgnore(true);
     $this->addElement($submit);
 }
开发者ID:valizr,项目名称:MMA,代码行数:49,代码来源:SearchLogs.php

示例10: init

 function init()
 {
     $this->setMethod('post');
     $this->addAttribs(array('id' => 'intrebare_form', 'class' => ''));
     $nume = new Zend_Form_Element_Text('tabel');
     $nume->setLabel('Nume Tabel');
     $nume->setAttribs(array('class' => 'text_input validate[required]', 'placeholder' => trim(Zend_Registry::get('translate')->_('Nume Tabel')), 'data-prompt-position' => 'topRight:-187'));
     $nume->setRequired(true);
     $this->addElement($nume);
     $button = new Zend_Form_Element_Submit('button');
     $button->setValue(trim(Zend_Registry::get('translate')->_('Generate Model')));
     $button->setAttribs(array('class' => 'question_submit'));
     $button->setIgnore(true);
     $this->addElement($button);
 }
开发者ID:valizr,项目名称:MMA,代码行数:15,代码来源:Generator.php

示例11: init

 function init()
 {
     $this->setMethod('post');
     $this->addAttribs(array('id' => 'comments_form', 'class' => ''));
     $description = new Zend_Form_Element_Textarea('description');
     $description->setLabel('Comment text');
     $description->setAttribs(array('class' => 'mess_textarea validate[required]', 'placeholder' => trim(Zend_Registry::get('translate')->_('Comment text')), 'data-prompt-position' => 'topLeft:6'));
     $description->setRequired(true);
     $this->addElement($description);
     $button = new Zend_Form_Element_Submit('button');
     $button->setValue(trim(Zend_Registry::get('translate')->_('Send Comment')));
     $button->setAttribs(array('class' => 'comments_submit'));
     $button->setIgnore(true);
     $this->addElement($button);
 }
开发者ID:valizr,项目名称:MMA,代码行数:15,代码来源:Comments.php

示例12: init

 function init()
 {
     // Set the method for the display form to POST
     $this->setMethod('post');
     $this->addAttribs(array('id' => 'addExpense', 'class' => ''));
     $this->setEnctype(Zend_Form::ENCTYPE_MULTIPART);
     $control = new Zend_Form_Element_Hidden('control');
     $control->setValue('addExpense');
     $this->addElement($control);
     // begin inputs
     $name = new Zend_Form_Element_Text('name');
     $name->setAttribs(array('class' => 'text validate[required] rightAdd', 'placeholder' => Zend_Registry::get('translate')->_('admin_recurrent_expense_description')));
     $name->setRequired(true);
     $this->addElement($name);
     $price = new Zend_Form_Element_Text('price');
     $price->setAttribs(array('class' => 'text validate[required] rightAdd', 'placeholder' => Zend_Registry::get('translate')->_('admin_price')));
     $price->setRequired(true);
     $this->addElement($price);
     //BEGIN: Date
     $date = new Zend_Form_Element_Text('date');
     $date->setAttribs(array('class' => 'rightAdd dateSearch w_315', 'placeholder' => 'Date'));
     $date->setLabel('Select day');
     $this->addElement($date);
     // END: Date
     //BEGIN:Id Group
     $idGroup = new Zend_Form_Element_Select('idGroup');
     $options = array();
     $pm = new Default_Model_Groups();
     $select = $pm->getMapper()->getDbTable()->select()->where('NOT deleted')->order('name ASC');
     $result = $pm->fetchAll($select);
     if (NULL != $result) {
         foreach ($result as $value) {
             $options[$value->getId()] = $value->getName();
         }
     }
     $idGroup->addMultiOptions($options);
     $idGroup->addValidator(new Zend_Validate_InArray(array_keys($options)));
     $idGroup->setAttribs(array('class' => 'select'));
     $idGroup->setRequired(false);
     $this->addElement($idGroup);
     //END:Id Group
     $submit = new Zend_Form_Element_Submit('submit');
     $submit->setValue(Zend_Registry::get('translate')->_('admin_add_recurrent_expense'));
     $submit->setAttribs(array('class' => 'submit'));
     $submit->setIgnore(true);
     $this->addElement($submit);
 }
开发者ID:valizr,项目名称:MMA,代码行数:47,代码来源:RecurrentExpenses.php

示例13: init

 function init()
 {
     $this->setMethod('post');
     $this->addAttribs(array('id' => 'filterForm', 'class' => ''));
     $this->setAction(WEBROOT . 'recurrent-expenses');
     // BEGIN: nume text
     $nameSearch = new Zend_Form_Element_Text('nameSearch');
     $nameSearch->setAttribs(array('class' => 'text large', 'placeholder' => Zend_Registry::get('translate')->_('admin_name')));
     $nameSearch->setRequired(false);
     $this->addElement($nameSearch);
     // END: nume text
     // BEGIN: prenume text
     $idGroupSearch = new Zend_Form_Element_Select('idGroupSearch');
     $options = array('' => Zend_Registry::get('translate')->_('admin_select_expense'));
     $groups = new Default_Model_Groups();
     $select = $groups->getMapper()->getDbTable()->select()->where('type=?', 0)->where('NOT deleted')->order('name ASC');
     $result = $groups->fetchAll($select);
     if (NULL != $result) {
         foreach ($result as $value) {
             $options[$value->getId()] = $value->getName();
         }
     }
     $idGroupSearch->addMultiOptions($options);
     $idGroupSearch->addValidator(new Zend_Validate_InArray(array_keys($options)));
     $idGroupSearch->setAttribs(array('class' => 'select uniformSelect filter_selector'));
     $idGroupSearch->setRequired(false);
     $this->addElement($idGroupSearch);
     // END: prenume text
     // BEGIN: fromDate text
     $fromDate = new Zend_Form_Element_Text('fromDate');
     $fromDate->setAttribs(array('class' => 'text large', 'placeholder' => Zend_Registry::get('translate')->_('admin_from_date')));
     $fromDate->setRequired(false);
     $this->addElement($fromDate);
     // END: fromDate text
     // BEGIN: toDate text
     $toDate = new Zend_Form_Element_Text('toDate');
     $toDate->setAttribs(array('class' => 'text large', 'placeholder' => Zend_Registry::get('translate')->_('admin_to_date')));
     $toDate->setRequired(false);
     $this->addElement($toDate);
     // END: toDate text
     $search = new Zend_Form_Element_Submit('searchProduct');
     $search->setValue(Zend_Registry::get('translate')->_('admin_filter'));
     $search->setAttribs(array('class' => 'submit'));
     $search->setIgnore(true);
     $this->addElement($search);
 }
开发者ID:valizr,项目名称:MMA,代码行数:46,代码来源:RecurrentExpenseSearch.php

示例14: init

 function init()
 {
     $this->setMethod('post');
     $this->addAttribs(array('id' => 'file-manager', 'class' => ''));
     $action = new Zend_Form_Element_Hidden('action');
     $action->setValue('add');
     $this->addElement($action);
     $description = new Zend_Form_Element_Textarea('description');
     $description->setLabel('Description');
     $description->setAttribs(array('class' => 'mess_textarea validate[required]', 'placeholder' => 'Description', 'style' => 'width:272px'));
     $this->addElement($description);
     $button = new Zend_Form_Element_Submit('rightSubmit');
     $button->setValue('UPLOAD FILE');
     $button->setAttribs(array('class' => 'comments_submit'));
     $button->setIgnore(true);
     $this->addElement($button);
 }
开发者ID:valizr,项目名称:MMA,代码行数:17,代码来源:FileManager.php

示例15: init

 function init()
 {
     $this->setMethod('post');
     $this->addAttribs(array('id' => 'filterForm', 'class' => ''));
     $this->setAction(WEBROOT . 'groups');
     $this->setEnctype(Zend_Form::ENCTYPE_MULTIPART);
     // BEGIN: nume text
     $nameSearch = new Zend_Form_Element_Text('nameSearch');
     $nameSearch->setAttribs(array('class' => 'text large', 'placeholder' => 'Name'));
     $nameSearch->setRequired(false);
     $this->addElement($nameSearch);
     // END: nume text
     $search = new Zend_Form_Element_Submit('searchGroup');
     $search->setValue('Search');
     $search->setAttribs(array('class' => 'submit'));
     $search->setIgnore(true);
     $this->addElement($search);
 }
开发者ID:valizr,项目名称:MMA,代码行数:18,代码来源:GroupSearch.php


注:本文中的Zend_Form_Element_Submit::setIgnore方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。