The MU forums have moved to WordPress.org

problem in 2nd step of registering new blog (13 posts)

  1. indyword
    Member
    Posted 17 years ago #

    i know i've asked alot of help last day
    the wpmu installation went so fine .. firstly i found an error in signing up page which drmike fixed it
    but after fixing it and on the 2nd page of registeration i found this error:
    Warning: in_array(): Wrong datatype for second argument in /blablabla"""/wp-includes/wpmu-functions.php on line 881

    i wish anyone can help in this .. drmike did alot of help here and i don't want to bother him more

  2. drmike
    Member
    Posted 17 years ago #

    Line 881 concerns the new banned email function. You're not the first person to raise an issue about it. I'm wondering if maybe not everything is OK with it.

    Looks fine to me though.

  3. indyword
    Member
    Posted 17 years ago #

    well .. i looked at the line either and i knew the function but i don't know what's the problem
    ' if( in_array( $email_domain, $banned_names ) == true ) {'
    that's the line :-(
    i wish if it could be fixed or to know what is the problem

  4. drmike
    Member
    Posted 17 years ago #

    *sigh*

    The problem is there appears to be an issue with the new banned email function. There already is a ticket open the subject and we're waiting for a developer to work on the issue.

    If you want, feel free to comment out that line and work around it.

  5. mypatricks
    Member
    Posted 17 years ago #

    open wpmu-edit.php add these

    if( $_POST[ 'banned_email_domains' ] != '' ) {
    update_site_option( "banned_email_domains", split( ' ', $_POST[ 'banned_email_domains' ] ) );
    } else {
    update_site_option( "banned_email_domains", '' );
    }

    after

    if( $_POST[ 'limited_email_domains' ] != '' ) {
    update_site_option( "limited_email_domains", split( ' ', $_POST[ 'limited_email_domains' ] ) );
    } else {
    update_site_option( "limited_email_domains", '' );
    }

  6. Ksaveras
    Member
    Posted 17 years ago #

    Looks like developers have vacation.

  7. indyword
    Member
    Posted 17 years ago #

    i tried to put the code but nothing changed
    i reported this to the ticket

  8. mypatricks
    Member
    Posted 17 years ago #

    sorry forgot this

    open /wp-include/wpmu-funtions.php

    replace this
    if ( is_array( $banned_names ) && empty( $banned_names ) == false ) {
    $email_domain = substr( $user_email, 1 + strpos( $user_email, '@' ) );
    if( in_array( $email_domain, $banned_names ) == true ) {
    $errors->add('user_email', __("You cannot use that email address to signup. Please use another provider."));
    }
    }

    with this (at line 880):
    $email_domain = substr( $user_email, 1 + strpos( $user_email, '@' ) );
    if( in_array( $email_domain, $banned_names ) == true ) {
    $errors->add('user_email', __("You cannot use that email address to signup. Please use another provider."));
    }
    it's work now. :)

  9. jonmat
    Member
    Posted 17 years ago #

    indyword, did this work for you? I was having the same problem as you, but the changes to this code didn't work for me. I reopened the ticket.

    I hope I did the right thing (I'm new here).

  10. indyword
    Member
    Posted 17 years ago #

    i followed the instructions given here and on the ticket and then everything went so fine

    i mentioned this there on the ticket
    i wish it works fine with u too

  11. mypatricks
    Member
    Posted 17 years ago #

    indyword, it's seen work, but user still can't signup. you must edit this line to "true" at wpmu-functions.php:

    if( in_array( $emaildomain, $limited_email_domains ) == true ) {

    this is feedback from my user. :) you may download the file at trac.mu.wordpress.org and test it.

  12. indyword
    Member
    Posted 17 years ago #

    :) i noticed it somehow .. actually was playing with the files lol
    i downloaded the files and gonna test it as soon as possible
    but it works fine now with me and i signed up and got a test blog which is working so fine
    thanks alot mypatricks
    ;-)

  13. Misera
    Member
    Posted 17 years ago #

    Slightly confused.. after those edits mine still says the error, but instead of banning all email domains besides the one I specify, it's banninig the one I specify and allowing all other domains. And to make sure it wasn't just that I edited in the wrong places, I uploaded the files from the zip and it is still like that.

    Edit: That last thing that says to change it to "true" is the thing that is flipping the ban

About this Topic