Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

/blog index page keeps working after changing blog route in settings #499

Closed
jornwildenbeest opened this issue May 23, 2023 · 2 comments
Closed

Comments

@jornwildenbeest
Copy link

jornwildenbeest commented May 23, 2023

Describe the bug
Goal: I want to change the slug of the blog index page.

Not sure if this is default behaviour or a bug. But it is not behaviour that I expected.
When changing the blog route in settings to /blogindex for example, /blog keeps working.

/blog is still working, you would expect that only /blogindex works.

Preconditions:

To Reproduce
Steps to reproduce the behavior:

  1. Go to settings
  2. Change blog index route to something else.
  3. Visit /blog
  4. This is still working while we changed the blog index route
@jornwildenbeest jornwildenbeest changed the title /blog keeps working after changing blog route in settings /blog index page keeps working after changing blog route in settings May 23, 2023
@magefan
Copy link
Owner

magefan commented May 23, 2023

@jornwildenbeest , that is expected behavior as the "blog" is also the module route frontend name https://github.com/magefan/module-blog/blob/master/etc/frontend/routes.xml (a technical path).

When you change the blog route to the blogindex all blog URLs are now working with this new route, but /blog is still available.
On /blog page you can see the canonical URL that leads to blogindex, this helps with fixing page duplication.
If you want you can make 301 redirects on the webserver level to 301 redirects from /blog to /blogindex

Similar behavior you can see in the catalog. For example, each product has a technical URL /catalog/product/view/id/PRODUCT ID, e.g. https://blog.demo.magefan.top/joust-duffle-bag.html has technical URL https://blog.demo.magefan.top/catalog/product/view/id/1

Let us know if it makes sense for you.

@jornwildenbeest
Copy link
Author

@magefan ah I understand. I indeed fixed it for now with a redirect to the new page. Thanks for the response!

I will close this issue as it is seen as expected behavior.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants