User:Mugserrant/comm.js

topaz.comm = { doreq:function(url,postdata,headers) { var req = topaz.util.xmlhttpreq; req.open(postdata?"POST":"GET", url, false); for(header in headers) { req.setRequestHeader(header,headers[header]); } req.send(postdata||null); return req; } };