php·ÖÒ³TEST£¬×Ô¼ºÐ´Ò»ÏÂ
<?
include 'conn.php';
$_pagenob=10; //ÿҳ¹æ¶¨µÄÐÅÏ¢ÊýÄ¿
//»ñÈ¡µ±Ç°Ò³
if(isset($_GET["page"]))
{
$_page = intval( $_GET['page'] );
}
else
{
$_page=1;
}
//²éѯÊý¾Ý×ÜÊý
$_query="select count(*) as acount from news";
$_result=mysql_query($_query);
$_row=mysql_fetch_row($_result);
$_acout=$_row("acount");
if($_acount)
{
if($_acount<$_pagenob)
{
$_pagecount=1;//µ±×ÜÊýСÓڹ涨ÿҳÊýÁ¿Ê± ·ÖÒ³×ÜÊý$_pagecount=1
}
if($_acount%$pagenob) //µ±È¡Óàʱ µ±Ç°¼Ó1
{
$_pagecount=int($_acount%$_pagenob)+1;
}
else
{
$_pagecount=$acount/$_pagenob;
}
else
{
$_pagecount=0;
}
//ÏÂÃæÂÔ
}
?>
Ïà¹ØÎĵµ£º
1¡¢PHP·¢ËÍÖÐÎÄ¡¢Ajax½ÓÊÕ
Ö»ÐèÔÚphp¶¥²¿¼ÓÈëÒ»¾ä£º
header('Content-type: text/html;charset=GB2312');
xmlHttp»áÕýÈ·½âÎöÆäÖеÄÖÐÎÄ¡£
2¡¢Ajax·¢ËÍÖÐÎÄ¡¢PHP½ÓÊÕ
Õâ¸ö±È½Ï¸´ÔÓ£º
AjaxÖÐÏÈÓÃencodeURIComponent¶ÔÒªÌá½»µÄÖÐÎĽøÐбàÂë
PHPÖУº
$GB2312string=iconv( ‘UTF-8′, ‘gb2312//I ......
±¾½Ì³Ì²ÉÓõÄÊÇxampp×Ô´øµÄtomcat²å¼þÀ´Íê³ÉÕûºÏµÄ£¬ËùÒÔ£¬ÒªÏëÍê³ÉÕûºÏ£¬µÚÒ»²½²»ÐèÏÂÔØxampp£¬¼°Æätomcat²å¼þ~
1.´ò¿ªxampp¹ÙÍø µã´Ëxampp¹ÙÍø´ò¿ª
&n ......
ÕªÒª ±¾ÎĽéÉÜPHPµÄÓŵãºÍÌØÕ÷£¬½áºÏʵÀý²ûÊöÁËPHP·ÃÎÊMySQLÊý¾Ý¿âµÄ·½·¨¡£
PHP MySQL ODBC
1. ÒýÑÔ
ÔÚInternetÓ¦ÓÃÖУ¬½«·þÎñÆ÷¶Ë½Å±¾¼¼ÊõºÍ¿Í»§¶Ë½Å±¾¼¼Êõ½áºÏÆðÀ´¿ÉÒÔÖÆ×÷³ö·á¸»¶à²ÊµÄÒ³Ãæ¡£CGIºÍASPÊDZȽÏÁ÷ÐеķþÎñÆ÷¶Ë½Å±¾¼¼Êõ¡£Í¨³£CGIÔÚ¿çÆ½Ì¨µÄ¿ª·¢ÖаçÑÝ×ÅÖ÷Òª½ÇÉ«£¬¿ÉÒÔʹÓÃVB¡¢C»òPerlµÈÀ´Ê ......
PHP Security for Deployers
If you're a Developer
READ THIS and then work with your SysAdmins to step through any and all the layers of security designed to protect your apps.
Example:
Traffic must first pass through a SPI firewall (ensure that ONLY necessary ports/protocols are permitted; en ......
1¡¢Êý×éµÄÉêÇëºÍʹÓãº
$array=array(array(2,324,34));
echo $array[0][1];
Ö±½ÓÉêÇëʹÓãº
$student[0][0]="ÎÒ";
$student[0][1]="ÊÇ";
$student[1][0]="Ë";
$student[1][1]="ά";
echo $student[1][0];
2¡¢±éÀú£º ......