Escape special characters in headings' IDs