Limited Support
Our team is currently on holiday, so support will be limited during this period. Response times may be slower than usual, and some inquiries may be delayed.
We appreciate your patience and understanding, and we’ll resume our usual support by the end of August.
Hello,
Â
is there a way to include the post title inside the comment join text (the placeholder)?Â
Â
I would like to change it dynamically according to the current post to something like:
Â
"What are your thoughts about 'post title' ?"Â
Â
Maybe this is archivable with a simple snippet?Â
Â
Thanks in advance.Â
Got it working with this:
Â
add_filter("wpdiscuz_phrase", function ($phrase, $key, $args) { if ($key === "wc_comment_join_text") { $title = get_the_title(get_queried_object_id()); $phrase = str_replace("Kommentar", "What are your thoughts about $title ?" , $phrase); } return $phrase; }, 10, 3);
Â
But now there results another question out of it: As the placeholder is the same like in reply to textarea it doesn't fit anymore. How can I hide the placeholder only in reply to form but keep it in the main comment form?
Thanks, working! Last question: Is it also possible to change the submit button text only for replies?
Great, thanks alot. Everything solved! 🙂