Пример #1
0
}
begin_table(5);
// ethaddr char(17)
print_field("ethaddr", $row, 17);
// date date
print_field("date", $row);
// batch char(32)
print_field("batch", $row, 32);
// type enum('IO','CLP','DSP','INPUT','ALT-INPUT','DISPLAY')
print_enum("type", $row, $type_vals);
// rev tinyint(3) unsigned zerofill
print_field("rev", $row, 3, 'rev_filter');
// location char(64)
print_field("location", $row, 64);
// comments text
print_field_multiline("comments", $row, 60, 10, 'text_filter');
// sdram[0-3] enum('32M','64M','128M','256M')
print_enum_multi("sdram", $row, $sdram_vals, 4, array());
// flash[0-3] enum('4M','8M','16M','32M','64M')
print_enum_multi("flash", $row, $flash_vals, 4, array());
// zbt[0-f] enum('512K','1M','2M','4M')
print_enum_multi("zbt", $row, $zbt_vals, 16, array());
// xlxtyp[0-3] enum('XCV300E','XCV400E','XCV600E')
print_enum_multi("xlxtyp", $row, $xlxtyp_vals, 4, array(), 1);
// xlxspd[0-3] enum('6','7','8')
print_enum_multi("xlxspd", $row, $xlxspd_vals, 4, array(), 1);
// xlxtmp[0-3] enum('COM','IND')
print_enum_multi("xlxtmp", $row, $xlxtmp_vals, 4, array(), 1);
// xlxgrd[0-3] enum('NORMAL','ENGSAMP')
print_enum_multi("xlxgrd", $row, $xlxgrd_vals, 4, array(), 1);
// cputyp enum('MPC8260(HIP3)','MPC8260A(HIP4)','MPC8280(HIP7)')
Пример #2
0
if (isset($_REQUEST['logno'])) {
    $logno = $_REQUEST['logno'];
    die("log number must not be specified when adding! ({$logno})");
}
?>
<form action=donewlog.php method=POST>
<p></p>
<?php 
echo "<input type=hidden name=serno value={$serno}>\n";
begin_table(3);
// date date
print_field("date", array('date' => date("Y-m-d")));
// who char(20)
print_field("who", array());
// details text
print_field_multiline("details", array(), 60, 10, 'text_filter');
end_table();
?>
<p></p>
<table width="100%">
<tr>
  <td align=center>
    <input type=submit value="Add Log Entry">
  </td>
  <td align=center>
    <input type=reset value="Reset Form Contents">
  </td>
</tr>
</table>
</form>
<?php 
Пример #3
0
<form action=doedlog.php method=POST>
<?php 
echo "<input type=hidden name=serno value={$serno}>\n";
echo "<input type=hidden name=logno value={$logno}>\n";
$r = mysql_query("select * from log where serno={$serno} and logno={$logno}");
$row = mysql_fetch_array($r);
if (!$row) {
    die("no record of log entry with serial number '{$serno}' " . "and log number '{$logno}' in database");
}
begin_table(3);
// date date
print_field("date", $row);
// who char(20)
print_field("who", $row);
// details text
print_field_multiline("details", $row, 60, 10, 'text_filter');
end_table();
echo "<p>\n";
echo "<center><b>";
echo "<font color=#ff0000>WARNING: NO UNDO ON DELETE!</font>";
echo "<br></br>\n";
echo "<tt>[ <a href=\"dodellog.php?serno={$serno}&logno={$logno}\">delete</a> ]</tt>";
echo "</b></center>\n";
echo "</p>\n";
?>
<p>
<table align=center width="100%">
<tr>
  <td align=center>
    <input type=submit value=Edit>
  </td>