Metahuman Network Posted May 6, 2020 Share Posted May 6, 2020 I think it's fantastic that WHMCS separated the types of emails so clients can fine-tune. Great feature. I'm wondering if there's a way to hide some from the client area using a template's .tpl. IE We don't offer affiliate plans or domains. And would like to consolidate the Client portal down to the 4 remaining options. Is this possible? Thanks! 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted May 6, 2020 Share Posted May 6, 2020 6 hours ago, Metahuman Network said: I'm wondering if there's a way to hide some from the client area using a template's .tpl. IE We don't offer affiliate plans or domains. And would like to consolidate the Client portal down to the 4 remaining options. I know you don't use Six, but are you talking about the four tiles in the client area homepage ? (services/domains/quotes/affiliates/tickets/invoices) ? 0 Quote Link to comment Share on other sites More sharing options...
Metahuman Network Posted May 6, 2020 Author Share Posted May 6, 2020 Hey brian! Thanks for the reply. I'm trying to hide the actual checkboxes. I was hoping they would hide when those features are disabled. Trying to consolidate down to the 4 that are checked in the screenshot. I can get them to display proper status individually by copying the contacts page and adjusting names/id's, but the page errors upon saving. Possible? Just trying to minimize our client area as we only sell a handful of subscription services. Thanks! 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted May 6, 2020 Share Posted May 6, 2020 21 minutes ago, Metahuman Network said: Possible? Just trying to minimize our client area as we only sell a handful of subscription services. oh those email types - must have had a mental block when I read the post earlier... 🙄 <?php # Email Preferences Removal Hook # Written by brian! function email_preferences_removal_hook($vars) { $preferences = $vars['emailPreferences']; $emailPreferences = array_splice($preferences, 0, 4); return array("emailPreferences" => $emailPreferences); } add_hook("ClientAreaPageProfile", 1, "email_preferences_removal_hook"); add_hook("ClientAreaPageContacts", 1, "email_preferences_removal_hook"); the above hook should remove the last two items from that list and keep only the first four... ... and it should work on both the client details and contacts details pages. you could achieve the same by editing the two templates, but hooking would be better. 1 Quote Link to comment Share on other sites More sharing options...
Metahuman Network Posted May 6, 2020 Author Share Posted May 6, 2020 Thank you so much! Works perfectly and I see what I was missing now. Do you have a Buy Me A Coffee or anything!? ❤️ 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.