wpsharks / comment-mail

A WordPress plugin enabling email subscriptions for comments.
http://comment-mail.com
GNU General Public License v3.0
8 stars 3 forks source link

Add Subscription Form: Option to hide pre-populated list of comments #210

Open raamdev opened 8 years ago

raamdev commented 8 years ago

It should be possible to disable the pre-populated list of comments on the Add Subscription form (when subscribing without commenting) to simplify what the subscriber sees when creating the subscription.

2016-01-11_21-31-20

Note that this is closely related to https://github.com/websharks/comment-mail/issues/209, which documents a bug with the comment detection when subscribing without commenting.


This was noted by @RealDavidoff in https://github.com/websharks/comment-mail/issues/199#issuecomment-170644228.

Related: https://github.com/websharks/comment-mail/issues/203

jaswrks commented 8 years ago

Possible Short-Term Solution

Switch to Advanced template mode and update this section of code as shown below in the template for the "Add/Edit Form":

2016-01-12_12-23-14

Here's that updated code as shown in the screenshot above:

<?php echo $form_fields->select_row(
    array(
        'name'                => 'comment_id', 'options' => '', 'post_id' => $current_value_for('post_id'), 'current_value' => $current_value_for('comment_id'),
        'input_fallback_args' => array('type' => 'hidden', 'maxlength' => 20, 'other_attrs' => 'min="1" max="18446744073709551615"', 'current_value_empty_on_0' => TRUE),
    )); ?>
RealDavidoff commented 8 years ago

I can't: I wouldn't know how to "also change the AJAX template variation".

Also, which of my suggestions would this short-term solution relate to? The only reason why we cannot use cm as is, is that users can subscribe to things they haven't even read yet (which is for a reason). Which code blocks would need to be deleted to prevent THIS Jason?

(Raam has created a # for that, not sure which)

raamdev commented 8 years ago

@RealDavidoff I updated @jaswsinc's Short-Term Solution above; see https://github.com/websharks/comment-mail/issues/210#issuecomment-170941795.

Note that you don't need to change the AJAX template variation if you are disabling that functionality altogether.

I also posted a similar Short-Term Solution for hiding the pre-populated Posts here: https://github.com/websharks/comment-mail/issues/203#issuecomment-171127582