Mailuser interface

Discussion in 'Plugins/Modules/Addons' started by Horfic, Aug 23, 2009.

?

Would you like to see a mailuser interface for Roundcube & Squirrelmail?

  1. Yes

    210 vote(s)
    98.6%
  2. No

    3 vote(s)
    1.4%
  1. jtheed

    jtheed Member HowtoForge Supporter

    Roundcube Interface on Multi-Server Setup

    Can this be used on a 2 Server setup where one server is the web site and the other is the mail server? I can get RoundCube to work by itself by installing it on the web server, but once I install the plugins, I can't log in. Do I need to install something on the mail server itself?
     
  2. Horfic

    Horfic Member

  3. jtheed

    jtheed Member HowtoForge Supporter

    Is there a way to test the remote user connection outside of RoundCube?
     
  4. Horfic

    Horfic Member

    write your self something and test it^^

    some example scripts are available when you download ispconfig 3

    whats the problem?
     
    Last edited: May 7, 2012
  5. jtheed

    jtheed Member HowtoForge Supporter

    When in RoundCube mail, go to settings and click on Account tab, get a Soap Error, Cannot connect to Host. I have setup remote user, re-entered password in case it was wrong , double checked the settings in ispconfig3_account/config.inc.php.


    I figured it out. I was putting the domain name instead of the server name.
     
    Last edited: May 7, 2012
  6. neutrino

    neutrino Member

    Hello, since Roundcube 0.8 will be out in the next month or so (7 bugs remaining before final version), will the mailuser interface work with it or should I wait for an upgrade ?

    Thanks for the great job done so far :)
     
  7. Horfic

    Horfic Member

    Well the newest version is already 100% compatible with 0.8.
     
  8. Croydon

    Croydon ISPConfig Developer ISPConfig Developer

    I think the function to hide the host field in the login form should be rewritten to

    PHP:
    function template_object_loginform($args)
            {
                    
    $args['content'] = preg_replace("/<tr>\s*<td class=\"title\">\s*<label for=\"rcmloginhost\">(.*?)<\/label>\s*<\/td>\s*<td class=\"input\">\s*<input name=\"_host\"([^>]*)>\s*<\/td>\s*<\/tr>/is","",$args['content']);

                    return 
    $args;
            }
    because the field does have variable attributes. e.g. attributes size and autocomplete are not always there.
     
  9. Horfic

    Horfic Member

    Hi Croydon,
    you don't have to double post, i saw the ticket in the bugtracker.

    PS: Due do heavy work atm, I can hardly maintain the roundcube plugins.
    Although everything is working, the ispconfig 3 package needs updating and I should also include the few tickets which are open.

    PPS: Paid work still has priority

    Regards,
    Horfic
     
  10. Croydon

    Croydon ISPConfig Developer ISPConfig Developer

    Hi,

    where did I double post? I found this just a few minutes ago. For my own server I fixed this already, just wanted to contribute back.
     
  11. Horfic

    Horfic Member

  12. EPMS

    EPMS New Member

    Hello,
    i have a problem with the plugin. I updatet my ISPConfig Version with no problems. When i know want to login in roundcube i get an error like "login incorrect". When i disable the plugin everything is ok. I updatet the Plugin also. But no effect.

    Where can be my problem?

    Thanks for help.
     
  13. Horfic

    Horfic Member

    FAQ: http://bugs.web-wack.at/documents/3

    Code:
    Q: After I installed all plugins, I can't login.
    A: The autoselect feature is probably activated and the $rcmail_config['default_host'] is not empty. Please refer to step 6 of the install instructions.
    So just disable the autoselect plugin
     
  14. cassus

    cassus New Member

    I've just installed plugin according to http://bugs.web-wack.at/documents/1
    ispc 3.0.4.6.
    roundcube 0.7.1.
    last version of plugin

    but i can't see the "account" tab. Where might be a problem? thanks
     
  15. maumar

    maumar New Member HowtoForge Supporter

    i think that last plugin version is for last roundcube version
    and your one isn't

    but maybe i'm wrong
     
  16. cassus

    cassus New Member

    yes, you were right, I installed last version of roundcube (0.8.1.) and it is OK now. Thanks !

    I assumed that 0.7.1. will be ok according to these requirements http://bugs.web-wack.at/documents/2
    but it isn't working
     
    Last edited: Sep 15, 2012
  17. SenseiSimple

    SenseiSimple New Member

    Soap Error: autoresponder_end_date_isgreater

    On the Change Password plugin [ROUNDCUBEDIR/plugins/ispconfig3_pass/ispconfig3_pass.php, on saving the new password, one gets

    "Soap Error: autoresponder_end_date_isgreater"

    with Roundcube 0.8, ISPconfig 3.0.5Beta1

    http://bugs.web-wack.at/issues/37 (i haven't received a confirmation email from registration on the bug tracker)

    I created a patch to check if the autoresponder dates aren't 0000's (not set), otherwise, it should all work as normal. I also repositioned the Try/Catch blocks to only include the relevant parts (this could probably be better, i hate repeated code)

    Code:
    --- ispconfig3_pass.php.old	2012-12-04 22:14:53.000000000 -0600
    +++ ispconfig3_pass.php	2012-12-04 22:06:38.000000000 -0600
    @@ -63,48 +63,58 @@
     			{
     				try
     				{
    -          $soap = new SoapClient(null, array('location' => $this->rcmail_inst->config->get('soap_url').'index.php',
    +          			$soap = new SoapClient(null, array('location' => $this->rcmail_inst->config->get('soap_url').'index.php',
     									'uri'      => $this->rcmail_inst->config->get('soap_url')));
     					$session_id = $soap->login($this->rcmail_inst->config->get('remote_soap_user'),$this->rcmail_inst->config->get('remote_soap_pass'));
     					$mail_user = $soap->mail_user_get($session_id, array('login' => $this->rcmail_inst->user->data['username']));
    -          
    -          $startdate = $mail_user[0]['autoresponder_start_date'];
    -          $enddate = $mail_user[0]['autoresponder_end_date'];
    -        
    -          if (strtotime($startdate) <= time())
    -          $startdate = date('Y').'-'.date('m').'-'.date('d').' '.date('H').':'.date('i', time() + 300);
    -		
    -          $startdate = array('year' => substr($startdate,0,4),
    -							'month' => substr($startdate,5,2),
    -							'day' => substr($startdate,8,2),
    -							'hour' => substr($startdate,11,2),
    -							'minute' => substr($startdate,14,2));
    -							
    -          $enddate = array('year' => substr($enddate,0,4),
    -						'month' => substr($enddate,5,2),
    -						'day' => substr($enddate,8,2),
    -						'hour' => substr($enddate,11,2),
    -						'minute' => substr($enddate,14,2));
    -
    -          $params = $mail_user[0];
    -          $params['autoresponder_start_date'] = $startdate;
    -          $params['autoresponder_end_date'] = $enddate;
    -          $params['password'] = $newpwd;
    +//PATCH 12-04-2012 http://bugs.web-wack.at/issues/37 senseisimple - [Soap Error: autoresponder_end_date_isgreater]	
    +				}
    +				catch (SoapFault $e)
    +				{
    +					$this->rcmail_inst->output->command('display_message', 'Soap Error: '.$e->getMessage(), 'error');
    +				}
    +
    +				$params = $mail_user[0];
    +				$params['password'] = $newpwd;
    +				if ( $mail_user[0]['autoresponder_start_date'] != '0000-00-00 00:00:00' ) {
    +					$startdate = $mail_user[0]['autoresponder_start_date'];
    +					$enddate = $mail_user[0]['autoresponder_end_date'];
    +
    +					if (strtotime($startdate) <= time())
    +					$startdate = date('Y').'-'.date('m').'-'.date('d').' '.date('H').':'.date('i', time() + 300);
    +					$startdate = array('year' => substr($startdate,0,4),
    +									'month' => substr($startdate,5,2),
    +									'day' => substr($startdate,8,2),
    +									'hour' => substr($startdate,11,2),
    +									'minute' => substr($startdate,14,2));
    +
    +					$enddate = array('year' => substr($enddate,0,4),
    +								'month' => substr($enddate,5,2),
    +								'day' => substr($enddate,8,2),
    +								'hour' => substr($enddate,11,2),
    +								'minute' => substr($enddate,14,2));
     
    +					$params['autoresponder_start_date'] = $startdate;
    +					$params['autoresponder_end_date'] = $enddate;
    +				}
    +
    +			  	try
    +				{
     					$uid = $soap->client_get_id($session_id, $mail_user[0]['sys_userid']);
     					$update = $soap->mail_user_update($session_id, $uid, $mail_user[0]['mailuser_id'], $params);
     					$soap->logout($session_id);
    -					
    +
     					$this->rcmail_inst->output->command('display_message', $this->gettext('successfullysaved'), 'confirmation');
    -					
    +
     					$_SESSION['password'] = $this->rcmail_inst->encrypt($newpwd);
    -					
    +
     					$this->rcmail_inst->user->data['password'] = $_SESSION['password'];
     				}
     				catch (SoapFault $e)
     				{
     					$this->rcmail_inst->output->command('display_message', 'Soap Error: '.$e->getMessage(), 'error');
     				}
    +//END PATCH 12-4-2012
     			}
     		}
     		$this->init_html();
    @@ -154,4 +164,4 @@
     		return $out;
     	}
     }
    -?>
    \ No newline at end of file
    +?>
    
     
    Last edited: Dec 5, 2012
  18. gapa

    gapa New Member

    Thanks for looking into this. But I have problems with applying your patch. Am I doing something wrong?

    br,
    gapa
     
  19. SenseiSimple

    SenseiSimple New Member

    I patched against the latest SVN version, i believe there were changes from what's downloadable on the site and what's in SVN,


    svn co http://svn.web-wack.at/ispconfig3_roundcube3/trunk/ .

    http://www.howtoforge.com/forums/showpost.php?p=213239&postcount=20
    look at the Update section of the first part, try the svn up . command in the plugins directory (though i suspect it will have to have been loaded from the svn in the first place... If you haven't made any modifications, just pull it all from svn (backing up your account login info file first)

    ROUNDCUBEDIR/plugins/ispconfig3_account/config/config.inc.php

    then apply the patch

    let me know if still doesn't work, i'll generate the patch again.
     
    Last edited: Dec 7, 2012
  20. brainkiller2000

    brainkiller2000 New Member

    @SenseiSimple

    The patch does not work for me. I updadet to the last svn of the ipsconfig plugin files.

    I got the following errors:
    Code:
    File to patch: ispconfig3_pass.php
    patching file ispconfig3_pass.php
    Hunk #1 FAILED at 63.
    patch unexpectedly ends in middle of line
    patch: **** malformed patch at line 93:
    
    Thanks in advance or helping!
     

Share This Page