E hoʻopaʻa i ka Mailto Clicks i nā hanana Google Analytics me ka hoʻohana ʻana iā Google Tag Manager

Google Tag Manager Google Analytics Event for Tracking Phone Number Clicks in a Anchor Tag

Ke hana pū nei mākou me nā mea kūʻai aku ma ka hōʻike ʻana, pono mākou e hoʻonohonoho i kahi moʻokāki Google Tag Manager no lākou. ʻAʻole ʻo Google Tag Manager wale nō kahi kahua e hoʻouka ai i nā palapala a pau o kāu pūnaewele, he mea hana ikaika nō hoʻi ia e hoʻoponopono i kahi a me ka wā āu e makemake ai e hoʻomaka i nā hana i loko o kāu pūnaewele me ka hoʻohana ʻana i nā palapala āu i hoʻokomo ai.

ʻO ka hāʻawi ʻana i kahi leka uila i nānā ʻia ma waho ma kāu pūnaewele he ala maikaʻi loa ia e maʻalahi ai ka malihini e hoʻolei i kāu hui kūʻai i leka uila. Eia ke ʻano o kēlā hōʻailona heleuma HTML:

<a href="mailto:info@highbridgeconsultants.com">info@highbridgeconsultants.com</a>

Hāʻawi nā Google Analytics Events i ka manawa e ana hanana i loko o kahi pūnaewele. Pono nā hanana no ke ana ʻana i ka launa pū ʻana e like me ke kaomi ʻana i nā kelepona i ka hana, hoʻomaka a hoʻōki i nā wikiō, a me nā pilina ʻē aʻe i loko o kahi pūnaewele e neʻe ʻole ai ka mea hoʻohana mai kekahi ʻaoʻao i kekahi. ʻO ia ke ala kūpono e ana i kēia ʻano pili. No ka hana ʻana pēlā, hiki iā mākou ke hoʻololi i ke code i luna a hoʻohui i kahi hanana JavaScript onClick e hoʻohui i ka hanana:

<a href="mailto:info@highbridgeconsultants.com" onclick="gtag('event', 'click', { event_category: 'Mailto Link', event_action: 'Email Click', event_label:'https://highbridgeconsultants.com/contact/'})">info@highbridgeconsultants.com</a>

E hoʻomaopopo he hoihoi nō mākou i ka ʻaoʻao i kaomi ʻia mai ka leka uila. He mea kōkua ka ʻike ʻana i nā ʻaoʻao e hoʻoikaika nui nei i ka hoʻopili ʻana ma o ka leka uila.

Aia kekahi mau pilikia me kēia. ʻO ka mea mua, ʻaʻole hiki iā ʻoe ke hoʻohui i ke code onclick i loko o nā kahua o ka ʻōnaehana hoʻokele maʻiʻo o kāu pūnaewele (CMS). ʻO ka lua, pono e pololei ka syntax no laila he nui nā manawa e hewa ai. ʻO ke kolu, pono ʻoe e hana i nā wahi āpau i loaʻa kahi leka uila ma kāu pūnaewele.

Ka hoʻokolo ʻana i nā hanana ma Google Tag Manager

ʻO ka hoʻonā ka hoʻohana ʻana i nā mana holomua o Mea Kūkākūkā Google Tag. Ke hoʻokō ʻia nei ʻo Google Tag Manager ma kāu pūnaewele, ʻaʻole pono ʻoe e hoʻopā i kāu ʻike a i ʻole code e hoʻokau i ka nānā ʻana i nā hanana e like me kēia. ʻO nā ʻanuʻu e hana ai penei:

  • kāhea - E hoʻonohonoho i kahi hoʻomaka e hoʻokō ʻia ke kaomi ʻana o kahi malihini kipa ma kahi loulou leka uila (mailto).
  • Tag - E hoʻonohonoho i kahi hōʻailona hanana i hana ʻia i kēlā me kēia manawa e hoʻokō ʻia ai ke kumu.

