 
	
		
		
		
		
			
- 
		AuthorPosts
- 
		
			
				
January 27, 2019 at 6:40 pm #1059401Hi, i have a Problem with Google Analytics and the gtag / contact form event. I am using the following Analytics Code: 
 <!– Global site tag (gtag.js) – Google Analytics –>
 <script async src=”https://www.googletagmanager.com/gtag/js?id=UA-133307688-1″></script>
 <script>
 window.dataLayer = window.dataLayer || [];
 function gtag(){dataLayer.push(arguments);}
 gtag(‘js’, new Date());gtag(‘config’, ‘UA-133307688-1’, { ‘anonymize_ip’: true }); 
 </script>I am using this in the child functions.php 
 add_filter(‘avf_contact_form_submit_button_attr’,’avia_add_submit_attributes_to_cf’, 10, 3);
 function avia_add_submit_attributes_to_cf($att, $formID, $form_params){
 $gaq = “_gaq.push([‘_trackPageview’, ‘UA-133307688-1’]);”;
 $att = “onclick=\”gtag(‘send’, ‘event’, ‘Submit’, { ‘event_category’ : ‘Contactform’, ‘event_label’ : ‘Form-Submit’, ‘value’: 1 });”;
 return $att;
 }And I am using this Event config. 
 Link: https://ibb.co/Y0sy3rdBut its not working, can you help me? Thanks, Ronald January 29, 2019 at 11:34 pm #1060231Hey ronaldalexander, Unfortunately, it would require quite some time and customization of the theme to achieve this, so I am sorry to tell you that this is not covered by our support. However, if it’s really important for you to get this done, you can always hire a freelancer to do the job for you :) Best regards, 
 BasilisJanuary 30, 2019 at 1:16 pm #1060465I don’t understand why you can’t help me because you helped everybody else. I saw lot’s of topics with people who asked almost for the same and since i used the code in your documentation and its not working, i thing you could help me solve my problem. I think its not the big deal anyway since you write “require quite some time and customization”. Regards, Ronald January 31, 2019 at 10:36 pm #1061276Hi Ronald, Here is a thread for you to consider Best regards, 
 Victoria
- 
		AuthorPosts
- You must be logged in to reply to this topic.
