Nama formulir Properti
Contoh
Kembalikan nama formulir:
var x = document.getElementById("myForm").name;
Definisi dan Penggunaan
Properti nama menetapkan atau mengembalikan nilai atribut nama dalam formulir.
Atribut nama menentukan nama formulir.
Dukungan Peramban
Property | |||||
---|---|---|---|---|---|
name | Yes | Yes | Yes | Yes | Yes |
Sintaksis
Kembalikan properti nama:
formObject.name
Setel properti nama:
formObject.name = name
Nilai properti
Value | Description |
---|---|
name | The name of the form |
Detail Teknis
Nilai Kembali: | Sebuah String, mewakili nama bentuk |
---|
Lebih Banyak Contoh
Contoh
Mengubah nama formulir:
document.getElementById("myForm").name = "newName";
Halaman Terkait
Referensi HTML: HTML <form> atribut nama
Objek Bentuk