Zen Cart Logo
Forums / Upgrading to 1.5.x / the dreaded white screen

the dreaded white screen

Views: 1,870

Results 1 to 20 of 22
12 Dec 2014, 1:20 AM
#1
jenpen avatar

jenpen

Zen Follower

Join Date:
Sep 2007
Location:
Far South Coast, NSW, Australia
Posts:
427
Plugin Contributions:
0

the dreaded white screen

Just now upgrading from 139h to 153.

Playing it safe, I took a back-up of the site files and uploaded them into a /store subfolder. Checked the store and admin, all fine.
Then I uploaded all the new v153 files into that folder, and corrected the configure files for the /store/ path.

White screens for store and admin.

I suspect I need to upgrade the database but I've forgotten how to do that.

Any pointers? Other ideas?

12 Dec 2014, 2:35 AM
#3
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: the dreaded white screen

jenpen:

White screens for store and admin.
What's it recording as the cause of the blank screens? http://www.zen-cart.com/content.php?124-blank-page

12 Dec 2014, 3:50 AM
#4
jenpen avatar

jenpen

Zen Follower

Join Date:
Sep 2007
Location:
Far South Coast, NSW, Australia
Posts:
427
Plugin Contributions:
0

Re: the dreaded white screen

Thanks, I'll try it.

12 Dec 2014, 4:48 AM
#5
jenpen avatar

jenpen

Zen Follower

Join Date:
Sep 2007
Location:
Far South Coast, NSW, Australia
Posts:
427
Plugin Contributions:
0

Re: the dreaded white screen

Hmm, I've hit a dead-end.

I got a long way forward, it was all looking good. I ran zc_install, it all went ahead. But it created a new, empty database. I thought, that's fine, so I imported my DB back-up SQL file into it - SQL error. Also fine, I deleted that DB, created a new one with the same name, user, password, imported the DB back-up into that. All went well.

BUT... then the DB needed upgrading, so I went back and ran zc_install again. OK, but when I clicked on Database Upgrade, it wouldn't accept my admin password. I tried the new temporary one, then the one I had changed it to. It's not accepting either. And if I try to open the admin log-in to get a new admin password sent to me, it just says "database upgrade required. please run the 1.3.9-to-1.5.0 upgrade via zc_install" - which is what I'm trying to do... :(

Is there some other way of getting/resetting the admin password?

12 Dec 2014, 5:07 AM
#6
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: the dreaded white screen

Sigh.
Lemme guess ... you're running an old version of PHP, right?

12 Dec 2014, 5:18 AM
#7
jenpen avatar

jenpen

Zen Follower

Join Date:
Sep 2007
Location:
Far South Coast, NSW, Australia
Posts:
427
Plugin Contributions:
0

Re: the dreaded white screen

PHP Version: 5.3.29 (Zend: 2.3.0)

13 Dec 2014, 5:10 AM
#8
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: the dreaded white screen

Use phpMyadmin and go to the admin table in your database, and look at the entry for your admin user. What are the first 10 characters of the encrypted password it's got there? (It's safe to post those, as nobody can use that information for anything ... I'm just looking for a pattern to know what it's done to your data.)

13 Dec 2014, 5:44 AM
#9
jenpen avatar

jenpen

Zen Follower

Join Date:
Sep 2007
Location:
Far South Coast, NSW, Australia
Posts:
427
Plugin Contributions:
0

Re: the dreaded white screen

Thanks... a2efab6917

13 Dec 2014, 8:16 AM
#10
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: the dreaded white screen

The password info you posted indicates that it hasn't upgraded the password methods yet, which means your data hasn't been altered. That's good. It also means your original admin password probably still will work (if you haven't asked it to email a new one ... and don't do that except as a last resort).

