Add Checked in Checkbox if value same with value from database
<p>i try to add checked in my checkbox if value in checkbox is same with value from database :</p>

<pre><code>My database :
Column = skin_type 
Value = Normal, Dry, Oily

My Default html checkbox :
&lt;input type="checkbox" name="skin_type[]" value="Normal"&gt;Normal &amp;nbsp;
&lt;input type="checkbox" name="skin_type[]" value="Dry"&gt;Dry &amp;nbsp;
&lt;input type="checkbox" name="skin_type[]" value="Oily"&gt;Oily &amp;nbsp;
&lt;input type="checkbox" name="skin_type[]" value="Combination"&gt;Combination &amp;nbsp;
&lt;input type="checkbox" name="skin_type[]" value="Sensitive"&gt;Sensitive
</code></pre>

<p>so if value is <code>Normal, Dry, Oily</code>  checkbox with this value will checked , example like below </p>

<p><img src="http://i.stack.imgur.com/mcAqA.jpg" alt="enter image description here"></p>

<p>Below is my current php script (<em>i try to explode the data first but not sure how to add checked if value is equal with value from database</em>) :</p>

<pre><code>&lt;?php 
$query_skin_type = mysql_query("SELECT skin_type FROM `customers` WHERE customers_id='".$_GET['cID']."'");
while($info = mysql_fetch_array($query_skin_type)) {

$skin_type = explode(", ", $info['skin_type']);

    foreach ($skin_type as $value) {
    $value.'&lt;br&gt;';
    }
}
?&gt;
</code></pre>
