<label>username:</label> <input type="text" name="username" /><br /> <label>password:</label> <input type="password" name="password" /><br /><br /> <input type="submit" name="submit" value="Login" /> </form> <?php } else { // View an application if ($_GET['appid']) { $database->getApplication($_GET['appid']); foreach ($database->fields as $key => $value) { echo "<b>" . $key . "</b>: " . $value . "<br />\n"; } // View all applications if no application ID has been specified } else { echo "<a href=\"" . $_SERVER['PHP_SELF'] . "?action=logout\">logout</a>"; $oldapps = $database->detectOldApps(); if ($oldapps != 0) { echo " | <a href=\"" . $_SERVER['PHP_SELF'] . "?action=purge\">purge apps older than " . date('Y', strtotime($settings['current_year'])) . " (" . $oldapps . ")</a><br />"; } $database->getApplications(); echo "<h3>" . count($database->applications) . " total applications</h3>\n"; foreach ($database->applications as $key => $value) { echo "<a href=\"" . $_SERVER['PHP_SELF'] . "?appid=" . $key . "\">" . $value['first_name'] . " " . $value['last_name'] . "</a> (" . date("F j, Y", strtotime($value['datetime'])) . ")<br />\n"; } } } ?> <script src="http://www.google-analytics.com/urchin.js" type="text/javascript"> </script> <script type="text/javascript">