NĀ MEA: ʻO kahi koi mua o kēia, ʻo ia ka loaʻa ʻana o kahi Google Analytics Universal Analytics Tag i hoʻonohonoho ʻia a paʻa pono i kāu pūnaewele.

Mahele 1: E hoʻonohonoho i kāu Kiʻi Kipi

  1. I loko o kāu moʻokāki Google Tag Manager, hoʻokele i ʻO Triggers ma ka ʻaoʻao hema a kaomi New
  2. E inoa i kāu Trigger. Ua kāhea mākou i kā mākou Mailto Kaomi
  3. Kaomi ma ka ʻāpana Trigger Configuration a koho i ke ʻano trigger Nā loulou wale nō

Google Tag Manager > Trigger > Kaomi wale

  1. E ho'āla E kali no Tags me ka manawa kali max max o 2000 milliseconds
  2. Hoʻololi E nānā i ka hōʻoia
  3. E ho'ā i kēia hoʻomaka ke a ʻAoʻao URL > pili iā RegEx > .*
  4. E ho'ā i kēia mea ho'āla Kekahi Link Clicks
  5. E hoʻā i kēia mea hoʻokani Kaomi iā URL > loaʻa > mailto:

Google Tag Manager Trigger Configuration mailto nā loulou

  1. Bus Save

Mahele 2: E hoʻonohonoho i kāu hōʻailona hanana

  1. E hoʻololi iā Tags
  2. Bus New
  3. E inoa i kāu Tag, ua kapa mākou i kā mākou Mailto Kaomi
  4. E koho i Google Analytics: ʻIkepili Universal

Google Tag Manager > New Tag > Google Analytics: Universal Analytics

  1. E hoʻonoho i ke ʻano Track i hanana
  2. E hoʻokomo i ke ʻano he enamel
  3. Kaomi i ka + hōʻailona ma Action a koho Kaomi URL
  4. Kaomi i ka + hōʻailona ma Label a koho Ala ʻAoʻao
  5. Waiho i ka Waiwai Blank
  6. Haʻalele i ka pā ʻole me he hoʻopunipuni
  7. E komo i kāu Hoʻololi Google Analytics.
  8. Kaomi i ka ʻāpana Triggering a koho i ka kāhea ua hoʻonohonoho ʻoe ma ka ʻāpana 1.

Google Tag Manager - Google Analytics Event for Mailto Click

  1. Bus Save
  2. E nānā i kāu Tag, hoʻohui i kāu pūnaewele, a kaomi ma kāu pūnaewele e ʻike ua puhi ʻia ka tag. Hiki iā ʻoe ke kaomi i ka tag Email Kaomi a ʻike i nā kikoʻī i hala.

Google tag manager mailto hanana hanana

  1. Ma hope o kou hōʻoia ʻana i ke kī pololei ʻana o kāu tag, hoolaha ka hōʻailona e waiho ola ma kāu pūnaewele

Manaʻo kōkua: ʻAʻole ʻike ʻo Google Analytics i nā hanana i ka manawa maoli no kāu pūnaewele no laila inā ʻoe e hoʻāʻo nei i ka pūnaewele a hoʻi hou i kāu paepae analytics, ʻaʻole paha ʻoe e nānā i ka hanana i hoʻopaʻa ʻia. E nānā hou i loko o kekahi mau hola.

I kēia manawa, me ka nānā ʻole i ka ʻaoʻao o kāu pūnaewele, kēlā me kēia loulou mailto e hoʻopaʻa i kahi hanana ma Google Analytics ke kaomi kekahi i ka loulou leka uila! Hiki iā ʻoe ke hoʻonohonoho i kēlā hanana ma ke ʻano he Pahuhopu ma Google Analytics.

Inā makemake ʻoe e hoʻonohonoho i kēia no nā kaomi helu kelepona, e ʻoluʻolu e heluhelu i kā mākou ʻatikala mua, Track Click to Call Links in Google Analytics Events using Google Tag Manager.