This is Interesting: Free Magazines for Graphics designers and webmasters
Home > Archive > Stylesheets > April 2006 > Not sure what is happening here
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Not sure what is happening here
|
|
|
| When I write a simple height or width CSS for a tag using percentage it
seems to give unreliable results.
..BannerPurple
{
background-color: #660066;
height: 60%;
width: 50%;
}
on IE the height and width are not modifiied yet the background-color is. On
Firefox and NN the height and width are modified.
When I use
..BannerGreen
{
background-color: #004401;
height: 50px;
width: 2340px;
}
the height and width are modified on both browsers. I have been reading all
over the web but have not found what I am doing incorrectly. Oh I "have"
tried setting position but still have mixed results.
Would someone please tell me what it is I am doing incorrectly?
Thanks
--
Totus possum, totum Deum.
Totus ero, totum meum.
WSW
| |
| Neredbojias 2006-04-20, 3:42 am |
| To further the education of mankind, "News"
<warren@no_S_P_A_M_wyght.com> vouchsafed:
> When I write a simple height or width CSS for a tag using percentage
> it seems to give unreliable results.
>
> .BannerPurple
> {
> background-color: #660066;
> height: 60%;
> width: 50%;
> }
>
> on IE the height and width are not modifiied yet the background-color
> is. On Firefox and NN the height and width are modified.
>
> When I use
>
> .BannerGreen
> {
> background-color: #004401;
> height: 50px;
> width: 2340px;
> }
>
> the height and width are modified on both browsers. I have been
> reading all over the web but have not found what I am doing
> incorrectly. Oh I "have" tried setting position but still have mixed
> results.
>
> Would someone please tell me what it is I am doing incorrectly?
Kind of hard to say with just those snippets. A url might facilitate
assistance.
--
Neredbojias
Infinity has its limits.
| |
|
| Neredbojias wrote:
> To further the education of mankind, "News"
> <warren@no_S_P_A_M_wyght.com> vouchsafed:
>
>
> Kind of hard to say with just those snippets. A url might facilitate
> assistance.
Here is the css file
http://www.wyght.com/htdocs/warren/testBanner.css
Here is the URL
http://www.wyght.com/warren/ieTMbanner.html
The height does not seem to be working at all, where as sometimes the width
seems to be working when I use percentage
--
Totus possum, totum Deum.
Totus ero, totum meum.
WSW
| |
| Neredbojias 2006-04-20, 6:44 am |
| To further the education of mankind, "News"
<warren@no_S_P_A_M_wyght.com> vouchsafed:
.....
>
> Here is the css file
> http://www.wyght.com/htdocs/warren/testBanner.css
>
> Here is the URL
> http://www.wyght.com/warren/ieTMbanner.html
>
> The height does not seem to be working at all, where as sometimes the
> width seems to be working when I use percentage
This will have other reprecussions for the page, but put the following in
the css:
html,body { height:100%; }
This gives the divs a reference which is needed in today's css.
--
Neredbojias
Infinity has its limits.
| |
|
| Neredbojias wrote:
> To further the education of mankind, "News"
> <warren@no_S_P_A_M_wyght.com> vouchsafed:
>
> ....
>
> This will have other reprecussions for the page, but put the
> following in the css:
>
> html,body { height:100%; }
>
> This gives the divs a reference which is needed in today's css.
Well that seems to work fine in IE but not in NN or FireFox
What I did for NN, FF and Opera was put in position: absolute;
From what I know that is not always the best either, but what is the
negitive side effect of having body{height: 100%}?
Thanks for your help
--
Totus possum, totum Deum.
Totus ero, totum meum.
WSW
| |
| Neredbojias 2006-04-20, 7:25 pm |
| To further the education of mankind, "News" <warren@no_S_P_A_M_wyght.com>
vouchsafed:
> Neredbojias wrote:
>
> Well that seems to work fine in IE but not in NN or FireFox
Strange. I checked it in Firefox. Oh, well...
> What I did for NN, FF and Opera was put in position: absolute;
That may be the best solution. -And IE6 doesn't "do" position:fixed,
anyway.
> From what I know that is not always the best either, but what is the
> negitive side effect of having body{height: 100%}?
I use it when trying to vertically-center small content, and that, along
with other related css, can cause all kinds of anomalous havoc in various
browsers.
--
Neredbojias
Infinity has its limits.
| |
|
| Neredbojias wrote:
> To further the education of mankind, "News"
> <warren@no_S_P_A_M_wyght.com> vouchsafed:
>
>
> Strange. I checked it in Firefox. Oh, well...
>
>
> That may be the best solution. -And IE6 doesn't "do" position:fixed,
> anyway.
>
>
> I use it when trying to vertically-center small content, and that,
> along with other related css, can cause all kinds of anomalous havoc
> in various browsers.
Thanks for your help in this, what I chose to do was make a img banner and
place that in a <div class="container"> which enables me to place it have
the width and height as I want them to be.
--
Totus possum, totum Deum.
Totus ero, totum meum.
WSW
|
|
|
| | Copyright 2003 - 2008 forum4designers.com Software forum Computer Hardware reviews |
|