amnuts / opcache-gui

A clean, effective and responsive interface for Zend OPcache
1.21k stars 197 forks source link

One line prevents this working on php 5.4 #24

Closed delafuente closed 7 years ago

delafuente commented 7 years ago

Only one line prevents this could work on php < 5.5 versions:

if( empty( ini_get('opcache.enable') )

that can be changed by something like this and the code will work again:

$myvar = ini_get('opcache.enable');
if( empty ( $myvar ) )
amnuts commented 7 years ago

I guess the question is; should much older versions of PHP even be supported? Are you running on 5.4 or below? If so then I guess there's a use case, but 5.4 was EOL in 2015.

delafuente commented 7 years ago

On some of my Debian installations ( Wheezy 7 ), I still have to use external repositories to update farther than 5.4.45, I've updated some and some others don't, but the point here is that not so much effort ( one line of code ) could make this code available for < 5.5 users, so I think it could have more range of adoption.

Obviously, it's your choice, I had your code working under 5.4 and was behaving well ( but finally upgraded to 5.6 for other reasons ), so even if you don't support old versions, it could help somebody, or at least my comment can help someone with the same problem.

Thanks for your comment, and for the project.

amnuts commented 7 years ago

You do make good points, @delafuente; some people can't necessarily upgrade to the latest and greatest versions of PHP, whether it's because it relies on external resources, or maybe it's out of their control, and that it's such a small update to get it working with 5.4. So latest push fixes that.

I appreciate your input, thanks! :+1: