Jump to content

Leaderboard


Popular Content

Showing content with the highest reputation since 01/17/20 in all areas

  1. 12 points
    in v8, the summary stats were removed from the admin display - e.g Pending Orders, Overdue Invoices and Tickets Awaiting Reply - the simple hook below adds them back to the output in a similar location (top of the page)... <?php # Stats Info Bar for v8 Blend # Written by brian! use WHMCS\Database\Capsule; use WHMCS\Billing\Invoice; function admin_v8_infobar_hook($vars) { $pendingstatuslist = Capsule::table('tblorderstatuses')->where('showpending','1')->pluck('title'); $pendingorders = Capsule::table('tblorders')->whereIn('status',$pendingstatuslist)->count(); $overdueinvoices = Invoice::overdue()->count(); $awaitingreplylist = Capsule::table('tblticketstatuses')->where('showawaiting','1')->pluck('title'); $ticketsawaiting = Capsule::table('tbltickets')->whereIn('status',$awaitingreplylist)->count(); $headerreturn = '<div style="margin: 0; padding: 5px; background-color: #1a4d80; display: block; width: 100%; max-height: 20px;"> <div style="text-align: center; color: #fff; font-size: .8em; margin: 0;"> <a href="orders.php?status=Pending" style="color: #fff;"><span style="font-weight: 700; color: #fc0;">'.$pendingorders.'</span> '.AdminLang::trans('stats.pendingorders').'</a> | <a href="invoices.php?status=Overdue" style="color: #fff;"><span style="font-weight: 700; color: #fc0;">'.$overdueinvoices.'</span> '.AdminLang::trans('stats.overdueinvoices').'</a> | <a href="supporttickets.php" style="color: #fff;"><span style="font-weight: 700; color: #fc0;">'.$ticketsawaiting.'</span> '.AdminLang::trans('stats.ticketsawaitingreply').'</a> </div> </div>'; return $headerreturn; } add_hook("AdminAreaHeaderOutput",1,"admin_v8_infobar_hook"); this was originally written for v8.0.0 betas, but the code has now been updated for v8.0.1 (where the $sidebarstats array no longer exists and the values now have to be calculated from database queries).
  2. 7 points
    i've posted the hook for the admin info bar in the thread below - should work on both v8.0.0 and v8.0.1 πŸ™‚
  3. 5 points
    I've seen there's a feature request submitted 7 years ago about bulk auto recalculate. I know you can do that from phpMyAdmin or with a script but enough is enough. <? /** * Bulk Auto Recalculate Client Domain & Products/Services * * @writtenby Kian * */ use WHMCS\Database\Capsule; add_hook('AdminAreaHeaderOutput', 1, function($vars) { if ($vars['filename'] == 'clientssummary' AND $_GET['userid'] AND in_array($_GET['kata'], array('bulkAutoRecalculateP', 'bulkAutoRecalculateD'))) { $adminUsername = ''; // Optional for WHMCS 7.2 and later if ($_GET['kata'] == 'bulkAutoRecalculateP') { foreach(Capsule::table('tblhosting')->where('userid', '=', $_GET['userid'])->pluck('id') as $v) { localAPI('UpdateClientProduct', array('serviceid' => $v, 'autorecalc' => true), $adminUsername); } header('Location: clientssummary.php?userid=' . $_GET['userid']); die(); } elseif ($_GET['kata'] == 'bulkAutoRecalculateD') { foreach (Capsule::table('tbldomains')->where('userid', '=', $_GET['userid'])->pluck('id') as $v) { localAPI('UpdateClientDomain', array('domainid' => $v, 'autorecalc' => true), $adminUsername); } header('Location: clientssummary.php?userid=' . $_GET['userid']); die(); } } return <<<HTML <script> $(document).ready(function(){ $('[href*="affiliates.php?action=edit&id="], [href*="clientssummary.php?userid="][href*="&activateaffiliate=true&token="]').closest('li').after(('<li><a href="#" id="kata_BulkAutoRecalculate"><i class="fas fa-fw fa-sliders-h" style="width:16px;text-align:center;"></i> Bulk Auto Recalculate</a></li>')); $('#kata_BulkAutoRecalculate').on('click', function(e){ e.preventDefault(); $('#modalAjaxTitle').html('Bulk Auto Recalculate'); $('#modalAjaxBody').html('<div class="container col-md-12"><div class="row"><div class="col-md-6 text-center"><div class="panel panel-default"><div class="panel-body"><p><i class="fas fa-box fa-5x"></i></p><p><small>Auto Recalculate Customer\'s <strong>Products/Services</strong></small></p><p><a href="clientssummary.php?userid={$_GET['userid']}&kata=bulkAutoRecalculateP" class="btn btn-info btn-block">Recalculate Now Β»</a></p></div></div></div><div class="col-md-6 text-center"><div class="panel panel-default"><div class="panel-body"><p><i class="fas fa-globe fa-5x"></i></p><p><small>Auto Recalculate Customer\'s <strong>Domains</strong></small></p><p><a href="clientssummary.php?userid={$_GET['userid']}&kata=bulkAutoRecalculateD" class="btn btn-info btn-block">Recalculate Now Β»</a></p></div></div></div></div></div>'); $('#modalAjax .modal-submit').addClass('hidden'); $('#modalAjaxLoader').hide(); $('#modalAjax .modal-dialog').addClass('modal-lg'); $('#modalAjax').modal('show'); }) }) </script> HTML; });
  4. 4 points
    Although it seems small but for us the users every extra action we need to do is important. Please bring back the fixed search box as I am sure every one is using it many times everyday. Thank You Giora
  5. 4 points
    I'll have to stop you right there, John. The same thing goes for regular clients. In theory, you could just change their details. It's just a hell lot easier to delete everything than to have hundreds of inactive users (all with unique email addresses). ... And so can a client. But - if the client wants their account deleted, we should (and must) delete it. If a user (not a client) actually decides to contact us and asks us to have their account removed, why shouldn't we be able to delete it? Sorry, but I just can't wrap my head around why a 'Delete User' button and/or API function has been made. Reasoning? We're forced to delete data about a client if the client requests it. Not doing so is punishable with huge fines. In 2018, WHMCS made a lot of steps to make it look like they cared about GDPR - and then they basically ruined it with a single update and can't understand why we feel something is wrong. Please, please, please, please (!!!!!) let us know why it has now taken 3 releases (I reported it before GA) and there's still no solution to this. It's really just a matter of deleting the user the same way that a client is deleted. Sorry about my tone in this reply, my it really frustrates me. You can't make a release that is so GDPR focused back in 2018 and then ruin it two years later saying: "You know, you can just manually edit out the personal information for each user" - WE COULD VERY WELL DO THAT WITH CLIENTS AS WELL BEFORE 2018, It's just a lot easier NOT having to do that.
  6. 4 points
    Hi everyone! Since I spend most of my time during the day on the WHMCS admin dashboard, answering tickets, activating services, following up with stuff, etc. I wanted to keep eye strain to a minimum, so I recently created this CSS file to turn our admin area into a dark look and feel. ------- Today, I'd like to share with you steps to achieve that. The file is compatible with Blend theme of v7.9.2 of WHMCS, I haven't tested it on the other versions yet. The process is pretty simple and straightforward IF YOU HAVEN'T MADE ANY CUSTOMIZATIONS to your Blend theme already. So just download the attached file (blend-dark.zip) and extract it anywhere in your computer. Next, open the folder and then the "images" folder to locate the (logo-dark.psd) file to edit it by placing your own logo there. Then save it as "logo-dark.gif" replacing the already existing file. Now you should end up with a file tree like this ... blend |__ css | |__ admin-dark.css | | |__ images | |__ logo-dark.gif | |__ logo-dark.psd | |__ header.tpl Now back top and compress your "blend" folder ... Name it something memorable, like "blend-2222.zip" in this example. Next navigate to the "admin" folder inside your WHMCS installation, and open the "templates" folder (based on your customizations, the "admin" folder name may differ, so this here presumes the default setting). /path/to/whmcs/admin/templates/ Next make sure to ZIP and backup your current Blend theme folder (name it something like "blend-original.zip). Next, upload the "blend-2222.zip" you compressed earlier to the "templates" folder and unzip it, and you should be all set and ready! If you have any notes or additions, please feel free to add! Also, any mistakes or errors are unintentional, please feel free to share and highlight them. Wishing everyone a good day! - Mohamed
  7. 3 points
    Seeing as WHMCS don't have a list of the bugs they have had reported and are working on, I thought I'd create this thread to track the current 8.1 GA bugs. If you find any, please let me know and I will edit this post to add them (hopefully I have enough permission to do so). Below is the list of ones I am aware of: CORE-16022 double validation warning password reset page: https://whmcs.community/topic/304324-twenty-one-template-minor-tweaks/?do=findComment&comment=1346483 CORE-16025 twenty one theme hard coded strings: Twenty one theme hard-coded string - WHMCS 8.1 Beta Discussion Board - WHMCS.Community CORE-16026 client email history missing: https://whmcs.community/topic/304324-twenty-one-template-minor-tweaks/?do=findComment&comment=1346510 (this might be a showstopper for you) PS WHMCS staff you are welcome to edit this post of mine to add any other bugs currently being worked on if you like.
  8. 3 points
    in v7 and earlier, you could right-click on the "Login As Client" link and open it in a new tab - useful if you need to see both admin and client areas at the same time. in v8, "Login As Owner" now uses a form and you can't right-click on it to open a new tab... *sighs* πŸ™„ so the simple hook below will open that link in a new tab by default... <?php # Login As Owner Open In New Tab Hook # Written by brian! function admin_login_as_owner_hook($vars) { if ($vars['filename'] == 'clientssummary' && isset($_GET["userid"])) { return '<script>$("#frmLoginAsOwner").prop("target","_blank");</script>'; } } add_hook("AdminAreaFooterOutput", 1, "admin_login_as_owner_hook"); you could edit the clientssummary.tpl template too and just add the target link to the form code.
  9. 3 points
    Happy New Year! We are pleased to announce we have released a Hotfix for this issue:
  10. 3 points
    i'm pretty sure that I haven't bothered to install any hotfixes in the v8.0.4 dev. give @web2008 a medal... πŸ₯‡ ... *now* I can reproduce the exact error that @xyzulu is seeing - and all I had to do was to replace the default version of /includes/ticketfunctions.php with the version in the CORE-15639 hotfix... reverting back to the version of the file that was already there (which must be the v8.0.3 version as there wasn't an update to that file in the v8.0.4 incremental patch) allows the form to work as normal. πŸ™‚ in that hotfix, there are other files within the/vendor folder that I haven't bother to test - so potentially they might have an impact on this too. if @xyzulu isn't piping, then I suspect just swapping the v8.0.3 or later version of the file should get him through until later, more "stable", v8.1 versions are available. only WHMCS could think of launching a major release GA in the week of Christmas - prepare for v8.1.1 before the New Year everyone. πŸ™„ frankly, i'd prefer to see a fix to the hotfix and delaying the GA until next month... but maybe i'm biased cos I was planning on a relaxing Xmas break! πŸŽ„
  11. 3 points
    even if there was a hotfix, WHMCS doesn't automatically tell you about it's existence... i'm going to have a look again at doing something about this. if you got a ticket opened an hour ago, that was me testing your form - and yes I did see the oops error... FWIW, if I do the same on my v8 dev, no similar error occurs and the ticket gets created.... the value of 0 is passed to the userid column rather than null. oh I so miss the days when bug reports were posted through this place and you then had an idea where the errors are and could look out and work around them... instead of finding out either a) when you got them yourselves or b) when the changelog suggests that they think they've fixed it. now you're in a position were your guest ticket might not work correctly - and the WHMCS solution might come in the next 5 minutes, 5 days, 5 weeks or might he held back for v8.1 and you're then almost obliged to update to fix it. i've said it before - WHMCS are one of the worst communicating companies i've ever seen... in many ways, they've got worse over the years and I bet nothing changes in the New Year.
  12. 3 points
    Hello I am missing the Waiting Tickets, Unpaid invoices and Orders on top, It was very useful and I have to take extra steps now. 😞 Giora
  13. 3 points
    in Smarty, it would be... {$tldpricing2.pricing.$tld2.register[1]} to return a 1 year registration price, in the current currency. https://classdocs.whmcs.com/8.0/WHMCS/View/Formatter/Price.html probably because they can be more flexible to manipulate than if they were strings. in Smarty, it would be... {$tldpricing2.pricing.$tld2.register[1]->toNumeric()}
  14. 3 points
    i'll guarantee that there is at least one existing bug that hasn't been fixed in v8.0.3 - I saw its error in the activity log on Monday (in v8.0.2) by chance and it's seemingly caused by one of the Six templates trying to use a feature that is now prohibited by the Smarty Security Policy.... you gotta love how the internal testing was so thorough that they don't even know when/how/why a template that they wrote is breaking the arbitrary security policy that they imposed.
  15. 3 points
    WHMCS v8.15.2 - Admin Area refreshed (old menu returns - due to public demand demonstrated by a 2-vote feature request gaining traction!). 😜
  16. 3 points
    Hi all, I'm pleased to confirm that v8.0.2 addressed the issue related to domain sync Next Due Dates and an improvement to the reporting when an invalid domain is encountered: CORE-15468 - Correct reporting of Domain Sync Next Due Dates CORE-15461 - Provide context for Invalid Domain errors in Domain Sync Thank you for reporting those issues.
  17. 3 points
    indeed. I think the issue might be that the existing query is counting merged tickets and that's inflating the count... when I ran a test of the results, the WHMCS sidebar was telling me there were 37 tickets awaiting replies... the infobar was telling me 38 - and the one ticket that wasn't included in the sidebar was a merged ticket. <?php # Stats Info Bar for v8 Blend # Written by brian! use WHMCS\Database\Capsule; use WHMCS\Billing\Invoice; use Carbon\Carbon; function admin_v8_infobar_hook($vars) { if ($vars['template'] == "blend") { $pendingstatuslist = Capsule::table('tblorderstatuses')->where('showpending','1')->pluck('title'); $pendingorders = Capsule::table('tblorders')->whereIn('status',$pendingstatuslist)->count(); $overdueinvoices = Invoice::overdue()->count(); $awaitingreplylist = Capsule::table('tblticketstatuses')->where('showawaiting','1')->pluck('title'); $ticketsawaiting = Capsule::table('tbltickets')->whereIn('status',$awaitingreplylist)->where('merged_ticket_id','0')->count(); $current_time = Carbon::now()->translatedFormat("l, j F Y, H:i"); $headerreturn = '<div style="margin: 0; padding: 5px; background-color: #1a4d80; display: block; width: 100%; max-height: 20px;"> <div style="text-align: center; color: #fff; font-size: .8em; margin: 0;"> <a href="orders.php?status=Pending" style="color: #fff;"><span style="font-weight: 700; color: #fc0;">'.$pendingorders.'</span> '.AdminLang::trans('stats.pendingorders').'</a> | <a href="invoices.php?status=Overdue" style="color: #fff;"><span style="font-weight: 700; color: #fc0;">'.$overdueinvoices.'</span> '.AdminLang::trans('stats.overdueinvoices').'</a> | <a href="supporttickets.php" style="color: #fff;"><span style="font-weight: 700; color: #fc0;">'.$ticketsawaiting.'</span> '.AdminLang::trans('stats.ticketsawaitingreply').'</a> | '.$current_time.' </div> </div>'; return $headerreturn; } } add_hook("AdminAreaHeaderOutput",1,"admin_v8_infobar_hook"); if you tell me that works, i'll delete this thread and repost to avoid confusion for others about which version to use.
  18. 3 points
    don't worry - everyone's having a collective migraine trying to get their heads around this nonsense. πŸ€• the session cart array no longer exists, so every $smarty.session.cart solution that's ever been posted will now fail... oh what fun. πŸ™„
  19. 3 points
    methinks he was being sarcastic - as the three of us all posted in that now-deleted (sorry hidden!) thread... which, for the benefit of others, is worth mentioning that it was started at the beginning of August (2 months ago)...
  20. 3 points
    it is possible to add the details back with a hook (i'm still tidying up the CSS and testing on other devices)... it's probably also worth mentioning that from my limited texting of the GA so far, the blend theme from v7.10.2 still appears to work on v8 - if you still want to use the old layout in the short-term.... if updating to v8 and wanting to use the old theme, then uploading the old blend folder from a v7.10.2 download to the /admin/templates folder, e.g call it blend7 (don't overwrite the existing v8 blend theme as those changes would get overwritten during an update) - then you can switch themes in the "My Account" section. from a quick test, there is a missing language string in the help menu, and the setup title as been changed - but if you correct those with Admin Language Overrides, then it looks like this... <?php $_ADMINLANG['setup']['title'] = "Setup"; $_ADMINLANG['help']['support'] = "Get Help"; Mass Mail is called Email Campaigns now, but the URL hasn't changed... intellisearch still works... some of the sidebar icons might be missing, but I suspect that's caused more by the v8 dev being a fresh install rather than an updated v7 with previously existing v7 image files. i'm still working on other solutions to fix the hideous v8 menu system...
  21. 3 points
    This is correct. @WHMCS John Would request to add this section in some form, perhaps as notification icons or dropdowns if space is an issue ?
  22. 3 points
    This was the most useful information shown on the admin dashboard. Unbelievable that such critical information has been removed.
  23. 3 points
    For v8 I really would like WHMCS to separate the market connect files, that includes the languages and the module. Have it as a separated download or installation. MarketConnect is a very different customer target to the original WHMCS clients. I surely don't need uploading and upgrading all those extra files for something I have no interested on using. I also paid the non-branded version but I see that lately WHMCS keeps renaming more and more files to whmcs.ext, in particular CSS and JS on the frontend. Personally I think this defeats the remove the branding option license. Its undesired for most installations as bots and spammers constantly scan WHMCS installations. This is not going to protect against security but I don't think it's a great idea to expose the WHMCS name on every single file. It also looks sloppy from the developing naming side. In the past WHMCS used more generic names for files which was a better fit because naming something WHMCS.js does not really tell me anything about what that file does and its purpose either. Files should be named based on what they do. Changes like this require almost no effort on WHMCS part or their development team and it would at least improve something. WHMCS is getting huge and I seriously think there are so many redundant files and things that most people don't need. It's not about saving space, but just being more efficient. I don't need thousands of files living on a production server that I will never use.
  24. 3 points
    Hello @WHMCS Sachin Thanks for letting us be more open to share our ideas.πŸ˜„ Al WHMCS users like this software a lot, so even that we know that software belongs to WHMCS, we would like to have it with our branded name on it, so my suggestion is that app could import our company name (that already exists on WHMCS admin>Setup>General settings) And display that name on app somewhere, on top or not, it is up to WHMCS where would be more convenient during developing , my print suggestion bellow. PS: this option to show company name could be also optional, so this mean if a user do not want to see their company name there , he\she could go to app settings and disable it with tick on\off so every one will be happy. Personally I think having a possibility to see our company name on APP make, make us feel like ...this is our app too, also perhaps could be users that have several WHMCS installations, so when they switch from one to another they could know easily on what installation is πŸ‘Œ
  25. 3 points
    I think you've really overcomplicated this by using multiple hooks and the way you're using each of them - it can be simplified to something more clearer... in fact, it could be reduced far more than i'm going to post here as i'm trying to keep it understandable for all. to a certain extent, that bit is fine... i'd argue that removing the affiliates link for everyone, then wanting to add it back just for clients, is a little silly - just remove it for non-clients. i'm not sure that you have going from that screenshot. you have to be careful because just one character wrong and it won't necessarily throw an error, the hook just won't work. out of the box, I don't think that Lagom does anything kinky with the navbars (other than to split the primary / secondary locations) - using hooks on them should still work... and i'm speaking as someone who was generously given a Lagom developers license by a client. 😎 one way I would write that hook would be... <?php add_hook('ClientAreaPrimaryNavbar', 1, function($primaryNavbar) { $client = Menu::context('client'); # remove for all if (!is_null($primaryNavbar->getChild('Home'))) { $primaryNavbar->removeChild('Home'); } # remove for non-clients if (is_null($client) && !is_null($primaryNavbar->getChild('Store'))) { $primaryNavbar->removeChild('Store'); } if (is_null($client) && !is_null($primaryNavbar->getChild('Affiliates'))) { $primaryNavbar->removeChild('Affiliates'); } if (is_null($client) && !is_null($primaryNavbar->getChild('Knowledgebase'))) { $primaryNavbar->removeChild('Knowledgebase'); } if (is_null($client) && !is_null($primaryNavbar->getChild('Announcements'))) { $primaryNavbar->removeChild('Announcements'); } # add for non-clients if (is_null($client)) { $primaryNavbar->addChild('hosting')->setLabel(Lang::trans('Hosting'))->setOrder(11); if (!is_null($primaryNavbar->getChild('hosting'))) { $primaryNavbar->getChild('hosting')->addChild('sharedhosting')->setLabel(Lang::trans('Shared Hosting'))->setURI('cart.php?gid=1')->setOrder(1); $primaryNavbar->getChild('hosting')->addChild('wordpresshosting')->setLabel(Lang::trans('WordPress Hosting'))->setURI('cart.php?gid=34')->setOrder(2); } $primaryNavbar->addChild('ecommerce')->setLabel(Lang::trans('Ecommerce Hosting'))->setOrder(12); if (!is_null($primaryNavbar->getChild('ecommerce'))) { $primaryNavbar->getChild('ecommerce')->addChild('ecommerce1')->setLabel(Lang::trans('CS-Cart Hosting'))->setURI('cart.php?gid=36')->setOrder(1); $primaryNavbar->getChild('ecommerce')->addChild('ecommerce2')->setLabel(Lang::trans('Magento Hosting'))->setOrder(2); } $primaryNavbar->addChild('vps')->setLabel(Lang::trans('Virtual Private Servers'))->setOrder(13); if (!is_null($primaryNavbar->getChild('vps'))) { $primaryNavbar->getChild('vps')->addChild('vps1')->setLabel(Lang::trans('VPS Cloud Shared'))->setURI('cart.php?gid=33')->setOrder(1); $primaryNavbar->getChild('vps')->addChild('vps2')->setLabel(Lang::trans('VPS Cloud Dedicated'))->setURI('cart.php?gid=31')->setOrder(2); } $primaryNavbar->addChild('dedicated')->setLabel(Lang::trans('Dedicated Servers'))->setURI('cart.php?gid=14')->setOrder(14); $primaryNavbar->addChild('cscart')->setLabel(Lang::trans('CS-Cart'))->setOrder(15); if (!is_null($primaryNavbar->getChild('cscart'))) { $primaryNavbar->getChild('cscart')->addChild('cscartlicenses')->setLabel(Lang::trans('CS-Cart Licenses'))->setURI('cart.php?gid=2')->setOrder(1); $primaryNavbar->getChild('cscart')->addChild('cscarthosting')->setLabel(Lang::trans('CS-Cart Hosibg'))->setURI('cart.php?gid=36')->setOrder(2); } } # add for clients only if (!is_null($client)) { $primaryNavbar->addChild('kb')->setLabel(Lang::trans('knowledgebasetitle'))->setURI('knowledgebase.php')->setOrder(50); } }); possibly an oversight on your part, but the magento child doesn't contain a link. in terms of how to add menu items for logged in users, i've done that at the end of the above hook where i've added a kb link back in for clients only. if you mean Services/Domains/Billing/Support, and removing them entirely/individually, then you don't really need to check whether the user is logged in or not - the same as you don't need to (though I do in the above hook) check that the client is not logged in when removing the "Store" link... it doesn't matter because only non-clients see the store link, clients don't (at least out of the box)... as an aside, you could nuke them with about 4 lines of code if you had to - but there are only four elements to remove, so let's not be deploying weapons of mass destruction for something so small. ☒️ note this quick method works because these default navbar children have unique names - if you had a situation where a link exists in both logged non-logged navbars (home being the obvious example), and you wanted to change their links depending on client logged in status, then under those circumstances, you would check first whether they were logged in or not... but I think for your purpose, you won't have to. so if you wanted to remove the Services tab for logged in users... if (!is_null($primaryNavbar->getChild('Services'))) { $primaryNavbar->removeChild('Services'); } that works because it checks to see of the parent exists, and only if it does, does it try to remove it - so for a non-client, it wouldn't get past the if statement. for kb, see above; for affiliates, I solved the issue by only removing it for non-logged in users - for new menu items, see above (re: kb and how I added the non-logged in parents with their kids).
  26. 3 points
    Hi Mohamed, <?php function admin_custom_css_hook($vars) { $currenttemplate = $vars['template']; if ($currenttemplate == "blend" ) { $head_return = ''; $head_return = '<link href="templates/blend/css/admin-dark.css" rel="stylesheet" type="text/css" /> <script type="text/javascript"> $(document).ready(function() { $(\'.header .logo img\').attr(\'src\', \'templates/blend/images/logo-dark.gif\'); }) </script>'; return $head_return; } } add_hook("AdminAreaHeadOutput",1,"admin_custom_css_hook"); there was two bugs in the original hook - first, it was changing the logos on the marketconnect pages with your logo(!)... i've fixed that by being more accurate with the logo .css reference in the hook. the second bug is when you look at admin pages that appear to be in a subdirectory (due to Friendly URL settings), e.g the setup pages for notifications, security settings etc, the logo is broken - that's purely down to the path to the image being wrong... I suspect that would be fixed by either expanding the hook for those conditions or referencing the replacement image with a full URL rather than a relative path.
  27. 3 points
    why? are they going to have a survey or a vote on what to add ?? (even if they did, how many users would vote??) no - they will already know what's going to change, and the user base will either have to like it or lump it.
  28. 3 points
    then you take @baymax's query and change the where statement... UPDATE tblclients SET groupid='new-group-ID' WHERE email LIKE '%@hotmail.com';
  29. 3 points
    maybe this query if all 60 clients are in the same group currently. UPDATE tblclients SET groupid='new-group-ID' WHERE groupid='current-group-ID'; Replace the parts in green.
  30. 3 points
    You can try this hook: https://github.com/Jetserver/WHMCS-Reply-Above-This-Line
  31. 3 points
    then you wouldn't use this hook, you would instead use ClientAreaProductDetailsOutput hook and specify what output occurs with specific service(s). <?php add_hook('ClientAreaProductDetailsOutput', 1, function($service) { $serviceID = $service['service']->Id; if ($serviceID == '600') { $output .= '<div class="alert alert-success" role="alert"><div class="row"><div class="col-sm-1"><i class="fab fa-whmcs fa-3x"></i></div><div class="col-sm-11">Welcome to WHMCS!<br><small>buy the addon!</small></div></div></div>'; } if ($output) { return $output; } }); it's worth noting that the location of this specific hook output is determined by the Smarty template and not the hook itself - if you were displaying MarketConnect banners on that page, it would display below them. if you have an unpaid/overdue invoice, then there is a default alert shown at the top of the page... ... but that output is specified in the template itself and only triggered if/when hardcoded conditions are passed to the template. if you wanted to output your alert elsewhere on the page, you would be looking at either editing the template to define exactly where the output should be (you could still trigger it, and specify it's content, with a hook), or using another output hook, containing JS to specify the exact location of the output (though can be difficult depending on where you want to output).
  32. 3 points
    Pretty simple to treat it like a typical config file in a lot of software. custom.css.txt (with a note to rename it)
  33. 3 points
    I was just about to suggest the same thing. πŸ™‚
  34. 3 points
    One thing to note is that WHMCS will redirect from contact.php to submitticket.php (your specific department) if you select a ticket department under WHMCS admin > setup > general settings > mail > Presales Form Destination
  35. 3 points
    then buy the Client Notifications addon! πŸ™„ <?php add_hook('ClientAreaHomepage', 1, function($vars) { return '<div class="alert alert-success"><div class="row"><div class="col-sm-1"><i class="fab fa-whmcs fa-3x"></i></div><div class="col-sm-11">Welcome to WHMCS!<br><small>buy the addon!</small></div></div></div>'; }); you could always log into their demo if you want to steal their div layout code, but you'd likely have to copy and adapt their css too.
  36. 2 points
    it should be waiting for the next cron run to occur - so if you're running the cron hourly, then it should occur within the next hour; if you running the cron every 5 mins, then it should have already begun.
  37. 2 points
    I know plenty of enterprise systems, far better in security than WHMCS. All of them (admin back end) lets you force a user password change. What purposes does a back end have if you cannot manipulate data...???? From a security standpoint removing this has NO, ZERO effect on the account's security. Forcing a user's password is still hashed, it's not saved in clear text. No risk involved. If WHMCS assumption is here "We don't want, you to know YOUR customers password" this is idiotic. It's my customer, not theirs. As you said, you can just use a dummy email account and still know the password, they now just add another layer of complication to the equation. Also, we already have full access to the database, I can manually change whatever password I want and still know my customers passwords because it's my data. And without mentioning that, well WE DON'T need the customers password in the first place as we can just impersonate the account. We don't care about the user's password. And finally, you can make a hook that does the same. What is the purpose of WHMCS removing this besides making it more complex and killing an especially useful feature in the back end? The only thing that comes to my mind is they don't want your staff to randomly change users' passwords. If this is the WHY they did this, it's a dumb approach. They should just add a permission and problem solved. That way we as admins can set specific staff users not to have the option to change a password or impersonate a user. Therefore permissions exist and you can give or remove specific permissions to your staff. Now completely removing the function is just going nuclear and making the whole admin side less useful. It makes no sense. Forcing a user's password change is one of the most, if not the most common tasks someone will look on a user's account. It seems WHMCS thinks that everyone using WHMCS just has random users online from a website. Don't they understand that some of us know our customers in person? And they are in front of us and we need to tell them now "Sorry, our fancy billing system does not let us change your password manually" This is seriously a joke. An admin software that does not let you change user's password. Then again, I'm not surprised because in v8 it seems you cannot remove users either. People are complaining about this because they either did not upgraded yet or are not even aware something this BASIC was removed from the customer profile. The devil in me tells me something different. I suspect why they are removing things like that. WHMCS is trying to slowly kill the self-hosted edition of WHMCS and move it to a cloud service. Then it makes no sense to offer things like this because you don't have access to the database. Their whole final idea is lock in. The self-hosted edition will be killed, and you will have to pay them monthly to use WHMCS and store your database with them. And your data and customers is now theirs. And eventually they will even email your customers directly and try to sell them things directly and claim it was a mistake. I saw this so many times. This is speculation but this is the only reason I can think why they don't added features like removing sub accounts in v8 or why they remove the password change feature. If someone takes a deep look at what they are adding in terms of features and removing, it all points to a version that will be cloud only and self-hosted killed. This is why they are slowly locking things down more and more and removing things that only makes sense on a self-hosted server edition. WHMCS will claim otherwise but just see each release and what brings and what it removes, and all things start to make sense. I suspect our future with WHMCS is already compromised. I refuse to believe they are doing this things by mistake because nobody would think removing something like this makes any sense at all or not adding a way to remove sub contacts in v8. The reason is they don't need customers to remove things. In their cloud service they will bill per users and customers and they will remove them from their back end. They don't want you to manipulate the database because it will be billed from their side. They already are moving towards that, owned license cannot be purchased anymore. Only leased. Then they introduced it billing by number of customers (your WHMCS now transfers that data) and they already confirmed here in the community that they plan a cloud hosted edition. Eventually they will move towards that and bill for everything, based on the number of customers, products, etc. Maybe even a % of your income in the future. This is why the marketplace makes so much sense for them. Of course they will lose most customers that cannot host billing & users data with them for compliance and regulatory reasons. But I suspect they don't care. Lucky for us, there are alternatives. I'm very disappointed with how the future looks with WHMCS because there is none for us that host it with our own servers. Granted, this is all speculation but the changes they are doing since version 6 are pointing towards that. Its all about vendor lock in.
  38. 2 points
  39. 2 points
    OK, Ive been using WHMCS 8.0 for over a day now and the click to view search in the top right corner is driving me mad. It needs to be visible always. The way it seems to autohide sometimes when im trying to use it causes a loss of productivity. (try selecting text in it from right to left - like your going to then paste over it) and the search box hides itself.. Arrrhh.. Surely im not the only one?
  40. 2 points
    That looks more like someone trying to gain counted posts to me. πŸ˜‰
  41. 2 points
  42. 2 points
    The following hook allows customers to login to Plesk, cPanel, DirectAdmin and any other panel directly from My Services list. Here's a preview (last column). Below I'm going to post the action hook but keep in mind that you'll need to make some changes to a couple of template files. The hook works with any control panel. The only requirement is that servers and products have been configured correctly. <?php /** * Auto-Login to cPanel/Plesk from My Services * * @written_by Kian */ use WHMCS\Database\Capsule; add_hook('ClientAreaPage', 1, function($vars) { if ($vars['filename'] == 'clientarea' AND $_GET['action'] == 'services') { $productIDs = Capsule::select(Capsule::raw('SELECT t1.id, t2.type FROM tblhosting AS t1 LEFT JOIN tblservers AS t2 ON t1.server = t2.id WHERE t1.userid = ' . $_SESSION['uid'] . ' AND t1.server != "0" AND t1.domainstatus IN ("Active", "Suspended") AND t1.username IS NOT NULL AND t1.password IS NOT NULL AND t2.type IS NOT NULL')); foreach ($productIDs as $v) { $output['kt_autologin'][$v->id] = $v; } return $output; } }); add_hook('ClientAreaHeadOutput', 1, function($vars) { if ($vars['filename'] == 'clientarea' AND $_GET['action'] == 'productdetails' AND $_GET['id'] AND $_GET['autologin']) { return <<<HTML <script type="text/javascript"> $(document).ready(function() { $("#domain form").removeAttr('target'); $("#domain form").submit(); }); </script> HTML; } }); Open your templates/{YOUR_TEMPLATE}/clientareaproducts.tpl where we need to add the new column. Let's begin from thead section. Add a new column like follows. Replace "Manage" defining a $LANG variable for multi-language support. Next move to tbody right inside foreach loop. Create a new cell like follows. <td class="text-center"> {if $kt_autologin[$service.id]} <div class="btn-group btn-group-sm plesk-login" style="width:60px;"> <a href="clientarea.php?action=productdetails&id={$service.id}&autologin=1" class="btn btn-primary btn-xs" alt="Click to Login" title="Click to Login" style="padding: 2px 5px;"><img src="templates/{$template}/img/katamaze_autologin/{$kt_autologin[$service.id]->type}.png" style="height:22px; max-width:39px"> <i class="fa fa-sign-in fa-fw" aria-hidden="true"></i></a> </div> {/if} </td> Replace "Click to Login" (alt and title attributes) with a $LANG variable. To display Plesk, cPanel, DirectAdmin (...) logo inside the button, create this directory templates/{YOUR_TEMPLATE}/img/katamaze_autologin. Here you have to add all logos in PNG format. The name of the file should be equal to module's system name: plesk.png cpanel.png directadmin.png etc. Now we have to disable sorting for the newly added column. At the very top of your template there's the following statement. Change (or add) noSortColumns="4" accordingly. "4" means that the 5th column will be not sortable (column count starts from zero). {include file="$template/includes/tablelist.tpl" tableName="ServicesList" noSortColumns="4" filterColumn="3"} Last but not least, open templates/{YOUR_TEMPLATE}/includes/head.tpl. Place this code at the very bottom of the file. {if $smarty.get.autologin} <style> body { visibility:hidden; } </style> {/if} A little bit of background For years I get used to show these buttons with a different approach. Basically I was retrieving and decrypting usernames and passwords from tblhosting and performing login with a separate form. For more than one reason (security & maintainability) I switched to this other approach.
  43. 2 points
    No one feels thanked because you had the intention to say β€œthank you.” I just want to take the time to say "THANK YOU" to all developers who helps WHMCS users to get their WHMCS app tweaked, fixed, customized and are still helping with many tips and things. My special "THANK YOU" get to @brian! who is the most contributor of all code changes and tweaks! Donation sent!
  44. 2 points
    it might be worth putting this in a GitHub and adding a link to it in Marketplace - who knows what's going to happen to Blend after v8, but that's going to be many months away at best.
  45. 2 points
    two options (at least when using Six) - you can either remove them using action hooks.... https://docs.whmcs.com/Editing_Client_Area_Menus https://docs.whmcs.com/Client_Area_Navigation_Menus_Cheatsheet ... or you can hide them with CSS (added to css/custom.css in your active template folder)... #Primary_Navbar-Services-View_Available_Addons, #Secondary_Sidebar-My_Services_Actions-View_Available_Addons {display:none;}
  46. 2 points
    I wouldn't class that as writing your own custom theme - that's just cosmetic changes to an existing theme. not mine, I don't support WGS products - that's what you pay him for! πŸ™‚
  47. 2 points
    Yes we gave up on this , just like we gave up on many other errors or un-wanted features , still not fixed, after all the years passed 😞 Also new errors now, with the new update/s, just going to live with it ,until we can find a better billing solution, for now we re stuck with WHMCS & the cPanel clan.
  48. 2 points
    I don't want to sound petulant but every time people talk about what is needed in WHMCS, the thread usually focuses on the app, admin interface, templates and open source. We have people asking to replace Smarty, Laravel or whatever with -insert any library here- just because it's newer and used by -insert any popular CMS/CRM here-. We don't need that. It'll make things worse not better. That's my opinion.
  49. 2 points
    or I think more accurately, don't ship an empty (apart from the comments header) custom.css file at all - it's because the updater thinks that it's a core file that it gets overwritten during an update. I mentioned this years ago that there is absolutely no need to include the file by default - if a user wants to create a custom.css file, then let them create the file themselves... the same as they would have to for whois.json, countries.json etc if a user has enough knowledge to add their own CSS (even if it's a copy & paste from elsewhere), they surely have the skill to create a file on their own server. πŸ™„ sadly, I doubt this will happen - three years after that feature request, it still only has 2 votes - even if it got another 50 votes, that wouldn't guarantee it being added.
  50. 2 points
    do you think the timing of launching a beta testing period one week before Christmas might have had something to do with that? πŸ™„
×
×
  • 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