开发者

How to see/display/debug the selected dom nodes with jquery?

Is there any good way to see/debug the result of a jQuery selector ?

Let's say we have something like this

var arr = $('div > span').parent();

How can I see what the selector contains? 开发者_StackOverflow

Update

Just to make this a bit harder: Can I do the same in http://jsfiddle.net/ ?


in firebug or chrome console do:

console.log($('div > span').parent());


var arr = $('div > span').parent();
document.write(arr.html());


console.log($('div > span').parent())

with firebug or chrome.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