Пробуем по другому
This commit is contained in:
parent
7bc0336b7a
commit
766f7d4f9d
|
@ -33,7 +33,10 @@ class YoutubeDownloadController extends Controller
|
||||||
//return response()->download($file_path);
|
//return response()->download($file_path);
|
||||||
// $video->getFile(); // \SplFileInfo instance of downloaded file
|
// $video->getFile(); // \SplFileInfo instance of downloaded file
|
||||||
//$file_path = public_path('/downloads/'.$videotitle);
|
//$file_path = public_path('/downloads/'.$videotitle);
|
||||||
return redirect()->route('download', [$videotitle]);
|
$response = new \stdClass();
|
||||||
|
$response->link = $videotitle;
|
||||||
|
return response(json_encode($response));
|
||||||
|
//return redirect()->route('download', [$videotitle]);
|
||||||
//return response()->download($file_path);
|
//return response()->download($file_path);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,9 +3,10 @@
|
||||||
<v-card-text class="d-flex justify-center align-center">
|
<v-card-text class="d-flex justify-center align-center">
|
||||||
<v-card class="align-center justify-center h-auto w-33">
|
<v-card class="align-center justify-center h-auto w-33">
|
||||||
<v-card-title>Вставьте ссылку:</v-card-title>
|
<v-card-title>Вставьте ссылку:</v-card-title>
|
||||||
<v-card-text>
|
<v-card-text class="justify-center">
|
||||||
<v-text-field v-model="url" label="Ссылка"/>
|
<v-text-field v-model="url" label="Ссылка"/>
|
||||||
<v-btn @click="startDownload">Скачать</v-btn>
|
<v-btn @click="startDownload">Найти</v-btn>
|
||||||
|
<v-btn>Скачать</v-btn>
|
||||||
</v-card-text>
|
</v-card-text>
|
||||||
</v-card>
|
</v-card>
|
||||||
</v-card-text>
|
</v-card-text>
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
<head>
|
<head>
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||||
<title>Boilerplate</title>
|
<title>Youtube Download</title>
|
||||||
@vite('resources/app.js')
|
@vite('resources/app.js')
|
||||||
@vite('resources/css/app.css')
|
@vite('resources/css/app.css')
|
||||||
</head>
|
</head>
|
||||||
|
|
Loading…
Reference in New Issue