Domain Categories
In the Client Area, domain categories group domain TLDs into categories on the Client Area Register Domain page. For example, they could appear in groups like Popular, Shopping, or Real Estate.
Domain categories make it easier for clients to find their ideal domain extensions.
The categories.json File
You can find the default domain categories that ship with WHMCS in the /resources/domains/dist.categories.json
file.
To add or edit domain category definitions, create your own custom category file.
- This file must use valid JSON.
- The update process will not overwrite changes that you make in your custom file.
.uk
and .co.uk
in the Popular
and Local
categories.Add a TLD or Category
To add a category or add a TLD to a default category, add a section that resembles this example to your custom /resources/domains/categories.json
file:
{
"Domains A-F": [
".biz",
".ca",
".com",
".co.uk",
".de",
".eu"
]
}
This example adds a Domains A-F
domain category with several TLDs.
Translate a Category
You can add category name translations to match your customers’ chosen languages. To do this, add an entry for the desired translation in each language’s override file.
For example, you could add the following override string to the german.php
language override file to translate a Money and Finance
category name into German:
$_LANG['domainTldCategory']['Money and Finance'] = "Geld und Finanzen";
Remove a TLD from a Default TLD Category
To remove a TLD from a default category, add a section that resembles this example to your custom /resources/domains/categories.json
file:
{
"REMOVE": {
"Popular": [
".com",
".net"
]
}
}
This example removes the .com
and .net
TLDs from appearing in the default Popular
category.
Add and Remove TLDs
If you want to both create and add to new categories while removing TLDs from default categories, add additions and removals in the same set of curly braces. For example:
{
"Domains A-F": [
".biz",
".ca",
".com",
".co.uk",
".de",
".eu"
],
"REMOVE": {
"Popular": [
".com",
".net"
]
}
}
Last modified: September 10, 2024