Jump to content

[SOLVED] Moving Prestashop folder on server issue


Recommended Posts

Hey there. I tried everything, and really need your help now.

I have Prestashop (1.3.1) on my server www.domain.com/newshop, and then, when we completed the updates there, we wanted to move the shop to basic domain. So we copied everything to main public_folder so that it would be displayed as www.domain.com.

But with moving this folder (moving-> download via FTP, upload via FTP) and all its subfolders i seem to get an error, a blank page. I set the @ini_set('display_errors', 'on'); to "on" and got this (in browser):


Warning: include(/domains/domain.com/public_html/classes/config/config.inc.php) [function.include]: failed to open stream: No such file or directory in /domains/domain.com/public_html/classes/Product.php on line 2

Warning: include() [function.include]: Failed opening '/domains/domain.com/public_html/classes/config/config.inc.php' for inclusion (include_path='.:/usr/local/lib/php') in /domains/domain.com/public_html/classes/Product.php on line 2

Warning: include_once(/domains/domain.com/public_html/classes/init.php) [function.include-once]: failed to open stream: No such file or directory in /domains/domain.com/public_html/classes/Product.php on line 4

Warning: include_once() [function.include]: Failed opening '/domains/domain.com/public_html/classes/init.php' for inclusion (include_path='.:/usr/local/lib/php') in /domains/domain.com/public_html/classes/Product.php on line 4

Warning: include_once(/domains/domain.com/public_html/classes/header.php) [function.include-once]: failed to open stream: No such file or directory in /domains/domain.com/public_html/classes/Product.php on line 100

Warning: include_once() [function.include]: Failed opening '/domains/domain.com/public_html/classes/header.php' for inclusion (include_path='.:/usr/local/lib/php') in /domains/domain.com/public_html/classes/Product.php on line 100

Fatal error: Call to a member function assign() on a non-object in /domains/domain.com/public_html/classes/Product.php on line 325


I get this for any subpage i want to open. I'm not using URL rewrite and run on php 5.x + Zend.

I really have no idea why this is occuring? I went through all the necesary steps that have been mentioned many times on this forum. But it seems as dirname(__FILE__) insisde Product.php doensn't give the right path, or what? (Includes don't work?).

include(dirname(__FILE__).'/config/config.inc.php');
include_once(dirname(__FILE__).'/init.php');



Is it possible that it's an issue with the local php instalation (does PHP create own cache?)?

Any help would be hot! :)

Cheers!

Link to comment
Share on other sites

Hi.

Have you tried editing your /config/settings.inc.php file? I think the first line (something base_uri) is where you declare the path to your ps installation. So it should have something like "/" or "/prestashop/" in that field. And also make sure all the information on the config file is up-to-date.

HTH!

Link to comment
Share on other sites

Hi!

Thanks for the short reply! Yes, I allready tried that. I somehow ran out of normal possible options. It might be a problem with my PHP settings? Because it seems to run if i put it in any child directory (eg. domain.com/xyz, domain.com/hooray, domain.com/xxx...), just not the parent domain (domain.com/).

Link to comment
Share on other sites

PROBLEM SOLVED!

So check this out. It was a human error, my error to be specific. I guess when the deadline is near, we tend to make such mistakes.

What was the problem? The problem was that Product.php was never the Product.php class file, but it was the product.php file from the parent directory. It seem to got there by my mistake and then, when downloading the whole shop to the windows, the difference between Product.php and product.php's capital letter didn't mean a thing. And, thus, the product.php file overwrited the class file after putting it back online.

So I'll keep in mind when doing FTP transfers UNIX->WINDOWS. Anyhow, thanks for support! And merely as as suggestion, why not naming the Product.php as Product.class.php? :)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...