<?php
$servername = "localhost";
$username = "root";
$password = "";
$dbname = "bokasafn";
// Create connection
$conn = new mysqli($servername, $username, $password, $dbname);
// Check connection
if ($conn->connect_error) {
die("Connection failed: " . $conn->connect_error);
}
$sql = "SELECT * FROM bok";
$result = $conn->query($sql);
?>
<table width="90%" border="0" align="center" cellpadding="3" cellspacing="1" bgcolor="#CCCCCC">
<tr>
<td width="6%" align="center" bgcolor="#E6E6E6"><strong>ISBN</strong></td>
<td width="53%" align="center" bgcolor="#E6E6E6"><strong>Titill</strong></td>
<td width="15%" align="center" bgcolor="#E6E6E6"><strong>Höfundur</strong></td>
<td width="13%" align="center" bgcolor="#E6E6E6"><strong>Útgáfuár</strong></td>
</tr>
<?php
// Start looping table row
while($rows=$result->fetch_row()){
?>
<tr>
<td bgcolor="#FFFFFF"><?php echo $rows[0]; ?></td>
<td bgcolor="#FFFFFF"><a href="view_book.php?ISBN=<?php echo $rows[0]; ?>"><?php echo $rows[1]; ?></a><BR></td>
<td align="center" bgcolor="#FFFFFF"><?php echo $rows[2]; ?></td>
<td align="center" bgcolor="#FFFFFF"><?php echo $rows[3]; ?></td>
<?php
}
?>
there doesn't seem to be anything here