Ir para conteúdo
View in the app

A better way to browse. Learn more.

Portal do Host

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies


Postado

Põe o website temporariamente em algum lugar pra nós vermos..

Sobre centralizar uma div, a forma do João é mais eficiente, e é nessa linha caso precise centralizar ela tanto na vertical quanto na horizontal.. Mas com o margin:auto; é mais simples mesmo e se tiver width definida, funciona perfeitamente.


Postado

E7, cole no seu código fonte o código que te postei daquele jeitinho. Aí você vê o que acontece.

No código que você posto, tem que mudar o left para 50% e trocar unnamed1 por Layer1.

Quanto ao uso do margin:auto, pode acontecer alguns problemas com IE6 (se você ainda se importa com isso) e em alguns tablets.


Postado
  • Autor

Vejam

"<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html>

<head>

<title>Documento sem t&iacute;tulo</title>

<style type= "text/css">

<!--

body (

margin-left: 0px;

margin-top: 0px;

margin-right: 0px;

margin-bottom: opx;

)

-->

</style>

<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

<script language="JavaScript" type="text/JavaScript">

<!--

function MM_reloadPage(init) { //reloads the window if Nav4 resized

if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {

document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}

else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();

}

MM_reloadPage(true);

//-->

</script>

</head>

<body leftmargin="auto" topmargin="auto" marginwidth="auto" marginheight="auto">

<div id="Layer1" style="position:absolute; left:50%; top:2px; width:920px; height:74px; background-color:#FFFFFF; layer-background-color:#FFFFFF; border:1px none #000000; z-index:1"><img src="index4.jpg" width="920" height="1716"></div>

</body>

</html>


Postado

<body leftmargin="auto" topmargin="auto" marginwidth="auto" marginheight="auto">

<div id="Layer1" style="position:absolute; left:50%; margin-left: -460px; top:2px; width:920px; height:74px; background-color:#FFFFFF; layer-background-color:#FFFFFF; border:1px none #000000; z-index:1"><img src="index4.jpg" width="920" height="1716"></div>

</body>

Só acrescentar o que está em vermelho, e retirar o que está em rosa...


Postado

você precisa remover o position: absolute, o left e o top do css e adicionar o margin: 0 auto, deixando o codigo assim:

<div id="Layer1" style="width:920px; height:74px; background-color:#FFFFFF; layer-background-color:#FFFFFF; border:1px none #000000; z-index:1; margin: 0 auto;"><img src="index4.jpg" width="920" height="1716"></div>


Postado
  • Autor

Opa Obrigado a Todos..Deu certo.!!


Visitante
Este tópico está impedido de receber novos posts.

Quem Está Navegando 0

  • Nenhum usuário registrado visualizando esta página.

Informação Importante

Concorda com os nossos termos?

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.