The Teaser button in my ckeditor is missing even though drupalbreaks folder in plugins folder and ckeditor.config.js contains 'DrupalBreak', 'DrupalPageBreak' in menu definitions but there are no actual buttons for that. So, I cannot insert teaser break.

CommentFileSizeAuthor
#10 SNAG-0150.jpg93.25 KBgadzuk

Comments

gadzuk’s picture

Me too. CKEditor 3.0.1. Apparently this is known? #627714: Date for release (comment #5)

I tried copying modules/ckeditor/plugins/* to modules/ckeditor/ckeditor/plugins

In my status report I get this message

CKEditor 3.0.1
Some features are disabled because you're using an older version of CKEditor, please upgrade the editor to CKEditor 3.1 (or higher).

I see the modules/ckeditor/ckeditor.config.js has this line. But there's no version 3.1 of ckeditor available that I can find, the latest is 3.0.1.
I tried editing the two CompareVersion lines to 3.0.1. No joy.

  if (Drupal.ckeditorCompareVersion('3.1')) {
    config.extraPlugins += (config.extraPlugins ? ',drupalbreaks' : 'drupalbreaks' );
  }

Also tried editing modules/ckeditor/ckeditor/config.js, but no luck

CKEDITOR.editorConfig = function( config )
{
        // Define changes to default configuration here. For example:
        // config.language = 'fr';
        // config.uiColor = '#AADC6E';
        config.extraPlugins = 'drupalbreaks';

        this.on( 'pluginsLoaded', function()
        {
                CKEDITOR.config.toolbar_Full.push( [ 'DrupalBreak', 'DrupalPageBreak' ] );
                CKEDITOR.config.toolbar_DrupalFiltered.push( [ 'DrupalBreak', 'DrupalPageBreak' ] );
                CKEDITOR.config.toolbar_DrupalBasic.push( [ 'DrupalBreak', 'DrupalPageBreak' ] );
                CKEDITOR.config.toolbar_DrupalFull.push( [ 'DrupalBreak', 'DrupalPageBreak' ] );
        });

};
mephir’s picture

Prerelease version of ckeditor is to download from main module project page (http://drupal.org/project/ckeditor).

brack11’s picture

Version: 6.x-1.0-beta1 » 6.x-1.x-dev

Tried to download ckeditor 3.1 also upgraded module to 6.x-1.x-dev still no luck

gadzuk’s picture

Just read the above...

Tried it, the break shows now in the editor but no show for the teaser button

brack11’s picture

Ok, moved back to FCKeditor until solution for CKeditor, Unfortunately FCK has problems with Safari 4.0.4 but have to survive with that.

mephir’s picture

Which of toolbars you have enabled? Because on non-Drupal toolbars there isn't drupal break and drupal page break. They are only on DrupalFull and DrupalFiltered. Buttons appear only if replaced textarea have teaser, they don't be showed for example on comment textarea.

wwalc’s picture

@anyone having still this problem with CKEditor 3.1 - can you send me a PM with a link to your Drupal installation where I could see this bug live?

brack11’s picture

@mephir
I was using only drupalfiltered so, there is nothing extra but default setup

brack11’s picture

Priority: Critical » Minor

Weird thing happened, today, after couple of days using fckeditor, i disabled it again and enabled ckeditor instead. The weird thing is that I can see button and break now!!! so I guess the status goes to closed for this topic. I will wait to close it for one more day, in case someone else is struggling with this issue.

gadzuk’s picture

StatusFileSize
new93.25 KB

I'm still having trouble. Downloaded today's dev and the 3.1 SVN version, running DrupalFiltered toolbar. Also tried DrupalFull.

Content that already had the break is showing it fine, but no teaser button. wwalc I'll PM you the site

CinemaSaville’s picture

I'm now having the same issue. Downloaded Dec 17 dev and 3.1 SVN version too. Running DrupalFull toolbar.

No break.

brack11’s picture

I believe this should be more investigated by developers, I have no problem now but I didnt do a thing to solve it, trying to remember maybe I cleared the drupal cache? Could any of you who have this problem try to disable ckeditor, clear cache and then enable ckeditor again, would that help?

CinemaSaville’s picture

Done. Had no effect.

wwalc’s picture

Priority: Minor » Normal

Ok, apparently it seems that the problem is in missing information about teaser break in the page source.
Teaser buttons should appear correctly, if something like that is in the source of your page:

<script type="text/javascript" src="/drupalck/misc/teaser.js?S"></script>

and

"teaser": { "edit-teaser-js": "edit-body" }

(the second line is a part of "jQuery.extend(Drupal.settings,...") and instead of edit-body there might be a different id of the textarea, but anyway something like that should be there).

Information about teaser is added by theme_textarea() function in includes/form.inc
The question is - are you perhaps using a custom theme or module that overrides this behavior? Could you try investigate it?

Try switching to the default Garland theme, write down somewhere the list of enabled modules and then disable contributed modules and check if that helped.
You may also list here the list of enabled modules, perhpaps we'll be able to track down which module appears on every site with this probolem (if it really is a problem with another module).

CinemaSaville’s picture

those 2 statements are not in the source.

wxman’s picture

I don't know if this will help solve this, but I got the teaser break to work for me.
I had originally ran the WYSIWYG module, and TinyMCE. I also had the Ajax module, with the "Ajax plugin - wysiwyg" enabled. After reading all your comments, I went back and disabled the WYSIWYG module compleatly, and just the "Ajax plugin - wysiwyg". Afterward, I cleared the browser, and the Drupal cache, reloaded my edit page, and there the button was.
This is all on a custom theme, by the way.

gadzuk’s picture

Found my problem, thanks wwalc!

misc/teaser.js wasn't loading due to conflict with component "Resizable Body and Comments 6.x-2.0", when I disabled that component the button came back.

The component adds a checkbox to each content type "Use "Split Summary at Cursor" teaser button?". When unchecked the teaser button in ckeditor no longer functions, (but I'm pretty sure it did function in fckeditor).

The body resize component has this code (resizable_body.module)

     // remove "split summary at cursor" button and related elements if necessary
    if (variable_get('resizable_body_split_' . $nodetype, TRUE) == FALSE) {
      $form['body_field']['#after_build'] = NULL;
      $form['body_field']['teaser_js'] = NULL;
      $form['body_field']['teaser_include'] = NULL;
    } 

I suspect the component was causing this to not run (includes/form.inc)

 function theme_textarea($element) {
  $class = array('form-textarea');

  // Add teaser behavior (must come before resizable)
  if (!empty($element['#teaser'])) {
    drupal_add_js('misc/teaser.js');
    // Note: arrays are merged in drupal_get_js().
    drupal_add_js(array('teaserCheckbox' => array($element['#id'] => $element['#teaser_checkbox'])), 'setting');
    drupal_add_js(array('teaser' => array($element['#id'] => $element['#teaser'])), 'setting');
    $class[] = 'teaser';
  }  
wwalc’s picture

I've created a separate issue regarding Resizable Body - #666560: Compatibility with Resizable Body. Thanks gadzuk!

wwalc’s picture

@wxman - thanks as well, the problem is in WYSIWYG module that adds this:

  // Teaser splitter is unconditionally removed and NOT supported.
  if (isset($form['body_field'])) {
    unset($form['body_field']['teaser_js']);
  }

I have created a separate issue: #666616: Problems with teaser when WYSIWYG module is enabled.

So, to summarize, if you have problem with missing teaser buttons, make sure that Resizable Body or WYSIWYG modules are not enabled.
If they're not enabled, please report it here and we'll try to investigate which module is causing this.

wwalc’s picture

@CinemaSaville - do you have any ot these modules enabled perhaps?

wxman’s picture

Status: Fixed » Active

Once I got rid of the WYSIWYG module completely, I switched back to the latest ckeditor module. It works great now, and the teaser splitter button is there.

CinemaSaville’s picture

I do not have any of those modules installed. And Teaser break still doesn't appear with latest dev.

CinemaSaville’s picture

Status: Active » Fixed

OK, mystery solved. It seems that when the "Table" editing issue popped up, I was forced to go back to WYSIWYG module implementation of CKEditor on another site in my multi-site config, and I ended up going back to CKEditor 3.0.1 to make that work. So I had forgotten (You'll have to forgive me, Drupal keeps me on my toes with updates, and modules doing funny little things sometimes, so I may lose track occasionally.) that I had that version in there, AND I was under the impression that this module only worked with 3.1, so on the other site I was using with CKEditor module, it was going along perfectly until the mysterious teaser break button disappeared. But, that happened somewhat later than the CKEditor was downgraded back to 3.0.1, so it was a bit tricky until I tried checking WYSIWYG settings, and noticed that the CKEditor in the libraries folder was indeed 3.0.1, and both modules were using that version. So, yes, the teaser button is now back in play. Sorry again for the confusion, but when you're bridging the two worlds, and things aren't completely working in either version it's really challenging. Keep up the great work, and by all means, let's try to get that table editing happening on the Mac. (Have latest DEV and nightly builds, and it still doesn't work.)

wwalc’s picture

I have fixed (in CVS) the problem with teaser button. It should appear even when modules disabling the teaser are enabled. Please check the dev release and let me know if it works as expected.

@CinemaSaville no problem at all, thanks for explanation and testing.
Regarding Mac and tables - we were not able to confirm this and probably it will be not fixed in 3.1 unless we'll manage to reproduce it locally.
The 3.1 branch of CKEditor was recently copied to the trunk, which means that now you can download the latest version of CKEditor 3.1 here: http://nightly.ckeditor.com/
The question is: do you still see this bug in the nightly build demo, I mean here: http://nightly.ckeditor.com/4803/_samples/replacebyclass.html ?

We do not want to introduce regression bugs in CKEditor, so if it really stopped working for you properly and worked in 3.0.1, can you please check this site: http://rev.ckeditor.com/ ? It contains each version of CKEditor, by clicking on "samples", you may instantly check it.

Try checking when exactly that thing was broken, perhaps we'll be able to fix it even without being able to reproduce it if we know what caused it.
The easiest way of finding such things is starting with relatively big gaps, like 200 revisions and then when you locate the problem between revisions 4200 and 4400 (for example) check revision 4300, then 4350 or 4250 and so on.

CinemaSaville’s picture

As far as the nightly build demo goes, there's no tables support in Sarafi 4.0.4 FF 3.5.6 and Chrome Beta. Are other people running Mac seeing the table edit when they control click on the table?

As far as figuring out when this broke, I'd love to do that, but right now I have so many projects going on, I'm just going to have to avoid using tables on my site. I really need to focus on making movies and leave the coding and testing to you guys. Please feel free to check out some funny movies on my site at http://CinemaSaville.com this way I can pay you back for your great work in laughter. And I can see if my comedy plays in your country, or if you're left scratching your head like I am about what happened to the table editing in your editor. Again, Bravo for your great WYSIWG web editor. My favorite!

brack11’s picture

Status: Active » Fixed

@CinemaSaville
I'm using mac with Tiger and Safari 4.0.4 works fine with tables in CKEditor and I see table edit when I right-click inside the table, so, no problem there.

CinemaSaville’s picture

Ok, could be a snow leopard issue then. Anyone on snow leopard want to weigh in on this.

brack11’s picture

Status: Fixed » Active

Trouble again - I upgraded the ckeditor module yesterday and after first save entire teaser has disappeared. Only moving back to fckeditor solved the problem. Now, the teaser button in ckeditor exists and functioning properly, the teaser break line is there and is placed below teaser, pressing preview or save results in empty teaser. Have a feeling that these two problems (teaser button disappearance and teaser text) are connected. Any ideas?

brack11’s picture

Title: Teaser button is missing » Teaser button/text is missing
brack11’s picture

I have restored ckeditor to 6.x-1.x-dev (2009-Dec-10) and it works like a charm. Then I have a question - what is wrong with 6.x-1.x-dev (2009-Dec-24) and 6.x-1.0-beta1 (2009-Dec-04)? I keep loosing teaser text if I use any of them.

wwalc’s picture

@brack11 - is it possible that you have javascript caching enabled in Drupal and forgot to clear Drupal cache? Or that your browser was caching javascript files?
The latest dev release should work, at least I hope so...
If possible, can you PM me a link to a site with the latest dev version where teaser break button is not available?

brack11’s picture

I cleared the cache several times because I'm developing a new theme so, did it a few times.

I will make yet another site and install new ckeditor there, and PM you link then, my site is in almost production stage now dont want to install new things there.

wwalc’s picture

@brack11 yes please, send me a PM with a link to such site, it will help me a lot. Thanks in advance!

brack11’s picture

I have mde another site but cannot figure how to make dierent version of ckeditor in this site - I have module in sites/all/modules/ckeditor and newer (problematic) version is at sites/drupal.swarl.org/modules but drupal.swarl.org site sees only version that is in all/modules folder.I dont want to replace the one located in "all" folder because there are two public sites working there with over 40 users.

brack11’s picture

Status: Active » Postponed (maintainer needs more info)

I guess there is a duplicate of this issue, more committed to the present problem of the latest version see it here: #671668: Teaser-Problem with CKEditor

wwalc’s picture

Status: Postponed (maintainer needs more info) » Closed (duplicate)
williswatson’s picture

Version: 6.x-1.x-dev » 6.x-1.1

i have the same bug

no matter what i 'm trying to do ,the fucking DRUPAL BREAKING BUTTON still don't come out

now i d'not upgrade fCK to cke ,

hope someone could fix it soon

hschott’s picture

Just updated to Drupal 6.24 and the latest ckeditor module only and now have this problem - teaser button missing.

acbramley’s picture

Version: 6.x-1.1 » 6.x-1.10

Having this problem also, updated from ckeditor-6.x-1.3 to 6.x-1.10, reconfigured my custom toolbars, and now one of them is showing the drupal break button and the other one isn't. Using the latest ckeditor library, have ticked the box to use the plugin in both profiles.

acbramley’s picture

After a bit more disabling/re-enabling I managed to get this working.