You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi! I'm trying to start using crossroads. I've managed to get "/" route working but for some reason others (/account) wont work. Could you help a noobie out of this?
`
var defaultRoute = crossroads.addRoute("/", function () {
$("#root").load("main.html");
});
var accountRoute = crossroads.addRoute("account", function () {
$("#root").load("account.html");
});
crossroads.parse(document.location.pathname);
`
I'm getting on url localhost:8000/ all working as I want to but on localhost:8000/account it gives 404... :(
The text was updated successfully, but these errors were encountered:
Have you checked what comes into parse method from document.location.pathname.
Your root is equivalent to / so your path should also start with slash. Try /acount.
Hi! I'm trying to start using crossroads. I've managed to get "/" route working but for some reason others (/account) wont work. Could you help a noobie out of this?
`
`
I'm getting on url localhost:8000/ all working as I want to but on localhost:8000/account it gives 404... :(
The text was updated successfully, but these errors were encountered: