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

javascript php Ö®¼ä´«µÝ ÖÐÎÄ ±ÜÃâÂÒÂë

ÔÚjavascript´úÂëÖÐÓÃencodeURIComponent()º¯Êý´¦ÀíÖÐÎÄ×Ö·û´®£¬
JS´úÂ룺
<mce:script type=”text/javascript”><!--
string = encodeURIComponent(string);
location.href = index.php?keyword=’+string;
// --></mce:script>
PHP´úÂë:
<?php
$keyword = (isset($_GET['keyword'])) ? $_GET['keyword'] : '';
?>
±£Ö¤JavaScriptºÍAsp¡¢PhpµÈºó¶Ë³ÌÐò¼ä´«Öµ±àÂëͳһ
ÔÚ·ÇÓ¢ÎÄ×Ö·û¼¯µÄÒ³ÃæÉÏ£¬Èç¹ûʹÓÃAjax·½Ê½½øÐÐÊý¾Ý½»»¥µÄ»°£¬
¾Í±ØÐëҪעÒⱣ֤ǰºó¶ËÊý¾ÝµÄͳһ±àÂ룬·ñÔò£¬ºÜÈÝÒ׾ͳöÏÖÂÒÂ룡
ÔÚºó¶ËÊÇASP³ÌÐòµÄÇé¿öÏ£¬±£³ÖÇ°¶ËJavascriptºÍAspÖ®¼ä´«ÖµµÄͳһ±àÂë¿ÉÒÔʹÓÃÒÔϺ¯Êý½øÐд¦Àí£º
±àÂ룺escape(string)
½âÂ룺unescape(string)
ÕâÁ½¸öº¯ÊýÔÚJavaScriptºÍAspÀﶼ´æÔÚ£¬¶øÇÒ¹¦ÄÜÍêÈ«Ò»Ñù£¬
Ö»ÒªÈκÎÒ»¶ËÏòÁíÒ»¶Ë´«Êý¾Ý£¬¶¼ÏÈÓÃescape½øÐбàÂ룬
½ÓÊÕµÄÒ»¶ËÓÃunescape½øÐнâÂë¼´¿É±£Ö¤JavascriptºÍAspÊý¾Ý´«µÝ¹ý³ÌÖв»»á³öÏÖÂÒÂ룡
ÔÚºó¶ËÊÇPHP³ÌÐòµÄÇé¿öÏ£¬±£³ÖÇ°¶ËJavascriptºÍPHPÖ®¼ä´«ÖµµÄͳһ±àÂë¿ÉÒÔʹÓÃÒÔϺ¯Êý½øÐд¦Àí£º
WEBÇ°¶ËJavaScript
±àÂ룺encodeURI(string)
½âÂ룺decodeURI(string)
WEBºó¶ËPhp
±àÂ룺urlencode(string)
½âÂ룺urldecode(string)
ͬÑù£¬´«ÖµµÄʱºòʹÓÃÏàÓ¦µÄ±àÂ뺯ÊýencodeURI»òurlencode£¬
½ÓÊÕµÄʱºòʹÓÃÏàÓ¦µÄ½âÂ뺯ÊýdecodeURI»òurldecode£¬
¼´¿É±£Ö¤JavascriptºÍPhpÊý¾Ý´«µÝ¹ý³ÌÖв»»á³öÏÖÂÒÂ룡
ÔÚWEBÇ°¶ËJavascript½âÂë,PhpÀïurlencode±àÂëµÄÊý¾Ýʱ£¬¿ÉÄÜÐèҪʹÓÃÁ½´Î½âÂ룬È磺
unescape(decodeURI(string))
unescapeÓÃÀ´½âһЩ·Ç×Ö·ûÀàµÄÎÄ×Ö£¬Èç±êµã·ûºÅµÈµÈ¡£ 


Ïà¹ØÎĵµ£º

javascript keycode´óÈ«

    IE   event.keyCode
keycode    8 = BackSpace BackSpace
keycode    9 = Tab Tab
keycode   12 = Clear
keycode   13 = Enter
keycode  &nb ......

Javascript¿ª·¢Ö®jsѹËõƪ

YUI Compressor ѹËõ JavaScript µÄÄÚÈÝ°üÀ¨£º
ÒƳý×¢ÊÍ
ÒƳý¶îÍâµÄ¿Õ¸ñ
ϸ΢ÓÅ»¯
±êʶ·ûÌæ»»£¨Identifier Replacement£©
YUI Compressor °üÀ¨ÄÄЩϸ΢ÓÅ»¯ÄØ£¿
object["property"] £¬Èç¹ûÊôÐÔÃûÊǺϷ¨µÄ JavaScript ±êʶ·û£¨×¢£ººÏ·¨µÄ JavaScript ±êʶ·û——ÓÉÒ»¸ö×Öĸ¿ªÍ·£¬ÆäºóÑ¡ÔñÐԵؼÓÉÏÒ»¸ö»òÕ ......

Javascript ÀàºÍÃüÃû¿Õ¼äµÄ¶¨Òå

//1.Àà
function Test(id)
{
     this.id=id;
     this.method=function()
         {
            //´úÂë
         };
}
......

JavaScriptÈÕÆÚת»»Îª¶«°ËÇøµÄÈÕÆÚ


                    var sDate = new Date(Date.UTC(arys[0], arys[1] - 1, arys[2]));
                    var eDate = new Date(Date.UTC(arys1[0], arys1[1] - 1, arys1[2]));
......

±È½ÏASP/.NET/ASP/PHP/JSPÍøÕ¾¿ª·¢ÓïÑÔ

Ä¿Ç°ÔÚInternetÉϹ㷺ʹÓõĺǫ́¼¼ÊõÖÖÀà·±¶à£¬Ó¦ÓñȽϹ㷺µÄÓÐCGI£¬ASP£¬PHP£¬JSP/JavaServlet£¬ColdFusionµÈ¡£ÔÚÕâÒ»½ÚÀÖ÷Òª½éÉܼ¸ÖÖÔÚ¹úÄÚÓ¦ÓñȽϹ㷺µÄºǫ́ÓïÑÔ¡£
¡¡¡¡CGI£¬È«³ÆΪCommon Gateway Interface
¡¡¡¡CGI¾ÍÊǹ«¹²Íø¹Ø½Ó¿Ú (Common Gateway Interface) µÄËõд¡£ËüÊÇ×îÔç±»ÓÃÀ´½¨Á¢¶¯Ì¬ÍøÕ¾µÄºǫ́¼¼Êõ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