forked from science-ation/science-ation
- Name the science fair login "Science Fair" not "Other Fair"
- Since science fairs are attached to users now, it doesn't make sense to allow the user to choose from a list of fairs, since there could be more than one with access to a fair (and we don't want to start putting names in there), so fairs can login with a user/pass like everyone else.
This commit is contained in:
parent
6e04220d36
commit
37bbcf312b
@ -63,7 +63,7 @@
|
||||
echo "</ul>\n";
|
||||
|
||||
if($config['fairs_enable'] == 'yes' && $config['fairs_allow_login'] == 'yes') {
|
||||
echo "<h4>Other Fair</h4>\n";
|
||||
echo "<h4>".i18n("Science Fairs")."</h4>\n";
|
||||
echo "<ul style=\"margin-top: 0px;\">";
|
||||
echo "<li><a href=\"{$config['SFIABDIRECTORY']}/user_login.php?type=fair\">".i18n("{$config['fairs_name']} Fair Login").'</a></li>';
|
||||
echo "</ul>\n";
|
||||
|
@ -351,22 +351,7 @@
|
||||
<form method="post" action="user_login.php?type=<?="$type$redirect_url"?>">
|
||||
<input type="hidden" name="action" value="login" />
|
||||
<table><tr><td>
|
||||
<?
|
||||
if($type == 'fair') {
|
||||
echo i18n("Select Fair").'</td><td><select name="user">';
|
||||
$q = mysql_query("SELECT
|
||||
users.username,fairs.fairname
|
||||
FROM users LEFT JOIN users_fair ON users_fair.users_id=users.id
|
||||
LEFT JOIN fairs ON users_fair.fairs_id=fairs.id
|
||||
WHERE types LIKE '%fair%' ORDER BY fairs.fairname");
|
||||
while($r = mysql_fetch_object($q)) {
|
||||
echo "<option value=\"{$r->username}\">{$r->fairname}</option>\n";
|
||||
}
|
||||
echo '</select>';
|
||||
} else {
|
||||
echo i18n("Email").'</td><td><input type="text" size="20" name="user" />';
|
||||
}
|
||||
?>
|
||||
<?=i18n("Email")?>:</td><td><input type="text" size="20" name="user" />
|
||||
</td></tr><tr><td>
|
||||
<?=i18n("Password")?>:</td><td><input type="password" size="20" name="pass" />
|
||||
</td></tr>
|
||||
|
Loading…
x
Reference in New Issue
Block a user