Cpanel::AddonDomain::addaddondomain

This article documents the usage of the Cpanel::AddonDomain::addaddondomain function in relation to the cPanel interface. This tag can be used inside cPanel pages.


SYNOPSIS

Cpanel::AddonDomain::addaddondomain


DESCRIPTION

This tag will create an addon domain based on the input variables below.


VARIABLES

INPUT

newdomain (string)
Name of the addon domain. Format: addondomain.com

dir (string)
Path to the new addon domains root. Relative to /home/username/

pass (string)
FTP password for addon domain user.

subdomain (string)
FTP user for addon domain. Format: username

OUTPUT

result
The result of the addon domain addition process

reason
The reason for failure, if any.


EXAMPLES

<?cp AddonDomain::addaddondomain('% %',result,reason) newdomain=$FORM{'domain'},dir=$FORM{'dir'},subdomain=$FORM{'user'},pass=$FORM{'pass'} ?>

This example will create an addon domain based on the domain name, directory name, username and password provided through a form. The result of the operation will be outputted and any reason for failure, if present.


COPYRIGHT

Copyright 2007 cPanel Inc.