Archived topic
removing links from the author, date in comment section
19 replies · Started by dassana on September 17, 2018
i want to remove the links from the author in the comment section. i did search in the forum but there are snippets of different codes for different functions. hence not added these codes.
Hi there,
There's no filter for this, unfortunately. You'd have to overwrite the entire function.
You can do that by adding this function to your site: https://gist.github.com/generatepress/6a9ad4e007ae0a7388bbbbb7b3ae068f
thanks tom. this code worked very well.
Just made a change: https://gist.github.com/generatepress/6a9ad4e007ae0a7388bbbbb7b3ae068f
Let me know :)
works like a charm. thanks a ton for all the support you and your team has given. ☺️🙏
You're welcome! :)
May I add this code to function file of GP Child Theme?
Hi I tried to add this code in the CodeSnippet Pplugin to remove links from the author, date in comment section. Getting following error.
The snippet has been deactivated due to an error on line 8:
Cannot redeclare function generate_comment.
Thanks,
Software Testing Material
Just tested it and this one will need to be added in the function.php file of your child theme:
https://docs.generatepress.com/article/using-child-theme/
Hi Leo, I am not using any child theme. I am using the Generatepress Premium theme. Can you guide me to fix this?
Thanks in advance.
Hi there,
you will need to install the GP Child Theme - see here:
https://docs.generatepress.com/article/using-child-theme/
Without the child theme the changes you require cannot be made at this time.
Hi David,
Thanks. I have installed the child theme and its working fine. Earlier I used Snippet plugin and Simple CSS plugin. Now I had moved the code to child theme relevant files (functions.php and style.css files). There is no point to use Snippet plugin and Simple CSS plugin right when using child theme and able to modify functions.php and style.css.
Thanks in advance.
Yup that's exactly what you'd want to do :)
Thanks Leo & David.
Software Testing Material