? GR0V Shell

GR0V shell

Linux www.koreapackagetour.com 2.6.32-042stab145.3 #1 SMP Thu Jun 11 14:05:04 MSK 2020 x86_64

Path : /home/admin/public_html/old/promice/Admin/src/QuPlupload/Model/
File Upload :
Current File : /home/admin/public_html/old/promice/Admin/src/QuPlupload/Model/RemoveModel.php

<?php
/**
 * @Author: Cel Ticó Petit
 * @Contact: cel@cenics.net
 * @Company: Cencis s.c.p.
 */

namespace QuPlupload\Model;


class RemoveModel
{

    /**
     * @var
     */
    protected $uploadDir;

    /**
     * @var
     */
    protected $ThumbResize;


    public function Remove($fileName){

        $ThumbSize    = $this->ThumbResize;
        $UploadDir    = $this->uploadDir;
        $file         = $UploadDir . DIRECTORY_SEPARATOR . $fileName;

        foreach($ThumbSize as $key => $size)
        {

            $fileSize = $UploadDir . DIRECTORY_SEPARATOR . $key . $fileName;
            if(file_exists($fileSize))
            {
                @unlink($fileSize);
            }

        }

        if(file_exists($file))
        {
            @unlink($file);
            return true;
        }

        return false;

    }

    /**
     * @param $uploadDir
     * @return $this
     */
    public function setUploadDir($uploadDir)
    {
        $this->uploadDir = $uploadDir;
        return $this;
    }

    /**
     * @return string
     */
    public function getUploadDir()
    {
        return $this->uploadDir;
    }

    /**
     * @param array $ThumbResize
     * @return $this
     */
    public function setThumbResize(array $ThumbResize)
    {
        $this->ThumbResize = $ThumbResize;
        return $this;
    }

    /**
     * @return string
     */
    public function getThumbResize()
    {
        return $this->ThumbResize;
    }

}

T1KUS90T
  root-grov@210.1.60.28:~$