Google Analytics trackPageview function with question id or question number

More
5 years 3 weeks ago #82808 by autopoiesis
autopoiesis created the topic: Google Analytics trackPageview function with question id or question number
When I activate the "Track pages within survey" function in the survey settings, I can only see different pageviews for the survey groups but not for the single question pages in the GA content report. Is it possible to modify the code in replacements.php in a way that I can see the single question id or number in the content report?
$_trackURL = htmlentities($thissurvey['name'] . '-[' . $surveyid . ']/[' . $gseq . ']-' . $_groupname, ENT_QUOTES);

It is important for me to define different goals within the survey - so I need real single pageviews.

Please Log in to join the conversation.

More
5 years 3 weeks ago #82813 by TMSWhite
TMSWhite replied the topic: Google Analytics trackPageview function with question id or question number
We anticipated that users might want different ways of using GA, so it is pretty easy to extend.

Are you using question-by-question mode? GA is currently configured for group-by-group mode.

If you're comfortable with the code and GitHub, the easiest way is to fork LimeSurvey, add a new 'googleanalyticsstyle', and try some combinations $_trackURL until you're happy with the results. Then you can issue a pull request and we can review it for possible inclusion in the base code.

I found I had to go through some trial and error in building the current GA support before it met my needs, so I recommend playing with it yourself.

Please Log in to join the conversation.

More
5 years 3 weeks ago #82826 by Mazi
Mazi replied the topic: Google Analytics trackPageview function with question id or question number
Tom, I couldn't find this additional information about how the GA feature works at the wiki. If I didn't over-read it, can you please ad it?!

Thanks!


Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)survey-consulting.com'"

Please Log in to join the conversation.

More
4 years 7 months ago #89898 by autopoiesis
autopoiesis replied the topic: Aw: Re: Google Analytics trackPageview function with question id or question num
I solved my problem with the standard group-by-group modus: I just created some extra question groups for my different goals.

Please Log in to join the conversation.

Did you already participate in our customer survey?

Don't miss your chance for great prices.

Please click here to participate:

Start now

Start now!

Just create your account and start using Limesurvey today.

Register now