Description

This function disables leech protection for a directory.

Examples




$cpanel = new CPANEL(); // Connect to cPanel - only do this once.
$disable_leech = $cpanel->api1('LeechProtect','disable', array('/home/username/public_html/protected_directory/') ); // Call the function.

 



my $cpliveapi = Cpanel::LiveAPI->new(); # Connect to cPanel - only do this once.
my $disable_leech = $cpliveapi->api1('LeechProtect','disable', ['/home/username/public_html/protected_directory/']); # Call the function.

 


<cpanel Module="LeechProtect::disable ( $FORM('dir'))">




cpapi1 --user=username LeechProtect disable /home/username/public_html/protected_directory/


This function does not return output when you call it from an array. Otherwise, the function the output resembles the following example:

LeechProtection disabled for /home/user/public_html/test




Parameters

ParameterTypeDescriptionPossible valuesExample
dirstring

Required

The directory's path.

A valid absolute directory path.
/home/username/public_html/protected_directory/

Returns

This function does not return output when you call it from an array. Otherwise, the function returns a confirmation message.