public function createBodyElement($name, $label, $required = false, $hidden = false, $mailFields = array(), $mailFieldsLabel = false) {
        if ($hidden) {
            return new \Zend_Form_Element_Hidden($name);
        }

        $options['required'] = $required;
        $options['label']    = $label;

        $mailBody                            = new \Gems_Form_Element_CKEditor($name, $options);
        $mailBody->config['availablefields'] = $mailFields;
        if ($mailFieldsLabel) {
            $mailBody->config['availablefieldsLabel'] = $mailFieldsLabel;
        } else {
            $mailBody->config['availablefieldsLabel'] = $this->translate->_('Fields');
        }

        $mailBody->config['extraPlugins'] .= ',availablefields';
        $mailBody->config['toolbar'][]    = array('availablefields');

        return new \Gems_Form_Element_CKEditor($name, $options);
    }
public function createBodyElement($name, $label, $required = false, $hidden = false, $mailFields = array(), $mailFieldsLabel = false) {
        if ($hidden) {
            return new \Zend_Form_Element_Hidden($name);
        }

        $options['required'] = $required;
        $options['label']    = $label;

        $mailBody                            = new \Gems_Form_Element_CKEditor($name, $options);
        $mailBody->config['availablefields'] = $mailFields;
        if ($mailFieldsLabel) {
            $mailBody->config['availablefieldsLabel'] = $mailFieldsLabel;
        } else {
            $mailBody->config['availablefieldsLabel'] = $this->translate->_('Fields');
        }

        $mailBody->config['extraPlugins'] .= ',availablefields';
        $mailBody->config['toolbar'][]    = array('availablefields');

        return new \Gems_Form_Element_CKEditor($name, $options);
    }
public function createBodyElement ( $ name , $ label , $ required = false , $ hidden = false , $ mailFields = array ( ) , $ mailFieldsLabel = false ) { if ( $ hidden ) { return new \ Zend_Form_Element_Hidden ( $ name ) ; } $ options [ 'required' ] = $ required ; $ options [ 'label' ] = $ label ; $ mailBody = new \ Gems_Form_Element_CKEditor ( $ name , $ options ) ; $ mailBody -> config [ 'availablefields' ] = $ mailFields ; if ( $ mailFieldsLabel ) { $ mailBody -> config [ 'availablefieldsLabel' ] = $ mailFieldsLabel ; } else { $ mailBody -> config [ 'availablefieldsLabel' ] = $ this -> translate -> _ ( 'Fields' ) ; } $ mailBody -> config [ 'extraPlugins' ] .= ',availablefields' ; $ mailBody -> config [ 'toolbar' ] [ ] = array ( 'availablefields' ) ; return new \ Gems_Form_Element_CKEditor ( $ name , $ options ) ; }
Create an HTML Body element with CKEditor


@return \Gems_Form_Element_CKEditor|\Zend_Form_Element_Hidden
Create an HTML Body element with CKEditor