• bigscaryrobot

    (@bigscaryrobot)


    I’m getting this error as soon as I load the page.

    Line: 25
    Char: 2
    Error: ‘document.getElementById(…)’ is null or not an object
    Code: 0
    URL: https://pistolsatnoonish.com/blog/

    I have no idea how to troubleshoot something like this. Any help would be greatly appreciated. I’m sure it’s something stupid I did while tinkering. ??

Viewing 1 replies (of 1 total)
  • Thread Starter bigscaryrobot

    (@bigscaryrobot)

    Well, not sure if this will fubar things down the road, but I just removed this bit from the header.php . . .

    <script type="text/javascript"><!--//--><![CDATA[//><!--
    sfHover = function() {
    	if (!document.getElementsByTagName) return false;
    	var sfEls = document.getElementById("nav").getElementsByTagName("li");
    
    	for (var i=0; i<sfEls.length; i++) {
    		sfEls[i].onmouseover=function() {
    			this.className+=" sfhover";
    		}
    		sfEls[i].onmouseout=function() {
    			this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
    		}
    	}
    
    }
    if (window.attachEvent) window.attachEvent("onload", sfHover);
    //--><!]]></script>

    . . . and the error is now gone. ??

Viewing 1 replies (of 1 total)
  • The topic ‘Error on Blog’ is closed to new replies.