extended JS login example