javascript for logged-in nav