forked from DogFrolic/Puppy-Playdate
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.php
30 lines (30 loc) · 939 Bytes
/
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
<?php
require_once "db.php";
session_start();
if ( isset($_SESSION['error']) ) {
echo '<p style="color:red">'.$_SESSION['error']."</p>\n";
unset($_SESSION['error']);
}
if ( isset($_SESSION['success']) ) {
echo '<p style="color:green">'.$_SESSION['success']."</p>\n";
unset($_SESSION['success']);
}
echo '<table border="1">'."\n";
$result = mysql_query("SELECT name, email, password, id FROM users");
/* while ( $row = mysql_fetch_row($result) ) {
echo "<tr><td>";
echo(htmlentities($row[0]));
echo("</td><td>");
echo(htmlentities($row[1]));
echo("</td><td>");
echo(htmlentities($row[2]));
echo("</td><td>\n");
echo('<a href="edit.php?id='.htmlentities($row[3]).'">Edit</a> / ');
echo('<a href="delete.php?id='.htmlentities($row[3]).'">Delete</a>');
echo("</td></tr>\n");
} */
?>
<?php include('nav.php'); ?>
</table>
<a href="add.php">Create Account</a>
<a href="login.php">Login</a>