Strange cell colours

  • Thread starter Thread starter tim
  • Start date Start date
T

tim

I am developing a JSP application that has some cells with the normal
default white background and some cells with a grey background.
It works fine on my computer but other people get some of the cells
showing up as yellow.
Is there some setting in IE that would override the colors I am
specifying or highlight certain cells depending on their names or
characteristics? One of the cells has to do with email addresses.
 
Hi Tim,
Table cells (td) or do you mean Input tags/text boxes(<input....>)?
There are browser differences for named colors and it is safest to use hex
values instead of named colors. Most non MSIE browsers do not recognise
system color names.
Input boxes which have autocomplete enabled appear with a yellow background
when they have focus.
Also, yes there are Accessibility and color settings on the General tab of
Internet Options that can alter the browser's rendering of web pages. Beware
of the use of a User Stylesheet - this can overide any external stylesheet
links. Hint - the user is King... let them decide the color scheme for the
web pages they view.

Regards.
 
Rob said:
Hi Tim,
Table cells (td) or do you mean Input tags/text boxes(<input....>)?
There are browser differences for named colors and it is safest to use hex
values instead of named colors. Most non MSIE browsers do not recognise
system color names.

They should accept these colour names: these colours are defined in the
CSS spec.
 
Hi CA,

I have only one example that I tried with FF 2.1. After a review, yes you
are correct. It is rendering the system colors... I had one cell in a table
with an enclosed gif which was not rendering the transparency color. I am
using the FF utility IE Tab to switch rendering engines.

Regards.
 
Hi Tim,
Table cells (td) or do you mean Input tags/text boxes(<input....>)?
There are browser differences for named colors and it is safest to use hex
values instead of named colors. Most non MSIE browsers do not recognise
system color names.
Input boxes which have autocomplete enabled appear with a yellow background
when they have focus.
Also, yes there are Accessibility and color settings on the General tab of
Internet Options that can alter the browser's rendering of web pages. Beware
of the use of a User Stylesheet - this can overide any external stylesheet
links. Hint - the user is King... let them decide the color scheme for the
web pages they view.






- Show quoted text -


Here is a short example of the page. All users are using IE although I
can't be sure we are all using the same version. There is not auto-
complete. I do not want to let the users set the colours because I am
using a white background for fields that can be updated and a grey
background for fields that cannot. If users can override the colours,
it will render the visual clues useless. Incidentally, this is an
internal application and the users will be a captive audience.

..cmf_tr {
background-color: #E4E9FF;
}

<html:html locale="true">
<head>
<html:base/><link href="CMF.css" rel="stylesheet" type="text/css">
</head>
<table width="100%" height="100%" border="0" cellspacing="0"
cellpadding="0">
<tr class=cmf_tr>
<td align="right">email address</td>
<td><input type="text" name="cmfsales.sales_email_address"
value="(e-mail address removed)" size="37" /></td>
</tr>
</table>
</body>
</html:html>
 
Here is a short example of the page. All users are using IE although I
can't be sure we are all using the same version. There is not auto-
complete. I do not want to let the users set the colours because I am
using a white background for fields that can be updated and a grey
background for fields that cannot. If users can override the colours,
it will render the visual clues useless. Incidentally, this is an
internal application and the users will be a captive audience.

.cmf_tr {
background-color: #E4E9FF;
}

<html:html locale="true">
<head>
<html:base/><link href="CMF.css" rel="stylesheet" type="text/css">
</head>
<table width="100%" height="100%" border="0" cellspacing="0"
cellpadding="0">
<tr class=cmf_tr>
<td align="right">email address</td>
<td><input type="text" name="cmfsales.sales_email_address"
value="(e-mail address removed)" size="37" /></td>
</tr>
</table>
</body>
</html:html>

The above code is not even close to being valid. It is not even clear
whether it is supposed to be HTML or XHTML. God knows what any
particular version of any particular browser would do with it. Use the
W3C validator to help you make it valid: when code is invalid, you put
yourself at the mercy of how the browser deals with errors.
 
The above code is not even close to being valid. It is not even clear
whether it is supposed to be HTML or XHTML. God knows what any
particular version of any particular browser would do with it. Use the
W3C validator to help you make it valid: when code is invalid, you put
yourself at the mercy of how the browser deals with errors.- Hide quoted text -

- Show quoted text -

OK, how about this?

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://
www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>
</title>
</head>
<body>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td align="right">email address</td>
<td><input type="text"
name="cmfsales.sales_email_address"
value="(e-mail address removed)" size="37" /></td>
</tr>
</table>
</body>
</html>
 
OK, how about this?

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://
www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>
</title>
</head>
<body>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td align="right">email address</td>
<td><input type="text"
name="cmfsales.sales_email_address"
value="(e-mail address removed)" size="37" /></td>
</tr>
</table>
</body>
</html>

Which has no CSS, which is what you were complaining about.

I made a wild guess and inserted what you likely meant, and saw a bluish
row with a white input box.

Looking back at your original example, I notice that you applied the
class to the TR. Better to apply it to the TD, and to also specify the
background colour for the TD containing the input box, as well as for
the box itself. Don't leave anything to the vagaries of the browser.
 
Which has no CSS, which is what you were complaining about.

I made a wild guess and inserted what you likely meant, and saw a bluish
row with a white input box.

Looking back at your original example, I notice that you applied the
class to the TR. Better to apply it to the TD, and to also specify the
background colour for the TD containing the input box, as well as for
the box itself. Don't leave anything to the vagaries of the browser.- Hide quoted text -

- Show quoted text -

No, sorry, I was never complaining about the CSS.
You people seem to be missing the point. This looks fine on some
computers using IE and on others, bright yellows or greens will fill
the background of some. but not all of the fields.
It has nothing to do with CSS or how the browser mis-interprets my
poor HTML.
There is something external to the HTML or CSS, like some option
specified in IE.
 
Back
Top