title: Multiple selection in cakephp
body: <p>Good night. I'm using cakephp 3.0 and I would really appreciate if could help me solving the follow issue:  </p>
  
  <p>I have a list of selections defined in this array:  </p>
  
  <pre><code>$daysOfWeek = ['Monday' =&gt; 'Monday', 'Tuesday' =&gt; 'Tuesday', 'Wednesday' =&gt; 'Wednesday', 'Thursday' =&gt; 'Thursday', 'Friday' =&gt; 'Friday', 'Saturday' =&gt; 'Saturday', 'Sunday' =&gt; 'Sunday'];
  </code></pre>
  
  <p>In my <strong><em>add</em></strong> view, I have something like this in order to allow multiple days selection:</p>
  
  <pre><code>echo $this-&gt;Form-&gt;input('day_of_week', [
      'options' =&gt; $daysOfWeek,
      multiple' =&gt; 'checkbox']);
  </code></pre>
  
  <p>Doing this, cakephp was always saving me and empty value in the <strong><em>daysOfWeek</em></strong> field in my database, so I had to edit the model adding the next function:</p>
  
  <pre><code>public function beforeMarshal(CakeEvent $event, ArrayObject $data, ArrayObject $options)
  {
      $data['day_of_week'] = json_encode($data['day_of_week']);
  }
  </code></pre>
  
  <p>Now, the values of the multiple selections is saving as follows in the database:</p>
  
  <pre><code>["Saturday","Sunday"]
  </code></pre>
  
  <p>But If the user wants to edit the information of some entry of this table, the checkboxes of <strong><em>daysOfWeek</em></strong> never are selected. How can I solve this?</p>
  
  <p>Thanks in advance.</p>