87,921
社区成员
发帖
与我相关
我的任务
分享
<table class="table table-striped table-bordered bootstrap-datatable datatable responsive">
<thead>
<tr>
<th>ID</th>
<th>昵称</th>
<th>得奖</th>
<th>奖项内容</th>
<th>得奖时间</th>
</tr>
</thead>
<tbody>
<?PHP
$result = mysql_query("select * from record as r left join prize as p on r.prizeid=p.id where p.type=2 ORDER BY r.rid desc");
$i=0;
while($row=mysql_fetch_array($result)){
$i++;
echo '<tr>';
echo ' <td class="center">'.$row['usernm'].'</td>';
if ($row['prize']==6){
echo ' <td class="center"> 未中奖</td>';
}else{
echo ' <td class="center"> <span class="label-success label label-default">'.$row['prize'].'</span></td>';
}
echo ' <td class="center">';
echo ' '.$row['prizetitle'].' <input id="ok" name="ok" type="button" value="审核通过" style="width:200px;" /> <input id="no" name="no" type="button" value="审核不通过" style="width:200px;" />';
echo ' </td>';
echo ' <td class="center">';
echo ''.date("Y-m-d ", $row['time']);
echo ' </td>';
echo '</tr>';
}
?>
</tbody>
</table>
<script type="text/javascript">
$(document).ready(function(){
$("#ok").click(function(){
alert(" ok ");
});
$("#no").click(function(){
alert(" no ");
});
}); // $(document).ready(){
</script>