Adding code to show a loading cursor on click