網站分析¶
網站分析可協助網站擁有者監控訪客如何使用其網站。它提供訪客人口統計、行為和互動的資料,有助於改善網站和行銷策略。
您可以使用Plausible.io或Google Analytics(分析)來追蹤您的 Odoo 網站流量。我們建議使用 Plausible.io,因為它重視隱私、輕量且易於使用。
Plausible 分析仪表板也已经整合到 Odoo 中,可通过:menuselection:`网站–>报告–>分析`访问。
Plausible.io¶
Odoo hosts its own Plausible.io server and provides a free and ready-to-work Plausible.io solution for Odoo Online databases. Odoo automatically creates and sets up your account. You can start using it by going to .
備註
如果您已经有一个 Plausible.io 账户,并想将其连接到您的 Odoo 在线数据库,您必须创建两个`ir.config.parameters`来使用 Plausible.io 服务器。要执行此操作,请启用:ref:开发者模式<developer-mode>`并进入:menuselection:`常规设置 --> 技术 -- 系统参数。点击 新建 并填写以下 密钥 和 数值 字段:
鍵 |
值 |
|---|---|
|
|
|
|
接著,依照下列步驟將您現有的帳戶與 Plausible.io 伺服器連線。
如果您的資料庫託管於 Odoo.sh 或**離線安裝**,或者您希望使用自己的 Plausible.io 帳戶,請依照以下步驟進行:
使用以下链接创建或登录 Plausible 账户: https://plausible.io/register。
如果您要创建一个新账户,请执行注册和激活步骤。当要求您提供网站详细信息时,请添加其 域名 而不包括`www`(例如,
example.odoo.com),如有必要,请更改 报告时区。单击 添加代码段 进入下一步。忽略 添加 JavaScript 代码段 说明,单击 开始收集数据。完成后,点击页面左上角的 Plausible 标志,进入 `网站列表<https://plausible.io/sites>`_,然后点击网站旁边的齿轮图标。
在侧边栏中,选择 可见性,然后点击 + 新链接。
输入 名称,密码`字段留空,因为 Odoo中 Plausible 分析仪表盘集成不支持密码,然后点击:guilabel:`创建共享链接。
複製共用連結。
在 Odoo 中,前往。
In the SEO section, enable Plausible Analytics, then paste the Shared Link and click Save.
小訣竅
If you have multiple websites, add your websites to your Plausible.io account by going to https://plausible.io/sites and clicking + Add website. In Odoo, in the Website settings, make sure to select the website in the Settings of Website field before pasting the Shared link.
備註
Odoo 會自動推送兩個自訂目標:Lead Generation 和 Shop。
Google Analytics(分析)¶
若要使用 Google Analytics 追蹤您的 Odoo 網站流量:
使用以下連結建立或登入 Google 帳戶:https://analytics.google.com。
如果您是第一次設定 Google Analytics(分析),請按一下開始評估並完成帳戶建立步驟。
If you already have a Google Analytics account, sign in and click the gear icon in the bottom-left corner of the page to access the Admin page. Then, click + Create Property.
Complete the next steps: property creation, business details, and business objectives.
當您進入 Data collection 步驟時,請選擇Web平台。
Set up your data stream: Specify your Website URL and a Stream name, then click Create stream.
複製評估 ID。
在 Odoo 中,前往。
在SEO區段中,啟用Google Analytics,然後貼上Measurement ID並按一下Save。
小訣竅
If you have multiple websites with separate domains, it is recommended to create one property per domain. In Odoo, in the Website settings, make sure to select the website in the Settings of Website field before pasting the Measurement ID.
Google 代碼管理工具¶
GTM is a tag management system that allows you to easily update measurement codes and related code fragments, collectively known as tags on your website or mobile app, directly through the code injector.
警告
某些 GTM 代碼使用資料層(例如進階電子商務追蹤資料層)來擷取變數並將其傳送至 Google Analytics(分析)。Odoo 目前不管理資料層。
Google 代碼管理工具可能不符合當地的資料保護法規。
To use GTM, proceed as follows:
前往 https://tagmanager.google.com/ 建立或登入 Google 帳戶。
In the Accounts tab, click Create account.
輸入帳戶名稱並選取帳戶的國家/地區。
在容器名稱欄位中輸入您網站的網址,並選取目標平台。
按一下建立並同意服務條款。
Copy the
<head>and<body>codes from the popup window. Then, go to your website, click Edit, go to the Themes tab, scroll down to the Website Settings section, then click <head> and </body> to paste the codes.
備註
資料會收集在用於監控網站的行銷工具中(例如 Google Analytics(分析)、Plausible、Facebook Pixel),而非 Odoo 中。