0
Hi, I've purchased Content Statistic recently and needed some custom action to be tracked. My desired action include:
1) Outbound link tracking (use AJAX call to action before out-bounding)
2) DOM tracking - click & scroll ( jQuery + AJAX should do the trick)
3) Individual's user visit duration tracking / time spent on page ( not sure how to do it yet )
I've some knowledge in AJAX and MySQL just that I'm hope to get some guideline on modify the source code with minimal impact on original function, e.g. which file I should edit/add to include more custom Action, which file is the 'Controller' where I could post AJAX call, any modification on database needed, etc. Or better yet, if you could provide a guideline to develop those in a form of plugin I would be grateful.
Thank you.
1) Outbound link tracking (use AJAX call to action before out-bounding)
2) DOM tracking - click & scroll ( jQuery + AJAX should do the trick)
3) Individual's user visit duration tracking / time spent on page ( not sure how to do it yet )
I've some knowledge in AJAX and MySQL just that I'm hope to get some guideline on modify the source code with minimal impact on original function, e.g. which file I should edit/add to include more custom Action, which file is the 'Controller' where I could post AJAX call, any modification on database needed, etc. Or better yet, if you could provide a guideline to develop those in a form of plugin I would be grateful.
Thank you.
Responses (7)
-
Accepted Answer
0hello,
1 & 2) the thing about tracking is that our plugin tracks actions in "components". this means that probably the best way to track these custom things would be to add "fake" actions to track (like... index.php?option=com_content&task=fake_action) and then you add this action to track into the plugin. with AJAX, you would be in charge to "call" this URL so the system tracks it.
but... this is complicated. you really must know what you're doing to track this...
about number 3) that's something else, you would need to modify the core plugin and somehow start tracking visit duration (also with some kind of ajax tracking...)
what you describe is technically a bit complicated. we can do these kind of things in our Custom Coding Service. -
Accepted Answer
-
Accepted Answer
-
Accepted Answer
0Thank you for the reply, will take a look later. By the way which place should I place my code to call my 'fake action', it should be place as one of the task in com_content right? For example, when user click on a certain link with class name "record_this", I will post some value like 'component', 'type', 'reference_id' to the task n within the task there will be code to insert them into database. -
Accepted Answer
-
Accepted Answer
-
Accepted Answer
0ok I can see you may be a bit lost.. the plugin will be anyone, the one you decide to create the "fake action" for... but in your case, since you seem to have to modify the com_community plugin, that would be the one...
just.. at this point... I have to suggest to "don't do anything you don't know"!
Your Reply

Please login to post a reply
You will need to be logged in to be able to post a reply. Login using the form on the right or register an account if you are new here.
Register Here »