making the buttons work