How to Use the WHMCS TLD Pricing Templates

We offer three lightweight PHP templates that integrate with your WHMCS installation to display domain pricing in a clean, responsive layout. These templates fetch live pricing using the WHMCS API and include optional sorting, currency toggling, and caching.


Files Included

File Name Description
pricing-bootstrap.php Bootstrap 5 version with a modern UI
pricing-bootstrap4.php Bootstrap 4 version styled like the WHMCS admin area
pricing-enhanced.php Enhanced version with advanced sorting, caching, and styling

Features

  • WHMCS API integration (localAPI)

  • Currency toggle (default: USD and CAD)

  • Sort by TLD or price (ascending or descending)

  • Mobile-responsive (Bootstrap-based)

  • Weekly caching (to reduce API calls)

  • Easy to modify and extend


Installation

  1. Upload the Files
    Place the *.php files in your WHMCS root folder or a public subdirectory such as /pricing/.

  2. Adjust Currency Settings
    Open any of the PHP files and update the currency ID mapping in this array:

     
    $currencies = [ 'USD' => 1, 'CAD' => 2 ];

    You can find your currency IDs in WHMCS under Setup > Payments > Currencies.

  3. Verify WHMCS Path
    Make sure this line points to your actual WHMCS installation path:

     
    require '/path/to/whmcs/init.php';
  4. Set Cache Permissions
    Each file stores pricing in a /cache/ folder to avoid repeated API calls. If it doesn't exist, create it manually:

     
    mkdir cache chmod 755 cache

Access the Demo Pages

You can access the demos by visiting them in your browser:

  • yourdomain.com/pricing-bootstrap.php

  • yourdomain.com/pricing-bootstrap4.php

  • yourdomain.com/pricing-enhanced.php

Each version includes a currency toggle and sortable columns.


Customization Tips

  • To change the default sort order, look for this line:

     
    $sortBy = isset($_GET['sort']) ? $_GET['sort'] : 'whmcs';

    Change 'whmcs' to 'alpha_asc', 'price_asc', etc. as needed.

  • To add or remove currencies, modify the $currencies array.

  • You can update Bootstrap styles, colors, or layout by editing the HTML inside each file.


Need Help?

If you need help customizing the templates or integrating them into your website or client area, please contact support.

  • 0 Korisnici koji smatraju članak korisnim
Je li Vam ovaj odgovor pomogao?

Vezani članci

Installation and Configuration Guide for Sendy Auto Campaign WordPress Plugin

1. Upload and Install the Plugin Access your WordPress Dashboard: Start by logging into your...

Installation and Configuration Guide for Sendy and WHMCS Integration

Prerequisites Before you begin, ensure you have the following: A WHMCS installation. A Sendy...

Installation and Configuration Guide for WHMCS Mailcow Integration

This provisioning module for WHMCS utilizes the Mailcow API. The module allows offering email...

Configure the WHMCS Bulk Client Export Script

The WHMCS Client Export Script allows you to filter and export client data from your WHMCS...

Configure the WHMCS Bulk Client Import Script

Overview This guide will walk you through the steps to configure and use the WHMCS API...