Forum de discussion
Forum « Programmation HTML » (archives)
trait superposé a tableaux avec DIV
Envoyé: 16 mai 2003, 10h04 par jm
voici 1 exemble qui devrais aider.
merci de votre participation
<html>
<head>
<script Language="javascript">
var pi = Math.PI;
function degToRad(x) { return ( x/(360/(2*pi)) ); }
function radToDeg(x) { return ( x*(360/(2*pi)) ); }
function spin(objet, angle){
var rad = degToRad(angle);
costheta = Math.cos(rad);
sintheta = Math.sin(rad);
var ec = document.getElementById(objet);
if(ec) {
ec.style.filter = "progid:DXImageTransform.Microsoft.Matrix()";
ec.filters.item("DXImageTransform.Microsoft.Matrix").SizingMethod = "auto expand";
ec.filters.item("DXImageTransform.Microsoft.Matrix").FilterType = "bilinear";
ec.filters.item("DXImageTransform.Microsoft.Matrix").M11 = costheta;
ec.filters.item("DXImageTransform.Microsoft.Matrix").M12 = -sintheta;
ec.filters.item("DXImageTransform.Microsoft.Matrix").M21 = sintheta;
ec.filters.item("DXImageTransform.Microsoft.Matrix").M22 = costheta;
}
}
</script>
<style>
#travers{position: absolute; top: -40; left: -40; width: 400; height: 60; z-index: 100;}
</style>
</head>
<body onload="spin('travers',-45);">
<div id="travers">
<table border="1" cellpadding="0" cellspacing="0" width="400" height="72" style="border-top-width: 0; border-bottom-width: 0" >
<tr>
<td width="33%" style="border-left-style:none; border-right-style:none; border-right-width:medium; border-top-style:none; border-bottom-style:none" bgcolor="#000080" height="70"> </td>
<td width="33%" style="border-width:medium; border-style:none; " height="70">
<h1 align="center" style="margin-top: 0; margin-bottom: 0">Vive la République</h1>
</td>
<td width="34%" style="border-left-style:none; border-left-width:medium; border-right-style:none; border-top-style:none; border-bottom-style:none" bgcolor="#FF0000" height="70"> </td>
</tr>
</table>
</div>
<table border = "1" width="100%">
<tr>
<td>a</td>
<td>b</td>
</tr>
<tr>
<td>1</td>
<td>2</td>
</tr>
</table>
</body>
</html>
Réponses
|