アナリティクスコード場所と設定方法プラグインとコクーン

ブログ

テーマ変えてからアナリティクスが動いてない気がするんだけど・・・どうしよ

テーマに直接コードを入れていたのかも。
もう一度設定しなおす必要があるよ。

えー💦忘れちゃっているし大変そう。

大丈夫!

アナリティクスコードの確認

まずは、アナリティクスコードの確認をしないとね。
場所は、覚えてる?

うーんと・・・

オッケー復習もかねて手順を伝えるね。

おねがいします!

アナリティクスにログインしたら以下の順で操作してね。

画面左下の歯車マーク[管理]をクリック。

次にプロパティ設定項目の[<>トラッキング情報]をクリック。

そしたら、詳細項目が表示されるから[トラッキングコード]をクリック。
すると、グローバルサイトタグが表示されるから全部(<!– Global s~cript>)コピーしてね。

コピーしたよ。

んじゃ、コピーした内容をあなたのサイトの各ページの <head> タグの直後に貼り付けるよ。

えっ!?各ページ?<head>タグ?
もっと簡単な方法ない?

オッケー♪
プラグインとテーマによる設定方法を説明するね。

プラグイン All inOne SEO での設定

All in One SEOというプラグインを使用する方法から説明するね。
プラグインはインストール済であることが前提よ。

All in One SEOをクリック。
GoogleアナリティクスID欄にグローバルサイトタグに記載されている『UA-xxxxxxxx-x』のコードを入力して[設定を更新]をクリックすれば完了よ。

できたー♪
ありがとう♪

テーマでの設定

そういえば、あなた、ワードプレスにテーマは何をしようしているの?

なんだろ?ハチみたいなやつ

きっと、Cocoon(コクーン)ね?

あっ!それだ、コクーン!

それなら、簡単よ。
ついでだから、そっちもやってみましょう。

はーい!

以下の順で操作してね。
[Cocoon設定]-[アクセス解析・認証]-[Google Analytics トラッキング]欄に『UA-xxxxxxxx-x』のコードを入力。
[変更をまとめて保存]をクリックして完了よ。

こっちも簡単だね。よかった!ありがとう♪

おつかれさま。

コメント

タイトルとURLをコピーしました

Fatal error: Uncaught Error: Call to undefined function Smush\Core\Parser\str_contains() in /home/planetx01/earthweblog.com/public_html/wp-content/plugins/wp-smushit/core/parser/class-parser.php:373 Stack trace: #0 /home/planetx01/earthweblog.com/public_html/wp-content/plugins/wp-smushit/core/parser/class-parser.php(358): Smush\Core\Parser\Parser->sanitize_value('property') #1 /home/planetx01/earthweblog.com/public_html/wp-content/plugins/wp-smushit/core/parser/class-parser.php(157): Smush\Core\Parser\Parser->is_safe('property') #2 /home/planetx01/earthweblog.com/public_html/wp-content/plugins/wp-smushit/core/parser/class-parser.php(120): Smush\Core\Parser\Parser->get_element_attributes('<meta property=...', 'https://earthwe...') #3 /home/planetx01/earthweblog.com/public_html/wp-content/plugins/wp-smushit/core/parser/class-page-parser.php(35): Smush\Core\Parser\Parser->get_elements_with_image_attributes('<!doctype html>...', 'https://earthwe...') #4 /home/planetx01/earthweblog.com/public_html/wp-content/plugins/wp-smushit in /home/planetx01/earthweblog.com/public_html/wp-content/plugins/wp-smushit/core/parser/class-parser.php on line 373