Closed (fixed)
Project:
Buy Me a Beer
Version:
6.x-1.1-beta1
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Reporter:
Created:
27 Feb 2009 at 22:13 UTC
Updated:
5 Mar 2009 at 22:24 UTC
I'm using the new buymeabeer-for-users setting for a site that does a lot of user-generated questions (as nodes) and answers (as comments). Right now the buymeabeer link is appearing below both questions (nodes) and answers (comments), but I just want it to appear below answers. Any idea what snippet in the buymeabeer.module code I would adjust/remove it from the node while preserving it for each comment? Or if there's a setting somewhere I missed?
Once again, thanks for the this extremely straightforward module, it really bridges a gap for our site.
Comments
Comment #1
yaph commentedUncheck the question node type on the buymeabeer settings, so the link is not displayed below the question. It should still be displayed on comments (answers) to questions.
Comment #2
fumbling commentedThanks, sorry, I should clarify, as I already unchecked all the content types. I would like the link to appear below users comments, but not their new posts/nodes. Right now for users w/ buymeabeer turned on it shows on both their new nodes and their comments. Is it possible to restrict to just user comments?
Comment #3
yaph commentedI understand, there is no setting for that. You could hide the link below the node using CSS or hook_link_alter (http://api.drupal.org/api/function/hook_link_alter) to remove it from node display.
I see additional settings would be helpful here, maybe something like "show user link only in comments". What do you think would be a useful setting?
Comment #4
fumbling commentedThat setting, just as you suggest it, would be perfect. I'm not savvy enough to do the hook link alter, but I work w/ a css guy that might be able to do it. Thanks again for your help.
Comment #5
yaph commentedI just released Buy me a Beer 1.1 Beta2 (http://drupal.org/node/388976) with the following changes:
show user link only in node links of enabled content types but in all comment links if buymeabeer_userbeer_enable is enabled.
So no additional setting is necessary.
Comment #6
fumbling commentedThanks, downloaded, that did just the trick, appreciate it.
Comment #7
yaph commented