ArrayBuffer support / removed document.write portion