Use Generic Analytic Snippets for author | Community
Skip to main content
This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by kautuk_sahni

Have a look at this documentation :- https://docs.adobe.com/docs/en/aem/6-2/administer/integration/external-providers.html

// It talks about Analytics with External Providers in AEM.

    All you need to do is to create Creating a new Cloud Services Configurations with a Generic Snippet

Check the documentation, it covers everything.

~kautuk

4 replies

kautuk_sahni
Community Manager
kautuk_sahniCommunity ManagerAccepted solution
Community Manager
April 7, 2017

Have a look at this documentation :- https://docs.adobe.com/docs/en/aem/6-2/administer/integration/external-providers.html

// It talks about Analytics with External Providers in AEM.

    All you need to do is to create Creating a new Cloud Services Configurations with a Generic Snippet

Check the documentation, it covers everything.

~kautuk

Kautuk Sahni
vjetty
Level 4
April 7, 2017

Hi, Bhanu

I think you are looking for this. 

http://help-forums.adobe.com/content/adobeforums/en/experience-manager-forum/adobe-experience-manager.topic.html/forum__8t1h-hi_masters_anybo.html

And, there is also another work around for this, just get your GTM library and place that inside the <head> section of your page. 

The example snippet looks like this,

<!-- Google Tag Manager --> <script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start': new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0], j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src= 'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f); })(window,document,'script','dataLayer','GTM-XXXX');</script> <!-- End Google Tag Manager -->

There might be <noscript> version of library as well for the browsers with JavaScript disabled. You can place that snippet right after the start of <body> tag of your page. 

<!-- Google Tag Manager (noscript) --> <noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-XXXX" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript> <!-- End Google Tag Manager (noscript) -->

Also, you can use different versions based on runmode for your non-prod and production by checking ${runMode == 'prod'} or ${runMode != 'prod'}.

Hope this helps.

Thanks,

Vamsi

vjetty
Level 4
April 11, 2017

Hi Bhanu

Any luck with this? 

bhanu_sabbella
April 11, 2017

Hi Vamsi,

My requirement is actually not associated with a page may be a jsp. Requirement is to generate a report of all the keywords that are searched in the "Asset Search" (Assets-> Select a path and "Enter Keyword" and other filters if required).  I tried DTM but it requires Adobe Analytics access. Checking if there is any other way.

PFA.