Woody
06-08-2006, 09:55 AM
Hi,
I'm very new to CSS,I am trying to put one of the horizontal nav bars from the dynamic drive CSS library onto my site, but really don't know what I am doing!:eek:
The test site is at:
http://www.woodenteacher.org.uk
I have worked in tables (don't know much about html/css though) and am trying desperatly to get into CSS.
I have put the navbar (CFnavbar)html code in, but don't know how to link it to table cell or style sheet. At the moment it is showing at the top of the page! Have added the CSS code to the style sheet, but don't know how to link it to the html. Have the button gifs in my image folder but don't know how to link them! It was so much easier with the old fashioned roll overs!!!
Lots of questions, but ANY help or ANY answers to lead me in the right direction would be great!!(CSS stylesheet contents below)
Stylesheet:
.toptile {
background-image: url(images/images/stmweb_bgndtop.jpg);
background-repeat: repeat-x;
position: relative;
background-position: right;
}
Source: Dynamic Drive CSS Library
URL: http://www.dynamicdrive.com/style/
<style type="text/css">
#cfnavbar{
margin: 0;
padding: 0;
}
#cfnavbar ul{
background: url(media/bgpink.gif) bottom center repeat-x;
padding-left: 0;
margin: 0;
float: left;
font: bold 80% Verdana;
}
* html #cfnavbar ul{ /*IE only rule. Add extra margin-bottom*/
margin-bottom: 1em;
}
#cfnavbar ul li{
display: inline;
}
#cfnavbar ul li a, #cfnavbar ul li span{
float: left;
color: black;
font-weight: bold;
padding: 7px 13px 8px 6px;
text-decoration: none;
background: url(media/dividerpink.gif) bottom right no-repeat;
}
#cfnavbar ul li span{ /*Targets span tag to the right of #leftcorner below*/
padding-left: 0px;
}
#cfnavbar ul li a#leftcorner{
float: none;
padding-left: 10px;
padding-right: 0px;
background: url(media/leftcornerpink.gif) bottom left no-repeat;
}
#cfnavbar ul li a#rightcorner{
padding-right: 10px;
background: url(media/rightcornerpink.gif) bottom right no-repeat;
}
#cfnavbar ul li a:hover{
text-decoration: underline;
}
.maintxt {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 14px;
text-align: justify;
word-spacing: normal;
padding: 0px 0px 0px 35px;
left: 50px;
text-indent: 0pt;
width: 80%;
}
h4 {
font-family: Verdana, Arial, Helvetica, sans-serif;
color: #6699CC;
padding-left: 35px;
font-size: large;
}
.rightbgnd {
background-image: url(images/stm_bluebgnd.jpg);
background-repeat: repeat-y;
height: 100%;
}
.footer {
background-color: #333366;
background-repeat: repeat-x;
width: 100%;
}
</style>
I'm very new to CSS,I am trying to put one of the horizontal nav bars from the dynamic drive CSS library onto my site, but really don't know what I am doing!:eek:
The test site is at:
http://www.woodenteacher.org.uk
I have worked in tables (don't know much about html/css though) and am trying desperatly to get into CSS.
I have put the navbar (CFnavbar)html code in, but don't know how to link it to table cell or style sheet. At the moment it is showing at the top of the page! Have added the CSS code to the style sheet, but don't know how to link it to the html. Have the button gifs in my image folder but don't know how to link them! It was so much easier with the old fashioned roll overs!!!
Lots of questions, but ANY help or ANY answers to lead me in the right direction would be great!!(CSS stylesheet contents below)
Stylesheet:
.toptile {
background-image: url(images/images/stmweb_bgndtop.jpg);
background-repeat: repeat-x;
position: relative;
background-position: right;
}
Source: Dynamic Drive CSS Library
URL: http://www.dynamicdrive.com/style/
<style type="text/css">
#cfnavbar{
margin: 0;
padding: 0;
}
#cfnavbar ul{
background: url(media/bgpink.gif) bottom center repeat-x;
padding-left: 0;
margin: 0;
float: left;
font: bold 80% Verdana;
}
* html #cfnavbar ul{ /*IE only rule. Add extra margin-bottom*/
margin-bottom: 1em;
}
#cfnavbar ul li{
display: inline;
}
#cfnavbar ul li a, #cfnavbar ul li span{
float: left;
color: black;
font-weight: bold;
padding: 7px 13px 8px 6px;
text-decoration: none;
background: url(media/dividerpink.gif) bottom right no-repeat;
}
#cfnavbar ul li span{ /*Targets span tag to the right of #leftcorner below*/
padding-left: 0px;
}
#cfnavbar ul li a#leftcorner{
float: none;
padding-left: 10px;
padding-right: 0px;
background: url(media/leftcornerpink.gif) bottom left no-repeat;
}
#cfnavbar ul li a#rightcorner{
padding-right: 10px;
background: url(media/rightcornerpink.gif) bottom right no-repeat;
}
#cfnavbar ul li a:hover{
text-decoration: underline;
}
.maintxt {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 14px;
text-align: justify;
word-spacing: normal;
padding: 0px 0px 0px 35px;
left: 50px;
text-indent: 0pt;
width: 80%;
}
h4 {
font-family: Verdana, Arial, Helvetica, sans-serif;
color: #6699CC;
padding-left: 35px;
font-size: large;
}
.rightbgnd {
background-image: url(images/stm_bluebgnd.jpg);
background-repeat: repeat-y;
height: 100%;
}
.footer {
background-color: #333366;
background-repeat: repeat-x;
width: 100%;
}
</style>