/*** WNiaoBlog Tag Template ShowTag** @package WNiaoBlog** @subpackage Tag*///Connect the database//include('../include/config.php');/*** CountTag() - Statistics labels appear the number,and the data to be stored in the two array** GetTag() - Access
function template($tpl = 'index',$dir = 'hello'){if(!file_exists($pd = TPL_PATH.$dir.'/'))@mkdir($pd,0777) or die("$pd目錄建立失敗");//如cache/tpl/hello/if(!file_exists($td = TPL.$dir.'/'))@mkdir($td,0777) or die("$td目錄建立失敗");//如data/tpl/hello/$t2p =
$foo = 'Bob'; // 將 'Bob' 賦給 $foo$bar = &$foo; // 通過 $bar 引用 $fooecho $foo.'';$bar = "My name is $bar"; // 修改 $bar 變數echo $bar.'';echo $foo.''; // $foo 的值也被修改?>複製代碼輸出:BobMy name is BobMy name is
/***************@length - length of random string (must be a multiple of 2)**************/function readable_random_string($length = 6){$conso=array("b","c","d","f","g","h","j","k","l","m","n","p","r","s","t","v","w","x","y","z");$vocal=array("a","e",
// Original PHP code by Chirp Internet: www.chirp.com.au// Please acknowledge use of this code by including this header.function myTruncate($string, $limit, $break=".", $pad="...") {// return with no change if string is shorter than $limitif(strlen($
$conn = new Com("ADODB.Connection"); //執行個體化一個Connection對象$connstr = "provider=sqloledb;datasource=.;uid=sa;pwd=123456;database=jnold;";$conn->Open($connstr);$rs = new Com("ADODB.Recordset"); //執行個體化一個Recordcount對象$rs->Open('select * from