I'm trying to upgrade an old version (1.2.8) of zenphoto to the latest.
I made a duplicate of my website & database on the same server, and tested it was all working before proceeding to upgrade it. Deleted index.php, /themes and /zp-core and uploaded new ones as per the instructions.
On attempting to upgrade, I just get the following error: "You must be logged in to run setup". I WAS logged in to admin (on the duplicate site) before starting the upgrade! Going to admin, I just get the same error.
I've also tried going directly to the setup file, but it also gives me that error!
I've found almost nothing on these forums about this particular error, so I have no idea of what I'm supposed to do now. Its not the first time I've upgraded a zenphoto site, but it is the first time I've come across this issue.
I'm so glad I made a duplicate of the site to test this on first
Can someone advise me on how to proceed with the upgrade please? Thanks!
Comments
If you really can't login anymore, the easiest and quickest to solve the issue is probably to delete the complete `adminstrators` table in the MySQL database of the install. But in case you have other users these will be deleted, too. But then the install will be treated as a fresh install so you can setup a new admin user, too.
Because of this error I couldn't upgrade the duplicate site, so definitely wasn't going to try it on the real site!
That is what I don't understand - why I'm getting this error when I am logged in.
In any case, I deleted the administrators table, and I can now get to the setup page - but when I click the "go" button at the bottom of the screen, the next page is blank except for the heading "Zenphoto Upgrade". So I can't go any further.
What's wrong now?
There is this in the zenphoto error log:
Backtrace: EXCEPTION (8192): preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/xxxxxxxx/public_html/zenphotocopy/zp-core/lib-kses.php on line 87
preg_replace called
from kses_split (lib-kses.php [87])
from kses (lib-kses.php [53])
from sanitize_string (functions-basic.php [885])
from sanitize (functions-basic.php [819])
from setup.php [1530]
Could this have anything to do with it?
Also, the setup system's check gives the warning that the log files have the wrong permissions, saying they should be set to 0600. But they already are.
Does this help at all narrowing down what could be wrong? I've already spent over 8 hours on this, including setting up yet another copy of the site (in case there was something wrong with the previous one), but got the same problems with it. I just don't know what to do now...
Thanks for your help!
As mentioned you really should also look into the server PHP error log. That might contain more.
Also check the obvious: Are cookies allowed on the browser used? Did you try to clear them? Did you try to delete the administrator table to create a new master user as suggested (note you will loose all other user accounts if you have any as well)?
Yes, I've deleted the administrator table - this is what allows me to get to the next step of the upgrade, but no further.
Cookies are enabled on the browser, and I've tried deleting the cookies. I've also tried using a different broswer and computer. Nothing makes any difference.
Just helpless further questions: Are you sure the server matches all requirements? Is it an Apache server?
Otherwise I can only suggest to try to clear the administrators table again and mail me so I can take a quick look myself. Mail me via our contact form and I get back to you.