Leaderboard
Popular Content
Showing content with the highest reputation since 02/07/25 in all areas
-
While I understand that bugs are part of any Release Candidate cycle, it's concerning that we are still discussing basic optimization issues like proper OPcache support. And let's not even get started on the fact that we still don't have 100% native Nginx support. This becomes particularly ironic with the introduction of the new WHMCS Cloud Solution. With cloud hosting, the resource costs are on their side, so you'd think they'd be rushing to support Nginx to reduce their own infrastructure expenses. It's like being sold a high-performance engine but being told you have to power it with hamster wheels. Maybe once their bills start rolling in, Nginx support will suddenly become a priority. This all points to the bigger issue: the development velocity. Core development feels like it's just about "keeping the lights on" (PHP/ionCube updates) rather than actual innovation. This stagnation has allowed third-party developers like ModulesGarden to build entire businesses by selling us functionality that should have been in the core a decade ago. When you look at the "Total Cost of Ownership" license fees + necessary third-party modules, the value proposition is slipping. Newer platforms like Upmind are entering the market with an API-first architecture and modern features built-in from day one. If WHMCS continues to outsource innovation to the community while raising prices for maintenance updates, that competitive threat is going to become an exodus very quickly. We need core features that match the modern hosting landscape, not just compatibility patches.4 points
-
I never imagined that a simple update could introduce so many problems — and even worse, apparently without proper testing. It is absolutely ridiculous for a financial management system to have its own financial logic broken. In the last 24 hours, I finally received a response on the open support ticket, along with a so-called “patch” (attached). In practice, this patch only fixes the reports by hiding the incorrect ledger entries. However, in several other areas of the system, the incorrect postings are still happening. For example, the “Transactions” tab inside the client profile continues to show wrong values and misleading entries. So, in short, this patch does not actually fix the root problem — it only masks it in specific reports. For now, apply it if you want to slightly reduce the visible impact, but be aware that the financial logic is still broken in multiple parts of the system. At this point, we are seriously considering rolling back to a previous version — or even migrating away from WHMCS entirely. Year after year, the pricing increases exponentially, while the quality of support continues to decline and critical issues like this keep happening. The current level of instability and support simply does not justify the price they are charging anymore. whmcs_v9.0.0-supporthotfix.1_750a0b77ff.321_WHMCS-24949.zip3 points
-
Hi WHMCS ecosystem developers! I am excited to share an early heads-up about the upcoming WHMCS 9.0 release by the end of 2025 - a major update that brings important changes to the platform’s technical requirements. As part of this release, several core dependencies will be updated, and minimum system requirements will be increased. These changes are designed to improve performance, security, and compatibility with modern PHP standards. Key Updates in WHMCS 9.0: Minimum PHP version: 8.2 Recommended PHP version: 8.3 Minimum ionCube Loader version: 13.0.2 or higher Recommended ionCube Loader version: 14.4.0 or higher Updated dependencies: A number of underlying libraries and components have been upgraded. Some notable changes include: Smarty v3.1.48 —> v4.3.4 Legacy Smarty Tags are being deprecated and will no longer function in 9.0. Smarty Template Objects (including their use in plugins) will no longer be supported. guzzlehttp v7.4 —> v7.4.5 illuminate v7.x —> v9.0 I have attached a provisional list of dependency changes to this post. Please also use this thread to provide your feedback and ask questions of the Development Team regarding these requirement and dependency changes. These changes will require action from module developers to ensure continued compatibility. We recommend reviewing your module code and preparing for updates ahead of the release. We’ll be sharing more details, including a release window, definitive changelog and developer guidance, between now and the end of 2025 to help you get ready. Thank you for being a valued part of the WHMCS ecosystem. We appreciate your continued support and look forward to working together to make WHMCS 9.0 a successful release. whmcsv90_composerlock_provisional.txt3 points
-
Okay, maybe I was too quick about credit notes. It seems a lot of the features are "coming soon™️". This is not a Release Candidate lol. This is not even alpha. This is internal development. Nothing can convince me that this release didn't just happen because WHMCS promised us a release in December.3 points
-
Yeah, except for adding AI to domain search, this release doesn't really provide on any of the other promises. Credit notes doesn't work either. When you cancel an invoice, WHMCS just adds a transaction to the invoice. If the invoice has a total of $100, WHMCS just adds a transaction of $100 and cancels the invoice. There's no credit note or anything.2 points
-
How WHMCS have set this as a RC instead of a Beta is insane. It's a huge upgrade in terms of it's impact on themes/modules. No beta, no reply from WHMCS, no forums specific to v9.2 points
-
Your process sounds good apart from WHMCS. I would never recommend trying to import tables to new files. You need to update your existing install as normal. You can update from your version but you may have more luck doing a manual update. Backup everything, upload the new v8.13 files, adjust your hosting/server settings to meet the requirements (e.g you may need to update PHP) then run the installation script.2 points
-
@BENELUX, Today's the day!! https://blog.whmcs.com/133775/whmcs-90-release-candidate-out-now2 points
-
This week or next! It sure would be nice to double the size of the engineering team temporarily for one release every few years!2 points
-
@stormy, I'm glad to hear the e-invoicing feature will be a real value add for you. We are working with expert solution-providers in this space, so we're confident about delivering an easy to use and compliant solution with the broadest coverage. @andp97, Yes, by the end of the year in a pre-release version of WHMCS you will have access to this new feature. This bullet point actually describes two significant features which we're very excited about: 1. A RESTful API which provides access to the product catalogue and shopping cart logic. This will provide a suite of new endpoints to get product catalogue information, add, manipulate and get information about items in the cart (including price breakdowns and totals) and much more, all without touching the cart.php file or PHP session data. This means that power users could create their own highly-bespoke frontends whilst WHMCS handles the maths in the background, before seamlessly passing visitors to the checkout page to complete payment. 2. A brand new thin client powered by the aforementioned new API capabilities, providing a thoroughly modern purchase experience based on Vue.js. I've attached a sneak peak below. The new BuyFlow is a compiled Single-page application, meaning the layout isn't manipulated through templates, but you will be able to customise the colours to match your theme through a custom.css overrides file. The shopping cart as it exists today (cart.php and order form templates) isn't going away and will still be available if you'd like to stay with the familiar experience. Stay tuned to our blog and socials over the coming weeks for more information!2 points
-
Hi @venkat.j, The current latest version is 8.13. This behaviour suggests the dates were set to 00/00/0000, either by an admin (in which case there should be an entry in the client's Log tab) or by a rogue after-market module (in which case there probably wouldn't). You can edit the date fields to set the actual dates and click Save Changes. The correct dates will be stored.2 points
-
Hi all, In 8.13 a small improvement was made to the accounting of refunded mass-pay invoices. Prior to this the totals of mass-pay invoices were included in the overall income statistics, but now they are excluded as it's already accounted for by the original invoices.2 points
-
But you did ask them, and not by just posting here? EDIT: This is a bit old now, but a fast search on this board found:2 points
-
Hello @ThemeMetro This is a known issue, and we have published a HotFix. For more details, please review the following. Apologies for any inconvenience. Kind regards, Stephen.2 points
-
Thanks to @Mytihost, I found an elegant solution for this issue. The following hook: add_hook('ClientAreaPage', 1, function($vars) { if (!empty($vars['clientsdetails']['customfields'])) { $customfieldsAssoc = []; foreach ($vars['clientsdetails']['customfields'] as $field) { $customfieldsAssoc[$field['id']] = $field['value']; } return ['customfieldsAssoc' => $customfieldsAssoc]; } }); makes available the value of any client custom field in a template, using i.e. the form {$customfieldsAssoc.17} (where "17" is the id field in the tbl customfields)2 points
-
Hello, Not at all and it's highly recommended, to change the admin path.2 points
-
You may want to check in softaculous you may have the auto update turned on. Go into Softaculous find your install click on edit details auto upgrade select do not auto upgrade. With regards to 9.0 their will still be a lot of developers slightly behind. WHMCS didn't exactly give developers alot of notice with regards to the changes.1 point
-
Una buona notizia e' che il nostro team di sviluppatori sta attivamente lavorando per aggiungere la gestione di fatture elettroniche in una delle prossime release di WHMCS. In attesa di avere piu' dettagli nei prossimi mesi, non si hanno ancora tempistiche o specifiche. Certo e' che si potranno emettere fatture elettroniche in diversi formati, incluso Fattura PA. Per rimanere aggiornati potete sottoscrivere alla feature request corrispondente: https://requests.whmcs.com/idea/add-electronic-invoicing1 point
-
Thanks for the detailed update! It’s great to see that ModulesGarden is moving quickly with WHMCS 9.0 compatibility, especially for modules like cPanel Extended and Proxmox VE. I’m curious have you noticed any specific issues or challenges when integrating custom-developed WHMCS modules with the new version, particularly around the updated checkout experience or recurring payments? It would be helpful to know what to watch out for before upgrading.1 point
-
I’m honestly not convinced by these repeated price increases, especially when they happen without clear prior notice. I’m a small provider managing around 10–20 clients only, and with the latest increase, the subscription is becoming financially unjustifiable. At this scale, the cost is no longer proportional to the value received and is starting to feel more like a burden than a business tool. I understand that businesses evolve, but constant yearly increases without meaningful added value for small users come across as exploitation rather than progress. If this pricing strategy continues, I’m seriously considering moving away from the entire WebPros ecosystem, including WHM and WHMCS. At the very least, there should be better transparency, advance notifications, and fair pricing options for low-usage customers.1 point
-
What I find somehow strange after being using WHMCS for 20 years.. when there was only 2-3 people in the company... bugs was fixed quickly often the same day. Now that I have a list of bugs reported many of them with 1 min solutions to implement, and they still doesnt get implement in X versions of whmcs 8x and still not fixed in WHMCS 9. So I dont know if being a large owned company is always a good thing. Just in December alone me and other people I work with found 3 new bugs of things that has been working since whmcs 5 and suddenly not working and per documentation should work.. I am actually concerned that the developing department / team doesnt have good working structure as they introduce bugs that should not be there that has been working for years. This make us need to use more time on testing before each upgrade and time testing is also a huge cost.. whmcs. should going forward be better in quality and also fixe the backlogs of bugs.1 point
-
am using 8.3 version now. i migrated my whmcs to a new server. but now the crons are not wrking properly. And am getting the following messages. Remove dead screens with 'screen -wipe'. #11 /home/mywhmcs/public_html/clients/vendor/whmcs/whmcs-foundation/lib/Installer/Composer/ComposerUpdate.php(0): WHMCS\Installer\Composer\ComposerUpdate->doComposerCommand(Object(Closure)) #12 /home/mywhmcs/public_html/clients/vendor/whmcs/whmcs-foundation/lib/Installer/Update/Updater.php(0): WHMCS\Installer\Composer\ComposerUpdate->getLatestVersion(true) #13 /home/mywhmcs/public_html/clients/vendor/whmcs/whmcs-foundation/lib/Cron/Task/CheckForWhmcsUpdate.php(0): WHMCS\Installer\Update\Updater->fetchComposerLatestVersion() #14 /home/mywhmcs/public_html/clients/vendor/whmcs/whmcs-foundation/lib/Scheduling/Task/AbstractTask.php(0): WHMCS\Cron\Task\CheckForWhmcsUpdate->__invoke() #15 /home/mywhmcs/public_html/clients/vendor/whmcs/whmcs-foundation/lib/Scheduling/Task/AbstractTask.php(0): WHMCS\Scheduling\Task\AbstractTask->execute() #16 /home/mywhmcs/public_html/clients/vendor/whmcs/whmcs-foundation/lib/Cron/Console/Command/AbstractCronCommand.php(0): WHMCS\Scheduling\Task\AbstractTask->run() #17 /home/mywhmcs/public_html/clients/vendor/whmcs/whmcs-foundation/lib/Cron/Console/Command/AbstractCronCommand.php(0): WHMCS\Cron\Console\Command\AbstractCronCommand->executeCollection(Object(WHMCS\Scheduling\Task\Collection)) #18 /home/mywhmcs/public_html/clients/vendor/symfony/console/Command/Command.php(255): WHMCS\Cron\Console\Command\AbstractCronCommand->execute(Object(WHMCS\Cron\Console\Input\CliInput), Object(Symfony\Component\Console\Output\ConsoleOutput)) #19 /home/mywhmcs/public_html/clients/vendor/symfony/console/Application.php(912): Symfony\Component\Console\Command\Command->run(Object(WHMCS\Cron\Console\Input\CliInput), Object(Symfony\Component\Console\Output\ConsoleOutput)) #20 /home/mywhmcs/public_html/clients/vendor/symfony/console/Application.php(264): Symfony\Component\Console\Application->doRunCommand(Object(WHMCS\Cron\Console\Command\AllCommand), Object(WHMCS\Cron\Console\Input\CliInput), Object(Symfony\Component\Console\Output\ConsoleOutput)) #21 /home/mywhmcs/public_html/clients/vendor/symfony/console/Application.php(140): Symfony\Component\Console\Application->doRun(Object(WHMCS\Cron\Console\Input\CliInput), Object(Symfony\Component\Console\Output\ConsoleOutput)) #22 /home/mywhmcs/public_html/clients/crons/cron.php(0): Symfony\Component\Console\Application->run(Object(WHMCS\Cron\Console\Input\CliInput), Object(Symfony\Component\Console\Output\ConsoleOutput)) #23 {main}[mywhmcs@hmserver ~]$ ^C [mywhmcs@hmserver ~]$ /opt/cpanel/ea-php74/root/usr/bin/php -q /home/mywhmcs/public_html/clients/crons/cron.php all -F -vvv^C1 point
-
1 point
-
Problem: I have a fairly old WHMCS installation (WHMCS 7.10.2 and PHP 7.3.3), which is now at the end of its useful life. The current WHMCS installation is used for both the website (service presentation pages, price lists, “about us,” etc.) and the customer area. (It seemed like a good idea at the time, but it’s not: it’s a mess, management is rigid, there’s no SEO optimisation, creating multilingual pages is a mess…) So I was thinking of installing the new WHMCS in a different directory (e.g., my.example.com) and developing the main site with WP on example.com. This way I could: leave the old WHMCS site running on example.com for as long as necessary develop the new customer area on my.example.com develop the new site offline Once everything is ready, I “just” need to: delete the site on example.com install the new WP site on example.com migrate the database from the old WHMCS installation to the new one set up a series of redirects in .htaccess from the old URLs to the new ones My questions are: Did I miss something along the way? Is there something I haven’t thought of? I'll need to migrate the database from a WHMCS 7.3.3 installation to 8.13… which tables do I need to migrate? Can I do it from phpmyadmin, or are there differences in the database structure?1 point
-
ETA: Estimated Time of Arrival. By definition, not exact. 😉1 point
-
Hello WHMCS Community! I'm thrilled to announce the release of Update 3 for the Stripe Checkout module for WHMCS, developed under RackNode! This update brings even more powerful features, making it easier than ever for businesses to cater to a global audience with a seamless and secure payment process. What’s New in Update 3? Expanded Payment Gateway Support The Stripe Checkout module already supports widely-used payment methods, including: PayPal Alipay Cash App Google Pay Apple Pay Link Card In addition to these trusted options, Update 3 introduces support for a wide range of new payment gateways to help you reach customers around the globe: WeChat Pay iDEAL Bancontact Giropay Sofort SEPA Debit EPS Przelewy24 (P24) OXXO Boleto FPX GrabPay Multibanco MobilePay Revolut Pay Amazon Pay (Beta) US Bank Account (ACH) TWINT Enhance checkout conversion rates by offering localized and regional payment methods your customers trust. Selectable Payment Gateways Now, you can choose a single payment gateway to display at checkout, offering a streamlined payment experience tailored to your business needs. Key Features (As Always): Multiple Payment Method Support: Accept payments via cards, Alipay, Cash App, and more. Adaptive Pricing: Automatically convert prices into local currencies, increasing global accessibility and conversion rates. Error Handling & Secure Webhook Integration: Ensuring secure, real-time payment confirmations with robust logging and signature verification. Seamless WHMCS Integration: Easy setup with just your Stripe credentials, making it a perfect solution for hosting providers and online businesses. Why Choose Stripe Checkout Module? Global-Ready: Accessibility for customers worldwide with local currencies and payment methods. Secure & Reliable: Built with security at its core, ensuring peace of mind for you and your customers. Pricing: $49 Per Year WHMCS Marketplace Documentation: For detailed setup instructions, visit our documentation: Documentation Questions or Customization Requests? Feel free to reply here or reach out directly to info@racknode.net for any inquiries or custom development needs.1 point
-
Hello, It's very easy to resolve with Hook, just do Create a hook file at: whmcs/includes/hooks/invoice-lineitem-date.php <?php use Illuminate\Database\Capsule\Manager as Capsule; use Carbon\Carbon; add_hook('InvoiceCreationPreEmail', 1, function ($vars) { $invoiceId = (int) $vars['invoiceid']; $inv = Capsule::table('tblinvoices')->where('id', $invoiceId)->first(); if (!$inv) { return; } $dateText = Carbon::parse($inv->date)->format('d-m-Y'); $items = Capsule::table('tblinvoiceitems') ->where('invoiceid', $invoiceId) ->get(); foreach ($items as $item) { $isBillableItem = ($item->type === 'Item'); if (!$isBillableItem) { continue; } $newDescription = $item->description; if (strpos($newDescription, '{DAY}') !== false || strpos($newDescription, '{MONTH}') !== false || strpos($newDescription, '{YEAR}') !== false) { $newDescription = preg_replace( '/\{DAY\}\s*-\s*\{MONTH\}\s*-\s*\{YEAR\}/i', $dateText, $newDescription ); } else { $newDescription .= " ({$dateText})"; } Capsule::table('tblinvoiceitems') ->where('id', $item->id) ->update(['description' => $newDescription]); } });1 point
-
As you might know, whmcs has a problem with stripe: when the payment is not immediately confirmed by stripe (but requires to clic "capture" on stripe dashboard), whmcs does not record the order and the customer details and does not even send any notification to whmcs admin or to the customer. We solved with a hook that sends us an email with the order details, so that: - we know that there was a order attempt - we know that there might be a payment in stripe that requires manual "capture" - if necessary, we have all the client and order details in order to recreate the both client account and order. Here is the hook. <?php if (!defined("WHMCS")) { die("This file cannot be accessed directly"); } /** * Save all checkout data to a TXT file * AND email it to admin * Runs BEFORE order/invoice creation, and before redirect to Stripe. */ add_hook('ShoppingCartValidateCheckout', 1, function ($vars) { // --- 1. Clone and sanitise incoming data ------------------------------- $data = $vars; // Mask any possible card data (good practice even if Stripe never posts it) $sensitiveFields = [ 'ccnumber', 'cccvv', 'ccexpirymonth', 'ccexpiryyear', 'password', 'password2', ]; foreach ($sensitiveFields as $field) { if (!empty($data[$field])) { $data[$field] = '***masked***'; } } // --- 2. Attach cart contents from session (products, domains, etc.) --- $cart = isset($_SESSION['cart']) ? $_SESSION['cart'] : []; $payload = [ 'timestamp' => date('Y-m-d H:i:s'), 'ip' => $_SERVER['REMOTE_ADDR'] ?? null, 'user_agent' => $_SERVER['HTTP_USER_AGENT'] ?? null, 'checkoutFields' => $data, 'cart' => $cart, ]; // --- 3. Build a text representation (for file & email) ---------------- $entry = "==============================\n"; $entry .= "Checkout submitted: " . $payload['timestamp'] . "\n"; $entry .= "IP: " . ($payload['ip'] ?? 'N/A') . "\n"; $entry .= "User-Agent: " . ($payload['user_agent'] ?? 'N/A') . "\n\n"; $entry .= "DATA:\n" . print_r($payload, true) . "\n\n"; // --- 4. Save to TXT file ---------------------------------------------- $logDir = __DIR__ . '/../../logs'; $logFile = $logDir . '/pre_stripe_checkout.txt'; if (!is_dir($logDir)) { @mkdir($logDir, 0700, true); } @file_put_contents($logFile, $entry, FILE_APPEND); // --- 5. Send email to admin ------------------------------------------- // This uses WHMCS' built-in admin notification helper. // The "system" type means it goes to the system email / admin notifications. if (function_exists('sendAdminNotification')) { $subject = 'Pre-Stripe Checkout Captured'; // Use <pre> so the print_r formatting is readable in HTML email $message = nl2br(htmlspecialchars($entry)); sendAdminNotification('system', $subject, '<pre>' . $message . '</pre>'); } // IMPORTANT: Do NOT return an error. Just let checkout continue. return; }); I suggest to implement it. It would be great if it would offer some sort of customization in the admin area.1 point
-
In the v9.0 release cycle we have focused efforts on updating our dependencies - which was quite a significant undertaking - ensuring that we carefully managed the Smarty update (as that is potentially an area of high user-impact). I anticipate this work will enable the testing and validation of future PHP versions to move much faster, and we expect to deliver PHP 8.4 support in v9.1. Please see the finalised list above. TCPDF will be updated to 6.10.1 point
-
1 point
-
can you maybe release an update to 8.13 to add a tool similar to the PHP compatibility tool that shows what files use these old components and won't be compatible? it'll help hosts like us that rely in multiple vendors plugins understand who we need to reach out too to ensure they're getting WHMCS v9 ready.1 point
-
Hello folks, I'm developing a custom payment gateway module and need to trigger a hook after the admin clicks "Save Changes" on the gateway configuration page (configgateways.php). I can see the POST request with the correct credentials (like App ID and Token) in my browser's dev tools. However, my hook isn't being triggered at all. ChatGPT suggested a GatewayConfigSave hook might exist, but I couldn't find any official documentation about it. I also tried AdminAreaPage and similar hooks, but none are reliably triggered with the config save event or POST data. Has anyone else run into this issue? Is there a recommended or undocumented hook to use when saving a gateway's settings?1 point
-
Hi @File_Explorer @TheHostingHeroes, Some users have reported poor performance of this query is resolved by updating their MySQL server version. So please try that first. As a workaround you can remove the /modules/widgets/Billing.php file.1 point
-
We're pleased to announce the release of WHMCS 8.13 Release Candidate. This marks the end of feature development for the 8.13 series and is the final stage before version 8.13 is promoted to General Availability status. WHMCS 8.13 includes the following new functionality and enhancements: Manual User Password ResetsOne of our most requested admin features is here. With over 250 community upvotes, WHMCS 8.13 introduces the ability to reset a user's password directly from the Admin Area. This...View the full blog post1 point
-
I haven't noticed any difference, enom support still sucks just as much as it always has.1 point
-
Technically the other way round - opensrs bought enom and that’s when enom fell apart1 point
-
Loads fine in Firefox, but Vivaldi (and a few others) sees what he does. Related to a javascript that's loading. It's a webpros script.1 point
-
1 point
-
Hi @3cellhosting, The directory can be safely deleted /vendor/whmcs/whmcs-foundation/lib/Installer/Composer/Hooks/ along with its contents. You can then run the update process again and this time the error will not occur.1 point
-
Lagom WHMCS Client Theme has been updated to 2.0 version! Order Now Changelog Documentation Services Contact Different Styles & Colors Lagom WHMCS Client Area Theme consists of 4 unique styles. There are 5 different color schemes available for each style. Modern Futuristic Default Depth Style Manager Provides essential tools used to manage Lagom theme colors and styles without having any technical know-how. You will be empowered to apply various Styles and Color Schemes to tailor our theme to your brand style. Learn More Menu Manager From now on, you do not need to create complicated WHMCS hooks to modify the Lagom theme navigation. Menu Manager delivers a super convenient option to set up the menu items from the WHMCS addon. Learn More Multiple Layouts Make full use of 5 unique layouts for the main menu navigation and 2 various layouts for the footer. Other Lagom Features Login Based Layouts Display different menu and footer layouts based on the customer's login status. Learn More Basic SEO Management Manage SEO for selected theme pages. Assign your custom page title, description, and social image. Learn More Custom Layout for Pages Assign a unique Lagom Layout to specific pages and overwrite settings made in Layout Manager. Learn More Affix Theme Navigation Affix the top Lagom theme navigation when a customer scrolls your website up. Learn More Multiple Element Styles Using a few simple clicks you can choose from 3 different styles available for particular Lagom elements. Learn More Multiple Page Templates Define various templates for selected Lagom theme pages and configure its settings. Learn More Different Fonts Change Font Family used in the Lagom theme with a few simple clicks. Learn More Affix Theme Sidebars Affix theme sidebars to the top of the browser window. Learn More Hide Sidebars Hide Lagom theme sidebars for selected pages in Page Manager. Learn More1 point
-
WHMCS users and client accounts have separate contact information and they require separate updates to change details like the email addresses. The user management system allows a single user to access multiple client accounts. This separates authentication and authorization from services, billing, and support. To learn how to change the client account and the user account email address so they match please review this help guide: https://help.whmcs.com/m/managing/l/1681243-updating-user-and-client-account-details With this hook added to your WHMCS installation the system will now "Sync" the Client Account Email Address to match the User Account Email Address only when the change is made under the Account Details page via the client area. This hook adds a little "Note" under the Email Address field under the Hello Client! > Account Details section of the client area to inform that when this Email Address is changed, they will be logged out and they will need to log back in using the new Email Address they just set since this hook is updating both the client account and user account email addresses. Here is an example of the Account Details page Email Address field with this note: Via the Admin Area, when a client does this change and the hook was used it will make a log entry just like this: This entry indicates that the Client/User Email Sync Script hook was a success. Now both the Client Account Email Address and the User Account Email Address match for that client account. If there are multiple Users associated with the Client Account, this will only change the Email Address of the Owner of the account. <?php /* This script will update both the Client Account Profile email address and the user account email address when the change is made to the Account Details page for the email address field. Otherwise, you would have to update the email in both places and follow this article: https://help.whmcs.com/m/managing/l/1681243-updating-user-and-client-account-details Upload this file to your /includes/hooks directory of your WHMCS installation. There will be a Log entry when this script runs. @WHMCSDanny */ add_hook('ClientAreaHeadOutput', 1, function($vars) { // Only run if the on the Account Details page via the client area. // The action is going to be "details". This will make sure this message does not show anywhere else. $action = $_GET['action']; if($action == "details") { //Input the message under the Email Address field that they will be logged out after making the change. return <<<HTML <script type="text/javascript"> $(document).ready(function() { jQuery("input[name='email']").after('<span style="color:red; font-size:9pt;"><b>Note:</b> Changing your email address here will sync the email with your User Account. You will be logged out after you change the email. You must login using the new email address you just set.</span>'); }); </script> HTML; }; }); // prevent file from being loaded directly if (!defined("WHMCS")) { die("This file cannot be accessed directly."); } else { function clientowneruseremailsync_changeUserEmail(int $client_id, string $client_email){ // call the API and grab the owner user ID $command = 'GetClientsDetails'; $postData = array( 'clientid' => $client_id, 'stats' => false, ); $results = localAPI($command, $postData); if ($results['result'] == 'success') { // success! $client_owner_user_id = $results['client']['owner_user_id']; if (is_numeric($client_owner_user_id)){ // got a number, so it should be a valid owner user ID // now to perform the update to the user account to match the email set for the client account $command = 'UpdateUser'; $postData = array( 'user_id' => $client_owner_user_id, 'email' => $client_email, ); $results = localAPI($command, $postData); if ($results['result'] == 'success') { logActivity("Client/User Email Sync Script - Emails Successfully Changed and Synced. The e-mail address is set to $client_email for the Client Account and the Owners User ID: $client_owner_user_id", $client_id); } else { logActivity("Client/User Email Sync Script - Failed to change the e-mail address to $client_email for the Owners User ID: $client_owner_user_id . Results: ". $results, $client_id); } } } else { logActivity("Client/User Email Sync Script - Failed to verify that an e-mail change occurred on the clients profile. Results: ". $results, $client_id); } } add_hook('ClientEdit', 1, function($vars) { // Only run if the clients account profile email address is being changed. if ($vars['email'] != $vars['olddata']['email']){ // email is being changed. Update owning user accordingly. // get the client ID. It should be $vars['userid'] $client_id = $vars['userid']; // get the new e-mail address $client_email = $vars['email']; // call our helper function clientowneruseremailsync_changeUserEmail($client_id, $client_email); } }); } ?> Enhanced Version - Added a checkbox and tooltip In this new updated version of this hook, I added a checkbox/tooltip for the end-users to decide if they want to use this option to sync the Email Address under the Profile page too. Otherwise, nothing happens and WHMCS works as normal. The checkbox needs to be checked before it will run the same hook code to update both email addresses in both locations. (Account Details and Profile sections via the client area) <?php /* This hook script will update both the Client Account Profile email address and the User Account email address When the change is made to the Account Details page for the email address field only. It does not work for the Profile page. This version adds a new checkbox with a tooltip to let the end-user decide if they want to use this option or not. The checkbox needs to be checked for the hook to execute. If the checkbox does not get checked WHMCS works as expected and updates just the Account email. The Profile email account will still need to be updated if they want it to be the same. Otherwise, you would have to update the email in both places and follow this article: https://help.whmcs.com/m/managing/l/1681243-updating-user-and-client-account-details Upload this file to your /includes/hooks directory of your WHMCS installation. There will be a Log entry in the admin area when this script executes. @WHMCSDanny */ add_hook('ClientAreaHeadOutput', 1, function($vars) { // Only run if the on the Account Details page via the client area. // The page action is "details". This will make sure this message does not show anywhere else. $action = $_GET['action']; if($action == "details") { //Input the checkbox and tooltip under the Email Address field return <<<HTML <script type="text/javascript"> $(document).ready(function() { jQuery("input[name='email']").after('<input type="checkbox" name="syncEmails" id="syncEmails"> <span style="color:red; font-size:9pt;"><b>Sync Email with your User Account Email</b></span><span class="form-group"> <i class="far fa-question-circle" data-toggle="tooltip" data-placement="top" title="This option will sync your Email Address Here with your Profile Email Address. You will be logged out and will need to login with your new email address. If you do not check this option you will need to update it under the Your Profile page as well"></i></span>'); }); </script> HTML; }; }); // Prevent file from being loaded directly if (!defined("WHMCS")) { die("This file cannot be accessed directly."); } else { if (isset($_POST['syncEmails'])) { // Checkbox is checked // Perform actions and the logic to check the emails and replace them with the new one function clientowneruseremailsync_changeUserEmail(int $client_id, string $client_email){ // call the API and grab the owner user ID $command = 'GetClientsDetails'; $postData = array( 'clientid' => $client_id, 'stats' => false, ); $results = localAPI($command, $postData); if ($results['result'] == 'success') { // Success we have the owners user ID from the database! $client_owner_user_id = $results['client']['owner_user_id']; if (is_numeric($client_owner_user_id)){ // We have the ID number, so it should be a valid owner user ID // Perform the update to the user account to match the email set for the client account $command = 'UpdateUser'; $postData = array( 'user_id' => $client_owner_user_id, 'email' => $client_email, ); $results = localAPI($command, $postData); if ($results['result'] == 'success') { logActivity("Client/User Email Sync Script - Emails Successfully Changed and Synced. The e-mail address is set to $client_email for the Client Account and the Owners User ID: $client_owner_user_id", $client_id); } else { logActivity("Client/User Email Sync Script - Failed to change the e-mail address to $client_email for the Owners User ID: $client_owner_user_id . Results: ". $results, $client_id); } } } else { logActivity("Client/User Email Sync Script - Failed to verify that an e-mail change occurred on the clients profile. Results: ". $results, $client_id); } } add_hook('ClientEdit', 1, function($vars) { // Only run if the clients account detaoils email address field is being changed. if ($vars['email'] != $vars['olddata']['email']){ // Wmail is being changed. // Get the client ID. It should be $vars['userid'] $client_id = $vars['userid']; // Get the new e-mail address $client_email = $vars['email']; // Call the helper function to make the change clientowneruseremailsync_changeUserEmail($client_id, $client_email); } }); } } ?> At the time of writing this post, this process was tested on the latest stable release of WHMCS 8.9.0 I hope you find this useful. If you have any feedback or questions, please feel free to reply to this thread! WHMCSDanny1 point
-
@sajibdesigns You need to select a Registrar from the dropdown before clicking accept order1 point
-
Hi. For convenience, I wanted to create a custom model for my module. I didn't like having to call Capsule every time I needed information that the module stored in the database. I want to share the code here in case other people didn't know how to do it but also to gather some feedback on this way of doing it. <?php namespace WHMCS\Module\Addon\MyModule; use WHMCS\Model\AbstractModel; /** * Convenience model for custom modules */ class MyModel extends AbstractModel { // Set the table that should be used for searching protected $table = 'mod_mymodule'; // We almost always have access to the service ID. Has to represent a column in the mod_mymodule table protected $primaryKey = 'serviceid'; } When using the model, we're able to do MyModule::find() or create a new instance using 'new MyModule()'.1 point
-
Apologies for bringing an old thread back from the dead but this issue has reared its ugly head again in version 8.13. We had an issue with a smarty variable in a custom template file triggering a security policy error so WHMCS Support suggested adding this security policy to our config file: // Smarty enable special variables policy: $smarty_security_policy = array( 'system' => array( 'enabled_special_smarty_vars' => array( 'session', 'foreach', 'section', 'block', 'capture', 'now', 'get', 'post', 'server', 'request', 'template', 'const', 'strstr', ), ), ); This fixed the issue with the template not working but now we are getting a "'strstr' not allowed by security setting" error when trying to send any email that contains this: {if strstr($client_credit, "GBP")}Blah blah blah{/if} The original security policy we had in place to allow "strstr" is still there but doesn't work if we also have the new "'system'" security policy in place, it works fine if we remove this leaving just the original security policy but ideally we need both the custom template and the code in the email to work! FYI our full security policy is listed here: // Smarty custom email based template policy: $smarty_security_policy = array( 'mail' => array( 'php_functions' => array( 'strstr', ), ), ); // Smarty enable special variables policy: $smarty_security_policy = array( 'system' => array( 'enabled_special_smarty_vars' => array( 'session', 'foreach', 'section', 'block', 'capture', 'now', 'get', 'post', 'server', 'request', 'template', 'const', 'strstr', ), ), ); Any ideas how to fix or if not, is there another workaround we could use to display conditional data depending on the currency used by the client?1 point
-
@WGS It seems you moved from copying contents to paying money trying to hurt our website with negative SEO. Nicely done 👍 I've got two words for you: Stop wasting money. It doesn't work as I know how to deal with negative SEO Do you want me to post details? 😛1 point
-
Hello @Blasgo Thanks for your post, if you have registered the domain with your registrar then you will need to follow the "Manual Domain Entry Only" process To add a domain on its own without a product, follow the steps below: If you haven't already, create the client by navigating to Go to Clients > Add New Client. On the client summary page, click the "Add New Order" link in the Actions panel The client will be preselected, so you should fill out the rest of the form - begin by choosing the payment gateway you want the client to pay with Leave the Product/Service dropdown menu set at None Leave the Billing Cycle dropdown menu set at Monthly Enter the domain in the Domain text field and select Register as the Domain Registration Option (even though you aren't intending to register it today) Choose the number of years you next want the client to be invoiced for at the time of renewal and tick any addons the user has for their domain Ensure both tick boxes for sending an order confirmation and generating an invoice are unchecked so the user is not emailed about the order you are adding Finally, set the Order Status dropdown to Active and then click the submit button to add the order to WHMCS You will now be shown the order screen summarising the details of the order you just added Now as the final step, you must go to the domain's information page to enter the correct next due and expiry dates as well as selecting the registrar the domain is registered with if using one of the built-in registrars. To do this, from the order screen, click on the link in the Item column of the items ordered - this will take you straight to the details screen.1 point
-
the easiest way would be a css entry in templates/six (or custom)/css/custom.css #order-premium_comparison .price-table-container .price-table { width: 250px !important; min-width: 250px !important; } if you wanted 5 columns, you'd change them both to 190px or less..1 point
-
the entry is correct, but if this is the only entry in your whois.json file, it should be... [ { "extensions": ".app", "uri": "socket://whois.nic.google", "available": "Domain not found" } ]1 point
-
which is the definition of a lookup provider. all i'm saying is that WHMCS 7 is designed to either use whois, or a lookup provider, for ALL TLDs - you can't mix and match, e.g this module for .ge, but whois for .com - you have to put all your eggs in one basket.1 point
-
Yes, you have to edit the admin template "viewticket.tpl". I hacked this code myself: {if !$numcustomfields} <div align="center">{$_ADMINLANG.support.nocustomfields}</div> {else} <table width="100%" border="0" cellspacing="1" cellpadding="5" bgcolor="#cccccc"> {foreach from=$customfields item=customfield} <tr bgcolor="{cycle values="#F4F4F4,#F8F8F8"}"><td width="200">{$customfield.name}</td><td><strong>{$customfield.value}</strong></td></tr> {/foreach} </table> {/if} There's probably a more elegant solution but that works.1 point
