Shopify themes, liquid, logos, and UX
Hi,
I was previously using an app to manually insert that certain products would have a upload button if you choose to click a certain variant of the product so we can paint the product according to the photos that the customer uploaded.
However I quickly realised that it would take so long time to manually insert that using the app so I am in need of help on how to automatize so that every variant X will have an upload button so the customer can attach photos which we can paint according to.
TLDR: Need help inserting upload button so customer can attach photos which we will paint the product after.
Best regards
Log
Hi @Log ,
Add the following code to main-product.liquid product forms:
<div>
<input type="file" id="file" name="properties[File]" form="{{ product_form_id }}">
<label class="field__label" for="file">Custom Image</label>
</div>
If you require further help to optimize or customize your store, please don’t hesitate to reach out. If you find this information useful, a Like would be greatly appreciated. And if this solves the problem, please Mark it as Solution!
Best Regards,
LuffyOnePiece
Hi Luffy. How do I choose which variant it will be applied to?
Best regards
Log
Hi @Log ,
Whichever the user selects the variant, the image will be selected for that selected variant.
If we need to allow the user to uplaod an image to only specific variant, we need to custom code for that.
Thank you
Will it apply to all products of said variant when the attached code is inserted into main-product.liquid?
Also, where will the uploaded images be sent? Does the attached code understand it is part of an order?
Best regards
Log
Hi @Log ,
It will be applied to all the products when the attached code is inserted into main-product.liquid inside product form.
Also remove the Content-Type as we're no long passing a json as the request's body.
The image will be sent as a line item properties of the product.
Thank you
It needs to be custom code because I do not want all my products to have the upload button, only if you click this variant the upload button should show up
Best regards
Log
Hi @Log ,
I can help you with the custom code.
Please let me know if you need help with the store customization.
Thank you
Hi @Log ,
You can contact me by email or WhatsApp for further queries.
Thank you
Hi @Log,
You should try out the Easify Product Options app. It allows you to seamlessly integrate a File Upload option for specific product variants in your store. With its Advanced conditional logic, you can easily determine which variants trigger the custom file upload feature. Setting it up takes just a few minutes. Here's a quick example for you 🤗:
Hope you can give the app a try!
By investing 30 minutes of your time, you can unlock the potential for increased sales,...
By Jacqui Sep 11, 2024We appreciate the diverse ways you participate in and engage with the Shopify Communi...
By JasonH Sep 9, 2024Thanks to everyone who participated in our AMA with 2H Media: Marketing Your Shopify St...
By Jacqui Sep 6, 2024