in reply to Duplicate field names and Test::WWW::Mechanize
I don't know how much "a fair amount of work downstream" amounts to, nor what timing issues are involved, but having two fields with the same name, in the same form, seems to me not a good idea (Service Mark pending).
From w3c (Forms in HTML documents):
name = cdata [CI]
This attribute names the element so that it may be referred to from style sheets or scripts. Note. This attribute has been included for backwards compatibility. Applications should use the id attribute to identify elements.
Emphasis in original
Further, albeit specifically asserted only in reference to anchors, w3c (global structure) notes that id and name "share the same namespace."
I have seen (sorry, no cite handy) discussions that suggest w3c will go beyond merely deprecating name in the context you're using it. How soon? Who knows, and yes, it'll be some time before browsers catch up, if it actually happens, but you could find yourself under the gun, if you hold off on fixing whatever's needed until there's a (practical) deadline stareing you in the face.
In fact, I suspect (without testing, since you don't specify the "work downstream") that eitherIf the form works, as is, in a browser, the former seems likely, because otherwise, I would not expect the form to distinguish between the duplicate names.
|
|---|