WordPress.org

Forums

MailPoet Newsletters
[resolved] "Subscribe in Comments" checkbox above submit button? (15 posts)

  1. etech0
    Member
    Posted 1 year ago #

    Hi! Thanks for a great plugin!

    I'm currently using the "Subscribe in Comments" checkbox. Is there a way to place it above the Submit button in the comment form?

    Thanks!

    http://wordpress.org/plugins/wysija-newsletters/

  2. Ben
    Member
    Plugin Author

    Posted 1 year ago #

    Hello there,

    That's simple css/js customization.
    Get in touch with these guys : https://codeable.io/

    For sure they'll know how to help you.

    Cheers,
    Ben

  3. etech0
    Member
    Posted 1 year ago #

    Thanks for the reply! I'm pretty ok at css, and learning js. Do you think you could point me in the right direction for this?
    Thanks!

  4. Tung Wysija
    Member
    Posted 1 year ago #

    Hi there,

    Basically, you will use js to move the boxes. In this case, they are submit button and the subscription form.

    Hope this helps!

  5. etech0
    Member
    Posted 1 year ago #

    Thanks! I think I'm looking for something like this:

    $('.submit').each(function() {
        $(this).insertAfter($(this).parent().find('.name-of-checkbox'));
    });

    Does that make sense? ALso, the p with the checkbox and label in it doesn't have a name.

    And where would I put the code?

    Thank you!

  6. MailPoet Staff
    Member
    Plugin Author

    Posted 1 year ago #

    Etech0, please follow up on this contact form for faster support: http://support.mailpoet.com/feedback/

    Thanks!

  7. etech0
    Member
    Posted 1 year ago #

    Will do, thanks!

  8. ckhNL
    Member
    Posted 1 year ago #

    This issues is actually NOT resolved. I contacted MailPoet and mentioned this post but was referred to a recommended customization company.

    Unfortunately for us Mailpoet doesn't offer the option Subscribe2 does: shall we place the checkbox above or below the submit button?

  9. This issues is actually NOT resolved.

    Sure it is. Either the plugin author or the original poster marked it resolved.

    If you have a problem with the plugin then per the forum welcome please post your own topic.

    http://wordpress.org/support/plugin/wysija-newsletters

  10. etech0
    Member
    Posted 1 year ago #

    The issue is definitely resolved. I used the contact form as suggested, and they helped me write this jquery code which fixed it:

    jQuery(document).ready(function() {
            jQuery('p.form-submit').insertAfter('p.wysija-after-comment');
            jQuery('#wysija-box-after-comment').attr('checked','checked');
    });
  11. ckhNL
    Member
    Posted 1 year ago #

    Great news! Fantastic, even if Mailpoet Support informed me differently.

    How do I however implement this jQuery for all comment pages? As placing the checkbox above the button is a best-practice this would really benefit al lot of users...

  12. etech0
    Member
    Posted 1 year ago #

    I made a file called submitbutton.js, and put that jquery code in it. Then I added this line to a custom plugin I have that stores all my functions.

    wp_enqueue_script( 'submitbutton', get_template_directory_uri() . '/js/submitbutton.js', array( 'jquery' ), '', true );

    How to set up a plugin for your functions:
    http://www.doitwithwp.com/create-functions-plugin/

  13. ckhNL
    Member
    Posted 1 year ago #

    Great! I installed it all and got it working as a part of my special theme child.

    .. the Mailpoet checkbnox line however doesn't move, because my submit button can't be found by the name above (p.form-submit). And I have some troubles finding out what should be the correct name.

    Do you have any suggestions? Would be great!

    </div> <!-- .box-wrap -->
    	</section> <!-- #comment-wrap -->
    
    	<section id="comment-form-wrap" class="entry box">
    		<div class="box-wrap">
    
    	<h3 id="respond" class="comments">Plaats je reactie</h3>
    
    	<div class="post-form innerbox">
    					<form action="wp-comments-post.php" class="group" method="post" id="reactieformulier">
    																										<fieldset><p><textarea title="Je reactie" cols="30" rows="4" id="comment" name="comment" aria-required="true"></textarea></p></fieldset>
    				<input type="submit" name="submit" class="btn" id="verstuur" value="Verstuur">
    				<input type='hidden' name='comment_post_ID' value='1270' id='comment_post_ID' />
    <input type='hidden' name='comment_parent' id='comment_parent' value='0' />
    
    				<input type="hidden" id="_wp_unfiltered_html_comment_disabled" name="_wp_unfiltered_html_comment_disabled" value="dc3c564136" /><script>(function(){if(window===window.parent){document.getElementById('_wp_unfiltered_html_comment_disabled').name='_wp_unfiltered_html_comment';}})();</script>
    <p style="display: none;"><input type="hidden" id="akismet_comment_nonce" name="akismet_comment_nonce" value="525fc9a61f" /></p><p class="wysija-after-comment"><label for="wysija-box-after-comment"><input type="checkbox" id="wysija-box-after-comment" value="1" name="wysija[comment_subscribe]">Ja, ik ontvang ook graag wekelijks een update met de nieuwste berichten.</label></p>			</form>
    			</div>
    
    		</div> <!-- .box-wrap -->
    	</section> <!-- #comment-form-wrap -->
    					</div> <!-- .columns -->
  14. etech0
    Member
    Posted 1 year ago #

    You can use Firebug or Chrome Developer tools to find out what the name should be. Or if you give me a link to the webpage in question I can locate it for you.

  15. ckhNL
    Member
    Posted 1 year ago #

    Thanks for offer, but let me first give this a try myself.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • MailPoet Newsletters
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic