TinyMCE - "Use WYSIWYG editor" wrong checkbox state
TinyMCE - "Use WYSIWYG editor" wrong checkbox state
This is something I've struck a few times and I haven't been able to trace the cause. When loading a page in admin that uses a WYSIWYG (but not necessarily in the "Pages" section), TinyMCE loads in the disabled state despite the "Use WYSIWYG editor" checkbox being checked. Unchecking the checkbox then activates TinyMCE.
Does anyone know what causes the checkbox to get out-of-sync with TinyMCE's active/inactive state like this? Is there a trick to fixing it?
Does anyone know what causes the checkbox to get out-of-sync with TinyMCE's active/inactive state like this? Is there a trick to fixing it?
Re: TinyMCE - "Use WYSIWYG editor" wrong checkbox state
Some more info on this frustrating issue...
It seems that there is some sort of interference going on between the active/inactive state of TinyMCE in the "Pages" section of CMSMS and the state of TinyMCE in modules (e.g. ListIt2, FormBuilder). The state in one section reverses the state in the other. For example:
If TinyMCE is incorrectly inactive in a ListIt2 instance, I can do a hard refresh in my browser and and TinyMCE will render properly (active). But now if I open a page for editing in Pages, TinyMCE will be incorrectly inactive. Do a hard refresh here and TinyMCE is back for Pages, but now inactive in ListIt2, and so on.
I've tried everything I can think of: cleared browser cache, cleared cookies, cleared CMSMS cache, logged out then in again, uninstalled and reinstalled TinyMCE... the problem remains.
It seems that there is some sort of interference going on between the active/inactive state of TinyMCE in the "Pages" section of CMSMS and the state of TinyMCE in modules (e.g. ListIt2, FormBuilder). The state in one section reverses the state in the other. For example:
If TinyMCE is incorrectly inactive in a ListIt2 instance, I can do a hard refresh in my browser and and TinyMCE will render properly (active). But now if I open a page for editing in Pages, TinyMCE will be incorrectly inactive. Do a hard refresh here and TinyMCE is back for Pages, but now inactive in ListIt2, and so on.
I've tried everything I can think of: cleared browser cache, cleared cookies, cleared CMSMS cache, logged out then in again, uninstalled and reinstalled TinyMCE... the problem remains.
Re: TinyMCE - "Use WYSIWYG editor" wrong checkbox state
Getting closer to understanding what's going on here...
Each admin page that has a WYSIWYG calls a javascript file to initialise TinyMCE, e.g. http://mydomain.com/admin/moduleinterface.php?mact=TinyMCE,fp_,tinyconfig,0&_sx_=72d01911&fp_templateid=24&fp_languageid=en&showtemplate=false
The problem is that this file is being cached by the browser when it should never be cached. I compared the headers of the files on a working CMSMS site and my problem site.
Working site:
Problem site:
The key difference is the Cache-Control field.
Can anyone advise me where the setting for the Cache-Control header field is set for this file? Any ideas why the field would end up set incorrectly?
Each admin page that has a WYSIWYG calls a javascript file to initialise TinyMCE, e.g. http://mydomain.com/admin/moduleinterface.php?mact=TinyMCE,fp_,tinyconfig,0&_sx_=72d01911&fp_templateid=24&fp_languageid=en&showtemplate=false
The problem is that this file is being cached by the browser when it should never be cached. I compared the headers of the files on a working CMSMS site and my problem site.
Working site:
Code: Select all
Key: http://workingsite.com/admin/moduleinterface.php?mact=TinyMCE,fp_,tinyconfig,0&_sx_=72d01911&fp_templateid=24&fp_languageid=en&showtemplate=false
Data Size: 20175 bytes
Fetch Count: 3
Last Modified: Thursday, 21 August 2014 12:43:16 p.m.
Last Fetched: Thursday, 21 August 2014 12:43:26 p.m.
Expiration Time: Thursday, 1 January 1970 1:00:00 p.m.
File on disk: none
request-method: GET
request-User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:31.0) Gecko/20100101 Firefox/31.0
response-head: HTTP/1.1 200 OK
Date: Thu, 21 Aug 2014 00:43:15 GMT
Server: Apache
X-Powered-By: PHP/5.3.27
Expires: Mon, 26 Jul 1997 05:00:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Last-Modified: Thu, 21 Aug 2014 00:43:15 GMT
X-Frame-Options: SAMEORIGIN
Vary: User-Agent
Content-Type: text/javascript; charset=utf-8
Code: Select all
Key: http://problemsite.com/admin/moduleinterface.php?mact=TinyMCE,fp_,tinyconfig,0&_sx_=6ed9b2dd06387de5&fp_templateid=24&fp_languageid=en&showtemplate=false
Data Size: 20624 bytes
Fetch Count: 3
Last Modified: Thursday, 21 August 2014 12:12:41 p.m.
Last Fetched: Thursday, 21 August 2014 12:13:05 p.m.
Expiration Time: Thursday, 1 January 1970 1:00:00 p.m.
File on disk: D:\_IN USE\Firefox\Cache\D\61\CF024d01
request-method: GET
request-User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:31.0) Gecko/20100101 Firefox/31.0
response-head: HTTP/1.1 200 OK
Date: Thu, 21 Aug 2014 00:12:40 GMT
Server: Apache
X-Powered-By: PHP/5.3.27
Pragma: no-cache
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: private, max-age=10800, pre-check=10800
Last-Modified: Sat, 02 Aug 2014 16:59:36 GMT
X-Frame-Options: SAMEORIGIN
Vary: User-Agent
Content-Type: text/javascript; charset=utf-8
Can anyone advise me where the setting for the Cache-Control header field is set for this file? Any ideas why the field would end up set incorrectly?
Re: TinyMCE - "Use WYSIWYG editor" wrong checkbox state
I have the same problem. I tried uninstalling TinyMCE removing and reinstalling but is still out of sync. (cmsms 1.11.11)If you have a solution please post.
Keith
Update: this has now cleared (24 hours) an is OK I did not clear cache on original problem... suspect cache problem
K
Keith
Update: this has now cleared (24 hours) an is OK I did not clear cache on original problem... suspect cache problem
K
Re: TinyMCE - "Use WYSIWYG editor" wrong checkbox state
For what it's worth, I had another post in this thread explaining the source of my problem and a fix, but this post was deleted by processes or persons unknown.
This has happened a few times in this forum. I don't know if it's a bug in the forum software or a moderator unilaterally deleting posts without explanation but in either case it's frustrating.
See this bug report for more information on the TinyMCE error: http://dev.cmsmadesimple.org/bug/view/10170
This has happened a few times in this forum. I don't know if it's a bug in the forum software or a moderator unilaterally deleting posts without explanation but in either case it's frustrating.
See this bug report for more information on the TinyMCE error: http://dev.cmsmadesimple.org/bug/view/10170
Re: TinyMCE - "Use WYSIWYG editor" wrong checkbox state
I have been having the same issue with TinyMCE on CMSMS 1.11.11 sites. I have 3 sites in development with the same issue. 2 other sites with (almost) identical modules installed are still on 1.11.10 are not showing this issue.
This definitely appears to be a caching issue within the admin area.
I have seen the WYSIWYG start in the wrong state (html) in Page templates using the multiple {content} blocks, in CustomGS and in ListIt2 modules that use the TinyMCE WYSIWYG.
Great to read that a Ctrl+F5 clears the issue as that is a nice quick fix... Although if I reset the WYSIWYG on the CustomGS page it is then inverted when editing a page template content block. :/
This issue does not appear to occur with MicroTiny set as the WYSIWYG. But then it also doesn't happen with TinyMCE prior to CMSMS 1.11.11.
I have also noticed that when changing config of TinyMCE, e.g. adding toolbar/table options, the WYSIWYG (including test area) are not updated until you logout or Ctrl+F5.
Will continue searching for a fix and hope someone clever does sooner.
System Information:
----------------------------------------------
Cms Version: 1.11.11
Installed Modules:
CMSMailer: 5.2.2
CMSPrinting: 1.0.5
FileManager: 1.4.5
MenuManager: 1.8.6
CGExtensions: 1.41.2
ModuleManager: 1.5.8
News: 2.14.4
ThemeManager: 1.1.8
CGSimpleSmarty: 1.7.4
Captcha: 0.4.6
CGFeedback: 1.6.5
CGSmartImage: 1.16.2
FormBuilder: 0.7.3
Gallery: 2.0.1
SiteMapMadeSimple: 1.2.8
CustomGS: 2.1
ECB: 1.6
GBFilePicker: 1.3.3
ListIt2: 1.4.1
TinyMCE: 2.9.12
CGFeedMaker: 1.0.20
TemplateExternalizer: 2.1.3
ListIt2XDefs: 1.2
ListIt2Widgets: 1.4.1
JQueryTools: 1.2.6
MicroTiny: 1.2.7
TagCloud: 1.0.2
Search: 1.7.11
CGGoogleMaps2: 0.99
Config Information:
php_memory_limit:
process_whole_template:
max_upload_size: 32000000
url_rewriting: mod_rewrite
page_extension: .html
query_var: page
image_manipulation_prog: GD
auto_alias_content: true
locale:
default_encoding: utf-8
admin_encoding: utf-8
set_names: true
Php Information:
phpversion: 5.4.31
md5_function: On (True)
gd_version: 2
tempnam_function: On (True)
magic_quotes_runtime: Off (False)
E_STRICT: 0
E_DEPRECATED: 0
memory_limit: 128M
max_execution_time: 120
output_buffering: 1
safe_mode: Off (False)
file_uploads: On (True)
post_max_size: 32M
upload_max_filesize: 32M
session_save_path: /tmp (1777)
session_use_cookies: On (True)
xml_function: On (True)
xmlreader_class: On (True)
Server Information:
Server Api: cgi-fcgi
Server Db Type: MySQL (mysqli)
Server Db Version: 5.1.68
Server Db Grants: Could not find a suitable "GRANT ALL" permission. This may mean you could have problems installing or removing modules. Or even adding and deleting items, including pages
Server Time Diff: No filesystem time difference found
----------------------------------------------
This definitely appears to be a caching issue within the admin area.
I have seen the WYSIWYG start in the wrong state (html) in Page templates using the multiple {content} blocks, in CustomGS and in ListIt2 modules that use the TinyMCE WYSIWYG.
Great to read that a Ctrl+F5 clears the issue as that is a nice quick fix... Although if I reset the WYSIWYG on the CustomGS page it is then inverted when editing a page template content block. :/
This issue does not appear to occur with MicroTiny set as the WYSIWYG. But then it also doesn't happen with TinyMCE prior to CMSMS 1.11.11.
I have also noticed that when changing config of TinyMCE, e.g. adding toolbar/table options, the WYSIWYG (including test area) are not updated until you logout or Ctrl+F5.
Will continue searching for a fix and hope someone clever does sooner.

