Bug Tracker

Opened 6 years ago

Closed 6 years ago

#14514 closed bug (notabug)

attribute selector is not working if value has . in it

Reported by: tgvrs_santhosh@… Owned by:
Priority: undecided Milestone: None
Component: selector Version: 1.7.2
Keywords: Cc:
Blocked by: Blocking:

Description

attribute selector is not working if value has . in it

<input value='12.12.12.12' />

$(function(){

alert($("input[value=12.12.12.12]").length);

});

link to jsfiddle : <http://jsfiddle.net/63Jf6/>

It's reproducible in latest versions of jquery as well.. earlier, it use to work in 1.4.2

Change History (2)

comment:1 Changed 6 years ago by anonymous

$(function(){

alert($("input[value='12.12.12.12']").length);

});

comment:2 Changed 6 years ago by gibson042

Component: unfiledselector
Resolution: notabug
Status: newclosed

Special characters like . must be escaped or in quotes: http://api.jquery.com/category/selectors/

Note: See TracTickets for help on using tickets.