Description
The fetch()
method is a wrapper to return a hash reference from the cpanelprint()
function, which retrieves a cPanel variable.
Note:
To return a data result for a cPanel variable's value, use the cpanelprint()
method.
Example
LiveAPI PHP Class
1
2
|
// Get a hashref of the cPanel account's username. $cpanel ->fetch( '$user' ); |
LiveAPI Perl Module
1
2
|
# Get a hashref of the cPanel account's username. $cpliveapi ->fetch( '$user' ); |
Parameters
Parameter |
Type |
Description |
Possible values |
Example |
variable |
string |
A cPanel variable. |
A valid cPanel variable.
|
$user |
Returns
This method returns the cPanel variable's value as a hash reference.