One also has to get used to the fact that there appear to be two elements created for each web link, a link and a node. Clicking on a web link is not the same as viewing the node as when editing it. This means that by default the new web links show on "Recent posts" but only shows on "Popular content" when it has been edited a number of times. Since there is a separate Popular Web Links block it may be something you don't want to show on the Popular content view and that view can be edited. Likewise, since there is a recent web links block you might not want to show the web links on the Recent posts view and this view also can be easily edited.

CommentFileSizeAuthor
#16 weblinks46.patch18.9 KBnancydru

Comments

nancydru’s picture

I wonder if hook_view might take care of this somehow?

rmiddle’s picture

Not really. The URL doesn't work because there is no way to know when someone has clicked on a link with our current method.

Thanks
Robert.

nancydru’s picture

Yeah, that's what I'm saying, maybe we can use hook_view instead of our current method. I'll look into this, but it might be a big change.

rmiddle’s picture

I think adding in a new method and documenting that straight URL doesn't work. Maybe evening hiding those blocks when URL is set. I think the idea of a redirect url that people click on works best. Were all links have something like /weblinks/links/nid that simple does a redirect to the url stored. Not hard to do and would allow us to track every click.

Thanks
Robert

nancydru’s picture

summit’s picture

Version: master » 5.x-2.1
Status: Postponed » Active

Hi Nancy,

Any progress in this field please?
The good thing to go through the same as on http://drupal.org/node/312225 is that link-stealing is also less easy using this process-handling.

Thanks a lot again for going into this!

greetings,
Martijn

nancydru’s picture

I started on this and got very confused and introduced problems into the module. Some of the code is still there. But Rmiddle says he will finish the click tracking part. Once that is done, the block is an easy change.

summit’s picture

Great! Looking forward to this.
Thanks for your quick reply (as always :).

greetings,
Martijn

rmiddle’s picture

Status: Active » Postponed

It is going to take me some time to get this done I am working 80+ hours a week at my day job right now. Things should slow down mid Nov. then I will be able to start working on things that are just sitting there waiting for more time.

Thanks
Robert

summit’s picture

Hi Robert, don't get a burn-out please, 80+ is a lot hours!
Thanks for your answer, and I'll wait for this.

greetings,
Martijn

rmiddle’s picture

Summit,

I am tiring not to burn out. This is kinda normal for my Job. We are in our xmas build right now. So by the time mid Nov. hits most everything for xmas is in place and work tends to die with only small project and the emergy stuff that needs fixed asap.

summit’s picture

Title: Popular Web Links block only works with node type. » Click tracking
Version: 5.x-2.1 » 6.x-1.x-dev
Status: Postponed » Active

Hi,

Setting this to D6, and thus acticve, and Click tracking as this is the key to this.
Any progress in this field please Robert?

Thanks a lot in advance for your update!

Greetings,
Martijn

nancydru’s picture

Status: Active » Postponed

Robert is busy taking care of his grandmother for a little while.

summit’s picture

Thanks for updating Nancy.
Robert, much energy and compassion for you on this task! I hope my grandchild will do the same once upon a time!
greetings,
Martijn

rmiddle’s picture

This is on my short list now. I hope to have something ready sooner then later.
Thanks
Robert

nancydru’s picture

Status: Postponed » Needs review
StatusFileSize
new18.9 KB

Patch to 6.x-2.x attached. The theme is changed to show click counts, if a link has been clicked. The Popular block has two new options to show click count and last click date.

I'm sure you are disappointed that the module should be a bit smaller.

BTW, this uses the "goto" redirect method.

summit’s picture

Hi Nancy, Will this be in the module patched. I tried patching this manually, but didn't succeed. Perhaps suggestion building seperate module for it, so it is possible to test it contained?
Greetings,
Martijn

nancydru’s picture

Because it is a relatively complex patch, I wanted some testing before I committed it, but maybe that won't happen.

nancydru’s picture

Status: Needs review » Fixed

Committed to 6.x-2.x-dev. Note that node titles now always point to the node. The rendered URL or "Visit" will redirect if that setting is chosen.

summit’s picture

Hi,
I confirm this is working, thanks for committing this!

I only see now default the click counting, also as anonymous user. Shouldn't it also be set by I setting if I want to show click counting like:

Clicked 2 times. Last clicked 04/20/2009 - 11:22.

I see it is set in: weblinks-link.tpl.php

 if ($click_count) {
    print '<div class="weblinks-click-stats">'. t('Clicked !count times. Last clicked !last.', array('!count' => $click_count, '!last' => $last_click)) .'</div><!--class="weblinks-click-stats"-->';
  }

Greetings,
Martijn

EkaMei’s picture

After some basic testing I can confirm that it is working, however I will play with it a bit more and report any issue due to the complexity of this patch. Thanks again for providing this.

nancydru’s picture

Assigned: Unassigned » nancydru

@Summit: We do theming so that you can change it any way you want.

summit’s picture

Hi Nancy, ok no prob, I thought I give by findings here so theming is the way to go then!
Greetings, Martijn

nancydru’s picture

Status: Fixed » Closed (fixed)

Cleaning up the queue.