Comment Guard: Link

Disables comment author links and limits the number of links in a comment.

0 stars out of 5

0 0 0 0 0
  • Author Taufik Nurrohman
  • Maintainer 1
  • Member
  • Version 1.0.2

Limit the number of links in comments with this extension. You can set the maximum number of links allowed in a comment by setting the content value in the .\lot\x\comment.guard.link\state.php file. The link property is used to determine whether or not to remove an anchor that surrounds the comment author’s name in the default comment markup. Note that this will also remove the link field in the comment form.

<?php

return [
    'content' => 5,
    'link' => false
];

If you set the content value to true, it will allow links in comments. Value as a number less than 0 will convert all links in comment content to plain text. If you set the content value to 0 or false, it will not allow any links in comments. Value as a number greater than 0 will limit the number of links you can put in a comment.

If you set the link value to true, then it is the same as enabling the link field in the comment form. If you set the link value to 0 or false, it will remove the link field in the comment form. Value as a number less than 0 will remove the link field in the comment form, including the anchor tags surrounding the comment author’s name in the existing comments.

KeyValueDescription
content-1Disallow links in comments and remove all links in existing comments.
content0Disallow links in comments.
content5Allow a maximum of 5 links to be included in a comment.
contentfalseDisallow links in comments.
contenttrueAllow links in comments.
link-1Hide the link field in the comment form and remove the anchor tags surrounding the comment author’s name.
link0Hide the link field in the comment form.
linkfalseHide the link field in the comment form.
linktrueShow the link field in the comment form.

This extension does not change the existing comments data, it only changes their presentation when they are presented in the default comments layout.

0 Comments

No comments yet.