You are here: Re: Margins, background problem... « HTML « IT news, forums, messages
Re: Margins, background problem...

Posted by dorayme on 03/06/06 22:20

In article <Xns977E5DDD38F5Estanmccann@216.234.192.142>,
Stan McCann <me@stanmccann.us> wrote:

> dorayme <doraymeRidThis@optusnet.com.au> wrote in news:doraymeRidThis-
> 59DE0E.16464706032006@news-vip.optusnet.com.au:
>
> > I have put up at http://dorayme.150m.com/test1/main.html
> > something to illustrate something that puzzles me. I found I
> > could get rid of the white space below and above the inline list
> > by assigning negative bottom margin to the the banner div and
> > same for top margin for the content div. I can also, of course,
> > be rid of it by assigning suitable colours to backgrounds. But I
> > would rather like to understand what is going on here. The body
> > or html element is white by default and it presumably is shining
> > through. What is it shining through, precisely, if anything?
> >
> > I put a green (#CFC ) background for #navStrip in the css to try
> > to find out what exactly it is that is white! It does not show up
> > - except, surprise, surprise, in what we might as well call a
> > deprecated browser (IE 5 Mac) and then only covering the top
> > white space above the menu strip, not the bottom! In all my
> > modern browsers there is just the white space.
> >
> > I tried this green bg to various things to try to track down what
> > is going on but so far have failed. Any ideas?
> >
> > Is the inline link mark up and css not kosher? I don't know.
> >
>
> If I'm looking at the right thing, the <style> element way down the
> page? That is not supposed to be outside of the <head>.
>

I think you might be referring to something that the free domain
puts there. The problem I put up is independent of this, it shows
up off line. In my markup, I have my <head> ... <link
rel="stylesheet" type="text/css" href="main.css"> ... </head>

> As for your white space, I think it has to do with
> #navStrip ul { background-color: silver; text-align: left; margin-left:
> 0; padding-left: 0; border-bottom: 1px solid gray; }. Notice you don't
> set a top/bottom margin. Try margin:0 instead of margin-left:0.
>
> I also noted an <img> with width="100px" height="75px". px is
> understood. I don't remember for certain if this is an error but the
> px is certainly unneeded.

Yes, I usually don't put px in pics, I must have been trying to
be on best behaviour (how pathetic is this eh?) in order not to
distract commentators from concentrating on my prob by any lack
of units!.

As for the rest, yes, there is no practical problem. You are
right about setting margin. It is not super important I guess,
just I am puxxled (let me leave this typo in) as to _what_ is
defaulted to _what_. Did the ul have (in so many browsers) a
default margin of about 14px top and bottom? I say 14 because
that is the figure I found that got rid of it in setting negative
margins to bottom of #banner div and top of #content div!

--
dorayme

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация