adapt index.php and sidebar.php