Sanitize query terms in URL