Thread Starter
Matoca
(@matoca)
Can anyone tell me how Zencache evaluates the PHP version on the server? Bluehost Support is telling me that it is NOT running 5.2, but Zencache will not run and the error in my dashboard says that it I AM running 5.2. Both cannot be correct.
Go to your Cpanel and check the default version of php.
Thread Starter
Matoca
(@matoca)
Thank you for your suggestions.
Both the cpanel and the php config did show PHP 5.4. However, it appears something altered the .htaccess file in my main directory.
The support tech told me that plugins obtain information about the PHP ver from that file. Unless that was fixed ZenCache would never see the correct version set in the account. Once the file was fixed, ZenCache was working fine.
Both the cpanel and the php config did show PHP 5.4. However, it appears something altered the .htaccess file in my main directory.
The support tech told me that plugins obtain information about the PHP ver from that file. Unless that was fixed ZenCache would never see the correct version set in the account. Once the file was fixed, ZenCache was working fine.
@matoca What the support tech told you is not true. ZenCache (and any other WordPress plugin) gets information about the PHP version from PHP itself (using the PHP_VERSION constant), not from the .htaccess file.
In fact, it’s the web server that uses the .htaccess file. Web hosts will often tell you to put specific code inside your .htaccess file to specify which version of PHP the web server should use.
It sounds like the web hosting company’s software did not properly update the .htaccess file when you selected the PHP version in your Control Panel, which meant that your server wasn’t actually running the PHP version that you selected (and hence ZenCache was reading the PHP version and discovering that the version of PHP actually being used on the server was less than v5.3.2).
It sounds like you have everything working now, but I just wanted to clarify what was likely going on. 🙂
Thread Starter
Matoca
(@matoca)
@raamdev Ha, this is even more complex than I thought! I always get the feeling that Bluehost support techs are variable in their training and experience.
So previous techs, when trying to get my WP site back up about 2 weeks ago, came up with a variety of reasons why it was down. But it was hours on chat over several days before one of them was able to actually get it back up. He simply disabled all plugins. What happened is more complex than I am describing and far more frustrating.
So I suspect that BH had somehow set my php to 5.2 at some point prior to this, disturbing some plugins and taking my site down.
I knew, from previous experience with another plugin, that I had to be on PHP 5.4. I had set my server for that at least a year or so ago when it first became available. So when I re-activated ZenCache and it responded it could not run on PHP 5.2, I went right into my server to see what it was set to, and as I have said, it indicated 5.4. I don’t know how the .htaccess file became corrupted.
Thank you for the excellent explanation. This adds to my knowledge so that I can troubleshoot and resolve problems on my own.
Matoca
@matoca Yikes, talk about a nightmare! I’m happy that I was able to help explain things a bit for you. I learned this stuff the hard way, much the same way you appear to be learning it actually, ha! 🙂
Make sure there are no extra spaces in the beginning or ending of the .htaccess file