nicolas 发表于 2008-10-17 12:18:36

define一些宏如何使用?

在model或者lib中没法用啊....
function test(){
                $this->load->library("DebugOut");
        }
提示:
A PHP Error was encountered
Severity: Notice

Message: Use of undefined constant ABC_CRITICAL - assumed 'ABC_CRITICAL'

Filename: libraries/Loader.php

Line Number: 873

protang 发表于 2008-10-17 14:33:09

宏定义直接使用, 不需要 ->这样的符号

例如DebugOut ,直接 拿来用echoDebugOut .'something' ;

Hex 发表于 2008-10-17 15:28:45

对,引用宏定义不需要引号。
页: [1]
查看完整版本: define一些宏如何使用?