Jump to content

Access to Secure Webmail via WHMC client panel


rkzm

Recommended Posts

 

When my clients attempt to log into webmail from the client panel they are directed to my server shared IP address port 2096.  This is not a secure connection.  How can I configure WHMCS so that they are directed to their domain:2096 which has SSL and resolves to https.

Link to comment
Share on other sites

19 hours ago, rkzm said:

When my clients attempt to log into webmail from the client panel they are directed to my server shared IP address port 2096.  This is not a secure connection.  How can I configure WHMCS so that they are directed to their domain:2096 which has SSL and resolves to https.

you could use the action hook in the thread below - just create a new .php file in /includes/hooks, paste the code into it and it will change the cPanel and webmail links.

however, in your case, you only want to change webmail (and not cPanel), so the hook code should just need to be...

<?php

use WHMCS\View\Menu\Item as MenuItem;

add_hook('ClientAreaPrimarySidebar', 1, function(MenuItem $primarySidebar)
{

$service = Menu::context('service');    
$domain = $service->domain;
$servertype = $service->product->servertype;

# Not cPanel, no links added
   if ($servertype!="cpanel"){
       return;
   }

   if (!is_null($primarySidebar->getChild('Service Details Actions'))) {
            $primarySidebar->getChild('Service Details Actions')
                           ->getChild('Login to Webmail')
                           ->setUri('http://'.$domain.':2096');
   }

});
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated