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

php mysqli ʹÓÃprepare

  1£¬°ó¶¨²ÎÊý
 
  $mysqli=new mysqli($host,$user,$pass,$db);  
   if(mysqli_connect_errno()){  
    echo 'Á¬½Ó³öÏÖÒì³£ÁË:'.mysqli_connect_error();  
    exit(0);  }  
      
   $sql = 'insert into user(name,pass,email) values(?,?,?)';  
   $stmt = $mysqli->prepare($sql);  
   $stmt->bind_param('sss',$name,$paassword,$email);  
   $name= '2';  
   $paassword=md5('12345');  
   $email = 'iamtsgx08@google.com';     
   $stmt->execute();  
     
   echo 'ÐÞ¸ÄÁË'.$stmt->affected_rows.'ÐÐ';  
     
   $stmt->close();  
   $mysqli->close();
2£¬°ó¶¨½á¹û¼¯
$sql = 'select name,pass,email from user';  
  if($stmt = $mysqli->prepare($sql)){  
    $stmt->execute();  
    $stmt->bind_result($name,$pass,$email); //°ó¶¨½á¹û  
    echo "<table>";  
    while($stmt->fetch()){  
        echo "<tr>";  
        echo "<td>".$name."</td>";  
        echo "<td>".$pass."</td>";  
        echo "<td>".$email."</td>";  
        echo "</tr>";  
    }  
    echo "</table>";  
    $stmt->close();  
  }  
   &nbs


Ïà¹ØÎĵµ£º

¼ò½éÁ½¿îPHP¿ª·¢µÄ¿ªÔ´µÄÔÚÏ߰칫Èí¼þ

    ÖîÈç Google Doc µÈWebÓ¦Óã¬ÔÊÐíͨ¹ý»¥ÁªÍø¹²ÏíÐÅÏ¢½øÐÐЭͬ¹¤×÷£¬¸øÎÒÃÇ´øÀ´ÁËȫеÄÈÕ³£°ì¹«ÌåÑé¡£Ëæ×Å´óÁ¿µÄ×ÀÃæÓ¦Óñ»ÒÆÖ²µ½ Web »·¾³£¬ÎÞÂÛÊÇ´¿´âµÄ HTML+CSS+JS »òÕß RIA ¶¼½«¸üÊÜ×·Åõ¡£
    ÒÔÏÂÊÇÁ½¿î¿ª·ÅÔ´´úÂëµÄ Web °ì¹«Èí¼þ£º
    1. OpenGoo
 &nbs ......

½áºÏʹÓÃPHPºÍRSS£¨×ª£©


ÄÚÈÝÕªÒª£ºRSS ¾ÛºÏ×î½ü·Ç³£Á÷ÐУ¬Òò´ËÖÁÉÙ¶Ô RSS ¼°Æ乤×÷·½Ê½ÓÐËùÁ˽âÊÇÒ»Ãû PHP ¿ª·¢ÈËÔ±µÄÆÈÇÐÐèÒª¡£±¾ÎĽéÉÜÁË RSS »ù´¡ÖªÊ¶¡¢RSS ÖÚ¶àÓÃ;ÖеÄһЩÓÃ;¡¢ÈçºÎʹÓà PHP ´ÓÊý¾Ý¿â´´½¨ RSS ÌáÒª£¬ÒÔ¼°ÈçºÎʹÓà XML_RSS Ä£¿é¶ÁÈ¡ÏÖÓÐ RSS ÌáÒª²¢½«Æäת»»Îª HTML¡£
¡¡¡¡Ê²Ã´£¿ÄúûÌý˵¹ý RSS£¿
¡¡¡¡RSS ¾ÛºÏÊÇ×î³£¼ûµÄ ......

ͨÓÃPHP¶¯Ì¬Éú³É¾²Ì¬HTMLÍøÒ³µÄ´úÂë

×î½üÑо¿PHPµÄһЩ¿ª·¢¼¼Êõ£¬·¢ÏÖPHPÓкܶàASPËùûÓеÄÓÅÐ㹦ÄÜ£¬¿ÉÒÔÍê³ÉһЩÒÔÇ°ÎÞ·¨Íê³ÉµÄ¹¦ÄÜ£¬ÀýÈ綯̬Éú³ÉHTML¾²Ì¬Ò³Ã棬ÒÔ¼õÉÙ·þÎñÆ÷CPUµÄ¸ºÔØ£¬Ìá¸ßÓû§·ÃÎʵÄËٶȡ£
¡¡¡¡ÎÒÃÇÖªµÀ£¬PHP¶ÁÈ¡MYSQL¶¯Ì¬ÏÔʾ£¬ÔÚ·ÃÎÊÁ¿´óµÄÇé¿öÏ£¬»áÓкܶàÐÔÄÜÎÊÌ⣬Èç¹û×âÓñðÈ˵ÄÐéÄâÖ÷»ú£¬Ôò»áÒòΪCPUÏûºÄ¹ý¶à¶ø±»ÏÞÖÆCPU£¬µ¼ÖÂÍø ......

php smarty±äÁ¿µÄÐÞÊÎ

test.php´úÂ룺 view plaincopy to clipboardprint?
assign("total",$total); //¶ÔÄ£°æÖеıäÁ¿¸³Öµ $formatted_total = number_format($total); //¸ñʽ»¯$total $smarty->assign("formatted_total",$formatted_total); //¶ÔÄ£°æÖеıäÁ¿¸³Öµ $smarty->display('test1.htm'); //ÏÔʾҳÃæ ?>
assign("total",$t ......

PHP×ÛºÏÍøµê

  ×ÛºÏÍøµêϵͳÊÇÓÉEÒ×ÍøÂç(68ws.cn)»ùÓÚphp+mysql¿ª·¢£¬¼æÈݸ÷ÀàÉÌÆ·µÄ·¢²¼¡¢Õ¹Ê¾ºÍ¶©¹º¡£³ýÁ˾ßÓÐÍêÉƵÄÉÌÆ·ÀàÐ͹ÜÀí¡¢ÉÌÆ·¹ÜÀí¡¢ÅäËÍÖ§¸¶¹ÜÀí¡¢¶©µ¥¹ÜÀí¡¢»áÔ±·Ö×é¡¢»áÔ±¹ÜÀí¡¢²éѯͳ¼ÆºÍ¶àÏîÉÌÆ·´ÙÏú¹¦ÄÜ£¬»¹¾ßÓÐÍêÕûµÄÎÄÕ¡¢Í¼ÎÄ¡¢ÏÂÔØ¡¢µ¥Ò³¡¢¹ã¸æ·¢²¼µÈÍøÕ¾ÄÚÈݹÜÀí¹¦ÄÜ¡£ÏµÍ³¾ßÓо²Ì¬HTMLÉú³É¡¢UTF-8¶àÓïÑÔÖ§³ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