unique array values
<p>I have string of comma separated values. </p>

<pre><code>1,2,3,4,4,4,4,4,4,4,4,01633,4,4
</code></pre>

<p>I need to remove the duplicates, so I though of using </p>

<pre><code>array_unique($str);
</code></pre>

<p>However, it returns no results. So I decided to output it to see what I have:</p>

<pre><code>print_r($str);
// returns: 1,2,3,4,4,4,4,4,4,4,4,01633,4,4
</code></pre>

<p>I'm a little lost. I checked if it is an array and I got true. Here's how that string is created:</p>

<pre><code>$str = '1,2,3';

foreach ($a as $b) {
    $str.= ','.$b;
}
</code></pre>

<p>What am I missing here? </p>
