如何从网页上删除奇怪的字符. [英] How to remove Strange Character  from webpage.

查看:116
本文介绍了如何从网页上删除奇怪的字符.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Hai All

我有一个网页,其中显示了数据库中的某些内容.当我在网页上显示内容时,我得到了符号.

Hai All

I have a web Page which shows some content from database. As I show the content on the web Page I am getting  symbol. How to remove it from the Page.

推荐答案

看看下面的链接.

http://forums.asp.net/t/1323303.aspx/1
Have a look at below link.

http://forums.asp.net/t/1323303.aspx/1


最有可能是编码问题.来自DBMS的数据以不安全的方式注入到HTML中.请在MSDN上参考此文章: http://msdn.microsoft.com/zh-cn/library/aa973813.aspx#anticross_sitescripting_topic4_four [ ^ ].请参阅步骤4:对输出进行编码.

函数AntiXSS.HtmlEncode(String str)将为您进行编码.

问候,

—MRB
It''s most likely an encoding problem. Data from you DBMS is injected into the HTML in an unsafe way. Please refer to this article on MSDN: http://msdn.microsoft.com/en-us/library/aa973813.aspx#anticross_sitescripting_topic4_four[^]. See Step 4: Encode output.

The function AntiXSS.HtmlEncode(String str) will do the encoding for you.

Regards,

—MRB


这篇关于如何从网页上删除奇怪的字符.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