Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

DataObjectManager Module /

Discuss the DataObjectManager module, and the related ImageGallery module.

Moderators: martimiz, UncleCheese, Sean, Ed, biapar, Willr, Ingo, swaiba

SimpleTinyMCE field not working--javascript problem

Go to End

2 Posts   1309 Views


Community Member, 103 Posts

7 March 2011 at 4:03am

My SimpleTinyMCEField has no buttons. I'm getting a JS error in firebug that points to '$(function(){' in this script:

<script type="text/javascript">//<![CDATA[

$(function() {
             plugins : 'safari,paste',
             theme : 'advanced',
          theme_advanced_buttons1 : 'bold,italic,underline,|,justifyleft,justifycenter,justifyright,|,styleselect,formatselect',theme_advanced_buttons2 : 'cut,copy,paste,pastetext,pasteword,|,bullist,numlist,|,link,unlink,anchor,image,|,code',theme_advanced_buttons3 : '',theme_advanced_buttons4 : '',   
          theme_advanced_toolbar_location : 'top',
       theme_advanced_toolbar_align : 'left',
       theme_advanced_statusbar_location : 'bottom',
       theme_advanced_resizing : false,
paste_auto_cleanup_on_paste : true,
paste_remove_spans: true,
paste_remove_styles: true,       
          content_css : ''


I'm not sure how to fix this--I have no custom JS in the CMS here, it's all SS (2.4.5) and DOM (using r540)
Nothing jumps out at me immediately here except that it mentions 'safari' and I'm using firefox. It is on a mac though.
Any ideas? Thanks!


Community Member, 9 Posts

12 March 2011 at 1:13am

Edited: 12/03/2011 1:14am

Hi theoldlr,

I've come across the same problem this morning, so I decided to share my simple solution:

The problem is, that sometimes not only jQuery but also prototype is included in the CMS, but both libraries are using the '$'-sign for different things, so the simple solution is to replace

$(function() { 

jQuery(function($) {

in line 186 in SimpleTinyMCEField.php
and you should have your SimpleTinyMCEField working... :)

@UncleCheese: I've attached a patch for this, maybe it would be useful to include this in dom's trunk...