Fog Creek Software
Discussion Board




Knowledge Base
Documentation
Terry's Tips
Darren's Tips

Not Every Bug is a CD Bug

I've had an odd Java Script problem with 2.0.5

I use CD to create HTML-Help files. I use some Java Script to provide a NSR (non-scrolling region) on each page. When I updated a project of mine to the beta the NSR in the new version would reduce itself to a one line area the width of the page. I wasn't having the problem with the earlier version so I blamed the CD beta (naturally) and reported this problem as a bug. I eventually sorted out the problem, or rather found a fix, and figured I post the results here in case some one else is experiencing similar problems and it may help out as a place to start your search.

In a nut shell, either removing the "<!DOCTYPE ... > statement from the top of each page OR (get this) placing a <!-- comment on the line before the DocType, like the old version did automatically - that some people had removed (grrrr) --> will make the problem disappear and the Java Script works as intended. Maybe a JS pro can have a look and figure out what's actually happening. I can interpret the code - I just can't write it.
If you're interested, download my HTML-Help template from http://tinyurl.com/a34m , add a DocType statement to any/all the  CD-Templates and "Preview on this computer".

Putting a DocType statement in a HTML-Help file isn't very useful so this was easy and prbably pretty smart to fix, thanx to CD, finding the problem was a bit of a different matter - but fun.

Dave
Saturday, July 05, 2003

Sheesh, interruptions, and always when you're in the middle of something!

>  NSR in the new version would reduce itself to
> a one line area the width of the page

It's the scrolling region that reduces to one line, sorry.

Dave
Saturday, July 05, 2003

Can you post a url to a page where the problem shows up?

Removing the doctype or inserting the comment above it both do the same thing on IE6 -- Turn on quirks mode.

Quirks mode makes IE6 display like it did with IE5.5 which had an incorrect way of displaying boxes. 

Have you tested your weirdly displaying pages with Netscape 7 or Opera7 or IE5 for Apple?

Joel Goldstick
Saturday, July 05, 2003

Hi Joel, Thanx for the response.

How in the fox creek did !DOCTYPE end up a science of it's own? Crap!  I'm lookiking into it. Glad HTML-Help only deals with EI.

Sheesh! "Quirk Mode" who'd have thought - so much for standards.

Found some info at:
http://gutfeldt.ch/matthias/articles/doctypeswitch/table.html
for any-one who needs it.

Dave
Saturday, July 05, 2003

OK, I got it now.

Dave
Saturday, July 05, 2003

*  Recent Topics

*  Fog Creek Home