NIM : 18611152
Basis Data ~Statistik (C)
1. Db_connect.php
<?php
$kon = mysqli_connect('localhost','root','');
?>
2. Index.php
<?php
include "db_connect.php";
$jumlah = mysqli_num_rows($query);
echo "<html>";
echo "<head>";
echo "</head>";
echo "<body>";
</tr>";
$j=0;
while ($row=mysqli_fetch_array($query)) {
echo $j+1;
echo"</font>";
echo"</td>";
echo $row["judul"];
echo"</font>";
echo"</td>";
echo $row["penulis"];
echo"</font>";
echo"</td>";
echo $row["penerbit"];
echo"</font>";
echo"</td>";
echo"</table>";
echo "</body>";
echo "</html>";
?>
3. Style.css
<?php
include "db_connect.php";
$jumlah = mysqli_num_rows($query);
echo "<html>";
echo "<head>";
echo "</head>";
echo "<body>";
$j=0;
while ($row=mysqli_fetch_array($query)) {
echo $j+1;
echo"</font>";
echo"</td>";
echo $row["judul"];
echo"</font>";
echo"</td>";
echo $row["penulis"];
echo"</font>";
echo"</td>";
echo $row["penerbit"];
echo"</font>";
echo"</td>";
echo"</table>";
echo "</body>";
echo "</html>";
?>
4. Add.php
<html>
<head>
</head>
<body>
<table align="left">
<tr>
<td>:</td>
</tr>
<tr>
<td>:</td>
</tr>
<tr>
<td>:</td>
</tr>
<tr>
<td></td><td></td>
</td>
</tr>
</table>
</form>
</body>
</html>
5. Insert_koleksi.php
<?php
include "db_connect.php";
$judul = $_POST['judul'];
$penulis = $_POST['penulis'];
$penerbit = $_POST['penerbit'];
if($query) {
?>
<script language="JavaScript">
document.location='index.php'</script>
<?php
?>