jQuery [atribut^=nilai] Pemilih

Pemilih jQuery

Contoh

Pilih semua elemen <input> dengan atribut nama yang dimulai dengan "nation":

$("input[name^='nation']")

Definisi dan Penggunaan

Pemilih [attribute^=value] memilih setiap elemen dengan atribut tertentu, dengan nilai yang dimulai dengan string tertentu.


Sintaksis

$("[attribute^='value']")

Parameter Description
attribute Required. Specifies the attribute to find
value Required. Specifies the string the value should begin with

Pemilih jQuery