How far down does an ini_set() go? I have a page that gets included on every page at the top and in it, it has some ini_set() commands. Do would those commands apply to each page below it so I would only need to call that command once? or, for instance, in order to display the errors on each page, do I need ini_set(display_errors) on every one that loads during that time?
And don't say, "Why don't you just put it in the php.ini file if they're all set the same?", cause they're not going to be set the same for each page load. It depends on a variable. Sorry, but too many times I go to ask questions on forums and people are like, "Why don't you just do it this way instead?" which is fine to suggest something, but then they don't answer my question.
ini_set redundancy
Moderator: General Moderators
Re: ini_set redundancy
Why don't you just... Just kidding.
Including files is much like copying the code from the secondary file and pasting it into the primary file. The program state is shared. If you change something in the primary file, the effect will carry over to the secondary file. Likewise, a change in the secondary file will affect the state of the primary file.
If you make a change to the configuration with ini_set(), that change will remain in effect until the end of the script or a subsequent change overrides it. The change is isolated to the current request and does not affect the default configuration.
Including files is much like copying the code from the secondary file and pasting it into the primary file. The program state is shared. If you change something in the primary file, the effect will carry over to the secondary file. Likewise, a change in the secondary file will affect the state of the primary file.
If you make a change to the configuration with ini_set(), that change will remain in effect until the end of the script or a subsequent change overrides it. The change is isolated to the current request and does not affect the default configuration.