Jump to content

Customizing email template


Michael M

Recommended Posts

Hello,

We are selling various products through WHMCS. shared hosting, ssl, vps,

The email template that needs customization is the ones with the VPS. We want to create an if statement to check that if the client has already another VPS or had in the past with the same clientID to make a small change in some login details we sent him.

So, is there a way we check in the database that the client has or had the same or same product's team to perform this check?

 

Thanks in advance.

Link to comment
Share on other sites

On 02/04/2020 at 01:12, Michael M said:

So, is there a way we check in the database that the client has or had the same or same product's team to perform this check?

not directly in the email template - you would have to use an EmailPreSend hook to query the database, if it's a product email template, then your starting point will be the service id of the service for the email being generated - from that, you'll have to get the client and then work out whether they have or had similar products.. and then the hook returns a mergefield to the template, and it's that mergefield that you would use in the email template if statement to determine whether to make any login detail changes.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • 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