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

È¥³ý×Ö·û´®ÖеÄHtml´úÂë

        /// <summary>
        /// È¥µôËùÓÐHTML±êÇ©
        /// </summary>
        /// <param name="strHtml">Ô´×Ö·û´®</param>
        /// <returns></returns>
        public static string DropHTML(string strHtml)
        {
            return Regex.Replace(strHtml, "<[^>]*>", "");
        }


Ïà¹ØÎĵµ£º

htmlÒ³ÃæÖ®¼äµÄ²ÎÊý´«µÝµÄ¾ÖÏÞÐÔ

Á½ÖÖ·½·¨:´óͬСÒì /*
*º¯Êý¹¦ÄÜ£º´Óhref»ñµÃ²ÎÊý
*sHref:   http://www.cscenter.com.cn/arg.htm?arg1=d&arg2=re
*sArgName:arg1, arg2
*return:  the value of arg. d, re
*/
function GetArgsfromHref(sHref, sArgName)
{
   ......

ÄãÕæµÄÁ˽âhtmlÂ𣿠֮script±êÇ©½éÉÜ

Ò»£®ÊôÐÔ£º
src£º¸ÃÊôÐÔÖ¸¶¨ÍⲿJavaScriptÎļþµÄµØÖ·£¬¿ÉÒÔ¿çÓò¡£Èç¹ûÖ¸¶¨Á˸ÃÊôÐÔ£¬ÄÇôscript±êÇ©ÖеÄÄÚÈݾͻᱻºöÂÔ¡£
 
type£ºÖ¸¶¨ËùʹÓõĽű¾ÓïÑÔ£¬¿ÉÒÔ¸²¸ÇĬÈϵĽű¾ÓïÑÔ£¨¼´ÔÚ<META http-equiv="Content-Script-Type" content="type">Öж¨ÒåµÄ½Å±¾ÀàÐÍ
£©¿ª·¢Õß±ØÐëÖ¸¶¨¸ÃÊôÐÔ£¬¸ÃÊôÐÔûÓÐĬÈÏÖµ¡ ......

Html/Jsp³£ÓõÄÒ³ÃæÌøת·½·¨

µÚÒ»ÖÖ£º
<script language="javascript" type="text/javascript">
    window.location.href="login.jsp?backurl="+window.location.href;
</script>
µÚ¶þÖÖ£º
<script language="javascript">
    alert("·µ»Ø");
    window.history.back ......

javascriptÖ®HTML£¨select option£©Ïê½â

Ò»¡¢»ù´¡Àí½â:
var e = document.getElementById("selectId");
e. options= new Option("Îı¾","Öµ") ;
//´´½¨Ò»¸öoption¶ÔÏó,¼´ÔÚ<select>±êÇ©Öд´½¨Ò»¸ö»ò¶à¸ö<option value="Öµ">Îı¾</option>
//optionsÊǸöÊý×é,ÀïÃæ¿ÉÒÔ´æ·Å¶à¸ö<option value="Öµ">Îı¾</option>ÕâÑùµÄ±êÇ©
1:opt ......

³£ÓÃÕýÔò±í´ïʽ´óÈ«£¡£¨ÀýÈ磺ƥÅäÖÐÎÄ¡¢Æ¥Åähtml£©

³£ÓÃÕýÔò±í´ïʽ´óÈ«£¡£¨ÀýÈ磺ƥÅäÖÐÎÄ¡¢Æ¥Åähtml£©
 Æ¥ÅäÖÐÎÄ×Ö·ûµÄÕýÔò±í´ïʽ£º [u4e00-u9fa5]  
¡¡¡¡ÆÀ×¢£ºÆ¥ÅäÖÐÎÄ»¹ÕæÊǸöÍ·ÌÛµÄÊ£¬ÓÐÁËÕâ¸ö±í´ïʽ¾ÍºÃ°ìÁË
¡¡¡¡Æ¥ÅäË«×Ö½Ú×Ö·û(°üÀ¨ºº×ÖÔÚÄÚ)£º[^x00-xff]
¡¡¡¡ÆÀ×¢£º¿ÉÒÔÓÃÀ´¼ÆËã×Ö·û´®µÄ³¤¶È£¨Ò»¸öË«×Ö½Ú×Ö·û³¤¶È¼Æ2£¬ASCII×Ö·û¼Æ1£©
¡¡¡¡Æ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