From 41f137e82baa6a4f84dec0a490616f99e032b64d Mon Sep 17 00:00:00 2001 From: rMalie Date: Mon, 16 Apr 2012 09:45:19 +0000 Subject: [PATCH] // Fix id_shop in URL git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@14650 b9a71923-0436-4b27-9f14-aed3839534dd --- classes/shop/Shop.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/classes/shop/Shop.php b/classes/shop/Shop.php index 2da29397e..21365d201 100644 --- a/classes/shop/Shop.php +++ b/classes/shop/Shop.php @@ -286,7 +286,7 @@ class ShopCore extends ObjectModel { // If in admin, we can access to the shop without right URL $shop = new Shop(Configuration::get('PS_SHOP_DEFAULT')); - $shop->physical_uri = str_replace('\\', '/', dirname(dirname($_SERVER['SCRIPT_NAME']))).'/'; + $shop->physical_uri = preg_replace('#/+#', '/', str_replace('\\', '/', dirname(dirname($_SERVER['SCRIPT_NAME']))).'/'); $shop->virtual_uri = ''; return $shop; }