Bonsoir, j'ai un probléme. C'est le suivant : j'ai ma page web dans laquelle il y a un tableau et un bouton "Imprimer". Lorsque j'imprimer il laisse un grand espace à gauche entre le bord de la feuille A4 et le contenu (le tableau). Bref je voudrais qu'on m'aide à centrer le tableau ou moment de l'impression. Pour que le tableau soit au milieu de la page au moment de l'impression.Comment on fait pour que l'impression soit par défaut en mode paysage. Si c'est n'est pas clair svp faites moi signe!Svp j'attends votre réponse! Merci d'avance! Voici le code de la page, vous pouvez l'éxecuter
<html>
<head>
<title>ETAT DU COMITE</title>
<!-----------les plugin----------------------->
<Style media="print" type="text/css">
.printzone {display:none}
</Style>
<style type="text/css">
<!--
td {color:#000000;font-family:Arial;font-size:10pt;text-decoration:none;}
a:link {color:#6DB3D1;font-family:Arial;font-size:10pt;text-decoration:none;}
a:visited {color:#5F5F5F;font-family:Arial;font-size:10pt;text-decoration:none;}
a:active {color:#6DB3D1;font-family:Arial;font-size:10pt;text-decoration:none;}
a:hover {color:#DB2424;font-family:Arial;font-size:10pt;text-decoration:none;}
body {background-image: url();}
.champ {color: #000000;font-family:Arial;font-size:10pt;text-decoration:none;;background-color: #FFFFFF;border: 1px solid #000000;}
Lcourant{100%}
Edition{color:#000000;background-color:#FFFFFF;font-family:Arial;font-size:10pt;text-decoration:none;}
.Style3 {font-size: xx-small}
.Style4 {font-size: 9pt}
.Style5 {font-size: 9px}
@media print
{.InEo { visibility:hidden; font-size: 9px; } /* ne pas imprimer, visible à l'écran */
.IoEn { visibility:visible; font-size: 9px; } /* imprimer, invisible à l'écran */
.IoEo { visibility:visible; font-size: 9px } /* imprimer, visible à l'écran ;o) */
}
@media screen
{.InEo { visibility:visible; font-size: 9px }
.IoEn { visibility:hidden; font-size: 9px }
.IoEo { visibility:visible; font-size: 9px }
}
.InEo1 {visibility:hidden; font-size: 9px; }
.InEo1 {visibility:visible; font-size: 9px }
-->
</style>
<Style media="print" type="text/css">
.printzone {display:none}
</Style>
<script type="text/JavaScript">
<!--
function OpenWindow(URL,nom_win,parametres,largeur,hauteur)
{
var gauche = (screen.width - largeur)/2;
var haut = (screen.height - hauteur)/2;
if (screen.width - largeur<1) {gauche=0}
if (screen.height - hauteur<1) {hauteur=0}
if (hauteur!="" || largeur!="") {parametres=parametres+',left='+gauche+',top='+haut}
try
{w.close()}
catch (ex)
{
}
w=window.open(URL,nom_win,parametres);
}
function JumpMenu(cible,selectObj,restore)
{
eval(cible+".location='"+selectObj.options[selectObj.selectedIndex].value+"'");
if (restore){selectObj.selectedIndex=0};
}
</script>
//-->
</script>
<SCRIPT type="text/javascript">
<!-- funtion permettant de cacher les zones unutile lors de l'impression
function removeelements(){
var remove_el=document.Frm.remove
if (remove_el!='' && remove_el.length==null){
remove_el.style.display='none'
}else{
for (i=0;i<remove_el.length;i++){
remove_el[i].style.display='none';
}
}
document.bgColor="white";
document.body.style.background='';
}
function revertback(){
setTimeout("window.location.reload()",50);
}
window.onbeforeprint=removeelements;
window.onafterprint=revertback;
// -->
</SCRIPT>
</head>
<body onload=' initialise_traduction();'>
<div id='PosCharte' style='position:absolute;width:973px;height:544px;left:50%;margin-left:-390px;top:40%;margin-top:-272px;' >
<div id='obj_945' style='position:absolute; left:-99px; top:10%; width:129px; height:14px; z-index:383; overflow:visible;' class="printzone">
<table width="100%" height="100%" cellpadding="0" cellspacing="0" border="0">
<tr><td align="left" valign="top"><img src='image_002.jpg' ></td></tr>
</table>
</div>
<div id='obj_948' style='position:absolute; left:472px; top:10%; width:296px; height:10%; z-index:382; overflow:visible;' class="printzone">
<table width="100%" height="100%" cellpadding="0" cellspacing="0" border="0">
<tr><td align="right" valign="top"><font color="#000000" style="font-family:Arial;font-size:12pt;font-weight:bold;text-decoration:none;"><span class='titre_rubrique'> ETAT DU COMITE</span></font></td></tr>
</table>
</div>
<div style='position:absolute; left:-99px; top:126px; z-index:380; overflow:auto;'>
<table border='0' cellpadding='0' cellspacing='0' align='center' >
<tr>
<td colspan="3" >
<table border="1" class="Style3" >
<tr>
<td colspan="19"><div align="center" class="Style30 Style4">ETAT DU COMITE DE COMPENSATION ET PORTEFEUILLE </div></td>
</tr>
<tr>
<td colspan="3"><div align="center" class="Style54 Style3">TIREUR</div></td>
<td colspan="2" class="Style54 Style3">BENEFICIAIRE</td>
<td colspan="4"> </td>
<td colspan="4"><div align="center" class="Style54 Style3">OUTILS DE DECISION </div></td>
<td colspan="6"><span class="Style13"></span></td>
</tr>
<tr>
<th width="32" ><p class="Style52 Style5">Intitulé</p></th>
<th width="67"><p class="Style5" >Coordonnées téléphoniques du client </p></th>
<th width="36" ><span class="Style5">N° de compte </span></th>
<th width="32" ><p class="Style5" >Intitulé</p></th>
<th width="35" ><p class="Style5" >Banque</p></th>
<th width="36" ><p class="Style5" >Montant</p></th>
<th width="29"><p class="Style5" >Solde avant </p></th>
<th width="47"><p class="Style5" >Solde aprés si payement </p></th>
<th width="55"><p class="Style5" >Autorisation</p></th>
<th width="59"><p class="Style5" >Cumul mouvement créditeur annuel </p></th>
<th width="55"><span class="Style5" >Cumul de mouvement des 3 derniers mois </span></th>
<th width="58" ><p class="Style5" >Cumul de mouvement des 30 derniers joours </p></th>
<th width="58"><p class="Style5" >Cumul mouvement crediteurs des 7 derniers jours </p></th>
<th width="56" ><p class="Style5" >Mouvement créditeur journalier moyen </p></th>
<th width="58" ><p class="Style52 Style5">Gestionnaire</p></th>
<th width="19" ><p class="Style52 Style5">Sort</p></th>
<th width="71" ><p class="Style52 Style5">Cumul annuel des apparitions sur l'état de compensation </p></th>
<th width="71" ><p class="Style52 Style5">Date previsionnelle de retour sur autorisation </p></th>
<th width="65" ><p class="Style52 Style5">Observations</p></th>
</tr>
<%
if (rs!=null){
while (rs.next()){
%>
<tr>
<td ><span class="Style52 Style5"></span></td>
<td><span class="Style5"> </span></td>
<td><span class="Style52 Style5"> </span></td>
<td><span class="Style52 Style5"></span></td>
<td><span class="Style5"></span></td>
<td><span class="Style52 Style5"></span></td>
<td><span class="Style52 Style5"></span></td>
<td><span class="Style53 Style5"></span></td>
<td><span class="Style5"></span></td>
<td> </td>
<td> </td>
<td> </td>
<td> </td>
<td> </td>
<td><span class="Style52 Style5"></span></td>
<td> </td>
<td> </td>
<td> </td>
<td> </td>
</tr>
</table>
</td>
</tr>
</table>
<tr> </tr>
<td> </td>
</tr>
<tr> </tr>
<tr> </tr>
<tr>
<td width="25" align="center"> </td>
<td width="585" align="center">
<div align="center" class="printzone">
<input name="Submit2" type="button" class="Style5" onClick="javascript:window.print()" value="Imprimer cette page" >
<input name="Input" type="submit" class="Style5" value="Téléchager le txt" >
</div>
</td>
<td width="724" align="center">
<div align="center"></div></td><td width="4" align="center"> </td>
<form action="/site/extra" method="post" name="Frmextra">
<td width="5" align="center"> </td>
</form>
<td width="20" align="center"> </td>
<td width="5" align="center"></td>
</tr>
</table>
</div>
<div id='obj_954' style='position:absolute; left:-99px; top:115px; width:697px; height:43px; z-index:381; overflow:visible;' class="printzone" >
<script type="text/javascript" src="config_menu_011.js"></script>
</div>
<div id='obj_961' style='position:absolute; top:0px; z-index:1; left: -15px;'></div>
</div>
<script language="javascript">
initialise_traduction();
</script>
</body>
</html>