Àlẹmọ Subdomains ni Awọn atupale Google

ga

Pẹlu sọfitiwia bi awọn olutaja iṣẹ (SaaS) bii Iṣiro, o ṣe aṣoju subdomain kan ati gbalejo bulọọgi rẹ lori subdomain ti o yatọ ju oju opo wẹẹbu rẹ lọ. Ni gbogbogbo, eyi ni a pari pẹlu blog.domain.com ati www.domain.com. Ni gbogbogbo awọn ile-iṣẹ ṣe imuse iwe ọtọtọ lapapọ ni Awọn atupale Google lati ṣe atẹle subdomain bulọọgi. Kosi ṣe pataki.

Awọn atupale Google yoo gba ọ laaye lati ṣe atẹle ọpọlọpọ awọn subdomains laarin profaili kan. Lati ṣe eyi, o kan fi ila koodu kan kun si iwe afọwọkọ Google Analytics rẹ lọwọlọwọ:

Iwe afọwọkọ Atupale Google Tuntun

	var _gaq = _gaq || [];
	_gaq.push(['_setAccount', 'UA-XXXXXX-XX']);
    _gaq.push (['_ setDomainName', 'example.com']);
	_gaq.push (['_ trackPageview']); _gaq.push (['_ trackPageLoadTime']); (iṣẹ () {var ga = document.createElement ('afọwọkọ'); ga.type = 'ọrọ / javascript'; ga.async = otitọ; ga.src = ('https:' == document.location.protocol? 'https: // ssl': 'http: // www') + '.google-analytics.com / ga.js'; var s = document.getElementsByTagName ('afọwọkọ') [0]; s.parentNode.insertBefore (ga, s);}) ();

Iwe afọwọkọ Google Analytics

 try {
var pageTracker = _gat._getTracker("UA-XXXXXX-XX");
pageTracker._setDomainName (". example.com");
pageTracker._trackPageview (); } mu (aṣiṣe) {}

O ko ti pari sibẹsibẹ! Ti o ba ṣe eyi ni irọrun, o ṣiṣe ọrọ ti awọn ọna kanna ti wọn wọn labẹ URl kan ni Google. Nitorinaa - ti o ba ni index.php lori bulọọgi rẹ ati awọn subdomains www, wọn yoo wọnwọn bi index.php. Iyẹn ko dara. Bi abajade, o ni lati ṣe iyọrisi ilọsiwaju ti o wuyi ninu akọọlẹ naa!

Wọle si Awọn atupale Google ki o tẹ Ṣatunkọ lori profaili Google rẹ. Yi lọ si isalẹ oju-iwe nibiti o le ṣafikun àlẹmọ ki o ṣafikun àlẹmọ ilọsiwaju pẹlu awọn eto wọnyi:
Ayẹwo To ti ni ilọsiwaju fun Awọn iwe-ikawe ni Awọn atupale Google

Bayi profaili rẹ yẹ ki o ṣe iyatọ subdomain jakejado gbogbo Apamọ Itupalẹ.

13 Comments

  1. 1
  2. 2
  3. 3

    Apakan “lẹẹmọ koodu naa” lori Awọn atupale Google ni bayi ni awọn igbesẹ meji:

    1. Kini o n tọpa?
    Agbegbe ẹyọkan (aiyipada)
    -ašẹ: marketingtechblog.com

    Ọkan-ašẹ pẹlu ọpọ subdomains
    apere:
    http://www.marketingtechblog.com
    apps.marketingtechblog.com
    store.marketingtechblog.com

    Awọn ibugbe oke-ipele pupọ

    ati lẹhinna apoti ayẹwo fun Titọpa Adwords

    Eyi ni ọkan fun ọ: kilode ti aṣawakiri safari mi fun PC n ṣafihan awọn ẹya google ti ko si ṣugbọn ko fun mi ni aṣayan lati ṣayẹwo Awọn imudojuiwọn (awọn imudojuiwọn aaye awujọ) ati bii?

  4. 4
  5. 5
  6. 7
  7. 8

    Hi Doug,

    Mo ṣafikun iwe afọwọkọ ti o wa loke ṣugbọn ko dabi pe o n ṣiṣẹ. Eyikeyi ohun ti mo fi yọ ti o mọ? 

    Yoo ṣe iranlọwọ pupọ ti o ba le mu mi siwaju lori eyi. 

    O ṣeun ati Kabiyesi,
    Nishanth T

    • 9

      Nkan meji, @google-1f23c56cd05959c64c268d8e9c84162e:disqus. Ni akọkọ (ati kedere julọ) ni lati rii daju pe koodu UA rẹ ti ṣeto daradara. Mo korira lati kọ iyẹn, ṣugbọn nigbami a daakọ ati lẹẹmọ ati gbagbe. Keji… yoo gba ọpọlọpọ awọn wakati lati mu nitootọ. Fun ni ọjọ kan lẹhinna wo!

      • 10

        Hey @douglaskarr: disqus - O ṣeun pupọ fun esi naa. O ṣeun pupọ- koodu UA ti ṣeto ni pipe. Tun ṣayẹwo lẹẹkansi. Mo ti n tọpa rẹ pẹlu koodu yii fun oṣu kan ni bayi. Awọn microsites/awọn aaye-ibugbe ko han ni GA. 

        Idunnu ...

  8. 11

    O ṣeun! Iranlọwọ pupọ. Mo ni koodu kanna ti n ṣiṣẹ ni awọn agbegbe oriṣiriṣi, ti o da lori boya http tabi https lo (julọ julọ lati pin awọn kuki sọtọ, nitori Mo tun ni tọkọtaya ti awọn idii ipari-ipari meji ti o yatọ & Mo fẹ lati yago fun awọn akọọlẹ aṣa-tun), ṣugbọn javascript. ayipada wà lẹwa kekere.

  9. 12

    Hey o ṣeun fun ikẹkọ yii o ṣe iranlọwọ pupọ! Nitorinaa ni kete ti Mo ṣafikun koodu naa si gbogbo awọn ibugbe iha mi jẹ awọn iṣiro ti awọn atupale fihan lilọ lati ni ijabọ lati awọn subdimains mi?

  10. 13

Kini o le ro?

Aaye yii nlo Akismet lati dinku apamọ. Mọ bi a ṣe n ṣalaye data rẹ ti o ṣawari.