function location changed