Bonsoir à tous,

Je voudrais savoir s'il est possible d'ouvrir une popup JS en lui passant en argument de l'html.

Du style :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
 
<SCRIPT LANGUAGE="JavaScript">
<!--
  window.open ('MaPopup', 'MonCodeHtml');
-->
</SCRIPT>
J'ai ce bout de code qui est "fonctionnel" mais je ne trouve pas sa très propre, si quelqu'un a mieux à me proposer je suis preneur :

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
 
<SCRIPT LANGUAGE="JavaScript">
<!--
var chemin = "about:blank";
var name = "ma pop-up";
var html = "<html><body><p>Code Html</p></body></html>";
var fen = window.open(chemin, name,'modal=yes, resizable=yes, height=700, width=800, screenY=100, screenX=100, scrollbars=yes');
fen.document.write(html);
-->
</SCRIPT>
Merci,
Math.