开发者

What is the disadvantage of setting php.ini variables in the script?

What is the disadvantage of setting php.ini variables in the script ? (I set up in index.php - starting point of we site.)

My client saying I must add all ini variable changes in php.ini file not in the script .

Is there any security problem or runtime exceptions can happen if I set 开发者_运维问答these variables in the script ?


Some variables can not be set in the script, they only work in php.ini.

Putting the variables in php.ini is simpler - you don't have to do it for every single page. Remember index.php is just the front page to your site, I'm sure you'll have lots of other pages.

On the other hand putting them in the script can make it easier to distribute, since you don't need to do special configuration.

But, what variables do you need to set anyway? It's not that common to need to set a bunch of variables.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