Skip to content
● Grav 2.2 is out: 2x faster cold starts and 96% less memory on big sites. Read the announcement →

Comments plugin without submit form

Started by Werner Joss 8 years ago · 1 replies · 798 views
8 years ago

I'm currently trying to get the comments plugin to show comments on pages without the comment submit form.
the reason is, I'm migrating an existing Wordpress blog to Grav, which is now mostly working,
but I don't want to enable submitting comments on old posts which already have comments, those should only be visible.
I wonder if this might be possible by tweaking comments.html.twig (already tried that without success) or if this would need the plugin source code to be modified (by e.g. introducing a new 'show_comments' twig variable ?

8 years ago

just to answer my own question 😉 - I solved the problem by using a modified item_cform.html.twig which would incorporate an also modified partials/blog_item_cform.html.twig, including the comments submit form.
Now I can use this for (new) posts as long as I want comments submit to be enabled.
Later, I use templates which just show the comments, but no submit form.

Suggested topics

Topic Participants Replies Views Activity
Plugins · by renedebaaij, 12 hours ago
0 16 12 hours ago
Plugins · by complanar, 2 weeks ago
6 379 2 weeks ago
Plugins · by BenLaKnet, 2 weeks ago
1 197 2 weeks ago
Plugins · by complanar, 1 month ago
2 472 4 weeks ago
Plugins · by Vladimir Novak, 2 months ago
3 750 2 months ago