1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Admin Email 0.4

Admin Email

  1. Nick

    Nick Well-Known Member

    Nick submitted a new resource:

    Admin Email - Admin Email

    Read more about this resource...
    Last edited by a moderator: Oct 14, 2014
  2. Nick

    Nick Well-Known Member

    Updated: v.0.4 2010/03/13 - Nick - Updated to use the $h->email function introduced in Hotaru 1.1.1.
  3. angolanmade

    angolanmade Well-Known Member

    What other options can we insert into the body of the email?

    i.e - {username} etc!
  4. Nick

    Nick Well-Known Member

    Feel free to extend the plugin. See lines 207 and 208 of admin_email.php. You can use any field from the users db table.
  5. emarza975

    emarza975 New Member

    Errors on sending emails....

    Good evening there....:cool:
    i'm a newbie: i installed Hotaru only today. I installed plugins also and I have a matter regarding the email smtp.
    When the site must send email (i.e. when it accept new registration or using the Admin Email plugins) debug gives me errors.

    Here when Admin Email starts in real mode....
    In simulation mode the test ends with "faked email sending..." as you see in quote:

    I don't understand where's the bug.:( The code seems right, the email smtp params are rights (i.e. they are ok using joomla plugin Sendmail)...
    Can you help me?:confused::confused::confused:
  6. Nick

    Nick Well-Known Member

    Hi Lele, you need the PEAR PHP extension installed on your server to use SMTP email authentication in Hotaru. According to the errors you posted above, you don't have PEAR. If you need it, ask your web host if they can install it, otherwise, turn off "SMTP" in Admin -> Settings and use email the regular way, i.e. using PHP's mail() function instead of PEAR Mail.
    emarza975 likes this.
  7. acorn

    acorn New Member

    Now I finaly moved my site from local server and started testing on webhost. But, I have a problem with the email smtp. When a user registers or existing user register to comments I get this message:
    In simulation mode:

    I asked my web host they said by default Pear mail is installed and functioning.
    They suggested I may need to set the include path to usr/bin/php in the script settings. So, I went back to emailfunctions.php, but could not figure out :(
    How I am going to set the include path to usr/bin/php? Or is there any other way to make this work?
    Please heeeelp. Thanks....
  8. acorn

    acorn New Member

    Hi, when I turn off the smtp on admin, it is working. Sending e-mails when user registers. However, I came across another problem. When user registers, I get following message on the screen:
    But, the user receives the e-mail and when click the link in the e-mail, the registration completes.
    Why there is CSRF error on the screen? How can I get rid of it?
    Also, I still want to enable pear mail. If anybody can help me with these, I will be very thankful!
  9. Nick

    Nick Well-Known Member

    Well, the line which includes Mail.php is line 140 in /libs/EmailFunctions.php :

    require_once "Mail.php";
    You'll need to ask your host what that should be changed to. For most people, it won't need changing at all.

    As for CSRF errors on registration, that's not caused by this plugin. Please post elsewhere about that, with as many details as possible.
    acorn likes this.
  10. acorn

    acorn New Member

    Thank you, Nick. Will contact my host again. What if I keep php mail? Would it have any downsides? sorry for too many questions :confused:
  11. Nick

    Nick Well-Known Member

    If your web host requires email authentication, you need to enable the SMTP option and use PEAR Mail, otherwise regular php mail() should be fine.
  12. cecilporter

    cecilporter Donor Donor

    I'd like to extend admin_email to use user-Manager's filtering drop-down. I want to email specific groups like pending users, the newest users, all moderators..

    I just wanted to drop a note here first to make sure nobody else has already done this so I don't replicate effort.
  13. hotaruuser

    hotaruuser New Member

    I just tried to send a longer email, but it did not work. If I try simulation mode or no simulation mode, it states: "error: no email body" which is indeed not right, because there is certainly a body.

    If I try a short text like "asdfasdf" it is send properly.

    Does anybody else have a problem like this? Could it be that the mail ist just too long? Where is the restriction? Or is it not possible to send links in it?


    Ok, I tried more, if I use any character like ? ? or ? or ?, then this error comes!!!

    A message without any of these characters is send properly!!!

    How can I fix this?

    Thank you
    Last edited: Jul 20, 2011
  14. narc

    narc Well-Known Member

    this plugin dosnt work with hotaru 1.7.3 :(
  15. valMETNG

    valMETNG Administrator Staff Member Admin

    I just ran a test and it worked. What problem or error message are you seeing?
  16. narc

    narc Well-Known Member

    ( ! ) Notice: unserialize(): Error at offset 1763 of 65535 bytes in /libs/Initialize.php on line 565

    ( ! ) Warning: Cannot modify header information - headers already sent by (output started at /libs/Initialize.php:565) in /content/admin_themes/admin_default/admin_header.php on line 29

    nothing modify in admin_email plugin
  17. valMETNG

    valMETNG Administrator Staff Member Admin

    I don't see an unserialize call on line 565 of Initialize.php which suggests there's some custom code causing the problem. If you post the entire function that includes line 565, I might be able to figure out where the problem is.
  18. narc

    narc Well-Known Member

        foreach ($pluginsSetting as $setting) {
          if ($setting['plugin_setting'] == $setting['plugin_folder'] . '_settings') {
            //if (is_serialized($setting['plugin_value'])) {
            $this->pluginSettings[$setting['plugin_folder']] = unserialize($setting['plugin_value']);
          else {
            $this->pluginSettings[$setting['plugin_folder']][$setting['plugin_setting']] = $setting['plugin_value'];
  19. valMETNG

    valMETNG Administrator Staff Member Admin

    So this code block starts at line 600. Have you customized Initialize.php and removed about 35 lines or are you, perhaps, using an older version of Initialize.php?

    To determine what's wrong, you'll need to print some values. I'd suggesting replacing your block of text with this:
    echo 'plugin settings:</br>';
        foreach ($pluginsSetting as $setting) {
          if ($setting['plugin_setting'] == $setting['plugin_folder'] . '_settings') {
            //if (is_serialized($setting['plugin_value'])) {
    echo ' <br/>plugin value = ' . $setting['plugin_value'];
            $this->pluginSettings[$setting['plugin_folder']] = unserialize($setting['plugin_value']);
          else {
            $this->pluginSettings[$setting['plugin_folder']][$setting['plugin_setting']] = $setting['plugin_value'];
    Then you can see what's in the variables to help determine the problem.
  20. narc

    narc Well-Known Member

    No, the file has not been modified . if I spend the ECHO , follows as a sher long list . Identification of the problem is therefore more difficult . I think your file is modified ? With me is the block of code exactly at 565. Could you give me your initialize.php , so I can compare them ?

Share This Page