Add cookie logic to remember the user
use ilike for postgresql databases