1.require_once() 在脚本执行期间包含并运行指定文件。
require_once("include/common.php");
2.define() 定义常量。
define("ROOTPATH2","C:\\");
3.dirname() 返回路径中的目录部分
dirname("news/show.php"); // 输出“news”
4.trim() 去除字符串首尾处的空白字符。这个和ASP中的用法一样
trim($username);
5.header() 输出一个http头
header("location:login.php"); // 这个类似ASP中 Response.Redirect("login.asp")
标签:常用函数



