simplified the websocket connection code, changed the navbar template so it sets the right navbar item active based on active page