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!

Access denied : please help:)

Discussion in 'cPanel Developers' started by jonniejoejonson, Jul 19, 2011.

  1. jonniejoejonson

    jonniejoejonson Registered

    Joined:
    Jul 19, 2011
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    51
    include("../xmlapi.php");

    $ip = 'localhost';
    $root_pass = 'this_is_the_password_I_use_to_loginto_cpanel';
    $account = "this_is_the_username_I_use_to_loginto_cpanel";

    $xmlapi = new xmlapi($ip);
    $xmlapi->password_auth("root",$root_pass);
    $xmlapi->set_output("json");


    print $xmlapi->listparkeddomains($account, null);

    I keep getting an access denied printout... am i using the right pasword or anyideas where i am going wrong?... kind regards J
     
  2. jonniejoejonson

    jonniejoejonson Registered

    Joined:
    Jul 19, 2011
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    51
    Boom... found the answer on the forums... set a diff port cos im not root user...

    $xmlapi = new xmlapi($ip);
    $xmlapi ->set_port(2083);
    $xmlapi->password_auth($username,$root_pass);
    $xmlapi->set_output("json");
     
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