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

"Visit URL" Route broken when Taxonomy Name contains space #2273

Closed
reuank opened this issue Aug 22, 2020 · 1 comment
Closed

"Visit URL" Route broken when Taxonomy Name contains space #2273

reuank opened this issue Aug 22, 2020 · 1 comment
Assignees

Comments

@reuank
Copy link

reuank commented Aug 22, 2020

Bug Description

When I click the "Visit URL" button while editing a Taxonomy Entry in the control panel, it leads to a 404 page when the Taxonomy Name contains a space. When creating the Taxonomy, e.g. "Application Category", the corresponding handle is "application_category", but the "Visit URL" button links to an URL containing "application-category".

How to Reproduce

  • Create a new Taxonomy called "Application Category"
  • Create a new "Application Category" called "Industry"
  • Create resources/views/application_category/show.antlers.html
  • Go to the "Industry" page in the control panel and click "Visit URL"
  • This leads you to example.com/application-category/industry instead of example.com/application_category/industry

Environment

Statamic 3.0.0 Solo
Laravel 7.23.2
PHP 7.4.8
No addons installed

Install method: Fresh install from statamic/statamic

@jasonvarga
Copy link
Member

Thanks! We'll need to make sure that the URL is kebab-cased, as per all URL-ish things, but the taxonomy is snake_cased as per handle-ish things.

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

No branches or pull requests

3 participants