Level 102
I believe it should be
header("Location: /install.php");
1 like
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
Hello Team. With this php, i will unzip my laravel folders. But after this, i will redirect to a other php file. The redirect doesnt work :(
<?php
$file = 'my-dev.zip'; //Dateiname entsprechend �ndern
$path = pathinfo(realpath($file), PATHINFO_DIRNAME);
$zip = new ZipArchive;
$res = $zip->open($file);
if ($res === TRUE) {
$zip->extractTo($path);
$zip->close();
header('/install.php');
} else {
echo "Die Datei $file konnte nicht gefunden/geöffnet werden.";
}
exit;
?>
Does it work if you just place this at the very top (after <?php)
header("Location: http://localhost/install.php");
Please or to participate in this conversation.