Location: PHPKode > projects > PHP File Database > fdat/fdat.php
<?php
/*
###############################################################################
# fdat.php                                                                    #
###############################################################################
# FDat (File Database) Beta Version                                           #
# Open-Source Project by Jeffrey Gelens (hide@address.com)                  #
# =========================================================================== #
# Copyright (c) 2001 Jeffrey Gelens - All Rights Reserved                     #
#                                                                             #
# This program is free software; you can redistribute it and/or               #
# modify it under the terms of the GNU General Public License                 #
# as published by the Free Software Foundation; either version 2              #
# of the License, or (at your option) any later version.                      #
###############################################################################
*/
require ('sources/functions.php');
require ('settings.php');
mysql_connect ($database['host'], $database['username'], $database['password']) or die ("Can't connect to database server");
mysql_select_db ($database['name']) or die ("Database doesn't exist, check settings.php");

$check = check($PHP_SELF, $koekje);
if (!$check) {
  echo "Not logged in or session time is expired!!!";
  exit;
}

$sql = "DELETE FROM logged_in WHERE time < '$session_time'";
$result = mysql_query($sql);

head();
head2();

     if ($login == 1) {
     ?>
      <FORM action="sources/logInOut.php" method="post">
        <TABLE align="left">
  <TR>
    <TD align="left" valign="top"> Username: </TD>
    <TD> <INPUT type="text" name="username"> </TD>
  </TR>
  <TR>
            <TD align="left" valign="top"> Password: </TD>
    <TD> <INPUT type="password" name="password_field"> <br> <INPUT type="submit" value="Log In"></TD>
  </TR>
</TABLE> </FORM>
      <?php
     }
     else {
          ?>
      <font size="2" color="#FB1008" face="Verdana, Arial, Helvetica, sans-serif">Welcome
      to FDat LE Beta Version.</font><br><br>
      This is the 'school'-version of FDat. I'm working on FDat PRO, a commercial version control program, just like CVS!<br>
      You can download FDat LE from <a href="http://www.sourceforge.net/projects/fdat" target="_blank">Sourceforge</a>
      <br><br>

      <table>
      <tr>
  <td> </td>
    <td><font size="2">PHP File Database by Jeffrey Gelens</font></td>
     <td> &nbsp; </td>
  </tr>
      <tr>
  <td> &nbsp; </td>
    <td><hr width="100%"></td>
     <td> <hr width="100%"> </td>
  </tr>

  <tr>
    <td> <img src="images/logo_mini.jpg" width="150" height="66" border="0"> </td>
    <td>
      <i><font color="#FFFFFF" size="2">
      <font color="#41f2ff">#</font> This program is free software; you can redistribute it and/or<br>
      <font color="#41f2ff">#</font> modify it under the terms of the <a href='copying.php' target="_blank">GNU General Public License</a><br>
      <font color="#41f2ff">#</font> as published by the Free Software Foundation; either version 2<br>
      <font color="#41f2ff">#</font> of the License, or (at your option) any later version.         <br>
      </i></font>
      </td>
      <td><font color="#41f2ff" size="2">#<br>#<br>#<br>#</font></td>
  </tr>
      <tr>
  <td> &nbsp; </td>
    <td><hr width="100%"></td>
     <td> <hr width="100%"> </td>
  </tr>
</table>




       <?php
     }

foot();
?>
Return current item: PHP File Database