Sitepoint's Catfish Tutorial - Javascript Error

I finally finished the first part of the Catfish tutorial from Sitepoint (it’s awesome, thanks), but am having an issue wit the catfish.js javascript file.

Any time I try to include it the page breaks. Without the entire <if IE> area I can have the footer open fine in IE8 and off center in IE7.

Then I add the IEhack.css and that works fine also, save for the fact that I lose my scrollbars, hence why I need the js included to make it all come together.

But when I have the js included also, the page breaks (my blogads get distorted amongst other things). IE isn’t giving me much of an error to off of, but the footer still appears but without scroll bars on the page.

Webpage error details

User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C)
Timestamp: Fri, 25 Feb 2011 10:06:42 UTC

Message: Object expected
Line: 20
Char: 1
Code: 0

Anybody else have this issue? I don’t have IE6 to test what happens there. Maybe the javascript works properly in IE6?


I wanted to see what error Firefox would give, and got rid of the IE condition. Firefox didn’t like the addLoadEvent function. Called it undefined.

Possible that IE is experiencing same issue?



No responses yet, so let me just give a demonstration of the Catfish javascript erroring out.

without the javascript:

with the javascript:

You’ll see the page fails to load properly on the second one that has the javascript included.

Why is that? There is nothing on this page to interfere with the code. Why is it erroring out one blank page but work on the sitepoint example?


Nevermind. Figured it out. There was a tiny little script not mentioned in the tutorial that Sitepoint was using.