Jump to content

Where is the code that gets the controller from url?


hastalavi2

Recommended Posts

Hi, I changed the main url working style a bit for my website. Normally, the prestashop link should look like this:

mywebsite.com/en/catalog/...

But, I installed the prestashop on a subfolder of my website. So it looked like this:

mywebsite.com/shop/en/catalog...

"shop" here is the main directory of the prestashop.

I changed the Link.php file in the Classes folder. So now I have this link:

mywebsite.com/en/shop/catalog...

But, any page returns "PageNotFound" now. So, I found that in Dispatcher.php on Classes folder, getController function gets the controller from url. But I could not figure out how.

Anyone can help me?

Link to comment
Share on other sites

6 hours ago, joseantgv said:

Have you updated the configuration?

image.thumb.png.415cc86f8042da4565cf2e04e694ba22.png

Thanks. My website is multi language. So I needed to make more than one base uris. So what I did was adding more rows on the MYPREFIX_shop_url table like:

/shop/

/en/shop/

/es/shop/

/de/shop/

But now I have another issue. The cart. 😺 When the url is not the first one, the cart products do not show up.

Everything works fine. I can add any product to cart, or any other function. But when I go to shopping cart, there is nothing there.

Only on the first link, they are accessible. Should continue on that.

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