Thursday, June 16, 2011

jQuery Plugin: FunkyFocus v1.1

I used by little plugin in a production environment today and found one bug and a couple needed features.

The bug was with this code:

Apparently it only replaces the first {id} found in the string. So I updated that line to this:
var selector = options.selectorOverride.replace(/{id}/gi,;

One of the features I needed was a way to ignore certain elements. So I created a new option called notSelector and the default is ‘.ignore’. So basically all the selectors are $(selector).not(options.notSelector).whatever.

I also added a check for when you set the focus of an input via the code-behind in ASP.NET.

You can download the new version here.

Check out the demo here.

Thanks for reading!

kick it on

blog comments powered by Disqus
Related Posts Plugin for WordPress, Blogger...