title: How do I fix PHP Warning: array_unique() expects parameter 1 to be array, string given in
body: <p>How to fix </p>
  
  <blockquote>
    <p>PHP Warning: array_unique() expects parameter 1 to be array, string
    given in</p>
  </blockquote>
  
  <p>Code :</p>
  
  <pre><code>$subitems_values=sanitize($_REQUEST['subitems']);
  $subitems_values = array_unique($subitems_values); // error line.
  $SubItemToken=implode(",", $subitems_values);
  $cnt=count($subitems_values);
  </code></pre>