Let the authors override validation message with x-moz-errormessage attribute

RESOLVED FIXED in mozilla2.0b7

Status

()

defect
RESOLVED FIXED
9 years ago
9 years ago

People

(Reporter: mounir, Assigned: mounir)

Tracking

({dev-doc-complete, html5})

Trunk
mozilla2.0b7
Points:
---
Dependency tree / graph
Bug Flags:
in-testsuite +

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

The idea is simple, if an element is invalid and mozErrorMessage is set, the error message will be overwritten by the string in mozErrorMessage. In some way, it lets the authors setting an error message without making the element suffering from a custom validity.
Jonas, should we add an IDL attribute for that? That might be more convenient but that might be annoying for authors if they use it and then we remove it, right?
I would say we should not add an IDL method. Seems better to add minimum amount of code to support an experimental feature.
Status: NEW → ASSIGNED
Summary: Let the authors override validation message with mozErrorMessage attribute → Let the authors override validation message with x-moz-errormessage attribute
Keywords: html5
Posted patch Patch v1 (obsolete) — Splinter Review
Assignee: nobody → mounir.lamouri
Attachment #479948 - Flags: review?(jonas)
Posted patch Patch v1Splinter Review
Attachment #479948 - Attachment is obsolete: true
Attachment #479950 - Flags: review?(jonas)
Attachment #479948 - Flags: review?(jonas)
Why such a very unusual naming for the attribute? Why x- prefix?
(In reply to comment #5)
> Why such a very unusual naming for the attribute? Why x- prefix?

I agree, that's horrible !
x-vendor is terrible. But I'll argue in the W3C bug.
(In reply to comment #8)
> x-vendor is terrible. But I'll argue in the W3C bug.

If you do, please, CC me :)
Attachment #479950 - Flags: approval2.0?
Attachment #479950 - Flags: approval2.0? → approval2.0+
Pushed:
http://hg.mozilla.org/mozilla-central/rev/188670e40942

But marking Target Milestone: beta7 because I realized this has been pushed accidentally with a big merge after a backout. I've no idea why :-/
I backed it out and pushed it again to have correct log.
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → mozilla2.0b7
Blocks: 344614
You need to log in before you can comment on or make changes to this bug.