Jquery去除从数据库中查询到的内容含有的p标签

时间:2014-03-30 12:08:54   收藏:0   阅读:535

$("#topic_content").html($("#topic_content").text());

 

如果这个数据是通过循环遍历出的数据,就需要下面这个代码了。

1 $(".search_result_content").each(function(index,obj){
2                 var e_obj=$(obj)
3                 e_obj.html(e_obj.text());
4                 
5                 });

Jquery去除从数据库中查询到的内容含有的p标签,布布扣,bubuko.com

原文:http://www.cnblogs.com/laifu/p/3633009.html

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!