• Resolved orgassist

    (@orgassist)


    I just installed the plugin but no subscribe option has been added to the comment section. After reading similar posts, I’ve checked the following options:
    – Show StCR checkbox/dropdown – Yes
    – StCR Position – Yes
    – Enable on post types – Posts, Pages

    Under Comment Form:
    – Enable default checkbox – Yes
    – Advanced subscription – Yes

    The page I need help with: [log in to see the link]

Viewing 8 replies - 1 through 8 (of 8 total)
  • Hi @orgassist

    It seems that the comment form in your site is modified version from the WordPress default comment form, and hence it is not working since there is the change of the id of the comment form. So, you need to modify the comment form display of your site: https://developer.www.ads-software.com/reference/functions/comment_form/ with the default argument pass for the id_form argument for this to work.

    Thread Starter orgassist

    (@orgassist)

    Thank you for the reminder. I had previously created a modified version of comments.php in my child theme. I’ve deleted that now, resaved your plugin settings and cleared all caches but there is still no checkbox. There is no reference to comments in functions.php.

    Hi @orgassist

    We can still see the modified version of the comments in your site. So, could you once properly check on it and confirm?

    Thread Starter orgassist

    (@orgassist)

    I’m not seeing what you’re seeing. What is indicating to you that the comment form is modified?

    Plugin Author WPKube

    (@wpkube)

    Hi @orgassist

    This is the HTML of the <form> element for the comment forms on your site:

    <form action="..." method="post" id="fl-comment-form" class="fl-comment-form">

    This is the default WordPress <form> element:

    <form action="..." method="post" id="commentform" class="comment-form">

    The difference is the ID (should be “commentform” instead of “fl-comment-form”) and class (“comment-form” instead of “fl-comment-form”).

    Our plugin looks for the form with the ID “commentform” (the default) to know where to place the subscription checkbox/label.

    That fl- prefix shows up throughout the source code of your site, it’s not limited just to the comment form.

    It’s added by the Beaver Builder theme that you are using, so it’s not something you can modify.

    Do the “comment subscription” elements not show up when you have the “StCR Position” set to “No” (in WP admin > StCR > Options)? That’s set to “No” by default and setting it to “Yes” is only meant for older themes where we have to use JavaScript to move the elements to the correct position.

    The theme correctly uses comment_form() to display the form, however it is also correctly using the comment_form_defaults filter to change the ID and class, being a filter its easily changable.

    add_filter( 'comment_form_defaults', function( $args ) {
      $args['id_form'] = 'commentform';
      $args['class_form'] = 'comment-form';
      return $args;
    }, 11 );
    Thread Starter orgassist

    (@orgassist)

    Thank you for that clarification. I’ve switched that setting to No, and everything is working now.

    I stated in my original post that I had StCR Position set to Yes, so it would have saved us both time if you’d mentioned this first.

    Plugin Author WPKube

    (@wpkube)

    Hi @orgassist

    You’re welcome.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘No checkbox showing up’ is closed to new replies.