Strip whitespace from ID in HTML output