entered inside the location function