Ir para conteúdo

POWERED BY:

Arquivado

Este tópico foi arquivado e está fechado para novas respostas.

fabberj

[Resolvido] Como Centralizar Background num Styles.css ?

Recommended Posts

Tenho um site que estou criando, aonde o beta dele está em :

 

http://www.repintores.com.br/aviacao/

 

ele tem um styles.css

 

e eu queria saber como eu faço para que a parte superior ao menu, fique centralizada em qualquer

monitor com resolução superior a 1200pixels de largura ( que é o tamanho da imagem ) sem que mexamos

nas partes inferiores ao menu !

 

aqui o styles.css

http://repintores.com.br/styles.rar

 

 

aqui o código .

 


body { background: url(images/mainbg.jpg) repeat-x 0 0 #fff; color: #171717; 
font-family: "segoe ui", tahoma, arial,helvetica,clean,sans-serif; font-size: 12px; margin: 0; padding: 0; }

a { text-decoration: none; color: #000000; }

#body { width: 100%; margin: 0 auto; padding: 0 0 0 0; background: #ffffff; font-size: 12px; border-top: none; border-bottom: none; padding-bottom: 10px; }

h1 { color: #FF6633; }

h3 { text-decoration: underline; height: 29px; font-size: 22px; padding-left: 0px; padding-bottom: 0px; margin-top: 10px; color: #000000; }

h4 {height: 29px; font-size: 22px; padding-left: 0px; padding-bottom: 0px; margin-top: 10px; color: #000000; }

hr{ margin-top: 15px; height: 1px; border: none; border-bottom: solid 1px #999; }

#innerwrapper { width: 100%; background: #fff; float: right; }

#topBanner { background: url(images/topbanner.jpg) no-repeat ; width: 1200px; height: 150px; text-align: center; }

#topLogin { width: 370px; display: inline; float: right; padding-top: 30px; padding-right: 50px; }

#topNav { font-size: 12px; width: 100%; margin: 0 auto; height: 37px; border-bottom: solid 1px #cccccc; }

#topNav ul { margin: 0; padding: 0; list-style: none; margin: 0 auto; }

#topNav ul li { height: 37px; float: left; padding: 0px; font: bold 12px/37px Arial, Helvetica, sans-serif; }

#topNav ul li a { padding: 0 18px; height: 37px; float: left; text-decoration: none; display: block; color: #666666; font: 14px/37px Arial, Helvetica, sans-serif; }

#bodytext { width: 100%; padding-left: 10px; padding-top: 5px; padding-right: 10px; padding-bottom: 0px; }

.indent { padding-left: 32px; }

.fsfk_section_title { font-weight: bold; }

#mainbox { width: 700px; float: left; padding-right: 20px; }

#sidebar { float: left; width: 210px; }

#messagebox { border: dashed 1px #FF9900; background-color: #FFFFCC; padding: 5px 5px 5px 5px; color: #000000; font-size: 14px; float: right; }

#error { border: 1px solid #FF0000; background: #FFCCDA; padding: 7px; text-align: center; }

#success { border: 1px solid #008020; background: #D8FFCC; padding: 7px; text-align: center; }

dl { position: relative; width: 730px; z-index: 100; clear: both; }

dt { clear: both; float: left; width: 180px; padding: 0px 0 2px 0; text-align: left; font-size: 12px; font-weight: bold; }

dd { float: left; width: 520px; margin: 0 0 8px 0; padding-left: 6px; font-size: 12px; }

dd button { }

dd p { margin-top: 0px; }

dd input { width: 300px; padding: 3px; margin-bottom: 3px; z-index: 500; }

#footer { width: 100%; background: url(images/bottombg.jpg) repeat-x 0 0 #ffffff; height: 88px; margin: 0 auto; padding: 10px 0 0 0; clear: both; text-align: right; border-left: none; border-right: none; }

#footer p { padding: 10px; font-size: 10px; }

/* Tables */
/* tables */
/*
table.tablesorter { width: 100%; }

table.tablesorter input { width: 90%; padding: 3px; border: solid 1px #7094FF; background: #FFFFFF; }

table.tablesorter thead tr th, table.tablesorter tfoot tr th { background-color: #e6EEEE; font-size: 8pt; padding: 4px; }
table.tablesorter thead tr .header { cursor: pointer; }
table.tablesorter tbody td { padding: 6px; vertical-align: top; border-bottom: dashed 1px #333; }
table.tablesorter tbody tr.odd td { background-color: #F0F0F6; }
table.tablesorter thead tr .headerSortUp { background-image: url(images/asc.gif) no-repeat; }
table.tablesorter thead tr .headerSortDown { background-image: url(images/desc.gif) no-repeat; }
table.tablesorter thead tr .headerSortDown, table.tablesorter thead tr .headerSortUp { background-color: #8dbdd8; }
*/

/* Navigation */


.nav, .nav ul { list-style: none; margin: 0; padding: 0; }

.nav { font-family: Arial, Helvetica, sans-serif; z-index: 1000; position: relative; }
.nav li { float: left; margin: 0; padding: 0; position: relative; /*background: url(images/navbg.jpg) repeat-x 0 0 #292929;*/ }
.nav li a, .nav li a:link, .nav li a:active, .nav li a:visited { font: bold 1.22em/25px Arial, Helvetica, sans-serif; color: #959595; display: block; padding: 0 9px; text-transform: lowercase; text-decoration: none; }

.nav li a:hover { background: /*#f2f2f2*/ #FAFBFF; color: #000; }
#nav-one li:hover a, #nav-one li.sfHover a { background: #ccc; color: #000; }
#nav-one li:hover ul a, #nav-one li.sfHover ul a { background: #565656; color: #959595; }
#nav-one li:hover ul a:hover, #nav-one li.sfHover ul a:hover { background: #ccc; color: #000; }

.nav ul { background: #565656; background: url(images/navbg.jpg) repeat-x 0 0 #292929; list-style: none; margin: 0; width: 150px; position: absolute; top: -999em; left: -1px; }
.nav li:hover ul, .nav li.sfHover ul { top: 37px; }
.nav ul li { border: 0; float: none; }
.nav ul a { border: 1px solid #cccccc; border-bottom: 0; padding-right: 20px; width: 150px; white-space: nowrap; }
.nav ul a:hover { background: #ccc; color: #000; }
/* Skin */

@media projection, screen {
/* Use class for showing/hiding tab content, so that visibility can be better controlled in different media types... */
.ui-tabs-hide { display: none; }
}

/* Hide useless elements in print layouts... */
@media print {
.ui-tabs-nav { display: none; }
}

.ui-tabs-nav, .ui-tabs-panel { font-family: "Trebuchet MS" , Trebuchet, Verdana, Helvetica, Arial, sans-serif; font-size: 12px; }
.ui-tabs-nav { list-style: none; margin: 0; padding: 0 0 0 4px; }
.ui-tabs-nav:after { /* clearing without presentational markup, IE gets extra treatment */ display: block; clear: both; content: " "; }
.ui-tabs-nav li { float: left; margin: 0 0 0 1px; min-width: 84px; /* be nice to Opera */ }
.ui-tabs-nav a, .ui-tabs-nav a span { display: block; padding: 0 10px; background: url(images/tab.png) no-repeat; }
.ui-tabs-nav a { margin: 1px 0 0; /* position: relative makes opacity fail for disabled tab in IE */ padding-left: 0; color: #27537a; font-weight: bold; line-height: 1.2; text-align: center; text-decoration: none; white-space: nowrap; /* required in IE 6 */ outline: 0; /* prevent dotted border in Firefox */ }
.ui-tabs-nav .ui-tabs-selected a { position: relative; top: 1px; z-index: 2; margin-top: 0; color: #000; }
.ui-tabs-nav a span { width: 64px; /* IE 6 treats width as min-width */ min-width: 64px; height: 18px; /* IE 6 treats height as min-height */ min-height: 18px; padding-top: 6px; padding-right: 0; }
* > .ui-tabs-nav a span { /* hide from IE 6 */ width: auto; height: auto; }
.ui-tabs-nav .ui-tabs-selected a span { padding-bottom: 1px; }
.ui-tabs-nav .ui-tabs-selected a, .ui-tabs-nav a:hover, .ui-tabs-nav a:focus, .ui-tabs-nav a:active { background-position: 100% -150px; }
.ui-tabs-nav a, .ui-tabs-nav .ui-tabs-disabled a:hover, .ui-tabs-nav .ui-tabs-disabled a:focus, .ui-tabs-nav .ui-tabs-disabled a:active { background-position: 100% -100px; }
.ui-tabs-nav .ui-tabs-selected a span, .ui-tabs-nav a:hover span, .ui-tabs-nav a:focus span, .ui-tabs-nav a:active span { background-position: 0 -50px; }
.ui-tabs-nav a span, .ui-tabs-nav .ui-tabs-disabled a:hover span, .ui-tabs-nav .ui-tabs-disabled a:focus span, .ui-tabs-nav .ui-tabs-disabled a:active span { background-position: 0 0; }
.ui-tabs-nav .ui-tabs-selected a:link, .ui-tabs-nav .ui-tabs-selected a:visited, .ui-tabs-nav .ui-tabs-disabled a:link, .ui-tabs-nav .ui-tabs-disabled a:visited { /* @ Opera, use pseudo classes otherwise it confuses cursor... */ cursor: text; }
.ui-tabs-nav a:hover, .ui-tabs-nav a:focus, .ui-tabs-nav a:active, .ui-tabs-nav .ui-tabs-unselect a:hover, .ui-tabs-nav .ui-tabs-unselect a:focus, .ui-tabs-nav .ui-tabs-unselect a:active { /* @ Opera, we need to be explicit again here now... */ cursor: pointer; }
.ui-tabs-disabled { opacity: .4; filter: alpha(opacity=40); }
.ui-tabs-panel { padding: 1em 8px; background: #fff; /* declare background color for container to avoid distorted fonts in IE while fading */ }
.ui-tabs-loading em { padding: 0 0 0 20px; background: url(loading.gif) no-repeat 0 50%; }

/* Additional IE specific bug fixes... */
* html .ui-tabs-nav { /* auto clear, @ IE 6 & IE 7 Quirks Mode */ display: inline-block; }
*:first-child + html .ui-tabs-nav { /* @ IE 7 Standards Mode - do not group selectors, otherwise IE 6 will ignore complete rule (because of the unknown + combinator)... */ display: inline-block; }

.menu{
border:none;
width:100%;
border:0px;
margin:0px;
padding:0px;
font-family:verdana,geneva,arial,helvetica,sans-serif;
font-size:14px;
font-weight:bold;
color:8e8e8e;
}
.menu ul{
background:url(images/menu-bg.gif) top left repeat-x;
height:43px;
list-style:none;
margin:0;
padding:0;
}
.menu li{
	float:left;
	}
.menu li a{
	color:#ffffff;
	display:block;
	font-weight:bold;
	line-height:43px;
	padding:0px 25px;
	text-align:center;
	text-decoration:none;
	}
	.menu li a:hover{
		color:#000000;
		text-decoration:none;
		}
.menu li ul{
	background:#e0e0e0;
	border-left:2px solid #0079b2;
	border-right:2px solid #0079b2;
	border-bottom:2px solid #0079b2;
	display:none;
	height:auto;
	filter:alpha(opacity=95);
	opacity:0.95;
	position:absolute;
	width:225px;
	z-index:200;
	/*top:1em;
	/*left:0;*/
	}
.menu li:hover ul{
	display:block;
	}
.menu li li {
	display:block;
	float:none;
	width:225px;
	}
.menu li ul a{
	display:block;
	font-size:12px;
	font-style:normal;
	padding:0px 10px 0px 15px;
	text-align:left;
	}
	.menu li ul a:hover{
		background:#949494;
		color:#000000;
		opacity:1.0;
		filter:alpha(opacity=100);
		}
.menu p{
	clear:left;
	}	
.menu #current{
	background:url(images/current-bg.gif) top left repeat-x;
	color:#ffffff;
	}

 

Obrigado aos mestres que possam me ajudar !!!

Compartilhar este post


Link para o post
Compartilhar em outros sites

basta adicionar isto aqui:

 

#topBanner { margin: 0 auto; }

Compartilhar este post


Link para o post
Compartilhar em outros sites

Olá

 

você pode fazer o seguinte código abaixo

 

.menu {
   background: url("images/menu-bg.gif") repeat-x scroll left top transparent;
   border: 0 none;
   font-family: verdana,geneva,arial,helvetica,sans-serif;
   font-size: 14px;
   font-weight: bold;
   margin: 0;
   padding: 0;
   width: 100%;
}

.menu ul {
   background: url("images/menu-bg.gif") repeat-x scroll left top transparent;
   height: 43px;
   list-style: none outside none;
   margin: 0 auto;
   padding: 0;
   width: 700px;
}

 

Já aviso que tem erros de javascript no teu site.

Compartilhar este post


Link para o post
Compartilhar em outros sites

basta adicionar isto aqui:

 

#topBanner { margin: 0 auto; }

 

RESOLVIDO !

 

obrigadão amigo !

 

 

Olá

 

Já aviso que tem erros de javascript no teu site.

 

opa, agradeço se puder citá-los !

abraços !!!

Compartilhar este post


Link para o post
Compartilhar em outros sites

×

Informação importante

Ao usar o fórum, você concorda com nossos Termos e condições.