scott001 Posted May 4, 2017 Report Posted May 4, 2017 Currently my server is running PHP 5.6.30 as the default, but PHP 7 is also installed. I am trying to force Rvive Adserver to run under PHP 7, and I've tried adding this code to a new .htaccess file in the root ad server's directory, in my case it is /adserv : <IfModule mime_module>AddType application/x-httpd-ea-php70 .php .php7 .phtml</IfModule> This configuration works fine for a forum which I have in a different directory on the same domain, but is not working for Revive Adserver--the ads stop running. Am I putting this file in the correct location, the root for Ad Server, or should it go somewhere else, for example /var ? It is possible that I don't have some required extension installed for PHP 7 that is needed for Revive, is there a list somewhere of those? Any help would be appreciated. Quote
scott001 Posted May 9, 2017 Author Report Posted May 9, 2017 Does anyone know why PHP 7.0 isn't working with Revive Adserver v4.0.1? Quote
andrewatfornax Posted May 25, 2017 Report Posted May 25, 2017 Hi @scott001, No, sorry - we do test Revive Adserver with PHP 7, and it should work. It would be worth checking with a simple file with phpinfo(); in it, served from the root Revive Adserver directory, that your setup is using the correct PHP version, and then you can check that all the requirements for Revive Adserver are met based on the information on that page. Quote
scott001 Posted June 12, 2017 Author Report Posted June 12, 2017 Unfortunately it does not work. The admin area doesn't seem to function...the admin login page does not load. Additionally, the statistics stop being collected, so the hourly cron job does not seem to work. The ads do show, but the app is not PHP 7 compatible. Quote
andrewatfornax Posted June 13, 2017 Report Posted June 13, 2017 Hi @scott001, Are there any errors in the webserver log files that you can share and/or report specific issues on GitHub about? As I said, one of the core team runs PHP 7, so it should work. Quote
scott001 Posted June 14, 2017 Author Report Posted June 14, 2017 I will try this again soon and post what I find. Since I am running PHP 7 on a per directory basis, I will try restarting the server when I switch it, because I did not do that last time. Quote
andrewatfornax Posted June 14, 2017 Report Posted June 14, 2017 Hi @scott001, Just a thought - are you using MySQL? When you switch to PHP7, do you change from the mysql driver to the mysqli driver in the Revive Adserver configuration? Quote
scott001 Posted June 15, 2017 Author Report Posted June 15, 2017 That did the trick, thank you. So I could not find a way to edit the DB settings withing the admin area, but did change it directly in the config file from "mysql" to "mysqli". l can now get into admin, and it looks like the stats are updating. Thank you! andrewatfornax 1 Quote
Megaboss Posted June 15, 2017 Report Posted June 15, 2017 Exactly what do I need to edit to make this work? Quote
scott001 Posted June 15, 2017 Author Report Posted June 15, 2017 I am running a cpanel apache mysql configuration. Under the latest cpanel you can run PHP per site, so you could set this in your control panel and run PHP 7 on your site. In my case, I wanted it to run within a directory, so I added this to the root .htaccess file for my Revivie Adserver site: <IfModule mime_module>AddType application/x-httpd-ea-php70 .php .php7 .phtml</IfModule> I then edited the main configuration file from: [database] type=mysql To: [database] type=mysqli Megaboss 1 Quote
Megaboss Posted June 15, 2017 Report Posted June 15, 2017 5 hours ago, scott001 said: I am running a cpanel apache mysql configuration. Under the latest cpanel you can run PHP per site, so you could set this in your control panel and run PHP 7 on your site. In my case, I wanted it to run within a directory, so I added this to the root .htaccess file for my Revivie Adserver site: <IfModule mime_module>AddType application/x-httpd-ea-php70 .php .php7 .phtml</IfModule> I then edited the main configuration file from: [database] type=mysql To: [database] type=mysqli Thank you, works perfect! //Niclas Quote
andrewatfornax Posted June 15, 2017 Report Posted June 15, 2017 Hi @scott001, Great, thanks for reporting back that it worked! As it seems like this is something that might catch people out, I've added this to our FAQ at https://documentation.revive-adserver.com/display/DOCS/Revive+Adserver+Broken. Thanks again! Quote
karl-pogi Posted November 13, 2017 Report Posted November 13, 2017 Hello everyone. I did all that checks according to @andrewatfornax, but seem to not solve anything. It was working well, then the UI suddenly broke after a certain time. Was just playing around with it and trying to post an add via iframe. Then after a refresh the UI seemed off. I'm using it on nginx. No adblocker, db is good, using on SSL. Like I said, everything was working well, until it didn't. It still works, it's just the UI. I did the maintenance checks as well, according to the system, it has no errors whatsoever. You are currently using Revive Adserver v4.1.1 running on nginx 1.13.5, PHP 7.1.9 and MySQL 5.5.5-10.1.28-MariaDB-1~xenial. Quote
andrewatfornax Posted November 17, 2017 Report Posted November 17, 2017 Hi @karl-pogi, Is the UI broken everywhere, or just in the parts where it's displaying the banner you added in the UI? Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.