jQueryでthisを使ってタグ要素の番号(index)と値を取得
- 2019.05.23
- index(this), this, リストタグ, 要素取得
thisを使ってliタグのクリックした要素番号と値を取得し表示させてみます。 1.CSSの記述例 以下は任意です。 <style> .clWrap{ width:700px; margin:0 auto; text-align:left; } #txtoutput{ width:600px; margin:0 auto; color:#F00; text-align:center; f […]