From 797d39e84771a6291c43539081ca79bb38a85324 Mon Sep 17 00:00:00 2001 From: HeshamTB Date: Wed, 13 Sep 2023 16:16:29 +0300 Subject: [PATCH] [WIP] feat: perpping for audio --- main.go | 4 ++++ templates/download.html | 12 ++++++++++-- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/main.go b/main.go index f199b95..d88350a 100644 --- a/main.go +++ b/main.go @@ -166,6 +166,10 @@ func main() { w = writeJSONResponse(w, "Provide URL as query") return } + toAudio := r.FormValue("toaudio") + if toAudio == "on" { + log.Println("User requested audio") + } downloadURL, err := getYoutubeDownloadURL(userURL) if err != nil { diff --git a/templates/download.html b/templates/download.html index 1096679..58afe27 100644 --- a/templates/download.html +++ b/templates/download.html @@ -23,20 +23,28 @@ + +
+ +
+