I am using CKEditor 3.6.0.6902 with WYSIWYG with D7.12. I have followed the readme.txt to the letter. I even added the same CSS code drupal.org uses for this filter. I turned on the filter in the FULL HTML and am using that to edit in the WYSIWYG body area.

When I type in the code tags in the editor, they show up as normal text. If I switch to source and type them in, they do not display, but I don not get any of the DIV class=codeblock stuff. I thought that would happen automatically, but I have to manually add the div and the class to get the effect to work, and then only partially.

I know I am doing something stupidly wrong, as no one else is reporting this issue. Any help appreciated.

Comments

cameron tod’s picture

Assigned: Unassigned » cameron tod
Status: Active » Closed (works as designed)

I have just picked up maintenance of this module, and am cleaning up the issue queue. I am not sure what level of compatibility code filter has with CKEditor, but will look into if further for you if you still need support. In the meantime, I am going to close this issue, but feel free to reopen it or comment if you do need more help.

ikeigenwijs’s picture

I desperately need this functionality.
I enabled the module, the filter info is added.
the tag just appears as text.

ikeigenwijs’s picture

Status: Closed (works as designed) » Active
cameron tod’s picture

I will test this for you - can you confirm that you are still using the combination of modules in the issue summary?

cameron tod’s picture

Title: Just not working as expected » Code Filter not working with WYSIWYG and CKEditor 3.6.0.6902 on Drupal 7.12
cameron tod’s picture

Status: Active » Needs review

I have tested this a little and found a very useful post by WYSIWYG maintainer TwoD: #1403918: "<?php" replaced by "<!--?php" by CKEditor

I have created a sandbox module that implements the code he has there. If you are not so comfortable with using git, I have created a mirror at https://github.com/cam8001/wysiwyg_codefilter where you can download a .zip of the module so that you can install it locally. Instructions are in the README.md.

Let me know how you get on!

ikeigenwijs’s picture

Hey , thx for the effort
But i use ckeditor module with ckeditor library.
Not the wysiwyg module ( i never get this to work properly)

Your sandbox module requires the wysiwyg.
Can you modify it for use with the ckeditor module ?

thx
i tried also direct ckeditor plugins but they get blocked off by the ckeditor.module i think

I use drupal 7.16
ckeditor 7x 1.9
ckeditor lib 3.6.5

cameron tod’s picture

Title: Code Filter not working with WYSIWYG and CKEditor 3.6.0.6902 on Drupal 7.12 » Code Filter not working with ckeditor module and CKEditor 3.6.0.6902 on Drupal 7.12
Status: Needs review » Needs work
cameron tod’s picture

Status: Needs work » Needs review

Well after adding in support for CKEditor, during testing, I realized that is has support built in.

To make it work, all you need to do is switch to plain text input, paste in your code, then save your node. Your code will then work with filters fine, but won't show up in the WYSIWYG editor - it will only show up in the non-rich editor.

cameron tod’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.