ILIAS  release_6 Revision v6.24-5-g0c8bfefb3b8
ilCertificateBackgroundImageDelete Class Reference
+ Collaboration diagram for ilCertificateBackgroundImageDelete:

Public Member Functions

 __construct (string $certificatePath, ilCertificateBackgroundImageFileService $fileService)
 
 deleteBackgroundImage (string $version)
 

Private Attributes

 $certificatePath
 
 $fileService
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilCertificateBackgroundImageDelete::__construct ( string  $certificatePath,
ilCertificateBackgroundImageFileService  $fileService 
)
Parameters
string$certificatePath
ilCertificateBackgroundImageFileService$fileService

Definition at line 24 of file classs.ilCertificateBackgroundImageDelete.php.

References $certificatePath, and $fileService.

Member Function Documentation

◆ deleteBackgroundImage()

ilCertificateBackgroundImageDelete::deleteBackgroundImage ( string  $version)

Definition at line 30 of file classs.ilCertificateBackgroundImageDelete.php.

References $filename.

31  {
32  if (file_exists($this->fileService->getBackgroundImageThumbPath())) {
33  unlink($this->fileService->getBackgroundImageThumbPath());
34  }
35 
36  $filename = $this->certificatePath . 'background_' . $version . '.jpg';
37  if (file_exists($filename)) {
38  unlink($filename);
39  }
40 
41  if (file_exists($this->fileService->getBackgroundImageTempfilePath())) {
42  unlink($this->fileService->getBackgroundImageTempfilePath());
43  }
44  }
$filename
Definition: buildRTE.php:89

Field Documentation

◆ $certificatePath

ilCertificateBackgroundImageDelete::$certificatePath
private

Definition at line 13 of file classs.ilCertificateBackgroundImageDelete.php.

Referenced by __construct().

◆ $fileService

ilCertificateBackgroundImageDelete::$fileService
private

Definition at line 18 of file classs.ilCertificateBackgroundImageDelete.php.

Referenced by __construct().


The documentation for this class was generated from the following file: