From 817accd04e8542c6de60b8181dcf16154c85456b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=A3=9E=E9=9B=AA=E6=97=A0=E6=83=85?= Date: Sat, 28 Dec 2024 20:41:47 +0800 Subject: [PATCH] update ga to v4 --- README.md | 5 +++-- README_EN.md | 2 +- layouts/partials/copyright.html | 2 +- layouts/partials/footer.html | 9 +++------ layouts/partials/head.html | 2 +- 5 files changed, 9 insertions(+), 11 deletions(-) diff --git a/README.md b/README.md index 1a6fb96..4964256 100644 --- a/README.md +++ b/README.md @@ -178,9 +178,10 @@ type: "search" #### 添加GA分析统计 -该主题已经支持了GA分析统计,只需要在`config.toml`配置里加入如下配置即可。 +该主题已经支持了GA4分析统计,只需要在`config.toml`配置里加入如下配置即可。 +一定要使用最新的GA4分析,填写`衡量ID`,以`G-`开头。 ```toml -googleAnalytics = "GA ID" +googleAnalytics = "G-xxxxxxxxxx" ``` #### 文章归档支持 diff --git a/README_EN.md b/README_EN.md index b61ae77..69f01b9 100644 --- a/README_EN.md +++ b/README_EN.md @@ -122,7 +122,7 @@ Ads Preview [http://www.flysnow.org/](http://www.flysnow.org/) #### Google Analytics ```toml -googleAnalytics = "GA ID" +googleAnalytics = "G-xxxxxxxxxx" ``` #### Custonm Summaries diff --git a/layouts/partials/copyright.html b/layouts/partials/copyright.html index f35375c..b2f0168 100644 --- a/layouts/partials/copyright.html +++ b/layouts/partials/copyright.html @@ -1,7 +1,7 @@ {{ if and (isset .Site.Params "cc") (in (slice "post" "posts") .Type) }}
diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html index 4ca0311..f8567d7 100644 --- a/layouts/partials/footer.html +++ b/layouts/partials/footer.html @@ -1,6 +1,6 @@