Check box for newsletter subscription

Unforgettable
Tourist
8 0 2

Hello everyone, 

I am using empire theme and I am looking for a free app or some code lines to add a check box in the newsletter subscription section.

at the moment it is sufficient for the customer to put his/her email address and to click on the button but I would like to add a checkbox which says : I read and accepted the privacy statement <link>.

Is there anyway to do that?

Thanks for your help 

Replies 14 (14)

jetlags
Visitor
3 0 0

Hi, did you already get this code? thanks..

Florian123
Visitor
3 0 0

Hi, I am also interested in a solution!

AvidBrio
Shopify Expert
295 17 29

hi all @Florian123  @Unforgettable  @jetlags  i am posting the solution 

you can find the newsletter template file  based on your theme- you can search into your theme code find this type of text  subscribe

 

 <button
        class="
          form-field
          newsletter-submit news-btn-v2
          button---{{ button_style }}
        "
        name="subscribe"
        type="submit"
      >
        {{ 'general.newsletter.subscribe' | t }}
      </button>

 

add this line below to the button 

 

      
<!-- add this live below to subscribe button code --><br/>
      <input type="checkbox"value="" required/>  I have read and agree to the Terms of Use and Privacy Policy

 



if you need more help on that- you can DM me or email me at jim@avidbrio.com 

If you find our comment helpful, hit the like button and accept it as a solution.
Want us to implement custom changes in your store? Contact us
Email me directly - jim@avidbrio.com
wearehumanus
Tourist
7 0 3

Hi 

</div>
 
{% schema %}
  {
    "name": "Newsletter",
    "class": "newsletter-section",
    "settings": [
      {
        "type": "text",
        "id": "title",
        "label": "Heading",
        "default": "Subscribe to our newsletter"
<input type="checkbox"value="" required/>  I have read and agree to the Terms of Use and Privacy Policy
      },
  {
        "type": "text",
        "id": "subtitle",
        "label": "Subheading",
"default": "A short sentence describing what someone will receive by subscribing"
 

In the footer.liquid I tried to add the line of code but got the result below. Could you please advise? Thanks a lot.

 

In the liquid footer Screenshot_1.jpgScreenshot_2.jpg

AvidBrio
Shopify Expert
295 17 29

@wearehumanus  you have add the HTML check box for only the newsletter.  Currently, you added on schema means they render on of active block, you can add the checkbox on newsletter snippets or particular section file.

If you find our comment helpful, hit the like button and accept it as a solution.
Want us to implement custom changes in your store? Contact us
Email me directly - jim@avidbrio.com
wearehumanus
Tourist
7 0 3

Thanks for much for your prompt response Avid.

Now I got the following:

The email address input box size changed.

wearehumanus_0-1608187365051.png

wearehumanus_1-1608187410947.png

 

 

AvidBrio
Shopify Expert
295 17 29

now you get your solution correct? @wearehumanus 

 

If you find our comment helpful, hit the like button and accept it as a solution.
Want us to implement custom changes in your store? Contact us
Email me directly - jim@avidbrio.com
wearehumanus
Tourist
7 0 3

@AvidBrio 

Hi again Avid and thanks for your follow-up. Haven't found the solution yet but on it. Any idea on the box size and putting a hyperlink on the Privacy Policy?

wearehumanus_1-1608376583971.png

 

wearehumanus_0-1608376495242.png

 

dottedlineshopi
Visitor
1 0 0

Hi,

 

Im using the Debut Theme as well and despite I did follow your step, the check box doesnt show up.

Screenshot 2020-12-20 at 12.45.11.png

Screenshot 2020-12-20 at 12.45.31.png

 

Could you please advise?

 

Thanks!!!

AvidBrio
Shopify Expert
295 17 29

@dottedlineshopi I can see you added code at the right place.  there two-issue

Maybe some CSS issue not showing up there.

or that section template used a different one. so cross check agin

If you find our comment helpful, hit the like button and accept it as a solution.
Want us to implement custom changes in your store? Contact us
Email me directly - jim@avidbrio.com
Zaza04
Visitor
1 0 0

I'm also interested in finding out how to add hyperlink to the text. I would like t hyperlink the "privacy policy" text to my privacy policy page.

wearehumanus
Tourist
7 0 3

No, still not. Still haven't figured out the right coding to get the appearance right and the hyperlink embeded.

wearehumanus_0-1608531737178.png

 

AvidBrio
Shopify Expert
295 17 29

@wearehumanus  thank for posting your issue now you need to add CSS based on your layout. if can't do it yourself then you have to hire an Expert Developer.

If you find our comment helpful, hit the like button and accept it as a solution.
Want us to implement custom changes in your store? Contact us
Email me directly - jim@avidbrio.com
Parizat
Tourist
3 0 1

OMG! this is really helpful! thank you!!!!