!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/classify.picotech.app/public_html/Modules/Testimonial/Http/Controllers/   drwxr-xr-x
Free 29.31 GB of 117.98 GB (24.84%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


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

namespace Modules\Testimonial\Http\Controllers;

use 
Illuminate\Contracts\Support\Renderable;
use 
Illuminate\Foundation\Validation\ValidatesRequests;
use 
Illuminate\Http\Request;
use 
Illuminate\Routing\Controller;
use 
Modules\Language\Entities\Language;
use 
Modules\Testimonial\Actions\CreateTestimonial;
use 
Modules\Testimonial\Actions\DeleteTestimonial;
use 
Modules\Testimonial\Actions\UpdateTestimonial;
use 
Modules\Testimonial\Entities\Testimonial;
use 
Modules\Testimonial\Http\Requests\TestimonialFormRequest;

class 
TestimonialController extends Controller
{
    use 
ValidatesRequests;

    public function 
__construct()
    {
        
$this->middleware(['permission:testimonial.view'])->only('index');
        
$this->middleware(['permission:testimonial.create'])->only(['create''store']);
        
$this->middleware(['permission:testimonial.update'])->only(['edit''update']);
        
$this->middleware(['permission:testimonial.create'])->only(['create''store']);
        
$this->middleware(['permission:testimonial.update'])->only(['edit''update']);
        
$this->middleware(['permission:testimonial.delete'])->only(['destroy']);
    }

    
/**
     * Display a listing of the resource.
     *
     * @return Renderable
     */
    
public function index()
    {
        try {
            
$testimonials Testimonial::latest()->get();
            
$group_testimonials $testimonials->groupBy('code');

            return 
view('testimonial::index'compact('testimonials''group_testimonials'));
        } catch (
\Exception $e) {
            
flashError('An error occurred: '.$e->getMessage());

            return 
back();
        }
    }

    
/**
     * Show the form for creating a new resource.
     *
     * @return Renderable
     */
    
public function create()
    {
        try {
            
$app_languages Language::all(['id''name''code']);

            return 
view('testimonial::create'compact('app_languages'));
        } catch (
\Exception $e) {
            
flashError('An error occurred: '.$e->getMessage());

            return 
back();
        }
    }

    
/**
     * Store a newly created resource in storage.
     *
     * @param  Request  $request
     * @return Renderable
     */
    
public function store(TestimonialFormRequest $request)
    {
        try {
            
$testimonial CreateTestimonial::create($request);

            if (
$testimonial) {
                
flashSuccess('Testimonial Added Successfully');

                return 
back();
            } else {
                
flashError();

                return 
back();
            }
        } catch (
\Exception $e) {
            
flashError('An error occurred: '.$e->getMessage());

            return 
back();
        }
    }

    
/**
     * Show the form for editing the specified resource.
     *
     * @param  int  $id
     * @return Renderable
     */
    
public function edit(Testimonial $testimonial)
    {
        try {
            
$app_languages Language::all(['id''name''code']);

            return 
view('testimonial::edit'compact('testimonial''app_languages'));
        } catch (
\Exception $e) {
            
flashError('An error occurred: '.$e->getMessage());

            return 
back();
        }
    }

    
/**
     * Update the specified resource in storage.
     *
     * @param  Request  $request
     * @param  int  $id
     * @return Renderable
     */
    
public function update(TestimonialFormRequest $requestTestimonial $testimonial)
    {
        try {
            
$testimonial UpdateTestimonial::update($request$testimonial);

            if (
$testimonial) {
                
flashSuccess('Testimonial Updated Successfully');

                return 
redirect(route('module.testimonial.index'));
            } else {
                
flashError();

                return 
back();
            }
        } catch (
\Exception $e) {
            
flashError('An error occurred: '.$e->getMessage());

            return 
back();
        }
    }

    
/**
     * Remove the specified resource from storage.
     *
     * @param  int  $id
     * @return Renderable
     */
    
public function destroy(Testimonial $testimonial)
    {
        try {
            
$testimonial DeleteTestimonial::delete($testimonial);

            if (
$testimonial) {
                
flashSuccess('Testimonial Deleted Successfully');

                return 
back();
            } else {
                
flashError();

                return 
back();
            }
        } catch (
\Exception $e) {
            
flashError('An error occurred: '.$e->getMessage());

            return 
back();
        }
    }
}

:: 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.0037 ]--