new product template json for customization

new product template json for customization

krisbee
Visitor
1 0 0

Hi i would like to create a new product template so the customer is able to input a name for engraving and other personalization on the product page. ideally this would be displayed on the cart page. currently using .json

 

I was able to do this when using liquid however i am struggling to find any instructions on creating this with json.

 

Any help would be appreciated - novice coder here. 

 

Thanks

Replies 2 (2)

PaulNewton
Shopify Partner
7746 679 1613

Hi @krisbee You don't do this type of logic in json templates directly they are just a property value store.

Use a custom-liquid block/section/setting and make formless inputs with the form attribute with the main product form id as the value

For dawn base themes that's roughly <input form={{ 'product-form-' | append: section.id  }} ....>

That liquid syntax to generate a form id will vary by theme, often found in main-product.liquid section, or buy-buttons.liquid snippet etc.

The form attribute associates an input to a form even if that input is NOT inside the form.

 

 

If you need this customization you can contact me for services.
Contact info in forum signature.
ALWAYS please provide context, examples: store url, theme name, post url(s) , or any further detail in ALL correspondence.

Contact paull.newton+shopifyforum@gmail.com for the solutions you need


Save time & money ,Ask Questions The Smart Way


Problem Solved? ✔Accept and Like solutions to help future merchants

Answers powered by coffee Thank Paul with a Coffee for more answers or donate to eff.org


WhiteWater_Web
Shopify Partner
468 19 43

Several ways to do this using a liquid section/custom code, or via a free easy-to-use app. We’re fans of the King Product Options app as it is easy to add options like ‘engraving fields’ to all products or specific products. Just make sure to include code to add the ‘option’ field data to order notifications, etc.


Pros and cons to each.

 

Good luck!

WhiteWater Web

A certified Shopify Partner and Expert, WhiteWater Web (WWW) is a premium digital solutions company specializing in advanced Shopify Dev, Usability/Design, and Online Strategy. WWW has been working with the Shopify platform since 2006.
info@whitewatersolutions.com