[jQuery] Re: How to test if plugin X is loaded ?

2007-08-15 Thread xavier
Thanks, didn't search the doc at the right place (was looking into core, that's under ajax). Why would you question if I really want to do that ? What would be the reason/risk of doing it ? X+ On Aug 15, 1:09 am, Erik Beeson [EMAIL PROTECTED] wrote: I question whether or not you really want

[jQuery] Re: How to test if plugin X is loaded ?

2007-08-15 Thread Erik Beeson
Because I think it would be much cleaner to just load the plugins that you want in the first place... --Erik On 8/15/07, xavier [EMAIL PROTECTED] wrote: Thanks, didn't search the doc at the right place (was looking into core, that's under ajax). Why would you question if I really want to

[jQuery] Re: How to test if plugin X is loaded ?

2007-08-14 Thread Benjamin Sterling
Xavier, For question #1: if(typeof $.fn.tableSorter == 'function') question #2: yes, you just need to know the path to the file and do a document.write('script... On 8/14/07, xavier [EMAIL PROTECTED] wrote: Hello, I'd like to be able to test if a specific plug in is loaded before

[jQuery] Re: How to test if plugin X is loaded ?

2007-08-14 Thread Erik Beeson
I question whether or not you really want to be doing that... But here's both questions in one go: if(!$.isFunction($.fn['pluginName'])) { $.getScript('/path/to/plugin', function() { alert('Plugin ready'); }); } else { alert('Plugin ready'); } That assumes the plugin is on the same