Move to production is not working
Had Zen-Cart running fine on my local pc. I moved it up to my host and now two things happen:
1) Accessing admin: it immediately comes up with the "Hello. Thank you for loading Zen Cart ... " screen,
and
2) Accessing the store gives me an empty page.
I have double-checked the two config files and they look fine.
Here is how I moved to production:
1) On my local pc, my store was in /store. I uploaded the entire directory to my host.
2) I exported my local database and imported it on the host. It looks fine. All the tables are there, data is there, etc.
3) I edited includes/configure.php and admin/includes/configure.php as appropriate. I have checked these over multiple times and everything looks fine.
4) In the database on the host, in the zc_configuration table (my prefix is zc_), I changed the value of "configuration_value" for configuration_key = 'SESSION_WRITE_DIRECTORY' to be the path to my cache (/vservers/mywebsite/htdocs/store/cache).
Did I miss something?
Re: Move to production is not working
Did you edit your DB connection entries in the configure.php files??
Re: Move to production is not working
Oh yes definitely. That's the first thing I checked. I have another site with Zen-Cart running on the same host, and I even looked at the settings for that to be sure I had slashes where I was supposed to, none where I wasn't supposed to, correct virtual paths, etc.
I can post my config files here if necessary. I would blank out my db password of course. What else should I disguise before posting?
Re: Move to production is not working
There are essentially 3 conditions:
All is well
Can not connect to DB
Needs to be installed
I don't recall exactly the conditions that create the not installed message versus the DB connect error....
Your blank screen is indicative of a corrupt upload of a file or many - - or an FTP client transfer corruption...Some clients are better at not doing this than others..
One method to minimize this is, if you are on a cPanel account or another that facilitates expanding compressed files on the server, is to zip or tar.gz locally all your shop files. FTP the compressed file to your server and expand it there. Use FTP to move any items needed on the server.
Re: Move to production is not working
I decided to try to upload my files again. I went to delete my "store" folder and it said I didn't have permissions! Support at my hosting company, however, was able to delete it by logging into ftp server with my exact same credentials. Very strange.
The post here:
https://www.zen-cart.com/tutorials/index.php?article=99
mentions being sure that the zc_install directory is copied up. I didn't do that because I didn't think I needed to go through the install. Maybe I do?
I'm going to load up "virgin" Zen files, then do the install up to the point of configuring the store (as the instructions say), then I'm going to FTP up my store files to overwrite what's there (except for the config files). I'll let you know what happens.
I'm not going to touch my database that I imported earlier.
Re: Move to production is not working
Re: Move to production is not working
Well ... I finally started from scratch with a fresh install of Zen Cart directly to my remote host.
Following the installation instructions, I downloaded the Zen zip file, extracted the files, and uploaded them to /store on my server. I uploaded them using ftp://mysite.com in Windows Explorer and then dragging files from a folder on my pc into the ftp window. Everything appeared to get copied up correctly.
Then I set permissions, as instructed.
Next was to run the installer, but when I tried to run it (www.mywebsite.com/store/zc_install) all I got was a blank page!
www.mywebsite.com/store/zc_install/index.php doesn't work either.
Nor does www.mywebsite.com/store
I'm in IE, the bottom of the window says "Done", but the window is empty. Same thing in Firefox.
SO ... this leads me to believe that my problem all along must have something to do with my host? What settings should I be looking at? I do have another site with the same host that is successfully running Zen Cart.
Any other ideas?
And again I ask: what the heck am I missing? :frusty:
Re: Move to production is not working
Quote:
Originally Posted by
alicia1234
... uploaded them to /store on my server. I uploaded them using
ftp://mysite.com in Windows Explorer and then dragging files from a folder on my pc into the ftp window.
EEK.
You trust IE as an FTP client? :eek:
You've probably got a bunch of damaged files or incomplete transfers.
Get a program whose sole purpose is FTP, instead of something that does FTP as an afterthought/addon.
Try FileZilla http://filezilla.sf.net instead.
Re: Move to production is not working
FTP has worked fine for me in the past, and also on the site that IS successfully running Zen Cart. Note that I have also uploaded the files through Dreamweaver's "Remote Files" panel and that produces the same result. Can I assume that Dreamweaver constitutes a "real FTP client"?
I really don't think it's an FTP problem.
Re: Move to production is not working
Dreamweaver's FTP is fine for one-off individual files. But for mass-uploading an entire site/folder, I don't trust it ... it's failed me many times in that regard.
Re: Move to production is not working
OK ... I installed FileZilla.
Re-uploaded all of the files using it.
SAME PROBLEM - when I try to run the installer, I just get a blank page.
Re: Move to production is not working
What's in the installer log in your /cache/ folder?
Re: Move to production is not working
What happens if you edit the /zc_install/includes/install_params.php file and change this line:
Code:
define('STRICT_ERROR_REPORTING', false);
to:
Code:
define('STRICT_ERROR_REPORTING', TRUE);
... and run the zc_install/index.php again?
Re: Move to production is not working
Quote:
Originally Posted by
DrByte
What's in the installer log in your /cache/ folder?
My /store/cache folder only has one file in it: index.php
Re: Move to production is not working
The file is actually "installer_params.php" not "install_params.php" ...
I set STRICT_ERROR_REPORTING to true.
Same problem - blank page.
Re: Move to production is not working
Could the .htaccess files have anything to do with this? I have not touched them. What got loaded up to the server is the original distribution files.
Re: Move to production is not working
You could try renaming the .htaccess file to htaccess_OFF as a test to see whether your server doesn't like the supplied .htaccess protections.
You could also look in the server's apache errorlog to see what it's recording as the cause of the blank page.
Re: Move to production is not working
I turned on error reporting on my host, and now I have more information:
When I try to run the installer (www.mysite.com/store/zc_install), php error reporting is telling me this:
Code:
Warning: include(includes/installer_params.php) [function.include]: failed to open stream: No such file or directory in /vservers/meatormotion/htdocs/store/zc_install/includes/application_top.php on line 41
Warning: include() [function.include]: Failed opening 'includes/installer_params.php' for inclusion (include_path='.;c:\php\includes') in /vservers/meatormotion/htdocs/store/zc_install/includes/application_top.php on line 41
If I click on [function.include], which is a link in the error message, it says this:
Code:
Not Found: The requested URL /store/zc_install/function.include was not found on this server
Re: Move to production is not working
Line 41 in the application_top.php file is:
Code:
include('includes/installer_params.php');
That file does exist and I can open it using my default editor (WordPad) in FileZilla.
That include at line 41 is the first include that the file tries to do.
Re: Move to production is not working
This is indicative of a corrupt file upload
More over:
Quote:
That file does exist and I can open it using my default editor (WordPad) in FileZilla.
Doing things in wordpad is highly suspect as it can add unwanted items to files
AND doing it through your FTP session is also not the recommended method.
When editing,FTP the file to your local and open it ONLY in a PLAIN text editor like notepad or one of the CODE editors available.
Try re-FTP'ing the files with filezilla and note any errors that may appear in the bottom window
Re: Move to production is not working
I'm not editing in WordPad - just viewing. I do all my editing in Dreamweaver. ;-)
I have already reloaded with FileZilla with no errors.
Re: Move to production is not working
I've been on Live Chat with my host - and comparing phpinfo across my site that runs Zen Cart fine and the one that doesn't. I discovered that the "include_path" was not set correctly! My host fixed it, and now, voila, everything works.
Yikes. I can't believe I've wasted three days on this! Thanks for your help because I did learn alot and FileZilla was a great discovery for me. Your comments also spurred me to turn on the error reporting.
So thanks again.
Re: Move to production is not working
Great!
And thanks for reporting the solution