Im using a page fetch script to dynamically load a web page into a div. Heres the code. BTW Im using Firefox w/ Kubuntu
function fetch(URL, divId) {
req = window.XMLHttpRequest ? new XMLHttpRequest() : new ActiveXObject(MSXML2.XMLHTTP.3.0);
req.open(GET, URL);
req.onreadystatechange = function() {
if (req.readyState == 4 && req.status == 200) {
document.getElementById(divId).innerHTML = req.responseText;
}
}
req.send(null);
}
When i try to get it to load a page nothing happens and I get an error
Error: junk after document element
Source File: file:///home/amnite/Stuff/MetalBraska/Shows/ContentRight.html
Line: 2, Column: 1
Source Code:
<img src=Layout/HeaderDiv.jpg width=250px height=7px>