开发者

Display the Element ID

I am using this statement alert(el.parent().next());

But I am getting [object] [object] as an alert. How do I displa开发者_如何学运维y the ID of the element?


Have you tried?

alert(el.parent().next().attr("id"));


You must get its id attribute:

alert(el.parent().next().attr("id"));


el.parent().next().attr("id")
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