[Dspace-devel] [DuraSpace JIRA] (DS-1190) Add Google Analytics tracking code to header-default.jsp

0 views
Skip to first unread message

Robin Taylor (DuraSpace JIRA)

unread,
Aug 20, 2015, 11:37:42 AM8/20/15
to dspace...@lists.sourceforge.net
Robin Taylor created DS-1190:
--------------------------------

Summary: Add Google Analytics tracking code to header-default.jsp
Key: DS-1190
URL: https://jira.duraspace.org/browse/DS-1190
Project: DSpace
Issue Type: Improvement
Components: JSPUI
Reporter: Robin Taylor
Assignee: Robin Taylor
Fix For: 3.0


Allow the user to turn on GA tracking by configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.duraspace.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira



Denys Slipetskyy (DuraSpace JIRA)

unread,
Aug 20, 2015, 11:37:50 AM8/20/15
to dspace...@lists.sourceforge.net

[ https://jira.duraspace.org/browse/DS-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=25076#comment-25076 ]

Denys Slipetskyy commented on DS-1190:
--------------------------------------

I have added such feature to my institutional repository.

1) Created ga.jspf file with pasted tracking code for GA account
2) added extra parameter to dspace.config (in version 1.7), so it can be turned on/off
3) added include of that jspf to header-default.jsp with check of configuration parameter

Additionally, I had to make small modification to ItemTag.java to track Download/View actions (because part of HTML markup is there and you need to put JS event handler). Also I added extra parameter to config file for labeling the action in GA.

All modifications I've done for 1.7 branch, should not be hard to implement the same for 1.8.
I can provide necessary pieces of code, but will not be able to test them on 1.8 in near future.

> Add Google Analytics tracking code to header-default.jsp
> --------------------------------------------------------

Ivan Masár (DuraSpace JIRA)

unread,
Aug 20, 2015, 11:37:53 AM8/20/15
to dspace...@lists.sourceforge.net

