mirror of
https://github.com/eiblog/eiblog.git
synced 2026-02-23 06:32:28 +08:00
requesturi to referer
This commit is contained in:
2
front.go
2
front.go
@@ -215,7 +215,7 @@ func HandleBeacon(c *gin.Context) {
|
|||||||
cookie, _ := c.Cookie("u")
|
cookie, _ := c.Cookie("u")
|
||||||
vals.Set("cid", cookie)
|
vals.Set("cid", cookie)
|
||||||
|
|
||||||
vals.Set("dl", c.Request.Host+c.Request.RequestURI)
|
vals.Set("dl", c.Request.Referer())
|
||||||
vals.Set("uip", c.ClientIP())
|
vals.Set("uip", c.ClientIP())
|
||||||
go func() {
|
go func() {
|
||||||
req, err := http.NewRequest("POST", "https://www.google-analytics.com/collect", strings.NewReader(vals.Encode()))
|
req, err := http.NewRequest("POST", "https://www.google-analytics.com/collect", strings.NewReader(vals.Encode()))
|
||||||
|
|||||||
Reference in New Issue
Block a user