I don't think so - I've updated the documentation to be a little more precise. http://docs.jquery.com/Attributes/val
--John On Tue, May 26, 2009 at 3:26 PM, Alex Farcas <alex.far...@gmail.com> wrote: > > I noticed val() ignores the 'value' attribute on html elements. > > If i have this markup: > < div id="test" value="45" >< / div > > > $('#test').val() - will return empty string > $('#test').attr() - will return '45' > > If i set a value using $('#test').val(88) > > $('#test').val() - will return '88' > $('#test').attr() - will return '45' > > So val() has nothing to do with the 'value' attribute, although in the > documentation for val() i see: Get the content of the value attribute > of the first matched element. > > Doesn't this qualify as a bug? > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "jQuery Development" group. To post to this group, send email to jquery-dev@googlegroups.com To unsubscribe from this group, send email to jquery-dev+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/jquery-dev?hl=en -~----------~----~----~----~------~----~------~--~---