本文整理汇总了PHP中Zend_Form_Element_Textarea::setAttrib方法的典型用法代码示例。如果您正苦于以下问题:PHP Zend_Form_Element_Textarea::setAttrib方法的具体用法?PHP Zend_Form_Element_Textarea::setAttrib怎么用?PHP Zend_Form_Element_Textarea::setAttrib使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Zend_Form_Element_Textarea
的用法示例。
在下文中一共展示了Zend_Form_Element_Textarea::setAttrib方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: init
public function init()
{
$this->setMethod('post');
$this->setAttrib('id', 'formid');
$this->setAttrib('name', 'holidaygroups');
$id = new Zend_Form_Element_Hidden('id');
$holidayname = new Zend_Form_Element_Text('holidayname');
$holidayname->setAttrib('maxLength', 20);
$holidayname->addFilter(new Zend_Filter_StringTrim());
$holidayname->setRequired(true);
$holidayname->addValidator('NotEmpty', false, array('messages' => 'Please enter holiday.'));
$holidayname->addValidator("regex", true, array('pattern' => '/^[a-zA-Z0-9.\\- ?]+$/', 'messages' => array('regexNotMatch' => 'Please enter valid holiday.')));
$groupid = new Zend_Form_Element_Multiselect('groupid');
$groupid->setAttrib('class', 'selectoption');
$groupid->setRegisterInArrayValidator(false);
$groupid->setRequired(true);
$groupid->addValidator('NotEmpty', false, array('messages' => 'Please select holiday group.'));
$holiday_date = new ZendX_JQuery_Form_Element_DatePicker('holidaydate');
$holiday_date->setAttrib('readonly', 'true');
$holiday_date->setAttrib('onfocus', 'this.blur()');
$holiday_date->setOptions(array('class' => 'brdr_none'));
$holiday_date->setRequired(true);
$holiday_date->addValidator('NotEmpty', false, array('messages' => 'Please select date.'));
$description = new Zend_Form_Element_Textarea('description');
$description->setAttrib('rows', 10);
$description->setAttrib('cols', 50);
$description->setAttrib('maxlength', '200');
$submit = new Zend_Form_Element_Submit('submit');
$submit->setAttrib('id', 'submitbutton');
$submit->setLabel('Save');
$this->addElements(array($id, $holidayname, $groupid, $holiday_date, $description, $submit));
$this->setElementDecorators(array('ViewHelper'));
$this->setElementDecorators(array('UiWidgetElement'), array('holidaydate'));
}
示例2: init
public function init()
{
$this->setMethod('post');
$this->setAttrib('action', BASE_URL . 'timezone/edit');
$this->setAttrib('id', 'formid');
$this->setAttrib('name', 'timezone');
$id = new Zend_Form_Element_Hidden('id');
$timezone = new Zend_Form_Element_Multiselect('timezone');
$timezone->setRegisterInArrayValidator(false);
$timezone->setRequired(true);
$timezone->addValidator('NotEmpty', false, array('messages' => 'Please select time zone.'));
$timezoneModal = new Default_Model_Timezone();
$timezoneData = $timezoneModal->getalltimezones();
foreach ($timezoneData as $data) {
$timezone->addMultiOption($data['id'], $data['timezone'] . ' [' . $data['timezone_abbr'] . ']');
}
$description = new Zend_Form_Element_Textarea('description');
$description->setAttrib('rows', 10);
$description->setAttrib('cols', 50);
$description->setAttrib('maxlength', '200');
$submit = new Zend_Form_Element_Submit('submit');
$submit->setAttrib('id', 'submitbutton');
$submit->setLabel('Save');
$url = "'timezone/saveupdate/format/json'";
$dialogMsg = "''";
$toggleDivId = "''";
$jsFunction = "'redirecttocontroller(\\'timezone\\');'";
$this->addElements(array($id, $timezone, $description, $submit));
$this->setElementDecorators(array('ViewHelper'));
}
示例3: init
public function init()
{
$this->setMethod('post');
$this->setAttrib('action', DOMAIN . 'attendancestatuscode/edit');
$this->setAttrib('id', 'formid');
$this->setAttrib('name', 'attendancestatuscode');
$id = new Zend_Form_Element_Hidden('id');
$attendancestatuscode = new Zend_Form_Element_Text('attendancestatuscode');
$attendancestatuscode->setAttrib('maxLength', 20);
//$attendancestatuscode->addFilter(new Zend_Filter_StringTrim());
$attendancestatuscode->setRequired(true);
$attendancestatuscode->addValidator('NotEmpty', false, array('messages' => 'Please enter attendance status.'));
$attendancestatuscode->addValidator("regex", true, array('pattern' => '/^(?=.*[a-zA-Z])([^ ][a-zA-Z0-9 ]*)$/', 'messages' => array('regexNotMatch' => 'Please enter valid attendance status.')));
$attendancestatuscode->addValidator(new Zend_Validate_Db_NoRecordExists(array('table' => 'main_attendancestatuscode', 'field' => 'attendancestatuscode', 'exclude' => 'id!="' . Zend_Controller_Front::getInstance()->getRequest()->getParam('id') . '" and isactive=1')));
$attendancestatuscode->getValidator('Db_NoRecordExists')->setMessage('Attendance status already exists.');
$description = new Zend_Form_Element_Textarea('description');
$description->setAttrib('rows', 10);
$description->setAttrib('cols', 50);
$description->setAttrib('maxlength', '200');
$submit = new Zend_Form_Element_Submit('submit');
$submit->setAttrib('id', 'submitbutton');
$submit->setLabel('Save');
$this->addElements(array($id, $attendancestatuscode, $description, $submit));
$this->setElementDecorators(array('ViewHelper'));
}
示例4: init
public function init()
{
$this->setMethod("post");
$title = new Zend_Form_Element_Text("title");
$title->setAttrib("placeholder", "Title");
$title->setAttrib("class", "form-control");
$title->setLabel("Title: ");
$title->setRequired();
$body = new Zend_Form_Element_Textarea("body");
$body->setAttrib("class", "form-control");
$body->setAttrib("placeholder", "Write body here....");
$body->setLabel("Body: ");
$body->setAttrib("rows", "5");
$body->setAttrib("cols", "55");
$body->setRequired();
$picture = new Zend_Form_Element_File('picture');
$picture->setLabel("Picture:");
$picture->setRequired();
$picture->setDestination('/var/www/html/RNR/public/images/thread');
$stick = new Zend_Form_Element_Radio("stick");
$stick->setLabel("Sticky:");
$stick->addMultiOption("on", "on");
$stick->addMultiOption("off", "off");
$stick->setRequired();
$id = new Zend_Form_Element_Hidden("id");
$submit = new Zend_Form_Element_Submit("Submit");
$submit->setAttrib("class", "btn btn-primary");
$submit->setLabel("Save");
$rest = new Zend_Form_Element_Submit('Rest');
$rest->setAttrib("class", "btn btn-info");
$this->addElements(array($id, $title, $body, $picture, $stick, $submit, $rest));
}
示例5: __construct
public function __construct($options = null)
{
parent::__construct($options);
parent::__construct();
$accountCode = new Zend_Form_Element_Hidden('accountcode');
$memberId = new Zend_Form_Element_Hidden('membercode');
$categoryId = new Zend_Form_Element_Hidden('categoryId');
$newStatus = new Zend_Form_Element_Select('newStatus');
$newStatus->setAttrib('class', 'NormalBtn');
$newStatus->setRequired(true);
$newStatus->addMultiOption('', 'Select...');
$description = new Zend_Form_Element_Textarea('description');
$description->setAttrib('rows', '2');
$description->setAttrib('cols', '20');
$description->setRequired(true);
$totalamount = new Zend_Form_Element_Text('totalamount');
$totalamount->setAttrib('class', 'textfield');
$totalamount->setAttrib('id', 'totalamount');
$totalamount->setAttrib('readonly', 'true');
$newStatus1 = new Zend_Form_Element_Hidden('newStatus1');
$description1 = new Zend_Form_Element_Hidden('description1');
$totalamount1 = new Zend_Form_Element_Hidden('totalamount1');
$confirm = new Zend_Form_Element_Submit('confirm');
$confirm->setAttrib('class', 'officesubmit');
$submit = new Zend_Form_Element_Submit('Submit');
$submit->setAttrib('class', 'officesubmit');
$this->addElements(array($submit, $newStatus, $description, $accountCode, $memberId, $categoryId, $totalamount, $confirm, $newStatus1, $description1, $totalamount1));
}
示例6: init
public function init()
{
/* Form Elements & Other Definitions Here ... */
$name = new Zend_Form_Element_Text("name");
$name->setLabel("You Name : ");
$name->setRequired(true);
$website = new Zend_Form_Element_Text("website");
$website->setLabel("Your Website : ");
$website->setDescription(" http://www.google.com ");
$email = new Zend_Form_Element_Text("email");
$email->setLabel("Email Address : ");
$email->setDescription(" Example : john@googe.com ");
$email->addValidator("EmailAddress", false, array('messages' => array(Zend_Validate_EmailAddress::INVALID_FORMAT => "Invalid Email Address Ya tayeb")));
$email->setRequired(true);
$body = new Zend_Form_Element_Textarea("body");
$body->setLabel("Text Message : ");
$body->setAttrib("class", "textbox");
$body->setAttrib("rows", "6");
$body->setAttrib("cols", "60");
$body->setRequired(true);
$submit = new Zend_Form_Element_Submit("contact");
$this->addElement($name);
$this->addElements(array($website, $email, $body, $submit));
$this->addElement("hash", "contact_us_hash_form");
}
示例7: __construct
public function __construct($loanamount)
{
Zend_Dojo::enableForm($this);
parent::__construct($loanamount);
//$fieldtype,$fieldname,$table,$columnname,$cssname,$labelname,$required,$validationtype,$min,$max,$rows,$cols,$decorator,$value
$formfield = new App_Form_Field();
$date = new ZendX_JQuery_Form_Element_DatePicker('date');
$date->setAttrib('class', 'txt_put');
$date->setJQueryParam('dateFormat', 'yy-mm-dd');
$date->setRequired(true);
$Amount = new Zend_Form_Element_Text('Amount');
$Amount->setAttrib('class', 'textfield');
$lessthan = new Zend_Validate_LessThan(array('max' => $loanamount + 1, 'inclusive' => false));
$Amount->setRequired(true)->addValidators(array(array('NotEmpty'), array('Float'), array($lessthan, true)));
$transactionMode = $formfield->field('Select', 'transactionMode', '', '', 'tmode', '', true, '', '', '', '', '', 0, '');
$etransfer = $formfield->field('Select', 'etransfer', '', '', 'etran', '', false, '', '', '', '', '', 0, '');
$etransfer->setRegisterInArrayValidator(false);
$memberid = $formfield->field('Hidden', 'memberid', '', '', 'memberclass', '', false, '', '', '', '', '', 0, '');
$membertypeid = $formfield->field('Hidden', 'membertypeid', '', '', 'membertypeclass', '', false, '', '', '', '', '', 0, '');
$pathhidden = $formfield->field('Hidden', 'pathhidden', '', '', 'pathclass', '', false, '', '', '', '', '', 0, '');
$othrtext = new Zend_Form_Element_Text('othertext');
$othrtext->setAttrib('size', 12);
$description = new Zend_Form_Element_Textarea('description');
$description->setAttrib('rows', '2');
$description->setAttrib('cols', '20');
$description->setRequired(true);
$sms = new Zend_Form_Element_Checkbox('sms');
$back = new Zend_Form_Element_Submit('Back');
$back->setAttrib('id', 'button2');
$submit = new Zend_Form_Element_Submit('Submit');
$submit->setAttrib('id', 'button');
$this->addElements(array($date, $Amount, $transactionMode, $etransfer, $othrtext, $description, $sms, $memberid, $pathhidden, $membertypeid, $submit, $back));
}
示例8: buildElements
protected function buildElements()
{
// Quick search field
$full_name = new Zend_Form_Element_Text('fullname');
$full_name->setLabel('Your Name:');
$full_name->setAttrib('class', 'contactforminput');
$full_name->setAttrib('hint', 'your name');
$this->addElement($full_name);
// create EMAIL input tag
// Unique check, require, email address valid check, length less than 100(database length for this field)
// do email address validation(default each email element do email address validation)
$credit_email = new Zend_Form_Element_Text('email_from');
$credit_email->setLabel('Your Email:');
$credit_email->setAttrib('class', 'contactforminput');
$this->addElement($credit_email);
// create Description Textarea tag
// filed type in db is Text
$description = new Zend_Form_Element_Textarea('question');
$description->setLabel('Your Question:');
$description->setAttrib('class', 'contactforminput');
$description->setAttrib('hint', 'your question');
$this->addElement($description);
// Quick search btn
$send = new Zend_Form_Element_Image('submit');
$send->setImage('/images/sitetemplate/send_button.png');
$send->setAttribs(array('rows' => 22, 'cols' => 60));
$send->setImageValue(true);
$this->addElement($send);
$this->setName("contactform");
$this->setAttrib("onSubmit", "return ValidateForm();");
}
示例9: init
public function init()
{
$this->setMethod('post');
$this->setAttrib('id', 'pdcategories');
$this->setAttrib('name', 'pdcategories');
$categoryName = new Zend_Form_Element_Text('category');
$categoryName->setAttrib('id', 'category');
$categoryName->setAttrib('name', 'category');
$categoryName->setAttrib('maxlength', '30');
$categoryName->setAttrib('onblur', 'chkCategory()');
$categoryName->setAttrib('onkeypress', 'chkCategory()');
$categoryName->addFilter(new Zend_Filter_StringTrim());
$categoryName->setRequired(true);
$categoryName->addValidator('NotEmpty', false, array("messages" => 'Please enter category'));
$categoryName->addValidator('regex', true, array('pattern' => '/^[a-zA-Z0-9][\\s+[a-zA-Z0-9]+]*$/', 'messages' => array('regexNotMatch' => 'Please enter valid category')));
$categoryName->addValidator(new Zend_Validate_Db_NoRecordExists(array('table' => 'main_pd_categories', 'field' => 'category', 'exclude' => 'id!="' . Zend_Controller_Front::getInstance()->getRequest()->getParam('id') . '" and isactive = 1')));
$categoryName->getValidator('Db_NoRecordExists')->setMessage('Category already exists');
$categoryDesc = new Zend_Form_Element_Textarea('description');
$categoryDesc->setAttrib('id', 'description');
$categoryDesc->setAttrib('name', 'description');
$categoryDesc->setAttrib('rows', 10);
$categoryDesc->setAttrib('cols', 50);
$categoryDesc->setAttrib('maxlength', 250);
$submitBtn = new Zend_Form_Element_Submit('submit');
$submitBtn->setAttrib('id', 'submitBtn');
$submitBtn->setLabel('Add');
$this->addElements(array($categoryName, $categoryDesc, $submitBtn));
$this->setElementDecorators(array('ViewHelper'));
}
示例10: init
public function init()
{
$this->setAttribs(array('id' => 'form-exposicao-add'));
// exposicao_nome
$exposicao_nome = new Zend_Form_Element_Text("exposicao_nome");
$exposicao_nome->setLabel("Nome da Exposição:");
$exposicao_nome->setAttrib('placeholder', 'Digite o nome de sua exposição');
$exposicao_nome->setRequired();
//exposicao_descricao
$exposicao_descricao = new Zend_Form_Element_Textarea("exposicao_descricao");
$exposicao_descricao->setLabel("Descrição da Exposição:");
$exposicao_descricao->setAttrib('placeholder', 'Conte aos usuários sobre sua exposição');
$exposicao_descricao->setAttrib('rows', 10);
$exposicao_descricao->setRequired();
// tipo_exposicao_id
$tipo_exposicao_id = new Zend_Form_Element_Select("tipo_exposicao_id");
$tipo_exposicao_id->setLabel("Categoria da Exposição:");
$tipo_exposicao_id->setRequired();
$tipo_exposicao_id->setMultiOptions($this->getTipoExposicao());
//exposicao_capa
$exposicao_capa = new Zend_Form_Element_File("files");
$exposicao_capa->setLabel("Selecione a capa:");
$exposicao_capa->setDestination(Zend_Registry::get('config')->path->images->exposicao->capa);
$exposicao_capa->addValidator('Extension', false, 'jpg,png,gif');
$exposicao_capa->addValidator('Size', false, 2097152)->setMaxFileSize(2097152);
$exposicao_capa->setAttrib('id', 'exposicao_capa');
$exposicao_capa->setRequired();
// add elements
$this->addElement($exposicao_nome);
$this->addElement($exposicao_descricao);
$this->addElement($tipo_exposicao_id);
$this->addElement($exposicao_capa);
parent::init();
}
示例11: init
public function init()
{
$this->setMethod('post');
$this->setAttrib('action', BASE_URL . 'timeformat/edit');
$this->setAttrib('id', 'formid');
$this->setAttrib('name', 'timeformat');
$id = new Zend_Form_Element_Hidden('id');
$timeformat = new Zend_Form_Element_Text('timeformat');
$timeformat->setAttrib('maxLength', 20);
$timeformat->addFilter(new Zend_Filter_StringTrim());
$timeformat->setRequired(true);
$timeformat->addValidator('NotEmpty', false, array('messages' => 'Please enter time format.'));
$description = new Zend_Form_Element_Textarea('description');
$description->setAttrib('rows', 10);
$description->setAttrib('cols', 50);
$description->setAttrib('maxlength', '200');
$submit = new Zend_Form_Element_Submit('submit');
$submit->setAttrib('id', 'submitbutton');
$submit->setLabel('Save');
$url = "'timeformat/saveupdate/format/json'";
$dialogMsg = "''";
$toggleDivId = "''";
$jsFunction = "'redirecttocontroller(\\'timeformat\\');'";
$this->addElements(array($id, $timeformat, $description, $submit));
$this->setElementDecorators(array('ViewHelper'));
}
示例12: __construct
public function __construct($options = null)
{
parent::__construct($options);
$accountId1 = new Zend_Form_Element_Hidden('accountId');
$productId1 = new Zend_Form_Element_Hidden('productId');
$memberId1 = new Zend_Form_Element_Hidden('memberId');
$maturedamount = new Zend_Form_Element_Hidden('maturedinterestamount');
$interestamountto = new Zend_Form_Element_Hidden('interestamountto');
$capitalamount = new Zend_Form_Element_Hidden('capitalamount');
$penalinterest = new Zend_Form_Element_Hidden('penalinterest');
$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');
$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);
$submit = new Zend_Form_Element_Submit('Finalize');
$submit->setLabel('Finalize');
$submit->setAttrib('class', 'recurring');
$this->addElements(array($accountId1, $productId1, $memberId1, $maturedamount, $submit, $capitalamount, $interestamountto, $penalinterest, $paymenttype, $description, $no));
}
示例13: init
public function init()
{
$this->setMethod('post');
$this->setAttrib('action', DOMAIN . 'workeligibilitydoctypes/edit');
$this->setAttrib('id', 'formid');
$this->setAttrib('name', 'workeligibilitydoctypes');
$id = new Zend_Form_Element_Hidden('id');
$documenttype = new Zend_Form_Element_Text('documenttype');
$documenttype->setAttrib('maxLength', 50);
$documenttype->setRequired(true);
$documenttype->addValidator('NotEmpty', false, array('messages' => 'Please enter document type.'));
$documenttype->addValidator("regex", true, array('pattern' => '/^(?=.*[a-zA-Z])([^ ][a-zA-Z0-9\\-\\s]*)$/', 'messages' => array('regexNotMatch' => 'Please enter valid document type.')));
$documenttype->addValidator(new Zend_Validate_Db_NoRecordExists(array('table' => 'main_workeligibilitydoctypes', 'field' => 'documenttype', 'exclude' => 'id!="' . Zend_Controller_Front::getInstance()->getRequest()->getParam('id') . '" and isactive=1')));
$documenttype->getValidator('Db_NoRecordExists')->setMessage('Document type already exists.');
$issuingauthority = new Zend_Form_Element_Select('issuingauthority');
$issuingauthority->setRegisterInArrayValidator(false);
$issuingauthority->setMultiOptions(array('' => 'Select issuing authority', '1' => 'Country', '2' => 'State', '3' => 'City'));
$issuingauthority->setRequired(true);
$issuingauthority->addValidator('NotEmpty', false, array('messages' => 'Please select issuing authority.'));
$description = new Zend_Form_Element_Textarea('description');
$description->setAttrib('rows', 10);
$description->setAttrib('cols', 50);
$description->setAttrib('maxlength', '200');
$submit = new Zend_Form_Element_Submit('submit');
$submit->setAttrib('id', 'submitbutton');
$submit->setLabel('Save');
$this->addElements(array($id, $documenttype, $issuingauthority, $description, $submit));
$this->setElementDecorators(array('ViewHelper'));
}
示例14: init
public function init()
{
$this->setMethod('post');
$this->setAttrib('action', BASE_URL . 'payfrequency/edit');
$this->setAttrib('id', 'formid');
$this->setAttrib('name', 'payfrequency');
$id = new Zend_Form_Element_Hidden('id');
$freqtype = new Zend_Form_Element_Text('freqtype');
$freqtype->setAttrib('maxLength', 20);
$freqtype->setLabel("Pay Frequency");
$freqtype->setRequired(true);
$freqtype->addValidator('NotEmpty', false, array('messages' => 'Please enter pay frequency type.'));
$freqtype->addValidator("regex", true, array('pattern' => '/^(?=.*[a-zA-Z])([^ ][a-zA-Z0-9 ]*)$/', 'messages' => array('regexNotMatch' => 'Please enter valid pay frequency type.')));
$freqtype->addValidator(new Zend_Validate_Db_NoRecordExists(array('table' => 'main_payfrequency', 'field' => 'freqtype', 'exclude' => 'id!="' . Zend_Controller_Front::getInstance()->getRequest()->getParam('id') . '" and isactive=1')));
$freqtype->getValidator('Db_NoRecordExists')->setMessage('Pay frequency type already exists.');
$freqshortcode = new Zend_Form_Element_Text('freqcode');
$freqshortcode->setLabel("Short Code");
$freqshortcode->setAttrib('maxLength', 20);
$freqshortcode->addValidator("regex", true, array('pattern' => '/^[a-zA-Z][a-zA-Z0-9]*$/', 'messages' => array('regexNotMatch' => 'Please enter valid pay frequency short code.')));
$freqshortcode->addValidator(new Zend_Validate_Db_NoRecordExists(array('table' => 'main_payfrequency', 'field' => 'freqcode', 'exclude' => 'id!="' . Zend_Controller_Front::getInstance()->getRequest()->getParam('id') . '" and isactive=1')));
$freqshortcode->getValidator('Db_NoRecordExists')->setMessage('Pay frequency short code already exists.');
$description = new Zend_Form_Element_Textarea('freqdescription');
$description->setAttrib('rows', 10);
$description->setAttrib('cols', 50);
$description->setAttrib('maxlength', '200');
$submit = new Zend_Form_Element_Submit('submit');
$submit->setAttrib('id', 'submitbutton');
$submit->setLabel('Save');
$this->addElements(array($id, $freqtype, $freqshortcode, $description, $submit));
$this->setElementDecorators(array('ViewHelper'));
}
示例15: init
public function init()
{
$this->setMethod("POST");
$category = new Zend_Form_Element_Text("name");
$category->setRequired();
$category->setLabel("category Name:");
$category->setAttrib("placeholder", "Enter Category Name");
$category->addValidator(new Zend_Validate_Alnum("true"));
$category->setAttrib("class", "form-control");
$category->getDecorator("Label")->setOption("class", "control-label");
$category->getDecorator("Errors")->setOption("class", "alert alert-danger");
$category->getDecorator("Errors")->setOption("role", "alert");
$category->getDecorator("Errors")->setOption("style", " list-style-type:none");
$description = new Zend_Form_Element_Textarea("description");
$description->setLabel('Description:');
$description->setRequired();
$description->setAttrib("rows", "10");
$description->setAttrib("class", "form-control");
$description->getDecorator("Label")->setOption("class", "control-label");
$description->getDecorator("Errors")->setOption("class", "alert alert-danger");
$description->getDecorator("Errors")->setOption("style", " list-style-type:none");
$submit = new Zend_Form_Element_Submit("submit");
$submit->setAttrib("class", "btn btn-xl center-block");
// $submit->setAttrib("class", "btn");
$this->addElements(array($category, $description, $submit));
}