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

Non-encoded slashes (/) on query params choosing wrong pattern #142

Open
arnavmaiti opened this issue Nov 24, 2015 · 0 comments
Open

Non-encoded slashes (/) on query params choosing wrong pattern #142

arnavmaiti opened this issue Nov 24, 2015 · 0 comments

Comments

@arnavmaiti
Copy link

We have 2 patterns that parses the URLs using crossroads:

crossroads.addRoute('/:seo_slug*:/{pageId}/{contextId}', null, 200);
crossroads.addRoute('/:seo_slug*:/{pageId}?{parameters}', null, 200);

This works fine for all the normal URL patterns. However for query based patterns that uses unencoded slashes (/) in their URLs, it seems to choose the first pattern over the second one.
For example

http://www.abc.com/#/abc?page=example/page/1

Although the second pattern should be chosen here, the first pattern is instead chosen and the data shows up as follows:

seo_slug = abc?page=example
pageId = page
contextId = 1
@arnavmaiti arnavmaiti changed the title Non URL encoded slashes (/) choosing wrong pattern Non URL encoded slashes (/) on query params choosing wrong pattern Nov 24, 2015
@arnavmaiti arnavmaiti changed the title Non URL encoded slashes (/) on query params choosing wrong pattern Non-encoded slashes (/) on query params choosing wrong pattern Nov 24, 2015
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

1 participant