[ https://jira.duraspace.org/browse/DS-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=25078#comment-25078 ]

Ivan Masár commented on DS-1190:
--------------------------------

Please, send the patch either here or via GitHub. Thanks.

> Add Google Analytics tracking code to header-default.jsp
> --------------------------------------------------------

Denys Slipetskyy (DuraSpace JIRA)

unread,
Aug 20, 2015, 11:37:55 AM8/20/15
to dspace...@lists.sourceforge.net

[ https://jira.duraspace.org/browse/DS-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=25079#comment-25079 ]

Denys Slipetskyy commented on DS-1190:
--------------------------------------

OK. Should I open pull request on Github ? Or I'll put files an description here.

> Add Google Analytics tracking code to header-default.jsp
> --------------------------------------------------------

Ivan Masár (DuraSpace JIRA)

unread,
Aug 20, 2015, 11:37:56 AM8/20/15
to dspace...@lists.sourceforge.net

[ https://jira.duraspace.org/browse/DS-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=25080#comment-25080 ]

Ivan Masár commented on DS-1190:
--------------------------------

Whichever works for you. GitHub pull request is better (also include a link to the pull request here).

> Add Google Analytics tracking code to header-default.jsp
> --------------------------------------------------------

Denys Slipetskyy (DuraSpace JIRA)

unread,
Aug 20, 2015, 11:38:46 AM8/20/15
to dspace...@lists.sourceforge.net

[ https://jira.duraspace.org/browse/DS-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=25191#comment-25191 ]

Denys Slipetskyy commented on DS-1190:
--------------------------------------

here is the link to pull request https://github.com/DSpace/DSpace/pull/27
I did it for JSP UI only, don't know how to do it for XML UI.


> Add Google Analytics tracking code to header-default.jsp
> --------------------------------------------------------

Robin Taylor (DuraSpace JIRA)

unread,
Aug 20, 2015, 12:02:29 PM8/20/15
to dspace...@lists.sourceforge.net

[ https://jira.duraspace.org/browse/DS-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=25315#comment-25315 ]

Robin Taylor commented on DS-1190:
----------------------------------

Hi Denys and Ivan, just wanted to say thanks for doing all the real work, it sounds just like what is needed. Cheers.


> Add Google Analytics tracking code to header-default.jsp
> --------------------------------------------------------

Ivan Masár (DuraSpace JIRA)

unread,
Aug 20, 2015, 12:02:30 PM8/20/15
to dspace...@lists.sourceforge.net

[ https://jira.duraspace.org/browse/DS-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ivan Masár reassigned DS-1190:
------------------------------

Assignee: Ivan Masár (was: Robin Taylor)

OK Robin, I'll assign the ticket to myself and take care of it. Thanks for checking up.

> Add Google Analytics tracking code to header-default.jsp
> --------------------------------------------------------
>
> Key: DS-1190
> URL: https://jira.duraspace.org/browse/DS-1190
> Project: DSpace
> Issue Type: Improvement
> Components: JSPUI
> Reporter: Robin Taylor
> Assignee: Ivan Masár

Ivan Masár (DuraSpace JIRA)

unread,
Aug 20, 2015, 12:02:32 PM8/20/15
to dspace...@lists.sourceforge.net

[ https://jira.duraspace.org/browse/DS-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ivan Masár updated DS-1190:
---------------------------

Status: Open (was: Received)

> Add Google Analytics tracking code to header-default.jsp
> --------------------------------------------------------
>
> Key: DS-1190
> URL: https://jira.duraspace.org/browse/DS-1190
> Project: DSpace
> Issue Type: Improvement
> Components: JSPUI
> Reporter: Robin Taylor
> Assignee: Ivan Masár

Denys Slipetskyy (DuraSpace JIRA)

unread,
Aug 20, 2015, 12:02:37 PM8/20/15
to dspace...@lists.sourceforge.net

[ https://jira.duraspace.org/browse/DS-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=25331#comment-25331 ]

Denys Slipetskyy commented on DS-1190:
--------------------------------------

Sorry, I couldn't finish this issue as we discussed in pull request thread. I can't promise to do it before my business trip will end in two weeks.
I can finish it then, if it still be relevant.

> Add Google Analytics tracking code to header-default.jsp
> --------------------------------------------------------
>
> Key: DS-1190
> URL: https://jira.duraspace.org/browse/DS-1190
> Project: DSpace
> Issue Type: Improvement
> Components: JSPUI
> Reporter: Robin Taylor
> Assignee: Ivan Masár

Ivan Masár (DuraSpace JIRA)

unread,
Aug 20, 2015, 12:02:49 PM8/20/15
to dspace...@lists.sourceforge.net

[ https://jira.duraspace.org/browse/DS-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=25336#comment-25336 ]

Ivan Masár commented on DS-1190:
--------------------------------

Sure, Denys, no problem. Freeze isn't upon us until mid-August.

> Add Google Analytics tracking code to header-default.jsp
> --------------------------------------------------------
>
> Key: DS-1190
> URL: https://jira.duraspace.org/browse/DS-1190
> Project: DSpace
> Issue Type: Improvement
> Components: JSPUI
> Reporter: Robin Taylor
> Assignee: Ivan Masár

Robin Taylor (DuraSpace JIRA)

unread,
Aug 20, 2015, 12:07:12 PM8/20/15
to dspace...@lists.sourceforge.net

[ https://jira.duraspace.org/browse/DS-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Robin Taylor reassigned DS-1190:
--------------------------------

Assignee: Robin Taylor (was: Ivan Masár)

> Add Google Analytics tracking code to header-default.jsp
> --------------------------------------------------------

Robin Taylor (DuraSpace JIRA)

unread,
Aug 20, 2015, 12:07:13 PM8/20/15
to dspace...@lists.sourceforge.net

[ https://jira.duraspace.org/browse/DS-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Robin Taylor resolved DS-1190.
------------------------------

Resolution: Fixed

Hi all, I hope you don't mind but given the impending feature freeze I created a another pull request and merged it. Many thanks for the code and discussion. Cheers, Robin.

> Add Google Analytics tracking code to header-default.jsp
> --------------------------------------------------------

Ivan Masár (DuraSpace JIRA)

unread,
Aug 20, 2015, 12:07:14 PM8/20/15
to dspace...@lists.sourceforge.net

[ https://jira.duraspace.org/browse/DS-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=25614#comment-25614 ]

Ivan Masár commented on DS-1190:
--------------------------------

Not at all, thanks! (echoing from under a pile of other work)

> Add Google Analytics tracking code to header-default.jsp
> --------------------------------------------------------
Reply all
Reply to author
Forward
0 new messages