为什么在共享主机上关闭php的ini_set函数 [英] why is php's ini_set function switched off on shared hosts

查看:90
本文介绍了为什么在共享主机上关闭php的ini_set函数的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在VPS上使用托管,但他们不允许我使用php的ini_set函数在运行时逐个脚本地设置配置.相反,我必须直接在php.ini文件中更改设置,这是通过SSH访问的任务.

I am using hosting on VPS and they've not allowed me to use php's ini_set function to set configuration at runtime, on a script by script basis. Instead I must change the settings directly in the php.ini file which is a mission to access via SSH.

这是为什么?

这虽然很好,但由于我在共享服务器上有12个域,所以有点烦人,我不必全盘设置设置....

This, although fine, is slightly annoying as I have 12 domains on the shared server and I do not neccessarily want to set the settings across the board....

推荐答案

如果它是针对转销商的产品,则可能是为了防止您的客户/客户/用户在以下位置更改php.ini设置意志,这通常是明智的选择.

If it's a product aimed at resellers, it is probably to prevent your clients / customers / users from changing php.ini settings at will, which is usually a wise thing to do.

但是,如果您拥有对计算机的完全访问权限,是否可以重新激活ini_set?

But if you have full access to the machine, shouldn't you be able to re-activate ini_set?

这篇关于为什么在共享主机上关闭php的ini_set函数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