How can i retrieve datas of my checkboxes
<p>I am having a problem with reading the data in checkboxes. I did some research on the net and found the below code. This code is for <em>removing</em> data with checkboxes though.</p>

<pre><code>function deleteData()
{
    var artistIds = new Array();

    $(".p16 input:checked").each(function(){
        artistIds.push($(this).attr('id'));
    });
var sitepath = 'http://www.sinemalar.com/';

$.post('/json/crewonly/deleteDataAjax2', 
       { json: JSON.stringify({'artistIds': artistIds}) },
       function(response){
        alert("Başarıyla silindi");
        window.location.replace(window.location.pathname);
});
</code></pre>

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

<p>and this is the code which produces checkboxes.</p>

<pre><code>{foreach value=artist2 from=$artist}



        &lt;br /&gt;
        &lt;input type="checkbox" name="artist[]" value="{$artist2.MOVIE_ID}-{$artist2.PERSON_ID}" { in_array array=$item match=$artist2.NAME_SURNAME returnvalue="CHECKED" }&gt;{$artist2.NAME_SURNAME}&lt;br /&gt;
        &lt;hr /&gt;



        {/foreach}
</code></pre>

<p>The person who wrote this code uses this to read checkboxes.  Do i have to use <code>&lt;p&gt;</code> to read my checkbox values or is there an alternative way? 
    .p16 input:checked</p>
