-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain_index.php
67 lines (62 loc) · 1.47 KB
/
main_index.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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
<?php
session_start();
if (!isset($_SESSION['username'])) {
header('Location: index.php');
}
?>
<html>
<head>
<title>Beranda - AccessNetLab</title>
</head>
<body>
<center><h1>Selamat Datang,<br>
Silahkan Masukan Data Barang Yang Anda Pinjam<br>
<a href="logout.php">Logout</a></h1></center>
<!-- Menampilkan Pesan Sukses -->
<?php
if (!empty($_GET['message']) && $_GET['message'] == 'success') {
echo '<center><h3>Berhasil Menginput Data!</h3></center>';
}
?>
<table border="0" align="center" bgcolor="#FFFFFF">
<tr>
<form name="form_penginputan" method="post" action="input_data.php">
<td>
<table>
<tr>
<td>Username</td>
<td>:</td>
<td><input name="username" type="text" value=" <?php echo $_SESSION['username'] ?>" ></td>
</tr>
<tr>
<td>Nama Barang</td>
<td>:</td>
<td><input name="namabarang" type="text" required="required"></td>
</tr>
<tr>
<td>Tanggal</td>
<td>:</td>
<td><input name="tanggal" type="date" required="required"></td>
</tr>
<tr>
<td>Jumlah</td>
<td>:</td>
<td><input name="jumlah" type="number" required="required"></td>
</tr>
<tr>
<td>Digunakan Untuk</td>
<td>:</td>
<td><textarea name="keperluan" rows="4" cols="22"></textarea></td>
</tr>
<tr>
<td> </td>
<td> </td>
<td><input type="submit" name="Submit" value="Input Data"></td>
</tr>
</table>
</td>
</form>
</tr>
</table>
</body>
</html>