2
Définir la largeur ou la hauteur de l'élément en mode standard
Est-il possible de définir la largeur ou la hauteur de l'élément HTML (ex. <div> ) En JavaScript en mode Standards? Notez le code suivant: <html> <script language="javascript" type="text/javascript"> function changeWidth(){ var e1 = document.getElementById("e1"); e1.style.width = 400; } </script> <body> <input type="button" value="change width" onclick="changeWidth()"/> <div id="e1" style="width:20px;height:20px; background-color:#096"></div> </body> …