summaryrefslogtreecommitdiffstats
path: root/wp-inst/wp-includes
diff options
context:
space:
mode:
authordonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2005-08-05 16:08:00 +0000
committerdonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2005-08-05 16:08:00 +0000
commit41d4795eef2579e540b0ae0919185d68da126e6a (patch)
tree4bde3b7e59602e68fdc59f43a521242d2b368446 /wp-inst/wp-includes
parent8b665b1672bcd41f285918ff7c6ce58d5d7b6e61 (diff)
Limit email addresses used to register.
git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@131 7be80a69-a1ef-0310-a953-fb0f7c49ff36
Diffstat (limited to 'wp-inst/wp-includes')
-rw-r--r--wp-inst/wp-includes/wpmu-functions.php7
1 files changed, 7 insertions, 0 deletions
diff --git a/wp-inst/wp-includes/wpmu-functions.php b/wp-inst/wp-includes/wpmu-functions.php
index 36f83ce..d90567f 100644
--- a/wp-inst/wp-includes/wpmu-functions.php
+++ b/wp-inst/wp-includes/wpmu-functions.php
@@ -436,6 +436,13 @@ function createBlog( $domain, $path, $username, $weblog_title, $admin_email, $si
if( empty($path) )
$path = '/';
+ $limited_email_domains = get_site_settings( 'limited_email_domains' );
+ if( is_array( $limited_email_domains ) ) {
+ $emaildomain = substr( $admin_email, 1 + strpos( $admin_email, '@' ) );
+ if( in_array( $emaildomain, $limited_email_domains ) == false ) {
+ return "error: email domain not allowed";
+ }
+ }
// Check if the domain has been used already. We should return an error message.
if( $wpdb->get_var("SELECT blog_id FROM $wpdb->blogs WHERE domain = '$domain' AND path = '$path'" ) )
return 'error: Blog URL already taken.';