implement preload_id/preload_type url scheme for backwards compatibility.
fix js login dialog.