logout uses AJAX too