Voici mon code :
Sous Fx, nickel.
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22 <html> <head> <script type="text/javascript"> function init() { formulaire = document.getElementById('form'); formulaire.appendChild(btn = document.createElement('input')); alert(btn.type); btn['type'] = 'submit'; //btn.type = 'submit'; btn.value = 'go'; btn.onclick = function (evt) { this.disabled = 'disabled'; return true; } } </script> </head> <body onload="init()"> <form action="http://www.google.fr/search" method="get" id="form"> </form> </body> </html>
Sous IE ca merdouille, il me met "Could not get the type property. This command is not supported." sur la ligne qui change le type de mon bouton.
![]()
Quelqu'un dans l'assistance saurait-il me dire comment générer un input type="submit" via js sous Fx et IE ?
Merci d'avance !
Partager