Remove all Document Properties (PHP REST)

Skip to end of metadata
Go to start of metadata
This example allows you to remove all document properties using Saaspose.Pdf REST API in your PHP applications.
We're referring to the following common methods to perform general operations:


	    $filePath = getcwd() . "\\Input\\MyFile.pdf";
	    $fileName = basename($filePath);

	    //set application information
	    $AppSID = "77**************";
	    $AppKey = "89***********";
	    
	    //build URI to replace image
	    echo "Uploading pdf file... <br/>";
	    $strURIRequest = "http://api.saaspose.com/v1.0" . "/storage/file/" . $fileName;
	    $signedURI = Sign($strURIRequest);
	    uploadFileBinary($signedURI, $filePath); 
	    echo "Pdf file has been uploaded successully <br/>";

	    echo "Removing document properties... </br>";
	    //build URI
	    $strURI = "http://api.saaspose.com/v1.0" . "/pdf/" . $fileName . "/documentProperties"	    //sign URI
	    $signedURI = Sign($strURI);
	    $responseStream = processCommand($signedURI, "DELETE", "", "");
	    $response_arr = json_decode($responseStream); 
	    if($response_arr->Code == 200)
	    	   echo "Properties have been removed successfully";
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.