Fix and refactor methods in database class. Add sites addition with unique code

Fixes #14 
Should I create a new method that calls the shorthand methods I wrote, or should it call the specific actions (visit "/" for instance)