[eluser]khmer angkor[/eluser]
[removed]
function checkall(num){
for ( i=0;i < document.action.elements.length ; i++ ){
if ( document.action.all.checked==true ){
document.action.elements[i].checked = true;
} else {
document.action.elements[i].checked = false;
}
}
[removed]
<?include "header.php";?>
<table width="770" border="1" style="border-collapse: collapse;">
<thead>
<tr>
<th>delete</th>
<th>devid</th>
<th>username</th>
<th>permission</th>
<th>lastname</th>
<th>firstname</th>
<th>Team</th>
<th>phone</th>
<th>joindate</th>
<th>gender</th>
<th>view</th>
</tr>
</thead>
<tbody>
<?foreach ($query->result() as $row): ?>
<tr>
<td><?echo form_checkbox('action', 'accept', FALSE);?></td>
<td><?=$row->devid?></td>
<td><?=$row->username?></td>
<td><?=$row->permission?></td>
<td><?=$row->lastname?></td>
<td><?=$row->firstname?></td>
<td><?=$row->Team?></td>
<td><?=$row->phone?></td>
<td><?=$row->joindate?></td>
<td><?=$row->gender?></td>
<td><?=anchor('welcome/view_dev/'.$row->devid, 'details')?></td>
</tr>
<?endforeach;?>
<tr>
<td width="5%" class="row_tittle"><input type="checkbox" name="all"></td>
<td colspan=11 class="row_tittle" align=left><input type="submit" name="Submit" value="Delete select devloper"><?=anchor('welcome/developer/', 'create')?></td>
</tbody>
</table>
<? $string = "</div></div>";
echo form_close($string); ?>
<?include "footer.php";?>
Anyone help me .my function red color.when i click on checkbox every checkbox in the form will be checked..
thanks,