Code now erases generated HTML and hides optional ToC entries before data is (re-)fetched to prevent incorrect display of old data.