I'm missing something here. My problem is very simple I think. mysite.com/app and mysite.com/transaction both load a different html page but they load the same router.
For each case I need my router to be written in order than mysite.com/app/#/someparams triggers 'app' function mysite.com/transaction/#/someparams triggers 'transaction' function. (With or without # I don't care but this is the way it works for me =/ )
If I write :
routes: {
'app':'app',
'app/:params':'app',
'transaction':'transaction',
'transaction/:params': 'transaction'
}
Backbone.history.start({
pushState: true
});
Then mysite.com/app/#/params or mysite.com/transaction/#/params won't trigger the wanted functions.
If I write this:
Backbone.history.start({
pushState: false,
root:'/app'
});
then parameters will be ok for /app but not for /transaction. What to do ? I'm pretty sure I'm missing something simple but I'm kinda confused right now ..
Thanks for your help