string str="<p>123asdf<img src='123'/>123456</p><img src='456'>aaaaa";去掉img 标签,返回值为<p>123asdf123456</p>aaaaa
解决方案 »
- ORA-01821: 日期格式无法识别
- list<DateTime> 排序
- 为何ajax调用form中的html元素会出错
- 要插入的数据为空时,不往数据库里写数据?
- 急!!asp.net在html中table是如何分页的??在线等~
- 新手问题!
- DataGrid点击某一行(不是某个控件)调出另一个页面,怎么实现?C#的。
- ASP.net + Ajax使得网站开发真的很简单,实战MS asp.net ajax framework1.0
- GridView怎样把一列设置成固定的值
- 用js将内容post到aspx文件,生产html文件,随机出现重复信息,内容如下
- 关于ado的一个难题
- string 数组排序和对比判断?
void Main()
{
string str="<p>123asdf<img src='123'/>123456</p><img src='456'>aaaaa";
str=Regex.Replace(str,@"(?i)</?img[^>]*?>","");
Console.WriteLine(str);
//<p>123asdf123456</p>aaaaa
}