php里include,include_once和requie,require_once的区别

854阅读 0评论2009-02-04 zhangsanji
分类:

这里是php。
1:带和不带once的区别:with the only difference being that if the code from a file has already been included, it will not be included again;*_once() should be used in cases where the same file might be included and evaluated more than once during a particular execution of a script, and you want to be sure that it is included exactly once to avoid problems with function redefinitions, variable value reassignments, etc.
2:require和include的区别:different in how they handle failure;require results in a Fatal Error;include results in only a warning and continue;
上一篇:firefox扩展实践
下一篇:perl里use和require的区别