-
Sebi86
Hey! π
I would like to change the format of the “comment area title” from H3-heading to a simple text format (span) and add some individual formatting (e.g. font-size: 26px etc.). Thank you for your support.
-
Hi there,
This should help:
https://docs.generatepress.com/article/generate_comments_title_output/Let me know π
-
Sebi86
Hey Leo,
Thanks for the prompt reply. Sorry, I am not proficient in web design, could you please tell me where to insert this code? I have a child theme with CSS and functions.php
Furthermore, can you please let me know how I can make some CSS adjustments to the comments title (i.e. font-size, font-weight, margin-top etc.)? Many thanks! π -
Hi there,
that code is PHP.
And this doc explains how to add it: -
Sebi86
Many thanks! I added the PHP to my functions.php, but even after clearing all the cache and checking on different browsers, it is unfortunately not working (still H3 instead of p). Any ideas? π
-
Ah, you need this snippet:
add_filter('comment_form_defaults',function($defaults){ $defaults['title_reply_before'] = '<p id="reply-title" class="comment-reply-title">'; $defaults['title_reply_after'] = '</p>'; return $defaults; }, 10, 1); -
Sebi86
Worked! Thank you. π
-
Glad to hear that
- You must be logged in to reply to this topic.