if (!function_exists('thumb')) {
function thumb($query, $file) {
$file = str_replace('https://softpas.com/build/', '', $file);
$file = str_replace('https://www.softpas.com/build/', '', $file);
// Dacă e URL complet (extern), mergem direct pe CDN
if (strpos($file, 'https') === 0) {
return thumb_cdn($query, $file);
}
$query = str_replace(':', '=', $query); // fix pentru Windows
if (request()->accepts('image/webp')) {
$file .= '.webp';
}
// Folosim direct CDN-ul pe baza fișierului din storage
return thumb_cdn($query, asset('storage/' . $file));
}
}
Tag: Project Backup | SoftPas
SoftPas is your platform for the latest software and technology news, reviews, and guides. Stay up to date with cutting-edge trends in tech and software development.