[eluser]Madmartigan1[/eluser]
It's from the manual - hence, "A little copy/paste from the manual".
Where are you getting a 404? Default controller?
Also FWIW, search the forums. There are already tons of posts about this very issue.
EDIT: I see you solved it. Thanks for sharing the code so others may benefit from it