Subversion Repositories computer_asset_manager_v2

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
1 rodolico 1
<?php 
2
   include_once( 'header.php' ); 
3
   include_once( 'DBDatabase.class.php' );
4
?>
5
<?xml version="1.0" encoding="utf-8"?>
6
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
7
<html xmlns="http://www.w3.org/1999/xhtml">
8
<head>
9
  <title>Daily Data - Computer Asset Management Program</title>
10
  <link rel="stylesheet" type="text/css" href="camp.css">
11
</head>
12
<body>
13
<?php 
14
 
15
  include_once('menu.php'); 
16
?>
17
<div id="content">
18
<?php
19
  global $DATABASE_DEFINITION;
20
  $camp = new DBDatabase( 'camp', $DATABASE_DEFINITION );
21
  if ( isset( $_REQUEST['table'] ) ) {
22
     $table = $camp->getTable($_REQUEST['table']);
23
     if ( $_REQUEST['id'] ) {
24
        $record = new DBRecord( $table, array( 'id' => $_REQUEST['id'] ) );
25
        $record->loadFromDatabase();
26
        print $record->toHTML();
27
        //print "<pre>" . print_r($record, true) . "</pre>";
28
     } else {
29
        print $table->toHTML(  );
30
     }
31
   }  else {
32
     print $camp->toHTML();
33
  }
34
?>
35
</div>
36
</body>
37
</html>
38