How to use explode() on $_POST
<p>Could somebody please help me with <code>explode()</code> function. I am reading values with <code>$_POST[]</code> from a form on my web page Which holds 3 values: <code>$user_id[$nro]".": "."$fname[$nro]".","."$sname[$nro]</code>. </p>

<p>Now I am trying to explode the <code>$_POST()</code> values, but I can not get it to work. I have tried it in 2 different ways, but no luck...</p>

<p>First way:</p>

<pre><code>$uservalue = array();
$uservalue = $_POST['userlist'];

foreach($uservalue as $line =&gt; $content) {
$uservalue[$line] = explode(',',$content);
}

print_r($uservalue);
</code></pre>

<p>There are no values in the new $uservalue[]</p>

<p>Second way:</p>

<pre><code>$uservalue = $_POST['userlist'];
$uservalue = explode(":", $uservalue);
$uservalue = explode(",", $uservalue);
</code></pre>

<p>Warning: explode() expects parameter 2 to be string, array given in ...</p>

<p>Could somebody please help me and tell how to do it properly?</p>

<p>Thanks.</p>
