Highlighted

How do I integrate adobe analytics using javascript?

selvasajin

06-12-2017

I am new to adobe analytics, trying to integrate adobe analytics on my angular1.6 web app using javascript from past 3 days. I had followed the steps from adobe analytics implementation documentation using javascript Implementing Analytics Using JavaScript

Added adobe marketing cloud debugger on chrome and I am able to see the requests, but couldn't able to see anything on my AEM dashboard (page views, visits, ect). I am running the application form localhost. Can anyone help me to resolve this?

Replies

Highlighted

selvasajin

06-12-2017

Guys! any update on this??  May be video links (or) sample codes for implementation using javascript will be helpful, thanks in advance!!

Highlighted

julienp80647070

06-12-2017

Sorry for the basic question, worth asking :
Did you check that your configuration is not excluding the hit from your ip address ?

Highlighted

selvasajin

06-12-2017

Not sure about this. Could you please tell me how to do/check this?? I don't have admin privilege on omniture dashboard but can view the reports like page views, pages ect.

For implementation the admin(client) had shared the AppMeasurement.zip file in which I updated the parameters like RSID,SERVER,MCORG ect.

Reference  https://marketing.adobe.com/resources/help/en_US/sc/implement/js_implementation.html

Highlighted

pabloc82923542

06-12-2017

Coding you need to read the Angularitics for its implementation.

The direct call rules are done in DTM

To check your work use Network tab and look at fired beacons to review your output.

This is not a 5 min and voila you are done. It will take a fair bit of Dev work and testing. You need to be able to work closely with Adobe Admin.

Highlighted

selvasajin

06-12-2017

Thanks Pabloc. Will try this, but without MCORG-ID, RSID, Tracking server how it will send data/request to adobe analytics? because there is no option to include these parameters in the source code.

Highlighted

pabloc82923542

06-12-2017

RSID can be found by looking at console output of any page presently using the same code. MCORG-ID not sure what you mean...

Were you not provided with:

Header and footer codes?

Highlighted

btripple

06-12-2017

The adobe Administrator for your company should provide the specific library settings for you.

There are two primary functions that will send data to Adobe:

s.t()

s.tl()

You may fire those depending on the situation, see these topics in the documentation:

The s.t() Function - Page Tracking

The s.tl() Function - Link Tracking

Highlighted

selvasajin

07-12-2017

Hi Pabloc,

There are two ways of implementations 1.DTM and 2.Javascript. I believe Header, Footer codes and DTM are required when we implement analytics using DTM. In my case its Javascript implementation  https://marketing.adobe.com/resources/help/en_US/sc/implement/js_implementation.html

I had included the path for AppMeasurement and VisitorAPI in my index.html

  <script language="JavaScript" type="text/javascript" src="assets/src/VisitorAPI.js"></script>

  <script language="JavaScript" type="text/javascript" src="assets/src/AppMeasurement.js"></script>

Then added the Example page code (https://marketing.adobe.com/resources/help/en_US/sc/implement/appmeasure_mjs_pagecode.html) in the pages that I need to track

<script language="JavaScript" type="text/javascript">

    s.pageName=“s.landingpage”

    s.server="window.location.hostname"

    s.channel="Discover"

    s.pageType=""

    s.prop1=""

    s.prop2=""

    s.prop3=""

    s.prop4=""

    s.prop5=""

    /* Conversion Variables */

    s.campaign=""

    s.state=""

    s.zip=""

    s.events="event1"

    s.products=""

    s.purchaseID=""

    s.eVar1=""

    s.eVar2=""

    s.eVar3=""

    s.eVar4=""

    s.eVar5=""

    var s_code=s.t();if(s_code)document.write(s_code)

</script>