in your signup.php file near:
PHP Code:
<tr valign=top><td align="right" class="heading">Email address:</td><td align=left><input type="text" size="40" name="email" />
append:
PHP Code:
<select name="maildomain"><option value="@gmail.com">@gmail.com</option><option value="@yahoo.com">@yahoo.com</option></select>
you can use as many option values as you may.
in takesignup.php:
PHP Code:
if (!mkglobal("wantusername:wantpassword:passagain:email))
die();
replace with:
PHP Code:
if (!mkglobal("wantusername:wantpassword:passagain:email:maildomain))
die();
PHP Code:
if (!validemail($email))
bark("That doesn't look like a valid email address.");
replace with:
PHP Code:
if (!validemail($email.$maildomain))
bark("That doesn't look like a valid email address.");
replace:
PHP Code:
$a = (@mysql_fetch_row(@mysql_query("select count(*) from users where email='$email'"))) or die(mysql_error());
with:
PHP Code:
$a = (@mysql_fetch_row(@mysql_query("select count(*) from users where email='$email.$maildomain'"))) or die(mysql_error());
and in the big query:
INSERT INTO users (username, passhash, secret, editsecret, email....
where you see $email
replace it with $email.$domain.
And thats about it!
An alternative solution is to create a table like maildomain where you can put allowed domains.
Note: this is done with tbdev source. Didn't had the time of installing tstrike but the differences are not that great.
Cheers.