Jump to content

Recommended Posts

Posted

Boas,

o meu menu em google chrome dá perfeitamente:

http://img593.imageshack.us/img593/483/menuchrome.jpg

mas se eu mudar para internet explorer fica assim:

http://img823.imageshack.us/img823/8956/menuie.jpg

Para pôr a dar em ie as sub-itens usei:

<meta http-equiv="X-PT-Compatible" content="IE=9; charset=utf-8" />

Sem isto eles não aparecem, mas com isto eles aparecem, só que quando tem acentos as letras ficam daquela maneira 😕

Posted

Isso é uma página em PHP, certo?

Usa a função header() do PHP para enviares os headers ao browser sem teres que usar meta tags para isso.

"[Os jovens da actual geração]não lêem porque não envolve um telecomando que dê para mirar e atirar, não falam porque a trapalhice é rainha e o calão é rei" autor: thoga31

Life is a genetically transmitted disease, induced by sex, with death rate of 100%.

Posted

Isso é uma página em PHP, certo?

Usa a função header() do PHP para enviares os headers ao browser sem teres que usar meta tags para isso.

Acho que é isto:

header('Content=IE9; http-equiv=X-PT-Compatible; charset=utf-8',true);
Posted

Acho que é isto:

header('Content=IE9; http-equiv=X-PT-Compatible; charset=utf-8',true);

dá-me isto:

Warning: Cannot modify header information - headers already sent by (output started at F:\xampp\htdocs\joomla1\SGP\Principal\principal.php:5) in F:\xampp\htdocs\joomla1\SGP\menu.php on line 4

Posted (edited)

Acho que é isto:

header('Content=IE9; http-equiv=X-PT-Compatible; charset=utf-8',true);

*slap*

header('X-PT-Compatible: IE9; charset=utf-8');
header('Content-Type: text/html; charset=UTF-8');

dá-me isto:

Warning: Cannot modify header information - headers already sent by (output started at F:\xampp\htdocs\joomla1\SGP\Principal\principal.php:5) in F:\xampp\htdocs\joomla1\SGP\menu.php on line 4

Tens que meter antes da linha 5.

Edited by brunoais

"[Os jovens da actual geração]não lêem porque não envolve um telecomando que dê para mirar e atirar, não falam porque a trapalhice é rainha e o calão é rei" autor: thoga31

Life is a genetically transmitted disease, induced by sex, with death rate of 100%.

Posted

E eu meti.

O menu fiz num ficheiro php á parte. E em todos os outros faço o include do menu.

Tenho assim a primeira parte do menu:



<?php
header('X-PT-Compatible: IE9; charset=utf-8');
header('Content-Type: text/html; charset=UTF-8');
?>

<link rel="stylesheet" type="text/css" href="estilo.css" />
<style media="all" type="text/css">@import "../estilo.css";
</style>

<style type="text/css">
.style1 {
text-align: center;
}
</style>

<body>
<ul  id="nav" class="menu" style="width: 818px; height: 26px;">



<?php
Function logout()
{
session_destroy();
$utilizador="carla.sampaio";
header ("Location: ../Login/index.php");
}
?>

o resto é a criação de li e de ul e assim.

Posted

Boas... experimenta colocar isto

<?php
header('X-PT-Compatible: IE9; charset=utf-8');
header('Content-Type: text/html; charset=UTF-8');
?>

no topo da página... antes de aparecer qualquer tipo de html

Posted

Boas... experimenta colocar isto

<?php
header('X-PT-Compatible: IE9; charset=utf-8');
header('Content-Type: text/html; charset=UTF-8');
?>

no topo da página... antes de aparecer qualquer tipo de html

É o que está :/

Posted (edited)

Aqui está um exemplo

http://www.mediafire...acrmoa5mwdz6l8d

Neste exemplo, na pagina principal, está a fazer o include duas vezes, enganei-me.

Mete no topo da página logo asseguir a tag <php - ob_start();

Se eu puser isso, os caractéres ficam direitos, mas em IE os subitems desaparecem.

Só é preciso que no IE apareçam os subitems e que os caracteres sejam normais

Edited by obamaself
Posted

experimenta por

<?php
header('X-PT-Compatible: IE9; charset=utf-8');
header('Content-Type: text/html; charset=UTF-8');
session_start();
?>

no topo da pagina principal e retiras

<?php
header('X-PT-Compatible: IE9; charset=utf-8');
header('Content-Type: text/html; charset=UTF-8');
?>

do menu.php

Posted

experimenta por

<?php
header('X-PT-Compatible: IE9; charset=utf-8');
header('Content-Type: text/html; charset=UTF-8');
session_start();
?>

no topo da pagina principal e retiras

<?php
header('X-PT-Compatible: IE9; charset=utf-8');
header('Content-Type: text/html; charset=UTF-8');
?>

do menu.php

Está perfeito no google chrome, mas no IE não aparecem os subitems 😕

Posted

E eu meti.

Tem que estar antes da linha 5 do ficheiro:

F:\xampp\htdocs\joomla1\SGP\Principal\principal.php

"[Os jovens da actual geração]não lêem porque não envolve um telecomando que dê para mirar e atirar, não falam porque a trapalhice é rainha e o calão é rei" autor: thoga31

Life is a genetically transmitted disease, induced by sex, with death rate of 100%.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site you accept our Terms of Use and Privacy Policy. We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.