I have some functions that I frequently use in a file called customLib.js. When I want to use one of the functions I copy its definition to the script where I want to use it. Could I upload it somewhere, like dropbox, and use a dropbox url as the src to link to it as an external script in the script tag? Like how Google hosts jQuery.

Recommended Answers

All 4 Replies

Sure you can, but I don't know how Dropbox works.

All you need is to put your file in a virtual directory, using IIS, apache or any other.

Do you have any host? If so just put the file there and use it's URL.

Isn't there something like google, dropbox, yahoo or whatever that could host it for me?

No one said you couldn't use dropbox. Just place it in the public directory in your dropbox account and it should work fine, it won't be exactly a nice looking URL but it will work.

You can check Google App Engine if you want as CDN. And yes, you can use dropbox as CDN.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.