Sat, Jan 29 2005 2:13 PM
Ernst Wolthaus
Usefull bit of javascript
Even though .NET and ASP.NET keeps getting better and better, a lot of times we still need to use javascript on the client to reduces roundtrips or to get more dynamic websites.
So here's a piece of javascript code I find very usefull to show the properties of any (HTML) object:
function ShowProps(obj)
{
var names = "";
for (var name in obj) names += name + "; ";
alert(names);
}
Be carefull, allthough it enumerates all user-defined properties, it doesn't enumerate certain predefined props or mehods...
Filed under: Programming general