· div 固定高宽
2009-12-12 14:44:53 阅读235 评论0 122009/12 Dec12
Nemo,这是本模板引擎的名字,估计大家都想到了“Finding Nemo”中那只鱼。嘿嘿,是的。本模板引擎就像那只鱼那样,别看小巧,但是本事大哦。
本模板引擎为 PHPSo.Com 自主开发的模板引擎,具有如下的特点:语法方面,内置 for、radio、select、include、switch 等模板流程语法,方便的控制模板的显示流程。
习惯方面,模板的语法标记,可以书写成HTML标记及注释两种书写,适合不同的开发习惯。
速度方面,模板自动编译,以及优化过的模板缓存文件,模板调用速度超快。
2009-8-21 23:44:17 阅读267 评论2 212009/08 Aug21
引用
白云 的 php-验证码类
1、验证码类文件 CreateImg.class.php
<?php
/**
* @version 1.0
* @author Ben
* @date 2008-1-30
* @email jinmaodao116@163.com
* @验证码文件类
* int function imagecolorallocate(resource image, int red, int green, int blue) //为一幅图像分配颜色
* bool function imagefilledrectangle(resource image, int x1, int y1, int x2, int y2, int color) //画一矩形并填充
* bool function imagerectangle(resource image,
2009-8-21 23:27:02 阅读106 评论0 212009/08 Aug21
引用
白云 的 用来给图片加水印的PHP类
<?php
/*
* 功能:PHP图片水印 (水印支持图片或文字)
* 参数:
* $groundImage 背景图片,即需要加水印的图片,暂只支持GIF,JPG,PNG格式;
* $waterPos 水印位置,有10种状态,0为随机位置;
* 1为顶端居左,2为顶端居中,3为顶端居右;
* 4为中部居左,5为中部居中,6为中部居右;
* 7为底端居左,8为底端居中,9为底端居右;
* $waterImage 图片水印,即作为水印的图片,暂只支持GIF,JPG,PNG格式;
* $waterText 文字水印,即把文字作为为水印,支持ASCII码,不支持中文;
* $textFont 文字大小,值为1、2、3、4或5,默认为5;
2009-7-18 16:17:31 阅读332 评论0 182009/07 July18
<?php
/********************************************
FileName:statistic.class.php
Function:Statistic
Date: 2003-10-12 20:35
Author: Kelphen
CopyRight:Capinfo Co.,ltd.
Modify:
********************************************/
class DB_MYSQL {
var $Host = "";//数据库连接服务器
2009-7-18 16:22:14 阅读91 评论0 182009/07 July18
<?
/**
* 操纵文件类
*
* 例子:
* FileUtil::createDir('a/1/2/3'); 测试建立文件夹 建一个a/1/2/3文件夹
* FileUtil::createFile('b/1/2/3'); 测试建立文件 在b/1/2/文件夹下面建一个3文件
* FileUtil::createFile('b/1/2/3.exe');
2010-4-30 19:02:24 阅读2380 评论4 302010/04 Apr30
2010-4-7 21:24:12 阅读177 评论0 72010/04 Apr7
取得网络上的打印机
function getnetprinter()
{
var obj=new ActiveXObject("WScript.Network");
var netprinter=obj.EnumPrinterConnections();
for(i=0;i<netprinter.Count();i+=2)
{
document.writeln(netprinter.Item(i)+"="+netprinter.Item(i+1));
2010-4-5 0:04:21 阅读85 评论0 52010/04 Apr5
/**
* 获得指定栏目最新的文章列表。
*
* @access private
* @return array
*/
function index_get_class_articles($cat_aid, $cat_num)
{
$sql = "SELECT article_id, title,open_type,cat_id,file_url FROM " .$GLOBALS['ecs']->table('article'). " WHERE cat_id = ".$cat_aid." and is_open = 1 LIMIT " . $cat_num;
$res = $GLOBALS['db']->getAll($sql);
2010-4-3 20:54:23 阅读77 评论0 32010/04 Apr3