htmlArea

A directory of browser-based WYSIWYG editors

  MAIN
INDEX
SEARCH
POSTS
WHO'S
ONLINE
LOG
IN

Home: htmlArea 3 (beta): htmlArea 2 & 3 archive (read only): htmlArea v3.0 - Bug Reports & Fixes:
[RC3 BUG] Mozilla - insert link over image fails to add title and target; same for IE and double click


The htmlArea 2 & 3 editors have been discontinued.

We've made these forums available as a read-only reference and knowledge-base for people using or developing editors based on htmlArea 2 or 3.

Anyone who is interested in taking over version 2 or 3 is free to do so. All we ask is that you choose a new name that doesn't have "htmlarea" in it to avoid confusion with this site. We'll even give you a link in the directory to make it easier for people to find you. If you are developing or hosting an htmlArea based-editor under a new name, please submit it to our directory.

 


Lukasz
New User

Feb 10, 2005, 2:25 PM

Post #1 of 1 (15666 views)
Shortcut
[RC3 BUG] Mozilla - insert link over image fails to add title and target; same for IE and double click Can't Post

when you click on image (to select it) then you click on create link. hArea creates link but since getParentElement() returns parent element (i.e. P) instead of element 'A' it fails to add title and target to the ceated link.

Another nice thing is double click on string + insert link - on IE it will fail to add target and title.

Has anyone fixed this?

As a quick fix for IE:
I have replaced call in createLink from getParentElement() to getParentElementForSelection(). Where getParentElementForSelection is exact copy of getParentElement(), the only difference is:

if (HTMLArea.is_ie) {
switch (sel.type) {
case "Text":
case "None":
> range.moveEnd("character", -1);
return range.parentElement();

 
 
 


Search for (options)