j'ai un petit problème de redirection sur un iframe et je n'arrive pas a trouver la solution
je joint un code PHP en exemple, ou je désire que le form en javascript me renvoie mon lien dans le iframe
<?php
?>
<html>
<head>
<title>exemple</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<!-- formulaire automatique -->
<script type= "text/javascript">
function chpage() {
document.write('<form id="form" action="new.php" method="POST" target="pgcentre"></form>');
setTimeout('document.getElementById(\'form\').submit();', 0);
}
</script>
</head>
<body>
<table border="0">
<tr>
<td>
<!-- ici tous va bien -->
<a href="pg/php/acceuil.php" target="pgcentre">Acceuil</a>
<br />
<!-- ici marche plus -->
<a href="#" onclick = "javascript:chpage();">mon_test</a>
</td>
</tr>
<tr>
<td>
<table>
<tr>
<td>
<!-- par defaut presentation.php -->
<iframe name="pgcentre" seamless sandbox="allow-top-navigation" src="presentation.php" width="100%" height="100%"></iframe>
</td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>