CSS Drop Down list not working in chrome - css

i use this css code in IE7 and it works great without any problems.
Now in IE11 and chrome the drop down doesn't work i see the main menu and all sub menus together.
need an assistance in that to understand what can be done to fix it.
Thanks.
<div id='cssmenu'>
<ul>
<li class='active'><a href='url'><span>text</span></a></li>
<li class='has-sub'><a href='#'><span>text</span></a></li>
<ul>
<li><a href='url'><span>text</span></a></li>
<li><a href='url'><span>text</span></a></li>
</ul>
body {
background: #4096EE url(images2/img1.jpg) repeat-x;
text-align: justify;
font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
font-size: small;
color: #333333;
}
h1 {
}
h2, h3 {
margin-top: 0px;
}
h4, h5, h6 {
}
p, ol, ul, dl, blockquote {
}
a {
color: #1B4978;
}
a:hover {
text-decoration: none;
}
/* Header */
#header {
width: 600px;
height: 60px;
margin: 0px auto;
}
#header h1 {
float: left;
margin: 0px;
padding-top: 20px;
font-size: 42px;
letter-spacing: -2px;
}
#header h2 {
float: right;
margin: 10px 0px 0px 0px;
padding-top: 28px;
font-size: 16px;
letter-spacing: -1px;
color: #FFFFFF;
}
#header a {
text-decoration: none;
color: #FFFFFF;
}
/* Menu */
#menu {
width: 600px;
height: 30px;
margin: 0px auto;
}
#menu ul {
margin: 0px;
padding: 0px;
list-style: none;
}
#menu li {
display: inline;
}
#menu a {
display: block;
float: left;
width: 120px;
padding: 5px 0px;
text-align: center;
text-decoration: none;
font-weight: bold;
background: #EEEEEE;
}
#menu a:hover {
background: #CCCCCC;
}
/* Content */
#content {
background: #FFFFFF;
width: 600px;
margin: 0px auto;
padding: 2px 0px 0px 0px;
}
#colOne {
float: right;
width: 360px;
margin-top: 20px;
padding-right: 20px;
}
#colTwo {
float: left;
width: 180px;
margin-top: 20px;
padding-right: 20px;
padding-left: 20px;
}
#colTwo ul {
margin-left: 0px;
padding-left: 0px;
list-style-position: inside;
}
#content h1 {
background-color: #B2D4F7;
padding: 5px 0px 5px 5px;
color: #173E68;
}
#content h2 {
background-color: #B2D4F7;
padding: 5px 0px 5px 5px;
text-transform: uppercase;
font-size: 16px;
color: #173E68;
}
#content h3 {
color: #2F73B8;
}
/* Footer */
#footer {
width: 600px;
margin: 0px auto;
padding: 3px 0px 0px 0px;
height: 50px;
background: #EEEEEE;
}
#footer p {
margin: 0px;
padding-top: 15px;
text-align: center;
font-size: 11px;
color: #999999;
}
#footer a {
color: #666666;
}
#footer a:hover {
color: #333333;
}
#cssmenu{
border:none;
border:0px;
margin:0px auto;
padding:0px;
font: 67.5% 'Lucida Sans Unicode', 'Bitstream Vera Sans', 'Trebuchet Unicode MS', 'Lucida Grande', Verdana, Helvetica, sans-serif;
width:600px;
font-size:14px;
font-weight:bold;
}
#cssmenu ul{
background:#333333;
height:35px;
list-style:none;
margin:0;
padding:0;
}
#cssmenu li{
float:left;
padding:0px;
}
#cssmenu li a{
background:#333333 url('seperator.gif') bottom right no-repeat;
color:#cccccc;
display:block;
font-weight:normal;
line-height:35px;
margin:0px;
padding:0px 25px;
text-align:center;
text-decoration:none;
}
#cssmenu li a:hover, #cssmenu ul li:hover a{
background: #2580a2 url('hover.gif') bottom center no-repeat;
color:#FFFFFF;
text-decoration:none;
}
#cssmenu li ul{
background:#333333;
display:none;
height:auto;
padding:0px;
margin:0px;
border:0px;
position:absolute;
width:225px;
z-index:200;
/*top:1em;
/*left:0;*/
}
#cssmenu li:hover ul{
display:block;
}
#cssmenu li li {
background:url('sub_sep.gif') bottom left no-repeat;
display:block;
float:none;
margin:0px;
padding:0px;
width:225px;
}
#cssmenu li:hover li a{
background:none;
}
#cssmenu li ul a{
display:block;
height:35px;
font-size:12px;
font-style:normal;
margin:0px;
padding:0px 10px 0px 15px;
text-align:left;
}
#cssmenu li ul a:hover, #cssmenu li ul li:hover a{
background:#2580a2 url('hover_sub.gif') center left no-repeat;
border:0px;
color:#ffffff;
text-decoration:none;
}
#cssmenu p{
clear:left;
}

I'm surprised that HTML works as expected anywhere, but then IE7 is a large pile of bugs.
You have a <ul> as a child of another <ul>, which isn't valid HTML. <ul> can only contain <li> elements. That sub-menu list should be the child of the <li> above it:
<li class='has-sub'><a href='#'><span>text</span></a>
<ul>
<li><a href='url'><span>text</span></a></li>
<li><a href='url'><span>text</span></a></li>
</ul>
</li>
body {
background: #4096EE url(images2/img1.jpg) repeat-x;
text-align: justify;
font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
font-size: small;
color: #333333;
}
h1 {
}
h2, h3 {
margin-top: 0px;
}
h4, h5, h6 {
}
p, ol, ul, dl, blockquote {
}
a {
color: #1B4978;
}
a:hover {
text-decoration: none;
}
/* Header */
#header {
width: 600px;
height: 60px;
margin: 0px auto;
}
#header h1 {
float: left;
margin: 0px;
padding-top: 20px;
font-size: 42px;
letter-spacing: -2px;
}
#header h2 {
float: right;
margin: 10px 0px 0px 0px;
padding-top: 28px;
font-size: 16px;
letter-spacing: -1px;
color: #FFFFFF;
}
#header a {
text-decoration: none;
color: #FFFFFF;
}
/* Menu */
#menu {
width: 600px;
height: 30px;
margin: 0px auto;
}
#menu ul {
margin: 0px;
padding: 0px;
list-style: none;
}
#menu li {
display: inline;
}
#menu a {
display: block;
float: left;
width: 120px;
padding: 5px 0px;
text-align: center;
text-decoration: none;
font-weight: bold;
background: #EEEEEE;
}
#menu a:hover {
background: #CCCCCC;
}
/* Content */
#content {
background: #FFFFFF;
width: 600px;
margin: 0px auto;
padding: 2px 0px 0px 0px;
}
#colOne {
float: right;
width: 360px;
margin-top: 20px;
padding-right: 20px;
}
#colTwo {
float: left;
width: 180px;
margin-top: 20px;
padding-right: 20px;
padding-left: 20px;
}
#colTwo ul {
margin-left: 0px;
padding-left: 0px;
list-style-position: inside;
}
#content h1 {
background-color: #B2D4F7;
padding: 5px 0px 5px 5px;
color: #173E68;
}
#content h2 {
background-color: #B2D4F7;
padding: 5px 0px 5px 5px;
text-transform: uppercase;
font-size: 16px;
color: #173E68;
}
#content h3 {
color: #2F73B8;
}
/* Footer */
#footer {
width: 600px;
margin: 0px auto;
padding: 3px 0px 0px 0px;
height: 50px;
background: #EEEEEE;
}
#footer p {
margin: 0px;
padding-top: 15px;
text-align: center;
font-size: 11px;
color: #999999;
}
#footer a {
color: #666666;
}
#footer a:hover {
color: #333333;
}
#cssmenu{
border:none;
border:0px;
margin:0px auto;
padding:0px;
font: 67.5% 'Lucida Sans Unicode', 'Bitstream Vera Sans', 'Trebuchet Unicode MS', 'Lucida Grande', Verdana, Helvetica, sans-serif;
width:600px;
font-size:14px;
font-weight:bold;
}
#cssmenu ul{
background:#333333;
height:35px;
list-style:none;
margin:0;
padding:0;
}
#cssmenu li{
float:left;
padding:0px;
}
#cssmenu li a{
background:#333333 url('seperator.gif') bottom right no-repeat;
color:#cccccc;
display:block;
font-weight:normal;
line-height:35px;
margin:0px;
padding:0px 25px;
text-align:center;
text-decoration:none;
}
#cssmenu li a:hover, #cssmenu ul li:hover a{
background: #2580a2 url('hover.gif') bottom center no-repeat;
color:#FFFFFF;
text-decoration:none;
}
#cssmenu li ul{
background:#333333;
display:none;
height:auto;
padding:0px;
margin:0px;
border:0px;
position:absolute;
width:225px;
z-index:200;
/*top:1em;
/*left:0;*/
}
#cssmenu li:hover ul{
display:block;
}
#cssmenu li li {
background:url('sub_sep.gif') bottom left no-repeat;
display:block;
float:none;
margin:0px;
padding:0px;
width:225px;
}
#cssmenu li:hover li a{
background:none;
}
#cssmenu li ul a{
display:block;
height:35px;
font-size:12px;
font-style:normal;
margin:0px;
padding:0px 10px 0px 15px;
text-align:left;
}
#cssmenu li ul a:hover, #cssmenu li ul li:hover a{
background:#2580a2 url('hover_sub.gif') center left no-repeat;
border:0px;
color:#ffffff;
text-decoration:none;
}
#cssmenu p{
clear:left;
}
<div id='cssmenu'>
<ul>
<li class='active'><a href='url'><span>text</span></a></li>
<li class='has-sub'><a href='#'><span>text</span></a>
<ul>
<li><a href='url'><span>text</span></a></li>
<li><a href='url'><span>text</span></a></li>
</ul>
</li>
</ul>
</div>

