Hitman
01-11-2009, 02:46 PM
Hi, I've got this code:
function setOutput(){
if(httpObject.readyState == 4){
document.getElementById('whatever').value = httpObject.responseText;
}
}
The whole script is getting something, basically, and putting it onto the page... but it only puts it in an input box, not a div.
For example, it shows what I want with
<input id="whatever" />
But with
<div id="whatever"></div>
it does nothing... I'm a newbie with javascript so if anybody could help... thanks.
function setOutput(){
if(httpObject.readyState == 4){
document.getElementById('whatever').value = httpObject.responseText;
}
}
The whole script is getting something, basically, and putting it onto the page... but it only puts it in an input box, not a div.
For example, it shows what I want with
<input id="whatever" />
But with
<div id="whatever"></div>
it does nothing... I'm a newbie with javascript so if anybody could help... thanks.