真实国产老熟女无套中出,亚洲精品一区二区成人,亚洲最新中文字幕成人,又污又爽又黄的网站,亚洲中文字幕无码爆乳app

shopify設(shè)置商店模板和將表單字段設(shè)置為必填字段步驟-ESG跨境

shopify設(shè)置商店模板和將表單字段設(shè)置為必填字段步驟

shopify新聞
shopify新聞
2022-03-28
點贊icon 0
查看icon 1236

若要防止客戶在不選擇您是如何了解到我們商店的?表單字段中選項的情況下繼續(xù)結(jié)賬,您可以將該字段設(shè)置為必填字段。

為配置添加模板設(shè)置

  1. 在 Config 目錄中,點擊 settings_schema.json。

  2. 在代碼中查找第一個右大括號 },。在右大括號 }, 下方的新行中,粘貼以下代碼:

{ "name": "Hear About Us", "settings": [ { "type": "text", "id": "hau_form_options", "label": "Form options", "default": "Facebook, Twitter, Google, Instagram, Youtube", "info": "Separate each option with a comma" }, { "type": "header", "content": "Form validation" }, { "type": "checkbox", "id": "hau_form_validation", "label": "Enable form validation", "default": true }, { "type": "text", "id": "hau_error_message", "label": "Error message", "info": "The error message that is displayed when no selection is made", "default": "Please select an option below" }, { "type": "text", "id": "hau_error_message_other", "label": "Other field error message", "info": "The error message that is displayed when there is no input in the 'Other' field", "default": "Please fill the text field below" }, { "type": "header", "content": "Error styling" }, { "type": "color", "id": "hau_error_color", "label": "Color", "default": "#ff0000" } ] },
  1. 點擊保存

將表單字段設(shè)置為必填字段

若要防止客戶在不選擇您是如何了解到我們商店的?表單字段中選項的情況下繼續(xù)結(jié)賬,您可以將該字段設(shè)置為必填字段。

  1. 在 Sections 目錄中,點擊 cart-template.liquid。如果您的模板中不包含 cart-template.liquid,請點擊 Templates 目錄中的 cart.liquid。

  2. 在購物車表單字段中查找以下 novalidate 屬性:

novalidate
  1. 將 novalidate 屬性替換為以下代碼:

{% unless settings.hau_form_validation %}novalidate{% endunless %}
  1. 點擊保存

  2. 在模板編輯器中,點擊側(cè)邊欄上的模板設(shè)置。

  3. 點擊了解我們選項卡。

  4. 表單驗證下,確保已啟用啟用表單驗證設(shè)置。

備注:您可以通過修改錯誤消息其他字段錯誤消息文本字段設(shè)置來自定義顯示的錯誤消息。您還可以通過更改錯誤樣式下的顏色設(shè)置來自定義錯誤顏色。

Include the snippet in your cart page

To include the How did you hear about us? snippet in your cart page:

  1. In the Sections directory, click cart-template.liquid. If your theme doesn't include a cart-template.liquid, then click cart.liquid in the Templates directory.

  2. Find the closing </form> tag in the code. On a new line above the closing </form> tag, paste the following code:

    {% render 'hear-about-us' %}
  3. Click Save.

Add theme settings for configuration

  1. In the Config directory, click settings_schema.json.

  2. Find the first closing curly bracket }, in the code. On a new line below the closing curly bracket },, paste the following code:

    { "name": "Hear About Us", "settings": [ { "type": "text", "id": "hau_form_options", "label": "Form options", "default": "Facebook, Twitter, Google, Instagram, Youtube", "info": "Separate each option with a comma" }, { "type": "header", "content": "Form validation" }, { "type": "checkbox", "id": "hau_form_validation", "label": "Enable form validation", "default": true }, { "type": "text", "id": "hau_error_message", "label": "Error message", "info": "The error message that is displayed when no selection is made", "default": "Please select an option below" }, { "type": "text", "id": "hau_error_message_other", "label": "Other field error message", "info": "The error message that is displayed when there is no input in the 'Other' field", "default": "Please fill the text field below" }, { "type": "header", "content": "Error styling" }, { "type": "color", "id": "hau_error_color", "label": "Color", "default": "#ff0000" } ] },
  3. Click Save.

Make the form field required

