title: how to validate checkbox number in Yii
body: <p>My page has many checkbox, varies from 5 to 100, I need to verify the checked number. The minimal number is 2, max is 8. I went through yii documents, and not found such a validation method. How can I achieve this in an elegant way?</p>
  
  <p>In addition, I want to save the checkbox value in session while user manipulating it , how to achieve this?</p>