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

X-PJAX-URL #577

Closed
Guro opened this issue Oct 1, 2015 · 3 comments
Closed

X-PJAX-URL #577

Guro opened this issue Oct 1, 2015 · 3 comments

Comments

@Guro
Copy link

Guro commented Oct 1, 2015

Hello we are using .htaccess with modrewrite to do some url rewriting.
so the problem is for example we have url:

/news/item/5 which actually rewrites via htacces to something like mode=news&id=5
so when pjax is imlemented and link is set to /news/item/5 it refreshes whole page, but if link is set to
?mode=news&id=5 everything works fine.

i think its related to X-PJAX-URL header but documentation is unclear at this point, can anyone help?

@kafeltz
Copy link

kafeltz commented Oct 1, 2015

As far as i know, the header have nothing to do with URL in this case.

See your response of your pjax and check for http 302 status or location attribute.

Seems to be some callback logic.

@staabm
Copy link
Contributor

staabm commented Oct 1, 2015

@Guro PJAX doesnt know anything about your server-side magic. it is only aware of urls on the client-side and it expects X-PJAX-URL to be formatted like the urls it uses for navigation.

@Guro
Copy link
Author

Guro commented Oct 1, 2015

Sorry the problem was in absolutely different thing :) my fault

@Guro Guro closed this as completed Oct 1, 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

3 participants