Changed method to type in AJAX calls.