Re: STILL UNSOLVED: Is there a way to set "maximum width"?

by =?iso-8859-1?Q?St=E9phane?= Bergeron <stephberg(at)videotron.ca>

 Date:  Fri, 27 Apr 2001 07:23:12 -0400
 To:  Jay Smith <jay(at)JaySmith.com>
 Cc:  hwg-techniques(at)hwg.org
 References:  one
  todo: View Thread, Original
At 08:13 PM 26/04/01 -0400, you wrote:
>If I could figure out (help?) how to get IE and NS to put the same
>space above and below tables, I could use tables and life would be
>good.
>
>Here are links to a UGLY page that has too much space above tables
>(and headlines) in NS, but is nice and "tight" in IE.
>    http://www.jaysmith.com/lists/by/aland_christmas_seal_list.html
>
>And a text version of my current CSS.
>    http://www.JaySmith.com/jsa.css.txt
>
>BY THE WAY, to my knowledge, using tables STILL does not solve the
>problem of MAXIMUM width.


First of all, max-width and min-width are CSS 3 properties and that spec=20
isn't out yet to my knowledge and unsupported in any browser at this=20
time.  You could take a look to the ALA article here on how they redesigned=
=20
their site to rely on CSS only and achieved a liquid layout:=20
http://www.alistapart.com/stories/journey/

Secondly, there are a few of serious errors in your code.  In the table=20
with class "PL", you specify the width as "300px".  Remove the px as it's=20
invalid in an HTML attribute and belongs in style sheets only.  In the same=
=20
table code you specify cellspacing as ".5".  I don't think any browser=20
supports fractional values or values below 1 for that attribute or any=20
attribute.  Change it to 1.  More serious still, you have redundant closing=
=20
body and html tags at the bottom of your document and that alone may throw=
=20
off Netscape 4 and with good reason.  The only good thing (IMO) about that=
=20
browser is that it doesn't tolerate sloppy code.  I wish IE acted the same=
=20
regarding this actually.

Another thing is that your doctype declaration at the top is not valid as=20
the URL to the DTD is not an absolute URL.  I'd recommend changing Hot=20
Metal's preferences (if that's possible, I use HomeSite 4.5.2 and UD 4=20
myself) to have it insert a more widely supported DTD such as HTML 4.01=20
Transitional.  The W3C validator can't validate this page because it can't=
=20
find the DTD and no browser that I know of supports that DTD.  Better stick=
=20
to HTML 4.01.

>I can put text into tables and use percentages, etc., but if a user
>has a large monitor and is running at high-res, the line length is way
>too long to read (according to me and all the stuff I read about
>readability in print and on the screen).

People who use very large screens and res are usually savvy enough to surf=
=20
with their browser window set to a smaller width than that of the whole=20
screen.  Most of the Web would look horrible if they always surfed at 1600=
=20
x 1200 for instance with a maximized browser window.  I think you should=20
test how a liquid layout looks at 800x600 and 1024x768 and not worry too=20
much about higher resolutions than that.

Lastly, looking at your style sheet, I think you should definitely stick to=
=20
pixels for specifying sizes, especially for margin and padding as it will=20
yield much more consistent results (this may be part of your problem here=20
actually). I'd stick to pixels as well for sizing text if you want=20
consistency.  Read the following article for details:=20
http://www.alistapart.com/stories/fear4/

HTH!

St=E9phane Bergeron

HWG hwg-techniques mailing list archives, maintained by Webmasters @ IWA