本文整理汇总了PHP中Zend_Form_Element_Text::removeDecorator方法的典型用法代码示例。如果您正苦于以下问题:PHP Zend_Form_Element_Text::removeDecorator方法的具体用法?PHP Zend_Form_Element_Text::removeDecorator怎么用?PHP Zend_Form_Element_Text::removeDecorator使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Zend_Form_Element_Text
的用法示例。
在下文中一共展示了Zend_Form_Element_Text::removeDecorator方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: setForm
function setForm()
{
$form=new Zend_Form;
$form->setMethod('post')->setAction('');
$ads_banner = new Zend_Form_Element_Textarea('ads_banner');
$ads_banner->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Biểu ngữ không được để trống'));
$ads_position = new Zend_Form_Element_Text('ads_position');
$ads_position->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Vị trí không được để trống'));
$ads_name = new Zend_Form_Element_Text('ads_name');
$ads_name->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Tên quảng cáo không được để trống'));
$ads_link = new Zend_Form_Element_Text('ads_link');
$ads_link->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Đường dẫn không được để trống'));
$ads_position = $form->createElement("select","ads_position",array(
"label" => "Vị trí",
"multioptions"=> array(
"1" => "Trên",
"2" => "Giữa",
"3" => "Trái",
"4" => "Phải",
"5" => "Nội dung")));
$ads_banner->removeDecorator('HtmlTag')->removeDecorator('Label');
$ads_position->removeDecorator('HtmlTag')->removeDecorator('Label');
$ads_name->removeDecorator('HtmlTag')->removeDecorator('Label');
$ads_link->removeDecorator('HtmlTag')->removeDecorator('Label');
$form->addElements(array($ads_banner,$ads_position,$ads_name,$ads_link));
return $form;
}
示例2: setForm
function setForm()
{
$form=new Zend_Form;
$form->setMethod('post')->setAction('');
$user_login = new Zend_Form_Element_Text('user_login');
$user_login->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Tên đăng nhập không được để trống'));
$user_pass = new Zend_Form_Element_Password('user_pass');
$user_pass->setAttrib('renderPassword', true);
$user_pass->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Mật khẩu không được để trống'));
$user_fullname = new Zend_Form_Element_Text('user_fullname');
$user_fullname->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Tên người dùng không được để trống'));
$user_email = new Zend_Form_Element_Text('user_email');
$user_email->addValidator('EmailAddress',true,array('messages'=>'Địa chỉ email không hợp lệ'));
$user_email->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Email không được để trống'));
$user_address = new Zend_Form_Element_Text('user_address');
$user_address->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Địa chỉ không được để trống'));
$user_login->removeDecorator('HtmlTag')->removeDecorator('Label');
$user_pass->removeDecorator('HtmlTag')->removeDecorator('Label');
$user_fullname->removeDecorator('HtmlTag')->removeDecorator('Label');
$user_email->removeDecorator('HtmlTag')->removeDecorator('Label');
$user_address->removeDecorator('HtmlTag')->removeDecorator('Label');
$form->addElements(array($user_login,$user_pass,$user_fullname,$user_email,$user_address));
return $form;
}
示例3: setForm
function setForm()
{
$form=new Zend_Form;
$form->setMethod('post')->setAction('');
$category_name = new Zend_Form_Element_Text('category_name');
$category_name->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Tên danh mục không được để trống'));
/*
$category_parent_id = new Zend_Form_Element_Select('category_parent_id');
$category_parent_id->addMultiOption('', '0');
foreach($this->mDanhmuc->getListDM() as $item)
{
$category_parent_id->addMultiOption($item['category_name'], $item['category_id']);
}
*/
$is_active = $form->createElement("select","is_active",array(
"label" => "Kích hoạt",
"multioptions"=> array(
"0" => "Chưa kích hoạt",
"1" => "Đã kích hoạt")));
$category_name->removeDecorator('HtmlTag')->removeDecorator('Label');
$is_active->removeDecorator('HtmlTag')->removeDecorator('Label');
$form->addElements(array($category_name,$is_active));
return $form;
}
示例4: setForm
function setForm()
{
$form=new Zend_Form;
$form->setMethod('post')->setAction('');
$youtube_username = new Zend_Form_Element_Text('youtube_username');
$youtube_username->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Tên tài khoản không được để trống'));
$password = new Zend_Form_Element_Text('password');
$password->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Mật khẩu không được để trống'));
$youtube_gallery = new Zend_Form_Element_Text('youtube_gallery');
$youtube_gallery->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Tên album không được để trống'));
$is_selected = $form->createElement("select","is_selected",array(
"label" => "Kích hoạt",
"multioptions"=> array(
"0" => "Không",
"1" => "Có")));
$youtube_username->removeDecorator('HtmlTag')->removeDecorator('Label');
$password->removeDecorator('HtmlTag')->removeDecorator('Label');
$youtube_gallery->removeDecorator('HtmlTag')->removeDecorator('Label');
$is_selected->removeDecorator('HtmlTag')->removeDecorator('Label');
$form->addElements(array($youtube_username,$password,$youtube_gallery,$is_selected));
return $form;
}
示例5: setForm
function setForm()
{
$form=new Zend_Form;
$form->setMethod('post')->setAction('');
$image_name = new Zend_Form_Element_Text('image_name');
$image_name->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Tên ảnh không được để trống'));
$image_link = new Zend_Form_Element_Textarea('image_link');
$image_link->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Hình ảnh không được để trống'));
$is_active = new Zend_Form_Element_Radio('is_active');
$is_active->setRequired(true)
->setLabel('is_active')
->setMultiOptions(array("1" => "Có","0" => "Không"));
$image_name->removeDecorator('HtmlTag')->removeDecorator('Label');
$image_link->removeDecorator('HtmlTag')->removeDecorator('Label');
$is_active->removeDecorator('HtmlTag')->removeDecorator('Label');
$form->addElements(array($image_name,$image_link,$is_active));
return $form;
}
示例6: setForm
function setForm()
{
$form = new Zend_Form;
$form->setMethod('post')->setAction('');
//$this->setAttrib('enctype','multipart/form-data');
$file = new Zend_Form_Element_File('video_file');
//$file->setAttrib('class','file');
$file->setLabel('video_file');
$file->setRequired(true);
$video_title = new Zend_Form_Element_Text('video_title');
$video_title ->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Tiêu đề không được để trống'));
$video_thumbnail=new Zend_Form_Element_Textarea('video_thumbnail');
$video_thumbnail->removeDecorator('HtmlTag')->removeDecorator('Label');
$video_description = new Zend_Form_Element_Textarea('video_description');
$video_description->setAttrib('rows','7');
$video_description ->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Mô tả không được để trống'));
$is_active = new Zend_Form_Element_Radio('is_active');
$is_active->setRequired(true)
->setLabel('is_active')
->setMultiOptions(array("1" => "Có","0" => "Không"));
$file->removeDecorator('HtmlTag')->removeDecorator('Label');
$video_title->removeDecorator('HtmlTag')->removeDecorator('Label');
$video_description->removeDecorator('HtmlTag')->removeDecorator('Label');
$is_active->removeDecorator('HtmlTag')->removeDecorator('Label');
$form->addElements(array($file,$video_title,$video_description,$is_active,$video_thumbnail));
return $form;
}
示例7: actionInputForm
public function actionInputForm($params)
{
$info = array('label' => $this->key, 'title' => $this->title, 'size' => $this->size, 'value' => $this->value, 'data' => $this->getAttrData(array('validate' => $this->validate)));
if (isset($params[$this->key])) {
$info['value'] = $params[$this->key];
}
$e = new Zend_Form_Element_Text($this->key, $info);
$e->removeDecorator('Errors')->removeDecorator('Description')->removeDecorator('HtmlTag')->removeDecorator('Label');
$this->_model->result[$this->key] = $e;
return true;
}
示例8: outputAction
public function outputAction($params)
{
$info = array('label' => $this->key, 'title' => $this->title, 'size' => $this->size, 'value' => $params[$this->key], 'data' => $this->getAttrData(array('validate' => $this->validate)));
if (isset($params[$this->key])) {
$info['value'] = $params[$this->key];
}
$e = new Zend_Form_Element_Text($this->key, $info);
$e->removeDecorator('Errors')->removeDecorator('Description')->removeDecorator('HtmlTag')->removeDecorator('Label');
$e = $e->__toString();
$e = str_replace('name="' . $this->key . '"', 'name="' . $this->key . '[' . $params['id'] . ']' . '"', $e);
return $e;
}
示例9: init
/**
* Inicializace formulare
*
*/
public function init()
{
$this->setMethod(self::METHOD_POST);
// Message
$message = new Zend_Form_Element_Text('message');
$message->addFilter('StringTrim');
$message->setRequired(true);
$message->setAttrib('class', 'form-control');
$message->setAttrib('placeholder', 'Type Message…');
$message->removeDecorator('Label');
$this->addElement($message, 'message');
// Send button
$send = new Zend_Form_Element_Submit('sendButton');
$send->setLabel('Send');
$send->setAttrib('class', 'btn btn-success btn-flat');
$send->setDecorators(array('ViewHelper'));
$this->addElement($send, 'sendButton');
}
示例10: setForm
function setForm()
{
$form=new Zend_Form;
$form->setMethod('post')->setAction('');
$danhmuc = new Zend_Form_Element_Text('danhmuc');
$noidung = new Zend_Form_Element_Text('noidung');
$noidung->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Nội dung không được để trống'));
$lienket = new Zend_Form_Element_Text('lienket');
$lienket->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Liên kết không được để trống'));
$danhmuc->removeDecorator('HtmlTag')->removeDecorator('Label');
$noidung->removeDecorator('HtmlTag')->removeDecorator('Label');
$lienket->removeDecorator('HtmlTag')->removeDecorator('Label');
$form->addElements(array($danhmuc,$noidung,$lienket));
return $form;
}
示例11: setForm
function setForm()
{
$form=new Zend_Form;
$form->setMethod('post')->setAction('');
$category_name = new Zend_Form_Element_Text('category_name');
$category_name->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Tên chuyên mục không được để trống'));
$is_active= new Zend_Form_Element_Radio('is_active');
$is_active->setRequired(true)
->setLabel('Are you sure?')
->setMultiOptions(array(
"1" => "Có",
"0" => "Không"));
$category_name->removeDecorator('HtmlTag')->removeDecorator('Label');
$is_active->removeDecorator('HtmlTag')->removeDecorator('Label');
$form->addElements(array($category_name,$is_active));
return $form;
}
示例12: init
public function init()
{
$this->setName(strtolower(get_class()));
$this->setMethod("post");
$oSearchedText = new Zend_Form_Element_Text("smart_searched_text");
$oSearchedText->removeDecorator("label");
$oSearchedText->setRequired(FALSE);
$oSearchedText->setFilters($this->_aFilters);
$this->addElement($oSearchedText);
$this->addElement("hash", "csrf_token", array("ignore" => false, "timeout" => 7200));
$this->getElement("csrf_token")->removeDecorator("Label");
$oViewScript = new Zend_Form_Decorator_ViewScript();
$oViewScript->setViewModule("admin");
$oViewScript->setViewScript("_forms/smartsearch.phtml");
$this->clearDecorators();
$this->setDecorators(array(array($oViewScript)));
$oElements = $this->getElements();
foreach ($oElements as $oElement) {
$oElement->setFilters($this->_aFilters);
$oElement->removeDecorator("Errors");
}
}
示例13: setForm
function setForm($check,$id)
{
$form=new Zend_Form;
$form->setMethod('post')->setAction('');
$category_name = new Zend_Form_Element_Text('category_name');
$category_name->setRequired(true)->addValidator('NotEmpty',true,array('messages'=>'Tên chuyên mục không được để trống'));
$category_parent_id = new Zend_Form_Element_Select('category_parent_id');
$category_parent_id->addMultiOption('0', '');
if($check==1)
{
$list = $this->mChuyenmuc->getListParentSubOne($id);
}
else
{
$list = $this->mChuyenmuc->getListCmParent();
}
foreach($list as $item)
{
$category_parent_id->addMultiOption($item['category_id'],$item['category_name']);
}
$is_active= new Zend_Form_Element_Radio('is_active');
$is_active->setRequired(true)
->setLabel('Are you sure?')
->setMultiOptions(array(
"1" => "Có",
"0" => "Không"));
$category_name->removeDecorator('HtmlTag')->removeDecorator('Label');
$category_parent_id->removeDecorator('HtmlTag')->removeDecorator('Label');
$is_active->removeDecorator('HtmlTag')->removeDecorator('Label');
$form->addElements(array($category_name,$category_parent_id,$is_active));
return $form;
}
示例14: __construct
/**
* Class constructor
*
* @return void
*/
public function __construct($options = null)
{
parent::__construct($options);
$labelCSS = Cible_FunctionsGeneral::getLanguageLabelColor($options);
$imageSrc = $options['imageSrc'];
$dataId = $options['dataId'];
$imgField = $options['imgField'];
$isNewImage = $options['isNewImage'];
$moduleName = $options['moduleName'];
$formItemPrices = new Zend_Form_SubForm();
$formTop = new Zend_Form_SubForm();
$formBottom = new Zend_Form_SubForm();
// $this = new Zend_Form_SubForm();
if ($dataId == '') {
$pathTmp = "../../../../../data/images/" . $moduleName . "/tmp";
} else {
$pathTmp = "../../../../../data/images/" . $moduleName . "/" . $dataId . "/tmp";
}
// hidden specify if new image for the news
// $newImage = new Zend_Form_Element_Hidden('isNewImage', array('value' => $isNewImage));
// $newImage->removeDecorator('Label');
// $this->addElement($newImage);
// Name of the product line
$name = new Zend_Form_Element_Text('II_Name');
$name->setLabel($this->getView()->getCibleText('item_label_name') . "<span class='field_required'>*</span>")->setRequired(true)->addFilter('StripTags')->addFilter('StringTrim')->addValidator('NotEmpty', true, array('messages' => array('isEmpty' => $this->getView()->getCibleText('validation_message_empty_field'))))->setDecorators(array('ViewHelper', array('label', array('placement' => 'prepend')), array('Errors', array('placement' => 'append')), array(array('row' => 'HtmlTag'), array('tag' => 'dd', 'class' => 'form_title_inline', 'id' => 'title'))))->setAttrib('class', 'stdTextInput');
$label = $name->getDecorator('Label');
$label->setOption('class', $this->_labelCSS);
$formTop->addElement($name);
// List of products
$oProducts = new ProductsObject();
$listProd = $oProducts->productsCollection(Zend_Registry::get('currentEditLanguage'));
$products = new Zend_Form_Element_Select('I_ProductID');
$products->setLabel($this->getView()->getCibleText('form_item_products_label') . "<span class='field_required'>*</span>")->setRequired(true)->addValidator('NotEmpty', true, array('messages' => array('isEmpty' => $this->getView()->getCibleText('validation_message_empty_field'))))->setAttrib('class', 'largeSelect')->setDecorators(array('ViewHelper', array('label', array('placement' => 'prepend')), array('Errors', array('placement' => 'append')), array(array('row' => 'HtmlTag'), array('tag' => 'dd', 'class' => 'form_title_inline', 'id' => 'title'))));
$products->addMultiOption('', $this->getView()->getCibleText('form_select_default_label'));
$products->addMultiOptions($listProd);
// foreach ($listProd as $data)
// {
// $products->addMultiOption($data['P_ID'], $data['PI_Name']);
// }
$formTop->addElement($products);
// Product
$productCode = new Zend_Form_Element_Text('I_ProductCode');
$productCode->setLabel($this->getView()->getCibleText('form_product_code_label'))->setRequired(false)->addFilter('StripTags')->addFilter('StringTrim')->addValidator('NotEmpty', true, array('messages' => array('isEmpty' => $this->getView()->getCibleText('validation_message_empty_field'))))->setDecorators(array('ViewHelper', array('label', array('placement' => 'prepend')), array(array('row' => 'HtmlTag'), array('tag' => 'dd', 'class' => 'form_title_inline', 'id' => 'title'))))->setAttrib('class', 'stdTextInput');
$formTop->addElement($productCode);
// Item sequence
$sequence = new Zend_Form_Element_Text('I_Seq');
$sequence->setLabel($this->getView()->getCibleText('form_product_sequence_label'))->setRequired(false)->addFilter('StripTags')->addFilter('StringTrim')->addValidator('NotEmpty', true, array('messages' => array('isEmpty' => $this->getView()->getCibleText('validation_message_empty_field'))))->setDecorators(array('ViewHelper', array('label', array('placement' => 'prepend')), array(array('row' => 'HtmlTag'), array('tag' => 'dd', 'class' => 'form_title_inline', 'id' => 'title'))))->setAttrib('class', 'smallTextInput');
$formTop->addElement($sequence);
// Detail Price
$detailPrice = new Zend_Form_Element_Text('I_PriceDetail');
$detailPrice->setLabel($this->getView()->getCibleText('form_item_pricedetail_label'))->setRequired(false)->addFilter('StripTags')->addFilter('StringTrim')->addValidator('NotEmpty', true, array('messages' => array('isEmpty' => $this->getView()->getCibleText('validation_message_empty_field'))))->setDecorators(array('ViewHelper', array('label', array('placement' => 'prepend')), array(array('row' => 'HtmlTag'), array('tag' => 'dd', 'class' => 'form_title_inline', 'id' => 'title'))))->setAttrib('class', 'smallTextInput');
$formTop->addElement($detailPrice);
// Pro price
$proPrice = new Zend_Form_Element_Text('I_PricePro');
$proPrice->setLabel($this->getView()->getCibleText('form_item_pricepro_label'))->setRequired(false)->addFilter('StripTags')->addFilter('StringTrim')->addValidator('NotEmpty', true, array('messages' => array('isEmpty' => $this->getView()->getCibleText('validation_message_empty_field'))))->setDecorators(array('ViewHelper', array('label', array('placement' => 'prepend')), array(array('row' => 'HtmlTag'), array('tag' => 'dd', 'class' => 'form_title_inline', 'id' => 'title'))))->setAttrib('class', 'smallTextInput');
$formTop->addElement($proPrice);
//********************************************************
//* Sub form containing data defining prices and volumes *
//********************************************************
$txtQty = new Cible_Form_Element_Html('lblQty', array('value' => $this->getView()->getCibleText('form_item_qty_label')));
$txtQty->setDecorators(array('ViewHelper', array('label', array('placement' => 'prepend')), array(array('row' => 'HtmlTag'), array('tag' => 'dd', 'class' => 'form_title_inline left'))));
$formItemPrices->addElement($txtQty);
$txtPrices = new Cible_Form_Element_Html('lblPrices', array('value' => $this->getView()->getCibleText('form_item_prices_label')));
$txtPrices->setDecorators(array('ViewHelper', array(array('row' => 'HtmlTag'), array('tag' => 'dd', 'class' => 'form_title_inline right'))));
$formItemPrices->addElement($txtPrices);
// Qty limit 1
$qtyInf = new Zend_Form_Element_Text('I_LimitVol1');
$qtyInf->setLabel($this->getView()->getCibleText('form_item_limitvol1_label'))->setRequired(false)->addFilter('StripTags')->addFilter('StringTrim')->addValidator('NotEmpty', true, array('messages' => array('isEmpty' => $this->getView()->getCibleText('validation_message_empty_field'))))->setDecorators(array('ViewHelper', array('label', array('placement' => 'prepend')), array(array('row' => 'HtmlTag'), array('tag' => 'dd', 'class' => 'inputColLeft'))))->setAttrib('class', 'smallTextInput left');
$formItemPrices->addElement($qtyInf);
// Price Vol 1
$firstPrice = new Zend_Form_Element_Text('I_PriceVol1');
$firstPrice->removeDecorator('Label')->setRequired(false)->addFilter('StripTags')->addFilter('StringTrim')->addValidator('NotEmpty', true, array('messages' => array('isEmpty' => $this->getView()->getCibleText('validation_message_empty_field'))))->setDecorators(array('ViewHelper', array('label', array('placement' => 'prepend')), array(array('row' => 'HtmlTag'), array('tag' => 'dd', 'class' => 'inputColRight'))))->setAttrib('class', 'smallTextInput');
$formItemPrices->addElement($firstPrice);
// Qty limit 2
$qtyMiddle = new Zend_Form_Element_Text('I_LimitVol2');
$qtyMiddle->setLabel($this->getView()->getCibleText('form_item_limitvol2_label'))->setRequired(false)->addFilter('StripTags')->addFilter('StringTrim')->addValidator('NotEmpty', true, array('messages' => array('isEmpty' => $this->getView()->getCibleText('validation_message_empty_field'))))->setDecorators(array('ViewHelper', array('label', array('placement' => 'prepend')), array(array('row' => 'HtmlTag'), array('tag' => 'dd', 'class' => 'inputColLeft'))))->setAttrib('class', 'smallTextInput textRight');
$formItemPrices->addElement($qtyMiddle);
// Price vol 2
$secondPrice = new Zend_Form_Element_Text('I_PriceVol2');
$secondPrice->removeDecorator('Label')->setRequired(false)->addFilter('StripTags')->addFilter('StringTrim')->addValidator('NotEmpty', true, array('messages' => array('isEmpty' => $this->getView()->getCibleText('validation_message_empty_field'))))->setDecorators(array('ViewHelper', array('label', array('placement' => 'prepend')), array(array('row' => 'HtmlTag'), array('tag' => 'dd', 'class' => 'inputColRight', 'id' => 'title'))))->setAttrib('class', 'smallTextInput textRight');
$formItemPrices->addElement($secondPrice);
// Price vol 3
$thirdPrice = new Zend_Form_Element_Text('I_PriceVol3');
$thirdPrice->setLabel($this->getView()->getCibleText('form_item_priceVol3_label'))->setRequired(false)->addFilter('StripTags')->addFilter('StringTrim')->addValidator('NotEmpty', true, array('messages' => array('isEmpty' => $this->getView()->getCibleText('validation_message_empty_field'))))->setDecorators(array('ViewHelper', array('label', array('placement' => 'prepend')), array(array('row' => 'HtmlTag'), array('tag' => 'dd', 'class' => 'inputColRight'))))->setAttrib('class', 'smallTextInput textRight');
$formItemPrices->addElement($thirdPrice);
//********************************************************
$special = new Zend_Form_Element_Checkbox('I_Special');
$special->setLabel($this->getView()->getCibleText('form_item_special_label'));
$special->setDecorators(array('ViewHelper', array('label', array('placement' => 'append')), array(array('row' => 'HtmlTag'), array('tag' => 'dd', 'class' => 'label_after_checkbox'))));
$formBottom->addElement($special);
// Special Price
$specialPrice = new Zend_Form_Element_Text('I_PrixSpecial');
$specialPrice->setLabel($this->getView()->getCibleText('form_item_specialPrice_label'))->setRequired(false)->addFilter('StripTags')->addFilter('StringTrim')->addValidator('NotEmpty', true, array('messages' => array('isEmpty' => $this->getView()->getCibleText('validation_message_empty_field'))))->setDecorators(array('ViewHelper', array('label', array('placement' => 'prepend')), array(array('row' => 'HtmlTag'), array('tag' => 'dd', 'class' => 'form_title_inline', 'id' => 'title'))))->setAttrib('class', 'smallTextInput');
$formBottom->addElement($specialPrice);
// Checkbox for tax of the province
//.........这里部分代码省略.........
示例15: init
/**
* Inicializace formulare
*
*/
public function init()
{
$this->setMethod(self::METHOD_POST);
// ################## FIRST COLUMN ###################
// datum pohovoru
$elem = new Zend_Form_Element_Text('datum_pohovoru');
$elem->addFilter('StringTrim');
$elem->setAttrib('class', array('form-control', 'date-picker'));
$elem->setAttrib('placeholder', 'Pick a date…');
$elem->removeDecorator('Label');
$this->addElement($elem, 'datum_pohovoru');
// Multi select (perzonalista – pokročilé informace)
$elem = new Zend_Form_Element_Multiselect('perzonalista_informace');
$elem->removeDecorator('Label');
$elem->setAttrib('placeholder', 'Pick an interviewers…');
$elem->setAttrib('class', 'form-control');
$this->addElement($elem, 'perzonalista_informace');
// vzdělání
$elem = new Zend_Form_Element_Text('vzdelani');
$elem->addFilter('StringTrim');
$elem->setAttrib('class', 'form-control');
$elem->setAttrib('placeholder', 'Education…');
$elem->removeDecorator('Label');
$this->addElement($elem, 'vzdelani');
// motivace
$elem = new Zend_Form_Element_Textarea('motivace');
$elem->addFilter('StringTrim');
$elem->setAttrib('class', 'form-control');
$elem->setAttrib('placeholder', 'Motivation…');
$elem->setAttrib('rows', '1');
$elem->removeDecorator('Label');
$this->addElement($elem, 'motivace');
// preferovaná práce
$elem = new Zend_Form_Element_Textarea('preferovana_prace');
$elem->addFilter('StringTrim');
$elem->setAttrib('class', 'form-control');
$elem->setAttrib('placeholder', 'Kind of work preferred…');
$elem->setAttrib('rows', '1');
$elem->removeDecorator('Label');
$this->addElement($elem, 'preferovana_prace');
// ambice
$elem = new Zend_Form_Element_Textarea('ambice');
$elem->addFilter('StringTrim');
$elem->setAttrib('class', 'form-control');
$elem->setAttrib('placeholder', 'Ambitions…');
$elem->setAttrib('rows', '1');
$elem->removeDecorator('Label');
$this->addElement($elem, 'ambice');
// jazyky
$elem = new Zend_Form_Element_Text('jazyky');
$elem->addFilter('StringTrim');
$elem->setAttrib('class', 'form-control');
$elem->setAttrib('placeholder', 'Languages…');
$elem->removeDecorator('Label');
$this->addElement($elem, 'jazyky');
// cestování
$elem = new Zend_Form_Element_Text('cestovani');
$elem->addFilter('StringTrim');
$elem->setAttrib('class', 'form-control');
$elem->setAttrib('placeholder', 'Travelling…');
$elem->removeDecorator('Label');
$this->addElement($elem, 'cestovani');
// ################## SECOND COLUMN ###################
// plusy_minusy
$elem = new Zend_Form_Element_Textarea('plusy_minusy');
$elem->addFilter('StringTrim');
$elem->setAttrib('class', 'form-control');
$elem->setAttrib('placeholder', 'Pluses/Minuses…');
$elem->setAttrib('rows', '3');
$elem->removeDecorator('Label');
$this->addElement($elem, 'plusy_minusy');
// zkusenosti_v_tymu
$elem = new Zend_Form_Element_Textarea('zkusenosti_v_tymu');
$elem->addFilter('StringTrim');
$elem->setAttrib('class', 'form-control');
$elem->setAttrib('placeholder', 'Team work experience…');
$elem->setAttrib('rows', '3');
$elem->removeDecorator('Label');
$this->addElement($elem, 'zkusenosti_v_tymu');
// pracovni_misto
$elem = new Zend_Form_Element_Textarea('pracovni_misto');
$elem->addFilter('StringTrim');
$elem->setAttrib('class', 'form-control');
$elem->setAttrib('placeholder', 'Domain/Areas of work…');
$elem->setAttrib('rows', '3');
$elem->removeDecorator('Label');
$this->addElement($elem, 'pracovni_misto');
// knowhow
$elem = new Zend_Form_Element_Textarea('knowhow');
$elem->addFilter('StringTrim');
$elem->setAttrib('class', 'form-control');
$elem->setAttrib('placeholder', 'Skills and technologies…');
$elem->setAttrib('rows', '3');
$elem->removeDecorator('Label');
$this->addElement($elem, 'knowhow');
// dalsi_informace
//.........这里部分代码省略.........