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


PHP Zend_Form_Element_Textarea::__construct方法代码示例

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


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

示例1: __construct

 public function __construct($spec, $options = array())
 {
     $options = array_merge($options, array('disableLoadDefaultDecorators' => true));
     parent::__construct($spec, $options);
     $this->_decorator = new Monkeys_Form_Decorator_Composite();
     $this->addDecorator($this->_decorator);
 }
开发者ID:sdgdsffdsfff,项目名称:auth-center,代码行数:7,代码来源:Textarea.php

示例2: __construct

 /**
  * Constructor
  *
  * $spec may be:
  * - string: name of element
  * - array: options with which to configure element
  * - \Zend_Config: \Zend_Config with options for configuring element
  *
  * @param  string|array|\Zend_Config $spec
  * @param  array|\Zend_Config $options
  * @return void
  * @throws \Zend_Form_Exception if no element name after initialization
  */
 public function __construct($spec, $options = null)
 {
     parent::__construct($spec, $options);
     if (\MUtil_Bootstrap::enabled()) {
         $this->addClass($this->_elementClass);
     }
 }
开发者ID:GemsTracker,项目名称:gemstracker-library,代码行数:20,代码来源:CKEditor.php

示例3: __construct

 public function __construct($spec, $aOptions = array())
 {
     if (isset($aOptions['ajax'])) {
         $this->_ajax = $aOptions['ajax'];
         unset($aOptions['ajax']);
     }
     if (!$this->getAttrib('cols')) {
         $this->setAttribs(array('cols' => 50, 'rows' => 5));
     }
     parent::__construct($spec, $aOptions);
 }
开发者ID:netixx,项目名称:Stock,代码行数:11,代码来源:TextArea.php

示例4: __construct

 public function __construct($spec, $options = null)
 {
     parent::__construct($spec, $options);
     //grab a reference to the view rendering the form element
     $view = $this->getView();
     //include scripts and initialize the ckeditor
     $view->headScript()->appendFile('/golive_theme/neon_theme/js/ckeditor/ckeditor.js', 'text/javascript');
     $_SESSION['KCFINDER']['uploadURL'] = $view->baseUrl("/uploads/");
     //give the textarea a class name that ckeditor recognises
     $this->setAttrib('class', 'ckeditor');
 }
开发者ID:zelimirus,项目名称:yard,代码行数:11,代码来源:CKEditor.php

示例5: __construct

 public function __construct($spec = null, $options = null, $required = false)
 {
     parent::__construct($spec, $options);
     $this->setLabel($options['label'])->setRequired($required);
     if (isset($options['style'])) {
         $this->setAttrib('style', $options['style']);
     }
     if ($required && isset($options['notEmptyErrorMessage'])) {
         $this->addValidator('NotEmpty', false, array('messages' => $options['notEmptyErrorMessage']));
     }
     if (isset($options['removeDecorators'])) {
         $this->removeDecorator('HtmlTag')->removeDecorator('Label');
     } else {
         $this->setDecorators(array(new vkNgine_Form_Element_Decorator_Text()));
     }
 }
开发者ID:AlexanderMazaletskiy,项目名称:gym-Tracker-App,代码行数:16,代码来源:Textarea.php

