Skip to main content

php.ini file, Composer, and allow_url_fopen=0

Comments

6 comments

  • cPanelLauren
    My assumption here is that your provider has allow_url_fopen disabled in the global php.ini for ea-php72. This isn't something you'd be able to modify, you'd need to contact them to do this. The global php.ini takes precedence over the local one you're adding so if its disabled you'll not be able to override that setting.
    0
  • StephenW
    My assumption here is that your provider has allow_url_fopen disabled in the global php.ini for ea-php72. This isn't something you'd be able to modify, you'd need to contact them to do this. The global php.ini takes precedence over the local one you're adding so if its disabled you'll not be able to override that setting.

    Thank you Lauren for responding. I'll give your suggestion a try. Stephen
    0
  • carock
    In your answer, you say the global takes precedence. Wouldn't that mean nothing in a local user php.ini will work then? Only global setting works?
    0
  • cPanelLauren
    In your answer, you say the global takes precedence. Wouldn't that mean nothing in a local user php.ini will work then? Only global setting works?

    In some instances....yes but it depends on what the circumstance is. For example, if I set the php_memory_limit for PHP 7.3 globally to 850M then set it for the site in the local .ini file to 256M -> the local .ini file value will take precedence. Alternatively, if I set it to 900M locally the global will take precedence. With that being said, for this setting allow_url_fopen if I disable this globally for php 7.3 no account will be able to utilize it. If I enable it globally for php 7.3 I can disable it per account with a local ini file. The local ini file is respected but will not honor values outside of the constraints of the global. Thanks!
    0
  • carock
    ok, that makes sense. Thank you for clarifying. is there a list of php values that are only global where the local ini has no influence or is that just anything that is not shown in the user's cpanel multi-php ini settings. Thanks, Chuck
    0
  • cPanelLauren
    Hi @carock/ Not a list but if the global value is set to no/off or less than the local value - the global will be used.
    0

Please sign in to leave a comment.