Configuration for DNS hosting of registered domains

With the Registered domains mode of our WHMCS module your customers will be able to manage the DNS zones of their registered domain names. When a domain name is successfully registered the customer will be checked, if has access to the product you will create in Step 1 and if not the service will be activated for him automatically. All domains registered by your customer will be shown in this Service. If there is no DNS zone for a particular domain name, it will be automatically created the first time the customer try to manage it.

Configuring a (free) product for DNS management of registered domains:

1. Create new Product/Service for DNS hosting and from the Module Settings tab choose ClouDNS DNS Manager as Module name. Remember the ID of the product, you will need it in Step 3.

2. Tick the Registered Domains checkbox, this will allow only registered domains in your system to have DNS zones in this service and the limit will be the amount of registered domains the customer has.

3. Open /path/to/whmcs/modules/servers/cloudns/cloudns_core/configuration.php with a text editor and enter an admin username, who has WHMCS API access. The permissions for that can be granted to the group the admin is in from WHMCS admin panel > Setup > Staff Managament > Administrator Users / Administrator Roles.

// whmcs admin account username
public static $_admin = 'admin';

After that enter the ID of the product.

 * id of the product created for Free DNS management
 * of registerred domains.
 * It will be automatically activated 1
 * time after a successfull domain registration.
public static $_pid = 0;

Save the file.

4. Move the file /path/to/whmcs/modules/servers/cloudns/cloudns_core/hooks/cloudns.php in /path/to/whmcs/includes/hooks/cloudns.php. The file has the following content:

if (!defined("WHMCS")) {
    die("This file cannot be accessed directly");

function activateFreeDNS ($vars) {
    include ROOTDIR.'/modules/servers/cloudns/cloudns_core/hooks/add-free-dns-to-domain.php';

add_hook('AfterRegistrarRegistration', 1, 'activateFreeDNS');

That's it!

Cookies help us deliver our services. By using our services, you agree to our use of cookies. Learn more