Current File : /home/inlingua/public_html/icentex/oral/oral.php |
<?php
include("header_oral.php");
?>
<?php
$month=date("m");
$year=date("Y");
//$year=2011;
// Include the database connection details
require('../dbConnection.php');
// Include common functions
require('../commonFunc.php');
// Include common functions
require('../globalVars.php');
// Include the table handler class
require('../dbHandler.class.php');
// Init and connect to database
$dbObject = new dbHandler();
$dbObject->connect();
?>
<h3> Add New Oral</h3>
<script>
function validate(form)
{ if (document.form.month.value=="")
{ alert("Please Select month.");
document.form.month.focus(); return false;
}
if (document.form.year.value=="")
{ alert("Please Select Year.");
document.form.year.focus(); return false;
}
if (document.form.location.value=="")
{ alert("Please Select Location.");
document.form.location.focus(); return false;
}
return true;
}
function validate1(form)
{ if (document.form1.month.value=="")
{ alert("Please Select month.");
document.form1.month.focus(); return false;
}
if (document.form1.year.value=="")
{ alert("Please Select Year.");
document.form1.year.focus(); return false;
}
if (document.form1.location.value=="")
{ alert("Please Select Location.");
document.form1.location.focus(); return false;
}
return true;
}
</script>
<font style="font-size:12px; color:#E84B1E"><?php if($_SESSION['oral1']) { echo $_SESSION['oral1']; unset ($_SESSION['oral1']); }?></font>
<table width="100%">
<tr><td width='23%'>
<form action="ingl_oral_main.main.php" method="post" name="form" onsubmit=" return validate(this)">
Enter oral for </td><td> <select name='month'>
<option value="">Select Month</option>
<option value="01" <?php if($month=='01') echo"selected"; ?>>Jan</option>
<option value="02" <?php if($month=='02') echo"selected"; ?>>Feb</option>
<option value="03" <?php if($month=='03') echo"selected"; ?>>Mar</option>
<option value="04" <?php if($month=='04') echo"selected"; ?>>Apr</option>
<option value="05" <?php if($month=='05') echo"selected"; ?>>May</option>
<option value="06" <?php if($month=='06') echo"selected"; ?>>Jun</option>
<option value="07" <?php if($month=='07') echo"selected"; ?>>Jul</option>
<option value="08" <?php if($month=='08') echo"selected"; ?>>Aug</option>
<option value="09" <?php if($month=='09') echo"selected"; ?>>Sep</option>
<option value="10" <?php if($month=='10') echo"selected"; ?>>Oct</option>
<option value="11" <?php if($month=='11') echo"selected"; ?>>Nov</option>
<option value="12" <?php if($month=='12') echo"selected"; ?>>Dec</option>
</select>
of
<select name='year'>
<?php
$newyear=date('Y');
for($j=2010;$j<=$newyear;$j++)
{
echo"<option value='".$j."' ";
if($j==$year)
{
echo"selected";
}
echo">".$j."</option>";
}
?>
</select>
<input type='hidden' name='half' value="1">
<input type='submit' class="submit1" value=" Next ">
</form>
</td></tr>
</table>
<?php
include("footer_oral.php");
?>