Remove head elements which are not in the new page