What is the difference between Server.HtmlEncode and HttpUtility.HtmlEncode?

Posted by lakhansin-22735 under ASP.NET on 7/10/2013 | Points: 10 | Views : 1631 | Status : [Member] | Replies : 3
Hello Everyone,

Can anyone tell me the exact difference between Server.HtmlEncode and HttpUtility.HtmlEncode?


Thanks,

Lakhan Singh
Tech Lead
BeyondKey System Pvt. Ltd.
Indore, M.P.
India



Responses

Posted by: Raja_89 on: 7/30/2013 [Member] Starter | Points: 25

Up
0
Down
Hai
Server.HtmlEncode
It is an instance of System.web.HTTPServerUtility
Readily accessible through any .aspx [inherit fromthe page object]

HTMLEncode

It comes under the System.Web.HTTPWebUtility
It is a static version [call from the static function or another class does not have an instance of serverutility class] of the server class


Regards



lakhansin-22735, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Ssj_Kumar on: 7/30/2013 [Member] Starter | Points: 25

Up
0
Down
Below link explain the difference
http://www.codeproject.com/Tips/134990/Server-HtmlEncode-vs-HttpUtility-HtmlEncode


Regards,
Jayakumar Selvakani

lakhansin-22735, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: aswinialuri-19361 on: 7/30/2013 [Member] Starter | Points: 25

Up
0
Down
Hi ,
refer this link it might helpful to you
http://forums.asp.net/t/1353828.aspx
http://asp.net.bigresource.com/c-What-is-the-difference-between-HttpUtility-HtmlEncode-and-Server-HTMLEncode-EWXwEo2VO.html
i hope you understand after referring these links


Mark as Answer if it helps you
Thanks&Regards
Aswini Aluri

lakhansin-22735, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response