User login

I've finished the conversions to the Rails way and added tests for the main login function.

The routes now use underscores instead of dashes so it is more automated. I looked for a conversion, but there's really no good way. So I figured no point fighting it any more and just got on the Rails with underscores.