Roundcube Community Forum

Release Support => Pending Issues => Topic started by: shiransabar on February 13, 2015, 11:56:18 PM

Title: Password Plugin Issue - 2015: Please help- Other topics didn't help
Post by: shiransabar on February 13, 2015, 11:56:18 PM
Hi Guyz,

I have tried so many solutions looking at 20 to 30 thread on this topic. Unfortunately non of this helped me. Most of the threads (new topics) are very old. Below is my code in cpanel and config file. I know there must be something wrong with the code and i do not know where, i'm using hostmonster cpanel. I'm not an expert in coding but love to fix this for my mail. Please Help...

cPanel Code
_______________________________________
function password_save($curpas, $newpass)
{
    $rcmail = rcmail::get_instance();

    // Create a cPanel email object
    $cPanel = new emailAccount($rcmail->config->get('password_cpanel_host'),
   $rcmail->config->get('password_cpanel_username'),
   $rcmail->config->get('password_cpanel_password'),
   $rcmail->config->get('password_cpanel_port'),
   $rcmail->config->get('password_cpanel_ssl'),
   $rcmail->config->get('password_cpanel_theme'),
   $_SESSION['username'] );

    if ($cPanel->setPassword($newpass)){
        return PASSWORD_SUCCESS;
    }
    else
    {
       return PASSWORD_ERROR;
    }
}



// cPanel Driver options
// --------------------------
// The cPanel Host name
$config['password_cpanel_host'] = 'xxxx.hostmonster.com';

// The cPanel admin username
$config['password_cpanel_username'] = 'myusername';

// The cPanel admin password
$config['password_cpanel_password'] = 'mypass';

// The cPanel port to use
$config['password_cpanel_port'] = 2083;

// Using ssl for cPanel connections?
$config['password_cpanel_ssl'] = true;

// The cPanel theme in use
$config['password_cpanel_theme'] = 'hostmonster';
Title: Re: Password Plugin Issue - 2015: Please help- Other topics didn't help
Post by: SKaero on February 14, 2015, 01:23:40 PM
Update Roundcube, your using an old version of the password plugin.
Title: Re: Password Plugin Issue - 2015: Please help- Other topics didn't help
Post by: shiransabar on February 27, 2015, 08:20:50 AM
Hi SKaero,

I have installed the latest version and still having the same issue.

the code:

// cPanel Driver options
// --------------------------
// The cPanel Host name
$config['password_cpanel_host'] = 'domain.com'; (hosting support says to use the domain name as host)

// The cPanel admin username
$config['password_cpanel_username'] = 'myusername'; (i should use the username for my hosting cpanel right?)

// The cPanel admin password
$config['password_cpanel_password'] = 'password';

// The cPanel port to use
$config['password_cpanel_port'] = 2082;

and latest version does not ask for SSL or cpanel theme. is that ok? apart from this i have done below too

Install cPanel XMLAPI Client Class into Roundcube program/lib directory
or any other place in PHP include path. You can get the class from
https://raw.github.com/CpanelInc/xmlapi-php/master/xmlapi.php


still no luck please advice.

Thank you
Shiran

Title: Re: Password Plugin Issue - 2015: Please help- Other topics didn't help
Post by: SKaero on February 27, 2015, 10:46:01 PM
Do you have any errors in your error log?
Title: Re: Password Plugin Issue - 2015: Please help- Other topics didn't help
Post by: shiransabar on February 28, 2015, 01:21:42 AM
Yes it says "password cannot be save"
Title: Re: Password Plugin Issue - 2015: Please help- Other topics didn't help
Post by: SKaero on February 28, 2015, 03:34:14 AM
That doesn't contain any information, there should be more info info in the actual error log.