English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية

jQuery [attribute] 属性選択子

jQueryの選択子

[ attribute ]選択子は、指定された属性の[attribute]要素。

構文:

$("[attribute]")

target属性を持つ各要素を選択:

$("document").ready(function(){
  $("[target]").css({"background":"green", "color":"white"});
});
テストを見て‹/›

パラメータの値

パラメータ説明
attribute選択する要素の属性を指定

jQueryの選択子