jQuery - How to check for available javascript on a page?
<p>On a html page that uses $.getScript to dynamically load .js files.</p>

<p>Later at some point if I wish to check whether a particular .js file is loaded.  How to do this?</p>

<p>Can I check using filename.js?  or do I have to check for an object/function/variable in that file?</p>

<p>Thanks for the answers folks.  You guys suggested callback function, global variable etc.  But the thing is, I work in corporate environment where one corporate .js loads other .js(the one I'm trying to detect).  Not only I can't modify corporate .js, I can't control when it'll change.  I was hoping may be there was a way to know which .js file is loaded on page.</p>
