CSS File

K

Kelly********

Is there any one that can make me a sample CSS file for a web page.
Im trying to learn how to make CSS files for my site and it would help to
have a sample on hand.
Sample basicly would be the code for everything with short explanations for
each next to the code line. i dont knoe the coding but excample may be

a:link (explanation)
color: rgb(255,204,0);
a:visited (explanation)
color: rgb(153,204,204);
a:active (explanation)
color: rgb(102,255,0);
body (explanation)
font-family: Garamond, Times New Roman, Times;
background-color: rgb(51,102,204);
color: rgb(255,255,153);
background image (explanation)************
didnt know the code at all for this************
table
table-border-color-light: rgb(153,255,204); (explanation)
table-border-color-dark: rgb(0,0,51); (explanation)
h1, h2, h3, h4, h5, h6
font-family: Verdana, Arial, Helvetica;
h1 (explanation)
color: rgb(255,204,0);
 
T

Trevor L.

Kelly******** said:
Is there any one that can make me a sample CSS file for a web page.
Im trying to learn how to make CSS files for my site and it would
help to have a sample on hand.

I'll try

a:link { color: blue; } /* sets default colour to blue */
a:visited { color: fuchsia; } /* sets colour when visited to fuchsia */
a:hover { color: #90f; } /* sets colour on hover to #9900ff */
a:active { color: #6f0 } /* sets active colour to #66ff00 or
rgb(102,255,0)*/

body {
font-family: "garamond,times new roman,times";
colour: black; /* sets text colour to black */
background-color: #fffeec; /* sets background colour to a yellow shade
*/
background-image: url(images/display/04-08-24-1-bird-bath-2.jpg)
repeat fixed top; /* sets the background-image to the url
specified
with repeat in both directions
with position fixed at top of body
*/
font-size: 100% ; /* sets font size to 100% of the default */
margin:0; /* sets all margins to zero */
}

table {border-color: #9fc ;} /* sets the table border color to #99ffcc
or rgb(153,255,204) */
table {border-color: #003;} /* sets the table border color to #000033
or rgb(0,0,51) */

h1, h2, h3, h4, h5, h6 {font-family: Verdana, Arial, Helvetica;} /* sets all
headings (h1 to h6) to this font */

h1 {color: #fc0;} /* sets text colour for h1 to #ffcc00 or
rgb(255,204,0) */

I suggest you visit http://www.w3schools.com/default.asp to get lots more
info.
 
T

Trevor L.

Trevor said:
body {
font-family: "garamond,times new roman,times";
colour: black; /* sets text colour to black */

Anywhere in CSS (or HTML or JS) where the word "colour" appears, it should
be spelt "color".

Sorry, I am Australian. (Not that I am sorry for being Australian, but that
this caused me to make an error.)
mea culpa
:))
 
M

Murray

Awesome, Trevor.

Just a few tiny corrections (other than the ones you have already pointed
out) -
font-family: "garamond,times new roman,times";

should be - font-family: garamond,"times new roman",times, serif;
table {border-color: #9fc ;} /* sets the table border color to
#99ffcc or rgb(153,255,204) */
table {border-color: #003;} /* sets the table border color to #000033
or rgb(0,0,51) */

Not quite sure where you are going with this. The latter rul will always
trump the former one in this case.
 
T

Trevor L.

Murray said:
Awesome, Trevor.

Thanks. That is a great compliment from an expert such as yourself.
Just a few tiny corrections (other than the ones you have already
pointed out) -


should be - font-family: garamond,"times new roman",times, serif;

Thank you. I thought I may have been wrong when I posted it. I should have
checked w3schools, but maybe it wouldn't have helped.
Not quite sure where you are going with this. The latter rul will
always trump the former one in this case.

I was giving alternatives, although I admit I didn't say so.
 
M

Murray

Its good to see you speaking confidently about these things, Trevor.

Keep it up!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top