Passing gclid to _trackEvent - google-analytics

I am using _trackEvent to record events in Google Analytics, and it appears to work fine.
I am doing something like this:
_gaq_push(['_trackEvent', 'Chat', 'Male',
'www.somesite.co.uk/?gclid=CNHvuPiijrUCFQsGnQodpjsA9w']);
Now, I see the URL and gclid appear in the label field in Google Analytics, however what I really want to happen is for it to interpret the gclid and populate the keywords section in GA.
Is this possible? How do I achieve it?

I am not sure what you are trying to achieve here but gclid is something that is not publicly documented. If you really want to fill in the campaign information, you should try and use the APIs described here or do something like this.

Link your adwords account to your google analytics account and the gclid will be resolved automatically. Manually resolving the gclid ist not possible.
Update: Sorry, I've only just seen that you are talking about events. So no, that is not possible - the proper way is to build segments with your keywords and to see which events apply to that segment (or the other way around, depending on what you are doing).

Related

Do UTM properties in URL work without gtag.js?

Maybe it's a silly question but couldn't find an answer for it other than for the opposite question.
If I have my website already connected with Google Analytics, do I still need to add gtag.js in order for UTM properties in an URL to be tracked?
I'm not really sure how would Google be able to track it otherwise.
You have to add the Google Analytics snippet in all pages. So, in this case if UTM parameter are in the URL it will be tracked automatically.

Custom Report in Google Analytics

I am new to Google Analytics.I want to create custom report which should look like this What will be my custom metrics and custom dimensions and what changes i need to do in my tracking code to generate such kind of report.
I second faridghar answer. However, to get a straight response to your question I will suggest creating a custom report and using other tools to accomplish what you want to achieve. Simply follow this youtube video steps. It will explain everything except the email ID issue, you can still follow their instructions to implement a similar solution as they did with the user's names.
It is forbidden to collect personally identifiable information (PII) in Google Analytics. In your example, "Client Name", "Email ID" and "Address" are all PII. Therefore, while it may be technically possible to achieve this, you would be violating Google Analytics policy. More info here.
One way around this would be to hash the data before you send it to GA. This would only really make sense for the email field as your other fields are probably not unique.

Set a tag to track links from a visual basic app in google analytics

I hope I can explain myself.
See. I have this little program where I put a link to my site, what I want to know if there's some way to add a tag into the URL so Google Analytics can count the amount of visitors coming from that program.
Like when you parse the GET in php.
something like http:\\www.stackoverflow.com\?something_to_google_analytics_to_read
If this is possible, I assume that I need also to configure that Tag into Analytic's, or?
Thanks
As #SLaks pointed, I can find a step by step guide for create what I wanted in:
https://support.google.com/analytics/answer/1033867?ref_topic=1032998
It is called Campaigns.
Thanks

Google Analytics scope question

I'm studying GA and and want to know if it is possible to save any custom information. For example I have a lot of checkboxes on the page and want to know checked statistics. I mean checks count for each checkbox separately. I see it in the following way: before postback I'm getting all checks information and send it to GA :).
What do you think?
You can use the Google Analytics javascript API to send this information to google, possibly as an event. This can happen whenever you choose, such as before form submission.
You can make events to each of the checkboxes, individualize them if you want, and see the results in "event tracking" in contents.
More info about event tracking from
google analytics docs

Add Analytics to account of someone other than the one who set it up?

I have been requested to get involved with a family member's site.
To date, they have been paying an SEO outfit, which I believe has been feeding them lies and milking them for money.
I can see that all pages in the site have Google Analytics. However, the SEO outfit refuses to let us see the Analytics page, and has always just forwarded them some (presumably doctored) slideshows.
The only tracking service that lists their site is Compete, which shows a number of visitors far from what they are paying for.
I would like to add their site to my own Analytics account. I have ftp access to their server, and permission from the site owners to modify any files I want.
However, I don't want to do anything that might destroy the entire existing history of analytics data, or even that would interfere with the current SEO outfit [until I have something concrete in-hand].
Does anyone know:
Can I add Analytics to my own account when it was originally setup by someone else?
Will there be any negative results of attempting this?
Any other ideas?
Thanks
Edit: Can anyone suggest a better title - I can tell mine is not good?
I've put two Google Analytics tracking codes from different accounts on the same site without issues. It may cause the site to be a tiny bit slower (as it communicates twice with Google) but it'll do nothing that would delete old data or impede collection of new data.
In short, what you're doing sounds like a good first step.
You will not, however, be able to access past data by doing this. You will be able to compare their numbers with the numbers you're getting, though, which should be valuable.
I don't know if you can add the same domain to two different Google Analytics accounts (easy enough to try, though), but you can always add another service's Javascript snippet, e.g. Woopra. Google and Woopra produced very similiar results in my experiments.
You may want to leave their Google Analytics tracking in place while adding your own Google Analytics tracking. In that case, your numbers should be identical to whatever is being tracked by this third party.
You'll need to set up your own account and then add in the creation of your pagetracker object and your own track page view. You don't need to recreate the entire page code. You can do it with two more lines. It would look something like:
var pageTracker =
_gat.getTracker("UA-XXXXXXXX-1"); //EXISTING pageTracker._trackPageView();
var secondTracker =
_gat.getTracker("UA-XXXXXXXX-1"); //YOUR TRACKING ACCOUNT secondTracker._trackPageView();

Resources