Description
This function lists information for the cPanel account's Site Publisher websites.
Note:
To retrieve the list of Site Publisher website information, the function queries the configurations.json
file in each domain's document root.
Examples
Note:
Use cPanel's API Shell interface (Home >> Advanced >> API Shell) to directly test cPanel API calls.
Parameters
This function does not accept parameters.
Returns
Return
|
Type
|
Description
|
Possible values
|
Example
|
|
hash
|
An unnamed hash of each domain's site template information.
|
This hash includes the homedir, documentroot, type, and domainreturns, the serveralias array, and the template_settingshash.
|
|
template_settings
|
hash
|
A hash of template settings.
The function returns this hash in the unnamed hash.
|
This hash includes the is_empty, path, and template returns.
Important:
This hash also contains the user's website content. The template provider determines these values.
|
|
is_empty
|
Boolean
|
Whether the domain'sconfigurations.jsonfile exists and contains template information.
The function returns this value in thetemplate_settingshash.
|
|
0
|
path
|
string
|
The template directory path.
The function returns this value in thetemplate_settingshash.
|
|
|
template
|
string
|
The template's name.
The function returns this value in thetemplate_settingshash.
|
The name of a template, as it appears in theconfigurations.json file.
|
mytemplate
|
homedir
|
string
|
The user's home directory.
The function returns this value in the unnamed hash.
|
The absolute path to the cPanel account's home directory.
|
/home/example
|
documentroot
|
string
|
The domain's document root.
The function returns this value in the unnamed hash.
|
The absolute path to the directory's document root inside of the account's home directory.
|
/home/example/public_html
|
serveralias
|
array
|
An array of the domain's aliases.
The function returns this array in the unnamed hash.
|
An array of one or more of the domain's aliases.
|
www.example.com
|
type
|
string
|
The domain's type.
The function returns this value in the unnamed hash.
|
|
main
|
domain
|
string
|
The domain name.
The function returns this value in the unnamed hash.
|
A valid domain name.
|
example.com
|