retreival of lost/forgotten registration number

This commit is contained in:
james 2004-12-02 17:53:31 +00:00
parent 1509632d22
commit 785e62a765

View File

@ -46,6 +46,24 @@
}
}
else if($_GET['action']=="resend" && $_SESSION['email'])
{
$q=mysql_query("SELECT num FROM registrations WHERE email='".$_SESSION['email']."'");
$r=mysql_fetch_object($q);
$mailbody= "We have received a request for the retrieval\n".
"if your registration number from this email\n".
"address. Please find your existing registration\n".
"number below:\n\n".
"\n".
"Registration Number: $r->num\n".
"\n";
mail($_SESSION['email'],i18n("Registration for %1",array(i18n($config['fairname']))),$mailbody);
send_header("Participant Registration");
echo notice(i18n("Your registration number has been resent to your email addess <b>%1</b>",array($_SESSION['email'])));
echo "<br />";
}
//if they've alreayd logged in, and somehow wound back up here, take them back to where they should be
@ -69,7 +87,7 @@
$q=mysql_query("SELECT * FROM registrations WHERE email='".$_SESSION['email']."' AND status='new' AND year=".$config['FAIRYEAR']);
if(mysql_num_rows($q)>0)
{
echo i18n("Please enter the <b>registration number</b> you received in your email, in order to begin your new registration");
echo i18n("Please enter your <b>registration number</b> that you received in your email, in order to begin your new registration");
echo "<input type=\"hidden\" name=\"action\" value=\"new\">";
$allownew=false;
}
@ -87,9 +105,10 @@
echo mysql_error();
if(mysql_num_rows($q)>0)
{
echo i18n("Please enter the <b>registration number</b> in order to continue your registration");
echo i18n("Please enter your <b>registration number</b> in order to continue your registration");
echo "<input type=\"hidden\" name=\"action\" value=\"continue\">";
$allownew=false;
echo "<br />";
}
}
@ -129,11 +148,12 @@
}
echo "<br />";
echo "<br />";
echo i18n("Registration Number:");
echo "<input type=\"text\" size=\"10\" name=\"regnum\">";
echo "<input type=\"submit\" value=\"Submit\">";
echo "</form>";
echo "<br />";
echo i18n("If you have lost or forgotten your <b>registration number</b>, pleaes <a href=\"register_participants.php?action=resend\">click here to resend</a> it to your email address");
}
else
{