Bug Tracker

Opened 12 years ago

Closed 11 years ago

#2359 closed bug (fixed)

[validate] Error message labels that are hidden then re-displayed are given block display mode

Reported by: kapowaz Owned by: joern
Priority: major Milestone: 1.2.2
Component: plugin Version: 1.2.1
Keywords: validate Cc:
Blocked by: Blocking:

Description

When using the Validation plugin, if error messages are set to be displayed inside of an inline element (including the default, labels) and the error message is hidden then shown a second time, then although that element is generated at first with the default inline display property, on subsequent occasions the element is given a display mode of block. This appears as though it could be a bug in the jQuery implementation of .show(), although this is apparently supposed to use the previous state of the element in question.

I've attached a patch which fixes the issue for the default error display of labels (or indeed, any inline element) but this will need to be modified to correctly redisplay errors that are intended to be contained within block display elements. Unless of course the problem really is with the jQuery .show() method, in which case I suppose it ought to be fixed upstream instead.

Attachments (1)

jquery.validate.js.diff (165 bytes) - added by kapowaz 12 years ago.
jQuery/Validation plugin 1.2.1 patch

Download all attachments as: .zip

Change History (4)

Changed 12 years ago by kapowaz

Attachment: jquery.validate.js.diff added

jQuery/Validation plugin 1.2.1 patch

comment:1 Changed 12 years ago by joern

Owner: set to joern

comment:2 Changed 12 years ago by joern

Milestone: 1.2.2
Version: 1.2.1

comment:3 Changed 11 years ago by joern

Resolution: fixed
Status: newclosed

Afaik this is fixed in jQuery core, can't reproduce the problem with current versions.

Note: See TracTickets for help on using tickets.