filter()和not(): 复制代码 代码如下: <BR>$(document).ready(function() { <BR>//输出 hello <BR>alert($("p").filter(".selected").html()); <BR>//输出 How are you? <BR>alert($("p").not(".selected").html()); <BR>}); <BR> Hello How are you? split(): 复制代码 代码如下: <BR>$(document).ready(function(){ <BR>$("input[@value=btn1]").click(function(){ <BR>//以¥分割 <BR>alert($("span.sale").text().split("¥")[2]+"||"+$("span.sale").text().split("¥")[1]+"||"+$("span.sale").text().split("¥")[0]); <BR>}); <BR>}); <BR> 获取价格120: Out Sale: ¥160 Deal Price: ¥120