Hi,
Is there any way to add addon domains with a script? I need to add a bunch of domains and it will take too much time to add them in cpanel, please advise.
Hi,
Is there any way to add addon domains with a script? I need to add a bunch of domains and it will take too much time to add them in cpanel, please advise.
Ok, I found AddonDomain.pm in /usr/local/cpanel/Cpanel, but how it supposed to get used?
I tried:
perl
use lib '/usr/local/cpanel';
use Cpanel;
use Cpanel::AddonDomain;
($res, $reas) = Cpanel::AddonDomain::api2_addaddondomain ({newdomain => 'aaa.com',subdomain=>'bbb',disallowdot=>'1',dir=>'public_html/aaa'});
print $reas;
and got:
Undefined subroutine &main::modloader called at /usr/local/cpanel/Cpanel.pm line 240.
So what to do next? I have greped /usr/local/cpanel for modloader and found nothing![]()