Closed (duplicate)
Project:
Wysiwyg
Version:
5.x-2.x-dev
Component:
Editor - CKEditor
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
14 May 2012 at 03:20 UTC
Updated:
1 Jun 2012 at 09:26 UTC
Full normal distribution package of CKEditor has been uploaded to the correct location. WYSIWYG is clearly detecting its existence, but fails to detect the version number.
Comments
Comment #1
Seb_CKSource commentedI would recommend using the CKEditor module instead of the WYSIWYG module, unless you also intend to use WYSIWYG for other things besides running CKEditor. Here's how to do it:
1- Download, install and enable one of the following modules through your Drupal admin panel: http://drupal.org/project/ckeditor
2- Download this file from our site: http://download.cksource.com/CKEditor/CKEditor/CKEditor%203.6.3/ckeditor...
3- Follow the instructions and install the aforementioned package
The Drupal module (step #1) should fully work once you have done step 2 and 3.
Comment #2
escoles commentedCKEditor module is n/a for D5, or that's what I would have used.
The workaround is to hack the .inc file for CKEditor (or FCKEditor). Unfortunately that didn't do me any good, as the current version of WYSIWYG for D5 can't handle font styles for CKE or FCK.
Comment #3
twod@Seb_CKSource, if you don't have a real answer, please don't simply point people to CKEditor module, I find that a bit disrespectful and I don't go to that that queue to send people here. I'd much rather see the two modules merge or at least get closer to another at some point that us trying to "steal" users from the other module.
@escoles, if you downloaded the "Drupal edition" of CKEditor, please download the standard edition instead. The Drupal edition is packaged differently and for some reason bundled with ckeditor.module.
Wysiwyg should detect the latest version of CKEditor just fine, but it's possible we forgot to apply some CKEditor-related patch to the D5 branch. We're about to drop official support for the D5 branch so it doesn't get any new features, but bugfixes like this should get it.
Test with the 5.x-2.x-dev version and if that (version detection) doesn't work I'll see if I can come up with a patch for you.
As for font styles not working, what exactly do you mean? Do you mean that custom styles don't show up in the dropdown? There's a patch in the works which should also apply cleanly to the 5.x-2.x, please see #746524: No Font Styles for CKeditor for that.
Comment #4
escoles commentedTwoD: The issue is that the fixes didn't get applied to the D5 branch. I was able to hack the .inc file for CKEditor to make WYSIWYG detect it. Same worked for FCKEditor. As noted, though, the fix wasn't ultimately useful due to the style issue. The solution I arrived at was to move them to TinyMCE, which will work better for them anyway -- its support for pasting from Microsoft Word, while not strictly speaking as good, appears to be more consistent, which is more important for this client.
(Also, I had taken care to make sure I wasn't using the "drupal version", having run across other issues about that.)
The style issue is as you describe. This was something that needed to be solved quickly and permanently, so the TinyMCE migration was really a more timely solution than a patch -- I needed something that would be stable in case someone else updated the module in future, since this is not a for-sure regular client.
In any case, I had suspected there might be editor issues (I do understand this particular one is a module defect), which was another reason I wanted to use WYSIWYG on this task instead of trying to fix or patch fckeditor.module.
Comment #5
twodHmm, the strange thing is that the version detection code is currently identical for 5.x-2.x-dev and 7.x-2.x-dev and I know it works in 7.x-2.x-dev.
(5.x-2.1 doesn't have
the[EDIT: a working] CKEditor integration, which is why I said to try 5.x-2.x-dev, also relabling the issue because of that)Can you please post the details of the changes you had to make to get CKEditor 3.6.3 recognized (and those for FCKeditor)?
Comment #6
escoles commentedAre you sure 5.x-2.1 doesn't support CKEditor? Because it sure seemed to ;-) (aside from not loading the custom styles).
5.x-2.1 is in fact the version I used -- I just checked the .info file -- and it definitely recognized and loaded CKEditor after modification. Here's the .info:
But it's a good thing you asked me this, because I was confused about FCKEditor: That code is fine, as you say. It was the TinyMCE .inc file I had to modify.
Here are the changes I made.
For CKEditor, I modified editors/ckeditor.inc as shown here:
i.e., removed the '400' parameter for fgets().
For TinyMCE, I modified editors/tinymce.inc as shown here:
i.e., removed the '100' parameter for fgets().
Comment #7
twodOops, it should have said 5.x-2.1 doesn't have "a working" CKEditor integration above. Fixed that.
The fix for detection of later CKEditor versions was committed to the 5.x-2.x branch, but there hasn't been an official release of the D5 version since, which is why it's only in the -dev release. D6 and D7 did get releases, so it is in those.
The fix was actually to bump the
fgets()limit from 140 to 500 in commit 015343.... We don't want it to not have a limit since that will read the entire minimized file into memory (the last line with the version info is all on one line and lines are read one by one until that info is found).UPDATE: The corresponding fix for TinyMCE was 2f5adf....
Comment #8
escoles commentedTwoD, when is the cost of loading the entire file into memory incurred? Only when loading the config page, right?
Comment #9
twodNo, it's checked on every page the editor is needed on. We always makes sure the editor exists and is a known version before trying to load it to avoid crashing the other scripts on the page.
Comment #10
escoles commentedOK, thanks, just trying to figure out whether I need to hassle them to let me patch the module. That's probably an acceptable cost for that client. They edit pages rarely and the editor is never loaded for anon visitors. If it were every page load period I'd hassle them to let me patch it.
Comment #11
twodI'm not sure which patch you need. Doesn't the 5.x-2.x-dev release already detect CKEditor 3.6.3?
Comment #12
escoles commentedI don't want to get into the weeds on this with client-specific stuff. I'm just trying to gauge whether it's worth their $$ and our time to re-engage to install an update.
so as I look over the current status and the thread, I think this satisfies criteria for some version of 'fixed' (since it's in dev), but not sure what the right status is.
Comment #13
twodOk, np.
Updating won't take long, mostly bugfixes and other changes not related to CKEditor. Your editor profiles will be kept as well.
Let's just mark the issue a duplicate of #1143104: Newer ( 3.6.3 ) CKeditor version not detected by ckeditor.inc.