Page 1 of 1

Language Key in URLs?

Posted: Mon Jul 18, 2022 2:43 am
by MMumpower
Hi there!

This is my very first install with OpenCart and after a fresh install with no modifications, I'm seeing "en-gb" in most (if not all) URLs. I did enable the SEO URL option and renamed the htaccess accordingly, but I'm still getting the same result.
Right now, I'm getting links like this: https://domain.ext/en-gb?route=account/wishlist
Ideally I would like this to be more akin to: https://tss.rocks/account/wishlist

Any guidance would be most appreciated!

Re: Language Key in URLs?

Posted: Mon Jul 18, 2022 11:12 pm
by Johnathan
SEO URLs are only for product pages, category pages, manufacturer pages, and information pages. For other pages you'll need an extension (or be handy with htaccess).

I have a Rewrite Manager extension that can do what you're looking for. It can replace the "index.php?route=" parameter of any page. You just enter the route and the replacement, and it will affect any page in your installation. This includes custom pages added through other extensions.

The only thing it doesn't have is the ability to rewrite URLs that include particular query string variables. (That's something like "&blog_id=123".) Those would get appended as usual. For example, you could replace the route "extension/blog" with "blog", and if the URL was this:

Code: Select all

www.mydomain.com/index.php?route=extension/blog&blog_id=123

then it would end up looking like this:

Code: Select all

www.mydomain.com/blog?blog_id=123

Feel free to take a look at the screenshots and demo site, and if you're interested let me know at www.getclearthinking.com/contact if you have any questions.