running perl in shell and in Apache, the 环境变量 is different!
Under shell, perl gets shell enviroment variables.
In Apache, perl as CGI gets Apache environment variables. Pls refer to Apache document => SetEnv.
If you want to set $HONE as an Apache ENV, you should configurate apache.
Apache config. Syntax:
SetEnv <ENV_NAME> = <ENV_VALUE>
actually your question is belong to apache, not perl!作者: maorui 时间: 2010-09-16 09:54
got it & thx!作者: flw 时间: 2010-09-16 11:24
perl -e 的时候最外层还是用单引号吧。