Page 1 of 1

Add Entry bug

Posted: Fri Jul 30, 2010 11:25 am
by evanslee
On the add entry screen

If you enter some text and highlight a word, then click a markup button (i.e italic), then backspace you lose eveything you have just typed.

Fix: would be to change the focus to the highlighted text again after clicking any of the markup buttons.

Re: Add Entry bug

Posted: Fri Jul 30, 2010 11:45 am
by onli
Which Editor in which browser? I can't reproduce this with the non-wsyiwyg-editor. There, nothing gets focused or deleted.

Re: Add Entry bug

Posted: Fri Jul 30, 2010 12:00 pm
by evanslee
Serendipity: 1.5.3
Browser: IE7
Serendipity Editor: Standard with markup buttons (not wiziwig)

I can recreate this bug over n over again...

Highlight a word
Click a markup button [which wraps the word but leaves it highlighted]
When you click backspace rather than delete the highlighted word it navigate to another page...


Backspace works fine if i highlight a word in the textbox but dont use any of the markup buttons...

Re: Add Entry bug

Posted: Fri Jul 30, 2010 12:29 pm
by garvinhicking
Hi!

Hm, basically serendipity_editor.js should already do the .focus() due to the "wrapSelection()" function at around line 61. It only does that if "scrollTop" is available, maybe this is a FF-only property?

You could try to set scrollPos = true; at the top of the function and see if that helps? (Remember to clear your browser cache before trying)

Regards,
Garvin

Re: Add Entry bug

Posted: Fri Jul 30, 2010 12:34 pm
by evanslee
Thanks, that did the trick.

Nice one :)

Regards,
Lee