Yes, we know the current page Scroll Depth Tracking is present default while we using plugins, but these values are captured on the next page only. But We are required to implement Scroll Depth Tracking for the current page, if the customer is reached a particular percentage then we need to fire the events and need to capture the element values in eVar. We have single-page applications & more dependency on other teams.
Solved! Go to Solution.
Views
Replies
Total Likes
In Adobe, there is no option to capture the value of the current page scroll depth. However, we can create custom JavaScript code to capture the value for the current page scroll depth.
In Adobe, there is no option to capture the value of the current page scroll depth. However, we can create custom JavaScript code to capture the value for the current page scroll depth.
Yes, now we have developed a custom script to store the current page scroll tracking values. In case if required the scripts, mail us to share the guide.
We have used below the steps to archive the results.
$(window).on("scroll", function(){
var winheight = $(window).height();
var docheight = $(document).height();
var scrollTop = $(window).scrollTop();
------ // Manual codes
});
$(window).on('beforeunload', function (){
if(ScrollVal <= 25){
//Conditions 1
}else if(ScrollVal > 26 && finalScrollVal <= 50){
//Conditions 2
}else if(ScrollVal > 51 && finalScrollVal <= 75){
//Conditions 3
}else if(ScrollVal > 76){
//Conditions 4
}
return;
});
Hi, Where do we have to paste the Code, Can We use to Capture 10%, 20%..also?
Views
Replies
Total Likes
You can paste the code in adobe analytics extension custom code place.
yes, we can use 10%, 20% also, but server call gets increased so use as much minimum numbers.
Views
Replies
Total Likes
How can we implement scroll depth through websdk approach ? Where there is no analytics extension we can't even call s object. We have XDM object available where all variables mapped to schema fields.
Views
Replies
Total Likes