我有从数据库中获取数据的网格,如下所示:-
<table width="100%" cellspacing="0" cellpadding="0" border="0" class="gwlines">
<tbody><tr>
<th width="15">#</th>
<th width="150">Name</th>
<th width="100">Type</th>
<th width="50">Date</th>
<th width="50">From</th>
<th width="50">To</th>
<th width="30">Price</th>
<th width="30">Paid</th>
<th width="30">Remaind</th>
<th colspan="4">Actions</th>
</tr>
<?
$i=1;
while($objResult=mysql_fetch_array($objQuery)){
?>
<tr id="vip_row<?=$objResult["vip_id"];?>" <? echo ($i%2==0?'bgcolor="#edf0f6"':''); ?>>
<td><input name="cbSelect[]" type="checkbox" id="cbSelect[]" value="<?=$objResult["vip_id"]; ?>" /></td>
<td><?=$objResult["customer_name"]; ?></td>
<td><?=$objResult["vip_type"]; ?></td>
<td><?=$objResult["vip_date"]; ?></td>
<td><?=$objResult["vip_from"]; ?></td>
<td><?=$objResult["vip_to"]; ?></td>
<td><?=$objResult["vip_price"]; ?></td>
<td><?=$objResult["vip_paid"]; ?></td>
<td><?=$objResult["vip_remind"]; ?></td>
<td width="16"><a href="index.php?body=edit_vip&id=<?=$objResult["vip_id"];?>" original-title="Edit and View VIP Information"><img width="15" height="15" class="tabpimpa" alt="picture" src="images/edit.png"></a></td>
<td width="16"><a href="#" onClick="delete_vip('<?=$objResult["vip_id"];?>');" original-title="Delete VIP"><img width="15" height="15" class="tabpimpa" alt="picture" src="images/delete.png"></a></td>
<td width="16"><a href="print_single_bills_vip.php?id=<?=$objResult["vip_id"];?>" target="_new"><img width="15" height="15" class="tabpimpa" alt="picture" src="images/print.png"></a></td>
<td width="16"><a href="#" onClick="vip_to_egypt('<?=$objResult["vip_id"];?>');"><img width="15" height="15" class="tabpimpa" alt="picture" src="images/sms.png"></a></td>
</tr>
<? ++$i; } ?>
</tbody></table>
该网格将从数据库中获取数据,我想将此结果数据导出到 Excel。
我怎样才能做到这一点?