TomB wrote:
Hello,
First of all, I'm just starting to use CSS so I am by no means
experienced in this matter.
What I want is a "box" div element that always is centered on the page.
Now I just use the center tag around my boxes, but I'm pretty sure there
must be a way to include the center positioning into the style code.
Anyone?
Also I had some people complaining about the colours of my site. I'm
using red (#6B0000) links on a black background, and on my monitor it
absolutely looks fine, but some people seem te have difficulties reading
the text. Opinions please? Site is located at http://deimos.curious.be/~dusk
..box { display: block; /* box with visible border, background
white */
margin-top: 1em;
margin-left: auto; margin-right: auto; /* to center it */
width: 80%;
background-color: #fff;
border-color: #000;
border-style: solid;
border-width: thin;
padding: 2%;
text-align: justify }
I would not have bothered since (as others point out), this is
really a question for comp.infosystems.
www.authoring.stylesheets.
However, you also asked a colors question.
You are specifying a dark red, not a true red (which would be
#ff0000). Dark red text against a black background is indeed
difficult to see.
Go to
<URL:http://sleepyoaks.com/HTML/hex_decimal_color_picker.htm>. Set
the Background to 000000 (black), Link to 6B0000 (your dark red),
and Active Link to ff0000 (true red). Compare the Link with the
Active Link.
In any case, if you define a color for Link, then you also need
contrasting colors for Visited Link and Active Link. When
selecting colors, don't forget that a sizable population is
color-blind. Don't put red text against a green background (or
vice versa), red-green being the most common form of
color-blindness (in which both appear gray). Also, a lack of
contrast between the text and the background might cause problems
for someone who is dyslexic.
--
David E. Ross
<URL:http://www.rossde.com/>
I use Mozilla as my Web browser because I want a browser that
complies with Web standards. See <URL:http://www.mozilla.org/>.