To prevent customers from ceeding to the checkout without selecting an option in the How did you hear about us? form field, you can make the field required.

  1. In the Sections directory, click cart-template.liquid. If your theme doesn't include a cart-template.liquid, then click cart.liquid in the Templates directory.

  2. Find the following novalidate attribute in the cart form code:

    novalidate
  3. Repla the novalidate attribute with the following code:

    {% unless settings.hau_form_validation %}novalidate{% endunless %}
  4. Click Save.

  5. In the theme editor, click Theme settings on the sidebar.

  6. Click the Hear About Us tab.

  7. Under Form Validation, make sure the Enable form validation setting is enabled.



特別聲明:以上文章內(nèi)容僅代表作者本人觀點,不代表ESG跨境電商觀點或立場。如有關(guān)于作品內(nèi)容、版權(quán)或其它問題請于作品發(fā)表后的30日內(nèi)與ESG跨境電商聯(lián)系。

搜索 放大鏡
韓國平臺交流群
加入
韓國平臺交流群
掃碼進群
歐洲多平臺交流群
加入
歐洲多平臺交流群
掃碼進群
美國賣家交流群
加入
美國賣家交流群
掃碼進群
ESG跨境專屬福利分享群
加入
ESG跨境專屬福利分享群
掃碼進群
拉美電商交流群
加入
拉美電商交流群
掃碼進群
亞馬遜跨境增長交流群
加入
亞馬遜跨境增長交流群
掃碼進群
亞馬遜跨境增長交流群
加入
亞馬遜跨境增長交流群
掃碼進群
拉美電商交流群
加入
拉美電商交流群
掃碼進群
ESG獨家招商-PHH GROUP賣家交流群
加入
ESG獨家招商-PHH GROUP賣家交流群
掃碼進群
《韓國平臺運營干貨包》
《波蘭allegro知識百科》
《Darty知識百科》
《法國Fnac知識百科》
《PEAKS 出海經(jīng)營方法論白皮書》
2025跨境電商營銷日歷
《2024年全球消費趨勢白皮書——美國篇》
《2024TikTok出海達人營銷白皮書》
《Coupang自注冊指南》
《eMAG知識百科》
通過ESG入駐平臺,您將解鎖
綠色通道,更高的入駐成功率
專業(yè)1v1客戶經(jīng)理服務(wù)
運營實操指導(dǎo)
運營提效資源福利
平臺官方專屬優(yōu)惠
聯(lián)系顧問

平臺顧問

平臺顧問 平臺顧問

微信掃一掃
馬上聯(lián)系在線顧問

icon icon

小程序

微信小程序

ESG跨境小程序
手機入駐更便捷

icon icon

返回頂部

【免費領(lǐng)取】全球跨境電商運營干貨 關(guān)閉
進行中
進行中
《韓國平臺運營干貨包》
包含四個韓國干貨報告:Coupang自注冊指南、GMK站內(nèi)推廣指南、韓國大促熱銷品詳細預(yù)測、韓國節(jié)日營銷全攻略
免費領(lǐng)取
進行中
進行中
TikTok運營必備干貨包
包含8個TikTok最新運營指南(市場趨勢、運營手冊、節(jié)日攻略等),官方出品,專業(yè)全面!
免費領(lǐng)取
進行中
進行中
韓國電商節(jié)日營銷指南
10+韓國電商重要營銷節(jié)點詳細解讀;全年度各節(jié)日熱度選品助力引爆訂單增長;8大節(jié)日營銷技巧輕松撬動大促流量密碼。
免費領(lǐng)取
進行中
進行中
【平臺干貨】eMAG知識百科
涵蓋從開店到大賣6個板塊:開店、運營、廣告、選品、上架、物流
免費領(lǐng)取
進行中
進行中
全球平臺詳解——全球合集
涵括全球100+個電商平臺的核心信息,包括平臺精煉簡介、競爭優(yōu)勢、熱銷品類、入駐要求以及入駐須知等關(guān)鍵內(nèi)容。
立即領(lǐng)取
進行中
進行中
韓國coupang平臺自注冊指南
韓國Coupang電商平臺從注冊準(zhǔn)備、提交申請到完成注冊,開店全流程詳細指引。
免費領(lǐng)取
進行中
進行中
2025跨境電商營銷日歷
包括傳統(tǒng)中、外重要節(jié)日及重點電商營銷節(jié)點還對營銷關(guān)鍵市場、選品輔以說明,讓你的365天安排的明明白白!
免費領(lǐng)取
進行中
進行中
全球平臺詳解——歐洲篇
涵蓋20+歐洲電商平臺,詳細解讀優(yōu)勢、入駐條件、熱銷品等
立即領(lǐng)取