Javascript Notes: Difference between revisions

From Federal Burro of Information
Jump to navigationJump to search
No edit summary
No edit summary
Line 11: Line 11:
}
}
</pre>
</pre>
Also see [[jquery notes]]


[[Category:Javascript]]
[[Category:Javascript]]

Revision as of 01:07, 22 September 2013

function showattrs(theObject) {
   var out="<pre>"
   for (var attr in theObject) {
      out+=attr+":"+ theObject[attr]+"\n"
   }
   out+="</pre>"
 
   var block = document.getElementById("showattrs")
   block.innerHTML=out
}

Also see jquery notes