Re: Need code to add name and phone number field to shopify newsletter for Impulse Theme

Need code to add name and phone number field to shopify newsletter for Impulse Theme

TamuC
New Member
4 0 0

Hi there, my store is https://www.thecocktailery.com and I am wondering if anyone has a piece of code that I can input that would enable me to request first name, last name and phone number for the newsletter signup?

 

Thanks in advance

Replies 4 (4)

code_with_adam
Shopify Partner
43 1 2

Hi @TamuC ,

You can add it as Customer Note: https://i.imgur.com/Ni8KxWh.png

Please add the code in the customer form: https://i.imgur.com/HYsfXgH.png 

Code: 

<input type="tel" id="{{ formId }}-phone" name="contact[note]" pattern="[0-9\-]*" value="{% if form[phone] %}{{ form[phone] }}{% elsif customer %}{{ customer.phone }}{% endif %}">
 

Hope it helps!

TamuC
New Member
4 0 0

Screenshot 2023-08-28 at 4.12.47 PM.png

TamuC
New Member
4 0 0

so this code will add name and phone number field here?

TamuC
New Member
4 0 0

I need fields for the newsletter signup not the customer accounts.