PHPÌáÈ¡8684¹«½»Êý¾Ý
×î½üÒ»ÄêÀ´Ò»Ö±ÔÚʹÓÃfedora£¬·¢ÏÖlinuxÕæÊÇÌ«ÊʺÏÎÒÁË£¬Ï²»¶Ð´³ÌÐò£¬×Ô¼ºÏ¹µ¹ÌÚ£¬°¦windowsÎóÎÒ´óºÃÄ껪……
ÓÃPHPдÁËÒ»¶Î³ÌÐòÓÃÓÚÌáÈ¡ÍøÒ³ÖеÄÊý¾Ý£¬ÏàÐÅËÑË÷ÒýÇæÒ²ÊDz¶àµÄÏë·¨£¬Ö»²»¹ýËûÃÇÊý¾Ý¶à£¬Ëã·¨ºÃЩ£¬ºÇºÇ
[php]
<?php
/*
*´ËÎļþµÄÄ¿±êÊÇ×Ô¶¯ËѼ¯´æ´¢8684ÉϵÄÉîÛÚÊй«½»Êý¾Ý
*
*ÓÉÓÚhttp»ñµÃµÄÍøÒ³Îªgbk±àÂëPHPÐèҪת»»£¬Ö»Äܽ«PHPÖØÐ±àÒë
*/
//ÔØÈësimple_html_domÀà·ÖÎöHTMLÎļþ
include 'simple_html_dom.php';
//´´½¨Ò»¸öSQLiteÊý¾Ý¿âÓÃÓÚ´æ´¢Êý¾Ý
$db = new SQLite3 ('BusData.db');
if ($db) //Êý¾Ý¿â´´½¨³É¹¦
{
//´´½¨Õ¾µãÃû±í
$db->exec('CREATE TABLE stationName (id INTEGER PRIMARY KEY AUTOINCREMENT,sName STRING)');
//´´½¨Ïß·±ísName,sNote,sTo,sfrom·Ö±ð´æ´¢Ïß·Ãû£¬±¸×¢£¬È¥³Ì£¬»Ø³Ì
$db->exec('CREATE TABLE Line (sName STRING, sNote STRING, sTo STRING, sfrom STRING)');
}
analysis($db, 'http://shenzhen.8684.cn/x_24f5dad9');
$db->close ();
echo "Congratulations! Write Sucessfully!";
//******************
//·ÖÎöÊý¾Ý,²åÈëÊý¾Ý²¿·Ö
//******************
function analysis($db, $url)
{
$html = new simple_html_dom ();
$html->load_file ($url); //ÔØÈëHTMLÎļþ£¬¿ÉÒÔ´Ó±¾µØ£¬Ò²¿ÉÊÇURL
$LName = ''; //ÓÃÓڼǼ¹«½»Ïß·Ãû³Æ
foreach ($html->find ('div[id=show] h2 a') as $lineName)
{
// echo mb_strlen($lineName->plaintext).'word<p>';±¾À´ÏëÈ¥µô¹«½»Ãû³ÆÖеđ·'×Ö£¬²»¹ýºóÀ´·¢ÏÖÕû¸öÃüÃû²»±ê×¼£¬ÒªÈ¥¿ÉÄÜÈ¥µÄÂÒÆß°ËÔãÁË
//¼Ç¼¹«½»Â·ÏßÃû³Æ
$LName = $LName.mb_strcut(mb_convert_encoding($lineName->plaintext,'UTF-8','gbk'),6);
}
//¼Ç¼Ïß·±¸×¢ÐÅÏ¢:
$note = '|';
foreach ($html->find ('div[id=show] li') as $Note)
$note = $note.mb_convert_encoding($Note->plaintext,'UTF-8','gbk').'|'; //½«±¸×¢Á¬½Ó
$i = 0; //ÓÃÒÔÅжÏÐг̣¨È¥³Ì£¯»Ø³Ì£©
$s_To = '.'; //¼Ç¼ȥ³Ì·Ïß
$s_from = '.'; //¼Ç¼»Ø³Ì·Ïß
//Êä³ö¹«½»Õ¾µãÐÅÏ¢
foreach ($html->find ('span') as $element)
{
$i++; //¿ØÖƱäÁ¿×ÔÔö
//iÎªÆæÊýʱÅжÏΪȥ³Ì
if ($i % 2)
{
foreach ($element->find ('a
Ïà¹ØÎĵµ£º
Win2003server ϼÜÉèPHPWind²úÆ·»·¾³
°²×°Ç°×¼±¸:1¡¢°²×°ºÃiis6
&nbs ......
£¨×ª×Ôhttp://www.jb51.net/article/20829.htm£©
ÕâÀï½éÉÜÒ»¸öÖ±½Ó½«excelÎļþµ¼ÈëmysqlµÄÀý×Ó¡£ÎÒ»¨ÁËÒ»ÍíÉϵÄʱ¼ä²âÊÔ£¬ÎÞÂÛµ¼Èë¼ò·±Ìå¶¼²»»á³öÏÖÂÒÂ룬·Ç³£ºÃÓá£
PHP-ExcelReader,ÏÂÔØµØÖ·: http://sourceforge.net/projects/phpexcelreader
˵Ã÷£º
²âÊÔ»·¾³£ºMYSQLÊý¾Ý¿â²ÉÓÃutf8±àÂë.µ¼ÈëEXCELÎĵµÊÇxls¸ñʽ,¾¹ ......
<?php
/**
»ñÈ¡»úÆ÷Íø¿¨µÄÎïÀí£¨MAC£©µØÖ·
wwa $Exp
**/
class GetMacAddr
{
var $return_array = array(); // ·µ»Ø´øÓÐMACµØÖ·µÄ×Ö´®Êý×é
......
GD¿âÊÇPHP½øÐÐͼÏó²Ù×÷Ò»¸öºÜÇ¿´óµÄ¿â¡£
ÏÈÔÚphp.iniÀïÔö¼ÓÒ»ÐÐÒýÓãºextension=php_gd2.dll
ÖØÆôapache¡£×öÒ»¸ö²âÊÔÒ³ var_dump(gd_info());Êä³öÊý¾Ý±íÃ÷GD¿âÒýÓóɹ¦¡£
±íµ¥auth.html
<html>
<head>
<meta http-equiv='Content-Type' content='text/html; charset=utf-8'>
< ......
Perl MemcachedµÄ¿Í»§¶ËÐòÁл¯¶ÔÏó²ÉÓõÄÊÇStorableÄ£¿éµÄnfreeze·½·¨£¬¶øÕâ¸ö·½·¨ÓÖµ÷ÓÃÁËcÀ©Õ¹µÄdo_store·½·¨£»·´ÐòÁл¯Ê¹ÓõÄÊÇStorableÄ£¿éµÄthaw·½·¨£¬¶øÕâ¸ö·½·¨ÓÖÊǵ÷ÓõÄcÀ©Õ¹µÄdo_retrieve·½·¨¡£
¶øÔÚPHPÖУ¬½øÐеÄÈ´ÊÇserializeºÍunserialize²Ù×÷¡£Ôì³ÉÁËÎÞ·¨Õý³£¶ÁÈ¡µÄ½á¹û¡£
Perl´æ´¢Ò»¸ö('a', 'c')Êý×éµÄÒýÓ ......