Javascript Notes

From Federal Burro of Information
Revision as of 16:03, 23 June 2010 by David (talk | contribs) (New page: <pre> function showattrs(theObject) { var out="<pre>" for (var attr in theObject) { out+=attr+":"+ theObject[attr]+"\n" } out+="</pre>" var block = document.getElem...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

function showattrs(theObject) {
   var out="<pre>"
   for (var attr in theObject) {
      out+=attr+":"+ theObject[attr]+"\n"
   }
   out+="

"

  var block = document.getElementById("showattrs")
  block.innerHTML=out

}