CodingForums.com

CodingForums.com (http://www.codingforums.com/index.php)
-   HTML & CSS (http://www.codingforums.com/forumdisplay.php?f=13)
-   -   Please help with HTML5 and CSS3 Drop down menu (http://www.codingforums.com/showthread.php?t=275186)

AirfieldCards 10-04-2012 09:01 PM

Please help with HTML5 and CSS3 Drop down menu
 
Hello People.

I have been modifying a template I found on the web and it seemed to work perfectly for me.

http://www.greeneru.co.uk/DropDownMenu/menu2.php

However, when I actually add it to my site it breaks my site.

Here is my site normally with the original menu on it.

http://www.greeneru.co.uk/index.php

However, when I add the menu I want to use it messes up the page itself. Anyone got any ideas? Should I put the CSS into one file?

Here is my site messed up with the new menu added

http://www.greeneru.co.uk/index1.php


Here is my CSS file for the site itself and this is in the "route"
Code:

body {
margin : 0;
padding : 0;
text-align : left;
font : 75% "Trebuchet MS", verdana, arial, sans-serif;
line-height : 1.6em;
background : #6db859 url(img/bg.jpg) top center repeat-y;
color : #000;
}
                        /*CONTAINER*/
#wrapper {
position : relative;
width : 1000px; /*Origonally 1000*/
margin-right : auto;
margin-left : auto;
padding : 0;
border : 0px solid green;
background : #fff;
}
                        /*TOP TITLE BAR*/
#title {
width : 995px;
margin-left : 5px;
padding : 0;
text-align : right;
background : #fff;
color : #000;
}
#title h1 {
margin : 0;
padding : 10px;
font-size : 175%;
/*text-transform : uppercase;*/
letter-spacing : 5px;
background : inherit;
color : #47bf37;
}
                        /*BANNER*/
#header {
background : url(images/led_lights_logo.jpg) no-repeat;
width : 995px;
height : 200px;
margin : 0 0 0 20px;
padding : 0 0 0 0;
}
                        /*TOP NAVIGATION*/
.container {
width : 995px;
height : 35px;
margin : 10px 0 10px 5px;
}
#navCircle {
margin : 0;
padding : 0 0 35px 3px;
border-bottom : 3px solid #b2d094;
}
#navCircle li {
margin : 0;
padding : 0;
display : inline;
list-style-type : none;
}
#navCircle a:link, #navCircle a:visited {
float : left;
font-size : 1.3em;
padding : 0 20px 5px 5px;
text-decoration : bold;
background : inherit;
color : #457C05;
}
#navCircle a:link.active, #navCircle a:visited.active, #navCircle a:hover {
background-color : inherit;
color : #000;
background : url(img/arrow1.gif) no-repeat bottom center;
}
                        /*MAIN CONTENT*/
#content {
width : 700px;
float : left;
margin-top : 0;
margin-left : 11px;
padding : 5px;
border-right : 3px solid #b2d094;
color : #193c19
}
#content p {
padding : 0 20px;
}
                        /*SIDEBAR*/
#right-col {
width : 175px;
margin : 5px 0 0 750px;
border-left : 1px none #28460a;
padding : 3px;
}
                        /*FOOTER*/
#footer {
margin : 100px 0 0 0;
padding : 20px;
font : 90% "Trebuchet MS", verdana, arial, sans-serif;
background : #164d07;
/*background : #164e07;*/
color : #fff;
width : 961px;
align : center;
}
#footer a:link, #footer a:visited {
background : inherit;
color : #b2d094;
}
#footer a:hover {
background : inherit;
color : #fff;
text-decoration : none;
}
                        /*SCROLLBAR*/
div.scroll {
overflow : auto;
height : 14em;
width : 190px;
padding : 1ex;
margin : 0 0 30px 5px;
border : 2px solid #345411;
background : #BCE0A8;
color : #000;
}
                        /*TYPOGRAPHY*/
h2 {
margin : 20px;
font-size : 140%;
text-transform : uppercase;
letter-spacing : 5px;
background : inherit;
color : green;
}
h3 {
margin : 5px;
font-size : 120%;
letter-spacing : 3px;
background : inherit;
color : green;
}
blockquote {
font-weight : bold;
font-style : italic;
font-size : 110%;
color : #193c19;/*was b29b35 now changed to a dark green */
}
                        /*LINKS*/
