Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

Banner View and Click tracking in Mobile App

Avatar

Avatar
Ignite 1
Level 1
SR3
Level 1

Likes

0 likes

Total Posts

4 posts

Correct Reply

0 solutions
Top badges earned
Ignite 1
View profile

Avatar
Ignite 1
Level 1
SR3
Level 1

Likes

0 likes

Total Posts

4 posts

Correct Reply

0 solutions
Top badges earned
Ignite 1
View profile
SR3
Level 1

04-12-2017

Hi There! we have an Activity running on Mobile App where we have the below code to track Banner views and Clicks. Unfortunately this isn't working. Would you where we are going wrong?

Offer Code

function displayoffer(mainText,redirectID,btnText,deepKey) {

var headText = mainText;

var btn = btnText;

$('#myaccounts-bottom-slider').prepend('<div id="App_Demo1" class="POCDemo1_offer_innerDisplayDiv ${campaign.recipe.name}" style="display: inline-block;"><p class="POCDemo1_offer_Bold">'+

headText+'</p><div id="button" class="POCDemo1_offer-button">'+'<a id="Demo1CTA" type="button">'+btn+'</a></div></div>');

var action = "account overview DemoPOC2 Rec B bannerView";

cData.put("cd.pageName","App:POC2:BannerView");          //Got this Syntax from offshore SC team

trackAction(action, cData);

var learnMore = document.getElementById("Demo1CTA");

    learnMore.addEventListener("click", function() {

var action1 = "account overview QPOC2 Rec B bannerClick";

cData.put("cd.campaign_code","123456"); 

cData.put("cd.pageName","App:POC2:BannerClick");    

trackAction(action1, cData);

var target = {};

target.key=deepKey;

setTimeout(function(){$(window).trigger('deep_link', target)},100);

document.getElementById('App_Demo1').style.display = "none";

return;

Replies

Avatar

Avatar
Validate 250
Employee
Amelia_Waliany
Employee

Likes

190 likes

Total Posts

449 posts

Correct Reply

73 solutions
Top badges earned
Validate 250
Validate 100
Validate 50
Validate 25
Validate 10
View profile

Avatar
Validate 250
Employee
Amelia_Waliany
Employee

Likes

190 likes

Total Posts

449 posts

Correct Reply

73 solutions
Top badges earned
Validate 250
Validate 100
Validate 50
Validate 25
Validate 10
View profile
Amelia_Waliany
Employee

06-12-2017

Hi there, thanks for your question! This article on Target for Mobile Apps in the Target Help Documentation may be helpful here. Good luck!

Avatar

Avatar
Validate 1
Level 1
vinodh_dinakar1
Level 1

Likes

0 likes

Total Posts

5 posts

Correct Reply

0 solutions
Top badges earned
Validate 1
View profile

Avatar
Validate 1
Level 1
vinodh_dinakar1
Level 1

Likes

0 likes

Total Posts

5 posts

Correct Reply

0 solutions
Top badges earned
Validate 1
View profile
vinodh_dinakar1
Level 1

08-12-2017

Amelia,

Let me give you a background of the issue;

I have a mobile app (android/ios) that has analytics SDK implemented in it. It uses context data variables to send data to SC. I am running an experiment via Adobe Targetn on the app. Now, my requirement is this:

When the banner loads on the mobile app, I want to trigger an analytics calls i.e. trackAction or trackState that says something like pagename = "banner_seen"

when the user clicks on the banner, I want to trigger an analytics calls i.e. trackAction or trackState that says something like pagename = "banner_clicked"

How can i do this? from the offer code of my experiment, I cannot trigger a trackAction or trackState. So, how can i pass the values like "banner_seen" or "banner_clicked" over to SC?