I have a dinamycly generated table on my page (depending on a result from a query) with entrys and checkboxes. Now I pass the checkboxnames to an array. The array have then values like eg. 10, 25, 26 ... in it. This values (checkboxnames) are also field-identifyer on a second database with the field "entry_ID".
What I would like to do now is to check if a checkbox is "ON" on the dynamicly generated table and update a field in the depending row with "1" (review_done).
My code looks like so atm: (and does not work)
if (isset($_POST['maintget']))  
        {
        $rows = $_SESSION["countRows"];
        $chkb_names = $_SESSION["arr_chkb_names"];
        //print_r($chkb_names);
        for ($c = 0; $c<$rows; $c++)
            {
                if(isset($_POST($chkb_names[$c])) && $_POST($chkb_names[$c] == 1))
                {                       
                    $sql    = 'UPDATE testDB SET review_done=? WHERE entry_ID =?';
                    $result = $db->prepare( $sql );
                    $result->bind_param('ii', 1,$chkb_names[$c]);
                    $result->execute(); 
                }
            }
        }
Any help would be nice!!! THX
 
    