Using Wysiwyg 6.x-2.0 my admin/settings/wysiwyg page has

Filtered HTML    TinyMCE 3.2.4.1	Edit	Remove
Full HTML       TinyMCE 3.2.4.1	Edit	Remove
PHP code       no editor

When I attempt create (or edit) a page I see no Rich Text editor. There is the link Disable rich-text and when I click on it I see:

Drupal.wysiwyg.instances[params.field] is undefined
http://yoursite.co.uk/sites/all/modules/contrib/wysiwyg/wysiwyg.js?L
Line 162
 Drupal.wysiwyg.instances[params.field].editor = 'none';

Something is wrong here. :(

Comments

hershel’s picture

I now installed FCKeditor 2.6.4 and the editor works. Clicking the Disable rich-text gives the same error, but it works--both disabling and enabling work.

The error is not precisely the same actually. Now it's:

Drupal.wysiwyg.instances[params.field] is undefined
var editor = Drupal.wysiwyg.instances[params.field].editor;

on line wysiwyg.js?L (line 128) whereas the error with TinyMCE is on line 162. Both errors appear actually, at different times.

twod’s picture

That's a bit odd, looks like the editor instance parameters were not registered by Wysiwyg API when the editor was attached.
Do you have any other modules which change things on the edit node page, or which runs a lot of JavaScripts?

Have you tried disabling all buttons and plugins? That should return the editor to the default toolbar in which it should always work.

If you have the Firebug extension for Firefox, could you please put a breakpoint right on the line where the error is, and reload the page.
That should stop script execution there so you can see what the value of params is at that moment.
You could of course also edit the file and insert some code to alert/print out the variable. But it's supposed to be an object with several properties so it's easier to set a breakpoint and use Firebug's watch feature.

twod’s picture

Status: Active » Postponed (maintainer needs more info)

I'd like to figure this out as soon as possible but I'm afraid I can't do much without more info.

hershel’s picture

Sorry didn't see your comments til now. Now that I have FCKeditor on the site, if I enable TinyMCE, nothing happens--no error yet also no tinymce. Just a regular textarea.

If you want to examine the site in question, email me offline.

twod’s picture

I'll send you an email when I get back home after the weekend.
Until then I've got some more questions and I need to repeat some.

Do you use a custom theme? If so, does it print out the contents of the PHP variables correctly so all scripts are included (see FAQ)?

Have you tried with Garland and disabling all the buttons/plugins?

Which exact version(s) of TinyMCE did you test with?

Was it working with an earlier version of Wysiwyg module?

hershel’s picture

Using zen subtheme. Of course all scripts are included. Otherwise FCK wouldn't work. :)

> Have you tried with Garland and disabling all the buttons/plugins?

No.

> Which exact version(s) of TinyMCE did you test with?

The latest download from their site, as of last week.

> Was it working with an earlier version of Wysiwyg module?

On other sites yes, I believe so. This is a brand new site, so no, not here.

sun’s picture

Then please test with Garland first.

hershel’s picture

Using Garland and TinyMCE has no buttons nor plugins enabled. I disabled these modules:

Nice Menus
Thickbox
Hierarchical Select Taxonomy
Hierarchical Select

just in case. Still FCK works fine and TinyMCE doesn't work. Now however I don't see an error--it just doesn't work--nothing happens. Behavior is the same with Garland or my Zen sub-theme.

If I browse to /sites/all/libraries/tinymce/jscripts/tiny_mce/tiny_mce.js I see

var tinymce={majorVersion:"3",minorVersion:"2.4.1",releaseDate:"2009-05-25"

sun’s picture

Status: Postponed (maintainer needs more info) » Closed (won't fix)

It seems you are the only one who is able to replicate this issue, so I can only guess that you have some other, conflicting modules installed.

Sorry, without further information this issue can only be marked as won't fix.

Feel free to re-open this issue if you want to provide further information. Thanks.

haggins’s picture

Version: 6.x-2.0 » 6.x-2.x-dev
Status: Closed (won't fix) » Active

I've got exactly the same issue. There's a fresh drupal 6.19 installation with only Wysiwyg module enabled and TinyMCE doesn't show up. Only the "Disable rich-text" link is shown.

haggins’s picture

Ha! Got it! It's because WYSIWYG settings page provides selection of many languages that aren't really available. So i choose "de" and got a lot of log entries like this one:

Typ	page not found
Datum	Sonntag, 5. Dezember 2010 - 19:57
Benutzer	admin
Ort	http://localhost/test/sites/all/libraries/tinymce/jscripts/tiny_mce/themes/advanced/langs/de.js?p
Referrer	http://localhost/test/node/add/page
Typ	page not found
Datum	Sonntag, 5. Dezember 2010 - 19:57
Benutzer	admin
Ort	http://localhost/test/sites/all/libraries/tinymce/jscripts/tiny_mce/langs/de.js?p
Referrer	http://localhost/test/node/add/page
Nachricht	sites/all/libraries/tinymce/jscripts/tiny_mce/langs/de.js

Maybe the ui should only provide a selection of installed languages?

edit: closing this issue again since there is already an issue about limiting language selection: #362318: Limit wysiwyg language selection to available languages

haggins’s picture

Status: Active » Closed (works as designed)