Some functions are migrated to functions.php
The menu items and page blocks now only display if there is anything to display
(still a bug on "galerie" menu item)