Dethman Posted October 27, 2009 Share Posted October 27, 2009 here is the function it deals with I will mark line 55 for you function do_option() { var xmlHttp = getXMLHttp(); var id = document.getElementById("id").value; xmlHttp.onreadystatechange = function() { if(xmlHttp.readyState == 4) { handle_option(xmlHttp.responseText); } } var option = document.getElementById("options").value; xmlHttp.open("GET", "option_js.php?option=" + option + "", true); xmlHttp.send(null); } function handle_option(type){ // LINE 55 document.getElementById('abottomPart').innerHTML = type; } If anyone could explain to me why this error is appearing it would be great, Thank you for your views Link to comment https://forums.phpfreaks.com/topic/179138-solved-error-documentgetelementbyidabottompart-is-null-line-55/ Share on other sites More sharing options...
Calver Posted October 27, 2009 Share Posted October 27, 2009 Are you triggering the Ajax function before the document has been fully rendered, to include the 'abottomPart' element? Link to comment https://forums.phpfreaks.com/topic/179138-solved-error-documentgetelementbyidabottompart-is-null-line-55/#findComment-945592 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.