77 questions
1
vote
1
answer
119
views
I can't query by UUID
I'm having trouble querying UUID values stored as BLOB(16) in SQLite3 using Go (with goqu). I insert a UUID using uuid.New().MarshalBinary() and this works correctly. However, when I try to select the ...
0
votes
0
answers
84
views
goquery replaces all self closing tags by open and closing tags
I am processing html contents with some custom elements which might be self-closing tags. Below is the example:
<!DOCTYPE en-note SYSTEM \"http://xml.evernote.com/pub/enml2.dtd\"><...
2
votes
1
answer
49
views
how write link in links
package main
import (
"fmt"
"github.com/PuerkitoBio/goquery"
"log"
)
func main() {
var links string = ""
doc, err := goquery.NewDocument(...
3
votes
0
answers
619
views
join using Goqu and scan the results into a struct containing an array of another struct
type selectUserWithOrders struct {
id int
name string
orders []order
}
type order struct {
id int
total int
}
// user table columns are -> id , name, password
// orders table columns are -&...
2
votes
1
answer
363
views
Extracting information from an attribute using goquery
package main
import (
"fmt"
"github.com/PuerkitoBio/goquery"
"net/http"
)
func main() {
url := "https://books.toscrape.com"
resp, err := ...
1
vote
0
answers
44
views
How to save the image in html (in crawler), which is changed to another image after about 1 minute or by reload(request)
I'm trying to make some automatic captcha input systems (recognition of figures in captcha image by deep learning and input the figure automatically)
.
For that, the captcha image should be inputted ...
1
vote
0
answers
111
views
Use GoQuery to modify style?
In GoQuery, how do you use it properly to modify the style of a certain element in a loop? I am currently unable to find it in the documentation.
doc.Find("class[id=needsclick]").Each(func(i ...
0
votes
2
answers
144
views
goquery get all <p> tags from just one selector
I have the following example
<div class="myClass">
<div>
<div>
<p>1</p>
</div>
</div>
<p>2&...
0
votes
0
answers
50
views
How to get text from <h3> without taking the span
I have the following function,
func getMosWantedInfo(doc *goquery.Document) {
doc.Find("div.flex-align-center.bg-base-lightest.padding-1.margin-1").Each(func(i int, s *goquery.Selection) ...
1
vote
2
answers
472
views
How can I use goquery parse single element
<speak><voice name=\"en-US-JennyNeural\"><prosody rate=\"1\">aaaaaaaa<break time=\"5s\"/> bbbb. <br time=\"2s\"/>ccccccdddddddd &...
2
votes
0
answers
621
views
Correlating HTML elements when scraping with golang/goquery/colly
I've been using colly for some simple web scraping tasks. It works fine for most of the cases where the web page layouts are consistent or for simple logic (e.g. a lot of existing examples and ...
1
vote
0
answers
460
views
How might I find an element in goquery like I would with find_all in BeautifulSoup?
I want to accomplish with goquery the same what is done
by the following Python code (the xpath in the comment specifies what is my target):
from requests import get
from bs4 import BeautifulSoup
#/...
2
votes
2
answers
767
views
Golang table webscraping
I have a code as below to scrape the specific cell value from html table. You can go to https://www.haremaltin.com/altin-fiyatlari website and search "satis__ATA_ESKI" on inspect mode to see ...
1
vote
0
answers
3k
views
Colly (GoLang) Web Scrapper - 403 Forbidden
I am trying to scrape products from mediamarkt site with Colly. Here is my code:
func WebScraper(allowedDomain string, page string, htmlElement string, htmlTag string) {
/*
Order in which ...
1
vote
1
answer
177
views
How can I add a non-escaped string as a plaintext node or as an attribute value?
I am trying to use a string containing a ' character as an attribute value. However, ' is always replaced with '. Is there a way around this? Since the value is enclosed with ", ' wouldn'...