任何人都可以解释Regex.Replace(txtTest.Text,“",string.Empty)这行. ...

编程入门 行业动态 更新时间:2024-10-25 12:27:12
本文介绍了任何人都可以解释Regex.Replace(txtTest.Text,“",string.Empty)这行. ...的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

任何人都可以解释Regex.Replace(txtTest.Text,<.*?>",string.Empty)这行..我还使用过编辑器/Ajax消毒剂bt可能会缺少一些步骤.所以可以

can anyone explain Regex.Replace(txtTest.Text, "<.*?>", string.Empty)this line..Also i had used editor/Ajax sanitizer bt might b i was missing some steps.so can also tel wht will be the proper steps for adding sanitizer?

推荐答案

Regex.Replace将检查您提到的字符(<.*?>),并将替换用<括起来的所有字符. >标签 例如: Hi, Regex.Replace will check for character that you have mentioned(<.*?>)and it will replace all the characters that are enclosed with < > tags Eg: string st="Test";<br /> string str=Regex.Replace(st, "<.*?>", string.Empty);

输出:str="Test"; 关于您的洗手液问题,请查看以下链接 stephenwalther/blog/archive/2011/08/01/ajax-control-toolkit-july-2011-release-and-the-new-html.aspx [ ^ ] stephenwalther/blog/archive/2011/08/17/adding-the-new-html-editor-extender-to-a-web-forms.aspx [ ^ ] 希望这会有所帮助 让我知道是否需要更多详细信息

Output: str="Test"; Regarding your sanitizer question please have a look on the following links stephenwalther/blog/archive/2011/08/01/ajax-control-toolkit-july-2011-release-and-the-new-html.aspx[^] stephenwalther/blog/archive/2011/08/17/adding-the-new-html-editor-extender-to-a-web-forms.aspx[^] Hope this helps Do let me know if you need any more details

许多应用程序可以帮助您学习正则表达式: Expresso表单 www.ultrapico csharpregexdemo RegEx Builder表单 www.softpedia Many applications may help you learn Regular Expressions: Expresso form www.ultrapico csharpregexdemo RegEx Builder form www.softpedia

更多推荐

任何人都可以解释Regex.Replace(txtTest.Text,“",string.Empty)这行. ...

本文发布于:2023-11-04 00:47:49,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1556499.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:这行   任何人都可以   Replace   Regex   Text

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!