Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

¼òµ¥µÄ±£Ö¤Ô­ÑùÊä³öhtmlµÄc#´úÂë

 public string NoExcuteHtml(string Htmlstring)
    {
        string x = string.Empty;
        x = Htmlstring.Replace(@"&", "&");//½«&ÉèÖÃΪ±£Áô×Ö
        x = x.Replace(@"<", "&lt;"); 
        x = x.Replace(@">", "&gt;");
        x = x.Replace(@" ", "&nbsp;");
        x = x.Replace("\r\n", "<br/>");
        return x;
    }


Ïà¹ØÎĵµ£º

¹ØÓÚasp.net c#ÖжÔcookieµÄ²Ù×÷


ÏÂÃæÊÇдcookie
1 HttpCookie cookie = new HttpCookie("Info");//¶¨Òåcookie¶ÔÏóÒÔ¼°ÃûΪInfoµÄÏî
2 DateTime dt = DateTime.Now;//¶¨Òåʱ¼ä¶ÔÏó
3 TimeSpan ts=new TimeSpan(1,0,0,0);//cookieÓÐЧ×÷ÓÃʱ¼ä£¬¾ßÌå²émsdn
4 cookie.Expires = dt.Add(ts);//Ìí¼Ó×÷ÓÃʱ¼ä
5 cookie.Values.Add("user","cxbkkk");//Ôö¼ ......

HTML±í¸ñÔÚIEÖÐֵΪ¿Õʱ²»ÏÔʾ±í¸ñ±ß¿òµÄ½â¾ö·½·¨

<table border="1" style="empty-cells:show; border-collapse:collapse;"> 
    <tr><td>111</td><td></td> 
    <tr><td></td><td>2222</td> 
<table> 
attention: 
style="empty ......

Html ÎÄ×Ö¹ö¶¯

¹ö¶¯×ÖÄ»»áÈúܶàÈ˸е½ÐË·Ü£¬ÌرðÊǵÚÒ»´ÎʹÓùö¶¯×ÖĻʱ£¬»á°®²»ÊÍÊÖ¡£ÏÖÔÚ×öÒ»¸öÏêϸµÄ·½°¸£¬ÈÃÄã¸üÈ«ÃæµØÁ˽âһϡ£
¡¡¡¡¹ö¶¯×ÖÄ»ÔÚFrontPageµÄ×é¼þÀïÓУ¬µ«ÊÇFrontPageÕâ¸öÈí¼þÖ»ÄÜÖ§³Öµ¥ÐÐÎÄ×Ö£¬Ò»³öÏÖ¶àÐÐÎÄ×ÖËü¾ÍÎÞÄÜΪÁ¦ÁË£¬¶øÇÒËüÖ»ÄÜÖ§³ÖÒ»Ðйö¶¯!(Èç¹û³öÏÖÖ»Äܹö¶¯Ò»ÐеÄÇé¿ö£¬½â¾ö°ì·¨ÊÇ°ÑÕâ¶Î´úÂëǶÈëµ½Java ......

ÕýÔò±í´ïʽ»ñÈ¡HTML±ê¼ÇÖеÄÄÚÈÝ£¨C#£©


ÕýÔò±í´ïʽ»ñÈ¡HTML±ê¼ÇÖеÄÄÚÈÝ£¨C#£©
//=====================Begin1========================
            //ÊÔÑé×Ö·û´®
            string strTmp = string.Empty;
    &n ......

Web¿ª·¢ µÚÒ»²¿·Ö HTML½Ì³Ì»ù´¡£¨Ê®£©Áбí

ÉÏÒ»ÕÂÎÒÃÇѧϰÁË“±í¸ñ”µÄ»ù±¾Ó÷¨£¬¿ÉÒÔ¿´µ½£¬±í¸ñ½«ÄÚÈÝÒÔÐÐÁз½Ê½½øÐÐ×éÖ¯²¼¾Ö£¬¿ÉÒÔÈÃÍøÒ³µÄÔĶÁÕ߷dz£ÈÝÒ׵ĻñÈ¡µ½ÐÅÏ¢¡£
ÕâÒ»ÕÂÎÒÃǽéÉÜÁ½ÖÖÁÐ±í£¬ËùνÁбí¾Í¿ÉÒÔ¿´×÷Ϊ±í¸ñµÄÒ»ÁУ¬¿ÉÒÔ°ÑÒ»ÀàÄÚÈÝ×éÖ¯ÔÚÒ»Æð¡£
ÓÐÁËÇ°ÃæµÄ»ù´¡£¬ÁбíºÜºÃÕÆÎÕ£¬Ö»ÐèÒª¼ÇסһЩ±êÇ©ºÍÊôÐÔ¼´¿É¡£
----------------
µ¥ÁÐ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