-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathaction_amandemen.php
45 lines (45 loc) · 1.06 KB
/
action_amandemen.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
<!DOCTYPE html>
<html>
<head>
<title></title>
</head>
<body>
<?php
header("Content-type: application/vnd-ms-excel");
header("Content-Disposition: attachment; filename=amandemen.xls");
?>
<table border="1">
<thead>
<tr>
<th>No. SPK</th>
<th>Vendor</th>
<th>No. Amandemen</th>
<th>Uraian</th>
<th>Tanggal</th>
<th>Akhir SPK</th>
<th>Nilai SPK</th>
</tr>
</thead>
<?php include 'config.php';
$sql = isset($_POST['export'])?$_POST['export']:'';
$sql_tabel = mysqli_query($conn, $sql) or die (mysqli_error($conn));
if (mysqli_num_rows($sql_tabel) > 0) {
while ($row = mysqli_fetch_array($sql_tabel)) { ?>
<tbody>
<tr>
<td><?php echo $row['no_spk']; ?></td>
<td><?php echo $row['vendor_spk']; ?></td>
<td><?php echo $row['no_amd']; ?></td>
<td><?php echo $row['uraian_amd']; ?></td>
<td><?php echo $row['tgl_amd']; ?></td>
<td><?php echo $row['akhir_spk']; ?></td>
<td>Rp.<?php echo number_format($row['nilai_spk']); ?></td>
</tr>
<?php
}
}
?>
</tbody>
</table>
</body>
</html>