Site not sending email notifications

It is observed that user registration validation email reports sent but does not get to the email inbox.

This started upon upgrading to 1.9.7.

Advice

  • New user registers and application submits with report but the verification email does not get to the new user's email.

  • I need explanation on the following report from the code analyzer:

    ....................................................................

        Line 1307:        Function call: add_submenu_item (deprecated since 1.8) Use the new menu system

    In file: /home/wemex/public_html//mod/uservalidationbyemail/actions/resend_validation.php

        Line 299:          Function call: access_get_show_hidden_status (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

     

    In file: /home/wemex/public_html//mod/uservalidationbyemail/actions/delete.php

        Line 299:          Function call: access_get_show_hidden_status (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

     

    In file: /home/wemex/public_html//mod/uservalidationbyemail/actions/validate.php

        Line 299:          Function call: access_get_show_hidden_status (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

     

    In file: /home/wemex/public_html//mod/uservalidationbyemail/actions/bulk_action.php

        Line 47:             Function call: action (use of function marked private is unsafe)

     

    In file: /home/wemex/public_html//mod/uservalidationbyemail/start.php

        Line 299:          Function call: access_get_show_hidden_status (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

        Line 299:          Function call: access_get_show_hidden_status (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

        Line 299:          Function call: access_get_show_hidden_status (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

     

    In file: /home/wemex/public_html//mod/uservalidationbyemail/lib/functions.php

        Line 190:          Function call: get_site_secret (use of function marked private is unsafe)

     

    In file: /home/wemex/public_html//mod/uservalidationbyemail/pages/confirm.php

        Line 299:          Function call: access_get_show_hidden_status (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

     

    In file: /home/wemex/public_html//mod/uservalidationbyemail/views/default/forms/uservalidationbyemail/bulk_action.php

        Line 299:          Function call: access_get_show_hidden_status (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

        Line 286:          Function call: access_show_hidden_entities (use of function marked private is unsafe)

    ....................................................................

    Thanks

     

  • After new registration, the site does not send validation, and when the user requests password , the site reports that username not found. User tries to register again but site reports that email has been registered.

  • I have just upgraded from 1.9.7 to 1.10.2 and still having the same issue.

    (1)New user registration do not get validation email although site reports that its delivered.

    (2)Forgotten password do not find emails/user names when requested.

    Advice.

  • I just realised that the send mail feature was disabled in my php.ini

  • The send mail was working but now it isn't. I'm running shared Linux hosting under GoDaddy. Here is what is in my php5.ini file.

    SMTP = relay-hosting.secureserver.net

    default_charset = "UTF-8"

    sendmail_path = /usr/sbin/sendmail -t -i

    [mail function]
    ; For Win32 only.
    SMTP = relay-hosting.secureserver.net
    smtp_port = 25

    I don't see anything for php mail. I don't see anywhere in elgg to configure or settings for how you want emails sent.

    I've tried turning off the anti-spam plugin plus user validation by email and then activating user validation by email again but left the anti-spam plugin disabled.

    I don't know why it was working and now isn't.

  • It doesn't make sense, but it appears that if elgg is installed in a different directory than /elgg then the email notification doesn't work. On two installations I have elgg in /elgg and in one it is /community when I register from either of the ones in /elgg I receive the email validation but not if I register in the one installed in /community.

    The really odd part, is I was able to register one user from the one installed in /community. Does anyone have a suggestion on a solution? For a signal domain having elgg installed in /elgg isn't a big deal but one of my projects is multiple installations of elgg but each in its' own directory.

  • I should also mention in .htaccess I have RewriteBase /community/

  • There is this error in the error.log

    [Fri Oct 02 08:28:50 2015] [5928640] [fcgid:warn] [client 99.249.38.154:60567] mod_fcgid: stderr: PHP WARNING: 2015-10-02 11:28:50 (EDT): "mail(): Bad parameters to mail() function, mail not sent." in file /home/content/40/5928640/html/hostedsites/everythingforseniorsdirectory.ca/community/engine/lib/notification.php (line 681), referer http://everythingforseniorsdirectory.ca/community/register

    Is it a problem because elgg is installed in the /community/ directory and not the /elgg/ directory?

  • It's not because of the install directory, something is passing the wrong parameters to the mail() function (as the warning suggests).  I would suggest logging what parameters are being sent to the mail function to see what is being passed, then you can trace back to see what the problem is.

    Likely you have a plugin that modifies mail (such as sending html emails) that's doing something.