Please note: This page is imported from my wiki, which hasn't been updated in over 10 years. Some of the formatting was lost during the import. I'll try to get around to fixing it someday.
s.substring(start,end) s.split(delimiter)
for (variable in object){ // do something ( can use object[variable] for value ) }
For example, to show all properties of the current document for (p in document) { alert(p+” = “+document[p]+“\n”); }
isNumber(val)
Events can be set to make a function run after a given number of milliseconds: setTimeout(“functionName()”, 100); To get an even to repeat, put this call inside the function itself and call it from body.onLoad
Event handlers can also be defined by naming an event handler. For example
document.onclick = clickHandler function clickHandler() { alert(“Click handled”); }
Note: The event handler when assigned should not be followed by parentheses
http://gleepglop.com/javascripts/logger/
This probably only works in Internet Explorer Make this my homepage
http://www.javascripttoolbox.com/ - with a fantastic javascript calendar. Cheers Matt.
Andrew McDonough is a consultant CTO and software developer, currently based between Berlin and London.
Follow Andrew on Twitter or Connect on LinkedIn