Based on limited testing, I believe that the 0.3 branch is now less buggy/more usable than 0.2 branch. Unfortunately, it depends on unreleased jQuery 1.1.x branch in svn (will be 1.1.3). Since Drupal 5 includes jQuery 1.0, it may not be possible to use wymeditor 0.3 under Drupal 5. However, if anybody has any bright ideas, post them here :)

Links:
Update D6 to jQuery 1.1.x

Comments

Moxide’s picture

Here is a report of the 'work in progress':

On the WYMeditor's side, some bugs had to be fixed (see WYMeditor's Trac)

On Drupal's side, WYM 0.3 module currently requires JQuery Update module, a patch for 'collapse-fix.js' and JQuery 1.1.3a.

The good news are that it does work with Drupal 5 and that WYMeditor no longer needs to be uploaded to the Drupal's CVS.

My short term goals are :
- propose the 'collapse-fix.js' patch to JQuery Update's issue queue.
- create the CVS branch for WYM 0.3

Any questions or comments are welcome ;-)

edrex’s picture

This seems unlikely to happen without a fix for core JS issues with jQuery 1.1.3a. We could try to backport the 6.x patch to 5.x. Unless some JS wizard knows a trick to feed one version of jQuery (the $ function) to Drupal core and another to wymeditor?

Moxide’s picture

My feelings now:
If there is an easy way to run JQuery 1.1.3a with Drupal 5 (namely, if jquery_update can be made compatible with JQuery 1.1.3a by backporting the 6.x core patches), I will create the 5.x branch for WYMeditor 0.3.
If not, WYMeditor 0.3 will be a Drupal 6.x project.

What do you think of this ?

wedge’s picture

I say go for d6.
Maybe it would be much trouble converting the module from the d5 to the d6 fapi and get the corefixes that you talk about backported.

edrex’s picture

Ok very exciting: it seems that wymeditor JS is being very gracious by doing this at startup:
var $j = jQuery.noConflict();
and then only accessing jquery via the $j. Provided that the two versions of query are willing to share a browser (i think they will), we should be able to run wym 0.3 with jquery 1.1.3a and leave Drupal with 1.0. I'm going to experiment and try to get it working to verify (I have very little js smarts)

edrex’s picture

Ok, I fooled around with this a bit, and what I came up with (actually thanks to someone on #jquery who's name I don't recall) is a simple find-and-replace of "jQuery" with "hQuery" in the several javascript files (jquery-1.1.3a.js itself, jquery.wymeditor.js, etc). Duh. Works great.

I attached a simple test module which activates wymeditor on node body textareas, with all patched files included. The wymeditor module will need some refactoring since embedding wymeditor is alot easier in 0.3.

edrex’s picture

StatusFileSize
new110 KB

oops, test module attached as promised

edrex’s picture

StatusFileSize
new100 KB

fixed. this is totally just to test that it basically works, lots of things are broken. Moxide, still interested to release a 5.x-0.3 version?

steinmb’s picture

Hi no new is not always good news, did Moxide answer you on this? D6 is prob. not out before oct/nov and then all modules have to be tested, so it quickly takes 1/2 year before it is usable (I think). Do you know what version of jQuery D6 is running?

--
Steinmb

mightyiam’s picture

Title: Support wymeditor 0.3 » Support wymeditor 0.4

Well, just got the email and 0.4 stable is out. I'd love to see it go in :).

steinmb’s picture

That is great news! Ver. 0.4 now work much better with Opera :) I was waiting for that to be solved. I really like like the editor, but now it is to much of a hassle getting it to work with Drupal and a image uploader. Wymeditor team is currently working on a media API, I am not sure if they are planning to release it with 0.5.

I hope someone step up and make 0.4 nicely with Drupal 5 or 6, this is really i compact and fast editor that are making clean and organized code, not like the tags in tinymce instead of (with Firefox) and even worse with Safari then it includes

tags with font type/class is very messy....

Moxide’s picture

