Opened 16 years ago

Closed 11 years ago

#1668 closed Bug (fixed)

IsDirty giving false positive with no content.

Reported by: Josh Ritter Owned by:
Priority: Normal Milestone:
Component: General Version: FCKeditor 2.5
Keywords: Cc: matti.jarvinen@…

Description

Using 2.5 in ff2. Loading fck with empty content and calling IsDirty and it is returning true. Adding content opening a fresh window and calling IsDirty then returns false. My demo is setup @ http://ritter.eplt.washington.edu/tools/fckeditor.

I tried to test this against your demo version, but every example I found on your site was pre-loaded with content.

Attachments (1)

isDirtyChange.js (677 bytes) - added by Matti Järvinen 15 years ago.
fixes IE7 FF3 isDirty failure with empty value

Download all attachments as: .zip

Change History (7)

comment:1 Changed 16 years ago by Wojciech Olchawa

Keywords: Confirmed added
Version: FCKeditor 2.5

Confirmed using FCKeditor 2.6 and the latest SVN. The bug occurs in FF2 as well as in IE.

Changed 15 years ago by Matti Järvinen

Attachment: isDirtyChange.js added

fixes IE7 FF3 isDirty failure with empty value

comment:2 Changed 15 years ago by Matti Järvinen

Cc: matti.jarvinen@… added
Version: FCKeditor 2.5FCKeditor 2.6.3

IE7 and FF3 handle empty values differently.

With oEditor.setData(,true):

FF StartupValue <br> IE StartupValue

FF EditorDocument.body.innerHTML '<p><br></p>' IE7 EditorDocument.body.innerHTML '<P></P>'

So oEditor.IsDirty() == true

I hacked something together to fix this in editor/_source/internals/fck.js replace IsDirty (line 63) with isDirty function in isDirtyChange.js

In no way the fix is complete since I do not know how this appears in Safari or other supported browsers.

comment:3 Changed 15 years ago by Alfonso Martínez de Lizarrondo

Version: FCKeditor 2.6.3FCKeditor 2.5

comment:4 Changed 15 years ago by Matti Järvinen

Version: FCKeditor 2.5FCKeditor 2.6.3

Yes I have this problem in 2.6.3

oEditor.setData(,true); oEditor.isDirty(); true

comment:5 Changed 15 years ago by Alfonso Martínez de Lizarrondo

Version: FCKeditor 2.6.3FCKeditor 2.5

Stop changing the version field.

If it was fixed in 2.6.3 then the ticket would be closed, not open. It must be used to note the first version where the problem was present, not the last one, because that would mean that it's the latest version in all the open tickets, so it would be useless.

comment:6 Changed 11 years ago by Piotrek Koszuliński

Resolution: fixed
Status: confirmedclosed

This issue expired.

Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy