Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

SOLVED Automated email generation script issue

Discussion in 'cPanel Developers' started by Jeff P., Nov 28, 2016.

Tags:
  1. Jeff P.

    Jeff P. Active Member

    Joined:
    Feb 2, 2016
    Messages:
    33
    Likes Received:
    6
    Trophy Points:
    8
    Location:
    Palm Coast, Fl
    cPanel Access Level:
    DataCenter Provider
    Anyone see why this would stop working? It's returning false and nothing else too.

    function makeemail1($domain,$account) {
    global $root_pass,$ip;
    $xmlapi = new xmlapi($ip);
    $xmlapi->set_port(2082);
    $xmlapi->password_auth($account,'xxxxxxxxxx');
    $call = array('domain'=>$domain, 'email'=>'abuse@'.$domain,'password'=>'xxxxxxxxxx', 'quota'=>'200');
    return $xmlapi->api2_query($account, "Email", "addpop", $call);
    }
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    43,870
    Likes Received:
    1,811
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    The "email" parameter should be 'abuse' in your example. Per the Email::addpop document:

    Thank you.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. Jeff P.

    Jeff P. Active Member

    Joined:
    Feb 2, 2016
    Messages:
    33
    Likes Received:
    6
    Trophy Points:
    8
    Location:
    Palm Coast, Fl
    cPanel Access Level:
    DataCenter Provider
    Ah new it would be something tiny. So just the username and not full email. Thanks.
     
    cPanelMichael likes this.
  4. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    43,870
    Likes Received:
    1,811
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    That's correct.

    Thanks!
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice