Javascript Notes

From Federal Burro of Information
Revision as of 16:06, 23 June 2010 by David (talk | contribs)
Jump to navigationJump to search
function showattrs(theObject) {
   var out=">pre<"
   for (var attr in theObject) {
      out+=attr+":"+ theObject[attr]+"\n"
   }
   out+="%gt;/pre<"
 
   var block = document.getElementById("showattrs")
   block.innerHTML=out
}