adding basic functionality for checkboxes