Bug Tracker

Opened 14 years ago

Closed 14 years ago

#4921 closed bug (invalid)

basic filters (lt & gt) only accept numbers, not variables

Reported by: th507 Owned by: john
Priority: minor Milestone:
Component: selector Version: 1.3.2
Keywords: lt gt filters Cc:
Blocked by: Blocking:


This does not work var t = 10; $("div:lt(t)").each();


while the following works $("div:lt(10)").each();

Change History (1)

comment:1 Changed 14 years ago by dmethvin

Resolution: invalid
Status: newclosed

Selectors do not do automagic variable substitution. This works fine though:

var t = 10;

Please use the forums rather than the bug tracker to ask these kind of questions.

Note: See TracTickets for help on using tickets.