noypiscripter
12-14-2017, 04:40 AM
By default, comments in vB5 have no Like button. I don't know the rationale behind not adding Likes in comments when you can like starter posts and replies. :confused:
If you want to enable Like button in comments, you've come to the right thread! This requires a very simple change in the comment template.
Here are the steps:
Login to AdminCP.
Navigate to Styles > Search in Templates.
Select the desired style/theme in the "Search in Style" dropdown.
Enter "conversation_comment_item" (without quotes) in the "Search for Text" field.
Select "Yes" in the "Search Titles Only" radio button.
Click "Find" button.
Double-click on the "conversation_comment_item" in the search result box to edit the template. Or select it then click "Edit" button on the "Controls" block on the right.
Search for the following line in the template: (Hint: It is near the bottom)
{vb:template conversation_footer, conversation={vb:raw conversation}, controls={vb:raw footerControls}}
Insert the following code ABOVE the code in Step 8
{vb:set footerControls.showVoteCtrl, 1}
Click "Save" button.
Repeat Steps 2 to 10 for each active style/theme you are using.
Adding the above code still adheres to the Like permission system. If user (e.g. guests) has no permission to like a post, the Like button will not be visible in the comments. Likewise, if you like your own comment, it will display an error "You cannot Like your own posts." similar to when you like your own starter post or reply.
This is a FREE mod. If you use this mod, please consider donating to show your support. Thank you!
NOTES:
This requires a template edit, so:
That means this mod is only for self-hosted version and not possible in vBCloud. Sorry vBCloud owners! :(
It may cause a template merge conflict for "conversation_comment_item" template whenever you upgrade. You would have to resolve the conflicts to ensure the change is not lost
This mod is also posted on my site (https://vbmods.rocks/forum/vbulletin-5-modifications/vbulletin-5-template-only-modifications/8260-add-like-button-in-comments).
If you want to enable Like button in comments, you've come to the right thread! This requires a very simple change in the comment template.
Here are the steps:
Login to AdminCP.
Navigate to Styles > Search in Templates.
Select the desired style/theme in the "Search in Style" dropdown.
Enter "conversation_comment_item" (without quotes) in the "Search for Text" field.
Select "Yes" in the "Search Titles Only" radio button.
Click "Find" button.
Double-click on the "conversation_comment_item" in the search result box to edit the template. Or select it then click "Edit" button on the "Controls" block on the right.
Search for the following line in the template: (Hint: It is near the bottom)
{vb:template conversation_footer, conversation={vb:raw conversation}, controls={vb:raw footerControls}}
Insert the following code ABOVE the code in Step 8
{vb:set footerControls.showVoteCtrl, 1}
Click "Save" button.
Repeat Steps 2 to 10 for each active style/theme you are using.
Adding the above code still adheres to the Like permission system. If user (e.g. guests) has no permission to like a post, the Like button will not be visible in the comments. Likewise, if you like your own comment, it will display an error "You cannot Like your own posts." similar to when you like your own starter post or reply.
This is a FREE mod. If you use this mod, please consider donating to show your support. Thank you!
NOTES:
This requires a template edit, so:
That means this mod is only for self-hosted version and not possible in vBCloud. Sorry vBCloud owners! :(
It may cause a template merge conflict for "conversation_comment_item" template whenever you upgrade. You would have to resolve the conflicts to ensure the change is not lost
This mod is also posted on my site (https://vbmods.rocks/forum/vbulletin-5-modifications/vbulletin-5-template-only-modifications/8260-add-like-button-in-comments).