Fully implemented the button