al posto di:
eanch.setAttribute("onclick","boo("+id+");");

metti:
eanch.onclick = function(){boo(id);}