php 5.4 or 5.5

Web hosting discussion, programming, and shared and dedicated servers.
12 posts Page 1 of 2
by scw1 » Tue Jul 02, 2013 8:05 am
Hi,

I can see that Sonic hosting has some hooks to for using php 5.3. Does anybody have any insight if there is a plan to get php 5.4 or 5.5 installed as well? I'm running a site using drupal and starting to have modules that require 5.4.

-Scott
by joemuller » Fri Jul 19, 2013 12:32 pm
Scott,

I can confirm that we are looking into installing at least PHP 5.4 in the near future, as according to this announcement, the 5.3 series has reached end-of-life status. When 5.4 is ready, expect to see an announcement here on the Hosting forum.

-- Joe @ System Operations
I'm a proud employee of Sonic.net! :-)
by morenoh149 » Tue Dec 24, 2013 2:03 pm
I'm not seeing php 5.5. When I do 'php --version' I get
PHP 4.4.7 (cli) (built: May 9 2007 13:54:29)
Copyright (c) 1997-2007 The PHP Group
Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies
_[Sonic:/home/m/morenoh149]_
How do I get a recent version of php? I'm using ssh on bolt.sonic.net.
by joemuller » Tue Dec 24, 2013 2:29 pm
The most recent version installed on bolt.sonic.net is PHP 5.3 - it can be found in /opt/php53/bin/php. The same version exists on our web cluster, so any code that runs on one server should work on the other.
I'm a proud employee of Sonic.net! :-)
by morenoh149 » Wed Dec 25, 2013 1:54 am
joe, could you explain how to add that dir to my path? the shell available seems nonstandard. I'm not having success exporting the path in a .bashrc or .bash_profile file in my home directory. Like the instructions I'm finding online. How can I use php53?
by thulsa_doom » Thu Dec 26, 2013 9:28 am
You might want to take a look at https://wiki.sonic.net/wiki/Php5

Basically you put up a .htaccess file containing

Code: Select all

Action php-cgi /cgi-bin/php53
AddHandler php-cgi .php
John Fitzgerald
Sonic Technical Support
by Guest » Thu Jan 16, 2014 12:06 pm
I have added .htaccess according to the instructions but when I run php -v. php -i or run the script 'php info.php' I get a response 'PHP Version 4.4.7'. According to Sonic.net support they are seeing version 5.3.15 when they access the info.php script from a browser. Should the response from php -v and a browser accessing info.php return the same value for the PHP version.
by joemuller » Tue Jan 28, 2014 11:56 am
thulsa_doom's instructions will set the proper version for web pages using PHP, but it sounds like you want to run PHP in a standalone fashion on the command line too. One way is simply substituting '/opt/php53/bin/php' for the 'php' command, but if you'd like to default to using the newer php version, here's how to do it for bash:

Add the directory that has php53:

Code: Select all

export PATH=/opt/php53/bin/:$PATH
Then have bash apply your new path:

Code: Select all

source .bashrc
Hope this helps!

-- Joe
I'm a proud employee of Sonic.net! :-)
by Guest » Mon Feb 03, 2014 8:00 pm
Ok, guys, it's been a few years. There are some significant improvements with 5.4 and we're starting to see WP sites that are performing poorly with < 5.4.

Thanks.
by williamt » Wed Feb 12, 2014 11:26 am
I have just installed php 5.5 on our web servers.
For usage instructions see: https://wiki.sonic.net/wiki/Php5

Let me know if you need anything else!
Sr. Systems Administrator @ sonic.net
12 posts Page 1 of 2