Added ability to handle checkbox