save location api added for ajax requests