System Information:
----------------------------------------------
Cms Version: 1.11.11
Installed Modules:
CMSMailer: 5.2.2
CMSPrinting: 1.0.5
FileManager: 1.4.5
MenuManager: 1.8.6
CGExtensions: 1.41.2
ModuleManager: 1.5.8
News: 2.14.4
ThemeManager: 1.1.8
CGSimpleSmarty: 1.7.4
Captcha: 0.4.6
CGFeedback: 1.6.5
CGSmartImage: 1.16.2
FormBuilder: 0.7.3
Gallery: 2.0.1
SiteMapMadeSimple: 1.2.8
CustomGS: 2.1
ECB: 1.6
GBFilePicker: 1.3.3
ListIt2: 1.4.1
TinyMCE: 2.9.12
CGFeedMaker: 1.0.20
TemplateExternalizer: 2.1.3
ListIt2XDefs: 1.2
ListIt2Widgets: 1.4.1
JQueryTools: 1.2.6
MicroTiny: 1.2.7
TagCloud: 1.0.2
Search: 1.7.11
CGGoogleMaps2: 0.99
Config Information:
php_memory_limit:
process_whole_template:
max_upload_size: 32000000
url_rewriting: mod_rewrite
page_extension: .html
query_var: page
image_manipulation_prog: GD
auto_alias_content: true
locale:
default_encoding: utf-8
admin_encoding: utf-8
set_names: true
Php Information:
phpversion: 5.4.31
md5_function: On (True)
gd_version: 2
tempnam_function: On (True)
magic_quotes_runtime: Off (False)
E_STRICT: 0
E_DEPRECATED: 0
memory_limit: 128M
max_execution_time: 120
output_buffering: 1
safe_mode: Off (False)
file_uploads: On (True)
post_max_size: 32M
upload_max_filesize: 32M
session_save_path: /tmp (1777)
session_use_cookies: On (True)
xml_function: On (True)
xmlreader_class: On (True)
Server Information:
Server Api: cgi-fcgi
Server Db Type: MySQL (mysqli)
Server Db Version: 5.1.68
Server Db Grants: Could not find a suitable "GRANT ALL" permission. This may mean you could have problems installing or removing modules. Or even adding and deleting items, including pages
Server Time Diff: No filesystem time difference found
----------------------------------------------
Re: TinyMCE - "Use WYSIWYG editor" wrong checkbox state
@chrisbt
Until this is fixed in the CMSMS core, the solution is to edit the file
[... removed by moderator ...]
...and I think you'll find that solves the TinyMCE problem.
Until this is fixed in the CMSMS core, the solution is to edit the file
[... removed by moderator ...]
...and I think you'll find that solves the TinyMCE problem.
Last edited by Jo Morg on Wed Sep 10, 2014 9:45 pm, edited 2 times in total.
Reason: No code hacking posts allowed, please read forum rules... thanks
Reason: No code hacking posts allowed, please read forum rules... thanks
Re: TinyMCE - "Use WYSIWYG editor" wrong checkbox state
Many thanks. I'll give that a try. You might want to subtly revise your post before the admins wack it out, as the is a rule about no core hacks in the forum.
Re: TinyMCE - "Use WYSIWYG editor" wrong checkbox state
Okay, for anyone else wanting the fix, see the bug report linked in my earlier post.
Re: TinyMCE - "Use WYSIWYG editor" wrong checkbox state
Worked perfectly - many thanks.
Re: TinyMCE - "Use WYSIWYG editor" wrong checkbox state
I don't believe this is a CMSMS problem but a tiny issue, I've had this happen on a lesser version, I set tiny to not start on page load for me on most which set the check box to the correct state and didn't notice it till I changed to start on page load...
- paulbaker
- Dev Team Member
- Posts: 1465
- Joined: Sat Apr 18, 2009 10:09 pm
- Location: Maidenhead, UK
- Contact:
Re: TinyMCE - "Use WYSIWYG editor" wrong checkbox state
The same issue detailed in Cerulean's first post happens with a 1.11.11 site when going to create a new blog in CGBlog.
The solution in the linked bug report further down the thread solves the problem for me.
I have never seen this issue in older versions of CMSMS despite using TinyMCE in most installations.
Here's the full spec of the site in question:
----------------------------------------------
Cms Version: 1.11.11
Installed Modules:
CMSMailer: 5.2.2
CMSPrinting: 1.0.5
FileManager: 1.4.5
MenuManager: 1.8.6
MicroTiny: 1.2.7
ModuleManager: 1.5.8
News: 2.14.4
Search: 1.7.11
ThemeManager: 1.1.8
Archiver: 0.2.6
SEOTools2: 1.2.1
TinyMCE: 2.9.12
Showtime: 3.4
FormBuilder: 0.7.3
CGExtensions: 1.41.2
CGSimpleSmarty: 1.7.4
JQueryTools: 1.2.6
CGBlog: 1.12.6
Config Information:
php_memory_limit:
process_whole_template:
max_upload_size: 32000000
url_rewriting: none
page_extension:
query_var: page
image_manipulation_prog: GD
auto_alias_content: true
locale:
default_encoding: utf-8
admin_encoding: utf-8
set_names: true
Php Information:
phpversion: 5.4.21
md5_function: On (True)
gd_version: 2
tempnam_function: On (True)
magic_quotes_runtime: Off (False)
E_STRICT: 0
E_DEPRECATED: 0
memory_limit: 128M
max_execution_time: 120
output_buffering: 4096
safe_mode: Off (False)
file_uploads: On (True)
post_max_size: 8M
upload_max_filesize: 32M
session_save_path: /tmp (1777)
session_use_cookies: On (True)
xml_function: On (True)
xmlreader_class: On (True)
Server Information:
Server Api: cgi-fcgi
Server Db Type: MySQL (mysqli)
Server Db Version: 5.1.73
Server Db Grants: Found a "GRANT ALL" statement that appears to be suitable
Server Time Diff: No filesystem time difference found
----------------------------------------------
The solution in the linked bug report further down the thread solves the problem for me.
I have never seen this issue in older versions of CMSMS despite using TinyMCE in most installations.
Here's the full spec of the site in question:
----------------------------------------------
Cms Version: 1.11.11
Installed Modules:
CMSMailer: 5.2.2
CMSPrinting: 1.0.5
FileManager: 1.4.5
MenuManager: 1.8.6
MicroTiny: 1.2.7
ModuleManager: 1.5.8
News: 2.14.4
Search: 1.7.11
ThemeManager: 1.1.8
Archiver: 0.2.6
SEOTools2: 1.2.1
TinyMCE: 2.9.12
Showtime: 3.4
FormBuilder: 0.7.3
CGExtensions: 1.41.2
CGSimpleSmarty: 1.7.4
JQueryTools: 1.2.6
CGBlog: 1.12.6
Config Information:
php_memory_limit:
process_whole_template:
max_upload_size: 32000000
url_rewriting: none
page_extension:
query_var: page
image_manipulation_prog: GD
auto_alias_content: true
locale:
default_encoding: utf-8
admin_encoding: utf-8
set_names: true
Php Information:
phpversion: 5.4.21
md5_function: On (True)
gd_version: 2
tempnam_function: On (True)
magic_quotes_runtime: Off (False)
E_STRICT: 0
E_DEPRECATED: 0
memory_limit: 128M
max_execution_time: 120
output_buffering: 4096
safe_mode: Off (False)
file_uploads: On (True)
post_max_size: 8M
upload_max_filesize: 32M
session_save_path: /tmp (1777)
session_use_cookies: On (True)
xml_function: On (True)
xmlreader_class: On (True)
Server Information:
Server Api: cgi-fcgi
Server Db Type: MySQL (mysqli)
Server Db Version: 5.1.73
Server Db Grants: Found a "GRANT ALL" statement that appears to be suitable
Server Time Diff: No filesystem time difference found
----------------------------------------------