From ca5ac0bcb9206e81faab60cc8a8d6da697bdfdbe Mon Sep 17 00:00:00 2001 From: horus Date: Mon, 12 Feb 2018 22:54:55 +0100 Subject: Crawler saves whole webpage. --- crawler/shop_bottleworld.go | 3 +++ 1 file changed, 3 insertions(+) (limited to 'crawler/shop_bottleworld.go') diff --git a/crawler/shop_bottleworld.go b/crawler/shop_bottleworld.go index 3eb151d..06082d4 100644 --- a/crawler/shop_bottleworld.go +++ b/crawler/shop_bottleworld.go @@ -61,6 +61,7 @@ func ScrapeBottleWord(shop Shop) []Angebot { W.Abv = get_abv(e) W.Spirit_type = e.Request.Ctx.Get("spirit_type") + W.Website = e.Request.Ctx.Get("website") Whiskys = append(Whiskys, W) }) @@ -78,6 +79,8 @@ func ScrapeBottleWord(shop Shop) []Angebot { e.Request.Ctx.Put("abv", td_str) } }) + + e.Request.Ctx.Put("website", string(e.Response.Body)) }) c.OnHTML(".short-description", func(e *colly.HTMLElement) { -- cgit v1.2.3