Google Adwords ASYNC conversion help

Hi All,

I have a adwords conversion setup on a client account, Its been setup for around 4 days now and I have been constantly testing however its still displaying as 'unverified' in the account.

Now I am trying to track a conversion from a form submission which is submitted using ajax. Basically once the form is filled in and click in the ajax success I want to send the conversion.

I include the following script above my ajax function (to clarify) but at the bottom of the page and not in the head (i assume this makes no difference???).;

<script type="text/javascript" src="http://www.googleadservices.com/pagead/conversion_async.js" charset="utf-8"></script>

Open in new window


I then fire the following code in my success call

success: function(data) {
                            if (data) {
                                ga('send', 'event', 'quickFormSubmit', 'click', 'form submitted');

                                /* <![CDATA[ */
                                window.google_trackConversion({
                                    google_conversion_id: XXXXXXXXX,
                                    google_remarketing_only: true
                                });
                                //]]>
                                
                                $('#submitting').slideUp("slow");
                                $('#complete').slideDown("slow");
                            }
                        }

Open in new window


the first part is a analytics conversion which seems to be working ok.

The slideUp and slideDOwn ar efiring and firefox is giving no errors in the console. Also i can see the .js files IS being loaded. Is there anything further I can do to debug it?

Finally, just to advise I installed and ran tag assistant in chrome, but its only picking up the analytics code and not this adword conversion code??

Thanks in advance,

MAtt.
flynnyAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Randy DownsOWNERCommented:
Maybe this will help.

only visitors from AdWords ads will trigger a conversion. So even if you made a transaction yourself the conversion will not trigger unless you entered your own site by clicking on an ad - and clicking on an ad "out there in the wild" and not through your AdWords interface....
0
Lucas BishopClick TrackerCommented:
I would use Developer Tools in Chrome or Firefox to view the headers of the request. Here is a brief overview.
0
flynnyAuthor Commented:
Hi Lucas,

Its not appearing in the google chrome tag assistant though?

I assumed this was because it was an async call? the code is there and not throwing any errors to the console?

Can I chain a promise from the call? or an eror handleR?
0
Why Diversity in Tech Matters

Kesha Williams, certified professional and software developer, explores the imbalance of diversity in the world of technology -- especially when it comes to hiring women. She showcases ways she's making a difference through the Colors of STEM program.

Lucas BishopClick TrackerCommented:
I do believe the tag should show in the Tag Assistant even though it is Async. At the least it should appear upon being fired. I'm more familiar with the debug tool in Google Tag Manager.

You can see a promise example here at the very bottom of the page.

I'd also recommend testing with the javascript in the head of the page, as I believe that's where Google defines its placement should be.
0
flynnyAuthor Commented:
Hi Lucas,

Ok I have added Google Tag Manager tothe site and add a new container to my account for the site.

I added the conversion to the container from my adwrods account (i.e. add the conversion_id and conversion_label).

Incidently the conversion_label is not used in the async code on my site (as per the instructions I have found and the ones you references, only

    google_conversion_id: 123456789, 
    google_remarketing_only: true

Open in new window


are used.  obviously the custom params are not added as i have none.

I then created and published this?

chrome tag assistant is picking up the tag assistant code in the page. Any ideas what I do now to test the conversion?
0
Lucas BishopClick TrackerCommented:
In tag manager, in the top right there is a "preview" button. Click this and then select 'debug'. Now visit your site and you'll have a debug window that gives access to the tags as they fire and you can review the Data Layer to see everything being sent across.
0
flynnyAuthor Commented:
Hi Lucas,

First of all thank hou for your time and help on this.

Ok I select preview and debug. Indeed the debug panel appeared on the site. I then filled the form in which fires the async conversion when the form is successfully submitted. However nothing appears in this debug window? and it is saying there are no tags?

One thing I have not done is add any firing rules in the tag manage window? Do I need to do this?
0
Lucas BishopClick TrackerCommented:
Yeah, you will need to create a firing rule. For now you could just set it up to fire on all pages (very generic rule) for testing.
0
flynnyAuthor Commented:
Lucas,

thanks for that, what is the purpose of the firing rule sorry?

Is this when the rule will fire? or just where it will fire?

Thanks ,

Matt.
0
Lucas BishopClick TrackerCommented:
The firing rule dictates exactly when the tag should fire.

While you're at it, I also recommend taking a look at the GTM Dev Guide here:
https://developers.google.com/tag-manager/devguide
0
flynnyAuthor Commented:
HI Lucas,

Ok, I setup the generic firing rule (i.e. for all pages). Now when I debug I get the following;

Form Conversion
Display Macros as: Names Values
Properties:
Type
	
AdWords Conversion Tracking
ID
	

'my id number'

Label
	

'generated label'

Value
	

''

Firing Rules
All pages
Conditions
	
	
matches RegEx
	
.*
	
	
equals
	
gtm.js
Blocking Rules
No Blocking Rules 

Open in new window


Now this appears when I load the page and not when I complete the form (as i need it too).

Will it help you debug if I provide the URL?

Thanks for the link. I'm not using the dataLayer at the moment? Should I be utilising this all the time?
0
Lucas BishopClick TrackerCommented:
Sorry, just noticed this. Yes, you'll want to use the datalayer.

I mentioned firing it on all pages just to try and run through a quick test to see if it's working. But this was just to see if your script was functioning as expected.

Here is a very comprehensive tutorial on how to set up a form submit listener and when to fire the events that this listener will be waiting for.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
flynnyAuthor Commented:
thanks sorry for the delay,
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
AJAX

From novice to tech pro — start learning today.