NicoKuroKusagi Posted September 30, 2017 Share Posted September 30, 2017 I dont get how to remove the Sidebar Items "Client Shortcuts" and "Client Contacts" on WHMCS Client-Area home... Version is 7.1 Any help? 0 Quote Link to comment Share on other sites More sharing options...
WHMCS ChrisD Posted October 1, 2017 Share Posted October 1, 2017 Nello @NicoKuroKusagi, Have you taken a look at the guides available at here 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted October 1, 2017 Share Posted October 1, 2017 https://whmcs.community/topic/248457-hook-can-not-hide-menu-entry/?do=findComment&comment=1155521 add_hook('ClientAreaSecondarySidebar', 1, function(MenuItem $secondarySidebar) { if (!is_null($secondarySidebar->getChild('Client Shortcuts'))) { $secondarySidebar->removeChild('Client Shortcuts'); } if (!is_null($secondarySidebar->getChild('Client Contacts'))) { $secondarySidebar->removeChild('Client Contacts'); } }); 1 Quote Link to comment Share on other sites More sharing options...
NicoKuroKusagi Posted October 1, 2017 Author Share Posted October 1, 2017 Thank you so much Brian! You are the best! Is this the same for the Announcements and Buy New Domain and so on? Or how to remove these "widgets" or change them? 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted October 1, 2017 Share Posted October 1, 2017 8 minutes ago, NicoKuroKusagi said: Is this the same for the Announcements and Buy New Domain and so on? Or how to remove these "widgets" or change them? generally yes - you just need to find out if they're using the Primary or Secondary sidebar, and their name... https://docs.whmcs.com/Client_Area_Sidebars_Cheatsheet viewing the source code in the browser will give you that information. the chances are, whatever you want to modify/change, there will already be a hook posted in these forums that would do it (or would be similar and could be adjusted). 0 Quote Link to comment Share on other sites More sharing options...
NicoKuroKusagi Posted October 1, 2017 Author Share Posted October 1, 2017 I see the name of it but where can i see if its primary or secondary? 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted October 1, 2017 Share Posted October 1, 2017 10 minutes ago, NicoKuroKusagi said: I see the name of it but where can i see if its primary or secondary? in the case of Client Contacts.. but if you know the name, and can't find out if it's primary/secondary, then just try one - if it doesn't work, try the other! if it's towards the top of the page, it might be primary - if it's in the cart pages, it will be secondary as the cart doesn't use primary sidebars. 0 Quote Link to comment Share on other sites More sharing options...
NicoKuroKusagi Posted October 1, 2017 Author Share Posted October 1, 2017 But how to remove this boxes... As they are no sidebar boxes 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted October 1, 2017 Share Posted October 1, 2017 they work in exactly the same way, but you use the homepagepanels hook instead of sidebar... https://whmcs.community/topic/271777-remove-news-amp-register-domain-section-in-client-area/?do=findComment&comment=1241469 <?php use WHMCS\View\Menu\Item; add_hook('ClientAreaHomepagePanels', 1, function (Item $homePagePanels) { $homePagePanels->removeChild('Register a New Domain'); }); 0 Quote Link to comment Share on other sites More sharing options...
NicoKuroKusagi Posted October 1, 2017 Author Share Posted October 1, 2017 You are the best! 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.