Jump to content

Can I Change Prestashop Base Url


Recommended Posts

My client is scraping his old sho, nad I am creating new shop with Prestashop.

I want to create the new shop in a subfolder of his website without interupting his current site. Once the new shop is ready, I will remove the old site and move the new shop to the top level folder of the domain such that this becomes the new website.

 

My question :wacko: - Are there any issues in changing the base URL of my newly created shop?

 

Appreciated.

Link to comment
Share on other sites

This is very easy to do and in fact was the proper way to carry out upgrades prior to the new autoupgrade feature being available.

 

Carry on and build your shop in a sub-folder and when you are done and ready to move it do the following.

 

Create a folder called /old and move all the files for the old shop into it, or delete them if no longer required.

 

Move all the folders and files from your prestashop sub-folder to the root directory.

 

Edit the /config/settings.inc.php file and change

 

define('__PS_BASE_URI__', '/sub_folder_name/');

 

to

 

define('__PS_BASE_URI__', '/');

 

 

Log in to your BO and go to Preferences>SEO & URL's to adjust your shop accordinly.

  • Like 2
Link to comment
Share on other sites

This is very easy to do and in fact was the proper way to carry out upgrades prior to the new autoupgrade feature being available.

 

Carry on and build your shop in a sub-folder and when you are done and ready to move it do the following.

 

Create a folder called /old and move all the files for the old shop into it, or delete them if no longer required.

 

Move all the folders and files from your prestashop sub-folder to the root directory.

 

Edit the /config/settings.inc.php file and change

 

define('__PS_BASE_URI__', '/sub_folder_name/');

 

to

 

define('__PS_BASE_URI__', '/');

 

 

Log in to your BO and go to Preferences>SEO & URL's to adjust your shop accordinly.

Actually Dave,

 

As the domain is not currently available to me (for beureucratic reasons out of my control) rather than build the website in a subfolder, if I build on an entirely different URL (so I can test before site live), and then move it to the correct URL, are there any more issues (such as reconnecting the database?)

 

Thanks

Link to comment
Share on other sites

Thats not a problem either.

 

If the other domain is on same server you'll just need to transfer the files when you want to move the site. The database can stay where it it. If it's on a different ser you will have to make a backup/export of the database and restore/import on the new server.

 

When the time comes to move it and you are not too sure, there is plenty of help on here. Just bookmark your post so you can your thread again and ask away.

Link to comment
Share on other sites

  • 2 weeks later...

I've pretty much done the same process as discussed above and now have my PrestaShop sitting on a subfolder on my new server.

 

Admin seems to be working fine however product images on the website itself are not being found correctly and all links are displaying the error page "object not found".

 

The page addresses being linked to look fine (ie. same as before with subfolder prefix).

 

Any ideas?!

Link to comment
Share on other sites

  • 1 month later...

OK I've done these changes and my shop is now on the correct domain - http://www.varaldocosmetica.it

 

BUT I have the following problems:

  1. Homepage gives a 404 error
  2. Admin pandel still have to access via old url (and it gives me a warning that I should not do this!?

Can anyone help.

Much appreciated

 

(p.s. I also regenerated the .htaccess)

Just solved this - clearing cache and regenerating htaccess file for a second time.

Not sure about SEO best practises though.

I would prefer my default Italian homepage http://www.varaldocosmetica.it/it/ to display without the /it/

Link to comment
Share on other sites

  • 6 months later...

 

 

Edit the /config/settings.inc.php file and change

 

define('__PS_BASE_URI__', '/sub_folder_name/');

 

to

 

define('__PS_BASE_URI__', '/');

 

 

 

can you tell me where i can found this file in prestashop 1.5. i do wrong setting from adimin url base!!fiuh.

Link to comment
Share on other sites

  • 2 weeks later...

i did wrong in base url as well, i changed the base url field from empty to myshop.com, and now when i want to login the back office the URL becomes myshop.com/myshop.com/admin/login.php and then leads to a "page-not-found", really strange. anyone have any idea about that ? :(

Link to comment
Share on other sites

  • 1 month later...
  • 3 weeks later...

I have got the same problem. When i try to understand about multistore i changed the destination of my shop from "/" to "/subdir/" in adminpanel. Instantly I lost the connection wit adminpanel and shop. Now when i folow to mysite.com browser redirect me to mysite.com/subdir/index.php and show 404. Adminpanel is the same.

Any body can help me!?

Edited by Abdurahman (see edit history)
Link to comment
Share on other sites

  • 11 months later...

This is very easy to do and in fact was the proper way to carry out upgrades prior to the new autoupgrade feature being available.

 

Carry on and build your shop in a sub-folder and when you are done and ready to move it do the following.

 

Create a folder called /old and move all the files for the old shop into it, or delete them if no longer required.

 

Move all the folders and files from your prestashop sub-folder to the root directory.

 

Edit the /config/settings.inc.php file and change

 

define('__PS_BASE_URI__', '/sub_folder_name/');

 

to

 

define('__PS_BASE_URI__', '/');

 

 

Log in to your BO and go to Preferences>SEO & URL's to adjust your shop accordinly.

Thank You so much,, its work !!  :)  :)

Link to comment
Share on other sites

  • 2 years later...

Hi, my domain is www.deltapeninternational.com

but i have all f iles in shop folders. if i write deltapeninternational.com it doesn't find me. i mus write /shop/

 

can help me?

Link to comment
Share on other sites

  • 5 months later...

Hello,

I've got the similar problem after changed dns domain my shop work correctly but Admin panel still have to access via old url and haven't got graphics there like on the picture.

post-1214107-0-67964300-1464146258_thumb.jpg

 

I changed in Preferences>SEO & URL's and domain it's fine, but didn't help for admin panel.

I will be gratefull for any advice.

Thank you.

Link to comment
Share on other sites

  • 2 years later...

Instead of changing configuration files, just go to database table called {$prefix}_shop_url, default is ps_shop_url and there you have all you want.

In the domain and domain_ssl place your root directory f.ex: example.com

In the physical_url you enter the exact directory with / at the beginning and the end. For example: /shop/

Link to comment
Share on other sites

  • 1 year later...
On 1/3/2012 at 7:23 PM, Dave L said:

This is very easy to do and in fact was the proper way to carry out upgrades prior to the new autoupgrade feature being available.

 

Carry on and build your shop in a sub-folder and when you are done and ready to move it do the following.

 

Create a folder called /old and move all the files for the old shop into it, or delete them if no longer required.

 

Move all the folders and files from your prestashop sub-folder to the root directory.

 

Edit the /config/settings.inc.php file and change

 

define('__PS_BASE_URI__', '/sub_folder_name/');

 

to

 

define('__PS_BASE_URI__', '/');

 

 

Log in to your BO and go to Preferences>SEO & URL's to adjust your shop accordinly.

Hi,

 

I tried this and get this text when I open the settings.inc.php file you earlier mentioned:

<?php
//@deprecated 1.7

 

Furthermore nothing in the document.

 

What now? please?

 

Regards

 

 

 

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...