Hi,
Thanks for you'r good module,
I use TinyMCE module and recently nodewords, when i edit a node, and want set the meta tags my textarea have a tinyMCE structure.. But description can't have HTML Tags, so he's not logic to purpose that..
When you see the source code of the textarea, we can see "class="mceEditorContainer", please can you remove it ?

Comments

tdimg’s picture

This is tinyMCE's doing and not Meta-Tag's. But the tinyMCE module gave the user/theme developer the power to do something about it.

So, you need to remove it yourself: Open the tinyMCE readme.txt file, look for the function theme_tinymce_theme, copy it in your theme's template.php file, change the function name to phptemplate_tinymce_theme, find out the ID of the textarea you want to have tinyMCE disabled and add that ID in the function similar to those just listed below the comment "Disable tinymce for these textareas"

so it may then look like:

    // Disable tinymce for these textareas
    case 'META-TAG-TEXTAREA':
    case 'log': // book and page log
    case 'img_assist_pages':
    case 'caption': // signature
    case 'pages':
    case 'access_pages': //TinyMCE profile settings.
    case 'user_mail_welcome_body': // user config settings
    case 'user_mail_approval_body': // user config settings
    case 'user_mail_pass_body': // user config settings
    case 'synonyms': // taxonomy terms
    case 'description': // taxonomy terms
Robrecht Jacques’s picture

Category: feature » support

Like c2uk says: it is tinyMCE that adds the class, not nodewords/meta tags. If I knew a way for this module to tell tinyMCE not to do that, I would avoid it. Unfortunately I don't.

Setting it as a "support request".

seanburlington’s picture

thanks for that - it pointed me in the right direction

short note for anyone else who googles their way here:

the text-area name is 'nodewords-description' - so the function should start like:

function phptemplate_tinymce_theme($init, $textarea_name, $theme_name, $is_running) {
  switch ($textarea_name) {
  	// Disable tinymce for these textareas
  	case 'nodewords-description': // meta tags description

Sean Burlington
www.practicalweb.co.uk
London

Riccardo83’s picture

I always get this error

Parse error: syntax error, unexpected $end in /home/riccardo/public_html/jbsoulscan.com/sites/all/themes/thirteen/template.php on line 6

What can I do about it?

Riccardo83’s picture

Got it working nevermind, was my FTP programs fault transfering the files wrong...

berenddeboer’s picture

Answer #3 has the wrong example, it will completely disable TinyMCE. This is the function I put in my template.php that works fine:

function phptemplate_tinymce_theme($init, $textarea_name, $theme_name, $is_running) {
  switch ($textarea_name) {
    // Disable tinymce for these textareas
  case 'nodewords-description': // meta tags description
    unset($init);
    break;
  }
  // Always return $init
  return $init;
}
tdimg’s picture

Answer #3 isn't wrong, mind the following text prior to the code:

so the function should start like:

And the function meant is the one given in the readme (as you can figure out by reading the previous responses). This function has exactly the same code as yours, except that the function from the readme also provides a means of assigning the simple theme to certain textareas and adding extra features to the advanced theme.

All answer #3 does is providing the correct textarea name to put in the function given in the readme file of tinyMCE.

Robrecht Jacques’s picture

Status: Active » Closed (works as designed)

Instructions added to README.txt in 5.x-1.10 (released later today). Setting it as "by design" (the design of tinymce).