working auth and links on pages