Пример #1
0
 /**
  * @access private
  * @param $dir
  */
 private function cacheDir($dir)
 {
     $makefile = new magixcjquery_files_makefiles();
     $pathDir = $this->pathCacheDir($dir);
     if (file_exists($pathDir)) {
         $scandir = $makefile->scanDir($pathDir, array('.htaccess', '.gitignore'));
         $clean = '';
         if ($scandir != null) {
             foreach ($scandir as $file) {
                 $clean .= $makefile->removeFile($pathDir, $file);
             }
         }
     } else {
         $magixfire = new magixcjquery_debug_magixfire();
         $magixfire->magixFireError(new Exception('Error: var is not exist'));
     }
 }
Пример #2
0
 /**
  * Suppression d'image
  */
 private function remove_image()
 {
     if (isset($this->delete_image)) {
         $makeFiles = new magixcjquery_files_makefiles();
         $vimage = parent::s_n_image_news($this->delete_image);
         if (file_exists(self::dir_img_news() . $vimage['n_image'])) {
             $makeFiles->removeFile(self::dir_img_news(), $vimage['n_image']);
             $makeFiles->removeFile(self::dir_img_news(), 's_' . $vimage['n_image']);
         }
         $img = null;
         parent::u_news_image($img, $this->delete_image);
     }
 }
Пример #3
0
 /**
  * @access private
  * Suppression des images de galerie produit
  */
 private function remove_product_galery()
 {
     if (isset($this->delete_galery)) {
         $makeFiles = new magixcjquery_files_makefiles();
         $data = parent::s_product_galery_data($this->delete_galery);
         if (file_exists(self::dirImgProductGalery() . 'maxi' . DIRECTORY_SEPARATOR . $data['imgcatalog'])) {
             $makeFiles->removeFile(self::dirImgProductGalery() . 'maxi' . DIRECTORY_SEPARATOR, $data['imgcatalog']);
             $makeFiles->removeFile(self::dirImgProductGalery() . 'mini' . DIRECTORY_SEPARATOR, $data['imgcatalog']);
             parent::d_product_galery($this->delete_galery);
         }
     }
 }