Related

CSS href text link jumps to a new line when clicked

My navigation bar works perfectly fine, any image links work fine, but all text links on my page jump down when I click on them. Most of them jump so far you cannot actually click it.
I also noticed my a:visited links are inheriting the color #000 from somewhere, when they should be #616161. There is no issue when browsing on my Android device, but happens in IE11 and Chrome32.
The HTML is nothing special. Just
Page Name
type links. It has to be something with the CSS.
The CSS:
body {
background-color: #7296d9;
max-width:1000px;
}
#wrapper {
width:auto;
background:url(../images/bg.jpg);
background-repeat:repeat;
margin:4px;
}
#content {
width:98%;
text-align:center;
margin:auto;
}
#paragraph {
width:80%;
font-size:18px;
color: #666;
font-weight:100;
text-align:justify;
margin:10px auto 25px auto;
}
.reviews {
width:80%;
margin:auto;
text-align:justify;
color: #666;
}
p {
margin:10px 0 10px 0;
}
h1 {
line-height:48px;
font-size:36px;
font-weight:bold;
text-align:center;
margin-top:10px;
}
h2 {
line-height:42px;
font-size:24px;
font-weight:bold;
text-align:center;
}
a:link, a:visited {
color: #616161;
text-decoration: underline;
}
a:hover, a:active {
color: #ffffff;
text-decoration: underline;
}
#header {
height:86px;
max-height:86px;
width:98%;
min-width:500px;
position:relative;
background-image:url(../images/logo.png);
background-repeat:no-repeat;
}
#header .left {
float:left;
height:auto;
}
#header .media-header {
float:right;
margin-top:50px;
margin-right:-20px;
}
#menu ul li:hover > ul {
display: block;
}
#menu {
display:table;
width:100%;
background: -webkit-linear-gradient( #d5d5d5, #595959); /* For Safari */
background: -o-linear-gradient( #d5d5d5, #595959); /* For Opera 11.1 to 12.0 */
background: -moz-linear-gradient( #d5d5d5, #595959); /* For Firefox 3.6 to 15 */
background: linear-gradient( #d5d5d5, #595959); /* Standard syntax */
-webkit-border-radius: 25px;
-o-border-radius: 25px;
-moz-border-radius: 25px;
border-radius: 25px;
}
#menu ul ul {
display: none;
}
#menu ul {
height:auto;
font-size: 16px;
font-family: "Times New Roman", Times, serif;
font-weight: bold;
text-align: center;
text-shadow: 2px 2px 2px #cccccc;
text-decoration:none;
list-style: none;
position: relative;
display: table-row;
}
#menu a:link, a:visited {
display:block;
text-decoration: none;
color: #000000;
padding: 8px auto 8px auto;
}
#menu a:hover, a:active {
display:block;
padding:5px;
text-decoration:none;
color: #fff;
}
#menu ul:after {
content: "";
clear:both;
display: block;
}
#menu ul li {
display:table-cell;
width:auto;
}
#menu ul a:link, a:visited {
display: block;
padding: 5px;
color: #000;
text-decoration: none;
}
#menu ul a:hover, a:active {
display:block;
padding:5px;
text-decoration:none;
color: #fff;
}
#menu ul ul {
background: #999;
border-radius: 0px;
padding: 0;
position: absolute;
}
#menu ul ul li {
width:auto;
border-top: 1px solid #ccc;
position: relative;
display:block;
}
#menu ul ul li a {
padding: 5px;
text-align:left;
color: #000;
}
#menu ul ul li a:hover {
color: #FFF;
}
#menu ul ul:last-child, nav ul ul:last-child a {
-webkit-border-bottom-right-radius: 10px;
-o-border-bottom-right-radius: 10px;
-moz-border-radius-bottomright: 10px;
border-bottom-right-radius: 10px;
-webkit-border-bottom-left-radius: 10px;
-o-border-bottom-left-radius: 10px;
-moz-border-radius-bottomleft: 10px;
border-bottom-left-radius: 10px;
}
.center {
text-align:center;
}
#reviews {
width:80%;
text-align:justify;
overflow:hidden;
margin:25px auto 25px auto;
}
#reviews img {
position:relative;
float:left;
}
#form {
color: #666;
margin:0px auto 0px auto;
width:350px;
}
#form p {
color: #666;
margin:0px auto 0px auto;
width:350px;
}
.bottombar {
margin:auto;
width:100%;
}
#footer {
display:block;
font-size:12px;
color: #616161;
text-align:center;
width:auto;
margin:5px auto 5px auto;
}
#footer img {
text-align:center;
color: #616161;
width:100%;
margin:5px auto 5px auto;
}
#media-footer {
text-align:center;
margin:10px 0 15px 55px;
}
#media-footer img {
text-align:center;
margin:10px 0 15px 55px;
}
nav ul {
display:none;
}
#minimenu {
display:none;
}
It's because you are adding padding to the element when it is :active:
#menu ul a:hover, a:active {
display: block;
padding: 5px;
text-decoration: none;
color: #fff;
}
It's worth noting that you are repeating the same styling in different instances.
#menu a:hover, a:active {
display: block;
padding: 5px;
text-decoration: none;
color: #fff;
}
Just remove the padding from both declarations and it will work as expected.

First Image in Wordpress Post Will Not Center

