<input type = class teks = name txt = qty value = onkeyup = this.value = this.value.replace (/[^0-9 /./ g, '')/>PS: kotak teks implementasi JS yang hanya dapat memasukkan angka dan titik desimal
<html> <head> <meta http-equiv = konten-tipe konten = teks/html; JavaScript> function clearnonum (OBJ) {obj.value = obj.value.replace (/media^/d. bah/g,); g,); ganti (., $#$). Poin: <input name = input1 onkeyup = clearnonum (this)> </body> </html>Di atas adalah semua isi artikel ini.