cleaning unnecessary links from header and some stuff from template setting