You haven't yet posted whether there are any new errors in myDebug-xxxxx.log files in the /logs/ folder. In the absence of that information it's hard to tell what exactly your server is having trouble with. But since it seems to take hours to dialog back and forth here, maybe making this small change might help?
Edit /includes/classes/class.zcPassword.php
Around line 49 you have this:if (version_compare($phpVersion, '5.3.7', '<')) { require_once (DIR_FS_CATALOG . DIR_WS_FUNCTIONS . 'password_compat.php'); } elseif (version_compare($phpVersion, '5.5.0', '<')) { require_once (DIR_FS_CATALOG . DIR_WS_CLASSES . 'vendors/password_compat-master/lib/password.php'); }Try changing it to this:```
if (version_compare($phpVersion, '5.3.7', '<')) {
require_once (realpath(dirname(FILE)) . '/../functions/password_compat.php');
} elseif (version_compare($phpVersion, '5.5.0', '<')) {
require_once (realpath(dirname(FILE)) . '/vendors/password_compat-master/lib/password.php');
}

1 Jan 2015, 5:31 PM
#11
welchyboy avatar

welchyboy

Zen Follower

Join Date:
Apr 2008
Posts:
274
Plugin Contributions:
0

Re: the dreaded white screen

I am getting a partial blank page on my admin page. I am trying to upgrade from 1.38 to 1.5. I have tried many things as I cloned my database and site for testing. I have upgraded to 1.50 and the main site works well so far but I get a partial blank admin page. It was originally all blank until I read a post about one of the errors I had in my logs. The error I receive is
[01-Jan-2015 10:10:30] PHP Fatal error: Cannot redeclare check_page() (previously declared in /home/stxmill/public_html/TESTSITE/admin/includes/functions/admin_access.php:15) in /home/stxmill/public_html/TESTSITE/admin/includes/functions/admin_profiles.php on line 121

I have removed the check_page function from both documents which helped a little. It went from completely blank to partial blank page. The top part of the admin page shows but nothing else.

I also read a post about changing the define charset to utf-8 which I also made the changes but it didn't seem to do much.

PHP Version 5.2.17
Database: MySQL 5.5.40-36.1

I am looking for advice but ultimately the best and quickest way to upgrade my 1.38a site currently to the latest version. Again I am not working with my live site so all this is on a test site. I am willing to redue the upgrade for the test site or what ever needs to be done to make it as seemless as possible.

I guess I can provide some basic background...i cloned my sql database with myphpadmin and then cloned my entire website folder. Reuploaded to the same server under a different directory and imported the sql. My test site worked perfectly on 1.38a. I then tried to upgrade it to 1.9 and everything seemed to work fine as well. I needed to make a few changes to the main page but nothing crazy. I then tried to upgrade to 1.5 and this is where I am at now. Blank or partial blank admin page.

1 Jan 2015, 6:00 PM
#12
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: the dreaded white screen

While hard for me to say exactly what all is going on, I have seen in upgrade from 1.3.8 or so to 1.5.x that sometimes the user has no choices in the admin page after login.

I assume further that because there are no new error logs (otherwise they would be posted,correct?) That you are able to successfully login, but now have no real "options". If this isthecase, it is possible that the users have been assigned an admin_profile of 0 instead of 1. Therefore when logging in ZC is not sure what permissions to provide, so basically, no permissions are given.

Okay, so, the next/other thing is why hopping from version to version and not just going to the latest perhaps following instructions like: http://www.zen-cart.com/entry.php?3-How-do-I-rebuild-my-site-on-the-new-version-instead-of-upgrading

1 Jan 2015, 6:54 PM
#13
welchyboy avatar

welchyboy

Zen Follower

Join Date:
Apr 2008
Posts:
274
Plugin Contributions:
0

Re: the dreaded white screen

A little more information...Just to see what happens...I did a complete fresh (test) install of the latest zen cart. Basically starting from scratch in another folder on the same server. Created a new database and everything. Didn't import anything. After the install the store comes up just fine but the admin portion is again completely blank. Nothing was changed or modified from the original files of the latest zencart. So it appears there are other issues. Not having to do with the upgrade. I looked in the cache folder and there were no errors.

I don't know if this has anything to do with it but the server requirements for 1.54 are

PHP Version

Zen Cart v1.2.x through v1.3.6 are compatible with PHP 4.3.2 - 4.4.x. They are NOT compatible with PHP 5.
Zen Cart v1.3.7-v1.3.8a are compatible with PHP 4.3.2 through PHP 5.2.x, but not PHP 5.3.
Zen Cart v1.3.9 series is compatible with PHP 5.2.10 thru PHP 5.3.x.
Zen Cart v1.5.0 is compatible with PHP 5.2.14 thru PHP 5.3.x. Requires patches to work with PHP 5.4, and upgrading is a better idea.
Zen Cart v1.5.1 is compatible with PHP 5.2.14 thru PHP 5.3.x. Requires some patches to work with PHP 5.4, and upgrading is a better idea.
Zen Cart v1.5.2 is compatible with PHP 5.3.7* thru PHP 5.6
Zen Cart v1.5.3 is compatible with PHP 5.3.7* thru PHP 5.6
Zen Cart v1.5.4 is compatible with PHP 5.3.7* thru PHP 5.6

But the version I have on my hosting server is 5.2.17.

1 Jan 2015, 7:07 PM
#14
welchyboy avatar

welchyboy

Zen Follower

Join Date:
Apr 2008
Posts:
274
Plugin Contributions:
0

Re: the dreaded white screen

It looks like that was it. I went into my cpanel and changed the php version to 5.4 and I was able to get in. The downside for testing purposes is when I do that it makes my 1.38a site not work because it isn't compatible with 5.4 lol. But I can do some after hours testing. Later on today I will try and do the upgrade again with php 5.4 turned on to see if I can get it to work properly.

1 Jan 2015, 7:12 PM
#15
mc12345678 avatar

mc12345678

Totally Zenned

Join Date:
Jul 2012
Posts:
16,908
Plugin Contributions:
2

Re: the dreaded white screen

welchyboy:

A little more information...Just to see what happens...I did a complete fresh (test) install of the latest zen cart. Basically starting from scratch in another folder on the same server. Created a new database and everything. Didn't import anything. After the install the store comes up just fine but the admin portion is again completely blank. Nothing was changed or modified from the original files of the latest zencart. So it appears there are other issues. Not having to do with the upgrade. I looked in the cache folder and there were no errors.

I don't know if this has anything to do with it but the server requirements for 1.54 are

PHP Version

Zen Cart v1.2.x through v1.3.6 are compatible with PHP 4.3.2 - 4.4.x. They are NOT compatible with PHP 5.
Zen Cart v1.3.7-v1.3.8a are compatible with PHP 4.3.2 through PHP 5.2.x, but not PHP 5.3.
Zen Cart v1.3.9 series is compatible with PHP 5.2.10 thru PHP 5.3.x.
Zen Cart v1.5.0 is compatible with PHP 5.2.14 thru PHP 5.3.x. Requires patches to work with PHP 5.4, and upgrading is a better idea.
Zen Cart v1.5.1 is compatible with PHP 5.2.14 thru PHP 5.3.x. Requires some patches to work with PHP 5.4, and upgrading is a better idea.
Zen Cart v1.5.2 is compatible with PHP 5.3.7* thru PHP 5.6
Zen Cart v1.5.3 is compatible with PHP 5.3.7* thru PHP 5.6
Zen Cart v1.5.4 is compatible with PHP 5.3.7* thru PHP 5.6

But the version I have on my hosting server is 5.2.17.

How about checking the logs folder instead of the cache folder? As of ZC 1.5.1 errors were captured in the logs folder instead...

Yes, php version may be an issue to some extent. When saying created a new database and everything, mind filling in the gap? What is and everything? Was a template installed? Possible configure.php configuration settings (wrong paths). As far as "nothing is changed" also did rename the admin directory though correct away from admin?

1 Jan 2015, 7:40 PM
#16
welchyboy avatar

welchyboy

Zen Follower

Join Date:
Apr 2008
Posts:
274
Plugin Contributions:
0

Re: the dreaded white screen

I tried to update again from 1.38 to 1.54 with the php correct this time. The main site works but admin is still blank. Nothing changed except the configure.php paths. The error in the logs folder is

[01-Jan-2015 13:26:20] PHP Parse error: syntax error, unexpected T_STATIC in /home/stxmill/public_html/testzen/admin/includes/classes/class.admin.zcObserverLogEventListener.php on line 118

1 Jan 2015, 8:25 PM
#17
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,097
Plugin Contributions:
56

Re: the dreaded white screen

What version of PHP? Saying PHP 5.4 is not sufficient; there were creeping changes introduced throughout the PHP 5.4 line. The version number I'd be looking for would be something like PHP 5.4.35.

1 Jan 2015, 8:34 PM
#18
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,097
Plugin Contributions:
56

Re: the dreaded white screen

I'm guessing that you've got a PHP version prior to 5.3.0, at which point "late static bindings" (http://php.net/manual/en/language.oop5.late-static-bindings.php) were introduced.

1 Jan 2015, 9:57 PM
#19
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: the dreaded white screen

welchyboy:

I tried to update again from 1.38 to 1.54 with the php correct this time. The main site works but admin is still blank. Nothing changed except the configure.php paths. The error in the logs folder is

[01-Jan-2015 13:26:20] PHP Parse error: syntax error, unexpected T_STATIC in /home/stxmill/public_html/testzen/admin/includes/classes/class.admin.zcObserverLogEventListener.php on line 118
Ooops ...
Ya, if you're using PHP 5.2.x then you'll need to change the word "static" on that line 118 to "self" instead.
But I think that's the only place where a change is needed if you're using PHP 5.2.x. We'll post an announcement about this.
(Note: If you're using PHP 5.2.x, then you MUST use at least 5.2.14. Remember: PHP 5.2.17 as the last 5.2 version, and that was in January 2011 ... and 5.2 is officially no longer supported, and has no security protections.)

2 Jan 2015, 12:26 AM
#20
welchyboy avatar

welchyboy

Zen Follower

Join Date:
Apr 2008
Posts:
274
Plugin Contributions:
0

Re: the dreaded white screen

DrByte:

Ooops ...
Ya, if you're using PHP 5.2.x then you'll need to change the word "static" on that line 118 to "self" instead.
But I think that's the only place where a change is needed if you're using PHP 5.2.x. We'll post an announcement about this.
(Note: If you're using PHP 5.2.x, then you MUST use at least 5.2.14. Remember: PHP 5.2.17 as the last 5.2 version, and that was in January 2011 ... and 5.2 is officially no longer supported, and has no security protections.)

I am aware my PHP is quite old now...but I turned it on to test after upgrading the site again and it still is not working. I have a chance to login to the admin portion once and then I get the menu but everything else is blank...partial blank page. Since I will be using PHP 5.4 and change it to that when I try the test site shouldn't it work? Or do I need to change the piece of code you are referring too?

All it says is an error has occurred. Try refreshing the page.

Here are the errors I am getting in the logs now..Currently I have my cpanel with php 5.4 when testing.

[01-Jan-2015 18:27:02 America/Chicago] PHP Fatal error: 1054:Unknown column 'SUPERUSER_PROFILE' in 'where clause' ... ==> (as called by) /home/stxmill/public_html/testzen/admin/includes/functions/admin_access.php on line 69 <== in /home/stxmill/public_html/testzen/includes/classes/db/mysql/query_factory.php on line 155

[01-Jan-2015 18:26:12] PHP Parse error: syntax error, unexpected T_STATIC in /home/stxmill/public_html/testzen/admin/includes/classes/class.admin.zcObserverLogEventListener.php on line 118