Personal tools
Namespaces

Variants
Actions

Product Free Trial Manager For WHMCS

From ModulesGarden Wiki
Jump to: navigation, search

Contents

About Product Free Trial Manager For WHMCS

Product Free Trial Manager For WHMCS allows you to activate a dedicated payment gateway for free trial access for all or single products in your offer.
Let your clients test your products by offering them free of charge, but limited in time, access to the ordered products, and make a well-thought decision to avoid cancellation requests.

Use the module to make your offer even more competitive and much practical to your clients.

  • Client Area Features:
✔ View Free Trial Labels On Applicable Product/Service Tiles
✔ Order Free Trial Access To Products/Services
✔ Receive Reminders On Scheduled Trial Period Expiration
✔ Pay Invoice Before Trial Period Expiration To Keep Service Active
  • Admin Area Features:
✔ Enable Trial Access For Selected Products/Services
✔ Configure Payment Email Reminders:
✔ Select Customized Email Template
✔ Define Number Of Days Before Invoice Due Date To Send Reminder
✔ Configure Module Settings:
✔ Define Trial Period Length
✔ Set Limit On Products Number In Shopping Cart
✔ Set Limit On Trials Number Per Customer
✔ Set Time Frame For Trials Limit Per Customer
✔ Allow One Trial Access Per Product
✔ Allow Trial Access For New Customers Only
✔ Hide Trial Payment Method For Not Applicable Products
✔ Allow Trial For Products With Free Domains
✔ Set Free Trial Label On Product Tiles And In Order Summary With:
✔ Predefined File For:
✔ Twenty-One Theme
✔ Lagom WHMCS Client Theme
✔ Custom HTML Code
✔ Enter Custom URL For Client Redirection After Completing Trial Order
✔ Set Default Payment Gateway
✔ Send Email Reminders Per Active Trial Service
✔ View Module Logs
✔ Customize Display Name Of Module Gateway
  • General Info:
✔ Multi-Language Support
✔ Supports PHP 8.1 Back To PHP 7.4
✔ Supports WHMCS Themes "Six", "Twenty-One" And "Lagom WHMCS Client Theme"
✔ Supports WHMCS V8.10 Back To WHMCS V8.8
✔ Requires ionCube Loader V12 Or Later
✔ Easy Module Upgrade To Open Source Version

Installation

This tutorial will show you how to successfully install and configure Product Free Trial Manager For WHMCS.

We will guide you step by step through the whole installation and configuration process.

1. Log in to our client area and download the module.
PTM 1.png
2. Extract the package and upload its content into the main WHMCS directory.

The content of the package to upload should look like this.

PTM 2.png
3. When installing Product Trial Manager For WHMCS for the first time, you have to rename the 'license_RENAME.php' file.

The file is located in 'your_whmcs/modules/addons/ProductFreeTrialManager/license_RENAME.php'. Rename it from 'license_RENAME.php' to 'license.php'.

PTM 3.png
4. In order to configure your license key, you have to edit the previously renamed 'license.php' file.

Enter your license key between the quotation marks as presented on the following screen. You can find your license key in our client area → 'My Products'.

PTM 4.png
5. Now, set up the 'storage' folder as recursively writable.

This folder is available at 'your_whmcs/modules/addons/ProductFreeTrialManager/'.

PTM 5.png

Configuration of Addon

6. Now you have to activate the module in your WHMCS system.

Log in to your WHMCS admin area. Go to 'System Settings' 'Addon Modules'. Afterwards, find 'Product Free Trial Manager' and press the 'Activate' button.

PTM 6.png
7. In the next step you need to permit access to this module.

To do so, click on the 'Configure' button, tick 'Full Administrator' and press 'Save Changes'.

PTM 7.png

Additional Steps Required

8. Now, proceed to 'Apps & Integrations' → 'Payments'.

Find the 'Product Free Trial Manager' gateway and activate it.
Important: Make sure that you have both the dedicated payment gateway and the addon active.

PTM 8.png
9. Afterwards, move to the gateway management section to add your custom display name. Press 'Save Changes'.

The gateway will be available to choose as a payment method for clients depending on the configuration in the Product Free Trial Manager addon.

PTM 9.png
9. Congratulations, you have just successfully installed Product Free Trial Manager For WHMCS!

You can now access your module from 'Addons' → 'Product Free Trial Manager'.

PTM 10.png

Management

In this section we will show you the possibilities of Product Free Trial Manager For WHMCS.

Our module allows your clients to order products and services from your offer in their full version, completely free of charge, for testing purposes before making the final purchase decision.

Addon Configuration

Settings

