implemnet the main page