package main
import (
"regexp"
"fmt"
)
func main() {
var re = regexp.MustCompile(`(?m)https:\/\/kiusk\.ca\/wp-content\/uploads.*\.(?:gif|jpeg|png|psd|bmp|tiff|tiff|jp2|iff|vnd\.microsoft\.icon|xbm|vnd\.wap\.wbmp|webp|)`)
var str = `https://kiusk.ca/wp-content/uploads/2022/01/dc2.webp`
for i, match := range re.FindAllString(str, -1) {
fmt.Println(match, "found at index", i)
}
}
Please keep in mind that these code samples are automatically generated and are not guaranteed to work. If you find any syntax errors, feel free to submit a bug report. For a full regex reference for Golang, please visit: https://golang.org/pkg/regexp/