|
From: Ulf E. <ulf...@us...> - 2005-07-20 18:01:47
|
Update of /cvsroot/phpbt/phpbt/templates/default/admin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28833/admin Modified Files: component-edit.html database-edit.html group-edit.html os-edit.html project-add.html resolution-edit.html severity-edit.html site-edit.html status-edit.html user-edit.html version-edit.html Log Message: Silencing some "undefined variable/index" warnings. Index: component-edit.html =================================================================== RCS file: /cvsroot/phpbt/phpbt/templates/default/admin/component-edit.html,v retrieving revision 1.8 retrieving revision 1.9 diff -u -r1.8 -r1.9 --- component-edit.html 25 Oct 2004 12:07:03 -0000 1.8 +++ component-edit.html 20 Jul 2005 18:01:35 -0000 1.9 @@ -1,3 +1,10 @@ +<?php + if (!isset($component_name)) $component_name = ''; + if (!isset($component_desc)) $component_desc = ''; + if (!isset($owner)) $owner = ''; + if (!isset($active)) $active = ''; + if (!isset($component_id)) $component_id = ''; +?> <script language="JavaScript"> var nameString = '<?php echo translate("Please enter a name"); ?>'; var descString = '<?php echo translate("Please enter a description"); ?>'; Index: database-edit.html =================================================================== RCS file: /cvsroot/phpbt/phpbt/templates/default/admin/database-edit.html,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- database-edit.html 25 Oct 2004 12:07:03 -0000 1.5 +++ database-edit.html 20 Jul 2005 18:01:35 -0000 1.6 @@ -1,53 +1,58 @@ -<script type="text/javascript" language="JavaScript"> - var nameString = '<?php echo translate("Please enter a name"); ?>'; - - function checkForm(frm) { - if (frm.database_name.value == '') { - alert(nameString); - frm.database_name.focus(); - return false; - } - return true; - } -</script> - -<b><?php echo $page_title; ?> </b> -<hr size="1"> -<form method="post" onsubmit="return checkForm(this)"> - <table border='0'> - <?php if ($error) { ?> - <tr> - <td colspan="2" class="error"> - <?php echo $error; ?> - </td> - </tr> - <?php } ?> - <tr> - <td align="right" valign="top"> - <?php echo translate("Name"); ?>: - </td> - <td> - <input type="text" size="20" maxlength="30" name="database_name" value="<?php echo stripslashes(htmlspecialchars($database_name)); ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("Sort Order"); ?>: - </td> - <td> - <input type="text" size="3" maxlength="3" name="sort_order" value="<?php echo $sort_order; ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - - </td> - <td> - <input type='submit' name='submit' value='<?php echo translate("Submit"); ?>'> - <input type="hidden" name="database_id" value="<?php echo $database_id; ?>"> - <input type="hidden" name="use_js" value="<?php echo $_REQUEST['use_js']; ?>"> - <input type="hidden" name="op" value="save"> - </td> - </tr> - </table> -</form> +<?php + if (!isset($database_name)) $database_name = ''; + if (!isset($sort_order)) $sort_order = ''; + if (!isset($database_id)) $database_id = ''; +?> +<script type="text/javascript" language="JavaScript"> + var nameString = '<?php echo translate("Please enter a name"); ?>'; + + function checkForm(frm) { + if (frm.database_name.value == '') { + alert(nameString); + frm.database_name.focus(); + return false; + } + return true; + } +</script> + +<b><?php echo $page_title; ?> </b> +<hr size="1"> +<form method="post" onsubmit="return checkForm(this)"> + <table border='0'> + <?php if ($error) { ?> + <tr> + <td colspan="2" class="error"> + <?php echo $error; ?> + </td> + </tr> + <?php } ?> + <tr> + <td align="right" valign="top"> + <?php echo translate("Name"); ?>: + </td> + <td> + <input type="text" size="20" maxlength="30" name="database_name" value="<?php echo stripslashes(htmlspecialchars($database_name)); ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("Sort Order"); ?>: + </td> + <td> + <input type="text" size="3" maxlength="3" name="sort_order" value="<?php echo $sort_order; ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + + </td> + <td> + <input type='submit' name='submit' value='<?php echo translate("Submit"); ?>'> + <input type="hidden" name="database_id" value="<?php echo $database_id; ?>"> + <input type="hidden" name="use_js" value="<?php echo $_REQUEST['use_js']; ?>"> + <input type="hidden" name="op" value="save"> + </td> + </tr> + </table> +</form> Index: group-edit.html =================================================================== RCS file: /cvsroot/phpbt/phpbt/templates/default/admin/group-edit.html,v retrieving revision 1.7 retrieving revision 1.8 diff -u -r1.7 -r1.8 --- group-edit.html 25 Oct 2004 12:07:03 -0000 1.7 +++ group-edit.html 20 Jul 2005 18:01:35 -0000 1.8 @@ -1,53 +1,58 @@ -<script type="text/javascript" language="JavaScript"> - var nameString = '<?php echo translate("Please enter a name"); ?>'; - - function checkForm(frm) { - if (frm.group_name.value == '') { - alert(nameString); - frm.group_name.focus(); - return false; - } - return true; - } -</script> -<b><?php echo $page_title; ?></b> -<hr size="1"> -<form method="post" onsubmit="return checkForm(this)"> - <table border='0'> - <?php if (!empty($error)) { ?> - <tr> - <td colspan="2" class="error"> - <?php echo $error; ?> - </td> - </tr> - <?php } ?> - <tr> - <td align="right" valign="top"> - Name: - </td> - <td> - <input type="text" size="20" maxlength="40" name="group_name" value="<?php echo stripslashes(htmlspecialchars($group_name)); ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - Assignable: - </td> - <td> - <input type="checkbox" name="assignable" value="1" <?php if ($assignable > 0) echo 'checked'; ?>> - </td> - </tr> - <tr> - <td align="right" valign="top"> - - </td> - <td> - <input type='submit' value='<?php echo translate("Submit"); ?>'> - <input type="hidden" name="op" value="save"> - <input type="hidden" name="group_id" value="<?php echo $group_id; ?>"> - <input type="hidden" name="use_js" value="<?php echo $_REQUEST['use_js']; ?>"> - </td> - </tr> - </table> -</form> - +<?php + if (!isset($group_name)) $group_name = ''; + if (!isset($assignable)) $assignable = ''; + if (!isset($group_id)) $group_id = ''; +?> +<script type="text/javascript" language="JavaScript"> + var nameString = '<?php echo translate("Please enter a name"); ?>'; + + function checkForm(frm) { + if (frm.group_name.value == '') { + alert(nameString); + frm.group_name.focus(); + return false; + } + return true; + } +</script> +<b><?php echo $page_title; ?></b> +<hr size="1"> +<form method="post" onsubmit="return checkForm(this)"> + <table border='0'> + <?php if (!empty($error)) { ?> + <tr> + <td colspan="2" class="error"> + <?php echo $error; ?> + </td> + </tr> + <?php } ?> + <tr> + <td align="right" valign="top"> + Name: + </td> + <td> + <input type="text" size="20" maxlength="40" name="group_name" value="<?php echo stripslashes(htmlspecialchars($group_name)); ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + Assignable: + </td> + <td> + <input type="checkbox" name="assignable" value="1" <?php if ($assignable > 0) echo 'checked'; ?>> + </td> + </tr> + <tr> + <td align="right" valign="top"> + + </td> + <td> + <input type='submit' value='<?php echo translate("Submit"); ?>'> + <input type="hidden" name="op" value="save"> + <input type="hidden" name="group_id" value="<?php echo $group_id; ?>"> + <input type="hidden" name="use_js" value="<?php echo $_REQUEST['use_js']; ?>"> + </td> + </tr> + </table> +</form> + Index: os-edit.html =================================================================== RCS file: /cvsroot/phpbt/phpbt/templates/default/admin/os-edit.html,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- os-edit.html 25 Oct 2004 12:07:03 -0000 1.6 +++ os-edit.html 20 Jul 2005 18:01:35 -0000 1.7 @@ -1,60 +1,66 @@ -<script type="text/javascript" language="JavaScript"> - var nameString = '<?php echo translate("Please enter a name"); ?>'; - - function checkForm(frm) { - if (frm.os_name.value == '') { - alert(nameString); - frm.os_name.focus(); - return false; - } - return true; - } -</script> -<b><?php echo $page_title; ?></b> -<hr size="1"> -<form method="post" onsubmit="return checkForm(this)"> - <table border='0'> - <?php if (!empty($error)) { ?> - <tr> - <td colspan="2" class="error"> - <?php echo $error; ?> - </td> - </tr> - <?php } ?> - <tr> - <td align="right" valign="top"> - <?php echo translate("Name"); ?>: - </td> - <td> - <input type="text" size="20" maxlength="40" name="os_name" value="<?php echo $os_name; ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("Regex"); ?>: - </td> - <td> - <input type="text" size="20" maxlength="40" name="regex" value="<?php echo $regex; ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("Sort Order"); ?>: - </td> - <td> - <input type="text" size="3" maxlength="3" name="sort_order" value="<?php echo $sort_order; ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - - </td> - <td> - <input type='submit' name='submit' value='<?php echo translate("Submit"); ?>'> - <input type="hidden" name="op" value="save"> - <input type="hidden" name="os_id" value="<?php echo $os_id; ?>"> - <input type="hidden" name="use_js" value="<?php echo $_REQUEST['use_js']; ?>"> - </td> - </tr> - </table> -</form> +<?php + if (!isset($os_name)) $os_name = ''; + if (!isset($regex)) $regex = ''; + if (!isset($sort_order)) $sort_order = ''; + if (!isset($os_id)) $os_id = ''; +?> +<script type="text/javascript" language="JavaScript"> + var nameString = '<?php echo translate("Please enter a name"); ?>'; + + function checkForm(frm) { + if (frm.os_name.value == '') { + alert(nameString); + frm.os_name.focus(); + return false; + } + return true; + } +</script> +<b><?php echo $page_title; ?></b> +<hr size="1"> +<form method="post" onsubmit="return checkForm(this)"> + <table border='0'> + <?php if (!empty($error)) { ?> + <tr> + <td colspan="2" class="error"> + <?php echo $error; ?> + </td> + </tr> + <?php } ?> + <tr> + <td align="right" valign="top"> + <?php echo translate("Name"); ?>: + </td> + <td> + <input type="text" size="20" maxlength="40" name="os_name" value="<?php echo $os_name; ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("Regex"); ?>: + </td> + <td> + <input type="text" size="20" maxlength="40" name="regex" value="<?php echo $regex; ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("Sort Order"); ?>: + </td> + <td> + <input type="text" size="3" maxlength="3" name="sort_order" value="<?php echo $sort_order; ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + + </td> + <td> + <input type='submit' name='submit' value='<?php echo translate("Submit"); ?>'> + <input type="hidden" name="op" value="save"> + <input type="hidden" name="os_id" value="<?php echo $os_id; ?>"> + <input type="hidden" name="use_js" value="<?php echo $_REQUEST['use_js']; ?>"> + </td> + </tr> + </table> +</form> Index: project-add.html =================================================================== RCS file: /cvsroot/phpbt/phpbt/templates/default/admin/project-add.html,v retrieving revision 1.7 retrieving revision 1.8 diff -u -r1.7 -r1.8 --- project-add.html 25 Oct 2004 12:07:03 -0000 1.7 +++ project-add.html 20 Jul 2005 18:01:35 -0000 1.8 @@ -1,3 +1,13 @@ +<?php + if (!isset($project_name)) $project_name = ''; + if (!isset($project_desc)) $project_desc = ''; + if (!isset($version_error)) $version_error = ''; + if (!isset($version_name)) $version_name = ''; + if (!isset($component_error)) $component_error = ''; + if (!isset($component_desc)) $component_desc = ''; + if (!isset($component_name)) $component_name = ''; + if (!isset($owner)) $owner = ''; +?> <script language="JavaScript"> <!-- var nameString = '<?php echo translate("Please enter a name"); ?>'; Index: resolution-edit.html =================================================================== RCS file: /cvsroot/phpbt/phpbt/templates/default/admin/resolution-edit.html,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- resolution-edit.html 25 Oct 2004 12:07:03 -0000 1.6 +++ resolution-edit.html 20 Jul 2005 18:01:35 -0000 1.7 @@ -1,68 +1,74 @@ -<script type="text/javascript" language="JavaScript"> - var nameString = '<?php echo translate("Please enter a name"); ?>'; - var descString = '<?php echo translate("Please enter a description"); ?>'; - - function checkForm(frm) { - if (frm.resolution_name.value == '') { - alert(nameString); - frm.resolution_name.focus(); - return false; - } - if (frm.resolution_desc.value == '') { - alert(descString); - frm.resolution_desc.focus(); - return false; - } - return true; - } -</script> -<b><?php echo $page_title; ?> </b> -<hr size="1"> -<form method="post" onsubmit="return checkForm(this)"> - <table border='0'> - <?php if($error) { ?> - <tr> - <td colspan="2" class="error"> - <?php echo $error; ?> - </td> - </tr> - <?php } ?> - <tr> - <td align="right" valign="top"> - <?php echo translate("Name"); ?>: - </td> - <td> - <input type="text" size="20" maxlength="40" name="resolution_name" value="<?php echo stripslashes(htmlspecialchars($resolution_name)); ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("Description"); ?>: - </td> - <td> - <textarea name="resolution_desc" cols="20" rows="5" wrap="virtual"> - <?php echo stripslashes(htmlspecialchars($resolution_desc)); ?> - </textarea> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("Sort Order"); ?>: - </td> - <td> - <input type="text" size="3" maxlength="3" name="sort_order" value="<?php echo $sort_order; ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - - </td> - <td> - <input type='submit' name='submit' value='<?php echo translate("Submit"); ?>'> - <input type="hidden" name="resolution_id" value="<?php echo $resolution_id; ?>"> - <input type="hidden" name="use_js" value="<?php echo $_REQUEST['use_js']; ?>"> - <input type="hidden" name="op" value="save"> - </td> - </tr> - </table> -</form> +<?php + if (!isset($resolution_name)) $resolution_name = ''; + if (!isset($resolution_desc)) $resolution_desc = ''; + if (!isset($sort_order)) $sort_order = ''; + if (!isset($resolution_id)) $resolution_id = ''; +?> +<script type="text/javascript" language="JavaScript"> + var nameString = '<?php echo translate("Please enter a name"); ?>'; + var descString = '<?php echo translate("Please enter a description"); ?>'; + + function checkForm(frm) { + if (frm.resolution_name.value == '') { + alert(nameString); + frm.resolution_name.focus(); + return false; + } + if (frm.resolution_desc.value == '') { + alert(descString); + frm.resolution_desc.focus(); + return false; + } + return true; + } +</script> +<b><?php echo $page_title; ?> </b> +<hr size="1"> +<form method="post" onsubmit="return checkForm(this)"> + <table border='0'> + <?php if($error) { ?> + <tr> + <td colspan="2" class="error"> + <?php echo $error; ?> + </td> + </tr> + <?php } ?> + <tr> + <td align="right" valign="top"> + <?php echo translate("Name"); ?>: + </td> + <td> + <input type="text" size="20" maxlength="40" name="resolution_name" value="<?php echo stripslashes(htmlspecialchars($resolution_name)); ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("Description"); ?>: + </td> + <td> + <textarea name="resolution_desc" cols="20" rows="5" wrap="virtual"> + <?php echo stripslashes(htmlspecialchars($resolution_desc)); ?> + </textarea> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("Sort Order"); ?>: + </td> + <td> + <input type="text" size="3" maxlength="3" name="sort_order" value="<?php echo $sort_order; ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + + </td> + <td> + <input type='submit' name='submit' value='<?php echo translate("Submit"); ?>'> + <input type="hidden" name="resolution_id" value="<?php echo $resolution_id; ?>"> + <input type="hidden" name="use_js" value="<?php echo $_REQUEST['use_js']; ?>"> + <input type="hidden" name="op" value="save"> + </td> + </tr> + </table> +</form> Index: severity-edit.html =================================================================== RCS file: /cvsroot/phpbt/phpbt/templates/default/admin/severity-edit.html,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- severity-edit.html 25 Oct 2004 12:07:03 -0000 1.6 +++ severity-edit.html 20 Jul 2005 18:01:35 -0000 1.7 @@ -1,77 +1,84 @@ -<script type="text/javascript" language="JavaScript"> - var nameString = '<?php echo translate("Please enter a name"); ?>'; - var descString = '<?php echo translate("Please enter a description"); ?>'; - - function checkForm(frm) { - if (frm.severity_name.value == '') { - alert(nameString); - frm.severity_name.focus(); - return false; - } - if (frm.severity_desc.value == '') { - alert(descString); - frm.severity_desc.focus(); - return false; - } - return true; - } -</script> -<b><?php echo $page_title; ?> </b> -<hr size="1"> -<form method="post" onsubmit="return checkForm(this)"> - <table border='0'> - <?php if($error) { ?> - <tr> - <td colspan="2" class="error"> - <?php echo $error; ?> - </td> - </tr> - <?php } ?> - <tr> - <td align="right" valign="top"> - <?php echo translate("Name"); ?>: - </td> - <td> - <input type="text" size="20" maxlength="40" name="severity_name" value="<?php echo stripslashes(htmlspecialchars($severity_name)); ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("Description"); ?>: - </td> - <td> - <textarea name="severity_desc" cols="20" rows="5" wrap="virtual"><?php echo stripslashes(htmlspecialchars($severity_desc)); ?> - </textarea> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("Sort Order"); ?>: - </td> - <td> - <input type="text" size="3" maxlength="3" name="sort_order" value="<?php echo $sort_order; ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("Row Color"); ?>: - </td> - <td> - <input type="text" size="11" maxlength="10" name="severity_color" value="<?php echo $severity_color; ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - - </td> - <td> - <input type='submit' name='submit' value='<?php echo translate("Submit"); ?>'> - <input type="hidden" name="severity_id" value="<?php echo $severity_id; ?>"> - <input type="hidden" name="use_js" value="<?php echo $_REQUEST['use_js']; ?>"> - <input type="hidden" name="op" value="save"> - </td> - </tr> - </table> - - <br> -</form> +<?php + if (!isset($severity_name)) $severity_name = ''; + if (!isset($severity_desc)) $severity_desc = ''; + if (!isset($sort_order)) $sort_order = ''; + if (!isset($severity_color)) $severity_color = ''; + if (!isset($severity_id)) $severity_id = ''; +?> +<script type="text/javascript" language="JavaScript"> + var nameString = '<?php echo translate("Please enter a name"); ?>'; + var descString = '<?php echo translate("Please enter a description"); ?>'; + + function checkForm(frm) { + if (frm.severity_name.value == '') { + alert(nameString); + frm.severity_name.focus(); + return false; + } + if (frm.severity_desc.value == '') { + alert(descString); + frm.severity_desc.focus(); + return false; + } + return true; + } +</script> +<b><?php echo $page_title; ?> </b> +<hr size="1"> +<form method="post" onsubmit="return checkForm(this)"> + <table border='0'> + <?php if($error) { ?> + <tr> + <td colspan="2" class="error"> + <?php echo $error; ?> + </td> + </tr> + <?php } ?> + <tr> + <td align="right" valign="top"> + <?php echo translate("Name"); ?>: + </td> + <td> + <input type="text" size="20" maxlength="40" name="severity_name" value="<?php echo stripslashes(htmlspecialchars($severity_name)); ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("Description"); ?>: + </td> + <td> + <textarea name="severity_desc" cols="20" rows="5" wrap="virtual"><?php echo stripslashes(htmlspecialchars($severity_desc)); ?> + </textarea> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("Sort Order"); ?>: + </td> + <td> + <input type="text" size="3" maxlength="3" name="sort_order" value="<?php echo $sort_order; ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("Row Color"); ?>: + </td> + <td> + <input type="text" size="11" maxlength="10" name="severity_color" value="<?php echo $severity_color; ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + + </td> + <td> + <input type='submit' name='submit' value='<?php echo translate("Submit"); ?>'> + <input type="hidden" name="severity_id" value="<?php echo $severity_id; ?>"> + <input type="hidden" name="use_js" value="<?php echo $_REQUEST['use_js']; ?>"> + <input type="hidden" name="op" value="save"> + </td> + </tr> + </table> + + <br> +</form> Index: site-edit.html =================================================================== RCS file: /cvsroot/phpbt/phpbt/templates/default/admin/site-edit.html,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- site-edit.html 25 Oct 2004 12:07:03 -0000 1.3 +++ site-edit.html 20 Jul 2005 18:01:35 -0000 1.4 @@ -1,54 +1,59 @@ -<script type="text/javascript" language="JavaScript"> - var nameString = '<?php echo translate("Please enter a name"); ?>'; - - function checkForm(frm) { - if (frm.site_name.value == '') { - alert(nameString); - frm.site_name.focus(); - return false; - } - return true; - } -</script> -<b><?php echo $page_title; ?> </b> -<hr size="1"> -<form method="post" onsubmit="return checkForm(this)"> - <table border='0'> - <?php if($error) { ?> - <tr> - <td colspan="2" class="error"> - <?php echo $error; ?> - </td> - </tr> - <?php } ?> - <tr> - <td align="right" valign="top"> - <?php echo translate("Name"); ?>: - </td> - <td> - <input type="text" size="20" maxlength="50" name="site_name" value="<?php echo stripslashes(htmlspecialchars($site_name)); ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("Sort Order"); ?>: - </td> - <td> - <input type="text" size="3" maxlength="3" name="sort_order" value="<?php echo $sort_order; ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - - </td> - <td> - <input type="submit" name="<?php echo translate("Submit"); ?>"> - <input type="hidden" name="site_id" value="<?php echo $site_id; ?>"> - <input type="hidden" name="use_js" value="<?php echo $_REQUEST['use_js']; ?>"> - <input type="hidden" name="op" value="save"> - </td> - </tr> - </table> -</form> - - +<?php + if (!isset($site_name)) $site_name = ''; + if (!isset($sort_order)) $sort_order = ''; + if (!isset($site_id)) $site_id = ''; +?> +<script type="text/javascript" language="JavaScript"> + var nameString = '<?php echo translate("Please enter a name"); ?>'; + + function checkForm(frm) { + if (frm.site_name.value == '') { + alert(nameString); + frm.site_name.focus(); + return false; + } + return true; + } +</script> +<b><?php echo $page_title; ?> </b> +<hr size="1"> +<form method="post" onsubmit="return checkForm(this)"> + <table border='0'> + <?php if($error) { ?> + <tr> + <td colspan="2" class="error"> + <?php echo $error; ?> + </td> + </tr> + <?php } ?> + <tr> + <td align="right" valign="top"> + <?php echo translate("Name"); ?>: + </td> + <td> + <input type="text" size="20" maxlength="50" name="site_name" value="<?php echo stripslashes(htmlspecialchars($site_name)); ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("Sort Order"); ?>: + </td> + <td> + <input type="text" size="3" maxlength="3" name="sort_order" value="<?php echo $sort_order; ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + + </td> + <td> + <input type="submit" name="<?php echo translate("Submit"); ?>"> + <input type="hidden" name="site_id" value="<?php echo $site_id; ?>"> + <input type="hidden" name="use_js" value="<?php echo $_REQUEST['use_js']; ?>"> + <input type="hidden" name="op" value="save"> + </td> + </tr> + </table> +</form> + + Index: status-edit.html =================================================================== RCS file: /cvsroot/phpbt/phpbt/templates/default/admin/status-edit.html,v retrieving revision 1.8 retrieving revision 1.9 diff -u -r1.8 -r1.9 --- status-edit.html 25 Oct 2004 12:07:03 -0000 1.8 +++ status-edit.html 20 Jul 2005 18:01:35 -0000 1.9 @@ -1,75 +1,81 @@ -<script type="text/javascript" language="JavaScript"> - var nameString = '<?php echo translate("Please enter a name"); ?>'; - var descString = '<?php echo translate("Please enter a description"); ?>'; - - function checkForm(frm) { - if (frm.status_name.value == '') { - alert(nameString); - frm.status_name.focus(); - return false; - } - if (frm.status_desc.value == '') { - alert(descString); - frm.status_desc.focus(); - return false; - } - return true; - } -</script> -<b><?php echo $page_title; ?> </b> -<hr size="1"> -<form method="post" onsubmit="return checkForm(this)"> - <table border='0'> - <?php if($error) { ?> - <tr> - <td colspan="2" class="error"> - <?php echo $error; ?> - </td> - </tr> - <?php } ?> - <tr> - <td align="right" valign="top"> - <?php echo translate("Name"); ?>: - </td> - <td> - <input type="text" size="20" maxlength="40" name="status_name" value="<?php echo stripslashes(htmlspecialchars($status_name)); ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("Description"); ?>: - </td> - <td> - <textarea name="status_desc" cols="20" rows="5" wrap="virtual"><?php echo stripslashes(htmlspecialchars($status_desc)); ?></textarea> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("Sort Order"); ?>: - </td> - <td> - <input type="text" size="3" maxlength="3" name="sort_order" value="<?php echo $sort_order; ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("Open/Closed"); ?>: - </td> - <td> - <input type="radio" name="bug_open" value="1" <?php echo $bug_open ? ' checked="checked"' : ''; ?>> <?php echo translate("Open"); ?> <input type="radio" name="bug_open" value="0" <?php echo $bug_open ? '' : ' checked="checked"'; ?>> <?php echo translate("Closed"); ?> - </td> - </tr> - <tr> - <td align="right" valign="top"> - - </td> - <td> - <input type='submit' name='submit' value='<?php echo translate("Submit"); ?>'> - <input type="hidden" name="status_id" value="<?php echo $status_id; ?>"> - <input type="hidden" name="use_js" value="<?php echo $_REQUEST['use_js']; ?>"> - <input type="hidden" name="op" value="save"> - </td> - </tr> - </table> -</form> - +<?php + if (!isset($status_name)) $status_name = ''; + if (!isset($status_desc)) $status_desc = ''; + if (!isset($sort_order)) $sort_order = ''; + if (!isset($status_id)) $status_id = ''; +?> +<script type="text/javascript" language="JavaScript"> + var nameString = '<?php echo translate("Please enter a name"); ?>'; + var descString = '<?php echo translate("Please enter a description"); ?>'; + + function checkForm(frm) { + if (frm.status_name.value == '') { + alert(nameString); + frm.status_name.focus(); + return false; + } + if (frm.status_desc.value == '') { + alert(descString); + frm.status_desc.focus(); + return false; + } + return true; + } +</script> +<b><?php echo $page_title; ?> </b> +<hr size="1"> +<form method="post" onsubmit="return checkForm(this)"> + <table border='0'> + <?php if($error) { ?> + <tr> + <td colspan="2" class="error"> + <?php echo $error; ?> + </td> + </tr> + <?php } ?> + <tr> + <td align="right" valign="top"> + <?php echo translate("Name"); ?>: + </td> + <td> + <input type="text" size="20" maxlength="40" name="status_name" value="<?php echo stripslashes(htmlspecialchars($status_name)); ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("Description"); ?>: + </td> + <td> + <textarea name="status_desc" cols="20" rows="5" wrap="virtual"><?php echo stripslashes(htmlspecialchars($status_desc)); ?></textarea> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("Sort Order"); ?>: + </td> + <td> + <input type="text" size="3" maxlength="3" name="sort_order" value="<?php echo $sort_order; ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("Open/Closed"); ?>: + </td> + <td> + <input type="radio" name="bug_open" value="1" <?php echo $bug_open ? ' checked="checked"' : ''; ?>> <?php echo translate("Open"); ?> <input type="radio" name="bug_open" value="0" <?php echo $bug_open ? '' : ' checked="checked"'; ?>> <?php echo translate("Closed"); ?> + </td> + </tr> + <tr> + <td align="right" valign="top"> + + </td> + <td> + <input type='submit' name='submit' value='<?php echo translate("Submit"); ?>'> + <input type="hidden" name="status_id" value="<?php echo $status_id; ?>"> + <input type="hidden" name="use_js" value="<?php echo $_REQUEST['use_js']; ?>"> + <input type="hidden" name="op" value="save"> + </td> + </tr> + </table> +</form> + Index: user-edit.html =================================================================== RCS file: /cvsroot/phpbt/phpbt/templates/default/admin/user-edit.html,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- user-edit.html 25 Oct 2004 12:07:03 -0000 1.4 +++ user-edit.html 20 Jul 2005 18:01:35 -0000 1.5 @@ -1,114 +1,122 @@ -<script type="text/javascript" language="JavaScript"> -<!-- - var hadAdmin = <?php echo $hadadmin; ?>; - var numAdmins = <?php echo $numadmins; ?>; - - function checkAdmin(slct) { - var adminSelected = false; - - if (hadAdmin && numAdmins == 1) { - for (current = 0; current < slct.options.length; current++ ) { - if (slct.options[current].selected && slct.options[current].value == 1) { - adminSelected = true; - } - } - if (!adminSelected) { - alert('This is the only admin user for the system. Removing this user from the Admin group would be unwise.'); - } - } - } -// --> -</script> -<b><?php echo $page_title; ?> </b> -<hr size="1"> -<form action="user.php" method="post"> - <table border='0'> - <?php if($error) { ?> - <tr> - <td colspan="2" class="error"> - <?php echo $error; ?> - </td> - </tr> - <?php } ?><?php if(!EMAIL_IS_LOGIN) { ?> - <tr> - <td align="right" valign="top"> - <?php echo translate("Login"); ?>: - </td> - <td> - <input type="text" size="20" maxlength="40" name="login" value="<?php echo stripslashes(htmlspecialchars($login)); ?>"> - </td> - </tr> - <?php } ?> - <tr> - <td align="right" valign="top"> - <?php echo translate("Email"); ?>: - </td> - <td> - <input type="text" size="20" maxlength="40" name="email" value="<?php echo $email; ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("First Name"); ?>: - </td> - <td> - <input type="text" size="20" maxlength="40" name="first_name" value="<?php echo stripslashes(htmlspecialchars($first_name)); ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("Last Name"); ?>: - </td> - <td> - <input type="text" size="20" maxlength="40" name="last_name" value="<?php echo stripslashes(htmlspecialchars($last_name)); ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("Password"); ?>: - </td> - <td> - <input type="text" size="20" maxlength="40" name="password" value="<?php echo $password; ?>"> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("User Groups"); ?>: - </td> - <td> - <select name="fusergroup[]" size="5" multiple onclick="checkAdmin(this)"> - <?php build_select('group', $user_groups); ?> - </select> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("Active"); ?>: - </td> - <td> - <input type="checkbox" name="active" value="1" <?php echo $active ? 'checked' : ''; ?>> - </td> - </tr> - <tr> - <td align="right" valign="top"> - <?php echo translate("Email Notify"); ?>: - </td> - <td> - <input type="checkbox" name="fe_notice" value="1" <?php echo $email_notices ? 'checked' : ''; ?>> - </td> - </tr> - <tr> - <td align="right" valign="top"> - - </td> - <td> - <input type='submit' name='submit' value='<?php echo translate("Submit"); ?>'> - <input type="hidden" name="user_id" value="<?php echo $user_id; ?>"> - <input type="hidden" name="filter" value="<?php echo $_REQUEST['filter']; ?>"> - <input type="hidden" name="use_js" value="<?php echo $_REQUEST['use_js']; ?>"> - <input type="hidden" name="op" value="save"> - </td> - </tr> - </table> -</form> - +<?php + if (!isset($email)) $email = ''; + if (!isset($first_name)) $first_name = ''; + if (!isset($last_name)) $last_name = ''; + if (!isset($active)) $active = ''; + if (!isset($email_notices)) $email_notices = ''; + if (!isset($user_id)) $user_id = ''; +?> +<script type="text/javascript" language="JavaScript"> +<!-- + var hadAdmin = <?php echo $hadadmin; ?>; + var numAdmins = <?php echo $numadmins; ?>; + + function checkAdmin(slct) { + var adminSelected = false; + + if (hadAdmin && numAdmins == 1) { + for (current = 0; current < slct.options.length; current++ ) { + if (slct.options[current].selected && slct.options[current].value == 1) { + adminSelected = true; + } + } + if (!adminSelected) { + alert('This is the only admin user for the system. Removing this user from the Admin group would be unwise.'); + } + } + } +// --> +</script> +<b><?php echo $page_title; ?> </b> +<hr size="1"> +<form action="user.php" method="post"> + <table border='0'> + <?php if(isset($error)) { ?> + <tr> + <td colspan="2" class="error"> + <?php echo $error; ?> + </td> + </tr> + <?php } ?><?php if(!EMAIL_IS_LOGIN) { ?> + <tr> + <td align="right" valign="top"> + <?php echo translate("Login"); ?>: + </td> + <td> + <input type="text" size="20" maxlength="40" name="login" value="<?php echo stripslashes(htmlspecialchars($login)); ?>"> + </td> + </tr> + <?php } ?> + <tr> + <td align="right" valign="top"> + <?php echo translate("Email"); ?>: + </td> + <td> + <input type="text" size="20" maxlength="40" name="email" value="<?php echo $email; ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("First Name"); ?>: + </td> + <td> + <input type="text" size="20" maxlength="40" name="first_name" value="<?php echo stripslashes(htmlspecialchars($first_name)); ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("Last Name"); ?>: + </td> + <td> + <input type="text" size="20" maxlength="40" name="last_name" value="<?php echo stripslashes(htmlspecialchars($last_name)); ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("Password"); ?>: + </td> + <td> + <input type="text" size="20" maxlength="40" name="password" value="<?php echo $password; ?>"> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("User Groups"); ?>: + </td> + <td> + <select name="fusergroup[]" size="5" multiple onclick="checkAdmin(this)"> + <?php build_select('group', $user_groups); ?> + </select> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("Active"); ?>: + </td> + <td> + <input type="checkbox" name="active" value="1" <?php echo $active ? 'checked' : ''; ?>> + </td> + </tr> + <tr> + <td align="right" valign="top"> + <?php echo translate("Email Notify"); ?>: + </td> + <td> + <input type="checkbox" name="fe_notice" value="1" <?php echo $email_notices ? 'checked' : ''; ?>> + </td> + </tr> + <tr> + <td align="right" valign="top"> + + </td> + <td> + <input type='submit' name='submit' value='<?php echo translate("Submit"); ?>'> + <input type="hidden" name="user_id" value="<?php echo $user_id; ?>"> + <input type="hidden" name="filter" value="<?php echo (isset($_REQUEST['filter']) ? $_REQUEST['filter'] : ''); ?>"> + <input type="hidden" name="use_js" value="<?php echo (isset($_REQUEST['use_js']) ? $_REQUEST['use_js'] : ''); ?>"> + <input type="hidden" name="op" value="save"> + </td> + </tr> + </table> +</form> + Index: version-edit.html =================================================================== RCS file: /cvsroot/phpbt/phpbt/templates/default/admin/version-edit.html,v retrieving revision 1.8 retrieving revision 1.9 diff -u -r1.8 -r1.9 --- version-edit.html 25 Oct 2004 12:07:03 -0000 1.8 +++ version-edit.html 20 Jul 2005 18:01:35 -0000 1.9 @@ -1,3 +1,8 @@ +<?php + if (!isset($version_name)) $version_name = ''; + if (!isset($active)) $active = ''; + if (!isset($version_id)) $version_id = ''; +?> <script language="JavaScript"> var nameString = '<?php echo translate("Please enter a version"); ?>'; |