In some of my posts (not all of them), the first image keeps floating right event though I have put in <center></center> tags. Can someone help me figure out why this is happening. Example here: http://renegadechicks.com/twelve-inspiring-centerpieces-3
Below is my CSS:
/*
Theme Name: StyleWeekly
Theme URI: http://cloverthemes.com/
Author: http://cloverthemes.com/
Author URI: http://cloverthemes.com/
Description: Style Weekly
Version: 1.2
Tags: magazine, beauty, style, fashion
*/
/* =Reset default browser CSS. Based on work by Eric Meyer: http://meyerweb.com/eric/tools/css/reset/index.html
-------------------------------webs------------------------------- */
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pbackgre,
a, abbr, acronym, address, big, cite, code,
del, dfn, font, ins, kbd, q, s, samp,
small, strike, sub, sup, tt, var,
dl, dt, dd, ol, ul, li,article, aside, details, figcaption, figure, footer, header, hgroup, menu, nav, section,fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td, br {
border: 0;
font-family: inherit;
font-size: 100%;
font-style: inherit;
font-weight: inherit;
margin: 0;
outline: 0;
padding: 0;
vertical-align: baseline;
}
:focus { /* remember to define focus styles! */
outline: 0;
}
body {
line-height: 1;
}
ol, ul {
list-style: none;
}
table { /* tables still need 'cellspacing="0"' in the markup */
border-collapse: separate;
border-spacing: 0;
}
caption, th, td {
font-weight: normal;
text-align: left;
}
blockquote:before, blockquote:after,
q:before, q:after {
content: "";
}
blockquote, q {
quotes: "" "";
}
a img {
border:5px solid #FBDDDF;
}
img.centered, .aligncenter, div.aligncenter {
display: block;
margin-left: auto;
margin-right: auto;
}
img.alignright {
padding: 4px;
margin: 0 0 2px 7px;
display: inline;
}
img.alignleft {
padding: 4px;im
margin: 0 7px 2px 0;
display: inline;
}
.alignright {
float: right;
}
.alignleft {
float: left;
}
.box img { display: block; margin: auto; }
img {
display: block;
width: auto;
margin: auto;
}
small {font-size:11px;}
/* Floating
---------------------------------------------------------------- */
.alignleft {
float: left;
margin: 0 10px 10px 0;
}
.alignright {
float: right;
margin: 0 0 0 10px;
}
.aligncenter {
display: block;
margin: 0 auto 10px;
}
.left{float:left;}
.right{float:right;}
/* Clear Floats
---------------------------------------------------------------- */
.clearfix:after { visibility: hidden; display: block; font-size: 0; content: " "; clear: both; height: 0; }
* html .clearfix { zoom: 1; } /* IE6 */
*:first-child+html .clearfix { zoom: 1; } /* IE7 */
/* Global
-------------------------------------------------------------- */
body {
color: #444;
font-family: "Segoe UI","Helvetica","Arial",sans-serif;
font-size: 16px;
line-height: 1.5em;
background: #000 url("images/graphicBg.jpg") no-repeat top center;
}
#inner {
background-color: #fff;
border: 3px solid #F10C6A;
padding: 20px}
#logos {
display:none;
}
#linkwithin_logo_0 {
display: none;
padding-below: 5px;
}
#post-131 .st_facebook_large, #post-131 .st_twitter_large, #post-131 .st_pinterest_large, #post-131 .st_linkedin_large, #post-131 .st_email_large, #post-131 .st_sharethis_large, #post-131 .st_fblike_large {display: none;}
.stMainServices st-facebook-counter {
padding-bottom:15px;
}
.c-1 {
float: left; padding-top: 20px;width:650px}
.c-1 .bd {
background: none}
h1,h2,h3,h4,h5,h6 {color:#cc0066; font-weight: normal;font-family:Georgia,"Times New Roman",Times,serif; padding-bottom: 10px;
}
h1 {
font-size: 40px;
}
h2 {
font-size: 30px;
}
h3 {
font-size: 30px; padding-top: 5px;
}
h4 {
font-size: 30px;
}
h5,h6 {
font-size: 30px;
}
pre,code,kbd,samp,tt {mos
font: 16px/1.385 "Courier New", Monospace, serif;
}
/* Hyperlinks
------------------------------------------------------------ */
a,
a:visited {
}
a:hover {
text-decoration: underline;
}
a img {
border: 5px solid #FBDDDF;
}
.imagelogo {
border:none;
}
h1 a,h2 a,h3 a,h4 a, h5 a, h6 a {
text-decoration: none; color: #
}
h1 a:hover,h2 a:hover,h3 a:hover,h4 a:hover,h5 a:hover,h6 a:hover {
text-decoration: underline; color: #0AC6F5;
}
/* Input Form & TextArea
---------------------------------------------------------------- */
input, textarea {
border-color: #ccc #efefef #efefef #ccc;
border-width: 1px;
border-style: solid;
color: #777;
padding: 6px;
}
input:focus {
background: #ffffff;
}
/* Color
-------------------------------------------------------------- */
a,
a:visited, #logo .site-title a {
color: #cc0066;border:none !important;
}
#nav, #nav li li a, #nav li li a:link, #nav li li a:visited{ text-transform:uppercase; }
.home-columns h3, .home-columns h4, a:hover {color: #0AC6F5;}
.home-columns a {text-decoration:none;}
#nav li a {color:#000000;}
#nav li a:hover {
color:#0AC6F5;
}
#nav li li a:hover, #nav li li a:active{background:rgba(0, 0, 0, 0.50);text-transform: uppercase;}
#nav li li a, #nav li li a:link, #nav li li a:visited {
}
#nav { }
#nav ul li{ }
#nav ul li a {
color: #fff}
#nav ul li ul li,#nav ul li ul li a {
border: none;
}
/* Padding
---------------------------------------------------------------- */
.pl20{padding-left:20px;}
.pl10{padding-left:10px;}
.pb10{padding-bottom:10px;}
.pb20{padding-bottom:20px;}
.pr20{padding-right:20px;}
.bd{background: url("images/dot.png") repeat-x scroll left bottom transparent;}
/* Header
---------------------------------------------------------------- */
#header {
}
#header .wrap {
/*background: url("images/topbanner.png") no-repeat scroll 350px 43px transparent;*/
margin: 0 auto;
overflow: hidden;
width:1012px;
padding: 40px 0 20px 0px;
border-bottom: 1px solid #fff;
}
#logo h1, h1{
font-size: 35px;
line-height: 40px;
}
#logo {
float:left;
}
#logo .site-title a , .site-title a{
color: #009999;
font-weight: normal;
font-family: "Georgia";
display: block;
float: left;
font-size: 48px;
line-height: 50px;
margin: 0;
padding: 10px 0 0;
text-decoration: none;
width: 380px;
}
#logo .site-title a:hover {
text-decoration:none;
}
#description {
color: #FFFFFF;
font-size: 12px;
font-style: italic;
font-weight: normal;
margin: 0;
padding: 0 0 0 10px;
display: block;
height: 0;
overflow: hidden;
width: 0;
}
#header-right{
padding: 0px 0 0;
float:right;
width:270px;
}
/* Nav
---------------------------------------------------------------- */
#nav{border-bottom-style: inherit;height: 36px; text-transform: uppercase; width:1012px;
}
.menu-main-container, .menu{margin:0 auto; }
#nav li a .sf-sub-indicator{
width: 11px;
height: 32px;
top: 18px;
right: 0px;
text-indent: -9999px;
overflow: hidden;
position: absolute;
}
#nav li a:hover .sf-sub-indicator{
}
#nav li li a .sf-sub-indicator {
top: 12px;
}
#nav ul {
float: left;
list-style: none;
margin: 0;
}
#nav .sub-menu {
}
#nav .sub-menu .sub-menu{
background: transparent !important;
}
#nav li {
float: left;
list-style: none;
padding: 0;
}
#nav li a {
display: block;
font-family: Helvetica,sans-serif;
text-transform: uppercase;
font-size: 14px;
font-weight: 400;
line-height: 20px;
margin: 0;
padding: 11px 19px;
position: relative;
text-decoration: none;
}
#nav .current-menu-item a {
}
#nav li a:hover, #nav li a:active {
}
#nav li li a, #nav li li a:link, #nav li li a:visited {
font-size:12px;
line-height: 20px;
width: 132px;
margin: 0;
padding:7px 21px 7px 13px;
text-transform:uppercase;
position: relative;
}
#nav li li a:hover, #nav li li a:active {color:#fff;
}
#nav li ul {
z-index: 9999;
position: absolute;
left: -999em;
height: auto;
width: 166px;
margin: 0;
padding: 0;
background:#c06;
text-transform:uppercase;
}
#nav li ul ul {
margin: -35px 0 0 166px;
}
#nav li:hover ul ul, #nav li:hover ul ul ul, #nav li.sfHover ul ul, #nav li.sfHover ul ul ul {
left: -999em;
}
#nav li:hover ul, #nav li li:hover ul, #nav li li li:hover ul, #nav li.sfHover ul, #nav li li.sfHover ul, #nav li li li.sfHover ul {
left: auto;
}
#nav li:hover, #nav li.sfHover {
position: static;
}
#nav li a span {
color:#999;
display: block;
font-size: 10px;
line-height: 14px;
}
/* Main
---------------------------------------------------------------- */
#wrapper{margin:0 auto; width:1012px; padding:0px;}h2
#home-third-left{width:660px;}
#home-sidebar{width:300px; float:right;}
#content-sidebar{width:980px;}
#content{width:660px; float:left; min-height:600px;}
/* Homepage Elements
---------------------------------------------------------------- */
#home-top .a-left ul{margin-left:-3px;}
#home-top .a-left li{float:left; padding-left:4px;}
#home-second h3{font-size:32px;}
#home-top .entry-excerpt p{font-size:13px; font-family:Georgia,"Times New Roman",Times,serif; line-height:22px;width:205px;float:left}
#home-top {padding-bottom: 36px;}
.a-left h3 {padding:10px 0px 10px 0px;font-family: 'Cookie', cursive;}
.a-left h3 a{color:#000000; font-size:45px;}
.a-left{padding-bottom: 5px;}
.a-left{width:660px;}
.a-right p{padding:0 40px 10px 10px;}
.a-right{width:300px; }
.home-post{padding-bottom:15px;margin-bottom:20px; min-height: 135px !important;font-size: 13px;line-height: 22px;}
.home-category {
float:left;
width:635px;
}
.home-category h2{font-size:40px;padding-bottom:20px;}
.small{font-size:10px; color:#999;}
.b-1{width:638px; float:left; padding-right: 4px;padding-top: 25px;}
.b-2{width:400px; float:left;}
.firstpost{padding-bottom:10px;margin-bottom:5px;}
.firstpost .entry-excerpt {font-size: 13px;line-height: 22px}
.b-3{width:445px;float:right; /*font-size:11px; line-height:18px;*/}
.b-1 h3 {line-height:28px;}
.c-1-post {width:200px; margin-left: 20px;margin-bottom:5px}
.c-1 h3{font-size:13px !important;padding-top:5px !important;line-height:20px;padding-bottom: 0px !important;}
.c-2-1{width:260px;}
.c-2-1 h3, .c-2-2 h3, .c-3 h3, .d-1 h3{font-size:26px; padding-bottom:10px;}
.c-2-2{width:380px; }
.c-2-2-post{margin-bottom: 15px;min-height: 100px !important;padding-bottom: 15px;}
.c-2-2 p{line-height:22px;font-size:13px}
.c-3-left, .c-3-right{width:320px;}
.featured-left{float:left; width:320px;}
.block-small-item{
height: 90px;
margin-bottom: 13px;
overflow: hidden;
padding-bottom: 13px; width:320px}
.block-meta {
color: #888888;
display: block;
font-size: 11px;
margin-bottom: 4px;
}
.block-meta a {
color: #888888 !important;
}
.block-meta a:hover {
color: #333333 !important;
text-decoration: none;
}
/* Post Page Style
---------------------------------------------------------------- */
.breadcrumbs {background: none repeat scroll 0 0 #F6F6F6;color: #666666;font-size: 11px;margin: 0 0 10px;padding: 3px 15px; display:none;}
.entry-content p{color: #464646;font-family: Georgia,Sans-serif; margin: 0 0 16px; line-height:24px; font-size: 13px;}
.entry-title{margin-bottom:13px;margin-top: 3px;background: url("images/dot.png") repeat-x scroll left bottom transparent;}
.entry-title h1 { color: #000000!important; }
.entry-content h2, .entry-content h3{ font-size: 32px;}
.entry-content ol, .entry-content ul {margin: 0;padding: 0 0 20px;}
.entry-content ol {margin: 0;}
.entry-content ul li {list-style-type: square;margin: 0 0 0 10px;}
.entry-content ol li {list-style: decimal outside none;margin: 0 0 0 25px;}
.entry-content ol ol, .entry-content ul ul {padding: 0;}
.entry-content li{padding:0 0 5px 0;}
.entry-content .wp-caption-text{color: #666666;font-size: 11px;font-style: italic;line-height: 16px;margin: 0;text-align: center;}
.post-meta {
background-color: #F6f6f6;
border-radius: 5px 5px 5px 5px;
clear: both;
color: #666666;
font-size: 11px;
padding: 7px 10px 5px;
margin-bottom: 15px;
display: none;
}
.entry-content clearfix {
padding-top: 10px;
}
.post-info {
font-size: 12px;
margin-bottom: 10px;
display: inline;
float: left;
padding-bottom: 15px;
font-family: verdana;
color: black;
}
.linkwithin_posts a {
background: none !important;
border: none !important;
padding-right: 5px !important;
}
.linkwithin_hook {
background: none repeat scroll 0 0 transparent;
color: #;
font-weight: bold;
letter-spacing: -0.25px;
line-height: 45px;
margin-bottom: 10px;
}
.linkwithin_text {
color: #cc0066;
font-size: 38px;
padding-left: 10px;
}
.linkwithin_title {
color: #464646!important;
font-family: verdana, sans-serif !important;
font-size: 12px !important;
line-height: 14px !important;
text-decoration: none;
}
.linkwithin_title:hover {
color: #c06!important;
text-decoration: underline !important;
}
.post-info .post-author {
background: url("images/post-author.png") no-repeat scroll left center transparent;
padding: 5px 16px 3px 61px;
font-size: 12px;
font-style: italic;
}
.post-info .time {
font-style:italic;
}en
.post-comments {
background: url("images/post-comments.png") no-repeat scroll left center transparent;
padding: 6px 20px 6px 40px;
}
#disqus_thread {
padding-top: 50px;
}
.cat{
background: url("images/icon-categories.png") no-repeat scroll left top transparent;
padding: 3px 0 3px 22px; display: none;
}
.tags{
background: url("images/icon-tags.png") no-repeat scroll left top transparent;
margin: 0 0 0 10px;
padding: 3px 0 3px 20px; display: none;
}
blockquote {background: url(images/q.png) no-repeat;border: none;margin: 5px 15px;padding: 15px 20px 10px 40px;}
blockquote p {color: #666;font-style: italic;}
.page-template-page-fullwidth-php #content{width:980px;}
#social{width:660px; padding:10px 0 5px; display:none;}
/* Pre- Next
---------------------------------------------------------------- */
#nav-below {padding-bottom:20px;}
.nav-previous a, .nav-next a {background: none repeat scroll 0 0 #0197B2;color: #FFFFFF;float: left;width: 100px;
font-weight: bold;display: block;font-size:12px;line-height:26px;font-family:arial,verdana,sans-serif;
height: 25px;text-align: center;width: 80px;overflow: hidden;}
.nav-previous a:hover, .nav-next a:hover{background:#009999;}
#nav-below .nav-previous a, #nav-below .nav-next a {
padding: 0 10px;
width: 45%;
}
.nav-previous a {
float: right;
}
.nav-next a {
float: left;
}
.nav-next a:hover, .nav-previous a:hover {
text-decoration: none;
}
/* Related Posts
---------------------------------------------------------------- */
.related-posts{ font-size:12px; line-height:18px;}
.relateimage img {border: 1px solid #EEEEEE;
height: 150px;
width: 150px;}
.listing {float: left;
padding-left: 20px;
width: 150px; }
.related-posts-title {
color: #0091A8;
margin:20px 0 10px 22px;
padding-bottom: 15px;}
/* Sidebar
---------------------------------------------------------------- */
#sidebar{
display: inline;
float: right;
line-height: 20px;
width: 300px;
}
#sidebar h4, #latest-posts h4 {
/*background-color: #0AC6F5;*/
background: url("images/banner.jpg") no-repeat top center;
color: #fff;
font-size: 36px;
text-align:center;
line-height: 38px;
padding: 7px 0px 0px 3px;
margin: 0 0 5px;
}
#sidebar p{margin-bottom:10px;}
.widget-wrap {
margin: 0 0 10px;
}
.widget{
margin: 0 0 30px;
}
.widget-area ul li {
border-bottom: 1px dotted #CCCCCC;
list-style-type: none;
padding: 0 0 5px 5px;
word-wrap: break-word;
font-size: 13px;
}
.widget-area li li, .widget-area li li li{
border-bottom: 0 none;
list-style: square outside none;
margin: 0 0 0 20px;
padding: 5px 0 0 0;
}
#sidebar .flickr-photos li{
float: left;
background:none;
list-style-type: none;
padding:8px;
}
#sidebar .twitter h4{
background: url("images/tt.png") no-repeat scroll left center transparent;
line-height: 30px;
padding: 0 0 0 40px;
}
#sidebar_left{
float: left;
width:160px;
#sidebar_left a {
text-decoration:none !important;}
}
a:-webkit-any-link {
text-decoration:none !important;}
}
#header-right a:-webkit-any-link {
padding-right: 15px;
}
#sidebar_right{
float: right;
width:120px;
}
.twitter h4 {
background: url("images/tt.png") no-repeat scroll left center transparent;
padding: 0 0 6px 35px;}
/* archive
---------------------------------------------------------------- */
.archive .post img, .search .post img {width:150px; height:auto;}
#archive-title {padding-bottom:15px; font-size:22px; display:none;}
/* search
---------------------------------------------------------------- */
input[type="button"], input[type="submit"] { border: none;color: #FFFFFF;cursor: pointer;font-size: 13px;font-weight: normal;text-decoration: none; }
input[type="button"]:hover, input[type="submit"]:hover {background-color: #565656; }
input, select, textarea,.sticky, .taxonomy-description {border: 1px solid #DDDDDD;}
#search {width: 265px;
padding-left: 18px;
padding-top: 5px;
padding-bottom: 10px;}
#search .s {
background: #c06;
border: medium none;
color: #fff;
font-size: 12px;
padding: 5px 8px;
width: 157px;float: left;
}
#search .search-submit{background: url("images/s.png") no-repeat scroll center center transparent;
border: medium none;
cursor: pointer;
float: right;
height: 28px;
margin: 0;
right: 0;
top: 0;
width: 39px;}
#search div {
background: #c06;
height: 27px;
position: relative;
border: 2px solid #0AC6F5;
}
/* Pagination
---------------------------------------------------------------- */
.ct-paginate {padding: 10px 0 20px 0; overflow:hidden; clear:both; font-family: arial;}
.ct-paginate a {border:1px solid #eee; margin-right:5px; padding:4px 8px; text-align:center; text-decoration:none;}
.ct-paginate .ct-title {color:#555; margin-right:4px;}
.ct-paginate .ct-gap {color:#999; margin-right:4px;}
.ct-paginate a:hover, .ct-paginate a:active, .ct-paginate .ct-current {color:#fff; background: url("images/navbg.png") repeat scroll 0 0 #333333;border:1px solid #ddd; margin-right:5px;padding:4px 8px;}
/* Footer
---------------------------------------------------------------- */
.footer-info {padding:30px 0;}
.footer-info .right{width:1012px;text-align:center;}
/* =Comments
------------------------------------------------------------------ */
#comments {padding:20px 0 0 0;}
#comments h3,#respond h4{color: #0091A8;
}
#comments a{
text-decoration:none;
}
#comments a:hover{
text-decoration:underline;
}
#comments input:hover, #commentstextarea:hover{
background: #f5f5f5;
}
#commentform {
margin: 5px 10px 0px 0px;
}
#commentform textarea {
width: 90%;
padding: 5px;
font-size:13px
}
#respond:after {
content: ".";
display: block;
height: 0px;
clear: both;
visibility: hidden;
}
#commentform p {
margin: 20px 0;
}
#commentform #submit, .wpcf7-submit{
-moz-box-shadow:inset 0px 1px 0px 0px #fbafe3;
-webkit-box-shadow:inset 0px 1px 0px 0px #fbafe3;
box-shadow:inset 0px 1px 0px 0px #fbafe3;
background:-webkit-gradient( linear, left top, left bottom, color-stop(0.05, #f03c96), color-stop(1, #cc0066) );
background:-moz-linear-gradient( center top, #f03c96 5%, #cc0066 100% );
filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#f03c96', endColorstr='#cc0066');
background-color:#f03c96;
-moz-border-radius:17px;
-webkit-border-radius:17px;
border-radius:17px;
border:1px solid #ee1eb5;
display:inline-block;
color:#ffffff;
font-family:Arial;
font-size:13px;
padding:6px 24px;
text-decoration:none;
text-shadow:1px 1px 0px #ff0080;
}
#commentform #submit:hover, .wpcf7-submit:hover {
background:-webkit-gradient( linear, left top, left bottom, color-stop(0.05, #ef027d), color-stop(1, #ff5bb0) );
background:-moz-linear-gradient( center top, #ef027d 5%, #ff5bb0 100% );
filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ef027d', endColorstr='#ff5bb0');
background-color:#ef027d;
}
#commentform #submit:active {
position:relative;
top:1px;
}
.commentlist {
margin: 0px;
padding: 0px;
}
.commentlist ol {
margin: 0px;
padding: 10px;
}
.commentlist li {
margin: 15px 0;
padding:15px;
list-style: none;
}
.commentlist li ul li {
margin: 10px;
}
.commentlist p {
margin: 10px 5px 10px 0px;
padding: 0px;
}
.commentlist li ul li {
font-size: 12px;
}
.commentlist li .avatar {
background-color: #FFFFFF;
border: 1px solid #EEEEEE;
box-shadow: 0 0 2px rgba(0, 0, 0, 0.1);
float: left;
margin: 0 10px 0 0;
padding: 3px;
}
.commentlist cite, .commentlist cite a {
font-style: normal;
font-size: 14px;
}
.commentlist p {
}
.commentmetadata {
font-weight: normal;
padding:5px 0 0 0;
}
.alt {
margin: 0px;
padding: 10px;
}
.children {
margin: 0px;
padding: 0px;
}
.nocomments {
text-align: center;
margin: 0px;
padding: 0px;
}
.commentmetadata {
font-size: 11px;
margin: 0px;
display: block;
}
.navigation {
display: block;
text-align: center;
margin-top: 10px;
margin-bottom: 40px;
}
.thread-alt {
background: #FFFFFF;
margin: 0px;
padding: 0px;
}
.thread-even {
background: #FFFFFF;
margin: 0px;
padding: 0px;
}
.depth-1 {
border: 1px solid #BBBBBB;
margin: 0px;
padding: 0px;
}
.even, .alt {
border:1px solid #eeeeee;
border-radius: 5px 5px 5px 5px;
}
em.date, .comment strong {
font-weight:normal;
color:#9E825F;
line-height:24px;
display:block;
font-style: normal;
}
/* Socialmedia
---------------------------------------------------------------- */
/* Additional
---------------------------------------------------------------- */
/* Styling posts
---------------------------------------------------------------- */
.one_half, .one_third, .two_third, .three_fourth, .one_fourth {
float: left;
line-height: 21px;
margin-bottom: 20px;
margin-right: 4%;
}
.one_half {
width: 48%;
}
.one_third {
width: 30.6%;
}
.two_third {
width: 65.3%;
}
.one_fourth {
width: 22%;
}
.three_fourth {
width: 74%;
}
.last {
clear: right;
margin-right: 0 !important;
}
.dropcap {
color: #383838;
float: left;
font-size: 40px;
margin-right: 6px;
padding-top: 7px;
position: relative;
text-transform: uppercase;
top: 5px;
}
.highlight1 {
background: none repeat scroll 0 0 #F6F67A;
}
.highlight2 {
background: none repeat scroll 0 0 #000000;
color: #CCCCCC;
}
.mosaic-block {
float:left;
position:relative;
overflow:hidden;
width:210px;
height:120px;
/*background:#111 url(images/progress.gif) no-repeat center center;
-webkit-box-shadow:0 1px 3px rgba(0,0,0,0.5);*/
border-radius: 15px;
}
.mosaic-backdrop {
display:none;
position:absolute;
top:0;
height:100%;
width:100%;
/*background:#111;*/
}
.mosaic-overlay {
display:none;
z-index:5;
position:absolute;
width:100%;
height:100%;
background:#111;
}
.bar .mosaic-overlay {
bottom:-100px;
height:40px;
background:url(images/bg-black.png);
}
.details{ margin:3px 10px; color:#eee; font-size:11px;}
.footer-links-copyright, .footer-links-copyright a{ color:#0AC6F5; font-size:11px;padding-right:10px;}
.attachment1{ text-align:center;}
#content .gallery img, #gallery-listing img{background: none repeat scroll 0 0 #DDDDDD;border: 5px solid #FFFFFF; box-shadow: 0 1px 2px #CCCCCC;margin: 5px; padding: 1px; max-width:160px; height:auto;}
#content .cb_pin_images {
margin-left: auto !important;
margin-right: auto !important;
}
.entry-content img {max-width:100%; height:auto; border: 5px solid #FBDDDF;}
.first-thumb img {
box-shadow:5px 5px 1px #888;}
.hfeed img.thumbnail {
float: left; height: 160px;
}
.archive .hfeed article {
margin-left: 20px;
float:left;
width: 470px;}
}
I changed this HTML for the first image
<center><a href="http://renegadechicks.com/wp-content/uploads/2013/02/centerpiece15.jpg
<img class="size-full wp-image-10673 aligncenter" alt="centerpiece15" src="http://renegadechicks.com/wp-content/uploads/2013/02/centerpiece15.jpg" width="361" height="559">
</a></center>
To this in chrome:
<p style="clear: both;">
<a href="http://renegadechicks.com/wp-content/uploads/2013/02/centerpiece15.jpg">
<img class="size-full wp-image-10673 aligncenter" alt="centerpiece15" src="http://renegadechicks.com/wp-content/uploads/2013/02/centerpiece15.jpg" width="361" height="559">
</a>
</p>
and it seemed to center just fine. I for some reason had to toggle the text-decoration on the tag off then on for it to work...
Basically, I replaced the < center > tags with < p> tags and made sure to clear any floats that were set up before hand.

Site not displaying properly on ipad and iphone. header and footer in place, body/container not

My site is http://farmersforum.in which is not displaying properly on ipad and iphone. The header and footer and left aligned but the body is right aligned and starts from where the header ends.
the #container width is 1020px so i dont think that is the problem. Here's the css code;
/*
Theme Name: gazpoMag
Theme URI: gazpo.com
Description: gazpoMag is a clean and featured-rich Wordpress magazine style theme. It allows you to easily customize every detail of the theme to best suit your needs.
Author: Sami Ch.
Author URI: http://www.gazpo.com
License: GNU General Public License
License URI: license.txt
*/
* {
padding:0;
margin:0;
}
body{
color: #333333;
font-family: Arial, Helvetica, sans-serif;
line-height: 20px;
font-size: 12px;
}
ol, ul {
list-style: none;
}
table {
border-collapse: collapse;
border-spacing: 0;
}
a, a:visited{
text-decoration: none;
color: #004A8D;
}
a:hover{
text-decoration: underline;
color: #004A8D;
}
a { outline: none; }
h2, h3, h4{
font-family: 'Helvetica', Arial;
color: #222;
text-shadow: 0px 0px 1px #ccc;
}
h2{
font-size:16px;
margin:10px 0 3px;
}
h3{
font-size: 16px;
}
h4{
font-size: 16px;
}
h2 a, h2 a:visited{
color:#004A8D;
font-size:16px;
}
h2 a:hover{
text-decoration: none;
color:#133451;
}
a img {
border: none;
}
img.centered {
display: block;
margin-left: auto;
margin-right: auto;
}
img.alignright {
padding: 4px;
margin: 0 0 2px 7px;
display: inline;
}
img.alignleft {
padding: 4px;
margin: 0 7px 2px 0;
display: inline;
}
.alignright {
float: right;
}
.alignleft {
float: left;
}
#container{
margin: 0 auto;
width: 1020px;
text-align: left;
overflow:auto;
background:#ffffff;
}
#header {
background: url("images/bg.png") repeat-x;
}
#header .wrap{
background: url("images/bg.png") repeat-x;
width: 1020px;
height: 120px;
margin:0 auto;
}
#header .logo{
margin-top:7px;
width: 420px;
float:left;
overflow:hidden;
display:table;
}
#header .logo img{
max-width: 415px;
max-height:110px;
}
#header .logo .text{
display:table-cell;
vertical-align:middle;
}
#header .logo h1 a{
font-family: 'Droid Serif', Arial;
font-size:44px;
line-height:0.9;
color:rgba(241,244,245,.7) ;
font-weight: bold;
text-shadow:1px 1px rgba(202,216,221,.7),
2px 2px rgba(202,216,221,.7),
3px 3px rgba(202,216,221,.7);
}
#header .logo h1 a:hover{
text-decoration:none;
}
#header .right{
margin-top:10px;
width: 546px;
float:left;
margin-left: 50px;
}
#header .links {
margin-bottom:10px;
overflow:auto;
}
#header .links ul{
overflow:auto;
color:white;
float:right;
}
#header .links ul li{
float: left;
margin-left:8px;
}
#header .links ul li a {
color: #DAE5EC;
padding-right:8px;
font-size:13px;
font-weight:bold;
}
#header .twitter{
background: url("") no-repeat;
padding-left:55px;
font-family:'Droid Serif', serif;
font-size:14px;
min-height:40px;
max-height:60px;
overflow:hidden;
}
#header #twitter_update_list{
color:#cccccc;
}
#header #twitter_update_list a{
color: #DAE5EC;
}
#subheader{
background: url("images/subheader.png") repeat-x;
}
#subheader .wrap{
width: 1020px;
margin:0 auto;
background: url("images/subheader.png") repeat-x;
height:40px;
text-transform:uppercase;
font-weight:bold;
color: #7B7B7B;
line-height:40px;
}
#subheader ul li{
float: left;
margin-right:25px;
}
#subheader .categories{
width:780px;
float:left;
}
#subheader .search{
width:236px;
float:left;
}
#subheader .search input {
font: normal 14px/100% Arial, Helvetica, sans-serif;
}
#subheader .search .searchfield {
background: #fff;
padding: 7px 6px 7px 8px;
width: 220px;
border: solid 1px #bcbbbb;
outline: none;
margin-top:4px;
border-radius: 15px;
-moz-box-shadow: inset 0 1px 2px rgba(0,0,0,.2);
-webkit-box-shadow: inset 0 1px 2px rgba(0,0,0,.2);
box-shadow: inset 0 1px 2px rgba(0,0,0,.2);
}
#content{
float: left;
width: 716px;
overflow: auto;
}
#featured-cat{
overflow: auto;
margin: 10px 10px 5px;
border-bottom:1px solid #D4D4D4;
}
#featured-cat .cat-title{
background:#f6f6f6;
border-bottom:1px solid #dbdbdb;
padding:5px;
margin-bottom:5px;
}
#featured-cat .box{
width:220px;
float:left;
overflow:hidden;
}
#featured-cat .margin-right{
margin-right:15px;
}
#featured-cat .thumb{
position:relative;
float:left;
width:220px;
height:130px;
overflow:hidden;
}
#featured-cat .date{
position:absolute;
background: #000000;
color: #FFFFFF;
display: block;
font-size: 12px;
font-weight: 700;
opacity: 0.7;
padding: 2px 5px 4px 5px;
top: 20px;
}
#featured-cat .details{
margin-bottom:10px;
clear:both;
padding-top: 8px;
}
#content .post{
overflow: auto;
margin: 10px 10px 5px 0px;
}
#content .s_socialbar{
margin-top:30px;
margin-left: -80px;
display: block;
position: absolute;
background:#ECF5FA;
border-radius:7px;
}
#content .s_socialbar ul{
margin:10px 5px 0px 5px;
}
#content .s_socialbar ul li{
margin-bottom:10px;
}
#content .s_socialbar .fb-like{
margin:0px 0px 4px 4px;
}
#content .post .postmeta {
overflow:auto;
padding:2px;
font-size:12px;
color: #777777;
}
#content .post .postmeta .comments{
float:right;
margin-right: 10px;
background:url(images/comments.png) no-repeat left center;
padding-left:20px;
}
#content .wp-post-image{
background-color: #F3F3F3;
border: 1px solid #DDDDDD;
border-radius: 3px 3px 3px 3px;
}
#content .entry img{
max-width: 97.5%;
height:auto;
border:1px solid #ddd;
padding:2px
background-color:#f3f3f3;
margin:5px 10px 5px 0;
}
#content .thumb-twitter-entry{
overflow:auto;
width: 420px;
float:left;
}
#content .thumb-entry{
float:left;
width: 489px;
}
#content .twitter-entry{
float:left;
width: 635px;
}
#content .entry{
overflow:auto;
margin-bottom:20px;
}
#content .post-twitter{
width: 60px;
float:left;
margin:15px 0px 0px 5px;
}
#content .wp-caption{
border:1px solid #ddd;
text-align:center;
background-color:#f3f3f3;
padding-top:4px;
margin:10px 5px;
-moz-border-radius:3px;
-khtml-border-radius:3px;
-webkit-border-radius:3px;
border-radius:3px;
}
#content .wp-caption img{
margin:0;
padding:0;
border:0 none;
}
#content .wp-caption p.wp-caption-text{
font-size:11px;
line-height:17px;
padding:0 4px 5px;
margin:0;
}
#content .entry blockquote{
background: url("images/quote.png") no-repeat;
font-family: "Georgia", Arial, Helvetica, sans-serif;
color: #777777;
margin: 5px 5px 10px 25px;
padding-left: 32px;
padding-top: 3px;
font-style:italic;
}
#content .entry ul{
list-style-type:square;
margin: 5px 10px 10px 40px;
}
#content .entry ol{
list-style-type:decimal;
margin: 5px 10px 10px 40px;
}
#sidebar{
float: left;
width: 300px;
padding-top:10px;
}
#sidebar h4{
padding: 4px 0px 4px 24px;
border-bottom:1px solid #dbdbdb;
}
#sidebar .box{
margin-bottom:10px;
border-bottom: 1px solid #EFEFEF;
padding:5px;
}
#sidebar_social{
overflow:auto;
margin:10px 0;
}
#sidebar_social a{
font-size: 12px;
font-weight: bold;
padding: 50px 5px 0px;
}
#sidebar_social ul{
overflow:auto;
}
#sidebar_social ul li{
width:70px;
float:left;
padding-top:50px;
text-align: center;
overflow:auto;
}
#sidebar .widget_categories{
margin-bottom: 10px;
}
#sidebar .widget_categories h4{
background:#f6f6f6 url('images/tag.png') no-repeat 5px center;
}
#sidebar .widget_categories ul, #footer .widget_categories ul{
overflow:auto;
padding:10px 5px;
margin: 5px;
}
#sidebar .widget_categories ul li, #footer .widget_categories ul li{
margin-right:8px;
float: left;
font-size: 12px;
margin-bottom: 10px;
}
#sidebar .widget_categories ul li a, #footer .widget_categories ul li a{
background-color: #f6f6f6;
border-bottom: 1px solid #DBDBDB;
border-right: 1px solid #DBDBDB;
color: #777777;
padding: 3px 6px;
text-decoration: none;
white-space: nowrap;
}
#sidebar .widget_categories ul li a:hover,#footer .widget_categories ul li a:hover{
text-decoration: none;
background: #E8E8E8;
}
#sidebar .widget_archive h4{
background:#f6f6f6 url('images/calendar.png') no-repeat 5px center;
}
#sidebar .widget_archive ul, #sidebar .widget_links ul{
padding:5px;
}
#sidebar .widget_archive ul li, #sidebar .widget_links ul li{
padding:3px 0px 3px 12px;
background:url(images/cat_bullet.png) no-repeat left center;
}
#sidebar .widget_links h4{
background:#f6f6f6 url('images/bookmarks.png') no-repeat 5px center;
}
#sidebar .widget_subscribers{
margin-bottom:10px;
}
#sidebar .widget_subscribers .counts{
margin:15px;
overflow:auto;
}
#sidebar .widget_subscribers .counts img{
vertical-align:middle;
}
#sidebar .widget_subscribers .fb{
float:left;
margin-right: 20px;
margin-left:25px;
}
#sidebar .widget_subscribers .twitter{
float:left;
}
#sidebar .widget_subscribers .count{
display: inline-block;
font-size: 22px;
font-weight: bold;
vertical-align: middle;
}
#sidebar .widget_subscribers .count a{
color: #404040 !important;
}
#sidebar .widget_subscribers .count a:hover{
text-decoration:none;
}
#sidebar .widget_posts{
margin-bottom:10px;
}
#sidebar .widget_posts ul.tabs {
height: 30px;
line-height: 24px;
list-style: none;
background: #FFF;
background:url(images/sidebar_posts.png) no-repeat top center;
font-size: 14px;
font-weight: bold;
font-family: 'Droid Serif', Arial;
border-bottom: 1px solid #D4D4D4;
}
#sidebar .widget_posts .tabs li {
float: left;
padding-top:3px;
color: #777;
cursor: pointer;
padding-left: 24px;
}
#sidebar .widget_posts .tabs li:hover {
color: #333333;
text-shadow: 0px 0px 1px #ccc;
}
#sidebar .widget_posts .tabs li.current {
color: #333333;
text-shadow: 0px 0px 1px #ccc;
}
#sidebar .widget_posts .post_box.visible {
display: block;
}
#sidebar .widget_posts .tabs li.recent{
background:#f6f6f6 url('images/calendar1.png') no-repeat 5px center;
margin-right:5px;
width:65px;
}
#sidebar .widget_posts .tabs li.popular{
background:#f6f6f6 url('images/heart.png') no-repeat 5px center;
margin-right:5px;
width:70px;
}
#sidebar .widget_posts .tabs li.comments{
background:#f6f6f6 url('images/comments.png') no-repeat 5px center;
width:80px;
}
#sidebar .widget_posts .posts-list li{
margin-bottom:5px;
font-size: 12px;
overflow:auto;
padding-bottom:5px;
}
#sidebar .widget_posts .post_box {
display: none;
border-width: 0 1px 1px;
padding: 5px;
height:255px;
}
#sidebar .widget_posts .info{
float:left;
width:210px;
}
#sidebar .widget_posts .meta {
font-style:italic;
}
#sidebar .widget_posts .meta .date{
float:left;
}
#sidebar .widget_posts .meta .cmts{
float:right;
margin-right: 10px;
background:url(images/comment.png) no-repeat left center;
padding-left:20px;
font-style:normal;
}
#sidebar .widget_posts .posts-list li .title{
font-weight:bold;
}
#sidebar .widget_posts .thumb{
width: 60px;
height: 40px;
float:left;
margin-right:5px;
}
#sidebar .widget_posts .avatar-42{
width: 42px;
height: 42px;
float:left;
margin-right:5px;
}
#sidebar .widget_posts .comment-info{
float:left;
width:230px;
}
#sidebar .widget_posts .comment-info p{
line-height:15px;
}
#sidebar .widget_facebook h4{
background:#f6f6f6 url('images/facebook.png') no-repeat 5px center;
}
#sidebar .widget_facebook{
margin-bottom:10px;
}
#sidebar .widget_text h4{
background:#f6f6f6 url('images/about.png') no-repeat 5px center;
margin-bottom:5px;
}
#sidebar .widget_text {
margin-bottom:10px;
}
#footer .widget_text h4{
background:url('images/about.png') no-repeat 12px center;
margin-bottom:5px;
}
#sidebar .widget_ad125{
margin-bottom:10px;
overflow:auto;
}
#sidebar .widget_ad125 h4{
background:#f6f6f6 url('images/star.png') no-repeat 5px center;
margin-bottom:5px;
}
#sidebar .widget_ad125 li{
float:left;
margin:10px 10px;
}
#sidebar .widget_ad125 li img{
width:125px;
height:125px;
}
#footer {
background: url("images/bg.png") repeat;
}
#footer .wrap{
width: 1020px;
margin:0 auto;
padding:10px;
overflow:auto;
color: #CCCCCC;
}
#footer .main{
overflow:auto;
padding-bottom:5px;
}
#footer .box{
float: left;
width:330px;
}
#footer .info{
font-size:12px;
}
#footer h4{
padding-left:32px;
margin-bottom:5px;
color: #CCCCCC;
text-shadow:none;
}
#footer a{
color: #DAE5EC;
}
#footer .widget_text{
margin-bottom:10px;
padding: 0 20px;
}
#footer .widget_links ul, #footer .widget_archive ul, #footer .widget_categories ul{
padding:0px 15px;
}
#footer .widget_links h4{
background:url('images/bookmarks.png') no-repeat 12px center;
}
#footer .widget_archive h4{
background:url('images/calendar.png') no-repeat 12px center;
}
#footer .widget_categories h4{
background:url('images/tag.png') no-repeat 12px center;
}
#footer .widget_links, #footer .widget_archive, #footer .widget_categories, #footer .widget_text{
float: left;
width:298px;
margin-right:10px;
}
#footer .widget_links ul li, #footer .widget_archive ul li{
padding: 2px 0 2px 20px;
background:url(images/u.png) no-repeat left center;
}
#footer .widget_tweets{
width:298px;
float:left;
margin-right:30px;
}
#footer .widget_tweets h4.title{
background:url('images/twitter.png') no-repeat 12px center;
}
#footer .widget_social{
width:298px;
float: left;
margin-right:10px;
}
#footer .widget_social h4{
background:url('images/interact.png') no-repeat 12px center;
}
#sidebar .widget_social h4{
background:#f6f6f6 url('images/interact.png') no-repeat 5px center;
}
#sidebar .widget_social ul{
padding:10px 5px;
}
#footer .widget_social ul{
padding:0px 15px;
}
#footer .widget_social ul li{
padding: 2px 0 2px 20px;
}
#sidebar .widget_social ul li{
padding:4px 0px 4px 20px;
}
.widget_social ul li.facebook{
background:url(images/facebook.png) no-repeat left center;
}
.widget_social ul li.twitter{
background:url(images/twitter.png) no-repeat left center;
}
.widget_social ul li.gplus{
background:url(images/gplus.png) no-repeat left center;
}
.widget_social ul li.rss{
background:url(images/rss.png) no-repeat left center;
}
.widget_social ul li.contact{
background:url(images/email.png) no-repeat left center;
}
#gazpo-socialbar {
background: #E3EDF4;
border-color: #E3EDF4;
display: block;
margin-left: -65px;
position: fixed;
top: 200px;
width: 65px;
}
#respond .cancel-comment-reply{
float:right;
}
#comments h3, #content .comments h4 {
margin:10px 0px;
}
#comments ol.commentlist {
margin: 10px 0 20px 0;
list-style-type: none;
overflow: visible;
}
#comments li.comment {
margin-bottom: 10px;
}
#comments li.comment .comment-body {
margin-left: 65px;
position: relative;
min-height:60px;
}
#comments li.comment .comment-meta {
overflow: hidden;
float: left;
display: block;
width: 50%;
}
#comments li.comment .avatar {
position: absolute;
left: -65px;
padding: 3px;
border:1px solid #ddd;
background-color:#f3f3f3;
}
#comments .comment-awaiting-moderation{
color: red;
font-size:12px;
font-style:italic;
}
#comments li.comment p {
clear: both;
}
#comments li.comment cite, li.bypostauthor li.comment cite {
font-weight: bold;
font-style: normal;
padding-right:10px;
margin-right: 8px;
float: left;
}
#comments .commentmetadata, .commentmetadata a {
font-size: 12px;
color: #999;
}
#comments .commentmetadata a:hover {
color: #666;
text-decoration: none;
}
#comments .says {
display: none;
}
#comments .comment-meta {
margin: 0 0 10px;
line-height: 18px;
position: relative;
}
#comments li.comment .comment-body a.comment-reply-link {
display: block;
position: absolute;
right: 0;
top: 0px;
padding-right: 10px;
font-size: 12px;
}
#comments .children {
list-style-type: none;
margin: 10px 0 0px 30px;
}
#comments .children li.comment .comment-body {
margin-left: 70px;
position: relative;
min-height:60px;
}
#comments .children li.comment .avatar {
position: absolute;
left: -65px;
}
#respond {
margin-top:15px;
}
#commentform {
background: #f6f6f6;
border-radius: 3px;
padding: 15px 10px;
overflow:auto;
margin:20px 0px;
}
#commentform .fields-container{
overflow:auto;
margin-bottom:15px;
}
#commentform .info{
float: left;
margin-right: 15px;
width: 250px;
}
#commentform .info span{
font-style:italic;
}
#commentform label{
clear: both;
color: #667780;
display: block;
line-height: 24px;
}
#commentform input{
width: 240px;
border: 1px solid #CAD9E0;
color: #333333;
font-family: Arial, Helvetica, sans-serif;
font-size:14px;
margin-bottom: 6px;
padding: 8px 3px;
}
#commentform textarea {
height: 150px;
width:98%;
border: 1px solid #CAD9E0;
border-radius: 3px;
color: #333333;
font-family: Arial, Helvetica, sans-serif;
font-size: 14px;
margin-bottom: 6px;
margin-top: 2px;
padding: 6px 3px;
}
#commentform .message{
float: left;
width: 410px;
}
#commentform .gazpo-button{
width: 80px;
padding: 6px 8px;
}
.gazpo-button{
border-radius: 6px;
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
cursor: pointer;
display: inline-block;
font: 14px/100% Arial,Helvetica,sans-serif;
margin: 0 2px;
outline: medium none;
padding: 5px 10px;
text-align: center;
text-decoration: none;
text-shadow: 0 1px 1px rgba(0, 0, 0, 0.3);
vertical-align: baseline;
background: -moz-linear-gradient(center top , #FFFFFF, #EDEDED) repeat scroll 0 0 transparent;
border: 1px solid #B7B7B7;
color: #606060;
}
.gazpo-button:hover {
background: #ededed;
background: -webkit-gradient(linear, left top, left bottom, from(#fff), to(#dcdcdc));
background: -moz-linear-gradient(top, #fff, #dcdcdc);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffff', endColorstr='#dcdcdc');
}
.gazpo-button:active {
color: #999;
background: -webkit-gradient(linear, left top, left bottom, from(#ededed), to(#fff));
background: -moz-linear-gradient(top, #ededed, #fff);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ededed', endColorstr='#ffffff');
}
.pagination {
clear:both;
margin: 10px;
text-align:center;
font-family:Verdana,Tahoma,Arial;
font-size: 13px;
padding:4px 6px 4px 0;
background-color:#fff;
color:#313031;
}
.pagination span{
padding: 3px;
margin: 3px;
text-align:center;
}
.pagination a {
padding: 2px 5px 2px 5px;
margin-right: 4px;
border: 1px solid #9aafe5;
text-decoration: none;
color: #2e6ab1;
}
.pagination a:hover, .pagination a:active{
border: 1px solid #2b66a5;
color: #000;
}
.pagination .current{
padding: 2px 5px 2px 5px;
margin-right: 4px;
border: 1px solid navy;
font-weight: bold;
background-color: #2e6ab1;
color: #FFF;
}
just put these inside another div and make it 1020px wide, secure the position and max/min widths.
<div id="wrapper/container">
<div id="header"></div>
<div id="subheader"></div>
<div id="container"></div>
<div id="footer"></div>
</div>
Or re-make theme using responsive design with grid and nice columns.

Navigation bounces on first and last li link in IE 6 only

I'm having a weird problem with my navigation in IE 6. Only the first and last links of the navigation bounce when hovered over.
Why would this be happening?
My CSS file:
#navigation {
width: 930px;
height: 30px;
background-color: #f1faff;
text-align:center;
}
#navigation ul {
margin: 0px;
padding: 0px;
list-style: none;
line-height: 30px;
}
#navigation ul li {
display: inline;
}
#navigation ul li a {
font-family: Arial, Helvetica, sans-serif;
font-size: 14px;
font-weight: bold;
color: #0067b4;
display: inline;
text-decoration: none;
text-transform: uppercase;
padding: 7px 50px;
}
#navigation ul li a:hover {
font-family: Arial, Helvetica, sans-serif;
font-size: 14px;
font-weight: bold;
color: #5e5e5e;
display: inline;
text-decoration: none;
text-transform: uppercase;
padding: 7px 50px;
}
#navigation ul li a.first {
padding-left: 8px;
margin: 0px;
overflow: hidden;
border: 0px;
}
#navigation ul li a.last {
padding-right: 8px;
margin: 0px;
overflow: hidden;
border: 0px;
}
The site where this is happening is available at http://www.paysonsecure.com/protekskiracing/
I would add this to your global-ie6.css
#navigation ul { display: inline-block; }
Thanks gutierrezalex!! I had the same problem and it works adding {display: inline-block;} at my styles..it works for any browser:
ul.menu li a{
text-decoration:none;
color:black;
display:block;
padding:0;
margin:0;
display:inline-block;
}
ul.menu li a:hover{
background-color:#5cc2ed;
color:#ffffff;
display:inline-block;
}

