Case Insensitive JQuery contains selector
If you need to use :contains() as a selector but need a case insensitive one, you need to extend jQuery yourself: This function will do it: $.extend($.expr, { 'containsi': function(element,…
A bunch of ramblings about PHP programming, JQuery, MySQL and other 'stuff'
If you need to use :contains() as a selector but need a case insensitive one, you need to extend jQuery yourself: This function will do it: $.extend($.expr, { 'containsi': function(element,…
Say you want to use a selector to select all controls with a certain class, apart from a particular one. Use the not selector: $('.selectedClass:not(#exceptionId)').functions(); Sweet.
We all have to bind events to elements: $('#link).click(function(){ do some stuff }); But, what if that element doesn’t exist yet? Well, you can use the “live” handler: $('#link').live('click', function(){…