***********************
** FILE NAME : classes.php
** SYSTEM NAME : Gnucomo - Gnu Computer Monitoring
-** VERSION NUMBER : $Revision: 1.1 $
+** VERSION NUMBER : $Revision: 1.2 $
**
** DESCRIPTION : Parameter classes Administration page.
** Input parameters: action (POST) : empty, 'Create'
/*****************************
$Log: classes.php,v $
- Revision 1.1 2005-06-04 07:22:40 arjen
+ Revision 1.2 2007-11-21 14:38:06 arjen
+ The buttonbar at the top of each page is now a fixed 'div' element
+ instead of a framed page.
+ Contributed by Edwin Nadorp.
+
+ Revision 1.1 2005/06/04 07:22:40 arjen
New page: Parameter classes administration.
******************************/
-// RCSID = "$Id: classes.php,v 1.1 2005-06-04 07:22:40 arjen Exp $";
+// RCSID = "$Id: classes.php,v 1.2 2007-11-21 14:38:06 arjen Exp $";
ini_set('include_path', '.:./classes:../phpclasses');
?>
-<script language='JavaScript'>
+<script type='text/ecmascript'>
function CheckCreate(f)
{
if (isset($_GET['classname']) && isset($_GET['propname']))
{
- echo "<h1>Detailed information for property " . $_GET['propname']
+ echo "<script type='text/ecmascript'>document.getElementById('menu_title').innerHTML = '<h1>Detailed information<\/h1>'</script><br>";
+ echo "<h1>for property " . $_GET['propname']
. " of class " . $_GET['classname'] . "</h1><br>\n";
if (isset($_POST['action']) && $_POST['action'] == 'Save Changes')
. "' AND property_name='" . $_GET['propname'] . "'");
$cls = pg_fetch_object($res, 0);
- echo "<form action='classes.php?classname=" . $cls->name . "&propname=" . $cls->property_name . "' method='POST'>";
+ echo "<form action='classes.php?classname=" . $cls->name . "&propname=" . $cls->property_name . "' method='POST'>";
echo "<table>";
echo "<tr><td>Description</td><td><input name='description' type='text' value='";
}
else
{
- echo "<h1>Parameter Classes Administration</h1><hr>";
+ echo "<script type='text/ecmascript'>document.getElementById('menu_title').innerHTML = '<h1>Parameter Classes Administration<\/h1>'</script><br>";
$res = pg_exec($this->database, "SELECT name, property_name, description FROM parameter_class
ORDER BY name, property_name");
echo "<table>";
- echo "<tr><th>Class</th><th>Property</th><th>Description</th><tr>";
+ echo "<tr><th>Class</th><th>Property</th><th>Description</th></tr>";
$cls = 0;
while ($cls < pg_numrows($res))
{
$u = pg_fetch_object($res, $cls);
?>
- <tr><td align='center'><a href='classes.php?classname=<?php echo $u->name?>&propname=<?php echo $u->property_name ?>'><img src='change.png'></a><br>
+ <tr><td align='center'><a href='classes.php?classname=<?php echo $u->name?>&propname=<?php echo $u->property_name ?>'><img src='change.png'></a><br>
<b><?php echo $u->name ?></b>
</td><td>
<?php echo $u->property_name ?>
?>
<h2>Create new parameter class property:</h2>
-<p>
<form action='classes.php' method='post' onSubmit='return CheckCreate(this)'>
Class name: <input name='classname' type='text'>
<br>
<input type='submit' name='action' value='Create'>
</form>
-</p>
<?php
}