Page 1 of 1

Two WYSIWYG bugs with Firefox 2.0

Posted: Wed Mar 14, 2007 4:49 pm
by killergege
Hi !

I foud two bugs when I use the WYSIWYG editor to post a new post on my blog.

I use Firefox 2.0.0.1 and Serendipity 1.1.2

Bug #1:
- Focus a WYSIWYG window (introduction or body)
- type a text
- click on the unordered list icon
- press enter and write some text for the other list item
- press enter : it adds another list item.
- click again on the unordered list icon : it removes the empty list item
- press enter

The "Path" label at the bottom of the window appears empty (normally it should display at least "body" or "body p") and I can't do anything in that window. I can just add text but can't use backspace, del button, etc.
I cannot switch to HTML mode.
Then an error messagebox appears sometimes : "Your document is not well formed"

Javascript console says :
Error: this._doc.body has no properties
Source File: serendipity/htmlarea/htmlarea.js
Line: 1177


And some :
SessionStore: TypeError: aContent.document.body has no properties

-----------------------------------------------------------------
Bug #2

if you click on the bullet list icon without having typed something in a zone you get this error in a messagebox (nothing in javascript console):
[Exception... "Component returned failure code: 0X80004005 (NS_ERROR_FAILURE)
[nsIDOMNSHTMLDocument.execCommand]" nsresult: "0x80004005 (NS_ERROR_FAILURE)"
location: "JS frame :: /serendipity/htmlarea/htmlarea.js :: anonymous :: line 1876" data: no]

by execCommand(insertunorderedlist);


If you typed something (a blinking cursor appeared), everything works. Even if I remove the text and focus another field.

With IE6, when the page is loaded the cursor is already blinking in the field so it always work.



For both bugs, there is no problem with IE

Re: Two WYSIWYG bugs with Firefox 2.0

Posted: Thu Mar 15, 2007 10:24 am
by garvinhicking
Hi!

Thanks for reporting those bugs. Sadly those are bugs in the WYSIWYG editor component called 'HTMLArea' that we simply bundled.

HTMLArea is no longer maintained, and there's nobody supporting (or understanding) it.

There are other WYSIWYG editor plugins that can use FCKEditor or Xinha or TinyMCE - but those are not as tightly integrated with the serendipity media database, and I'm lacking the time to inspect WYSIYWG editor components, because I'm not good enough with JavaScript to properly understand the hooks and interface of those components.

:-(

Best regards,
Garvin

Posted: Thu Mar 15, 2007 4:16 pm
by killergege
That's a really bad news... And the worst it's that it works on IE :)

Let's hope that someone very good at javascript will take a look at this problem and provide a solution.

The workarounds are easy so these are not so serious problems.

Should I report these bugs in your BTS so that someone could work on it ?

Posted: Fri Mar 16, 2007 10:30 am
by garvinhicking
Hi!
Should I report these bugs in your BTS so that someone could work on it ?
If you would have the time to do so, that would be most appreciated! :-)

Best regards,
Garvin

Posted: Mon Mar 19, 2007 9:57 am
by killergege
Done :)

Posted: Sun May 13, 2007 3:10 am
by luto
Is there any idea how to get rid of HTMLarea? It does not work with Firefox 2.0.0.3 at all and although I installed FCKeditor I have severe problems using the media library (although I followed the instructions of the plugin). When opening a media link I only see a huge windows with errors. And although my screen resolution is 1280x1024 I can't read all of the error messages). TinyMCE does not work at all, so I am editing with the non-WYSIWYG editor at the moment.

Posted: Sun May 20, 2007 10:48 pm
by utak3r
luto wrote:Is there any idea how to get rid of HTMLarea? It does not work with Firefox 2.0.0.3 at all
umm? it works with 2.0.0.3 fine. Not very well, but fine ;)
Focusing a cursor is generally a problem in HTMLArea under Firefox... try inserting an image at the very end of an article, then go up, anf try writing below the image... it takes a few seconds to get it done ;) Ctrl+Home / Ctrl+End don't work... moving with a cursor to the end, and sometimes the focus goes off... ech.
garvinhicking wrote:HTMLArea is no longer maintained, and there's nobody supporting (or understanding) it.
well said... going through its code is a real pain the ass :roll:

Posted: Mon May 21, 2007 9:08 am
by luto
After some testing I found out that the problem seems to be with the NoScript-addon from Firefox. All computers where this plugin is not installed show the HTMLArea editor as it should be. The one with NoScript enabled seems to block essential JavaScript.

Posted: Mon May 21, 2007 9:14 am
by utak3r
luto wrote:The one with NoScript enabled seems to block essential JavaScript.
So why not configuring it to accept JavaScript from this site?... I'm using NoScript, too - just tell it that your site is trusted to run scripts :)

Posted: Mon May 21, 2007 2:11 pm
by luto
Well, I did that but it still doesn't work. Maybe it is another plugin I used, I don't know. Just started a new profile and now everything is fine and I am happy :lol: