<?php $file = '/path/file.php'; if (file_exists($file)) { require_once $file; } else { http_response_code(404); }