Created
December 19, 2010 18:36
-
-
Save rmdort/747574 to your computer and use it in GitHub Desktop.
Sammy.js Routes for Expression Engine
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Sammy Routes for Expression Engine | |
this.get('#/', function(context) { | |
this.partial('{path=sammy/home}'); | |
context.app.swap(); | |
}); | |
this.get('#!/:url', function(context) { | |
this.partial('{path=sammy}/'+this.params['url']); | |
}); | |
this.get('#!/:url/:item', function(context) { | |
context.partial('{path=sammy}/'+context.params['url']); | |
}); | |
this.get('#!/:url/category/:item', function(context) { | |
this.partial('{path=sammy}/'+context.params['url']+'/category/'+context.params['item']); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment