phpÓëjavascriptÖ®¼ä±äÁ¿ÒýÓÃÎÊÌâ
JavaScript ==> PHP£º
·½·¨Ò»: ÏÈÓÃPHPÉú³Éjs´úÂ룬Ȼºóͨ¹ýä¯ÀÀÆ÷µÄ×Ô¶¯Ë¢Ð£¬½«javascript±äÁ¿´«µÝµ½PHP½Å±¾ÖС£
×¢Ò⣺ÔÚʵ¼ÊÓ¦ÓÃÖÐÒª·ÀÖ¹Óû§ÔÚµØÖ·À¸ÄÚ¸ü¸Ä´«µÝµÄ±äÁ¿Öµ¡£
<?php
if($qq) echo $qq.'<br>';
else echo "<script language='javascript'>var qq='ÎÒµÄQQÊÇ1234567'; location.href='?qq='+qq; </script>";
echo $qq;
?>
·½·¨¶þ£ºÏÈÓÃdocument.cookie·½·¨°Ñjs±äÁ¿Ð´ÈëcookieÖУ¬ÔÙÓÃPHPÈ¡³ö¡£
<script language="javascript" type="text/javascript">
var name = "myqq",value="10000";
document.cookie = name+" = "+value+";"
</script>
<?php
echo $_COOKIE["myqq"]."<br/>";
$my = "ÎÒµÄQQÊÇ".$_COOKIE["myqq"];
echo $my;
?>
·½·¨Èý£º
<script>
var a = 'ÎÒÊÇÐñÈÕ£¡';
</script>
<?php
$c = "<script>document.write(a);</script>";
echo $c;
?>
PHP ==> JavaScript £º
//·½·¨Ò»£ºÒÔhtmlΪý½é, php±äÁ¿-->html¶ÔÏó-->javascriptµ÷Óá£
<?php
$val_overview_pic = "ÎÒÊÇÐñÈÕ£¡";
?>
<input type="hidden" name="did" value="<?=$val_overview_pic;?>">
<script language="javascript" type="text/javascript">
alert(did.value);
//window.location ="/topic/isoktoshow.php?pic="+did.value;
</script>
·½·¨¶þ£ºÓÃphpÊéдjavascript¡£
<?php
$val_overview_pic = "/pic/pic1.jpg";
echo "<script language='javascript' type='text/javascript'>";
echo " alert('".$val_overview_pic."');";
//echo " window.location ='/topic/isoktoshow.php?pic='".$val_overview_pic ."';";
echo "</script>";
?>
Ïà¹ØÎĵµ£º
¡¾¶ÔÏó¡¿-->·ÖÎöµÄ½á¹û-->¡¾ÔÐÍ¡¿-->¡¾Àà¡¿ ÒµÎñÊǶÔÏóÓë¶ÔÏóµÄ½»»¥ ʵÌå ·ÇʵÌå ¸üÇåÎúµÄ·ÖÎö¶ÔÏó¼äµÄ¹Øϵ ÐÐΪÓÃÀ´ÃèÊöÔÐÍ ÊôÐÔ¶ÔÓ¦ÌØÕ÷ ½Ó¿ÚÊǶÔÒ»ÀàÔÐÍ»ò¶àÀàÔÐÍijһ·½Ãæ·½·¨µÄ¹æ·¶ ʵÀý-¶ÔÏóµÄµÄ¾ßÌ壬ÀàµÄʵÀý»¯µÄ½á¹û ÃæÏò¶ÔÏóµÄ3¸ö²½Öè OOA--ÀíÇåÂß¼£¬ÕÒ³öÔÐÍ ¡¾¶ÔÏó¡¿-->¡¾ÔÐÍ¡¿ OOD--¸ù¾ÝÔÐÍ£¬½â ......
Ç°ÑÔ£º
¡¡¡¡FCKeidtorÊǸö¹úÍâµÄ¶àÓïÑÔ±à¼Æ÷£¬Äã¿ÉÒÔ¶ÔÆäÅäÖÃÎļþ½øÐмòµ¥ÐÞ¸Äʹ֧֮³ÖÄ¿Ç°³£ÓÃWeb¿ª·¢ÓïÑÔµÄÓ¦Óã¬ÏÂÃæÎҾͽ²½²FCKeditorµÄ×îа汾2.4.2ÔÚphpµÄ¾ßÌåÅäÖùý³Ì£¬Óв»×ãºÍ³ö´íµÄµØ·½£¬»¶ÓÖ¸Õý¡£
¾«¼ò£º
¡¡¡¡ÕýÒòΪÕâ¸ö±à¼Æ÷ÊÇÖ§³Ö¶àÓïÑԵģ¬ËùÒÔÊ×ÏÈÎÒÃÇÕë¶ÔʹÓöÔÆä×öÏàÓ¦µÄÈßÓàÎļþɾ³ý¡£
¡¡¡ ......
µÚ3ÕÂ ¶ÔÏó
JavaScriptµÄ¼òµ¥ÀàÐÍ°üÀ¨Êý×Ö¡¢×Ö·û´®¡¢²¼¶ûÖµ£¨trueºÍfalse£©¡¢nullÖµºÍundefinedÖµ¡£ÆäËûËùÓеÄÖµ¶¼ÊǶÔÏó¡£Êý×Ö¡¢×Ö·û´®ºÍ²¼¶ûÖµ“òËÆ”¶ÔÏó£¬ÒòΪËüÃÇÓµÓз½·¨£¬µ«ËüÃÇÊDz»¿É±äµÄ¡£JavaScriptÖеĶÔÏóÊǿɱäµÄ¼ü-Öµ¼¯ºÏ(keyed collections)¡£ÔÚJavaScriptÖУ¬Êý×éÊǶÔÏ󣬺¯ÊýÊǶÔÏó£¬Õý ......
ÔÚb/s¿ª·¢Öо³£Óõ½µÄjavaScript¼¼Êõ
Ò»¡¢ÑéÖ¤Àà
1¡¢Êý×ÖÑéÖ¤ÄÚ
1.1 ÕûÊý
1.2 ´óÓÚ0µÄÕûÊý £¨ÓÃÓÚ´«À´µÄIDµÄÑéÖ¤)
1.3 ¸ºÕûÊýµÄÑéÖ¤
1.4 ÕûÊý²»ÄÜ´óÓÚiMax
1.5 ÕûÊý²»ÄÜСÓÚiMin
2¡¢Ê±¼äÀà
2.1 ¶Ìʱ¼ä£¬ÐÎÈç (13:04:06)
2.2 ¶ÌÈÕÆÚ£¬ÐÎÈç (2003-12-05)
2.3 ³¤Ê±¼ä£¬ÐÎÈç (2003-12-05 13:04:06)
2. ......