0

I have a custom form and a textarea in it as follows :

$form['fieldset']['email_template'] = array('#type' => 'textarea',
    '#title' => t('E-mail template content'),
    '#default_value' => '',    
    '#description' => t('A valid template for email trigger.<b> Please type ":" for variable suggestions</b>'),
    '#required' => TRUE,
    '#cols' => 60,
    '#resizable' => TRUE,
    '#rows' => 5,
    //'#type' => 'text_format',
    //'#base_type' => 'textarea',
  );

When i installed the ckeditor module and enabled it , the following text appears under textarea , enter image description here

Then i gave sky:notification/addTemplate.edit-email-template in the visibility settings Fields to exclude/include: after enabling the include option in Use inclusion or exclusion mode:

0

Try adding '#wysiwyg' => TRUE,

Also i think you need to keep '#type' => 'text_format', instead of textarea.

  • When i give '#type' => 'text_format' the textarea get disappearing – Crazyrubixfan Sep 7 '15 at 12:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.