开发者

Selecting rows in jQuery [duplicate]

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

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