berstein
Member-
Posts
25 -
Joined
-
Last visited
About berstein

Recent Profile Visitors
The recent visitors block is disabled and is not being shown to other users.
berstein's Achievements
Junior Member (1/3)
1
Reputation
-
berstein started following Error Laminas\Diactoros\ServerRequest , Custom API via Addon Module , WHMCS Custom Security Module Documentation and 6 others
-
Dear all, I would like to ask whether it is possible to create custom API not inside "includes/api" but inside my custom addon module? Creating API inside module will make grouping easier per functionality and simplify repository management. Thank you
-
Dear all, Is there any documentation provided by WHMCS regarding custom security module? I want to create custom OTP functionality for logging in, and I believe how to achieve it is by creating custom security module but I cant find any documentation online. I have checked that there are several providers sell modules for OTP, so I think it is possible to achieve it. Any suggestion are welcomed. Thank you
- 1 reply
-
1
-
Display Extra Service Detail in Client Area
berstein replied to berstein's topic in Developer Corner
I see, Kind of disappointed that there are no built-in function within WHMCS for this functionality. I think the workaround is just use the 'domain' field of the service, which normally used to show the domain name of a hosting service. Thank you for your answer -
You can edit the invoice template on whmcs\templates\[your template]\invoicepdf.tpl Check which template you are currently using. WHMCS default template includes Six and Twenty-One if I'm not mistaken. Must be one of those if you didn't change the template before. I hope that helps
-
Hello, I was wondering how can I add extra information under the product's name in the Products & Services list in the Client Area like inside the WHMCS's dashboard? Is it using default WHMCS functionality or should I create customized template for that? Thank you
-
This might not what you are looking for, but setting the mail SMTP to Mailtrap can still log your email without actually sending to recipient. I haven't check whether cancelling the mail sending using hooks "EmailPreSend" would still log the mail delivery or not.
-
So, if the client purchase the product on 15th, they have to pay full price; and they have to pay full price again on the 1st day of month? I think yes, you shouldn't use WHMCS's prorata billing, so whenever the client order the product, they will get the full price. But you will need to modify the due date on the service, and you will also need to modify the product's period in the invoice description. My invoice item show the line like this: Product Name Placeholder (29/05/2023 - 31/05/2023) I don't know if it's configurable by WHMCS default, but you need to change it to before the first day of the next month, since it will follow the value of the NDD/NID (haven't check which one to be exact) of the service. Default prorata product probably will shows the 15th of this month and 15th of the next month (assuming client purchased it on the 15th)
-
Hello all, I was wondering if is there any way I can manually trigger a hook? I'm currently using custom module and also paid module (encrypted) and they kinda won't work together. What I need is to trigger the paid module's hook function (I assume it use UpdateInvoiceTotal hook) after my custom module done executing. My custom module use UpdateInvoice API, but it wont trigger the UpdateInvoiceTotal hook. Any advice is welcomed. Thank you
-
@ghsa Is the "Mail Provider" you are looking the same "Mail Provider" in the "Configure Mail Provider" window? If yes, I think the "module" is what you are looking for since the options for mail providers are equal with the mail modules inside WHMCS. Please correct me if I'm wrong or if I misunderstand the question.
-
I'm currently creating a module using guzzlehttp/guzzle and symfony/mailer package. The module works as intended, it grabs data from API and send email using symfony mailer by copying the SMTP credential from WHMCS configuration in database. But, after few times sending email, I'm starting to get ErrorException when opening pages in WHMCS (mostly those which URL ended with index.php). From the error stack, it says the error comes from Laminas\Diactoros package. I don't have any experience with that module and I don't know why it is used by WHMCS. Anyobody have a clue about Laminas\Diactoros package and what it does? Whoops\Exception\ErrorException: Declaration of Laminas\Diactoros\ServerRequest::withCookie Params(array $cookies): Laminas\Diactoros\ServerRequest must be compatible with Psr\Http\Message\ServerRequestInterface::withCookie Params(array $cookies)
-
Sir @Rahat_Arif The SMTP configuration is stored on "tblconfiguration" on column "setting" with the value of "MailConfig". Like sir @Kian said, you need to decrypt() the value of MailConfig. The decrypted value will return JSON containing SMTP setting. I'm currently using WHMCS 8.0. I hope this helps.
-
Sir @iKaros do you use internal WHMCS mail configuration to send the email (e.g. email send button or API) ? I have a question regarding email styling, where I want to use Symfony mailer package to send email (I have various requirements which are not supported by using sendmail API). The problem is, the WHMCS variable for company name and company logo won't loaded properly. Did you face similar issue or maybe do you have solution to this issue? Thanks
-
Error "Dataset must be an array" when opening Product/Services menu
berstein replied to berstein's topic in Developer Corner
-
Dear all, I'm having an issue in my WHMCS development environment. When I try to open the menu Clients > Product/Services > Other Services, it will show error "Dataset must be an array". I have tried opening the database and opening the tblhosting, it seems that deleting the 1st and 3rd of the last 150 records somehow fix the problem. I suspect there is some kind of relation issue, but when I tried to relate from tblhosting to tblorders and tblproducts on the last 50 rows, I see nothing wrong and no NULL found. Anyone have ever meet similar issue? I want to troubleshoot it on my dev environment before similar issue found on my production. Thank you (I'm unable to post full stack trace, the website returned 403 forbidden)