a img {
border : none;
}
a:link, a:visited {
text-decoration : none;
background : inherit;
color : #457C05;
}
a:hover {
text-decoration : underline;
background : inherit;
color : #666;
}
ul.side {
list-style-type : square;
padding : 0;
margin : 0;
background : inherit;
color : #457C05;
}
.side li {
padding-left : 0.2em;
margin-left : 2em;
}
                        /*CLASSES*/
.news {
font-size : 90%;
background : inherit;
color : #000;
}
.imgleft {
float : left;
border : 0px solid #345411;
padding : 5px;
margin-right : 15px;
}
.imgright {
float : right;
border : 0px solid #345411;
padding : 5px;
margin-left : 15px;
}

Here is the CSS for the menu itself.

Code:

@charset "utf-8";
/* CSS Document */

@font-face {
        font-family: 'Ubuntu Condensed';
        src: url('../_fonts/UbuntuCondensed-Regular.ttf');
        font-weight: 400;
}

/***Global styles***/

/*limited reset*/
html, body, div, section, article, aside, header, hgroup, footer, nav, h1, h2, h3, h4, h5, h6, p, blockquote, address, time, span, em, strong, img, ol, ul, li, figure, canvas, video, th, td, tr {
        margin: 0;
        padding: 0;
        border: 0;
        vertical-align:baseline;
        font: inherit;
}

/*html5 display rule*/
address, article, aside, canvas, details, figcaption, figure, footer, header, hgroup, nav, menu, nav, section, summary {
        display: block;
}

* { margin: 0;
        padding: 0; }

body{
        font-family:Verdana, Geneva, sans-serif;
        background:#f5f5f5 repeat;
    font-size: 12px;
    line-height: 1.5;
        color:#444444;
        margin: 0;
        padding: 0;
        border: 0;
        outline: 0;
}

#container{
        padding:0px;}


/* Main Menu */

#menu {
        clear:both;
        width: 980px;
        height:37px;
        border:1px solid #E0E0E0;
        margin:1px auto 0 1px;
        box-shadow: 0px 3px 8px #cecece;
        border-radius:5px;
        margin:2px auto;       
}

.menu{
        padding-top:2px;}

.menu li {
        float:left;
        display:block;
        text-align:center;
        position:relative;
        padding: 2px 10px;
        border:none;
        margin-left:3px;
}

