From 89cf49af5862ff60d2df8011d1c5d47ea762755d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=96zg=C3=BCr=20Kesim?= Date: Sun, 6 Oct 2019 17:10:57 +0200 Subject: [PATCH] =?UTF-8?q?Benutze=20url.QueryEscape=20f=C3=BCr=20die=20Su?= =?UTF-8?q?chw=C3=B6rter?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- dict.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dict.go b/dict.go index 11ad959..9721269 100644 --- a/dict.go +++ b/dict.go @@ -4,6 +4,7 @@ import ( "bufio" "fmt" "net/http" + "net/url" "os" "regexp" "strings" @@ -30,7 +31,7 @@ func main() { fromto = os.Args[2] + "." } - r, err := http.Get("http://" + fromto + BASE + os.Args[1]) + r, err := http.Get("http://" + fromto + BASE + url.QueryEscape(os.Args[1])) if err != nil { println("error:", err.Error()) return