3.1. USING THE CPANEL::ACCOUNTING PERL MODULE
CHAPTER 3. FAQ
}
print \$response;
my %PKGS = \$whm >listpkgs();
if (\$whm >{error} ne "") {
print "There was an error while processing your request: Cpanel::Accounting returned [\$whm >{error}]\n";
exit;
}
foreach \$package (sort keys %PKGS) {
@PKCTS = @{\$PKGS{\$package}};
print "\$package @PKCTS\n";
}
\$response = \$whm >createacct("","","","");
if (\$whm >{error} ne "") {
print "There was an error while processing your request: Cpanel::Accounting returned [\$whm >{error}]\n";
exit;
}
print \$response;
\$response = \$whm >suspend('');
if (\$whm >{error} ne "") {
78