Description

This function checks whether the Password Protect feature protects a specified directory.

Examples 




$cpanel = new CPANEL(); // Connect to cPanel - only do this once.
$check_protected = $cpanel->api1('Htaccess','checkprotected', array('protectedfolder') ); // Call the function.



my $cpliveapi = Cpanel::LiveAPI->new(); # Connect to cPanel - only do this once.
my $check_protected = $cpliveapi->api1('Htaccess','checkprotected', ['protectedfolder'] ); # Call the function.

 


<cpanel Module="Htaccess::checkprotected( $FORM('dir') )">




cpapi1 --user=username Htaccess checkprotected protectedfolder



checked




Parameters

ParameterTypeDescriptionPossible valuesExample

dir

string

Required

The directory name.

A valid directory name.protectedfolder

Returns

This function will display checked if the directory is password protected.