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!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Help Regarding Email::Autoresponder API

Discussion in 'cPanel Developers' started by toqeer2050, Jan 11, 2013.

  1. toqeer2050

    toqeer2050 Registered

    Jan 11, 2013
    Likes Received:
    Trophy Points:
    cPanel Access Level:
    Root Administrator

    $server = "";
    $auser = "cPanel username";
    $pass = "The Password";
    $port = '2083';
    $domain = 'domain.tld';


    $xmlapi = new xmlapi($server);

    // Add new Email autoresponder
    $add_a_email = $_POST['add_a_email'];
    $add_a_from_name = $_POST['add_a_from_name'];
    $add_a_subject = $_POST['add_a_subject'];
    $add_a_content = $_POST['add_a_content'];
    $add_a_start = $_POST['add_a_start'];
    $add_a_stop = $_POST['add_a_stop'];
    $args = array(
    'email' => $add_a_email,
    'from' => $add_a_from_name,
    'subject' => $add_a_subject,
    'body' => $add_a_content,
    'domain' => $domain,
    'html' => '0',
    'interval' => '3600',
    'start' => $add_a_start,
    'stop' => $add_a_stop
    $response = $xmlapi->api1_query($auser, "Email", "addautoresponder", $args);

    I am using above code to make autoresponder plugin. I need help. when user enter values and press submit button will this script work there? or we need to write something more to make this thing working. I am saving this file as autored.php is that ok ? and where is xmlapi.php . should i put it in the same directory where my plugin file autored.php is placed? Please help to complete this plugin for me. I urgently need this.

Share This Page