.menu li:hover {
        display:block;
        padding: 2px 8px 6px;
        background:#F4F4F4;
        background: -moz-linear-gradient(top, #F4F4F4, #EEEEEE);
        background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#F4F4F4), to(#EEEEEE));
        -moz-border-radius: 10px 10px 0px 0px;
        -webkit-border-radius: 10px 10px 0px 0px;
        border-radius: 10px 10px 0px 0px; /* top left - top right - bottom right - bottom left */
        border:3px solid #b0d290;/* this is the border colour round the top menu item when hovered over */
}

.menu li a {
        font-family: 'Ubuntu Condensed', sans-serif;
        font-size:18px;
        outline:0;
        text-decoration:none;
        color:#5a8100;
}

.menu li:hover a {
        color:#00b846;
        text-shadow: 0px 1px 0px #ccc;
       
}

.menu li a.active {
    background:#0990ff;
    color: #fff;
    padding:8px 15px 7px 15px;
        text-decoration:none;
}

.menu li .drop {
        background:none;
}

.menu li:hover .drop {
        background:none;
}

.dropdown-1column,
.dropdown-2columns,
.dropdown-3columns,
.dropdown-4columns,
.dropdown-5columns {
        margin:3px auto;
        float:left;
        position:absolute;
        left:-999em;
        text-align:left;
        padding:10px 5px 10px 5px;
        border:3px solid #b1d192;
        -moz-border-radius: 0px 0px 10px 10px;
        -webkit-border-radius: 0px 0px 10px 10px;
        border-radius: 0px 0px 10px 10px;
        border-top:none;
        background:#f4f4f4;
        background: -moz-linear-gradient(top, #f4f4f4, #d8d8d8);
        background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#f4f4f4), to(#d8d8d8));
}

.dropdown-1column {width: 145px;}
.dropdown-2columns {width: 380px;}
.dropdown-3columns {width: 420px;}
.dropdown-4columns {width: 560px;}
.dropdown-5columns {width: 700px;}

.menu li:hover .dropdown-1column,
.menu li:hover .dropdown-2columns,
.menu li:hover .dropdown-3columns,
.menu li:hover .dropdown-4columns,
.menu li:hover .dropdown-5columns {
        left:-2px;
        top:30px;
}

.col-1,
.col-2,
.col-3,
.col-4,
.col-5 {
        display:inline;
        float: left;
        position: relative;
        margin-left: 5px;
        margin-right: 5px;
}
.col-1 {width:130px;}
.col-2 {width:270px;}
.col-3 {width:410px;}
.col-4 {width:550px;}
.col-5 {width:690px;}
.col-demo{width:145px;}

.col-5 img{
        float:left;
        margin-right:20px;}
       
.col-5 p{
        font-size:20px !important;
        padding-top:30px;
        color: #F30;
        text-shadow:1px 1px 2px #fff !important;
        font-family: 'Ubuntu Condensed', sans-serif;}       


.menu p, .menu h2, .menu h3, .menu ul li {
        line-height:21px;
        font-size:12px;
        text-align:left;
        text-shadow: 1px 1px 1px #FFFFFF;
}
.menu h2 {
        font-size:21px;
        font-weight:400;
        letter-spacing:-1px;
        margin:7px 0 14px 0;
        padding-bottom:14px;
        border-bottom:1px solid #666666;
        box-shadow: 0 2px 0 #CCCCCC;
}

.menu h3 {
        font-size:14px;
        margin:7px 0 14px 0;
        padding-bottom:7px;
        border-bottom:1px solid #888888;
        box-shadow: 0 2px 0 #CCCCCC;
}

.menu p {
        line-height:18px;
        margin:0 0 22px 0;
}

.menu li:hover div a {
        padding-left:3px;
        font-size:15px;
        color:#5a8100;
        text-shadow:none;
}

.menu li:hover div a:hover {
        color:#b0d290;
        text-shadow:none;
}


.strong {
        font-weight:bold;
}

.italic {
        font-style:italic;
}

.menu li .blackbox {
        background-color:#333333;
        color: #eeeeee;
        text-shadow: 1px 1px 1px #000;
        padding:4px 6px 4px 6px;
        -moz-border-radius: 5px;
    -webkit-border-radius: 5px;
    border-radius: 5px;
        -webkit-box-shadow:inset 0 0 3px #000000;
        -moz-box-shadow:inset 0 0 3px #000000;
        box-shadow:inset 0 0 3px #000000;
}

.menu li .blue {
        background-color: #444;
    box-shadow: 0px 4px 12px #000 inset;
    padding: 7px 10px;
    text-shadow: 1px 1px 1px #000000;
}

.menu .blue li a{
        color: #FFFFFF !important;
        text-shadow:0 1px 0 #000 !important;}

.menu li ul {
        list-style:none;
        padding:0;
        margin:0 0 12px 0;
}

.menu li ul li {
        font-size:12px;
        line-height:24px;
        position:relative;
        text-shadow: 1px 1px 1px #ffffff;
        padding:0;
        margin:0;
        float:none;
        text-align:left;
}

.menu li ul li:hover {
        background:none;
        border:none;
        padding:0;
        margin:0;
}

.menu li .grisbox li {
        background:#F4F4F4;
        border:1px solid #bbbbbb;
        margin:0px 0px 4px 0px;
        padding:4px 6px 4px 6px;
        width:116px;
        -moz-border-radius:5px 5px 2px 2px;
    -webkit-border-radius:5px 5px 2px 2px;
    -khtml-border-radius: 5px 5px 2px 2px;
    border-radius: 5px 5px 2px 2px;
        -webkit-box-shadow:inset 0 0 3px #ccc;
        -moz-box-shadow:inset 0 0 3px #ccc;
        box-shadow:inset 0 0 3px #ccc;
}

.menu li .grisbox li:hover {
        background:#ffffff;
        border:1px solid #aaaaaa;
        padding:4px 6px 4px 6px;
        margin:0px 0px 4px 0px;
}

.imgclass{
        float:left;
        margin-top:3px;
        margin-right:10px;
        background:#FFFFFF;
        padding:4px;
        border:1px solid #777777;
        -moz-box-shadow:0px 0px 5px #666666;
        -webkit-box-shadow:0px 0px 5px #666666;
        box-shadow:0px 0px 5px #666666;}
       
.text{
        width:230px;
        display:block;}
       
.textblock{
        width:410px;
        clear:both;}

Any help would really be appreciated, I really like this menu and I would dearly love to add to it as I add pages to my ever growing site.


All times are GMT +1. The time now is 06:45 PM.

Powered by vBulletin®
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.