Description

This function checks whether the account allows anonymous FTP connections.

Examples 




https://hostname.example.com:2083/cpsess##########/execute/Ftp/allows_anonymous_ftp



$cpanel = new CPANEL(); // Connect to cPanel - only do this once.
 
// Check whether anonymous FTP is enabled.
$anon_ftp_enabled = $cpanel->uapi(
    'Ftp', 'allows_anonymous_ftp'
);

 



my $cpliveapi = Cpanel::LiveAPI->new(); # Connect to cPanel - only do this once.
 
# Check whether anonymous FTP is enabled.
my $anon_ftp_enabled = $cpliveapi->uapi(
    'Ftp', 'allows_anonymous_ftp',
);

 



<!-- Check whether anonymous FTP is enabled. -->
[% execute( 'Ftp', 'allows_anonymous_ftp' ); %]

 



uapi --user=username Ftp allows_anonymous_ftp 



{
  "messages": null,
  "errors": null,
  "status": 1,
  "data": {
    "allows": 0
  }
}



Parameters

This function does not accept parameters.

Returns

ReturnTypeDescriptionPossible valuesExample
allowsBooleanWhether the cPanel account allows anonymous FTP connections.
  • 1 — Allowed.
  • 0 — Not allowed.
1