RE: Ways to refer Javascript Libraries in CRM Portal
Hi Sreedhar,
As Aric mentioned, if you want to include JavaScript from your CRM instance, you need to upload as a web file. You can't easily include JavaScript that is uploaded as a Web Resource.
As far as actually including the reference, I thought I'd mention a few additional options, in addition to the "Tracking Code" snippet. The Tracking Code snippet was originally meant for including javascript code for things such as Google Analytics, but it can be used as Aric described, to include JavaScript for external sources, or web files. Whatever you put in that snippet will appear near the closing body tag on all pages.
If you need to include JavaScript higher up on the page (which is necessary if you're including libraries that you reference directly in some of the custom javascript areas in entity lists, forms, etc which are placed within the main content of the page), there is another snippet called "Head/Bottom" which will put it within the <head> tags.
You can also include scripts via the Header or Footer "Web Templates", which appear on all pages, except if you've specifically excluded them from the page template.
Hope that helps.