开发者

Selecting rows in jQuery [duplicate]

开发者 https://www.devze.com 2022-12-08 17:16 出处:网络
This question already has answers here: Closed 9 years ago. Possible Duplicate: JQuery: How to select rows from a table
This question already has answers here: Closed 9 years ago.

Possible Duplicate:

JQuery: How to select rows from a table

I am a beginner in jQuery. I开发者_JS百科 have a table with multiple rows, how do I select next row or previous row after selecting a particular row?


For the next row (assuming myRow is your selected row element):

$(myRow).next();

I'd recommend using the very powerful selector syntax, instead of selecting previous and next elements based on currently selected element instances, however:

http://docs.jquery.com/Selectors


$(this).next();

or

$(this).prev();
0

精彩评论

暂无评论...
验证码 换一张
取 消