0
votes

I have an installation of prestashop 1.6 on a domain www.mydomain.com and a virtualhost on a server for redirecting to the prestashop/public_html folder. This is my main website working perfect.

Now i would like to clone the installation in another folder prestashop/clone_html and i created an alias on the virtualhost from www.mydomain.com/clone to prestashop/clone_html

Now if i access the clone website the frontend is not working, i get a 404 error and all the links are pointing on the main domain

I tried to change settings.inc.php change the base URI on the database and delete both .htaccess and cache but the links are never changing.

I think maybe the problem is coming from multilanguage redirect? Do you have any idea what i should try to change?

Thanks

1
Why don't you simply use a subdomain? - Julien Lachal
you mean putting the other installation in another folder without alias? Because i'm used to use Larvel and i presumed also prestashop rewrites all the url in the subdomain - GabAntonelli
I mean having both installations in different folders, then have your main instal on your main domain, and have the clone on a subdomain in your vhost. You then simply have to change the URL of the clone in the DB in table ps_configuration, look for the 2 fields with the URL in them. - Julien Lachal
Even if you move shop to a new domain, you can still access your backend at www.newdomain.com/youradminfolder and make changes to the shop URL from backend. - TheDrot

1 Answers

1
votes

That is a good one! If you want to change the URL of the store and you have already migrated the contents (so no access to the admin is possible or you don“t want to bother), you may do the change directly at the PS table where this information is kept. The name of the table is <prefix>shop_url. Once you access it, the content is self explanatory. You have to play with domain or domain_ssl and then with physical_uri.

Also, using a subdomain as has been suggested in a comment may be a good idea. Depending on your hosting, you may be able to define a subdomain and make it point to a subdirectory. This keeps the physical_uri to / and may avoid other potential problems.