zcommand 7 Denunciar post Postado Junho 27, 2013 olá pessoal tudo bem? sou novo aqui no forum e ão sei se abri este tópico no local correto, mas espero que vcs possam me ajudar com um problema que estou tendo. estou iniciando em php e estou enfrentando um bug que não to conseguindo corrigir. vamos logo ao assunto. fiz o design do meu site e depois eu dividi ele em partes pois falaram que é a melhor forma para organizar um site seria com includes, mas condo chamo o meu header corpo e rodape, acontece um problema, o header fica afastado do topo do navegador como se eu tivesse colocado um padding nele. O que pode ser isso? Compartilhar este post Link para o post Compartilhar em outros sites
rockrgo 138 Denunciar post Postado Junho 27, 2013 tem algum outro código antes deste include? Compartilhar este post Link para o post Compartilhar em outros sites
JMarcioProgrammer 2 Denunciar post Postado Junho 27, 2013 verifique se existe algo que ocupe espaço fisico antes do include: verifique se no arquivo que vc ta dando include não tem algo que tbm ocupe espaço: no final das contas se não achar o erro disponibilize o codigo do header corpo e o do arquivo que está recebendo o include! Compartilhar este post Link para o post Compartilhar em outros sites
zcommand 7 Denunciar post Postado Junho 27, 2013 olá pessoal, obrigado pelo interesse em me ajudar. Não tem nada no include ocupando espaço físico. Já tentei de várias formas, mas da o mesmo erro, deixei apenas assim o index com os includes: <?php include_once("header.php" )?> ai deixei uma div do corpo neste index dessa forma <div id="conteudo-corpo"></div> e o include do rodape <?php include_once("rodape.php" )?>. essa foi minha última tentativa, mas não surtiu efeito. o que pode ser? Compartilhar este post Link para o post Compartilhar em outros sites
Lauro Daniel 15 Denunciar post Postado Junho 27, 2013 Da uma olhada no CSS, a div pode ter uma margem. Seu problema não está no include, pode ter certeza disto. Seu problema é de design, HTML ou CSS. Compartilhar este post Link para o post Compartilhar em outros sites
TiagoMaker 3 Denunciar post Postado Junho 27, 2013 manda o código do header e do teu index Compartilhar este post Link para o post Compartilhar em outros sites
zcommand 7 Denunciar post Postado Junho 27, 2013 Ei amigos o código do index é só aquele q postei acima não tem mais nada, pois tirei tudo para ver se funcionaria. O html do header é esse: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>modelo</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> <body> <div id="barra-tecnocom"><!-- começo barra --> <div class="conteudo-barra"><!-- conteudo da barra--> </div><!-- fim do conteudo da barra --> </div><!-- fim barra--> <div id="tecno-doc"><!-- tecno doc--> <div id="tecno-topo"><!--começo topo--> <div id="tcn-cabecalho"><!--começo cabeçalho--> <div class="conteudo-cabecalho"> <div id="logo"> <a href="#" id="img-logo"> <img src="images/tz-logo-log.png" alt="Pagina Inicial do Tecno Zoom" title="Pagina Inicial do Tecno Zoom" class="borda-ico-ms"/></a> </div> <div id="info"> <span class="titulo-info">NÃO SEI QUE PORRA COLOCAR AQUI</span> </div> <div id="search"><form action="" method="get"><input class="txt-search" name="q" placeholder="Faça uma busca" type="text" /><button class="btn-search" name="go" type="submit"><img class="ic-search" src="images/icone_home_lupa.png" /><b id="bb">Busca</b></button></form></div> </div> </div><!--fim cabeçalho--> <div id="tcn-menu"><!--começo menu--> <div class="conteudo-menu"> <div id="menu-navegacao"> <ul class="list-menu"> <li class="li-menu"><a href="#" class="a-menu">Início</a></li> <li class="li-menu"><a href="#" class="a-menu">Plugado</a> <ul id="ul-list-menu"> <li id="li-menu-dropdown" class="t01"><a href="#" id="a-list-dropdown">Animes & Desenhos </a></li> <li id="li-menu-dropdown"><a href="#" id="a-list-dropdown">Bizarro</a></li> <li id="li-menu-dropdown"><a href="#" id="a-list-dropdown">Curiosidades</a></li> <li id="li-menu-dropdown"><a href="#" id="a-list-dropdown">Filmes & Séries</a></li> <li id="li-menu-dropdown"><a href="#" id="a-list-dropdown">Games</a></li> <li id="li-menu-dropdown"><a href="#" id="a-list-dropdown">Humor</a></li> <li id="li-menu-dropdown" class="t02"><a href="#" id="a-list-dropdown" class="2">Musica & Entretenimento</a></li> </ul></li> <li class="li-menu"><a href="#" class="a-menu">Como Faz</a></li> <li class="li-menu"><a href="#" class="a-menu">Download</a></li> <li class="li-menu"><a href="#" class="a-menu-01">Contato</a></li> </ul> </div> </div> </div><!--fim menu--> </div><!--fim topo--> Compartilhar este post Link para o post Compartilhar em outros sites
TiagoMaker 3 Denunciar post Postado Junho 27, 2013 no header tu não coloca essas informações que destaquei, pois elas já estão no index e como você está inserindo sua página na index não teria porque eles constarem novamente, saca? <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR...ransitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>modelo</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> <body> Compartilhar este post Link para o post Compartilhar em outros sites
zcommand 7 Denunciar post Postado Junho 27, 2013 no header tu não colocaca essas informações que destaquei, pois elas já estão no index e como você está inserindo sua página na index não teria porque eles constarem novamente, saca? <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR...ransitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>modelo</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> <body> Tiago, eu sei que estas informações tem que estar no index, mas da mesma forma estava ocorrendo esse problema, ai fui orientado a colocar esta parte direto no header e tirar do index para ver se assim iria funcionar, mas independentemente de como eu faça isso sempre buga. obs esses codigos so estão no header e não no index, o index so tem os código dos include Compartilhar este post Link para o post Compartilhar em outros sites
TiagoMaker 3 Denunciar post Postado Junho 27, 2013 Está invertido, o index carrega as informações principais e o header, footer teriam seus respectivos conteúdos, verifica se o BOM não está incluso nas páginas. se usa o dreamweaver vai em propriedades de página > título-codificação e desmarca incluir assinatura unicode (BOM) e salva Compartilhar este post Link para o post Compartilhar em outros sites
zcommand 7 Denunciar post Postado Junho 27, 2013 Está invertido, o index carrega as informações principais e o header, footer teriam seus respectivos conteúdos, verifica se o BOM não está incluso nas páginas. se usa o dreamweaver vai em propriedades de página > título-codificação e desmarca incluir assinatura unicode (BOM) e salva Está ok então vou vou fazer de novo os códigos de maneira correta e verificar se não tem nada em lugar errado e tentar esta sua dica, ai posto o resultado, valeu por enquanto.. abraço Compartilhar este post Link para o post Compartilhar em outros sites
Lauro Daniel 15 Denunciar post Postado Junho 28, 2013 Posta o seu CSS, provavelmente o "problema" está nele. Compartilhar este post Link para o post Compartilhar em outros sites
zcommand 7 Denunciar post Postado Junho 28, 2013 Posta o seu CSS, provavelmente o "problema" está nele. ei cara vc quer que eu post o css inteiro ou so a parte do header? Compartilhar este post Link para o post Compartilhar em outros sites
vonzuben 12 Denunciar post Postado Junho 28, 2013 com certeza é erro no menu navegação Compartilhar este post Link para o post Compartilhar em outros sites
zcommand 7 Denunciar post Postado Junho 28, 2013 esse é o css @charset "utf-8"; * {background: transparent; font-family: inherit; font-size: 100%; margin: 0;outline: 0;padding: 0;} body { background:#FFF;} #barra-tecnocom{ width:100%;background:#F3F3F3; height:40px;}.conteudo-barra { width:960px; background:#F3F3F3; margin:0 auto;} #tecno-doc{font-size: 1.2em;text-align: center;width: 100%;}#tecno-topo { width:100%; background:#fbfbfb; height:154px; border-bottom:1px solid #999;}#tcn-cabecalho{ width:100%; position:}.conteudo-cabecalho { width:960px; margin:0 auto;border-bottom:1px solid #ccc; height:120px; position:relative;}#logo{display: block;float: left;height: 90px;overflow: hidden;width: 120px; margin-top:25px;}.borda-ico-ms {border:0;}#info{display: inline-block;font-family: ProximaNova-Light;height: 35px;padding-left: 30px;position: relative;text-transform: uppercase;vertical-align: top;zoom: 1;float: left;}.titulo-info{font-family: ProximaNova-Light; font-weight: normal; font-size: 18px; margin-top: 55px; margin-left: -2px; letter-spacing: -1px; cursor: default;display: block; color:#999;}#search {position: absolute;width: 360px;height: 34px;top: 45px;left: 600px;}#search .txt-search {border-width: 1px;border-style: solid;border-color: #cccccc #dedede #dedede;border-radius: 4px 0 0 4px;padding: 8px;width: 252px;height: 16px;font-size: 14px;line-height: 16px;color: #aaa;float: left;}#search .btn-search {border-style: none;border-radius: 0 4px 4px 0;width: 90px;height: 34px;float: right;color: #fff;font-size: 14px;line-height: 1;cursor: pointer;text-transform: lowercase;background:#999;}#search .btn-search:hover { background:#c3c3c3;}#bb{ padding:7px 2px 1px; float:left;}#search .btn-search .ic-search {float: left;width: 30px;height: 30px;margin-right: 4px;} #tcn-menu { width:100%; height:30px;} .conteudo-menu {width:960px; margin:0 auto;} #menu-navegacao { width:519px; height:30px; background:#fbfbfb; float:left;}.list-menu { list-style-type:none; border:0;}.li-menu { position:relative; float:left;}.a-menu { text-decoration:none; padding:0px 17px;color:#666; display:block; border-right-style:dashed; border-right-width:thin; border-right-color:#CCC; margin-top:5px;}.a-menu-01 { text-decoration:none; padding:0px 17px;color:#666; display:block; margin-top:5px;}.a-menu:hover { background:#f3f3f3; border-bottom:2px solid #900; padding:5px 17px; margin-top:0;}.a-menu-01:hover { background:#f3f3f3; border-bottom:2px solid #900; padding:5px 17px; margin-top:0;}.li-menu #ul-list-menu { position:absolute; top:32px; left:0px; display:none; list-style-type:none; border:0; background:#FFF;}.li-menu:hover #ul-list-menu, .li-menu.over #ul-list-menu{display:block;}.list-menu .li-menu #ul-list-menu #li-menu-dropdown{ width:250px; border-left:1px solid #CCC; border-right:1px solid #CCC;height:30px; padding-top:5px; text-align:justify;}.t01{ border-top:2px solid #900;}.t02{ border-bottom:1px solid #CCC}.list-menu .li-menu #ul-list-menu #li-menu-dropdown #a-list-dropdown{ padding:10px; margin-top:5px; text-decoration:none; color:#333;}.list-menu .li-menu #ul-list-menu #li-menu-dropdown:hover{background:#f3f3f3;}#tecno-corpo{ width:100%; overflow:auto; padding-bottom:20px;}.conteudo-corpo{ width:960px; margin:0 auto;}#topo-do-corpo{ width:960px; margin:0 auto; height:200px; padding:10px 0;}#coluna-esquerda { width:640px; float:left;}#coluna-direita{ width:320px; float: right;}#publicidade-01 {width:320px; margin:0 auto; height:200px; background:#CCC; position:relative;}#spc-title { width:80px; margin:0 auto; padding-top:10px;}#colunistas { width:320px; margin:0 auto; height:250px;}#title-colunistas { width:300px; height:40px; background:#F3F3F3; margin:0 auto; border:1px solid #CCC; border-top:2px solid #900; text-align:center;} #a-colunistas {text-decoration:none; color:#000;} #cronistas { width:300px; height:200px; background:#fbfbfb; margin:0 auto; border-left:1px solid #CCC; border-right:1px solid #CCC; border-bottom:1px solid #CCC;}#top-cinco { width:320px; margin:0 auto;}#camp-top-title{ width:80px; margin:0 auto; padding-top:10px;}#top-title { width:300px; height:40px; background:#F3F3F3; margin:0 auto; border:1px solid #CCC; border-top:2px solid #900; text-align:center;}#camp-top {width:300px; background:#fbfbfb; margin:0 auto; border-left:1px solid #CCC; border-right:1px solid #CCC; border-bottom:1px solid #CCC;}ol { list-style-type: upper-roman; list-style-position:inside; padding:15px; color:#999;}#li-top5 { padding:7px; border-bottom-style:dashed; border-bottom-width:thin; border-bottom-color:#CCC;}#a-top5 { text-decoration:none; color:#000;}#a-top5:hover { text-decoration: underline;} #rodape { width:100%; background:#8B0000; height:200px;}.conteudo-rodape{ width:960px; margin:0 auto; background:#8B0000; height:160px;}#col-rodape-01 {width:320px; height:90px; padding:35px 0; float:left;}#col-rodape-02{width:320px; float: left; height:90px; padding:35px 0;}#ul-barra-diretorio { list-style-type:none; text-align:justify; margin:0 0 0 15px;}#a-barra-diretorio { text-decoration:none; color:#FFF;}#a-barra-diretorio:hover { text-decoration: underline;}#txt-midia-sociais { height:20px; padding:5px; margin:0 auto; text-decoration:underline; color:#fbfbfb;}.gallery{ list-style: none; margin:0; padding: 5px 64px; width: 200px; /* (200+10+4)x3 */ font-size: 0; /* fix inline-block spacing */ border:0; } .gallery #msocial-li{ display: inline-block; *display: inline; zoom: 1; width: 40px; height: 40px;padding:5px; border:0; -webkit-transition: all .3s ease; -moz-transition: all .3s ease; -ms-transition: all .3s ease; -o-transition: all .3s ease; transition: all .3s ease; } .gallery:hover #msocial-li #msocial-a{display: inline-block; *display: inline; width: 40px; height: 40px; border:0;} .gallery:hover #msocial-li #msocial-a:not(:hover){ border:0; -webkit-filter: blur(2px) grayscale(1); -moz-filter: blur(2px) grayscale(1); -o-filter: blur(2px) grayscale(1); -ms-filter: blur(2px) grayscale(1); filter: blur(2px) grayscale(1); opacity: .7; /* fallback */ } #col-rodape-03{width:320px; float:right; text-align:center; color:#fff; padding:35px 0;}#ul-criator { list-style-type:none;}#a-creator { text-decoration:none; color:#FFF;}#a-creator:hover { text-decoration: underline;} .borda-ico-ms{ border:0px;}#txt-rodape { width:100%; background:#800000; height:20px; padding:10px 0; color:#FFF;} Compartilhar este post Link para o post Compartilhar em outros sites