473,324 Members | 2,124 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,324 software developers and data experts.

Link selection problem for fckeditor in Firefox

Hi...
I am just trying to use FCK Editor.
I am having problem with link selection on double click for firefox.
Means if I select the link by double clicking on it and then swith to source mode, the link is removed.
I can only see the text inside the link. But the <a> tag is gone.
But if I select the link without double click then everything is working fine.
I am not getting what is going wrong.

Following is the code I have written in fckeditorcode_gecko.js:

Expand|Select|Wrap|Line Numbers
  1. if(FCK.EditMode==FCK_EDITMODE_WYSIWYG)
  2. {
  3. var oRangeAll = FCK.EditorWindow.getSelection();
  4.  
  5. if (oRangeAll.rangeCount>0)
  6. {
  7. oRange=oRangeAll.getRangeAt(0);
  8. var start = oRange.startOffset;
  9. var end = oRange.endOffset;
  10. var selsize = end-start;
  11. var sContent = FCK.GetHTML();
  12.  
  13. var selectstring = oRange.toString();
  14.  
  15. selectstring = selectstring.replace(/&/g, "&") ;
  16. selectstring = selectstring.replace(/"/g, """) ;
  17. selectstring = selectstring.replace(/</g, "<") ;
  18. selectstring = selectstring.replace(/>/g, ">") ;
  19. selectstring = selectstring.replace(/'/g, "’") ;
  20.  
  21. if(sContent.indexOf(selectstring)<0 || selectstring=="")
  22. {
  23. oRange.collapse(true);
  24. }
  25.  
  26. FCK.InsertHtml('%SelStart%' + oRange + '%SelEnd%');
  27.  
  28. }
  29. }
Thanks in advance
Mar 30 '07 #1
1 1693
acoder
16,027 Expert Mod 8TB
If you think this is a bug, ask the authors of the editor.
Feb 12 '08 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

8
by: Ronald | last post by:
Hi, I'm am trying to implement FCKeditor in my webapplication, but unfortunatly, I haven't succeeded in doing this. After almost a week, I finally got an compiled application, but now I get some...
2
by: Duncan Welch | last post by:
Has anyone here successfully got the FCKeditor working with .NET, including the image browser? It seems to be a great component, but is sorely lacking in any decent documentation. I've got the...
5
by: Jeff | last post by:
Hey ASP.NET 2.0 lets say I have a web page containing a FCKeditor, when this page loads it will fill the FCKeditor with some kind of text... I'm wondering how to set this text in the...
10
by: madtom1999 | last post by:
I've been playing with some javascript code and have produced a very rough proof of concept source code editor written in javascript (a bit like FCKeditor). Its not ready for release ((L)GPL>2 when...
2
by: ivowel | last post by:
Dear Experts: I am trying to write a css style that makes text invisible; visible-when-selected (so that at least a visible block appears over the selected text---like black foreground over...
0
by: beemer127 | last post by:
Hello: I'm really new to both .NET and SQL, and I am still learning. I have the FCKeditor working, meaning that it displays in my page, and I have the SQL connection string established, but I'm...
1
by: Archana1 | last post by:
hi I want to add fckeditor in asp. but it have some error like page can not be display Please reply urgently my code is: <!-- #include...
0
by: manojpolawar2008 | last post by:
Hi, I am using the fckeditor with asp.net2.0. I have declared and initialized and the FCKEditor on code behind(ie on aspx.vb) page. and i wan to set the ViewState value to FckEditor on...
1
by: ShirishKumar | last post by:
Hi, I have some problem with FCKEditor . First of all Required FiledValidator is not working for FCKeditor . I searched google and kept EnableClientScript of requiredfieldvalidator for...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.