Welcome Guest. Please Login or Register  


You are here: Index > Softaculous Auto Installer > Suggestions > Topic : Auto-detect *actual* version of PHP on customer's account (and install folder)



Threaded Mode | Print  

 Auto-detect *actual* version of PHP on customer's account (and install folder) (11 Replies, Read 33499 times)
electric
Group: Member
Post Group: Newbie
Posts: 6
Status:
Hello, We are using CloudLinux PHP Selector to allow our customers to choose what version of PHP they want for their account.    The problem is that Softaculous does not recognize what version of PHP customer has selected, so if (for example) customer tries to install Joomla 3.x.. then Softaculous failes with a "PHP version must be PHP 5.3 or higher" message. But... the customer IS using PHP 5.3 (or PHP 5.4 or PHP 5.5 if selected). I know this can be "fixed" by hard-coding a PHP version into Softaculous, but that is not a good solution because... well, it involves hard-coding a fake PHP version into softaculous.  ("Fake", in that the customer could have any other version installed, regardless of what is hardcoded into the softaculous hook file.)  Perhaps a better solution might be if Softaculous did a simple function call to the phpinfo() command on a test file in the customer's account, to see what is the actual version of PHP running on their account.  For example: - Create test file called "/home/username/public_html/path/to/test_file_phpinfo.php" (with only phpinfo() function.  (Note, this file should be located in whatever folder user selected to install the app in, since it's possible to have multiple versions of PHP in an account, even different versions in different folders. - Call "get_file_contents("/home/username/public_html/test_file_phpinfo.php"). - Parse out the actual PHP version that is running in that folder.
This problem with softaculous is just going to get more frequent as more and more people start using CloudLinux (or other method) of switching PHP for either an entire account or individual folders.  Manual "fixing" of softaculous with a hardcoded version in the hook file is not good... Thanks.
IP: --   

Auto-detect *actual* version of PHP on customer's account (and install folder)
Brijesh
Group: Softaculous Team
Post Group: Super Member
Posts: 5652
Status:
Hi,

Sorry for the delay. We are in talks with the CloudLinux team on how to detect the appropriate PHP version and we will modify the version check accordingly.

-----------------------
Webuzo - Multi User Hosting Control Panel
AMPPS - Best WordPress/PHP/MySQL development tool
IP: --   

Auto-detect *actual* version of PHP on customer's account (and install folder)
electric
Group: Member
Post Group: Newbie
Posts: 6
Status:
Quote From : Brijesh February 1, 2013, 5:27 am
Hi,

Sorry for the delay. We are in talks with the CloudLinux team on how to detect the appropriate PHP version and we will modify the version check accordingly.
Is there any progress on this?  Our customers are finding this problem more and more, and it's very annoying.  Their account *is* using PHP 5.3, but yet they are unable to use Softaculous to install some software. Thanks.
IP: --   

Auto-detect *actual* version of PHP on customer's account (and install folder)
electric
Group: Member
Post Group: Newbie
Posts: 6
Status:
Just to clarify, I am using Softaculous latest version (v4.2.0) and this problem is still occurring.

Please let me know if this is planned to be fixed.
IP: --   

Auto-detect *actual* version of PHP on customer's account (and install folder)
Brijesh
Group: Softaculous Team
Post Group: Super Member
Posts: 5652
Status:
Hi,

Sorry for the delay. The fix should be available by today.

-----------------------
Webuzo - Multi User Hosting Control Panel
AMPPS - Best WordPress/PHP/MySQL development tool
IP: --   

Auto-detect *actual* version of PHP on customer's account (and install folder)
Brijesh
Group: Softaculous Team
Post Group: Super Member
Posts: 5652
Status:
Hi,

The hook for CageFS is available here :
http://softaculous.com/docs/Detect_PHP_Version_on_CageFS

This hook will detect correct PHP version for user on CageFS and enable the required version as well.

-----------------------
Webuzo - Multi User Hosting Control Panel
AMPPS - Best WordPress/PHP/MySQL development tool
IP: --   

Auto-detect *actual* version of PHP on customer's account (and install folder)
electric
Group: Member
Post Group: Newbie
Posts: 6
Status:
Thanks a lot!

Can you tell me exactly what the last part of the hook file does? 

Will it actually change their PHP version if the software being installed needs a different version?

IP: --   

Auto-detect *actual* version of PHP on customer's account (and install folder)
electric
Group: Member
Post Group: Newbie
Posts: 6
Status:
Oh.. I am an idiot.  I just read the documentation page a little more closely.

The script will ask if you wants to change their PHP version.

Great! 

Thanks again.  :)
IP: --   

Auto-detect *actual* version of PHP on customer's account (and install folder)
VincentLeclerc
Group: Member
Post Group: Newbie
Posts: 2
Status:
Our customers are looking for more and more problems, and it is very annoying. Their account * is * PHP5.3, but they can not use Softaculous to install some software.
IP: --   

Auto-detect *actual* version of PHP on customer's account (and install folder)
Brijesh
Group: Softaculous Team
Post Group: Super Member
Posts: 5652
Status:
Hi,

Sir can you please confirm if the pre-install hook for cagefs was added to Softaculous :
http://softaculous.com/docs/Detect_PHP_Version_on_CageFS

If you still face the issue please open a support ticket with us we will check it :
https://www.softaculous.com/support/

-----------------------
Webuzo - Multi User Hosting Control Panel
AMPPS - Best WordPress/PHP/MySQL development tool
IP: --   

Auto-detect *actual* version of PHP on customer's account (and install folder)
elecor
Group: Member
Post Group: Newbie
Posts: 1
Status:
Which versions of softaculous are not affected by this?

I mean what's the first version without this issue.


-----------------------
Free hosting
IP: --   

Auto-detect *actual* version of PHP on customer's account (and install folder)
Brijesh
Group: Softaculous Team
Post Group: Super Member
Posts: 5652
Status:
Hi,

The issue is when you have installed CageFS on your server as it allows users to change their PHP version.

A simple solution to the issue would be simply unzipping the below hook :
http://softaculous.com/docs/Detect_PHP_Version_on_CageFS

-----------------------
Webuzo - Multi User Hosting Control Panel
AMPPS - Best WordPress/PHP/MySQL development tool
IP: --   

« Previous    Next »

Threaded Mode | Print  



Jump To :


Users viewing this topic
1 guests, 0 users.


All times are GMT. The time now is April 24, 2024, 3:27 am.

  Powered By AEF 1.0.8 © 2007-2008 Electron Inc.Queries: 11  |  Page Created In:0.050