Koozali.org: home of the SME Server

PHP Fopen not working

Offline davidS

  • ****
  • 80
  • +0/-0
PHP Fopen not working
« on: March 11, 2016, 04:03:45 PM »
hello
i have sme server 9.1, i am using it to host my web site.
in the default php version 5.3.3 all the configuration are working good,
i have url fopen = on per ibay but when i am changing it to php55/54/56 with php-pcl software collection the parameters are changing to the php55 default and not to my earlier configs.

when using phpinfo() on default sme server 9.1 php version
Quote
PHP Version    5.3.3
allow_url_fopen   On   

and when using phpinfo() on php55 php-pcl
Quote
PHP Version    5.5.33
allow_url_fopen   Off
how do i enable fopen per ibay on php55 ?
thank you

Offline stephdl

  • *
  • 1,523
  • +0/-0
    • Linux et Geekeries
Re: PHP Fopen not working
« Reply #1 on: March 11, 2016, 04:43:17 PM »
You can find what you are looking for in the documentation https://wiki.contribs.org/PHP_Software_Collections#Usage

config setprop php56 AllowUrlFopen On
signal-event php-update
« Last Edit: March 11, 2016, 04:48:35 PM by stephdl »
See http://wiki.contribs.org/Koozali_Foundation
irc : Freenode #sme_server #sme-fr

!!! Please write your knowledge to the Wiki !!!

Offline davidS

  • ****
  • 80
  • +0/-0
Re: PHP Fopen not working
« Reply #2 on: March 11, 2016, 05:49:53 PM »
You can find what you are looking for in the documentation https://wiki.contribs.org/PHP_Software_Collections#Usage

config setprop php56 AllowUrlFopen On
signal-event php-update

Yes . but is there a way to do it per ibay  and not to all php55.
Like i used to do per ibay name
« Last Edit: March 11, 2016, 05:53:04 PM by davidS »

Offline stephdl

  • *
  • 1,523
  • +0/-0
    • Linux et Geekeries
Re: PHP Fopen not working
« Reply #3 on: March 11, 2016, 09:06:55 PM »
Just to be clear, do you use php56 only for the Ibay or for the whole server ?

If you use php56 (or php54,php55) for the whole server, then you can use the AllowUrlfOpen per ibay with 'php_admin_flag allow_url_fopen on', because apache is the handler of php. You can add also specific values (MemoryLimit,UpMaxFileSize,PostMaxSize,MaxExecTime) per Ibay

If you use php56,php55,php54 per ibay, then you use php with a cgi application and you cannot add specific setting to apache with php_admin_flag or php_admin_value. Then if you want to add the setting AllowUrlfOpen you must use it for the whole php application by the command I gave.

It is the limitation I have with php-scl

In short

PHP SCL for the whole server -> all settings can be set per Ibay normally with db or with smeserver-webhosting
PHP SCL per Ibay -> all settings must be set in each php{54,55,56} properties https://wiki.contribs.org/PHP_Software_Collections#Usage
See http://wiki.contribs.org/Koozali_Foundation
irc : Freenode #sme_server #sme-fr

!!! Please write your knowledge to the Wiki !!!

Offline davidS

  • ****
  • 80
  • +0/-0
Re: PHP Fopen not working
« Reply #4 on: March 11, 2016, 09:15:46 PM »
Just to be clear, do you use php56 only for the Ibay or for the whole server ?

If you use php56 (or php54,php55) for the whole server, then you can use the AllowUrlfOpen per ibay with 'php_admin_flag allow_url_fopen on', because apache is the handler of php. You can add also specific values (MemoryLimit,UpMaxFileSize,PostMaxSize,MaxExecTime) per Ibay

If you use php56,php55,php54 per ibay, then you use php with a cgi application and you cannot add specific setting to apache with php_admin_flag or php_admin_value. Then if you want to add the setting AllowUrlfOpen you must use it for the whole php application by the command I gave.

It is the limitation I have with php-scl

In short

PHP SCL for the whole server -> all settings can be set per Ibay normally with db or with smeserver-webhosting
PHP SCL per Ibay -> all settings must be set in each php{54,55,56} properties https://wiki.contribs.org/PHP_Software_Collections#Usage

ok thank you very much
now i get it .
ok so i did it for the whole php55
again thank you

Offline stephdl

  • *
  • 1,523
  • +0/-0
    • Linux et Geekeries
Re: PHP Fopen not working
« Reply #5 on: March 11, 2016, 09:45:40 PM »
no problem it wasn't written in the documentation, now it is.
See http://wiki.contribs.org/Koozali_Foundation
irc : Freenode #sme_server #sme-fr

!!! Please write your knowledge to the Wiki !!!