At the 'Settings' tab you can set up the module's behavior. Configure free trial access settings and the cron tab behavior.
PTM 10.png
At the 'Cron Settings' tab you can set up the cron's behavior, which is responsible for the regular delivery of email reminders.
If you set up the cron job exactly as in the automatically generated line below, the task will be performed daily at 10 pm.
We advise setting the task once a day.
PTM 11.png
In 'General Settings' section you may customize the trial access requirements for all products:
  • Trial Period - enter the number of days for how long the ordered product will remain active. After the specified time, the product will be automatically suspended. Use '0' for an unlimited trial period.
  • Products Limit In Cart - enter the maximum number of products that a client may add to the cart and still be able to use the free trial payment method.
  • Trials Per Customer Limit - allows you to limit how many trials a single client can start, it is meant to be used with the next option. Set '-1' to disable the limit.
  • Trials Per Customer Limit Time Frame - restricts the limit by a time frame. The number given represents the number of days during which the limit will be working. Use '-1' to disable trial limiting within time frames.
    Once the time frame passes, the trial will no longer count towards the limit, and the client will be able to start another trial.
  • One Trial Per Product - if enabled, only one trial access to a single product may be ordered.
  • New Customers Only - if enabled, only customers who do not have any orders yet will be allowed to select the trial payment method.
  • Hide Trial Payment Method - if trial access is not available for a given product, and that product is in the client's cart, this payment gateway will be hidden for the client.
  • Email Reminders Per Service - if enabled, a separate email reminder will be sent per every active trial service.
  • Allow Free Domains - allows free domain registration to be used with free trials (free domain has to be set in the product's configuration).
  • "Free Trial" Label On Product Tile - places a label on tiles in the product list indicating that a free trial is available for the given product.
    Templates can be edited or added under 'ProductTrialManager/storage/app/labels/productList'.
  • Product Tile Label Custom Code - when using the 'Custom Label' for the product tiles, HTML code can be placed here.
  • "Free Trial" Label In Order Summary - places a label on products in the order summary indicating that a free trial is available for the given product.
    Templates can be edited or added under 'ProductTrialManager/storage/app/labels/productConfiguration'.
  • Order Summary Label Custom Code - when using the 'Custom Label' for the order summary, HTML code can be placed here.
  • Custom Landing Page - enter the URL to which the customer will be redirected after completing the trial order. If left empty, clients will be redirected to the invoice by default.
  • Default Gateway - define which payment gateway will be used with the free trial payment, if a client does not have a payment method set on his profile.

Do not forget to save the changes when ready.

PTM 12.png

Trials Per Customer Limit Example

Consider the following usage example with the following limit settings:
  • Trials Per Customer Limit: 3
  • Trials Per Customer Limit Time Frame: 7

Let's illustrate with a client's activity:

  • On the 1st day, the client orders 1 trial.
  • On the 5th day, the client orders two more trials.

Since the limit of 3 trials has been reached, the client cannot order any additional trials.
After 7 days have passed since the order of the first trial (on day 1), the trial count will be 2 out of 3, allowing the client to order one new trial.
Once 7 days have passed since the order of the two additional trials (on day 5), the trial count will reset to 0 out of 3, enabling the client to order more trials if needed.

PTM 12 1.png

Custom Labels

Product Free Trial Manager For WHMCS features the ability to create custom labels that can be used instead of the default ones. See the examples below to learn how to use this function.
Custom label visible on product tiles:

1. Navigate to '/home/your_whmcs/modules/addons/ProductTrialManager/storage/app/labels/productList' and create a new .html file.

PTM 12 2.png
2. Copy and paste the code from the default Lagom Client Theme or Twenty-One Theme labels (default-lagom.html or default-twentyone.html, depending on your theme).

3. Customize the variables to your liking:

  • Font size - size of the text in pixels.
  • Color - the color of the text, rgb number, hex number or name.
  • Font weight - normal, bold or number.
  • Text shadow - color and properties in pixels.
  • Background color - the color of the background, rgb number, hex number or name.
  • or enter your own code.

To position the label, include style= code inline as shown on the screenshot.
The message displayed on the label can be raw text, but to support multiple languages, we recommend using the lang variable included in the default labels.
4. Make sure you have saved the file.

PTM 12 3.png
5. Open the addon, navigate to 'Settings' '"Free Trial" Label On Product Tile' and select the new label.
PTM 12 4.png
Once you save your settings, the new label will be displayed on the tiles in the product list.

Note: You can keep editing the file and refreshing the page until you get the perfect configuration.

PTM 12 5.png
If you keep the {$MGLANG.freeTrial} variable in your configuration, you can set up different text for each language you support.

1. Navigate to '/home/your_whmcs/modules/addons/ProductTrialManager/langs'
2. Copy the english.php file, and rename the copy to the desired language.

PTM 12 6.png
3. Find the {$MGLANG.freeTrial} variable and translate the message.

4. Save the changes made in the file.

PTM 12 7.png
When the language in the client area matches the name of the file the text will be replaced.

Note: You can add more language files and edit all variables inside, creating multiple language versions for your clients and admins.

PTM 12 8.png
Custom label visible in the order summary:

1. Navigate to 'Settings' '"Free Trial" Label In Order Summary' and select 'Custom Label' .
2. Include the code in the box below, it functions the same way as the separate label file, so make sure you include the code for the correct theme, the label positioning and the language variable.
3. Remember to save changes.

PTM 12 9.png
The label will be displayed in the order summary.
PTM 12 10.png

Products

In the 'Products' section, you will find a full list of products and services available in your WHMCS.
PTM 13.png
Here you can turn on/off the trial access for single products or apply it to numerous products at once with mass action buttons.

Products with enabled here trial access will be applicable for clients if they meet all the requirements.

PTM 14.png

Email Reminders

'Email Reminders' tab allows the option to configure email reminders for your customers.
They will be allowed to make the decision ahead and pay for the product before its automatic suspension.

Press 'Add Reminder' to compose the first notification message rules.

PTM 15.png
Provide your reminder name, select one of the templates and enter the number of days.
The email reminder will be delivered this number of days before the invoice due date.
PTM 16.png
Once ready, you may turn on/off every single reminder, edit it or completely delete by pressing adequate buttons.
PTM 17.png
Note that you may use the module's dedicated email template. You will find it under 'Product Free Trial Manager - Reminder Notification' name.
The template content may be adjusted in your WHMCS → System Settings → Email Templates → Products/Services Templates.

List of supported merge fields that can be used in the email template:

Service related

  • $services_ids
  • $reminder_days
  • $service_product_name

Invoice related

  • $invoice_link
  • $invoice_id
  • $invoice_num
PTM 18.png

Logs

The 'Logs' section contains information on all actions taken by the module, that is:
  • information on orders placed and the module payment gateway selected,
  • email reminders sent
  • suspending products due to their trial access being expired.

You may always delete the logs if their number is extensive.

PTM 19.png

Client Area

Add products to your cart and select the payment gateway that allows free trial access to the ordered products.
Note that the name of the gateway may be different than the one on the screen below, as the display name of the payment gateway can be fully customized by your administrator in the module language file.

Important: The gateway will not be available if a free trial does not apply to all the products in the cart.
Depending on the module settings, the gateway will be either blocked or completely hidden.

PTM 21.png
Your order is now complete, you may download the package and start the tests.
PTM 20.png
If you wish to continue using your product right after the trial period, please remember to pay the remaining invoice.

In case the invoice remains unpaid on the day the trial period is over, your service will be automatically suspended.

PTM 22.png

Tips

1. Free trials can currently be applied to products and services, the module does not work with addons or domains (other than free domains attached to a product).

Update Instructions

An essential guidance through the process of updating the module is offered here.

Ensure successful completion of the module update by carefully following each step, thereby preventing data loss or any unforeseen issues.
Additionally, you will find a current list of supplementary actions necessary for a smooth update process there.

Upgrade Guide

Seeking a solution that offers greater flexibility, customization tailored to your precise needs, and unrestricted availability?
There is an option that not only proves to be cost-effective in the long run but also includes prioritized support services, making it a truly valuable investment.

Opt for the Open Source version of your Product Free Trial Manager For WHMCS module to unlock these benefits.
Simply click on either the Get Source Code or Upgrade To Lifetime button found on the product's page in our client area to complete the one-step upgrade process, with a dedicated discount already applied.

Follow a comprehensive guide covering the transition process, the advantages it brings, and step-by-step instructions on what to do next after the order has been successfully finalized.

Common Problems

1. When you have problems with connection, check whether your SELinux or firewall does not block ports.
2. We do not recommend using the Product Free Trial Manager For WHMCS with the following modules:
  • Payment Gateway Charges For WHMCS
  • Recurring Contract Billing For WHMCS
  • Resellers Center For WHMCS
  • Multibrand For WHMCS

Integration between these modules is hampered due to specific features of each one of them and their individual work flow.
We are continually working on eliminating these limitations wherever possible.

Navigation
WHMCS Modules
WHMCS Widgets
Translations
cPanel Modules
General
FAQ
Community
Product Free Trial Manager For WHMCS