Jojodae Ganesh Sivaji
March 23, 2012
Drupal provides a handful of settings to format the comment listing. One thing that we found very irrelevant in the comment view is the link item "Login or register to post comments" especially when the comments are styled to display as flat items. Let's take the snapshot below from the drupal.org issue queue.
[[{"type":"media","view_mode":"media_original","fid":"102","attributes":{"alt":"","class":"media-image","typeof":"foaf:Image"}}]]
It is obvious that the login and register link in every comment is not needed. Fortunately, Drupal 7 provides a hook to alter comment view output hook_comment_view_alter(&$build)
These five lines of code shared above do the trick of removing unwanted stuff from the comment view.
Just like how your fellow techies do.
We'd love to talk about how we can work together
Take control of your AWS cloud costs that enables you to grow!