
<!--jscript-->
<script language="javascript" src="../jscript/calendar.js"></script>
<script src="../jscript/nicEdit.js" type="text/javascript"></script>
<script type="text/javascript">
bkLib.onDomLoaded(function() {
  new nicEditor().panelInstance('warning_text');
  //new nicEditor({fullPanel : true}).panelInstance('warning_text');
  //new nicEditor({iconsPath : '../jscript/nicEditorIcons.gif'}).panelInstance('warning_text');
  //new nicEditor({buttonList : ['fontSize','bold','italic','underline','strikeThrough','subscript','superscript','html','image']}).panelInstance('warning_text');
  //new nicEditor({maxHeight : 100}).panelInstance('warning_text');
});
</script>
<?php 

$table_name = $_SESSION['db_prefix']."_list_names_discipline";
    $position_query = "SELECT item_name FROM $table_name ORDER BY item_name ASC";
  $arrId1 = array ();
  $arrName1 = array ();
  $position_result = execsql($position_query);
  if ($position_result!="") {
  $position_num = mysql_num_rows($position_result);
  $b = 0;
  while ($b < $position_num) {
    $arrId1[$b] = mysql_result($position_result, $b, "item_name");
    $arrName1[$b] = mysql_result($position_result, $b, "item_name");
    $b++;
  }
  }

require_once('../include/tc_calendar.php');
$exp_date = strtotime($_SESSION['exp_date']);
$d = date("d", $exp_date );
$m = date("m", $exp_date );
$y = date("Y", $exp_date );

?>


</head>
<?php include('../include/wait.php') ?>
<body onLoad="MM_showHideLayers('wait','','hide')" onFocus="MM_showHideLayers('wait','','hide');">


<div class="wizard_page_middle_frame">
<form id="feedbackform" method="POST" action="warningWizbase.php?p=4&s=3"  >
     <div class="wizard_frame">
            
            <table width="612" id="table_display_wizard">
              <tr>
                <td valign="top">Warning:&nbsp;&nbsp;<label class="star">*<br>
                </label><textarea name="warning_text" cols="70" rows="5" id="warning_text" style="width:600px; min-height:400px;"><?php echo $_SESSION['warning_text'] ?> </textarea></td>
              </tr>
            </table>
    </div>
          <div class="wizard_frame">
              <table width="613" height="145" id="table_display_wizard">
                <tr>
                  <td width="165" height="45" valign="middle"><label class="label_std">Expiry Date of warning:</label>
&nbsp;&nbsp;
</td>
                  <td width="252" valign="middle"><div id='calendar_div' onClick="document.getElementById('period_div').hidden=true;"><?php 
          //instantiate class and set properties
    $myCalendar = new tc_calendar("exp_date", true);
    $myCalendar->setIcon("../images/iconCalendar.gif");
    $myCalendar->setDate($d, $m, $y);
    $myCalendar->setYearInterval(2010, 2099);
    //output the calendar
    $myCalendar->writeScript();
?>
</div></td>
                  <td width="180" valign="middle"><div id='period_div'><?php echo $_SESSION['period'];?></div></td>
                  </tr>
                <tr>
                  <td height="45" valign="middle">Issued by:&nbsp;&nbsp;<label class="star">*</label></td>
                  <td colspan="2" valign="middle"><select name="issued_select" class="select120"  >
                    <option value="<?php echo $_SESSION['issued_by'] ?>" selected="selected"><?php echo $_SESSION['issued_by'] ?></option>
                    <?php
          for ($j = 0; $j < count($arrId1); $j++) {
        echo "<option value=" . "\"" . $arrId1[$j] . "\"" . ">" . $arrName1[$j] . "</option>";
  }
?>
                  </select></td>
                </tr>
                <tr>
                  <td height="45" valign="middle">Additional notes:</td>
                  <td colspan="2" valign="middle"><textarea name="additional_text" id="additional_text" cols="60" rows="3" class="text_box"><?php echo $_SESSION['additional_text'] ?></textarea></td>
                </tr>
              </table>
            </div>
 
            <div class="wizard_frame">
              <table width="640" height="50" align="center" id="table_button_bar">
                <tr>
                  <td width="117"><input type="button" name="lastprev_button" class="imagebutton" value="Prev" onClick="needToConfirm = false;MM_goToURL('parent','warningWizbase.php?s=&amp;p=2');return document.MM_returnValue; MM_showHideLayers('wait','','show');" /></td>
                  <td width="115">&nbsp;</td>
                  <td width="99">
                    <input name="s" type="hidden" id="s" value="3" />
                    <input name="p" type="hidden" id="p" value="3" />
                  </td>
                  <td width="125" align="right"><input name="cancelbutton" type="button" class="imagebutton" id="cancelbutton" onClick="needToConfirm = false; cancel_confirmation(1, '../hr_module/hr_main.php?date=0'); MM_showHideLayers('wait','','show');" value="Cancel" /></td>
                  <td width="110" align="right"><input type="submit" name="next_button" class="imagebutton" value="Next" onClick="needToConfirm = false; MM_showHideLayers('wait','','show');" /></td>
                </tr>
              </table>
    </div>
  </form>
  </div>
<script language="JavaScript" type="text/javascript" xml:space="preserve">
  var frmvalidator  = new Validator("feedbackform");
  frmvalidator.EnableMsgsTogether();
  //frmvalidator.addValidation("warning_text","req","- text for the warning.");
  frmvalidator.addValidation("issued_select","req","- the issuer.");
    
</script>
  


