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

Relative urls using pathjs #89

Open
docmattman opened this issue Jan 6, 2016 · 0 comments
Open

Relative urls using pathjs #89

docmattman opened this issue Jan 6, 2016 · 0 comments

Comments

@docmattman
Copy link

I'm having trouble with relative image urls and links when using pathjs and routing. I am developing in http://localhost/app and on that page, I have relative urls for images (i.e. src="images/some.jpg"). When I navigate to some route (i.e. "test/route/1"), the url changes to http://localhost/app/test/route/1, which is expected. But if I refresh that page on that route, the image no longer works. It is looking for the image at http://localhost/app/test/route/1/images/some.jpg (incorrect location) instead of http://localhost/app/images/some.jpg (correct location). Is there a way to use relative urls for links and image sources when routing with pagejs?

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