Hi everyone,

To my knowledge, as of today, JQuery Update is still using JQuery 1.1.2 and thus can't help with WYMeditor 0.4 integration.

But this might change shortly, see this JQuery Update issue.

If so, I will rework and release a WYMEditor 0.4 module for Drupal 5. If not, I will focus on a Drupal 6 module.

Regards.

peterx’s picture

I use Drupal 5.x and lots of optional modules across various sites. I replaced the Drupal 5.x jquery with jquery 1.2.1 and everything still works including wymeditor-5.x-1.x-dev. I encourage you to create the WYMeditor 0.4 version for Drupal 5.x using jquery 1.2.1.

With Drupal 6 at beta 3 and not far from final release, the few 5.x modules that use jquery should be under development for 6.x and the changes could be backported to 5.x so those modules can use jquery 1.2.1 in Drupal 5.x. Create a new WYMeditor for 5.x and call it 5.x 1.2.1. Many sites can jump straight to jquery 1.2.1 and WYMeditor 0.4. The other sites can help upgrade the few optional Drupal modules that do not work with jquery 1.2.1 or stay with WYMeditor 0.2.

bennybobw’s picture

I have custom module running Wymeditor 0.4 on 5x. But there's a pretty big bug that has made it unusuable for my site. i've posted a bug on the Wymeditor site, but haven't heard about it yet. You can check out the issue here: https://trac.wymeditor.org/trac/ticket/87

liquidcms’s picture

hey gang.. i stumbled upon this looking for some Drupal 5 and jquery 1.2 compatibility help - and thought i would mention NO Dr 5 not comp with jq 1.2.. but mostly

i upgraded my site to 1.2 because the main docs on jq site were for 1.2 and very non-backward compatible.

this has been working fine for me except i just noticed the little "select all" check box on the admin/content page is missing.. after a little diggin around i tried replacing jq back to 1.1.. and sure enough thats the problem

i am not that concerned about that checkbox.. although i really do need it back - but i am more concerned about all the other things that might also be busted.. and worse.. that i dont get any js error from this.

fall_0ut’s picture

I am working in this module to integrate with wymeditor 0.4 for drupal 5.x.
To do that, I started by updating jquery, according to the patches provided at jquery_update http://drupal.org/node/156221

magico’s picture

(subscribe)

fall_0ut’s picture

Category: task » feature

After upgrading the jquery to the most recent version using the jquery_update patch, I've done several changes and modifications, so WYMeditor could be upgraded to version 0.4

  1. The configuration is now based on user roles instead of creating editor profiles
  2. On the new profile window, several old functions where removed and new ones added (like the options to choose buttons and select plugins)
  3. Instead of always returning JS inside the HTML, a js file is created according to user roles to use browser cache system
  4. Allows the insertion of images, from the node attachments
  5. A specific filter for WYMeditor is automatically created, and the allowed HTML is syncronized with the HTML tags selected for use within the editor

I post the code later...

steinmb’s picture

Great Work!! :-D
Does this mean it will work with D6 without any updates of jquery? D6 will ship with jquery ver. 1.2.3 when it is done.

--
Stein Magne

demeester_roel’s picture

(subscribe)

zmove’s picture

subscribe too

asezen’s picture

Hello, is this project dead or just suspended ? D6 already release and i tho that we could use wymeditor with d6. Any information will be appreciated.

Thanks.

ansorg’s picture

subscribe

marcvangend’s picture

@asezen, #22:
I guess the WYMeditor project itself (www.wymeditor.org) is not making much progress at the moment. The latest version (0.4) is almost half a year old and the roadmap shows that version 0.6 is already 2 months late.
I would love to be able to use this module, but we can't expect the module developers to make progress if the core component doesn't.

fall_0ut’s picture

Assigned: Unassigned » fall_0ut
Status: Active » Needs review
StatusFileSize
new299.33 KB

The following patch adds support for version 0.4

