Printable Version of Topic

Click here to view this topic in its original format

HTMLHelp Forums _ Cascading Style Sheets _ Website ok in IE, horrible in Firefox, help please

Posted by: Grumbleduke Oct 23 2007, 12:37 PM

I started designing a website the other day and decided to use tables and css instead of frames.

All went well and the page looks fine in IE7

Then I checked it in firefox and the page is unreadable.

The page is http://www.lothiancomputersolutions.com/events

Can anyone help please?

Cheers
Andy

Posted by: Darin McGrew Oct 23 2007, 12:59 PM

QUOTE(Grumbleduke @ Oct 23 2007, 10:37 AM) *
Then I checked it in firefox and the page is unreadable.
In what way is it "unreadable"?

QUOTE(Grumbleduke @ Oct 23 2007, 10:37 AM) *
The page is http://www.lothiancomputersolutions.com/events
Actually, it's http://www.lothiancomputersolutions.com/events/ (note the / at the end of the URL). But regardless...

You do have http://htmlhelp.com/cgi-bin/validate.cgi?url=http%3A%2F%2Fwww.lothiancomputersolutions.com%2Fevents%2F&warnings=yes, which our online validator reports. You can't put block-level elements inside heading (h1-h6) elements).

But the main thing I noticed is that some of your page is centered, and some of it is aligned left. Depending on the width of the browser window, you can end up with red-on-red text. The best approach would be to fix the design so it adapts gracefully to whatever size display area is available. But if you stick with the fixed-width layout, then you need to center it or align it left, and not mix the two.

Posted by: Grumbleduke Oct 24 2007, 05:25 AM

It's the alignment that is giving me the problem, the plan is to use the <div> tag to center a table containing the menu to the left and the page body to the right, but the centering doesnt work in firefox, is there an easy fix for this?

I'll fix the markup problem just now smile.gif

Posted by: Darin McGrew Oct 24 2007, 08:26 AM

The text-align attribute centers only inline (text-level) content. It doesn't center block-level elements. MSIE gets this wrong unless it's in standards mode, and your doctype declaration puts it in http://hsivonen.iki.fi/doctype/.

See http://www.w3.org/Style/Examples/007/center.html.

Posted by: Grumbleduke Oct 25 2007, 03:19 AM

Excellent, thanks smile.gif

Powered by Invision Power Board (http://www.invisionboard.com)
© Invision Power Services (http://www.invisionpower.com)