prototype for button functionality