Shopify themes, liquid, logos, and UX
I'm using Dawn Theme. I'm needing my Custom Liquid section to have an option to select a dynamic source. Is there a line of code I can add to the section file? Thanks!
For context, we have shortcodes added to a metafield for each product that will load a unique UGC gallery for each product.
Hello @pearlerwork
Here's a simplified example of what the code might look like in your section file:
<div class="custom-section">
<form action="#" method="post" id="dynamic-source-form">
<label for="dynamic-source-select">Select Dynamic Source:</label>
<select name="dynamic-source" id="dynamic-source-select">
{% for source in product.metafields.custom.sources %}
<option value="{{ source }}">{{ source }}</option>
{% endfor %}
</select>
<button type="submit">Apply</button>
</form>
</div>
iCart Cart Drawer Cart Upsell App
@iCart_App
In Shopify product section will the form action need. Is that managed by Shopify auto?
Thank you
In Shopify, the form action for product sections typically doesn't need to be specified manually. Shopify handles form submissions automatically for product pages.
When a customer interacts with the product form, such as selecting options for variants or adding the product to the cart, Shopify's JavaScript code manages the form submission process.
iCart Cart Drawer Cart Upsell App
Thanks, @iCart_App - shouldn't I be adding schema, not HTML?
I'm just wanting to add the little 'dynamic source' button in the top right like all the other fields have:
i'm having the same issue. did you get a resolutions? thanks
We want to take a moment to celebrate the incredible ways you all engage with the Shopi...
By JasonH Oct 15, 2024Starting a B2B store is a big undertaking that requires careful planning and execution. W...
By JasonH Sep 23, 2024By investing 30 minutes of your time, you can unlock the potential for increased sales,...
By Jacqui Sep 11, 2024