Javascript equivalent for PHP’s functions
Mr. Kevin van Zonneveld has a nice collection of PHP functions ported to JS.
For example sprintf:
no comments yet
mredkj.com
A good JS and VB.NETĀ resource with unpronounceable name atĀ http://www.mredkj.com/index.html
Dynamically loading an external JavaScript or CSS file
To load a .js or .css file dynamically, in a nutshell, it means using DOM methods to first create a swanky new “SCRIPT” or “LINK” element, assign it the appropriate attributes, and finally, use element.appendChild() to add the element to the desired location within the document tree. It sounds a lot more fancy than it really is. Lets see how it all comes together:
(more…)