CSS: Submenu not working in IE 7,8 & 9

I created sub menus on a website but when I mouse over the parent link, the sub menus are displayed horizontally instead of vertically. They work fine in Chrome and Firefox.
Here's the HTML code for the menu
<div class="suckertreemenu">
<ul>
<li>Home</li>
<li>About Us
<ul>
<li> Overview</li>
<li> What do we deliver? </li>
<li> Our People
<ul>
<li> Management</li>
<li> Consultants</li>
</ul>
</li>
<li>What is it like working with us?</li>
</ul>
</li>
<li>Solutions
<ul>
<li>Business Model
<ul>
<li>Business Consulting</li>
<li>Technology Consulting</li>
<li> Managed Services Consulting</li>
</ul>
</li>
<li>Modus Operandi</li>
</ul>
</li>
<li>Industries</li>
<li>Alliances</li>
<li>News</li>
<li>Contact Us</li>
</ul>
</div>
Here's my CSS code below.
#charset "utf-8";
/* CSS Document */
Body{
margin:0;
padding:0;
background-color:#DCDCDC;
color:#000;
font-family: Arial, Helvetica, sans-serif;
/*font-size:12px;*/
}
.bodytext{
font-size:12px;
}
H1{
font-family:Arial, Helvetica, sans-serif;
font-size:14px;
font-weight:bold;
color:#000000;
background-image:url(../images/welc_image.jpg);
background-position:left;
background-repeat:no-repeat;
padding-left:12px;
}
P{
font-size:12px;
}
h3{
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size:11px;
font-weight:bold;
color:#000000;
border-bottom:#FF0000 solid 1px;
padding:5px 5px 5px 5px;
}
.btext{
font-size:12px;
}
H2 a:link{
font-family:Arial, Helvetica, sans-serif;
font-size:12px;
font-weight:bold;
color:#666666;
background-image:url(../images/news_image.jpg);
background-position:left;
background-repeat:no-repeat;
padding-left:12px;
}
H2 a:visited{
font-family:Arial, Helvetica, sans-serif;
font-size:12px;
font-weight:bold;
color:#666666;
background-image:url(../images/news_image.jpg);
background-position:left;
background-repeat:no-repeat;
padding-left:12px;
}
H2 a:active{
font-family:Arial, Helvetica, sans-serif;
font-size:12px;
font-weight:bold;
color:#666666;
background-image:url(../images/news_image.jpg);
background-position:left;
background-repeat:no-repeat;
padding-left:12px;
}
H2 a:hover{
font-family:Arial, Helvetica, sans-serif;
font-size:12px;
font-weight:bold;
color: #FF0000;
background-image:url(../images/news_image.jpg);
background-position:left;
background-repeat:no-repeat;
padding-left:12px;
}
H2 {
font-family:Arial, Helvetica, sans-serif;
font-size:12px;
font-weight:bold;
color:#666666;
background-image:url(../images/news_image.jpg);
background-position:left;
background-repeat:no-repeat;
padding-left:12px;
}
.ik img {
background: #ebebeb;
border: solid 1px #d1d1d1;
padding: 5px;
}
#nav{
background-image: url(../images_v2/bg_grad_02.gif);
}
li{
list-style-image: url(../images/bullet2.gif);
font-size:12px;
list-height:30px;
}
.ContactUS
{
color: #FFF;
}
.footer
{
font-size:11px;
color: #000;
}
.businessText {
font-size: 12px;font-size:12px;
color: #FFF;
font-weight:bold
}
.searchText {
font-size: 12px;
color: grey;
}
.partners {
text-align: center;
color:#000;
font-size: 12px;
}
.Block_Headers {
font-family: Arial, Helvetica, sans-serif;
font-size: 14px;
color: #D9D9D9;
}
.searchBox{
background:url(../images_v2/tboxfill.gif)
}
.suckertreemenu ul{
margin: 0;
padding: 2px 0 0 0;
float: left;
font: 14px Arial;
text-align:left;
height:29px;
z-index:100;
}
/*Top level list items*/
.suckertreemenu ul li{
position: relative;
display: inline;
float: left;
/*background-color: #F3F3F3;*/ /*overall menu background color*/
}
/*Top level menu link items style*/
.suckertreemenu ul li a{
float: left;
color: white;
padding: 5px 11px;
text-decoration: none;
background:url(../images_v2/navsplit.gif) no-repeat scroll right center transparent;/*Place right border image here*/
font: 14px Arial;
}
.suckertreemenu ul li a:link{
float: left;
color: white;
padding: 5px 11px;
text-decoration: none;
}
.suckertreemenu ul li a:visited{
float: left;
color: white;
padding: 5px 11px;
text-decoration: none;
}
.suckertreemenu ul li a:active{
float: left;
color: white;
padding: 5px 11px;
text-decoration: none;
border-right: 1px solid white;
background-color: #BD0021;
}
/*1st sub level menu*/
.suckertreemenu ul li ul{
left: 0;
position: absolute;
top: 1em; /* no need to change, as true value set by script */
display: block;
visibility: hidden;
font: normal 13px Arial;
}
/*Sub level menu list items (undo style from Top level List Items)*/
.suckertreemenu ul li ul li{
display: list-item;
list-style:none;
float: left;
top: 14px;
}
/*All subsequent sub menu levels offset after 1st level sub menu */
.suckertreemenu ul li ul li ul{
left: 159px; /* no need to change, as true value set by script */
top: -16px;
}
/* Sub level menu links style */
.suckertreemenu ul li ul li a{
display: block;
width: 160px; /*width of sub menu levels*/
text-decoration: none;
background-color: #31458C;
color: white;
/*font-weight:normal;*/
padding: 10px 11px;
border-top: 1px solid white;
border-right: 1px solid ;
border-left: 1px solid ;
background:none;
}
.suckertreemenu ul li ul li a:link{
display: block;
width: 160px; /*width of sub menu levels*/
text-decoration: none;
background-color: #31458C;
color: white;
/*font-weight:normal;*/
padding: 5px 11px;
border-top: 1px solid white;
border-right: 1px solid ;
}
.suckertreemenu ul li ul li a:visited{
display: block;
width: 160px; /*width of sub menu levels*/
text-decoration: none;
background-color: #31458C;
color: white;
/*font-weight:normal;*/
padding: 5px 11px;
border-top: 1px solid white;
border-right: 1px solid ;
}
.suckertreemenu ul li ul li a:active{
display: block;
width: 160px; /*width of sub menu levels*/
text-decoration: none;
background-color: #31458C;
color: white;
/*font-weight:normal;*/
padding: 5px 11px;
border-top: 1px solid white;
border-right: 1px solid ;
}
.suckertreemenu ul li ul li a:hover{
background-color: #BD0021;
color: white;
border-bottom: none;
/*font-weight:normal;*/
}
#current{
border-bottom:#AA0B34 solid 3px;
color: white;
}
.suckertreemenu ul li a:hover{
color: red;
}
.suckertreemenu ul li a:active{
border-bottom:#BD0021 solid 3px;
color: white;
/*font-weight:normal;*/
}
/*Background image for subsequent level menu list links */
.suckertreemenu .subfoldericon{
background: #31458C url(../images_v2/arrow-right.gif) no-repeat center right;
}
* html p#iepara{ /*For a paragraph (if any) that immediately follows suckertree menu, add 1em top spacing between the two in IE*/
padding-top: 1em;
}
/* Holly Hack for IE \*/
* html .suckertreemenu ul li { float: left; height: 1%; }
* html .suckertreemenu ul li a { height: 1%; }
/* Holly Hack for IE \*/
* html .suckertreemenu ul li ul li { float: left; height: 1%; }
* html .suckertreemenu ul li ul li a { height: 1%; }
/* End */
/* End */
Sir,
You are setting the ul's visibility to hidden but you're not changing its state back to visible on hover, that is why you never see your sub menus.
Put in the following CSS:
.suckertreemenu ul li:hover ul {
visibility: visible;
}
Also, your sub-items display horizontally because they are set to float: left in your CSS.
.suckertreemenu ul li ul li {
list-style:none;
float: left; <------ reset this style!
top: 14px;
}
I hope that helps
I managed to solve it by adding clear:left atrribute to .suckertreemenu ul li ul li property
/*Sub level menu list items (undo style from Top level List Items)*/
.suckertreemenu ul li ul li{
display: list-item;
list-style:none;
float: left;
top: 14px;
**clear:left;**
}

Resources