Dont allow submitting the forms after the registration is closed

This commit is contained in:
james 2005-05-12 17:32:50 +00:00
parent c3896013c1
commit 570d7714dc
6 changed files with 31 additions and 0 deletions

View File

@ -33,6 +33,17 @@ function registrationFormsReceived($reg_id="")
else
return false;
}
function registrationDeadlinePassed()
{
global $config;
$q=mysql_query("SELECT (NOW()<'".$config['dates']['regclose']."') AS datecheck");
$datecheck=mysql_fetch_object($q);
if($datecheck->datecheck==1)
return false;
else
return true;
}
function studentStatus($reg_id="")

View File

@ -75,6 +75,10 @@ echo mysql_error();
{
echo error(i18n("Cannot make changes to forms once they have been received by the fair"));
}
else if(registrationDeadlinePassed())
{
echo error(i18n("Cannot make changes to forms after registration deadline"));
}
else
{
//first, lets make sure this emergency contact really does belong to them

View File

@ -67,6 +67,10 @@ if($_POST['action']=="save")
{
echo error(i18n("Cannot make changes to forms once they have been received by the fair"));
}
else if(registrationDeadlinePassed())
{
echo error(i18n("Cannot make changes to forms after registration deadline"));
}
else
{
$x=1;

View File

@ -75,6 +75,10 @@ echo mysql_error();
{
echo error(i18n("Cannot make changes to forms once they have been received by the fair"));
}
else if(registrationDeadlinePassed())
{
echo error(i18n("Cannot make changes to forms after registration deadline"));
}
else
{
//first, lets make sure this project really does belong to them

View File

@ -66,6 +66,10 @@ echo mysql_error();
{
echo error(i18n("Cannot make changes to forms once they have been received by the fair"));
}
else if(registrationDeadlinePassed())
{
echo error(i18n("Cannot make changes to forms after registration deadline"));
}
else
{
//first we will delete all their old answer, its easier to delete and re-insert in this case then it would be to find the corresponding answers and update them

View File

@ -67,6 +67,10 @@ if($_POST['action']=="save")
{
echo error(i18n("Cannot make changes to forms once they have been received by the fair"));
}
else if(registrationDeadlinePassed())
{
echo error(i18n("Cannot make changes to forms after registration deadline"));
}
else
{
$x=1;