I have php5 and php7 applications.
The php5 application are not compatible with php7.
How can I run both runtime on the same apache server ?
I have php5 and php7 applications.
The php5 application are not compatible with php7.
How can I run both runtime on the same apache server ?
Essentially you need to use fastcgi.
You should look here for doing so:http://linuxplayer.org/2011/05/intall-multiple-version-of-php-on-one-server
You should be able to but you'll need access to the server, so shared web hosting is probably off limits. Have a look at this answer from another SO post. I believe that should apply here.
One way to do this is to have your main version of php set up with mod_php and run all of the others through fast cgi on different ports (i.e. 81, 82, 83 etc). This won't guarantee totally consistent behavior though.
So one version is done through CGI and the other is done as an apache module.
Alternatively you could look into upgrading your php5 code to be compatible for php7 as it'll make it more stable and secure. Albeit time consuming though.