Jump to:
| Project: | Nitobe |
| Version: | 6.x-4.0 |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Shannon Lucas |
| Status: | closed (fixed) |
Issue Summary
Hi,
I believe this qualifies as a bug - in node.tpl.php, the following code is responsible for printing out user links below the node's content (copied from the CVS listing):
<div class="meta">
<?php
if ($taxonomy) {
print nitobe_render_terms($node) . (($comment > 0) ? " | " : '');
}
else {
print " ";
}
print (($comment > 0) ? nitobe_comment_link($node, $teaser) : " ");
?>
</div>
<?php if ($links): ?>
<div class="links"><?php //print $links; ?></div>
<?php endif; ?>
<div class="clear"></div>Thus, Nitobe introduces it's own handling of what otherwise is done via the $links variable (which isn't used at all).
The problem IMHO is that some other modules might add things to $links; these additional entries get not printed. I discovered this when playing with the talk module, where the links to add comments are not printed if there are no comments to a node (see this issue). Another example is the flag module; the "Bookmark this" link added by this module upon installation doesn't show up in a Nitobe themed site.
Comments
#1
* **apologies - looks like I posted in the wrong place! ***
I'm having a similar issue - would love some insight.
Maybe even simpler, but I'm just trying to print $links in my node.tpl.php. with this:
<div class="links"><?php print $links;?>
</div>
I haven't run any preprocessing on this variable.
The DIV is being successfully written, so I figured $links was empty.
However, my AddThis module is set to print the addthis button into the $links array.
I would love the "Comment" and "Read More" links too, but they aren't appearing - any idea where I set those?
(apologies if these are obvious questions)
Cheers!
#2
subscribing ...
#3
The code in Nitobe has been a bit too assuming about reformatting the list of links, and that approach seems to be causing issues with modules that modify the links array.
The next release will address this.
#4
This should be corrected in the 6.x-4.0 release.
#5
Automatically closed -- issue fixed for 2 weeks with no activity.