0

I would like to move the "Login or Register to Post Comments" link from above the comments to below the comments, yet above the comment form.

I have the link variable available in the preprocess_node hook and I can unset it there, but when I try to add it as a variable with another name, it's not available in comment-wrapper.tpl.php.

I guess I'm asking what the Drupal way is to pass this variable from the node to comment-wrapper.tpl.php. It's important that we copy the variable value instead of manually creating the links in so we have the same value for the login and register links regardless of whether another module has acted/changed them.

2

The "Login or Register to Post Comments" link is created via:

theme('comment_post_forbidden', array('node' => $node));

so I'd create a variable with that in the appropriate preprocess hook that has $node available.

1

Use

theme('comment_post_forbidden', array('node' => $node));

protected by Clive Jul 28 '16 at 16:33

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.