示例6: __construct

    /**
     * Constructor
     *
     * $spec may be:
     * - string: name of element
     * - array: options with which to configure element
     * - Zend_Config: Zend_Config with options for configuring element
     *
     * @param  string|array|Zend_Config $spec
     * @return void
     * @throws Zend_Form_Exception if no element name after initialization
     */
    public function __construct($spec, $options = null)
    {
        parent::__construct($spec, $options);
        if (!empty($options['mode'])) {
            $this->_mode = $options['mode'];
        }
        $fc = Zend_Controller_Front::getInstance();
        $this->_request = $fc->getRequest();
        if (null === $this->_view) {
            $this->setView($this->getView());
        }
        $_id = $this->getId();
        if (!empty($options['subFormID'])) {
            $_id = $options['subFormID'] . "-" . $_id;
        }
        $_lang = Zend_Registry::get('languageID') == 1 ? 'fr' : 'en';
        $_cssPath = Zend_Registry::get('www_root') . '/themes/default/css/integration.css';
        $mediaPath = Zend_Registry::get('www_root') . "/data/images/lists/media_list.js";
        $this->_script = <<<EOS

            tinyMCE.init({
                // General options
                relative_urls : false,
                remove_script_host : true,
                doctype: "<!DOCTYPE html>",

                extended_valid_elements : "iframe[src|width|height|name|align|frameborder|marginheight|marginwidth]",
                extended_valid_elements : "a[href|charset|coords|hreflang|class|data-show-count|name|rel|rev|shape|target|title]",
                //cleanup : false,

                mode : "exact",
                elements : "{$_id}",
                theme : "{$this->_mode}",
                plugins : "imagemanager, filemanager,safari,pagebreak,style,layer,table,save,advhr,advimage,advlink,emotions,iespell,inlinepopups,insertdatetime,preview,media,searchreplace,print,contextmenu,paste,directionality,fullscreen,noneditable,visualchars,nonbreaking,xhtmlxtras,template",
                language : "{$_lang}",
                paste_text_use_dialog : true,

                 // Theme options
                theme_advanced_buttons1 : "bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,|,styleselect,formatselect,fontsizeselect,|,forecolor,backcolor",
                theme_advanced_buttons2 : "cut,copy,paste,pastetext,pasteword,|,search,replace,|,bullist,numlist,|,outdent,indent,blockquote,|,undo,redo,|,link,unlink,anchor,image,cleanup,code,|,insertdate,inserttime",
                theme_advanced_buttons3 : "tablecontrols,|,hr,removeformat,visualaid,|,sub,sup,|,charmap,media,advhr,|,print,fullscreen",
                theme_advanced_buttons4 : "cite,abbr,acronym,del,ins,|,visualchars,nonbreaking,pagebreak",
                theme_advanced_toolbar_location : "top",
                theme_advanced_toolbar_align : "left",
                theme_advanced_statusbar_location : "bottom",
                theme_advanced_resizing : false,

                // Style formats
                style_formats : [
                        {title : 'Bold text', inline : 'b'},
                        {title : 'Red text', inline : 'span', styles : {color : '#ff0000'}},
                        {title : 'Header styles'},
                        {title : 'Red header', block : 'h1', styles : {color : '#ff0000'}},
                        {title : 'Example 1', block : 'span', classes : 'example1'},
                        {title : 'Example 2', inline : 'span', classes : 'example2'},
                        {title : 'Table styles'},
                        {title : 'Table row 1', selector : 'tr', classes : 'tablerow1'},
                        {title : 'Images'},
                        {title : 'Agrandissement photo', selector : 'img', classes : 'add_prettyphoto'},
                        {title : 'Bouton'},
                        {title : 'Bouton lien', block : 'div', classes : 'grayish-button2'}
                ],

                formats : {
                        alignleft : {selector : 'p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img', classes : 'left'},
                        aligncenter : {selector : 'p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img', classes : 'center'},
                        alignright : {selector : 'p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img', classes : 'right'},
                        alignfull : {selector : 'p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img', classes : 'full'},
                        bold : {inline : 'span', 'classes' : 'bold'},
                        italic : {inline : 'span', 'classes' : 'italic'},
                        underline : {inline : 'span', 'classes' : 'underline', exact : true},
                        strikethrough : {inline : 'del'},
                        customformat : {inline : 'span', styles : {color : '#00ff00', fontSize : '20px'}, attributes : {title : 'My custom format'}}
                },

                // Example content CSS (should be your site CSS)
                content_css : "{$_cssPath}",
                theme_advanced_styles : "",
                theme_advanced_blockformats : "p,h2,h3",

                // Drop lists for link/image/media/template dialogs
                template_external_list_url : "lists/template_list.js",
                external_link_list_url : "lists/link_list.js",
                external_image_list_url : "lists/image_list.js",
                media_external_list_url : "{$mediaPath}"
            });
EOS;
        if ($this->_request->isXmlHttpRequest()) {
//.........这里部分代码省略.........
开发者ID:anunay,项目名称:stentors,代码行数:101,代码来源:Editor.php

示例7: __construct

 /**
  * Constructor
  *
  * $spec may be:
  * - string: name of element
  * - array: options with which to configure element
  * - \Zend_Config: \Zend_Config with options for configuring element
  *
  * @param  string|array|\Zend_Config $spec
  * @param  array|\Zend_Config $options
  * @return void
  * @throws \Zend_Form_Exception if no element name after initialization
  */
 public function __construct($spec, $options = null)
 {
     parent::__construct($spec, $options);
     $this->addClass($this->_elementClass);
 }
开发者ID:GemsTracker,项目名称:MUtil,代码行数:18,代码来源:Textarea.php


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