Ruslan Ulanov’s Codeshack

The developer’s notebook

Javascript equivalent for PHP’s functions

Posted in JavaScript by Ruslan Ulanov on the March 13th, 2008

Mr. Kevin van Zonneveld has a nice collection of PHP functions ported to JS.

For example sprintf:

(more…)

mredkj.com

Posted in JavaScript, VB.NET by Ruslan Ulanov on the March 13th, 2008

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

Posted in JavaScript by Ruslan Ulanov on the March 6th, 2008

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…)