#include <infocon.style>
#include "hwdb.inc"
#include "form.inc"

<page func=InfoCon title="Hardware Database">

<?
<dbconnect>

  if ($id) {
    $query = sprintf ("SELECT * FROM types WHERE id = %d", $id);
    $sth = pg_exec ($dbh, $query) or die("Cannot issue query!");

    if (pg_NumRows ($sth) > 0) {
      $row = pg_fetch_array ($sth, 0);
    }
  }
?>

<form method=post action=update.php>
<input type=hidden name=formtype value="type">
<input type=hidden name=id value="<? echo $id; ?>">
<center><table cellpadding=0 cellspacing=1>

<row_input	name=name
		title="<b>Type</b>"
		value="<? echo $row['name']; ?>"
		>

<row_submit>

</table></center></form>

</page>

# Local variables:
# mode: text
# mode: auto-fill
# end:
