stripping leadding and trailing whitespace from location input