This patch includes the wymeditor, but it can be easilly removed because i use the upstream version only with new files added. I was thinking in doing some organization to this... what do you think moxide?

PS: this is my first patch, so... be carefull!

adrien.gibrat’s picture

Thank for your patch,
but i can't use it... I can't even figure out if i need to apply it against 5.x-1.x-dev or CVS, both fails...

The patch put a big mess but don't apply correctly!

Could you send the zip version of your work?

I think i will make a patch only for the wymeditor.module, wymeditor.js, wymeditor.install & wymeditor.info only.
And just copy the wymeditor folder (0.4 version) manually, it's better to do this way (in my opinion).

I really hope this module will not die... i'm ready to help to maintain... Drupal need such an editor!

fall_0ut’s picture

StatusFileSize
new72.71 KB

The zip of wymeditor 0.4 for drupal-5.x

This version has some changes in the profiles of wymeditor, the profiles are associated to content filters

adrien.gibrat’s picture

Thanks!

you answered quickly, i appreciate.

I've got some problems on install due to the old wymeditor (so for all the ones who want to test: uninstall manually wymeditor before testing this version: drop all wymeditor related tables = wymeditor_classes, wymeditor_containers, wymeditor_profiles)

Using filters is definitively a good way to setup nicely upon profiles!
Storing the containers and classes settings in variables is a great idea.

But there is still some bugs, i will post patches as soon as i have some time to do it.

adrien.gibrat’s picture

The first things i've noticed:

You'll need to use jQuery 1.1.4, so on top of jquery_update, manually change the misc/jquery.js file with the most recent jquery version.
This seems to work great with others js module... plus, jquery 1.1.4 is really faster!

If not, you will have some stange behaviour in the editor: when creating new content or after a heading, the text isn't in a paragraph = it's raw text and you will be unable to make it append in a p tag without editing the HTML... strange!

Line 290 of the wymeditor.module:

      $container_js[] = "{'name': '".$container['tagname']."', 'title': '".$container['description']."', 'css': 'wym_containers_".$container['tagname']."'}";

is better like this:

      $container_js[] = "{'name': '".strtoupper($container['tagname'])."', 'title': '".$container['description']."', 'css': 'wym_containers_".strtolower($container['tagname'])."'}";

As we can't always be sure users will enter the tag name in uppercase, and the css name must be in lowercase.

And a little trick: jquery style baby.

jQuery(wym._box).find(wym._options.containersSelector)

it's better and faster to write it like that, as "wym._box" is a dom element, it can be used as context (see jquery doc):

jQuery(wym._options.containersSelector, wym._box)

fall_out, your work is awsome... really a great job!
This should be added as a beta in the module page... for a larger testing scale. (do you hear me Moxide?)
Thanks a lot!

fall_0ut’s picture

I use this patch for the jquery update and work fine.

You need to create a patch with your corrections?

http://drupal.org/node/156221 #48

alanburke’s picture

subscribe

steinmb’s picture

Hi
Any patch soon?

Query_update module is picking up speed and have released a 5.x-2-branch that contain jQuery 1.2.3 so when this is done, we don't have to brake our Drupal installation to make the editor work and WYMeditor have finally started working in Safari ver 0.5-alpha is the first release that support Safari. I have done some light testing, and it is indeed promising.

Cheers
Stein Magne

magico’s picture

Title: Support wymeditor 0.4 » Support wymeditor 0.5-a1
StatusFileSize
new87.11 KB

And here it comes the work for WYMeditor 0.5-a1 (all the credits goes to fall_0ut)

New things in this version:
1. No more global permissions. Permissions are set against the input format permissions
2. We can turn off/on the WYMeditor at runtime using the filter formats radio buttons
3. No more right panel with classes and conatiners (we now have them as dropdowns (we will try to get this as an official WYMeditor patch)

For screens and video take a look at #125315: Textarea with input format attached

magico’s picture

Status: Needs review » Fixed

The patch was applied!

Anonymous’s picture

Status: Fixed » Closed (fixed)

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