Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

ie9 not applying css to header or footer, firefox works great

1,038 views
Skip to first unread message

roberts...@gmail.com

unread,
May 22, 2013, 1:43:08 PM5/22/13
to
Hi,

I am trying to rewrite a website in html5. The code I have works in firefox, but it doesn't work in IE9. In IE9 the blue bars are missing and the header is left justified even though I told it right justification. I did a search for IE9 css problems only to find css problems for IE8 and below. I ran the code through validator.w3.org and it comes back clean. I am using IE9 fully patched on a fully patched Windows 7 x64 computer. IE10 won't be deployed until next year so I have to use IE9. Am I doing something wrong?

Thank you,
Bob

<!DOCTYPE html>
<html>
<head>
<title>website</title>
<meta charset="UTF-8">
<meta name="description" content="This is a test website">

<style>
html {
height: 100%;
}

body {
width: 800px;
margin: 0 auto;
padding: 0;
background-color: #FFFFFF;
background: -webkit-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
background: -webkit-gradient(linear, left top, right bottom, color-stop(0%,#C13B5A), color-stop(100%,#ffffff));
background: -moz-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
background: -o-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
background: -ms-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
background: linear-gradient(to bottom, #C13B5A 0%, #ffffff 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#C13B5A', endColorstr='#ffffff', GradientType=0 );
}

section,article,aside{
display: block;
}

header {
display: block;
line-height:22px;
vertical-align:middle;
height:106px;
text-align:right;
background-color:#36436F;
background-repeat: no-repeat;
padding-right:10px;
}

footer {
line-height: 22px;
vertical-align:middle;
height:22px;
text-align:left;
background-color:#36436F;
background-repeat: no-repeat;
color:#ffffff;
padding-left: 25px;
}
</style>
</head>

<body>
<header>
<a href="/" style='color:white'
onmouseover="this.style.color='yellow';"
onmouseout="this.style.color='white';">Home</a>&nbsp;
&bull;&nbsp;

<a href="/News.asp" >News</a>
&bull;&nbsp;

<a href="/ContactUs.asp" style='color:white'
onmouseover="this.style.color='yellow';"
onmouseout="this.style.color='white';">Contact Us</a>
</header>

<p> this is a test</p>

<footer>
Footer info.
</footer>
</body>
</html>

Thomas 'PointedEars' Lahn

unread,
May 22, 2013, 4:55:14 PM5/22/13
to
roberts...@gmail.com wrote:
^^^^^^^^^^^^^^^^^^^^^^^^
Please fix that.

> I am trying to rewrite a website in html5. The code I have works in

_HTML5_

> firefox, but it doesn't work in IE9. In IE9 the blue bars are missing and
> the header is left justified even though I told it right justification. I
> did a search for IE9 css problems only to find css problems for IE8 and
> below. I ran the code through validator.w3.org and it comes back clean.

The W3C Validator cannot not check for semantic or compatibility problems.
Also, HTML5 support is still experimental there.

> I am using IE9 fully patched on a fully patched Windows 7 x64 computer.

You should post the unforged User-Agent header field value (or
navigator.userAgent value) next time.

> IE10 won't be deployed until next year so I have to use IE9. Am I doing
> something wrong?

Probably, see <news:2354532.M...@PointedEars.de>

> <!DOCTYPE html>
> <html>
> <head>
> <title>website</title>

<http://www.w3.org/QA/Tips/good-titles>

> <meta charset="UTF-8">
> <meta name="description" content="This is a test website">

You can't be serious.

> <style>

It is probably a good idea to still specify the ”type” attribute on the
“style” and “script” elements for the time being.

> html {
> height: 100%;

Without effect as the element is not positioned.

> }
>
> body {
> width: 800px;
^^^^^
You can't be serious. Ever heard of wide-screen displays and Responsive Web
Design (RWD)?

> margin: 0 auto;
> padding: 0;
> background-color: #FFFFFF;

background-color: #fff;

is more compatible.

The corresponding “color” declaration is missing, potentially causing
usability issues:

<http://www.w3.org/QA/Tips/color>

> background: -webkit-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
> background: -webkit-gradient(linear, left top, right bottom,
> color-stop(0%,#C13B5A), color-stop(100%,#ffffff));

AFAIK the order of those two declarations should be swapped.
-webkit-gradient(…) is the older, AFAIK less efficient, more buggy, less
standards-compliant function for earlier Safari versions, now deprecated:

<https://www.webkit.org/blog/1424/css3-gradients/>

> background: -moz-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
> background: -o-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
> background: -ms-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
> background: linear-gradient(to bottom, #C13B5A 0%, #ffffff
> 100%); filter:
> progid:DXImageTransform.Microsoft.gradient(startColorstr='#C13B5A',
> endColorstr='#ffffff', GradientType=0 );
> }

For the corporate website of a large international company we had eventually
decided not to use gradients for IE at all (neither filter nor -ms-linear-
gradient) because of text on those elements becoming partially translucent
and “click-transparent” (for lack of a better word) in IE < 9. Since that
was for a dropdown navigation menu, this behavior was not acceptable since
the text links could not be triggered in all places of the glyphs as a
result.

> section,article,aside{
> display: block;
> }
>
> header {
> display: block;
> line-height:22px;
^
Please don't.

> vertical-align:middle;
> height:106px;
^^
Please don't.

> text-align:right;
> background-color:#36436F;

If the value #333366 for a similar color would be acceptable instead, you
could use the color-depth independent value, #336:

<http://www.w3.org/TR/css3-color/#numerical>

> background-repeat: no-repeat;

No “background-image” declaration, no need to declare “background-repeat”.

> padding-right:10px;

Your design does not scale to the font-size. Use “em” instead of ”px”
almost always.

> }
>
> footer {

Missing

display: block;

> [same problems as above]
> }
> </style>
> </head>
>
> <body>
> <header>

This should probably be

<header>
<nav>

See also: <http://html5doctor.com/downloads/h5d-sectioning-flowchart.png>

> <a href="/" style='color:white'
> onmouseover="this.style.color='yellow';"
> onmouseout="this.style.color='white';">Home</a>&nbsp;

Please do not use client-side scripting for that, there are CSS pseudo-
classes (*at least* the hyperlink text colors should differ between normal,
:hover, :visited, :focus and :active):

<http://www.w3.org/TR/css3-selectors/#pseudo-classes>

> &bull;&nbsp;
> <a href="/News.asp" >News</a>

This is asemantic, therefore not interoperable and not accessible. Use list
elements like “ol”, “ul”, or “dl” instead:

<http://www.w3.org/TR/2012/CR-html5-20121217/grouping-content.html#grouping-content>

And please do not misuse the &nbsp; CRE for spacing. If you need more
spacing, use margins and/or paddings:

<http://www.w3.org/TR/CSS2/box.html#box-dimensions>


PointedEars
--
Use any version of Microsoft Frontpage to create your site.
(This won't prevent people from viewing your source, but no one
will want to steal it.)
-- from <http://www.vortex-webdesign.com/help/hidesource.htm> (404-comp.)

Thomas 'PointedEars' Lahn

unread,
May 22, 2013, 4:56:02 PM5/22/13
to
roberts...@gmail.com wrote:
^^^^^^^^^^^^^^^^^^^^^^^^
Please fix that.

> I am trying to rewrite a website in html5. The code I have works in

_HTML5_

> firefox, but it doesn't work in IE9. In IE9 the blue bars are missing and
> the header is left justified even though I told it right justification. I
> did a search for IE9 css problems only to find css problems for IE8 and
> below. I ran the code through validator.w3.org and it comes back clean.

The W3C Validator cannot check for semantic or compatibility problems.
Also, HTML5 support is still experimental there.

> I am using IE9 fully patched on a fully patched Windows 7 x64 computer.

You should post the unforged User-Agent header field value (or
navigator.userAgent value) next time.

> IE10 won't be deployed until next year so I have to use IE9. Am I doing
> something wrong?

Probably, see <news:2354532.M...@PointedEars.de>

> <!DOCTYPE html>
> <html>
> <head>
> <title>website</title>

<http://www.w3.org/QA/Tips/good-titles>

> <meta charset="UTF-8">
> <meta name="description" content="This is a test website">

You can't be serious.

> <style>

It is probably a good idea to still specify the ”type” attribute on the
“style” and “script” elements for the time being.

> html {
> height: 100%;

Without effect as the element is not positioned.

> }
>
> body {
> width: 800px;
^^^^^
You can't be serious. Ever heard of wide-screen displays and Responsive Web
Design (RWD)?

> margin: 0 auto;
> padding: 0;
> background-color: #FFFFFF;

background-color: #fff;

is more compatible.

The corresponding “color” declaration is missing, potentially causing
usability issues:

<http://www.w3.org/QA/Tips/color>

> background: -webkit-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
> background: -webkit-gradient(linear, left top, right bottom,
> color-stop(0%,#C13B5A), color-stop(100%,#ffffff));

AFAIK the order of those two declarations should be swapped.
-webkit-gradient(…) is the older, AFAIK less efficient, more buggy, less
standards-compliant function for earlier Safari versions, now deprecated:

<https://www.webkit.org/blog/1424/css3-gradients/>

> background: -moz-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
> background: -o-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
> background: -ms-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
> background: linear-gradient(to bottom, #C13B5A 0%, #ffffff
> 100%); filter:
> progid:DXImageTransform.Microsoft.gradient(startColorstr='#C13B5A',
> endColorstr='#ffffff', GradientType=0 );
> }

For the corporate website of a large international company we had eventually
decided not to use gradients for IE at all (neither filter nor -ms-linear-
gradient) because of text on those elements becoming partially translucent
and “click-transparent” (for lack of a better word) in IE < 9. Since that
was for a dropdown navigation menu, this behavior was not acceptable since
the text links could not be triggered in all places of the glyphs as a
result.

> section,article,aside{
> display: block;
> }
>
> header {
> display: block;
> line-height:22px;
> <a href="/" style='color:white'
> onmouseover="this.style.color='yellow';"
> onmouseout="this.style.color='white';">Home</a>&nbsp;

Please do not use client-side scripting for that, there are CSS pseudo-
classes (*at least* the hyperlink text colors should differ between normal,
:hover, :visited, :focus and :active):

<http://www.w3.org/TR/css3-selectors/#pseudo-classes>

> &bull;&nbsp;
> <a href="/News.asp" >News</a>

Bob

unread,
May 22, 2013, 7:24:49 PM5/22/13
to
On Wednesday, May 22, 2013 3:55:14 PM UTC-5, Thomas 'PointedEars' Lahn wrote:
> Bob wrote:
> ^^^^^^^^^^^^^^^^^^^^^^^^
> Please fix that.

I think I have. Please let me know if I did not fix it.

> > I am trying to rewrite a website in html5. The code I have works in
>
> _HTML5_
>
> > firefox, but it doesn't work in IE9. In IE9 the blue bars are missing and
> > the header is left justified even though I told it right justification. I
> > did a search for IE9 css problems only to find css problems for IE8 and
> > below. I ran the code through validator.w3.org and it comes back clean.
>
> The W3C Validator cannot not check for semantic or compatibility problems.
>
> Also, HTML5 support is still experimental there.
>
> > I am using IE9 fully patched on a fully patched Windows 7 x64 computer.
>
> You should post the unforged User-Agent header field value (or
> navigator.userAgent value) next time.

How do I do this?

> > IE10 won't be deployed until next year so I have to use IE9. Am I doing
> > something wrong?
>
> Probably, see <news:2354532.M...@PointedEars.de>

I used groups.google.com to search for that posting but nothing comes up except your response to my posting.

> > <!DOCTYPE html>
> > <html>
> > <head>
> > <title>website</title>
> > <meta charset="UTF-8">
> > <meta name="description" content="This is a test website">
>
> You can't be serious.

This is just a page that includes enough content to demonstrate the problem. I don't think anyone wants me to post 20 pages of code.

> > <style>
>
> It is probably a good idea to still specify the ”type” attribute on the
> “style” and “script” elements for the time being.
>
> > html {
> > height: 100%;
>
> Without effect as the element is not positioned.
> > }
> >
> > body {
> > width: 800px;
> ^^^^^
> You can't be serious. Ever heard of wide-screen displays and Responsive Web
> Design (RWD)?

I use wide-screen displays everyday. I have 2 on my desk. The width is fixed because of pictures. No I have not heard of Responsive Web Design (RWD). I will have to look it up.

> > margin: 0 auto;
> > padding: 0;
> > background-color: #FFFFFF;
>
> background-color: #fff;
> is more compatible.
>
> The corresponding “color” declaration is missing, potentially causing
> usability issues:
>
> <http://www.w3.org/QA/Tips/color>
>
> > background: -webkit-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
> > background: -webkit-gradient(linear, left top, right bottom,
> > color-stop(0%,#C13B5A), color-stop(100%,#ffffff));
>
> AFAIK the order of those two declarations should be swapped.
>
> -webkit-gradient(…) is the older, AFAIK less efficient, more buggy, less
> standards-compliant function for earlier Safari versions, now deprecated:
>
> <https://www.webkit.org/blog/1424/css3-gradients/>

-webkit-gradient is used by old versions of chrome and safari 4 until 5.1. It looks like the latest version of safari is 6.04 so I will remove that line. I only care about browsers from the last 3 or 4 years. IE6-IE8 will disappear next when XP dies. Vista supports IE9 but not IE10 so that becomes least browser I care about for windows.

> > background: -moz-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
> > background: -o-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
> > background: -ms-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
> > background: linear-gradient(to bottom, #C13B5A 0%, #ffffff
> > 100%); filter:
> > progid:DXImageTransform.Microsoft.gradient(startColorstr='#C13B5A',
> > endColorstr='#ffffff', GradientType=0 );
> > }
>
> For the corporate website of a large international company we had eventually
> decided not to use gradients for IE at all (neither filter nor -ms-linear-
> gradient) because of text on those elements becoming partially translucent
> and “click-transparent” (for lack of a better word) in IE < 9. Since that
> was for a dropdown navigation menu, this behavior was not acceptable since
> the text links could not be triggered in all places of the glyphs as a
> result.

Thank you for the warning. The original website has the gradient as a jpg so if I need to I can go back and get that.

> > section,article,aside{
> > display: block;
> > }
> >
> > header {
> > display: block;
> > line-height:22px;
> ^
> Please don't.
>
> > vertical-align:middle;
> > height:106px;
> ^^
> Please don't.
>
> > text-align:right;
> > background-color:#36436F;
>
> If the value #333366 for a similar color would be acceptable instead, you
> could use the color-depth independent value, #336:
>
> <http://www.w3.org/TR/css3-color/#numerical>
>
> > background-repeat: no-repeat;
>
> No “background-image” declaration, no need to declare “background-repeat”.
>
> > padding-right:10px;
>
> Your design does not scale to the font-size. Use “em” instead of ”px”
> almost always.

I have made the switch.

> > }
> >
> > footer {
> Missing
> display: block;

Fixed

> > [same problems as above]
> > }
> > </style>
> > </head>
> >
> > <body>
> > <header>
>
> This should probably be
>
> <header>
> <nav>
>
> See also: <http://html5doctor.com/downloads/h5d-sectioning-flowchart.png>
>
> > <a href="/" style='color:white'
> > onmouseover="this.style.color='yellow';"
> > onmouseout="this.style.color='white';">Home</a>&nbsp;
>
> Please do not use client-side scripting for that, there are CSS pseudo-
> classes (*at least* the hyperlink text colors should differ between normal,
> :hover, :visited, :focus and :active):

Thank you for the hints. I have wanted that code to go away for awhile I just didn't know how.

> <http://www.w3.org/TR/css3-selectors/#pseudo-classes>
> > &bull;&nbsp;
> > <a href="/News.asp" >News</a>
>
> This is asemantic, therefore not interoperable and not accessible. Use list
> elements like “ol”, “ul”, or “dl” instead:
>
> <http://www.w3.org/TR/2012/CR-html5-20121217/grouping-content.html#grouping-content>

Fixed but the bullets don't show up.

> And please do not misuse the &nbsp; CRE for spacing. If you need more
> spacing, use margins and/or paddings:
>
> <http://www.w3.org/TR/CSS2/box.html#box-dimensions>

After addressing most of the issues you pointed out IE still does not display the blue background while firefox does.

Here is the latest version of the code:

<!DOCTYPE html>
<html>
<head>
<title>website</title>
<meta charset="UTF-8">
<meta name="description" content="This is a test website">

<style type="text/css">
html {
height: 100%;
position: relative;
}

body {
height: 100%;
width: 800px;
margin: 0 auto;
padding: 0;
background-color: #FFF;
color: #000;
background: -webkit-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
background: -moz-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
background: -o-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
background: -ms-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
background: linear-gradient(to bottom, #C13B5A 0%, #ffffff 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#C13B5A', endColorstr='#ffffff', GradientType=0 );
}

section,article,aside{
display: block;
}

header {
display: block;
line-height:1.5em;
vertical-align:middle;
text-align:right;
background-color:#336;
color:#000;
padding-right:10px;
}

footer {
display: block;
line-height: 1.5em;
vertical-align:middle;
text-align:left;
background-color:#336;
color:#fff;
padding-left: 2em;
}

a, a:link, a:visited {
text-decoration: none;
color: #fff;
}
a:hover, a:focus { color: yellow; }

ul {
list-style-type: disc;
display: list-item;
text-align:right;
padding-right:1em;
margin:0;
}

li {
display:inline;
padding: 1em;
}

</style>
</head>

<body>
<header>
<ul>
<li><a href="/">Home</a></li>
<li><a href="/News.asp">News</a></li>
<li><a href="/ContactUs.asp">Contact Us</a></li>
</ul>
</header>
<nav>
</nav>

Jukka K. Korpela

unread,
May 22, 2013, 7:37:22 PM5/22/13
to
2013-05-23 2:24, Bob wrote:

> On Wednesday, May 22, 2013 3:55:14 PM UTC-5, Thomas 'PointedEars' Lahn wrote:

Just ignore the troll.

>>> I am trying to rewrite a website in html5.

Stop doing that. It's not any more productive that reading the pointless
babbling of the troll.

When you have a real problem that needs a solution, post a URL and
specify exactly what you regard as the problem, in a manner that lets
everyone see immediately what your problem is.

--
Yucca, http://www.cs.tut.fi/~jkorpela/

dorayme

unread,
May 22, 2013, 9:39:46 PM5/22/13
to
In article <d744d2b8-bc10-4d60...@googlegroups.com>,
roberts...@gmail.com wrote:

> I am trying to rewrite a website in html5. The code I have works in firefox,
> but it doesn't work in IE9. In IE9 the blue bars are missing and the header
> is left justified even though I told it right justification. I did a search
> for IE9 css problems only to find css problems for IE8 and below. I ran the
> code through validator.w3.org and it comes back clean. I am using IE9 fully
> patched on a fully patched Windows 7 x64 computer. IE10 won't be deployed
> until next year so I have to use IE9. Am I doing something wrong?

Did you try validating the CSS? Try it.

Did you try using DIVS with classes, for example:

<div class="header">...</div>

instead of <header>...</header>

(the safer course)

--
dorayme

Gus Richter

unread,
May 23, 2013, 1:52:26 PM5/23/13
to
On 5/22/2013 1:43 PM, roberts...@gmail.com wrote:
> I am trying to rewrite a website in html5. The code I have works in firefox, but it doesn't work in IE9.

1. New HTML5 semantic elements are missing support by the browsers, so
you have not provided display:block; for the header and footer
elements which I have now included.

2. I've applied your background declarations to the HTML element
instead of the BODY element.
N.B., going forward, Google and Mozilla will no longer use the
Vendor Prefixes.

3. I have added the lang attribute to the HTML element (lang="en")

4. I have placed the meta specifying the UTF-8 charset immediately after
the HEAD element.

5. I have included "HTML5 Shiv" - a script section which is needed for
IE8 at least to make it support the new elements.
Use <http://caniuse.com/> to check for support (e.g.
<http://caniuse.com/#search=section> ).

6. Congratulations for using HTML5.
Here is my revised version:



<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>website</title>
<meta name="description" content="This is a test website">

<style>
html {
height: 100%;
background-color: #FFFFFF;
background: -webkit-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
background: -webkit-gradient(linear, left top, right bottom,
color-stop(0%,#C13B5A), color-stop(100%,#ffffff));
background: -moz-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
background: -o-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
background: -ms-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
background: linear-gradient(to bottom, #C13B5A 0%, #ffffff
100%);
filter:
progid:DXImageTransform.Microsoft.gradient(startColorstr='#C13B5A',
endColorstr='#ffffff', GradientType=0 );
}

body {
width: 800px;
margin: 0 auto;
}

section,article,aside,header,footer{
display: block;
}

header {
line-height:22px;
vertical-align:middle;
height:106px;
text-align:right;
background-color:#36436F;
background-repeat: no-repeat;
padding-right:10px;
}

footer {
line-height: 22px;
vertical-align:middle;
height:22px;
text-align:left;
background-color:#36436F;
background-repeat: no-repeat;
color:#ffffff;
padding-left: 25px;
}
</style>

<script>
document.createElement("section");
document.createElement("article");
document.createElement("aside");
document.createElement("header");
document.createElement("footer");
</script>

Jukka K. Korpela

unread,
May 23, 2013, 2:06:27 PM5/23/13
to
2013-05-23 20:52, Gus Richter wrote:

> On 5/22/2013 1:43 PM, roberts...@gmail.com wrote:
>> I am trying to rewrite a website in html5. The code I have works in
>> firefox, but it doesn't work in IE9.
>
> 1. New HTML5 semantic elements are missing support by the browsers, so
> you have not provided display:block; for the header and footer
> elements which I have now included.

A pointless exercise in fixing pointless code. The issue was IE9, which
does *not* need any tricks for support to the new "semantic" elements.

> Here is my revised version:

It probably has nothing to do with the problems presented.

--
Yucca, http://www.cs.tut.fi/~jkorpela/

Thomas 'PointedEars' Lahn

unread,
May 23, 2013, 2:51:27 PM5/23/13
to
Bob wrote:

> On Wednesday, May 22, 2013 3:55:14 PM UTC-5, Thomas 'PointedEars' Lahn
> wrote:

It's attribution _line_, not attribution novel.

>> Bob wrote:
>> ^^^^^^^^^^^^^^^^^^^^^^^^
>> Please fix that.
>
> I think I have. Please let me know if I did not fix it.

It is better now, but your full name would be even more polite (and less
ambiguous, Bob #74656).

>> > I am using IE9 fully patched on a fully patched Windows 7 x64 computer.
>>
>> You should post the unforged User-Agent header field value (or
>> navigator.userAgent value) next time.
>
> How do I do this?

For example, by entering

navigator.userAgent

in the script console. STFW.

>> > IE10 won't be deployed until next year so I have to use IE9. Am I
>> > doing something wrong?
>>
>> Probably, see <news:2354532.M...@PointedEars.de>
>
> I used groups.google.com to search for that posting but nothing comes up
> except your response to my posting.

I can see now that Google broke this useful feature in the new version, too.
You should complain about it to them.

For the time being, you have to switch back (temporarily) to the old Google
Groups with the “My settings” dropdown. (You might need to set the new
Google Groups as default first even if you are already using it for the
respective command to be displayed – they messed this up, too.) Then the
URI will be made a link to the article. That link is working here.

>> > body {
>> > width: 800px;
>> ^^^^^
>> You can't be serious. Ever heard of wide-screen displays and Responsive
>> Web Design (RWD)?
>
> I use wide-screen displays everyday. I have 2 on my desk. The width is
> fixed because of pictures. […]

Try to find another way.

>> > background: -webkit-linear-gradient(top, #C13B5A 0%, #ffffff 100%);
>> > background: -webkit-gradient(linear, left top, right bottom,
>> > color-stop(0%,#C13B5A), color-stop(100%,#ffffff));
>>
>> AFAIK the order of those two declarations should be swapped.
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>> -webkit-gradient(…) is the older, AFAIK less efficient, more buggy, less
>> standards-compliant function for earlier Safari versions, now deprecated:
>>
>> <https://www.webkit.org/blog/1424/css3-gradients/>
>
> -webkit-gradient is used by old versions of chrome and safari 4 until 5.1.

Yes, I know.

> It looks like the latest version of safari is 6.04 so I will remove that
> line. I only care about browsers from the last 3 or 4 years.

Thereby unnecessarily reducing your user base; if the site is commercial,
also your customer base and potential turnover.

> IE6-IE8 will disappear next when XP dies. Vista supports IE9 but not IE10
> so that becomes least browser I care about for windows.

What kind of argument is this? Have you read and understood what I said?

>> <http://www.w3.org/TR/css3-selectors/#pseudo-classes>
>> > &bull;&nbsp;
>> > <a href="/News.asp" >News</a>
>>
>> This is asemantic, therefore not interoperable and not accessible. Use
>> list elements like “ol”, “ul”, or “dl” instead:
>>
>> <http://www.w3.org/TR/2012/CR-html5-20121217/grouping-content.html#grouping-content>
>
> Fixed but the bullets don't show up.

Because you have messed with the list's stylesheet, see below.

>> And please do not misuse the &nbsp; CRE for spacing. If you need more
>> spacing, use margins and/or paddings:
>>
>> <http://www.w3.org/TR/CSS2/box.html#box-dimensions>
>
> After addressing most of the issues you pointed out IE still does not
> display the blue background while firefox does.

The solution to that is probably in the posting I have referred to earlier.

> […]
> Here is the latest version of the code:
> […]
> html {
> height: 100%;
> position: relative;
> }

Will you *please* stop dabbling around, and RTFM for a change? Declaring a
height of 100% when the element is not absolute positioned means nothing as
the element will always be as high as the combined height of its descendants
in the same flow. Percentage values for box dimensions are always in
relation to a containing block.

<http://www.w3.org/TR/CSS21/visudet.html#propdef-height>

One wonders how you got the idea to format the root element in the first
place.

> background-color:#336;
> color:#000;

I do not think black text on dark blue background will be overly well
readable. Do you?

> a, a:link, a:visited {

One of those three simple selectors does not belong there.

> text-decoration: none;

Generally a bad idea. Should be at most used for navigations, and then
*only* those.

> color: #fff;

You forgot to declare “background-color”.

> }
>
> a:hover, a:focus { color: yellow; }

Conceptionally OK, but consider that yellow is a signal color indicating
attention/danger, and therefore is probably not the best color to choose
here.

Also, changes in context should not be indicated by color alone:

<http://www.w3.org/TR/WCAG/#visual-audio-contrast>

> ul {
> list-style-type: disc;

This is the initial value of that property; it does not need to be declared.

> display: list-item;

This is wrong. A list element like “ul” has ”display: list” by default, of
course. Declaring

display: list-item;

for it instead makes a list *item* out of this list, which does not make any
sense.

You do not have to declare anything at all there. Is this your CSS editor
screwing up? If yes, try Eclipse's; if no, RTFM before you code.

> […]
> <header>
> <ul>
> <li><a href="/">Home</a></li>
> <li><a href="/News.asp">News</a></li>
> <li><a href="/ContactUs.asp">Contact Us</a></li>
> </ul>
> </header>

Better, but that content *is* the navigation and so …

> <nav>
> </nav>

… this makes absolutely no sense. Read, think, code; in that order.


PointedEars
--
Danny Goodman's books are out of date and teach practices that are
positively harmful for cross-browser scripting.
-- Richard Cornford, cljs, <cife6q$253$1$8300...@news.demon.co.uk> (2004)

Thomas 'PointedEars' Lahn

unread,
May 23, 2013, 3:33:33 PM5/23/13
to
Thomas 'PointedEars' Lahn wrote:

> Bob wrote:
>> display: list-item;
>
> This is wrong. A list element like “ul” has ”display: list” by default,
> of course. […]

Note to self: RTFM. The “display” property has no “list” value, at least
not in CSS 2.1; the default “display” value for the “ul” element is “block”.
It is what should be kept here, by omitting the declaration.

(I had falsely assumed that there was a corresponding “list” value for the
“list-item” value as there is a corresponding “table” value for the “table-
row“, and “table-cell” values, among others.)

<http://www.w3.org/TR/CSS21/visuren.html#propdef-display>

Gus Richter

unread,
May 25, 2013, 2:11:51 AM5/25/13
to
On 5/23/2013 2:06 PM, Jukka K. Korpela wrote:
> 2013-05-23 20:52, Gus Richter wrote:
>
>> On 5/22/2013 1:43 PM, roberts...@gmail.com wrote:
>>> I am trying to rewrite a website in html5. The code I have works in
>>> firefox, but it doesn't work in IE9.
>>
>> 1. New HTML5 semantic elements are missing support by the browsers, so
>> you have not provided display:block; for the header and footer
>> elements which I have now included.
>
> A pointless exercise in fixing pointless code. The issue was IE9, which
> does *not* need any tricks for support to the new "semantic" elements.

Well, for you I shall explain. I have IE8, IE10 but no IE9. I saw the
problem in IE8 as described, corrected the problem for IE8 and included
a few gems as well. Since the OP is targeting IE9 I thought that he
might as well get some info for IE8 as a bonus. IE10 also had no problem
with my version. This may be pointless to you, but is a very large
improvement over the "help" you provided.

>> Here is my revised version:
>
> It probably has nothing to do with the problems presented.

Jeez, what a statement! Probably indeed! If you don't know, then say
nothing. Run the code and then report back!

--
Gus


Jukka K. Korpela

unread,
May 25, 2013, 3:16:55 AM5/25/13
to
2013-05-25 9:11, Gus Richter wrote:

>>> Here is my revised version:
>>
>> It probably has nothing to do with the problems presented.
>
> Jeez, what a statement! Probably indeed! If you don't know, then say
> nothing. Run the code and then report back!

Next time, consider testing whether you have understood the question
that was asked and checking whether your proposal actually solves it.
The burden of testing a proposed solution is actually on the person who
proposes it.

--
Yucca, http://www.cs.tut.fi/~jkorpela/

roberts...@gmail.com

unread,
May 26, 2013, 1:02:17 PM5/26/13
to
Thank you everyone who posted. My blue bars now show up in IE9.

Thanks again,
Bob

Gus Richter

unread,
May 26, 2013, 11:35:36 PM5/26/13
to
On 5/25/2013 3:16 AM, Jukka K. Korpela wrote:
> 2013-05-25 9:11, Gus Richter wrote:
>
>>>> Here is my revised version:
>>>
>>> It probably has nothing to do with the problems presented.
>>
>> Jeez, what a statement! Probably indeed! If you don't know, then say
>> nothing. Run the code and then report back!
>
> Next time, consider testing whether you have understood the question
> that was asked and checking whether your proposal actually solves it.

I understood the question and gave an answer. You on the other hand only
continue with your usual negative remarks intended to denigrate HTML5
which is the only babble I see and you call that understanding the
question and thereby solving it?!

> The burden of testing a proposed solution is actually on the person who
> proposes it.

Another thoughtless answer!
You state that my code "probably" is worthless without you checking that
it is so and when called on this, instead of presenting your reasoning,
you boldly state that the burden is on me to test my demo. What a laugh!

--
Gus

Gus Richter

unread,
May 26, 2013, 11:38:56 PM5/26/13
to
On 5/26/2013 1:02 PM, roberts...@gmail.com wrote:
> Thank you everyone who posted. My blue bars now show up in IE9.

Would it be too much to ask as to what and how?

--
Gus


0 new messages