> At the point of doing document.getElementById(t), you might as well just
> return that since that's all jQuery is going to do anyways.

No, jQuery will validate that the elem is within the given context (if any).


> You might consider something like (only tested on FF2/win32):
>
> jQuery.fn._find = jQuery.fn.find;
> jQuery.fn.find = function(t, context) {
>     if (typeof t == 'string' && document.getElementById(/^\w+/.exec(t)))
>         t = '#' + t;
>     return this._find(t, context);
> }


Nice!

_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/

Reply via email to