login on every page, fix some urls