append URI fragment and links to all HTML headings