Jump to content

Customization SixTemplate


vam87t

Recommended Posts

Hello,

 

from WHMCS6 I use the six template, this template is different from five and old template, and I have serius issue for customize it.

 

Into my client area homepage, I see the "panel tab" > Domains Expiring Soon, the problem is that we not permit to the customer to renew the domain manually, so when you click "Renew Now" the WHMCS refresh the page and not do any action. This is an problem, because many customer think that there is an error into ClientArea.

 

There is anyone that know how can I change the link of "Domains Expiring Soon" from actual: cart.php?gid=renewals to for example: clientarea.php?action=domains?

 

Same thing for "alter notification bar", I have the same problem.

 

I try to read the documentation of WHMCS; but I understend only how can I add an new PanelTab or remove the actual.

 

Thanks for the help

 

Regards

Link to comment
Share on other sites

There is anyone that know how can I change the link of "Domains Expiring Soon" from actual: cart.php?gid=renewals to for example: clientarea.php?action=domains?

create a file called "domainexpirypanel.php" (or anything you like!), add it to includes/hooks and add the following code to it...

 

<?php
use WHMCS\View\Menu\Item;

add_hook('ClientAreaHomepagePanels', 1, function (Item $homePagePanels)
{
       $homePagePanels->getChild('Domains Expiring Soon')
                       ->setExtra('btn-link','clientarea.php?action=domains');
});

this will change the link on the panel to the one you wish. :idea:

 

Same thing for "alter notification bar", I have the same problem.

that's a good question - I don't know if notifications (alerts) can be modified or deleted... though they can be easily added... as with other aspects of these new features, the documentation isn't great (or anywhere near complete). :roll:

 

other options to look at might be to remove the notifications section from the header.tpl; modify the order-form template/domainrenewals.tpl template to remove the option to renew the domains, or perhaps use htaccess to redirect visitors from cart.php?gid=renewals -> clientarea.php?action=domains

Link to comment
Share on other sites

Hello

 

the hooks works fine thanks.

 

About the "alert" even if I do the 301, the redirect not works, because when you click the option into "alert" the result is Always rdirect into clientarea.php page.

 

The redirect code is that

 

RewriteRule cart.php?gid=renewals http://domain.tld/page [L,NC,R=301]

 

If I do into browser http://domain.tld/page the redirect works fine, but from WHMCS no.

 

Any idea?

 

Thanks

 

Regards

Link to comment
Share on other sites

do you mean the notifications bar shown in the image below ? you want to change the "Renew Now" link ??

 

JU6LsNS.png

 

i'm not aware of any way to change that link - support might be able to help (if so, let the rest of us know their answer!) or perhaps someone else on the forum knows.

Link to comment
Share on other sites

do you mean the notifications bar shown in the image below ? you want to change the "Renew Now" link ??

 

JU6LsNS.png

 

i'm not aware of any way to change that link - support might be able to help (if so, let the rest of us know their answer!) or perhaps someone else on the forum knows.

 

Yes I mean that. I opened an support request to WHMCS.

 

About your hooks unfortunatly not works well, I receive from client area this error

 

Fatal error: Call to a member function setExtra() on a non-object in /var/www/vhosts/root/httpdocs/clients/includes/hooks/panel_boxdomainexpires.php on line 7

 

Solution?

 

Regards

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