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


PHP Zend_Form_Element_Hidden::setAttrib方法代码示例

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


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

示例1: __construct

 public function __construct($options = null)
 {
     Zend_Dojo::enableForm($this);
     parent::__construct($options);
     $category_id = new Zend_Form_Element_Select('category_id');
     $category_id->addMultiOption('', 'Select...');
     $category_id->setAttrib('class', 'txt_put')->setLabel('Category  Name');
     $category_id->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $productname = new Zend_Form_Element_Text('productname');
     $productname->addValidator(new Zend_Validate_Db_NoRecordExists('ourbank_productdetails', 'productname'));
     $productname->setAttrib('class', 'txt_put')->setLabel('Product Name');
     $productname->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $product_id = new Zend_Form_Element_Hidden('product_id');
     $product_id->setAttrib('class', 'txt_put');
     $productshortname = new Zend_Form_Element_Text('productshortname');
     $productshortname->setAttrib('class', 'txt_put')->setLabel('Product Short Name');
     $productshortname->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $product_description = new Zend_Form_Element_Textarea('product_description', array('rows' => 3, 'cols' => 20));
     $product_description->setAttrib('class', '')->setLabel('Productdescription');
     $product_description->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $submit = new Zend_Form_Element_Submit('Submit');
     $submit->setAttrib('id', 'save')->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('colspan' => '8 ')), array(array('data' => 'HtmlTag'), array('tag' => 'td ', 'colspan' => '8')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $this->addElements(array($category_id, $productname, $productshortname, $product_description, $product_id, $submit));
     $this->setDecorators(array('FormElements', array(array('data' => 'HtmlTag'), array('tag' => 'table', 'id' => 'hor-minimalist-b')), 'Form'));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:25,代码来源:Product.php

示例2: __construct

 public function __construct($options = null)
 {
     parent::__construct();
     $this->setMethod('post');
     $this->setEnctype('multipart/form-data');
     //$this->setAction('');
     $this->setName('custom_layout_advanced_form');
     $this->addElementPrefixPath('Oibs_Form_Decorator', 'Oibs/Form/Decorator/', 'decorator');
     $clearall = new Oibs_Form_Element_Note('clearall');
     $clearall->setValue('<div style="clear:both;"></div>');
     $csstextarea = new Zend_Form_Element_Textarea('csscontent');
     $csstextarea->setLabel('Editable custom layout css for advanced users')->setAttrib('id', 'css_textarea')->setAttrib('style', 'width: 575px; height: 660px; margin-left: -5px; margin-right: 10px; margin-bottom: 10px;')->setValue($options['cssContent'])->addDecorator('Label', array('tag' => 'div', 'style' => '/*font-weight:bold;*/ float:left; margin-top:6px'))->addValidators(array(array('StringLength', false)));
     $savecssbutton = new Zend_Form_Element_Submit('save_css_button');
     $savecssbutton->setLabel('Save')->setAttrib('style', 'width:60px; float:right;')->removeDecorator('DefaultDecorator')->removeDecorator('DtDdWrapper');
     $cancelcssbutton = new Zend_Form_Element_Button('cancel_css_button');
     $cancelcssbutton->setLabel('Cancel')->setAttrib('style', 'width:60px; float:right; margin-right:10px')->removeDecorator('DefaultDecorator')->removeDecorator('DtDdWrapper');
     $defaultcssbutton = new Zend_Form_Element_Button('default_css_button');
     $defaultcssbutton->setLabel('Default')->setAttrib('style', 'width:80px; float:left; margin-left: 10px; margin-top:-17px;')->removeDecorator('DefaultDecorator')->removeDecorator('DtDdWrapper');
     $restorecssbutton = new Zend_Form_Element_Button('restore_css_button');
     $restorecssbutton->setLabel('Restore')->setAttrib('style', 'width:80px; float:left; margin-left: -5px; margin-top:-17px;')->removeDecorator('DefaultDecorator')->removeDecorator('DtDdWrapper');
     $defaultcsshidden = new Zend_Form_Element_Hidden('default_css');
     $defaultcsshidden->setAttrib('id', 'default_css')->setValue($options['default_css']);
     $originalcsshidden = new Zend_Form_Element_Hidden('original_css');
     $originalcsshidden->setAttrib('id', 'original_css')->setValue($options['cssContent']);
     $advancedhelp = new Oibs_Form_Element_Note('help_link_advanced');
     $advancedhelp->setValue('<a href="#" onClick="return false;">Help</a>');
     $this->addElements(array($csstextarea, $savecssbutton, $cancelcssbutton, $advancedhelp, $restorecssbutton, $defaultcssbutton, $defaultcsshidden, $originalcsshidden));
     // Add decorators
     $this->setDecorators(array('FormElements', 'Form'));
 }
开发者ID:jannev,项目名称:site,代码行数:30,代码来源:AccountCustomLayoutAdvancedForm.php

示例3: __construct

 public function __construct($recurringBeginDate, $recurringClosedDate, $recurringMinAmount, $recurringMaxAmount, $app)
 {
     parent::__construct($recurringBeginDate, $recurringClosedDate, $recurringMinAmount, $recurringMaxAmount, $app);
     $startdate = new ZendX_JQuery_Form_Element_DatePicker('startdate');
     $startdate->setAttrib('id', 'startdate');
     $startdate->setAttrib('size', '8');
     $startdate->setAttrib('class', '');
     $startdate->setRequired(true)->addValidators(array(array('Date', true), array('Between', false, array($recurringBeginDate, $recurringClosedDate, 'messages' => array('notBetween' => 'date should be between ' . $recurringBeginDate . ' to (Closed date) ' . $recurringClosedDate)))));
     $recurringamount = new Zend_Form_Element_Text('recurringamount');
     $recurringamount->setRequired(true)->addValidators(array(array('Digits'), array('GreaterThan', false, array($recurringMinAmount)), array('LessThan', false, array($recurringMaxAmount)), array('NotEmpty')));
     $recurringamount->setAttrib('size', '8');
     $recurringperiod = new Zend_Form_Element_Text('recurringperiod');
     $recurringperiod->setAttrib('id', 'recurringperiod');
     $recurringperiod->setAttrib('class', 'NormalBtn');
     $memberfirstname = new Zend_Form_Element_MultiCheckbox('memberfirstname');
     $memberfirstname->setAttrib('class', 'textfield');
     $freequencyofdeposit = new Zend_Form_Element_Select('frequencyofdeposit');
     $freequencyofdeposit->addMultiOption('', 'Select...');
     $freequencyofdeposit->setAttrib('class', 'NormalBtn');
     $freequencyofdeposit->setAttrib('id', 'freequencyofdeposit');
     $perioddescription = new Zend_Form_Element_Select('perioddescription');
     $perioddescription->addMultiOption('', 'Select..');
     $perioddescription->setAttrib('class', 'NormalBtn');
     $perioddescription->setAttrib('id', 'perioddescription');
     $perioddescription->setRequired(true);
     $perioddescription->setAttrib('onchange', 'getInterests(this.value,"' . $app . '")');
     $periodinterest = new Zend_Form_Element_Select('periodinterest');
     $periodinterest->addMultiOption('', 'Select...');
     $periodinterest->setAttrib('class', 'NormalBtn');
     $periodinterest->setAttrib('id', 'periodinterest');
     $periodinterest->setAttrib('size', '5');
     $accountId = new Zend_Form_Element_Hidden('accountId');
     $productIdss = new Zend_Form_Element_Hidden('productId');
     $recurringindex = new Zend_Form_Element_Text('recurringinterest');
     $recurringindex->setAttrib('id', 'recurringinterest');
     $recurringindex->setAttrib('size', '8');
     $recurringindex->setAttrib('class', 'NormalBtn');
     $recurringindex->setAttrib('readonly', 'true');
     $recurringindex->setAttrib('class', 'NormalBtn');
     $recurringindex->setAttrib('readonly', 'true');
     $memberTypeId = new Zend_Form_Element_Hidden('memberTypeId');
     $memberId = new Zend_Form_Element_Hidden('member_id');
     $productId = new Zend_Form_Element_Hidden('product_id');
     $offerproductId = new Zend_Form_Element_Hidden('offerproduct_id');
     $groupId = new Zend_Form_Element_Hidden('groupId');
     $this->addElements(array($memberfirstname, $recurringindex, $freequencyofdeposit, $recurringperiod, $recurringamount, $startdate, $perioddescription, $periodinterest, $memberId, $productId, $offerproductId, $groupId, $memberTypeId, $accountId, $productIdss));
     $period_id = new Zend_Form_Element_Hidden('period_id');
     $period_id->setAttrib('id', 'period_id');
     $startdate1 = new Zend_Form_Element_Hidden('startdate1');
     $recurringamount1 = new Zend_Form_Element_Hidden('recurringamount1');
     $perioddescription1 = new Zend_Form_Element_Hidden('perioddescription1');
     $interest1 = new Zend_Form_Element_Hidden('interest1');
     $Confirm = new Zend_Form_Element_Submit('Confirm');
     $Confirm->setLabel('Confirm');
     $Confirm->setAttrib('class', 'recurring');
     $submit = new Zend_Form_Element_Submit('Submit');
     $submit->setLabel('submit');
     $submit->setAttrib('class', 'recurring');
     $this->addElements(array($submit, $period_id, $Confirm, $startdate1, $recurringamount1, $perioddescription1, $interest1));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:60,代码来源:RecurringAccount.php

示例4: init

 public function init()
 {
     $this->setMethod('post');
     $this->setAction('/main/new');
     $this->setAttrib('id', 'newRoute');
     $note = new Zend_Form_Element_Note('title', array('value' => '<h2 id="titleProductDetails">Create a New Route</h2>'));
     $intermed = new Zend_Form_Element_Hidden('intermed');
     $intermed->setAttrib('readonly', 'readonly');
     $intermed->addFilter('StripTags');
     $intermed->addFilter('HtmlEntities');
     $intermed->addFilter('StringTrim');
     $start = new Zend_Form_Element_Text('startForm');
     $start->setLabel('Starting Point*');
     $start->setAttrib('autocomplete', 'off');
     $start->addFilter('StripTags');
     $start->addFilter('HtmlEntities');
     $start->setAttrib('class', 'form-control');
     $start->addFilter('StringTrim');
     $start->setRequired(true)->addErrorMessage('Start Location Required');
     //        $start->addValidator('Regex', true, array('/^[a-zA-Z0-9.,:-\s]*$/'))->addErrorMessage('Invalid characters used');
     //        $start->addValidator('StringLength', true, array(0, 255))->addErrorMessage('Required Field');
     $end = new Zend_Form_Element_Text('endForm');
     $end->setLabel('Destination*');
     $end->setAttrib('autocomplete', 'off');
     $end->addFilter('StripTags');
     $end->setAttrib('class', 'form-control');
     $end->addFilter('HtmlEntities');
     $end->addFilter('StringTrim');
     $end->setRequired(true)->addErrorMessage('Destination Required');
     //        $end->addValidator('StringLength', true, array(0, 255))->addErrorMessage('Required Field');
     $routeDate = new Zend_Form_Element_Text('routeDate');
     $routeDate->setAttrib('autocomplete', 'off');
     $routeDate->setAttrib('readonly', 'readonly');
     $routeDate->setAttrib('maxlength', '10');
     $routeDate->setAttrib('class', 'form-control');
     $routeDate->setLabel('Date of Journey' . '*');
     $routeDate->addFilter('StripTags');
     $routeDate->addFilter('HtmlEntities');
     $routeDate->addFilter('StringTrim');
     $routeDate->setRequired(true)->addErrorMessage('Date Required');
     $routeDate->addValidator('Regex', true, array('/^[0-9.\\s]*$/'))->addErrorMessage('Invalid characters used');
     $routeDate->addValidator('StringLength', true, array(10, 10))->addErrorMessage('Required Field');
     $passangers = new Zend_Form_Element_Select('passangers');
     $passangers->setLabel('No of Passangers*');
     $passangers->setAttrib('autocomplete', 'off');
     $passangers->setAttrib('class', 'form-control');
     $passangers->addFilter('StripTags');
     $passangers->addFilter('HtmlEntities');
     $passangers->addFilter('StringTrim');
     $passangers->setRequired(true)->addErrorMessage('Password Required');
     $passangers->setMultiOptions(array('1' => '1 Passanger', '2' => '2 Passangers', '3' => '3 Passangers', '4' => '4 Passangers', '5' => '5 Passangers', '6' => '6 Passangers'));
     $submit = new Zend_Form_Element_Submit('newRoute');
     $submit->setLabel('New Route');
     $submit->setAttrib('class', 'btn btn-info');
     $submit->setAttrib('style', 'margin-top:20px');
     $this->addElements(array($note, $intermed, $start, $end, $passangers, $routeDate, $submit));
     $this->setElementDecorators(array('ViewHelper', 'Label', 'Errors'));
     $submit->setDecorators(array('ViewHelper'));
     $this->setDecorators(array('FormElements', 'Form', array('HtmlTag', array('tag' => 'div', 'id' => 'newRouteFormContainer'))));
 }
开发者ID:bogdanmatra,项目名称:ibm-hackathon,代码行数:60,代码来源:Route.php

示例5: __construct

 public function __construct($currencysymbol)
 {
     Zend_Dojo::enableForm($this);
     parent::__construct($options);
     $feename = new Zend_Form_Element_Text('feename');
     $feename->addValidator(new Zend_Validate_Db_NoRecordExists('ourbank_feedetails', 'feename'));
     $feename->setAttrib('class', 'txt_put')->setLabel('Fee Name');
     $feename->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td', "'..'")), array('Label', array('tag' => 'td')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $feedescription = new Zend_Form_Element_Textarea('feedescription', array('rows' => 3, 'cols' => 20));
     $feedescription->setAttrib('class', '')->setLabel('Description');
     $feedescription->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $feeappliesto_id = new Zend_Form_Element_Select('feeappliesto_id');
     $feeappliesto_id->addMultiOption('', 'Select...');
     $feeappliesto_id->setAttrib('class', 'txt_put')->setLabel('Member Type');
     $feeappliesto_id->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $feefrequency_id = new Zend_Form_Element_Select('feefrequency_id');
     $feefrequency_id->addMultiOption('', 'Select...');
     $feefrequency_id->setAttrib('class', 'txt_put')->setLabel('Fee for');
     $feefrequency_id->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $feevalue = new Zend_Form_Element_Text('feevalue');
     $feevalue->setAttrib('class', 'txt_put')->setLabel('Fee Amount');
     $feevalue->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $fee_id = new Zend_Form_Element_Hidden('fee_id');
     $fee_id->setAttrib('class', 'txt_put');
     $submit = new Zend_Form_Element_Submit('Submit');
     $submit->setAttrib('id', 'Submit')->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('colspan' => '8 ')), array(array('data' => 'HtmlTag'), array('tag' => 'td ', 'colspan' => '8')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $this->addElements(array($fee_id, $feename, $feevalue, $feedescription, $feeappliesto_id, $feefrequency_id, $product_id, $submit));
     $this->setDecorators(array('FormElements', array(array('data' => 'HtmlTag'), array('tag' => 'table', 'id' => 'hor-minimalist-b')), 'Form'));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:29,代码来源:Fee.php

示例6: init

 public function init($ppty_id)
 {
     global $mySession;
     $db = new Db();
     $airport1_value = "";
     $airport2_value = "";
     $distance2_value = "";
     $distance1_value = "";
     $latitude_value = "41.659";
     $longitude_value = "-4.714";
     $address_value = "";
     if ($ppty_id != "") {
         $locationValue = $db->runQuery("select * from " . PROPERTY . " where id = '" . $ppty_id . "' ");
         if ($locationValue != "" && count($locationValue) > 0 && $locationValue[0]['cletitude'] != "") {
             $latitude_value = $locationValue[0]['cletitude'];
             $longitude_value = $locationValue[0]['clongitude'];
             $address_value = $locationValue[0]['address'];
         }
     }
     $latitude = new Zend_Form_Element_Hidden('latitude');
     $latitude->setAttrib("class", "textInput")->setAttrib("readonly", "readonly")->setValue($latitude_value);
     $longitude = new Zend_Form_Element_Hidden('longitude');
     $longitude->setAttrib("class", "textInput")->setAttrib("readonly", "readonly")->setValue($longitude_value);
     $address = new Zend_Form_Element_Text('address');
     $address->setRequired(true)->addValidator('NotEmpty', true, array('messages' => 'Enter Your location is required.'))->addDecorator('Errors', array('class' => 'error'))->setAttrib("class", "mws-textinput required")->setValue($address_value);
     /*$airport1 = new Zend_Form_Element_Text('airport1');
     		$airport1->setRequired(true)
     		->addValidator('NotEmpty',true,array('messages' =>'Enter Name of airport.'))
     		->addDecorator('Errors', array('class'=>'error'))
     		->setAttrib("class","mws-textinput required")
     		->setValue($airport1_value);
     		
     		$distance1 = new Zend_Form_Element_Text('distance1');
     		$distance1->setRequired(true)
     		->addValidator('NotEmpty',true,array('messages' =>'Enter Airport distance from Property location'))
     		->addDecorator('Errors', array('class'=>'error'))
     		->setAttrib("class","mws-textinput required number")
     		->setValue($distance1_value);
     		
     		$airport2 = new Zend_Form_Element_Text('airport2');
     		$airport2->setRequired(true)
     		->addValidator('NotEmpty',true,array('messages' =>'Enter Name of airport.'))
     		->addDecorator('Errors', array('class'=>'error'))
     		->setAttrib("class","mws-textinput required")
     		->setValue($airport2_value);		
     		
     		$distance2 = new Zend_Form_Element_Text('distance2');
     		$distance2->setRequired(true)
     		->addValidator('NotEmpty',true,array('messages' =>'Enter Airport distance from Property location'))
     		->addDecorator('Errors', array('class'=>'error'))
     		->setAttrib("class","mws-textinput required number")
     		->setValue($distance2_value);*/
     $step = new Zend_Form_Element_Hidden("step");
     $step->setValue("4");
     $this->addElements(array($latitude, $longitude, $address, $step));
 }
开发者ID:ankuradhey,项目名称:dealtrip,代码行数:56,代码来源:Location.php

示例7: __construct

 public function __construct($options = null)
 {
     Zend_Dojo::enableForm($this);
     parent::__construct($options);
     $categoryname = new Zend_Form_Element_Text('categoryname');
     $categoryname->addValidator(new Zend_Validate_Db_NoRecordExists('ourbank_categorydetails', 'categoryname'));
     $categoryname->setAttrib('class', 'txt_put');
     $categoryname->setAttrib('id', 'hName')->setLabel('Category  Name');
     $categoryname->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $category_id = new Zend_Form_Element_Hidden('category_id');
     $category_id->setAttrib('class', 'txt_put');
     $category_id->setAttrib('id', 'hName')->setLabel('');
     $categorydescription = new Zend_Form_Element_Textarea('categorydescription', array('rows' => 3, 'cols' => 20));
     $categorydescription->setAttrib('id', 'glcodeDescription')->setLabel('Category  Description');
     $categorydescription->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $submit = new Zend_Form_Element_Submit('Submit');
     $submit->setAttrib('id', 'save')->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('colspan' => '8 ')), array(array('data' => 'HtmlTag'), array('tag' => 'td ', 'colspan' => '8')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $this->addElements(array($categoryname, $categorydescription, $category_id, $submit));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:19,代码来源:category.php

示例8: __construct

 public function __construct($haveToPay, $currentdate, $fromDate)
 {
     parent::__construct($haveToPay, $currentdate, $fromDate);
     $accountId = new Zend_Form_Element_Hidden('accountcode');
     $installment_status = new Zend_Form_Element_Hidden('installment_status');
     $memberId = new Zend_Form_Element_Hidden('membercode');
     $amount = new Zend_Form_Element_Text('amount');
     $amount->setRequired(true)->addValidators(array(array('Float'), array('GreaterThan', false, array($haveToPay - 0.0001, 'messages' => array('notGreaterThan' => 'Min=' . $haveToPay)))));
     $amount->setAttrib('class', 'txt_put');
     $amount->setAttrib('id', 'amount');
     $loanInterestAmountPaied = new Zend_Form_Element_Text('loanInterestAmountPaied');
     $loanInterestAmountPaied->setAttrib('class', 'textfieldreadonly');
     $loanInterestAmountPaied->setAttrib('readonly', 'true');
     $loanInterestAmountPaied->setAttrib('id', 'loanInterestAmountPaied');
     $loanRepaymentDate = new Zend_Form_Element_Text('loanRepaymentDate');
     $loanRepaymentDate->setAttrib('id', 'loanRepaymentDate');
     $loanRepaymentDate->setAttrib('size', '8');
     $loanRepaymentDate->setAttrib('class', 'txt_put');
     $loanRepaymentDate->setRequired(true)->addValidators(array(array('Date', true), array('Between', false, array($fromDate, $currentdate, 'messages' => array('notBetween' => 'date should be between ' . $fromDate . ' to (today date) ' . $currentdate)))));
     $transactionMode = new Zend_Form_Element_Select('transactionMode');
     $transactionMode->addMultiOption('', 'select');
     $transactionMode->setAttrib('class', 'selectbutton');
     $transactionMode->setAttrib('onchange', 'toggleField();');
     $transactionMode->setAttrib('id', 'paymenttype');
     $transactionMode->setRequired(true);
     $transactionModeDetails = new Zend_Form_Element_Textarea('paymenttype_details');
     $transactionModeDetails->setAttrib('class', 'txt_put');
     $transactionModeDetails->setAttrib('id', 'paymenttype_details');
     $transactionModeDetails->setAttrib('style', 'display:none');
     $transactionModeDetails->setAttrib('rows', '1');
     $transactionModeDetails->setAttrib('cols', '20');
     $transactionModeDetails->setRequired(true);
     $pay = new Zend_Form_Element_Submit('pay');
     $pay->setAttrib('class', 'officesubmit');
     $pay->setAttrib('onclick', 'getState(this.value)');
     $pay->setLabel('pay');
     $back = new Zend_Form_Element_Submit('back');
     $back->setAttrib('class', 'officesubmit');
     $confirm = new Zend_Form_Element_Submit('confirm');
     $confirm->setAttrib('class', 'officesubmit');
     $confirm->setAttrib('onclick', 'getState(this.value)');
     $confirm->setLabel('confirm');
     $categoryId = new Zend_Form_Element_Hidden('categoryId');
     $categoryId->setAttrib('class', 'txt_put');
     $amount1 = new Zend_Form_Element_Hidden('repayableamounts1');
     $loanRepaymentDate1 = new Zend_Form_Element_Hidden('loanRepaymentDate1');
     $transactionMode1 = new Zend_Form_Element_Hidden('transactionMode1');
     $paymenttype_details1 = new Zend_Form_Element_Hidden('paymenttype_details1');
     $fine1 = new Zend_Form_Element_Hidden('fine1');
     $this->addElements(array($accountId, $amount, $loanRepaymentDate, $pay, $memberId, $loanInterestAmountPaied, $transactionMode, $transactionModeDetails, $categoryId, $installment_status, $confirm, $amount1, $loanRepaymentDate1, $transactionMode1, $paymenttype_details1, $fine1, $back));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:51,代码来源:Loanrepayment.php

示例9: __construct

 public function __construct($options = null)
 {
     parent::__construct($options);
     $accountId = new Zend_Form_Element_Hidden('accountcode');
     $memberId = new Zend_Form_Element_Hidden('membercode');
     $Date = new ZendX_JQuery_Form_Element_DatePicker('date');
     $Date->setAttrib('class', 'txt_put');
     $Date->setJQueryParam('dateFormat', 'yy-mm-dd');
     $Date->setRequired(true)->addValidator(new Zend_Validate_Date('YYYY-MM-DD'), true, array('messages' => array(Zend_Validate_Date::FALSEFORMAT => 'Enter the valid date')));
     $Amount = new Zend_Form_Element_Text('amount');
     $Amount->setRequired(true)->addValidators(array(array('NotEmpty'), array('Float'), array('GreaterThan', false, array('0'))));
     $Amount->setAttrib('class', 'textfield');
     $Amount->setAttrib('id', 'amount');
     $Amount->setAttrib('size', '8');
     $paymenttype = new Zend_Form_Element_Select('paymenttype');
     $paymenttype->addMultiOption('', 'select');
     $paymenttype->setAttrib('class', 'NormalBtn');
     $paymenttype->setAttrib('id', 'paymenttype');
     $paymenttype->setAttrib('onchange', 'toggleField();');
     $paymenttype->setRequired(true);
     $description = new Zend_Form_Element_Textarea('transactiondescription');
     $description->setAttrib('class', 'textfield');
     $description->setAttrib('rows', '2');
     $description->setAttrib('cols', '20');
     $description->setRequired(true);
     $no = new Zend_Form_Element_Textarea('paymenttype_details');
     $no->setAttrib('class', 'textfield');
     $no->setAttrib('rows', '1');
     $no->setAttrib('cols', '20');
     $no->setAttrib('id', 'paymenttype_details');
     $no->setAttrib('style', 'display:none;');
     $no->setRequired(true);
     $categoryId = new Zend_Form_Element_Hidden('categoryId');
     $categoryId->setAttrib('class', 'textfield');
     $date1 = new Zend_Form_Element_Hidden('date1');
     $amount1 = new Zend_Form_Element_Hidden('amounts');
     $transactiondescription1 = new Zend_Form_Element_Hidden('transactiondescription1');
     $paymenttype_details1 = new Zend_Form_Element_Hidden('paymenttype_details1');
     $paymenttype1 = new Zend_Form_Element_Hidden('paymenttype1');
     $confirm = new Zend_Form_Element_Submit('confirm');
     $confirm->setAttrib('class', 'NormalBtn');
     $submit = new Zend_Form_Element_Submit('Submit');
     $submit->setAttrib('class', 'NormalBtn');
     $submit->setLabel('submit');
     $this->addElements(array($Date, $Amount, $paymenttype, $submit, $accountId, $memberId, $description, $no, $categoryId, $confirm, $date1, $amount1, $transactiondescription1, $paymenttype_details1, $paymenttype1));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:46,代码来源:SavingsTransaction.php

示例10: __construct

 public function __construct($path)
 {
     Zend_Dojo::enableForm($this);
     parent::__construct($options);
     $attendanceupdates_id = new Zend_Form_Element_Hidden('attendanceupdates_id');
     $attendance_id = new Zend_Form_Element_Hidden('attendance_id');
     $attendance_id->setAttrib('class', 'txt_put');
     $officetype_id = new Zend_Form_Element_Select('officetype_id');
     $officetype_id->setRequired(true);
     $officetype_id->addMultiOption('', 'select' . '...');
     $officetype_id->setAttrib('class', 'selectbutton');
     $officetype_id->setAttrib('onchange', 'getGroups(this.value,"' . $path . '")');
     $submit = new Zend_Form_Element_Submit('Submit');
     $submit->setAttrib('class', 'officesubmit');
     $submit->setLabel('Submit');
     $this->addElements(array($officetype_id, $submit, $attendanceupdates_id, $attendance_id));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:17,代码来源:Attendance.php

示例11: preGenerate

 public function preGenerate()
 {
     $f = new Zend_Form_Element_Hidden(array('disableTranslator' => true, 'name' => Translation_Traits_Model_DbTable::ORIGINAL_FIELD));
     $f->setAttrib('hidden', true);
     $this->addElement($f, Translation_Traits_Model_DbTable::ORIGINAL_FIELD);
     $this->addElement($this->_generateInfoField(Translation_Traits_Model_DbTable::ORIGINAL_FIELD, $this->getView()->translate('Translated from'), ''));
     $this->addElement($this->_generateInfoField(Translation_Traits_Model_DbTable::LANGUAGE_FIELD, $this->getView()->translate('Language'), (string) Translation_Traits_Common::getDefaultLanguage()->name));
     if ($this->getModel()->isOriginalForcedToDefaultLanguage()) {
         $f = new Zend_Form_Element_Hidden(array('disableTranslator' => true, 'name' => Translation_Traits_Model_DbTable::LANGUAGE_FIELD, 'value' => Translation_Traits_Common::getDefaultLanguage()->id));
         $f->setAttrib('hidden', true);
         $this->addElement($f, Translation_Traits_Model_DbTable::LANGUAGE_FIELD);
     } else {
         $langues = Centurion_Db::getSingleton('translation/language')->fetchAll();
         foreach ($langues as $lang) {
             $languages[$lang->id] = $lang->name;
         }
         $f = new Zend_Form_Element_Select(array('disableTranslator' => true, 'name' => Translation_Traits_Model_DbTable::LANGUAGE_FIELD, 'value' => Translation_Traits_Common::getDefaultLanguage()->id, 'multiOptions' => $languages, 'label' => $this->getView()->translate('Select a language: ')));
         $this->addElement($f, Translation_Traits_Model_DbTable::LANGUAGE_FIELD);
     }
 }
开发者ID:netconstructor,项目名称:Centurion,代码行数:20,代码来源:Model.php

示例12: __construct

 public function __construct($options = null)
 {
     parent::__construct($options);
     $date = new ZendX_JQuery_Form_Element_DatePicker('Date1');
     $date->setAttrib('class', '');
     $date->setJQueryParam('dateFormat', 'yy-mm-dd');
     $date->setRequired(true)->addValidator(new Zend_Validate_Date('YYYY-MM-DD'), true, array('messages' => array(Zend_Validate_Date::FALSEFORMAT => 'Enter the valid date')));
     $accountCode = new Zend_Form_Element_Hidden('accountcode');
     $memberId = new Zend_Form_Element_Hidden('membercode');
     $categoryId = new Zend_Form_Element_Hidden('categoryId');
     $loanAmount = new Zend_Form_Element_Hidden('loan_amount');
     $typeId = new Zend_Form_Element_Hidden('typeId');
     $creditlinebalance = new Zend_Form_Element_Text('creditlinebalance');
     $creditlinebalance->setAttrib('readonly', 'true');
     $transactionType = new Zend_Form_Element_Select('transaction_type');
     $transactionType->setAttrib('class', 'NormalBtn');
     $transactionType->setAttrib('id', 'transaction_type');
     $transactionType->addMultiOption('3', '-Loan Disbursement-');
     $Amount = new Zend_Form_Element_Text('Amount');
     $Amount->setRequired(true)->addValidators(array(array('NotEmpty'), array('Digits'), array('GreaterThan', false, array('0'))));
     $Amount->setAttrib('class', 'textfield');
     $Amount->setAttrib('id', 'Amount');
     $description = new Zend_Form_Element_Textarea('description');
     $description->setAttrib('rows', '2');
     $description->setAttrib('cols', '20');
     $description->setRequired(true);
     $fee = new Zend_Form_Element_Text('fee');
     $fee->setAttrib('class', 'textfield');
     $fee->setAttrib('readonly', 'true');
     $Save = new Zend_Form_Element_Submit('Save');
     $Save->setAttrib('class', 'officesubmit');
     $submit = new Zend_Form_Element_Submit('Submit');
     $submit->setAttrib('class', 'officesubmit');
     $transactionTypeId = new Zend_Form_Element_Hidden('transactionType_id');
     $transactionTypeId->setAttrib('class', 'textfield');
     $disburseddate = new Zend_Form_Element_Hidden('disburseddate');
     $description1 = new Zend_Form_Element_Hidden('description1');
     $Amount1 = new Zend_Form_Element_Hidden('Amount1');
     $fee1 = new Zend_Form_Element_Hidden('fee1');
     $this->addElements(array($Amount, $date, $transactionType, $description, $categoryId, $memberId, $typeId, $fee, $submit, $loanAmount, $accountCode, $transactionTypeId, $creditlinebalance, $Save, $disburseddate, $description1, $Amount1, $fee1));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:41,代码来源:loandisbursement.php

示例13: __construct

 public function __construct($path)
 {
     Zend_Dojo::enableForm($this);
     parent::__construct($options);
     $meetingupdates_id = new Zend_Form_Element_Hidden('meetingupdates_id');
     $meeting_id = new Zend_Form_Element_Hidden('meeting_id');
     $meeting_id->setAttrib('class', 'txt_put');
     $meeting_name = new Zend_Form_Element_Text('meeting_name');
     $meeting_name->setRequired(true)->addValidators(array(array('NotEmpty')));
     $meeting_name->setAttrib('class', 'txt_put');
     $meeting_name->addValidator(new Zend_Validate_Db_NoRecordExists('ourbank_meetingdetails', 'meeting_name'));
     $meeting_days = new Zend_Form_Element_Select('meeting_days');
     $meeting_days->addMultiOption('', 'SelectTheDay' . '...');
     $meeting_days->setAttrib('class', 'selectbutton');
     $meeting_place = new Zend_Form_Element_Text('meeting_place');
     $meeting_place->setRequired(true)->addValidators(array(array('NotEmpty')));
     $meeting_place->setAttrib('class', 'txt_put');
     $meeting_time = new Zend_Form_Element_Text('meeting_time');
     $meeting_time->setRequired(true)->addValidators(array(array('NotEmpty')));
     $meeting_time->setAttrib('class', 'txt_put');
     $timeg = new Zend_Form_Element_Select('timeg');
     $timeg->setRequired(true)->addValidators(array(array('NotEmpty')));
     $timeg->setAttrib('class', 'txt_put');
     $group_head = new Zend_Form_Element_Select('group_head');
     $group_head->addMultiOption('', 'select' . '...');
     $group_head->setAttrib('class', 'selectbutton');
     $officetype_id = new Zend_Form_Element_Select('officetype_id');
     $officetype_id->setRequired(true);
     $officetype_id->addMultiOption('', 'select' . '...');
     $officetype_id->setAttrib('class', 'selectbutton');
     $officetype_id->setAttrib('onchange', 'getGroups(this.value,"' . $path . '")');
     $group = new Zend_Form_Element_Select('group');
     $group->addMultiOption('', 'select' . '...');
     $group->setAttrib('class', 'selectbutton');
     $group->setRegisterInArrayValidator(false);
     //         $group->setAttrib('onchange', 'getGroupHead(this.value,"'.$path.'")');
     $submit = new Zend_Form_Element_Submit('Submit');
     $submit->setAttrib('class', 'officesubmit');
     $submit->setLabel('Submit');
     $this->addElements(array($meetingupdates_id, $meeting_id, $meeting_name, $meeting_days, $meeting_place, $timeg, $group_head, $officetype_id, $group, $submit, $meeting_time));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:41,代码来源:Meeting.php

示例14: __construct

 public function __construct($options = null)
 {
     parent::__construct($options);
     $this->setName('class');
     $this->setIsArray(true);
     $classname = new Zend_Form_Element_Text(Model_ClassGenerator_FormToClass::$nameKey);
     $classname->setLabel('Class name')->setRequired(true)->addValidator('NotEmpty', true);
     $classComment = new Zend_Form_Element_Textarea(Model_ClassGenerator_FormToClass::$commentKey);
     $classComment->setLabel('Class comment/description');
     $classComment->setAttrib('cols', '50')->setAttrib('rows', '4');
     $persistenceOn = new Zend_Form_Element_Checkbox(Model_ClassGenerator_FormToClass::$withPersistenceKey);
     $persistenceOn->setLabel('Persistence ON');
     $table = new Zend_Form_Element_Text(Model_ClassGenerator_FormToClass::$tableKey);
     $table->setLabel('Database Table');
     $addFieldDynId = new Zend_Form_Element_Hidden('addFieldDynId');
     $addFieldDynId->setAttrib('id', 'addFieldDynId');
     $addFieldDynId->setValue(1);
     $attributesSf = self::getAttributeSubform();
     $this->addSubForm($attributesSf, 'attributes', 1);
     /*Use table decorator!
             require_once('../application/forms/Decorators/Table.php');
             $this->setDecorators(array(
     			'FormElements',
     			array('Table', array('doNotSetDecorators' => false)),
     			'Form'
     		));
             */
     $add = new Zend_Form_Element_Button('addAttribute');
     $add->setAttrib('id', 'addAttribute');
     $add->setLabel('Add Attribute');
     $remove = new Zend_Form_Element_Button('removeAttribute');
     $remove->setAttrib('id', 'removeAttribute');
     $remove->setLabel('Remove Attribute');
     $submit = new Zend_Form_Element_Submit('submit');
     $submit->setLabel('Play!')->setOrder(5);
     $this->addElements(array($classname, $classComment, $persistenceOn, $table));
     $this->addDisplayGroup(array($classname->getName(), $classComment->getName(), $persistenceOn->getName(), $table->getName()), 'Class properties')->setOrder(0);
     $this->addElements(array($add, $remove, $submit, $addFieldDynId));
     $this->addElement('hash', 'no_csrf_foo', array('salt' => 'unique'));
 }
开发者ID:JPustkuchen,项目名称:phppcg,代码行数:40,代码来源:Class.php

示例15: init

 public function init()
 {
     $institution_id = new Zend_Form_Element_Hidden('institution_id');
     $institution_id->setAttrib('class', 'txt_put');
     $institutionname = new Zend_Form_Element_Text('institutionname');
     $institutionname->addValidator(new Zend_Validate_Db_NoRecordExists('ourbank_institutionaddress', 'institutionname'));
     $institutionname->setAttrib('class', 'txt_put')->setLabel('Institution Name');
     $institutionname->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $institutionshortname = new Zend_Form_Element_Text('institutionshortname');
     $institutionshortname->setAttrib('class', 'txt_put')->setLabel('Short Name');
     $institutionshortname->setRequired(true)->addValidators(array(array('NotEmpty'), array('stringLength', false, array(1, 3))))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $address1 = new Zend_Form_Element_Text('address1');
     $address1->setAttrib('class', 'txt_put')->setLabel('Address1');
     $address1->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $address2 = new Zend_Form_Element_Text('address2');
     $address2->setAttrib('class', 'txt_put')->setLabel('Address2');
     $address2->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $address3 = new Zend_Form_Element_Text('address3');
     $address3->setAttrib('class', 'txt_put')->setLabel('Address3');
     $address3->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $city = new Zend_Form_Element_Text('city');
     $city->setAttrib('class', 'txt_put')->setLabel('city');
     $city->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $state = new Zend_Form_Element_Text('state');
     $state->setAttrib('class', 'txt_put')->setLabel('state');
     $state->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $country = new Zend_Form_Element_Text('country');
     $country->setAttrib('class', 'txt_put')->setLabel('country');
     $country->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $pincode = new Zend_Form_Element_Text('pincode');
     $pincode->setAttrib('class', 'txt_put')->setLabel('pincode');
     $pincode->setRequired(true)->addValidators(array(array('Digits')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $phone = new Zend_Form_Element_Text('phone');
     $phone->setAttrib('class', 'txt_put')->setLabel('phone');
     $phone->setRequired(true)->addValidators(array(array('Digits')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $fax = new Zend_Form_Element_Text('fax');
     $fax->setAttrib('class', 'txt_put')->setLabel('fax');
     $fax->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $email_Id = new Zend_Form_Element_Text('email_Id');
     $email_Id->setAttrib('class', 'txt_put')->setLabel('Email_Id');
     $email_Id->setRequired(true)->addValidators(array(array('EmailAddress')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $institutiondescription = new Zend_Form_Element_Textarea('institutiondescription', array('rows' => 3, 'cols' => 20));
     $institutiondescription->setAttrib('class', '')->setLabel('Description');
     $institutiondescription->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $contactperson = new Zend_Form_Element_Text('contactperson');
     $contactperson->setAttrib('class', 'txt_put')->setLabel('contact person');
     $contactperson->setRequired(true)->addValidators(array(array('NotEmpty')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $contactperson_phone1 = new Zend_Form_Element_Text('contactperson_phone1');
     $contactperson_phone1->setAttrib('class', 'txt_put')->setLabel('Contactperson phone1');
     $contactperson_phone1->setRequired(true)->addValidators(array(array('Digits')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $contactperson_phone2 = new Zend_Form_Element_Text('contactperson_phone2');
     $contactperson_phone2->setAttrib('class', 'txt_put')->setLabel('Contactperson_phone2');
     $contactperson_phone2->setRequired(true)->addValidators(array(array('Digits')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $contactperson_email = new Zend_Form_Element_Text('contactperson_email');
     $contactperson_email->setAttrib('class', 'txt_put')->setLabel('Contactperson_email');
     $contactperson_email->setRequired(true)->addValidators(array(array('EmailAddress')))->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'td', 'requiredSuffix' => ' *')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $this->addElements(array($institution_id, $institutionname, $institutionshortname, $address1, $address2, $address3, $city, $state, $country, $pincode, $phone, $fax, $email_Id, $institutiondescription, $contactperson, $contactperson_phone1, $contactperson_phone2, $contactperson_email));
     $submit = new Zend_Form_Element_Submit('Submit');
     $submit->setAttrib('id', 'Submit')->setDecorators(array('ViewHelper', array('Description', array('tag' => '', 'escape' => false)), 'Errors', array(array('data' => 'HtmlTag'), array('colspan' => '8 ')), array(array('data' => 'HtmlTag'), array('tag' => 'td ', 'colspan' => '8')), array(array('row' => 'HtmlTag'), array('tag' => 'tr'))));
     $this->addElements(array($submit));
 }
开发者ID:maniargaurav,项目名称:OurBank,代码行数:61,代码来源:institution.php


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