Create protected directory

				
					StructOperationResponse WebHostingProtectedDirCreate(string $IDsession, string $id, string $fqdn, string $pathSecured, string $authname, string $username, string $password)
				
			

Add a protection on a directory in the vhost.

REQUIRED

  • idSession string (32)
    Session ID.
  • id string
    Hosting ID.
  • fqdn string
    fqdn of the vhost.
  • pathSecured string
    Path of the directory, starting from the directory of the vhost.
  • authname string
    Realm to be used in the authentication.
  • username string
    Login of the first user.
  • password string
    Password of the first user.

An Object of type StructOperationResponse

<?php 
$clientSOAP = new SoapClient("http://URL.wsdl");
 
try 
{
 
    $idSession = $clientSOAP->sessionOpen("XX000", "xxxxxxxx"); 
    $clientSOAP->WebHostingProtectedDirCreate($idSession, "NW1024", "wordpress.netim.com", "/protected", "Please login", "admin", "12abCD%@"); 
}
catch(SoapFault $fault) 
{
    echo "Exception : " .$fault->getMessage(). "\n"; 
}
 
if (isset($idSession)) 
{
    $clientSOAP->sessionClose($idSession); 
}