├── .DS_Store ├── .gitignore ├── LICENSE ├── Online Store └── preferences │ └── google analytics │ └── funnel-reports.js ├── README.md ├── Templates ├── collection.amazon-product-feed--shoes.liquid ├── collection.csv-ga-product-feed-inc-colorsize.liquid ├── collection.csv-ga-product-feed.liquid ├── collection.fb-currency-feed.liquid ├── collection.fb-product-feed.liquid ├── collection.fb-product-update.liquid ├── collection.google-feed-update.liquid └── collection.xml-product-feed.liquid ├── settings └── checkout │ ├── adwords-conversion.liquid │ ├── adwords-remarketing.liquid │ ├── ga-ec-funnel-report.js │ ├── ga-new-customers.liquid │ ├── pinterest-conversion.liquid │ └── twitter-conversion.liquid └── snippets ├── adwords-remarketing.liquid ├── facebook-remarketing.liquid ├── pinterest-remarketing.liquid ├── product-color-swatch.liquid ├── seo-collection-dynamic-titles.liquid └── twitter-remarketing.liquid /.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Czarto/ShopifyScripts/ad65693f90cd60c9782abd2b37883a2a20704f94/.DS_Store -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | Templates/amazon.csv 3 | Templates/amazon.tsv 4 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2016 Alex Czartoryski 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /Online Store/preferences/google analytics/funnel-reports.js: -------------------------------------------------------------------------------- 1 | // Checkout steps for the Checkout Behavior report in Google Analytics from digitaldarts.com.au/analytics 2 | var ShopifyCheckoutstep = Shopify.Checkout.step; 3 | switch (ShopifyCheckoutstep) { 4 | case "contact_information": 5 | ga("require", "ec"); 6 | ga("ec:setAction", "checkout", { 7 | "step": 1, 8 | "option": "contact_information" 9 | }); 10 | ga('send', 'event', 'checkout', 'contact information', { nonInteraction: true }); 11 | break; 12 | case "shipping_method": 13 | ga("require", "ec"); 14 | ga("ec:setAction", "checkout", { 15 | "step": 2, 16 | "option": "shipping_method" 17 | }); 18 | ga('send', 'event', 'checkout', 'shipping method', { nonInteraction: true }); 19 | break; 20 | case "payment_method": 21 | ga("require", "ec"); 22 | ga("ec:setAction", "checkout", { 23 | "step": 3, 24 | "option": "payment_method" 25 | }); 26 | ga('send', 'event', 'checkout', 'payment', { nonInteraction: true }); 27 | }; 28 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Shopify Scripts, Templates, and Code 2 | 3 | Various useful scripts for Shopify stores 4 | 5 | ## Templates 6 | Various collection templates that output product data in a machine readable format (XML or CSV) 7 | 8 | - **Google Analytics Product Data Import** 9 | - https://github.com/Czarto/ShopifyScripts/blob/master/Templates/collection.csv-ga-product-feed-inc-colorsize.liquid 10 | - https://github.com/Czarto/ShopifyScripts/blob/master/Templates/collection.csv-ga-product-feed.liquid 11 | - Blog Post: Fix your GA Product Performance Reports 12 | 13 | - **Facebook Product Update Feed** 14 | - https://github.com/Czarto/ShopifyScripts/blob/master/Templates/collection.fb-product-update.liquid 15 | - Blog Post: Fix missing attributes in Shopify's Facebook Product Feed 16 | 17 | - **Google Shopping Update Feed** (including Sale Price) 18 | - https://github.com/Czarto/ShopifyScripts/blob/master/Templates/collection.google-feed-update.liquid 19 | - Blog Post: Enhance Shopify’s Google Shopping feed 20 | - *Augment your Google Shopping Feed with Sale Price, Additional Variant Images by color, Automatic Exclusion of Out of Stock varaints, and Intelligent Exclusion of Low Stock color variants.* 21 | 22 | ### Deprecated 23 | Old scripts and code that are no longer being maintained. 24 | 25 | - **Google Shopping Product Feed** [deprecated] 26 | - https://github.com/Czarto/ShopifyScripts/blob/master/Templates/collection.xml-product-feed.liquid 27 | - *Deprecated in favor of Shopify's native Google Shopping integration via the Google Shopping channel / app combined with feed enhancement with Enhance Shopify’s Google Shopping feed* 28 | 29 | - **Facebook Product Catalog Feed** [deprecated] 30 | - https://github.com/Czarto/ShopifyScripts/blob/master/Templates/collection.fb-product-feed.liquid 31 | - Blog Post: Shopify DIY Facebook Feed 32 | - *Depracted in favor of Shopify's native Facebook integration via the Facebook Sales Channel in combination with feed enhancement with Fix missing attributes in Shopify's Facebook Product Feed* 33 | 34 | ## Checkout Scripts 35 | Scripts to be included in the checkout script section in Shopify 36 | 37 | - **Google Ads Conversion + Remarketing Tracking Tag** 38 | - https://github.com/Czarto/ShopifyScripts/blob/master/settings/checkout/adwords-conversion.liquid 39 | 40 | 41 | ## Snippets 42 | Shopify code snippets 43 | 44 | - **Google Ads Dynamic Remarketing code** 45 | - https://github.com/Czarto/ShopifyScripts/blob/master/snippets/adwords-remarketing.liquid 46 | - Blog Post: Shopify Dynamic Remarketing Setup 47 | 48 | - **Collection page color swatches** 49 | - https://github.com/Czarto/ShopifyScripts/blob/master/snippets/product-color-swatch.liquid 50 | - Blog Post: Add Color Swatches to your Collection Page 51 | -------------------------------------------------------------------------------- /Templates/collection.amazon-product-feed--shoes.liquid: -------------------------------------------------------------------------------- 1 | {%- layout none -%} 2 | {%- paginate collection.products by 1000 -%} 3 | {%- liquid 4 | 5 | assign brand_name = 'Manitobah' 6 | assign manufacturer = 'Manitobah' 7 | assign manufacturer_contact_information = 'Blue Moose Clothing Company Ltd, 401-25 Forks Market Road, Winnipeg, MB R3C 4S8 Tel +1-855-685-5857' 8 | 9 | assign update_delete = 'Update' 10 | assign currency_code = cart.currency.iso_code 11 | assign price_adjustment = 1.05 12 | 13 | assign batteries_required = 'no' 14 | assign are_batteries_included = false 15 | assign contains_liquid_contents = 'no' 16 | 17 | assign fulfillment_center_id = 'AMAZON_NA' 18 | assign package_height = '5' 19 | assign package_width = '10' 20 | assign package_length = '13.25' 21 | assign package_weight = '1' 22 | assign package_length_unit_of_measure = 'in' 23 | assign package_height_unit_of_measure = 'in' 24 | assign package_width_unit_of_measure = 'in' 25 | assign package_weight_unit_of_measure = 'lb' 26 | assign item_package_quantity = 1 27 | 28 | -%} 29 | TemplateType=fptcustom Version=2024.0502 Category=shoes TemplateSignature=U0xJUFBFUixTQU5EQUwsVEVDSE5JQ0FMX1NQT1JUX1NIT0UsU0hPRVMsQk9PVCxTSE9FX0FDQ0VTU09SWSxIQU5EQkFH settings=attributeRow=3&contentLanguageTag=en_CA&dataRow=4&feedType=113&headerLanguageTag=en_CA&isEdit=false&isProcessingSummary=false&labelRow=2&primaryMarketplaceId=amzn1.mp.o.A2EUQ1WTGCTBG2&reportProvenance=false&templateIdentifier=c01ab600-e6d4-4292-98c7-16e1da48eeac×tamp=2024-05-02T00%3A39%3A50.822Z " Use ENGLISH to fill in this template. DO NOT modify or delete the coloured header rows. To expand all optional columns, click the ""2"" button on the top left." Images Variation Discovery Product Enrichment Dimensions Fulfillment Compliance Offer 30 | Product Type Seller SKU Brand Update Delete Product Name Product Description Product ID Recommended Browse Nodes Product ID Type Style Number Sole Material Heel Type Item Type Model Name Manufacturer Part Number Manufacturer Heel Height Unit Of Measure Heel Height Footwear Size System Shoe Size Age Group Shoe Size Gender Shoe Size Class Shoe Size Width Shoe Size Shoe Size To Range (If Range) Shoe Size Gender (If Unisex) Shoe Size Width (If Unisex) Shoe Size (If Unisex) Shoe Size To Range (If Unisex and Range) Standard Price Quantity Outer Material Type Model Year Heel Height Closure Type Product Care Instructions Target Gender Age Range Description Main Image URL Other Image Url1 Other Image Url2 Other Image Url3 Other Image Url4 Other Image Url5 Other Image Url6 Other Image Url7 Other Image Url8 Swatch Image URL Parentage Parent SKU Relationship Type Variation Theme Style Name Key Product Features Key Product Features Key Product Features Key Product Features Key Product Features Search Terms Toe Style Arch Type Department Department Department Department Department Department Department Department Department Department Color Color Map Material Fabric Fur Description Pattern Style Water Resistance Level Occasion Lifestyle Occasion Lifestyle Occasion Lifestyle Occasion Lifestyle Occasion Lifestyle Additional Features Additional Features Additional Features Additional Features Additional Features Item Type manufacturer_contact_information Lining Description League Name Product Lifecycle Supply Type Product Lifecycle Supply Type Product Lifecycle Supply Type Product Lifecycle Supply Type Product Lifecycle Supply Type Item Booking Date Minimum Circumference Unit of Measure Season of the Product Collection Target Audience Target Audience Target Audience Target Audience Target Audience Pronation Correction Special Size Type shaft_style_type Catalog Number Style Keyword Team Name Boot Opening Circumference is-stain-resistant Country/Region as Labeled Platinum Keywords Platinum Keywords Platinum Keywords Platinum Keywords Platinum Keywords Size Shaft Circumference Shaft Circumference Unit Autographed Athlete Weave Type Shoulder Strap Drop Shoulder Strap Drop Unit Of Measure Occasion Type Sport Type Sport Type Frame Material Type Fit Type Theme Included Components Pattern character Duration Unit Duration flash_point_unit_of_measure Built-in Light Shaft Diameter Shoe Safety Code ISO-20345 Surface Recommendation Insole Type Cleat Description Cleat Material Type Strap Type Sub Brand Shaft Diameter Unit Shoe Dimension Unit Of Measure Certifying Authority Name Geographic Jurisdiction opacity_unit_of_measure Size Display Name Sleeve Type Fabric Wash Height Map Size Map Liquid Volume Liquid Volume Unit of Measure Width Item Display Height Unit Of Measure Item Display Width Unit Of Measure Display Height Maximum Girth Size Shoe Width Maximum Circumference Unit of Measure Shipping Weight Website Shipping Weight Unit Of Measure Shaft Height Platform Height Item Length Unit Of Measure Item Length Item Width Item Height Shaft Height Unit Of Measure Item Width Unit Of Measure Item Height Unit Of Measure Shoe Width Unit Of Measure Capacity Unit Of Measure Screen Size Display Size Unit Of Measure Capacity Fulfillment Center ID Package height Package Width Package Length Package Length Unit Of Measure Package Weight Package Weight Unit Of Measure Package Height Unit Of Measure Package Width Unit Of Measure Compliance Regulation Type Compliance Regulation Type Compliance Regulation Type Compliance Regulation Type Compliance Regulation Type Regulatory Identification Regulatory Identification Regulatory Identification Regulatory Identification Regulatory Identification Cpsia Warning Cpsia Warning Cpsia Warning Cpsia Warning Country/Region of Origin item_weight_unit_of_measure Item Weight Is this product a battery or does it utilize batteries? Batteries are Included Battery composition Battery type/size Battery type/size Battery type/size Number of batteries Number of batteries Number of batteries Battery weight (grams) battery_weight_unit_of_measure Number of Lithium Metal Cells Number of Lithium-ion Cells Lithium Battery Packaging Watt hours per battery lithium_battery_energy_content_unit_of_measure Lithium content (grams) lithium_battery_weight_unit_of_measure Applicable Dangerous Goods Regulations Applicable Dangerous Goods Regulations Applicable Dangerous Goods Regulations Applicable Dangerous Goods Regulations Applicable Dangerous Goods Regulations UN number Safety Data Sheet (SDS) URL Volume item_volume_unit_of_measure Contains Liquid Contents? Certification Expiration Date Flash point (�C)? Manufacturer Warranty Description Certification Date of Issue External Testing Certification Material/Fabric Regulations Material/Fabric Regulations Material/Fabric Regulations Certification Metadata Product Compliance Certificate Categorization/GHS pictograms (select all that apply) Categorization/GHS pictograms (select all that apply) Categorization/GHS pictograms (select all that apply) Legal Disclaimer Safety Warning Fabric Type Import Designation CPSIA Warning Description Regulatory Organization Name Product Compliance Certificate Manufacturer's Suggested Retail Price Currency Product Tax Code Handling Time Release Date Restock Date Sale Price Sale Start Date Sale End Date Offering Can Be Gift Messaged Is Gift Wrap Available Minimum Advertised Price Offer End Date Max Order Quantity Shipping-Template Offer Start Date Item Condition Condition Note Number of Items Launch Date Max Aggregate Ship Quantity Item Package Quantity Is Discontinued by Manufacturer? 31 | feed_product_type item_sku brand_name update_delete item_name product_description external_product_id recommended_browse_nodes external_product_id_type model sole_material heel_type item_type model_name part_number manufacturer heel_height_unit_of_measure heel_height_string footwear_size_system footwear_age_group footwear_gender footwear_size_class footwear_width footwear_size footwear_to_size footwear_gender_unisex footwear_width_unisex footwear_size_unisex footwear_to_size_unisex standard_price quantity outer_material_type model_year heel_height closure_type care_instructions target_gender age_range_description main_image_url other_image_url1 other_image_url2 other_image_url3 other_image_url4 other_image_url5 other_image_url6 other_image_url7 other_image_url8 swatch_image_url parent_child parent_sku relationship_type variation_theme style_name bullet_point1 bullet_point2 bullet_point3 bullet_point4 bullet_point5 generic_keywords toe_style arch_type department_name1 department_name2 department_name3 department_name4 department_name5 department_name6 department_name7 department_name8 department_name9 department_name10 color_name color_map material_type fur_description pattern_type water_resistance_level lifestyle1 lifestyle2 lifestyle3 lifestyle4 lifestyle5 special_features1 special_features2 special_features3 special_features4 special_features5 item_type_name manufacturer_contact_information lining_description league_name lifecycle_supply_type1 lifecycle_supply_type2 lifecycle_supply_type3 lifecycle_supply_type4 lifecycle_supply_type5 item_booking_date minimum_circumference_unit_of_measure seasons collection_name target_audience_keywords1 target_audience_keywords2 target_audience_keywords3 target_audience_keywords4 target_audience_keywords5 pronation_correction special_size_type shaft_style_type catalog_number style_keywords team_name minimum_circumference is_stain_resistant country_as_labeled platinum_keywords1 platinum_keywords2 platinum_keywords3 platinum_keywords4 platinum_keywords5 size_name shaft_circumference shaft_circumference_unit_of_measure is_autographed athlete weave_type shoulder_strap_drop shoulder_strap_drop_unit_of_measure occasion_type sport_type1 sport_type2 frame_material_type fit_type theme included_components pattern_name subject_character duration_unit_of_measure duration flash_point_unit_of_measure has_builtin_light shaft_diameter shoe_safety_code_iso_20345 surface_recommendation insole_type cleat_description cleat_material_type strap_type sub_brand_name shaft_diameter_unit_of_measure shoe_dimension_unit_of_measure legal_compliance_certification_certifying_authority_name legal_compliance_certification_geographic_jurisdiction opacity_unit_of_measure size_info_display_name sleeve_type fabric_wash height_map size_map liquid_volume liquid_volume_unit_of_measure item_display_width item_display_height_unit_of_measure item_display_width_unit_of_measure item_display_height maximum_circumference shoe_width maximum_circumference_unit_of_measure website_shipping_weight website_shipping_weight_unit_of_measure shaft_height platform_height item_length_unit_of_measure item_length item_width item_height shaft_height_unit_of_measure item_width_unit_of_measure item_height_unit_of_measure shoe_width_unit_of_measure capacity_unit_of_measure display_size display_size_unit_of_measure capacity fulfillment_center_id package_height package_width package_length package_length_unit_of_measure package_weight package_weight_unit_of_measure package_height_unit_of_measure package_width_unit_of_measure regulation_type1 regulation_type2 regulation_type3 regulation_type4 regulation_type5 regulatory_compliance_certification_value1 regulatory_compliance_certification_value2 regulatory_compliance_certification_value3 regulatory_compliance_certification_value4 regulatory_compliance_certification_value5 cpsia_cautionary_statement1 cpsia_cautionary_statement2 cpsia_cautionary_statement3 cpsia_cautionary_statement4 country_of_origin item_weight_unit_of_measure item_weight batteries_required are_batteries_included battery_cell_composition battery_type1 battery_type2 battery_type3 number_of_batteries1 number_of_batteries2 number_of_batteries3 battery_weight battery_weight_unit_of_measure number_of_lithium_metal_cells number_of_lithium_ion_cells lithium_battery_packaging lithium_battery_energy_content lithium_battery_energy_content_unit_of_measure lithium_battery_weight lithium_battery_weight_unit_of_measure supplier_declared_dg_hz_regulation1 supplier_declared_dg_hz_regulation2 supplier_declared_dg_hz_regulation3 supplier_declared_dg_hz_regulation4 supplier_declared_dg_hz_regulation5 hazmat_united_nations_regulatory_id safety_data_sheet_url item_volume item_volume_unit_of_measure contains_liquid_contents legal_compliance_certification_expiration_date flash_point warranty_description legal_compliance_certification_date_of_issue external_testing_certification supplier_declared_material_regulation1 supplier_declared_material_regulation2 supplier_declared_material_regulation3 legal_compliance_certification_metadata legal_compliance_certification_value ghs_classification_class1 ghs_classification_class2 ghs_classification_class3 legal_disclaimer_description safety_warning fabric_type import_designation cpsia_cautionary_description legal_compliance_certification_regulatory_organization_name legal_compliance_certification_status list_price currency product_tax_code fulfillment_latency merchant_release_date restock_date sale_price sale_from_date sale_end_date offering_can_be_gift_messaged offering_can_be_giftwrapped map_price offering_end_date max_order_quantity merchant_shipping_group_name offering_start_date condition_type condition_note number_of_items product_site_launch_date max_aggregate_ship_quantity item_package_quantity is_discontinued_by_manufacturer 32 | {%- comment -%}Need this here to add a line break{% endcomment %} 33 | {%- for product in collection.products -%} 34 | {%- liquid 35 | assign model_name = product.title | replace: ',','' | remove: '"' | remove: "'" | remove: "," | strip_html | strip 36 | 37 | # Item Name 38 | assign item_name = model_name 39 | unless item_name contains product.type 40 | assign item_name = item_name | append: ' ' | append: product.type 41 | endunless 42 | case model_name 43 | when 'Tipi' 44 | assign item_name = item_name | replace: 'Moccasin', 'Slipper' 45 | endcase 46 | 47 | # Description 48 | assign product_description = product.description | strip_html | strip_newlines | escape | remove: "," | truncate: 2000 49 | if product.metafields.global.description_tag.size > 0 50 | assign product_description = product.metafields.global.description_tag | remove: "," 51 | endif 52 | 53 | assign footwear_size_system = 'US Footwear Size System' 54 | assign footwear_age_group = 'adult' 55 | assign age_range_description = footwear_age_group 56 | assign footwear_width = 'Medium' 57 | assign footwear_width_unisex = '' 58 | assign footwear_size_class = 'Numeric' 59 | assign footwear_size_unisex = '' 60 | assign footwear_gender = '' 61 | assign footwear_gender_unisex = '' 62 | assign target_gender = '' 63 | 64 | # Outer Material Type 65 | assign outer_material_type = 'leather' 66 | assign product_specs_metafield = product.metafields.custom.accordion_specs | metafield_text 67 | if product_specs_metafield contains 'Materials: Cowhide Suede' 68 | assign outer_material_type = 'suede' 69 | endif 70 | 71 | 72 | 73 | # Product Type, Item Type, Item Type Name, etc... 74 | assign item_type = 'Shoes' 75 | assign item_type_name = '' 76 | assign feed_product_type = 'none' 77 | assign sole_material = '' 78 | case product.type 79 | when 'Mukluk' 80 | assign feed_product_type = 'boot' 81 | when 'Slipper' 82 | assign feed_product_type = 'slipper' 83 | assign item_type = 'slipper' 84 | assign item_type_name = 'slipper' 85 | when 'Moccasin' 86 | assign feed_product_type = 'shoes' 87 | assign item_type = 'shoes' 88 | assign item_type_name = 'moccasin' 89 | assign sole_material = 'Rubber' 90 | 91 | when 'Shoes' 92 | assign feed_product_type = 'shoes' 93 | assign item_type = 'shoes' 94 | assign item_type_name = 'moccasin' 95 | assign sole_material = 'Rubber' 96 | 97 | endcase 98 | case model_name 99 | when 'Tipi' 100 | assign feed_product_type = 'slipper' 101 | assign item_type = 'slipper' 102 | assign item_type_name = 'slipper' 103 | assign sole_material = 'Leather' 104 | assign outer_material_type = 'suede' 105 | endcase 106 | 107 | # Special Features 108 | assign special_features1 = 'Breathable' 109 | assign special_features2 = 'Flexible' 110 | assign special_features3 = 'Lightweight' 111 | 112 | 113 | # Clear product id type for Parent nodes 114 | assign external_product_id = '' 115 | assign external_product_id_type = '' 116 | 117 | # Clear price for Parent Node 118 | assign standard_price = '' 119 | assign list_price = '' 120 | 121 | # Parent's Item SKU 122 | assign item_sku = product.first_available_variant.sku | slice: 0, 5 123 | assign parent_child = 'parent' 124 | assign parent_sku = '' 125 | assign relationship_type = '' 126 | assign variation_theme = 'color-size' 127 | assign model_number = '' 128 | assign color_name = '' 129 | assign color_map = '' 130 | 131 | # Parent's Image 132 | assign main_image_url = product.featured_image | image_url: width: 2000 | prepend: "https:" 133 | assign other_image_url1 = '' 134 | assign other_image_url2 = '' 135 | assign other_image_url3 = '' 136 | assign other_image_url4 = '' 137 | assign other_image_url5 = '' 138 | assign other_image_url6 = '' 139 | assign other_image_url7 = '' 140 | assign other_image_url8 = '' 141 | 142 | # Parent's Recommended Browse Node 143 | for option in product.options 144 | if option == 'Size' 145 | assign footwear_size = product.first_available_variant.options[forloop.index0] 146 | endif 147 | endfor 148 | assign recommended_browse_nodes = 7141124011 149 | if footwear_size contains 'Ladies' 150 | assign footwear_gender = 'Women' 151 | case feed_product_type 152 | when 'boot' 153 | assign recommended_browse_nodes = 679380011 154 | when 'slipper' 155 | assign recommended_browse_nodes = 679433011 156 | when 'shoes' 157 | assign recommended_browse_nodes = 679337011 158 | endcase 159 | elsif footwear_size contains 'Mens' 160 | assign footwear_gender = 'Men' 161 | case feed_product_type 162 | when 'boot' 163 | assign recommended_browse_nodes = 5658904011 164 | when 'slipper' 165 | assign recommended_browse_nodes = 679324011 166 | when 'shoes' 167 | assign recommended_browse_nodes = 679313011 168 | endcase 169 | endif 170 | assign footwear_size = 5 171 | assign footwear_to_size = '' 172 | 173 | -%} 174 | {%- if product.variants.size > 1 -%} 175 | {{ feed_product_type }} {{ item_sku }} {{ brand_name }} {{ update_delete }} {{ item_name }} {{ product_description }} {{ external_product_id }} {{ recommended_browse_nodes }} {{ external_product_id_type }} {{ model_number }} {{ sole_material }} {{heel_type}} {{item_type}} {{model_name}} {{part_number}} {{manufacturer}} {{heel_height_unit_of_measure}} {{ heel_height_string }} {{ footwear_size_system }} {{footwear_age_group}} {{footwear_gender}} {{footwear_size_class}} {{footwear_width}} {{footwear_size}} {{footwear_to_size}} {{footwear_gender_unisex}} {{footwear_width_unisex}} {{footwear_size_unisex}} {{footwear_to_size_unisex}} {{standard_price}} {{quantity_available}} {{outer_material_type}} {{model_year}} {{heel_height}} {{closure_type}} {{care_instructions}} {{target_gender}} {{age_range_description}} {{main_image_url}} {{other_image_url1}} {{other_image_url2}} {{other_image_url3}} {{other_image_url4}} {{other_image_url5}} {{other_image_url6}} {{other_image_url7}} {{other_image_url8}} {{swatch_image_url}} {{parent_child}} {{parent_sku}} {{relationship_type}} {{variation_theme}} {{style_name}} {{bullet_point1}} {{bullet_point2}} {{bullet_point3}} {{bullet_point4}} {{bullet_point5}} {{generic_keywords}} {{toe_style}} {{arch_type}} {{department_name1}} {{department_name2}} {{department_name3}} {{department_name4}} {{department_name5}} {{department_name6}} {{department_name7}} {{department_name8}} {{department_name9}} {{department_name10}} {{color_name}} {{color_map}} {{material_type}} {{fur_description}} {{pattern_type}} {{water_resistance_level}} {{lifestyle1}} {{lifestyle2}} {{lifestyle3}} {{lifestyle4}} {{lifestyle5}} {{special_features1}} {{special_features2}} {{special_features3}} {{special_features4}} {{special_features5}} {{item_type_name}} {{manufacturer_contact_information}} {{lining_description}} {{league_name}} {{lifecycle_supply_type1}} {{lifecycle_supply_type2}} {{lifecycle_supply_type3}} {{lifecycle_supply_type4}} {{lifecycle_supply_type5}} {{item_booking_date}} {{minimum_circumference_unit_of_measure}} {{seasons}} {{collection_name}} {{target_audience_keywords1}} {{target_audience_keywords2}} {{target_audience_keywords3}} {{target_audience_keywords4}} {{target_audience_keywords5}} {{pronation_correction}} {{special_size_type}} {{shaft_style_type}} {{catalog_number}} {{style_keywords}} {{team_name}} {{minimum_circumference}} {{is_stain_resistant}} {{country_as_labeled}} {{platinum_keywords1}} {{platinum_keywords2}} {{platinum_keywords3}} {{platinum_keywords4}} {{platinum_keywords5}} {{size_name}} {{shaft_circumference}} {{shaft_circumference_unit_of_measure}} {{is_autographed}} {{athlete}} {{weave_type}} {{shoulder_strap_drop}} {{shoulder_strap_drop_unit_of_measure}} {{occasion_type}} {{sport_type1}} {{sport_type2}} {{frame_material_type}} {{fit_type}} {{theme_theme}} {{included_components}} {{pattern_name}} {{subject_character}} {{duration_unit_of_measure}} {{duration}} {{flash_point_unit_of_measure}} {{has_builtin_light}} {{shaft_diameter}} {{shoe_safety_code_iso_20345}} {{surface_recommendation}} {{insole_type}} {{cleat_description}} {{cleat_material_type}} {{strap_type}} {{sub_brand_name}} {{shaft_diameter_unit_of_measure}} {{shoe_dimension_unit_of_measure}} {{legal_compliance_certification_certifying_authority_name}} {{legal_compliance_certification_geographic_jurisdiction}} {{opacity_unit_of_measure}} {{size_info_display_name}} {{sleeve_type}} {{fabric_wash}} {{height_map}} {{size_map}} {{liquid_volume}} {{liquid_volume_unit_of_measure}} {{item_display_width}} {{item_display_height_unit_of_measure}} {{item_display_width_unit_of_measure}} {{item_display_height}} {{maximum_circumference}} {{shoe_width}} {{maximum_circumference_unit_of_measure}} {{website_shipping_weight}} {{website_shipping_weight_unit_of_measure}} {{shaft_height}} {{platform_height}} {{item_length_unit_of_measure}} {{item_length}} {{item_width}} {{item_height}} {{shaft_height_unit_of_measure}} {{item_width_unit_of_measure}} {{item_height_unit_of_measure}} {{shoe_width_unit_of_measure}} {{capacity_unit_of_measure}} {{display_size}} {{display_size_unit_of_measure}} {{capacity}} {{fulfillment_center_id}} {{package_height}} {{package_width}} {{package_length}} {{package_length_unit_of_measure}} {{package_weight}} {{package_weight_unit_of_measure}} {{package_height_unit_of_measure}} {{package_width_unit_of_measure}} {{regulation_type1}} {{regulation_type2}} {{regulation_type3}} {{regulation_type4}} {{regulation_type5}} {{regulatory_compliance_certification_value1}} {{regulatory_compliance_certification_value2}} {{regulatory_compliance_certification_value3}} {{regulatory_compliance_certification_value4}} {{regulatory_compliance_certification_value5}} {{cpsia_cautionary_statement1}} {{cpsia_cautionary_statement2}} {{cpsia_cautionary_statement3}} {{cpsia_cautionary_statement4}} {{country_of_origin}} {{item_weight_unit_of_measure}} {{item_weight}} {{batteries_required}} {{are_batteries_included}} {{battery_cell_composition}} {{battery_type1}} {{battery_type2}} {{battery_type3}} {{number_of_batteries1}} {{number_of_batteries2}} {{number_of_batteries3}} {{battery_weight}} {{battery_weight_unit_of_measure}} {{number_of_lithium_metal_cells}} {{number_of_lithium_ion_cells}} {{lithium_battery_packaging}} {{lithium_battery_energy_content}} {{lithium_battery_energy_content_unit_of_measure}} {{lithium_battery_weight}} {{lithium_battery_weight_unit_of_measure}} {{supplier_declared_dg_hz_regulation1}} {{supplier_declared_dg_hz_regulation2}} {{supplier_declared_dg_hz_regulation3}} {{supplier_declared_dg_hz_regulation4}} {{supplier_declared_dg_hz_regulation5}} {{hazmat_united_nations_regulatory_id}} {{safety_data_sheet_url}} {{item_volume}} {{item_volume_unit_of_measure}} {{contains_liquid_contents}} {{legal_compliance_certification_expiration_date}} {{flash_point}} {{warranty_description}} {{legal_compliance_certification_date_of_issue}} {{external_testing_certification}} {{supplier_declared_material_regulation1}} {{supplier_declared_material_regulation2}} {{supplier_declared_material_regulation3}} {{legal_compliance_certification_metadata}} {{legal_compliance_certification_value}} {{ghs_classification_class1}} {{ghs_classification_class2}} {{ghs_classification_class3}} {{legal_disclaimer_description}} {{safety_warning}} {{fabric_type}} {{import_designation}} {{cpsia_cautionary_description}} {{legal_compliance_certification_regulatory_organization_name}} {{legal_compliance_certification_status}} {{list_price}} {{currency_code}} {{product_tax_code}} {{fulfillment_latency}} {{merchant_release_date}} {{restock_date}} {{sale_price}} {{sale_from_date}} {{sale_end_date}} {{offering_can_be_gift_messaged}} {{offering_can_be_giftwrapped}} {{map_price}} {{offering_end_date}} {{max_order_quantity}} {{merchant_shipping_group_name}} {{offering_start_date}} {{condition_type}} {{condition_note}} {{number_of_items}} {{product_site_launch_date}} {{max_aggregate_ship_quantity}} {{item_package_quantity}} {{is_discontinued_by_manufacturer}} 176 | {%- endif -%} 177 | {%- liquid 178 | 179 | # Parent SKU 180 | assign parent_sku = item_sku 181 | assign parent_child = 'child' 182 | assign relationship_type = 'Variation' 183 | assign variation_theme = 'color-size' 184 | 185 | # Set Product Id type for child nodes 186 | assign external_product_id_type = 'UPC' 187 | 188 | -%} 189 | {%- for variant in product.variants -%} 190 | {%- liquid 191 | 192 | # Reset values 193 | assign item_name = model_name | append: ' ' | append: variant.title 194 | assign item_sku = variant.sku 195 | assign external_product_id = variant.barcode 196 | assign footwear_size_system = 'US Footwear Size System' 197 | assign footwear_width = 'Medium' 198 | assign footwear_size_class = 'Numeric' 199 | assign footwear_size = '' 200 | assign footwear_to_size = '' 201 | assign color_name = '' 202 | assign color_map = '' 203 | 204 | # TODO: on sale logic 205 | # assign sale_price = variant.price | money_without_currency 206 | assign standard_price = variant.price | times: price_adjustment | money_without_currency 207 | assign list_price = variant.compare_at_price | money_without_currency 208 | assign quantity_available = '' 209 | assign item_weight_unit_of_measure = variant.weight_unit 210 | assign item_weight = variant.weight_in_unit 211 | assign condition_type = 'New' 212 | 213 | # Color and Size data 214 | # TODO: Color Map 215 | for option in product.options 216 | if option == 'Color' or option == 'Colour' 217 | assign color_name = variant.options[forloop.index0] 218 | elsif option == 'Size' 219 | assign variantSizes = variant.options[forloop.index0] | split: ' ' 220 | endif 221 | endfor 222 | 223 | # Outer Material Type 224 | if color_name contains 'Suede' 225 | assign outer_material_type = 'suede' 226 | endif 227 | 228 | # Footwear size and gender values 229 | assign footwear_gender_unisex = '' 230 | assign footwear_size_unisex = '' 231 | assign footwear_width_unisex = '' 232 | assign footwear_size = '' 233 | assign target_gender = '' 234 | 235 | assign footwear_size = variantSizes[1] 236 | 237 | if variantSizes.first == 'Ladies' 238 | assign footwear_gender = 'Women' 239 | assign target_gender = 'Female' 240 | 241 | if variantSizes.size > 2 242 | assign footwear_gender_unisex = 'Men' 243 | assign target_gender = 'Unisex' 244 | assign footwear_size_unisex = variantSizes[4] 245 | assign footwear_width_unisex = "Medium" 246 | endif 247 | elsif variantSizes.first == 'Mens' 248 | assign footwear_gender = 'Men' 249 | assign target_gender = 'Male' 250 | endif 251 | 252 | # Recommended Browse Nodes 253 | assign recommended_browse_nodes = 7141124011 254 | case feed_product_type 255 | when 'boot' 256 | case footwear_gender 257 | when 'Women' 258 | assign recommended_browse_nodes = 679380011 259 | when 'Men' 260 | assign recommended_browse_nodes = 5658904011 261 | endcase 262 | when 'slipper' 263 | case footwear_gender 264 | when 'Women' 265 | assign recommended_browse_nodes = 679433011 266 | when 'Men' 267 | assign recommended_browse_nodes = 679324011 268 | endcase 269 | when 'shoes' 270 | case footwear_gender 271 | when 'Women' 272 | assign recommended_browse_nodes = 679337011 273 | when 'Men' 274 | assign recommended_browse_nodes = 679313011 275 | endcase 276 | endcase 277 | 278 | 279 | assign model_number = variant.sku 280 | 281 | # Main Variant Image 282 | # TODO: Include Video if present 283 | if variant.image 284 | assign main_image_url = variant.image | image_url: width: 2000 | prepend: "https:" 285 | else 286 | assign main_image_url = product.featured_image | image_url: width: 2000 | prepend: "https:" 287 | endif 288 | 289 | # Image ALT text must exactly match variant color for images to be matched 290 | assign variantOtherImages = product.images | where: "alt", color_name | sort: 'attached_to_variant' | reverse 291 | 292 | assign other_image_url1 = '' 293 | assign other_image_url2 = '' 294 | assign other_image_url3 = '' 295 | assign other_image_url4 = '' 296 | assign other_image_url5 = '' 297 | assign other_image_url6 = '' 298 | assign other_image_url7 = '' 299 | assign other_image_url8 = '' 300 | 301 | if variantOtherImages[1] 302 | assign other_image_url1 = variantOtherImages[1] | image_url: width: 2000 | prepend: "https:" 303 | endif 304 | if variantOtherImages[2] 305 | assign other_image_url2 = variantOtherImages[2] | image_url: width: 2000 | prepend: "https:" 306 | endif 307 | if variantOtherImages[3] 308 | assign other_image_url3 = variantOtherImages[3] | image_url: width: 2000 | prepend: "https:" 309 | endif 310 | if variantOtherImages[4] 311 | assign other_image_url4 = variantOtherImages[4] | image_url: width: 2000 | prepend: "https:" 312 | endif 313 | if variantOtherImages[5] 314 | assign other_image_url5 = variantOtherImages[5] | image_url: width: 2000 | prepend: "https:" 315 | endif 316 | if variantOtherImages[6] 317 | assign other_image_url6 = variantOtherImages[6] | image_url: width: 2000 | prepend: "https:" 318 | endif 319 | if variantOtherImages[7] 320 | assign other_image_url7 = variantOtherImages[7] | image_url: width: 2000 | prepend: "https:" 321 | endif 322 | if variantOtherImages[8] 323 | assign other_image_url8 = variantOtherImages[8] | image_url: width: 2000 | prepend: "https:" 324 | endif 325 | -%} 326 | {%- unless feed_product_type == 'none' -%} 327 | {%- # feed_product_type item_sku brand_name update_delete item_name product_description external_product_id recommended_browse_nodes external_product_id_type model sole_material heel_type item_type model_name part_number manufacturer heel_height_unit_of_measure heel_height_string footwear_size_system footwear_age_group footwear_gender footwear_size_class footwear_width footwear_size footwear_to_size footwear_gender_unisex footwear_width_unisex footwear_size_unisex footwear_to_size_unisex standard_price quantity outer_material_type model_year heel_height closure_type care_instructions target_gender age_range_description main_image_url other_image_url1 other_image_url2 other_image_url3 other_image_url4 other_image_url5 other_image_url6 other_image_url7 other_image_url8 swatch_image_url parent_child parent_sku relationship_type variation_theme style_name bullet_point1 bullet_point2 bullet_point3 bullet_point4 bullet_point5 generic_keywords toe_style arch_type department_name1 department_name2 department_name3 department_name4 department_name5 department_name6 department_name7 department_name8 department_name9 department_name10 color_name color_map material_type fur_description pattern_type water_resistance_level lifestyle1 lifestyle2 lifestyle3 lifestyle4 lifestyle5 special_features1 special_features2 special_features3 special_features4 special_features5 item_type_name manufacturer_contact_information lining_description league_name lifecycle_supply_type1 lifecycle_supply_type2 lifecycle_supply_type3 lifecycle_supply_type4 lifecycle_supply_type5 item_booking_date minimum_circumference_unit_of_measure seasons collection_name target_audience_keywords1 target_audience_keywords2 target_audience_keywords3 target_audience_keywords4 target_audience_keywords5 pronation_correction special_size_type shaft_style_type catalog_number style_keywords team_name minimum_circumference is_stain_resistant country_as_labeled platinum_keywords1 platinum_keywords2 platinum_keywords3 platinum_keywords4 platinum_keywords5 size_name shaft_circumference shaft_circumference_unit_of_measure is_autographed athlete weave_type shoulder_strap_drop shoulder_strap_drop_unit_of_measure occasion_type sport_type1 sport_type2 frame_material_type fit_type theme included_components pattern_name subject_character duration_unit_of_measure duration flash_point_unit_of_measure has_builtin_light shaft_diameter shoe_safety_code_iso_20345 surface_recommendation insole_type cleat_description cleat_material_type strap_type sub_brand_name shaft_diameter_unit_of_measure shoe_dimension_unit_of_measure legal_compliance_certification_certifying_authority_name legal_compliance_certification_geographic_jurisdiction opacity_unit_of_measure size_info_display_name sleeve_type fabric_wash height_map size_map liquid_volume liquid_volume_unit_of_measure item_display_width item_display_height_unit_of_measure item_display_width_unit_of_measure item_display_height maximum_circumference shoe_width maximum_circumference_unit_of_measure website_shipping_weight website_shipping_weight_unit_of_measure shaft_height platform_height item_length_unit_of_measure item_length item_width item_height shaft_height_unit_of_measure item_width_unit_of_measure item_height_unit_of_measure shoe_width_unit_of_measure capacity_unit_of_measure display_size display_size_unit_of_measure capacity fulfillment_center_id package_height package_width package_length package_length_unit_of_measure package_weight package_weight_unit_of_measure package_height_unit_of_measure package_width_unit_of_measure regulation_type1 regulation_type2 regulation_type3 regulation_type4 regulation_type5 regulatory_compliance_certification_value1 regulatory_compliance_certification_value2 regulatory_compliance_certification_value3 regulatory_compliance_certification_value4 regulatory_compliance_certification_value5 cpsia_cautionary_statement1 cpsia_cautionary_statement2 cpsia_cautionary_statement3 cpsia_cautionary_statement4 country_of_origin item_weight_unit_of_measure item_weight batteries_required are_batteries_included battery_cell_composition battery_type1 battery_type2 battery_type3 number_of_batteries1 number_of_batteries2 number_of_batteries3 battery_weight battery_weight_unit_of_measure number_of_lithium_metal_cells number_of_lithium_ion_cells lithium_battery_packaging lithium_battery_energy_content lithium_battery_energy_content_unit_of_measure lithium_battery_weight lithium_battery_weight_unit_of_measure supplier_declared_dg_hz_regulation1 supplier_declared_dg_hz_regulation2 supplier_declared_dg_hz_regulation3 supplier_declared_dg_hz_regulation4 supplier_declared_dg_hz_regulation5 hazmat_united_nations_regulatory_id safety_data_sheet_url item_volume item_volume_unit_of_measure contains_liquid_contents legal_compliance_certification_expiration_date flash_point warranty_description legal_compliance_certification_date_of_issue external_testing_certification supplier_declared_material_regulation1 supplier_declared_material_regulation2 supplier_declared_material_regulation3 legal_compliance_certification_metadata legal_compliance_certification_value ghs_classification_class1 ghs_classification_class2 ghs_classification_class3 legal_disclaimer_description safety_warning fabric_type import_designation cpsia_cautionary_description legal_compliance_certification_regulatory_organization_name legal_compliance_certification_status list_price currency product_tax_code fulfillment_latency merchant_release_date restock_date sale_price sale_from_date sale_end_date offering_can_be_gift_messaged offering_can_be_giftwrapped map_price offering_end_date max_order_quantity merchant_shipping_group_name offering_start_date condition_type condition_note number_of_items product_site_launch_date max_aggregate_ship_quantity item_package_quantity is_discontinued_by_manufacturer -%} 328 | {{ feed_product_type }} {{ item_sku }} {{ brand_name }} {{ update_delete }} {{ item_name }} {{ product_description }} {{ external_product_id }} {{ recommended_browse_nodes }} {{ external_product_id_type }} {{ model_number }} {{ sole_material }} {{heel_type}} {{item_type}} {{model_name}} {{part_number}} {{manufacturer}} {{heel_height_unit_of_measure}} {{ heel_height_string }} {{ footwear_size_system }} {{footwear_age_group}} {{footwear_gender}} {{footwear_size_class}} {{footwear_width}} {{footwear_size}} {{footwear_to_size}} {{footwear_gender_unisex}} {{footwear_width_unisex}} {{footwear_size_unisex}} {{footwear_to_size_unisex}} {{standard_price}} {{quantity_available}} {{outer_material_type}} {{model_year}} {{heel_height}} {{closure_type}} {{care_instructions}} {{target_gender}} {{age_range_description}} {{main_image_url}} {{other_image_url1}} {{other_image_url2}} {{other_image_url3}} {{other_image_url4}} {{other_image_url5}} {{other_image_url6}} {{other_image_url7}} {{other_image_url8}} {{swatch_image_url}} {{parent_child}} {{parent_sku}} {{relationship_type}} {{variation_theme}} {{style_name}} {{bullet_point1}} {{bullet_point2}} {{bullet_point3}} {{bullet_point4}} {{bullet_point5}} {{generic_keywords}} {{toe_style}} {{arch_type}} {{department_name1}} {{department_name2}} {{department_name3}} {{department_name4}} {{department_name5}} {{department_name6}} {{department_name7}} {{department_name8}} {{department_name9}} {{department_name10}} {{color_name}} {{color_map}} {{material_type}} {{fur_description}} {{pattern_type}} {{water_resistance_level}} {{lifestyle1}} {{lifestyle2}} {{lifestyle3}} {{lifestyle4}} {{lifestyle5}} {{special_features1}} {{special_features2}} {{special_features3}} {{special_features4}} {{special_features5}} {{item_type_name}} {{manufacturer_contact_information}} {{lining_description}} {{league_name}} {{lifecycle_supply_type1}} {{lifecycle_supply_type2}} {{lifecycle_supply_type3}} {{lifecycle_supply_type4}} {{lifecycle_supply_type5}} {{item_booking_date}} {{minimum_circumference_unit_of_measure}} {{seasons}} {{collection_name}} {{target_audience_keywords1}} {{target_audience_keywords2}} {{target_audience_keywords3}} {{target_audience_keywords4}} {{target_audience_keywords5}} {{pronation_correction}} {{special_size_type}} {{shaft_style_type}} {{catalog_number}} {{style_keywords}} {{team_name}} {{minimum_circumference}} {{is_stain_resistant}} {{country_as_labeled}} {{platinum_keywords1}} {{platinum_keywords2}} {{platinum_keywords3}} {{platinum_keywords4}} {{platinum_keywords5}} {{size_name}} {{shaft_circumference}} {{shaft_circumference_unit_of_measure}} {{is_autographed}} {{athlete}} {{weave_type}} {{shoulder_strap_drop}} {{shoulder_strap_drop_unit_of_measure}} {{occasion_type}} {{sport_type1}} {{sport_type2}} {{frame_material_type}} {{fit_type}} {{theme_theme}} {{included_components}} {{pattern_name}} {{subject_character}} {{duration_unit_of_measure}} {{duration}} {{flash_point_unit_of_measure}} {{has_builtin_light}} {{shaft_diameter}} {{shoe_safety_code_iso_20345}} {{surface_recommendation}} {{insole_type}} {{cleat_description}} {{cleat_material_type}} {{strap_type}} {{sub_brand_name}} {{shaft_diameter_unit_of_measure}} {{shoe_dimension_unit_of_measure}} {{legal_compliance_certification_certifying_authority_name}} {{legal_compliance_certification_geographic_jurisdiction}} {{opacity_unit_of_measure}} {{size_info_display_name}} {{sleeve_type}} {{fabric_wash}} {{height_map}} {{size_map}} {{liquid_volume}} {{liquid_volume_unit_of_measure}} {{item_display_width}} {{item_display_height_unit_of_measure}} {{item_display_width_unit_of_measure}} {{item_display_height}} {{maximum_circumference}} {{shoe_width}} {{maximum_circumference_unit_of_measure}} {{website_shipping_weight}} {{website_shipping_weight_unit_of_measure}} {{shaft_height}} {{platform_height}} {{item_length_unit_of_measure}} {{item_length}} {{item_width}} {{item_height}} {{shaft_height_unit_of_measure}} {{item_width_unit_of_measure}} {{item_height_unit_of_measure}} {{shoe_width_unit_of_measure}} {{capacity_unit_of_measure}} {{display_size}} {{display_size_unit_of_measure}} {{capacity}} {{fulfillment_center_id}} {{package_height}} {{package_width}} {{package_length}} {{package_length_unit_of_measure}} {{package_weight}} {{package_weight_unit_of_measure}} {{package_height_unit_of_measure}} {{package_width_unit_of_measure}} {{regulation_type1}} {{regulation_type2}} {{regulation_type3}} {{regulation_type4}} {{regulation_type5}} {{regulatory_compliance_certification_value1}} {{regulatory_compliance_certification_value2}} {{regulatory_compliance_certification_value3}} {{regulatory_compliance_certification_value4}} {{regulatory_compliance_certification_value5}} {{cpsia_cautionary_statement1}} {{cpsia_cautionary_statement2}} {{cpsia_cautionary_statement3}} {{cpsia_cautionary_statement4}} {{country_of_origin}} {{item_weight_unit_of_measure}} {{item_weight}} {{batteries_required}} {{are_batteries_included}} {{battery_cell_composition}} {{battery_type1}} {{battery_type2}} {{battery_type3}} {{number_of_batteries1}} {{number_of_batteries2}} {{number_of_batteries3}} {{battery_weight}} {{battery_weight_unit_of_measure}} {{number_of_lithium_metal_cells}} {{number_of_lithium_ion_cells}} {{lithium_battery_packaging}} {{lithium_battery_energy_content}} {{lithium_battery_energy_content_unit_of_measure}} {{lithium_battery_weight}} {{lithium_battery_weight_unit_of_measure}} {{supplier_declared_dg_hz_regulation1}} {{supplier_declared_dg_hz_regulation2}} {{supplier_declared_dg_hz_regulation3}} {{supplier_declared_dg_hz_regulation4}} {{supplier_declared_dg_hz_regulation5}} {{hazmat_united_nations_regulatory_id}} {{safety_data_sheet_url}} {{item_volume}} {{item_volume_unit_of_measure}} {{contains_liquid_contents}} {{legal_compliance_certification_expiration_date}} {{flash_point}} {{warranty_description}} {{legal_compliance_certification_date_of_issue}} {{external_testing_certification}} {{supplier_declared_material_regulation1}} {{supplier_declared_material_regulation2}} {{supplier_declared_material_regulation3}} {{legal_compliance_certification_metadata}} {{legal_compliance_certification_value}} {{ghs_classification_class1}} {{ghs_classification_class2}} {{ghs_classification_class3}} {{legal_disclaimer_description}} {{safety_warning}} {{fabric_type}} {{import_designation}} {{cpsia_cautionary_description}} {{legal_compliance_certification_regulatory_organization_name}} {{legal_compliance_certification_status}} {{list_price}} {{currency_code}} {{product_tax_code}} {{fulfillment_latency}} {{merchant_release_date}} {{restock_date}} {{sale_price}} {{sale_from_date}} {{sale_end_date}} {{offering_can_be_gift_messaged}} {{offering_can_be_giftwrapped}} {{map_price}} {{offering_end_date}} {{max_order_quantity}} {{merchant_shipping_group_name}} {{offering_start_date}} {{condition_type}} {{condition_note}} {{number_of_items}} {{product_site_launch_date}} {{max_aggregate_ship_quantity}} {{item_package_quantity}} {{is_discontinued_by_manufacturer}} 329 | {%- endunless -%} 330 | {%- endfor -%} 331 | {%- endfor -%} 332 | {%- endpaginate -%} -------------------------------------------------------------------------------- /Templates/collection.csv-ga-product-feed-inc-colorsize.liquid: -------------------------------------------------------------------------------- 1 | {% layout none %}{% paginate collection.products by 1000 %}ga:productSku,ga:productName,ga:productVariant,ga:dimension1,ga:dimension2{% for product in collection.products %}{% for variant in product.variants %}{% for option in product.options %}{% if option == 'Color' %}{% capture Color %}{{ variant.options[forloop.index0] }}{% endcapture %}{% elsif option == 'Size' %}{% capture Size %}{{ variant.options[forloop.index0] }}{% endcapture %}{% endif %}{% endfor %} 2 | {{ variant.sku }},{{ product.title | replace: ',','' | remove: '"' | remove: "'" | strip_html | strip }},{{variant.title | replace: ',','' | remove: '"' | remove: "'" | strip_html | strip }},{{ Size | remove: '"' }},{{ Color | remove: '"' }}{% endfor %}{% endfor %}{% endpaginate %} -------------------------------------------------------------------------------- /Templates/collection.csv-ga-product-feed.liquid: -------------------------------------------------------------------------------- 1 | {% layout none %}{% paginate collection.products by 1000 %}ga:productSku,ga:productName,ga:productVariant{% for product in collection.products %}{% for variant in product.variants %} 2 | {{ variant.sku }},{{ product.title | replace: ',','' | remove: '"' | remove: "'" | strip_html | strip }},{{variant.title | replace: ',','' | remove: '"' | remove: "'" | strip_html | strip }}{% endfor %}{% endfor %}{% endpaginate %} -------------------------------------------------------------------------------- /Templates/collection.fb-currency-feed.liquid: -------------------------------------------------------------------------------- 1 | {% layout none %} 2 | 3 | {%- paginate collection.products by 1000 -%} 4 | 5 | {{ shop.name }} {{ collection.title | replace: '&', '&' }} 6 | {{ shop.url }} 7 | {{ collection.description | strip_html }} 8 | {% for product in collection.products %} 9 | {%- if product.variants.size > 0 -%} 10 | {%- for variant in product.variants -%} 11 | 12 | {%- assign OnSale = false -%} 13 | {%- assign Price = variant.price -%} 14 | {%- if variant.compare_at_price > variant.price -%} 15 | {%- assign OnSale = true -%} 16 | {%- assign Price = variant.compare_at_price -%} 17 | {%- assign SalePrice = variant.price -%} 18 | {%- endif -%} 19 | 20 | 21 | {{ variant.id }} 22 | {{ variant.id }} 23 | {{ shop.url }}{{ variant.url }}&currency={{ cart.currency.iso_code }} 24 | {{ Price | money_without_currency }} {{ cart.currency.iso_code }} 25 | {%- if OnSale -%} 26 | {{ SalePrice | money_without_currency }} {{ cart.currency.iso_code }} 27 | {%- endif -%} 28 | 29 | 30 | {% endfor %} 31 | {%- else -%} 32 | 33 | 34 | {{ product.id }} 35 | {{ shop.url }}{{ product.url }}&currency={{ cart.currency.iso_code }} 36 | {{ Price | money_without_currency }} {{ cart.currency.iso_code }} 37 | {%- if OnSale -%} 38 | {{ SalePrice | money_without_currency }} {{ cart.currency.iso_code }} 39 | {%- endif -%} 40 | 41 | 42 | {% endif %} 43 | {% endfor %} 44 | 45 | 46 | {% endpaginate %} -------------------------------------------------------------------------------- /Templates/collection.fb-product-feed.liquid: -------------------------------------------------------------------------------- 1 | {% layout none %} 2 | 3 | {%- paginate collection.products by 1000 -%} 4 | {%- assign CountryCode = 'US' -%} 5 | {%- if shop.currency == 'CAD' -%}{%- assign CountryCode = 'CA' -%}{%- endif -%} 6 | {%- assign PriceAdjustment = 1.0 -%} 7 | {%- assign PriceAdjustmentEffectiveDate = '20181226T080000-0500/20190102T235900-0800' -%} 8 | 9 | 10 | {{ shop.name }} {{ collection.title | replace: '&', '&' }} 11 | {{ shop.url }} 12 | {{ collection.description | strip_html }} 13 | {%- for product in collection.products -%} 14 | {%- assign GoogleProductCategory = product.metafields.mm-google-shopping.google_product_category -%} 15 | {%- assign Gender = product.metafields.mm-google-shopping.gender -%} 16 | {%- assign AgeGroup = product.metafields.mm-google-shopping.age_group -%} 17 | {%- assign Color = "" -%} 18 | {%- assign Size = "" -%} 19 | 20 | {%- if product.variants.size > 0 -%} 21 | {%- for variant in product.variants -%} 22 | {%- for option in product.options -%} 23 | {%- if option == 'Color' -%}{% capture Color %}{{ variant.options[forloop.index0] }}{% endcapture %} 24 | {%- elsif option == 'Size' -%}{% capture Size %}{{ variant.options[forloop.index0] }}{% endcapture %} 25 | {%- endif -%} 26 | {%- endfor -%} 27 | 28 | {% comment %} Calculate Sales vs Base Pricing {% endcomment %} 29 | {%- if variant.compare_at_price == blank -%} 30 | {%- assign BasePrice = variant.price -%} 31 | {%- else -%} 32 | {%- assign BasePrice = variant.compare_at_price -%} 33 | {%- endif -%} 34 | {%- assign SalePrice = variant.price | times: PriceAdjustment -%} 35 | 36 | 37 | {{ product.title | strip_html | strip_newlines | replace: '&', '&' }}{% unless product.title contains Color %} {{ Color | replace: '&', '&' }}{% endunless %} 38 | {{ shop.url }}{{ variant.url }} 39 | {{ product.title | strip_html | strip_newlines | replace: '&', '&' }} {{ variant.title | strip_html | strip_newlines | replace: '&', '&' }} {{ product.description | replace: ' 40 | {{ GoogleProductCategory | replace: '&', '&' }} 41 | {{ product.id }} 42 | {{ variant.id }} 43 | new 44 | {{ BasePrice | money_without_currency }} {{ shop.currency }} 45 | {%- if SalePrice < BasePrice -%}{{ SalePrice | money_without_currency }} {{ shop.currency }}{%- endif -%} 46 | {%- if PriceAdjustment < 1 -%}{{ PriceAdjustmentEffectiveDate }}{%- endif -%} 47 | {% if variant.available %}in stock{% else %}out of stock{% endif %} 48 | http:{% if variant.image.src %}{{ variant.image.src | product_img_url: 'grande' }}{% else %}{{ product.featured_image.src | product_img_url: 'grande' }}{% endif %} 49 | {{ variant.barcode }} 50 | {{ product.vendor }} 51 | {{ variant.sku }} 52 | {{ product.type | replace: '&', '&' }} 53 | {{ AgeGroup }} 54 | {% unless Color == "" %}{{ Color | strip_html | strip_newlines | replace: '&', '&' }}{% endunless %} 55 | {% unless Size == "" %}{{ Size | strip_html | strip_newlines | replace: '&', '&' }}US{% endunless %} 56 | {{ Gender }} 57 | {{ product.metafields.mm-google-shopping.custom_label_0 }} 58 | {{ product.metafields.mm-google-shopping.custom_label_1 }} 59 | {{ product.metafields.mm-google-shopping.custom_label_2 }} 60 | {{ product.metafields.mm-google-shopping.custom_label_3 }} 61 | {{ product.metafields.mm-google-shopping.custom_label_4 }} 62 | {{ variant.weight | weight_with_unit }} 63 | 64 | 65 | {% endfor %} 66 | {% else %} 67 | 68 | {% comment %} Calculate Sales vs Base Pricing {% endcomment %} 69 | {%- if product.compare_at_price_min == blank -%} 70 | {%- assign BasePrice = product.price -%} 71 | {%- else -%} 72 | {%- assign BasePrice = product.compare_at_price_min -%} 73 | {%- endif -%} 74 | {%- assign SalePrice = product.price | times: PriceAdjustment -%} 75 | 76 | 77 | {{ product.title | strip_html | strip_newlines | replace: '&', '&' }} 78 | {{ shop.url }}{{ product.url }} 79 | {{ product.title | strip_html | strip_newlines | replace: '&', '&' }} {{ product.description | replace: ' 80 | {{ GoogleProductCategory | replace: '&', '&' }} 81 | {{ product.id }} 82 | {{ product.id }} 83 | new 84 | {{ BasePrice | money_without_currency }} {{ shop.currency }} 85 | {%- if SalePrice < BasePrice -%}{{ SalePrice | money_without_currency }} {{ shop.currency }}{%- endif -%} 86 | {%- if PriceAdjustment < 1 -%}{{ PriceAdjustmentEffectiveDate }}{%- endif -%} 87 | {% if product.available %}in stock{% else %}out of stock{% endif %} 88 | http:{{ product.featured_image.src | product_img_url: 'grande' }} 89 | {{ product.barcode }} 90 | {{ product.vendor }} 91 | {{ product.sku }} 92 | {{ product.type }} 93 | {{ AgeGroup }} 94 | {{ Gender }} 95 | {{ product.metafields.mm-google-shopping.custom_label_0 }} 96 | {{ product.metafields.mm-google-shopping.custom_label_1 }} 97 | {{ product.metafields.mm-google-shopping.custom_label_2 }} 98 | {{ product.metafields.mm-google-shopping.custom_label_3 }} 99 | {{ product.metafields.mm-google-shopping.custom_label_4 }} 100 | {{ variant.weight | weight_with_unit }} 101 | 102 | {% endif %} 103 | {% endfor %} 104 | 105 | 106 | {% endpaginate %} -------------------------------------------------------------------------------- /Templates/collection.fb-product-update.liquid: -------------------------------------------------------------------------------- 1 | {% layout none %} 2 | 3 | {%- paginate collection.products by 1000 -%} 4 | {%- assign useSEOdescription = true -%} 5 | {%- assign additionalImagesForVariants = true -%} 6 | {%- assign includeOutOfStock = false -%} 7 | {%- assign filterVariantImagesByColor = true -%} 8 | {% comment %} 9 | This template is used to add additional information to the Facebook product catalog 10 | Documentation: https://business.czarto.com/2019/12/11/update-your-shopify-facebook-product-feed-with-missing-attributes/ 11 | 12 | {{ product.title}} {{variant.title}} 13 | {% endcomment %} 14 | 15 | {{ shop.name }} {{ collection.title | replace: '&', '&' }} 16 | {{ shop.url }} 17 | {{ collection.description | strip_html }} 18 | {% for product in collection.products %} 19 | {%- assign GoogleProductCategory = product.metafields.mm-google-shopping.google_product_category -%} 20 | {%- assign Gender = product.metafields.mm-google-shopping.gender -%} 21 | {%- assign AgeGroup = product.metafields.mm-google-shopping.age_group -%} 22 | {%- assign Material = product.metafields.mm-google-shopping.material -%} 23 | {%- assign Color = "" -%} 24 | 25 | {%- if product.variants.size > 1 -%} 26 | {%- for variant in product.variants -%} 27 | {%- if includeOutOfStock or variant.available -%} 28 | {%- for option in product.options -%} 29 | {%- if option == 'Color' -%}{% capture Color %}{{ variant.options[forloop.index0] }}{% endcapture %}{%- endif -%} 30 | {%- endfor -%} 31 | 32 | {% assign additional_images = product.images %} 33 | {% if filterVariantImagesByColor %}{% assign additional_images = product.images | where: "alt", Color | sort: 'attached_to_variant' | reverse%}{% endif %} 34 | 35 | 36 | {{ variant.id }} 37 | {% if useSEOdescription and product.metafields.global.description_tag.size > 0 %}{{ product.metafields.global.description_tag | strip_html | strip_newlines | replace: '&', '&' }}{% endif %} 38 | {{ GoogleProductCategory | replace: '&', '&' }} 39 | {% if Material %}{{ Material }}{% endif %} 40 | {% if Gender %}{{ Gender }}{% endif %} 41 | {% if AgeGroup %}{{ AgeGroup }}{% endif %} 42 | {% if additionalImagesForVariants %} 43 | {% if additional_images.size > 1 %}{%- for image in additional_images offset:1 limit:10 -%} 44 | https:{{ image.src | product_img_url: 'master' }} 45 | {% endfor %}{% endif %} 46 | {% endif %} 47 | 48 | {%- endif -%} 49 | {% endfor %} 50 | {%- else -%} 51 | 52 | 53 | {{ product.variants[0].id }} 54 | {{ GoogleProductCategory | replace: '&', '&' }} 55 | {% if useSEOdescription and product.metafields.global.description_tag.size > 0 %}{{ product.metafields.global.description_tag | strip_html | strip_newlines | replace: '&', '&' }}{% endif %} 56 | {% if Material %}{{ Material }}{% endif %} 57 | {% if Gender %}{{ Gender }}{% endif %} 58 | {% if AgeGroup %}{{ AgeGroup }}{% endif %} 59 | {% if product.images.size > 1 %}{%- for image in product.images offset:1 limit:10 -%} 60 | https:{{ image.src | product_img_url: 'master' }} 61 | {% endfor %}{% endif %} 62 | 63 | 64 | {% endif %} 65 | {% endfor %} 66 | 67 | 68 | {% endpaginate %} 69 | -------------------------------------------------------------------------------- /Templates/collection.google-feed-update.liquid: -------------------------------------------------------------------------------- 1 | {% layout none %} 2 | 3 | 4 | {% comment %} 5 | Google Shopping / Merchant Center + Shopify Product Update Feed by Alex Czartoryski 6 | https://business.czarto.com/2020/10/14/enhance-shopify-google-shopping/ 7 | 8 | This version: Aug 30, 2022 9 | The latest version of this script available here: 10 | https://github.com/Czarto/ShopifyScripts/blob/master/Templates/collection.google-feed-update.liquid 11 | 12 | TODO: Test & handle products without variants 13 | TODO: Test & hanlde products without color 14 | TODO: Specify Sizes to never exclude. eg: Women's 7,8 15 | {% endcomment %} 16 | 17 | {% comment %} Settings {% endcomment %} 18 | {%- assign exclude_unavailable_variants = true -%} 19 | {%- assign exclude_variant_colors_with_limited_availability = false -%} 20 | {%- assign ignore_x_smallest_sizes = 1 -%} 21 | {%- assign ignore_x_largest_sizes = 1 -%} 22 | {%- assign minimum_percentage_availability = 50 -%} 23 | {%- assign filter_variantImages_byColor = false -%} 24 | 25 | {%- comment -%} 26 | TODO: Move this into a snippet and use capture to assign the variable 27 | {%- endcomment -%}} 28 | {%- case shop.currency -%} 29 | {%- when 'USD' -%}{%- assign CountryCode = 'US' -%} 30 | {%- when 'CAD' -%}{%- assign CountryCode = 'CA' -%} 31 | {%- when 'GBP' -%}{%- assign CountryCode = 'GB' -%} 32 | {%- when 'AUD' -%}{%- assign CountryCode = 'AU' -%} 33 | {%- else -%}{%- assign CountryCode = 'US' -%} 34 | {%- endcase -%} 35 | 36 | 37 | {{ shop.name }} {{ collection.title | strip_html | strip_newlines | replace: '&', '&' }} 38 | {{ shop.url }} 39 | {{ collection.description | strip_html | strip_newlines | replace: '&', '&' }} 40 | 41 | {%- paginate collection.products by 1000 -%} 42 | {%- for product in collection.products -%} 43 | 44 | {%- comment -%} Get color option {%- endcomment -%} 45 | {%- for option in product.options -%} 46 | {%- if option == 'Color' or option == 'Colour' -%}{% capture option_color %}option{{ forloop.index }}{% endcapture %}{%- endif -%} 47 | {%- endfor -%} 48 | 49 | {%- comment -%} Make a list of Colors to exclude {%- endcomment -%} 50 | {%- assign colors_to_exclude = "" -%} 51 | {%- if exclude_variant_colors_with_limited_availability -%} 52 | {%- for color in product.options_by_name['Color'].values -%} 53 | {%- assign variants = product.variants | where: option_color, color -%} 54 | {%- assign variants_to_process_count = variants.size | minus:ignore_x_smallest_sizes | minus:ignore_x_largest_sizes -%} 55 | {%- assign available_count = 0 -%} 56 | {%- assign total_processed_count = 0 -%} 57 | {%- for variant in variants offset:ignore_x_smallest_sizes limit:variants_to_process_count -%} 58 | {%- assign total_processed_count = total_processed_count | plus:1 -%} 59 | {%- if variant.available -%}{%- assign available_count = available_count | plus:1 -%}{%- endif -%} 60 | {%- endfor -%} 61 | {%- if total_processed_count == 0 -%} 62 | {%- continue -%} 63 | {%- endif -%} 64 | {%- assign percentage_availability = available_count | times: 100.0 | divided_by: total_processed_count | round -%} 65 | {%- if percentage_availability < minimum_percentage_availability -%} 66 | {% capture colors_to_exclude %}{{colors_to_exclude}}#{{ color }}{%endcapture%} 67 | {%- endif -%} 68 | {%- endfor -%} 69 | {%- assign colors_to_exclude = colors_to_exclude | split: "#" -%} 70 | {%- endif -%} 71 | 72 | {%- for variant in product.variants -%} 73 | 74 | shopify_{{ CountryCode }}_{{ product.id }} 75 | shopify_{{ CountryCode }}_{{ product.id }}_{{ variant.id }} 76 | {{ variant.sku }} 77 | {{ variant.barcode }} 78 | 79 | {%- comment -%} Additional Images by Color {%- endcomment -%} 80 | {%- assign additional_images = product.images -%} 81 | {%- for option in product.options -%} 82 | {%- if option == 'Color' or option == 'Colour' -%}{% capture variant_color %}{{ variant.options[forloop.index0] }}{% endcapture %}{%- endif -%} 83 | {%- endfor -%} 84 | {% if filter_variantImages_byColor %}{% assign additional_images = product.images | where: "alt", variant_color | sort: 'attached_to_variant' | reverse%}{% endif %} 85 | {% if additional_images.size > 1 %}{%- for image in additional_images offset:1 limit:10 -%} 86 | https:{{ image.src | product_img_url: 'master' }} 87 | {% endfor %}{% endif %} 88 | 89 | {%- comment -%} Exclude Out of Stock Variants {%- endcomment -%} 90 | {% if exclude_unavailable_variants and variant.available == false %} 91 | ads 92 | {% elsif exclude_variant_colors_with_limited_availability and colors_to_exclude contains variant_color %} 93 | ads 94 | {% endif %} 95 | 96 | 97 | {% endfor %} 98 | {% endfor %} 99 | {% endpaginate %} 100 | 101 | -------------------------------------------------------------------------------- /Templates/collection.xml-product-feed.liquid: -------------------------------------------------------------------------------- 1 | {% layout none %} 2 | 3 | {% paginate collection.products by 1000 %} 4 | {%- assign useSEOtitle = false -%} 5 | {%- assign useSEOdescription = true -%} 6 | {%- comment -%} 7 | TODO: Move this into a snippet and use capture to assign the variable 8 | {%- endcomment -%} 9 | {%- case shop.currency -%} 10 | {%- when 'USD' -%}{%- assign CountryCode = 'US' -%} 11 | {%- when 'CAD' -%}{%- assign CountryCode = 'CA' -%} 12 | {%- when 'GBP' -%}{%- assign CountryCode = 'GB' -%} 13 | {%- when 'AUD' -%}{%- assign CountryCode = 'AU' -%} 14 | {%- else -%}{%- assign CountryCode = 'US' -%} 15 | {%- endcase -%} 16 | {%- assign Color = "" -%} 17 | {%- assign Size = "" -%} 18 | 19 | {{ shop.name }} {{ collection.title | strip_html | strip_newlines | replace: '&', '&' }} 20 | {{ shop.url }} 21 | {{ collection.description | strip_html | strip_newlines | replace: '&', '&' }} 22 | {% for product in collection.products %} 23 | {%- assign GoogleProductCategory = product.metafields.mm-google-shopping.google_product_category -%} 24 | {%- assign Gender = product.metafields.mm-google-shopping.gender -%} 25 | {%- assign AgeGroup = product.metafields.mm-google-shopping.age_group -%} 26 | 27 | {% for variant in product.variants %} 28 | {%- assign Color = "" -%} 29 | {%- assign Size = "" -%} 30 | {%- for option in product.options -%} 31 | {%- if option == 'Color' -%}{%- capture Color -%}{{ variant.options[forloop.index0] }}{%- endcapture -%} 32 | {%- elsif option == 'Size' -%}{%- capture Size -%}{{ variant.options[forloop.index0] }}{%- endcapture -%} 33 | {%- endif -%} 34 | {%- endfor -%} 35 | 36 | {%- capture productTitle -%}{{ product.title }}{%- endcapture -%} 37 | {%- unless productTitle contains Color -%}{%- capture productTitle -%}{{ productTitle }} {{ Color }}{%- endcapture -%}{%- endunless -%} 38 | {%- if useSEOtitle and product.metafields.global.title_tag.size > 0 -%}{%- assign productTitle = product.metafields.global.title_tag -%}{%- endif -%} 39 | {%- assign productDescription = product.description -%} 40 | {%- if useSEOdescription and product.metafields.global.description_tag.size > 0 -%}{%- assign productDescription = product.metafields.global.description_tag -%}{%- endif -%} 41 | 42 | {%- assign OnSale = false -%} 43 | {%- assign Price = variant.price -%} 44 | {%- if variant.compare_at_price > variant.price -%} 45 | {%- assign OnSale = true -%} 46 | {%- assign Price = variant.compare_at_price -%} 47 | {%- assign SalePrice = variant.price -%} 48 | {%- endif -%} 49 | 50 | 51 | {{ productTitle | strip_html | replace: '&', '&' }} 52 | {{ shop.url }}{{ variant.url }}&currency={{ cart.currency.iso_code }} 53 | {{ productDescription | strip_html | strip_newlines | replace: '&', '&' }} 54 | {{ GoogleProductCategory | replace: '&', '&' }} 55 | shopify_{{ CountryCode }}_{{ product.id }} 56 | shopify_{{ CountryCode }}_{{ product.id }}_{{ variant.id }} 57 | new 58 | {{ Price | money_without_currency }} {{ cart.currency.iso_code }} 59 | {%- if OnSale -%} 60 | {{ SalePrice | money_without_currency }} {{ cart.currency.iso_code }} 61 | {%- endif -%} 62 | {% if variant.available %}in stock{% else %}out of stock{% endif %} 63 | http:{% if variant.image.src %}{{ variant.image.src | product_img_url: 'master' }}{% else %}{{ product.featured_image.src | product_img_url: 'master' }}{% endif %} 64 | {{ variant.barcode }} 65 | {{ product.vendor }} 66 | {{ variant.sku }} 67 | {{ product.type }} 68 | {{ AgeGroup }} 69 | {% unless Color == "" %}{{ Color | strip_html | strip_newlines | replace: '&', '&' }}{% endunless %} 70 | {%- unless Size == "" -%} 71 | {{ Size | strip_html | strip_newlines | replace: '&', '&' }} 72 | US 73 | {%- endunless -%} 74 | {{ Gender }} 75 | {{ product.metafields.mm-google-shopping.custom_label_0 }} 76 | {{ product.metafields.mm-google-shopping.custom_label_1 }} 77 | {{ product.metafields.mm-google-shopping.custom_label_2 }} 78 | {{ product.metafields.mm-google-shopping.custom_label_3 }} 79 | {{ product.metafields.mm-google-shopping.custom_label_4 }} 80 | {{ variant.weight | weight_with_unit }} 81 | 82 | 83 | {% endfor %} 84 | {% endfor %} 85 | 86 | 87 | {% endpaginate %} 88 | -------------------------------------------------------------------------------- /settings/checkout/adwords-conversion.liquid: -------------------------------------------------------------------------------- 1 | {% comment %} 2 | Google Ads Conversion Tracking Script by Alex Czartoryski https://business.czarto.com/ 3 | 4 | DEPRECATED! Conversion tracking is now handled by the Shopify Google Shopping Channel 5 | 6 | This version: Sep 30, 2020 7 | The latest version of this script available here: 8 | https://github.com/Czarto/ShopifyScripts/blob/master/settings/checkout/adwords-conversion.liquid 9 | {% endcomment %} 10 | 11 | {% comment %}Set to false if GTAG is already loaded on the page. Leave to true if unsure.{%endcomment%} 12 | {% assign load_gtag = true %} 13 | 14 | {% if first_time_accessed %} 15 | {% comment %} Enter your account specific values below {% endcomment %} 16 | {% assign google_conversion_id = "123456789" %} 17 | {% assign google_conversion_label = "abcdefghijklmnop" %} 18 | 19 | {% assign shopify_store_country = 'US' %} 20 | {% if shop.currency == 'CAD' %} 21 | {% assign shopify_store_country = 'CA' %} 22 | {% elsif shop.currency == 'AUD' %} 23 | {% assign shopify_store_country = 'AU' %} 24 | {% endif %} 25 | 26 | 27 | {%if load_gtag %} 28 | 29 | 30 | {% endif %} 31 | 37 | 38 | 39 | 48 | 49 | {% endif %} 50 | -------------------------------------------------------------------------------- /settings/checkout/adwords-remarketing.liquid: -------------------------------------------------------------------------------- 1 | {% comment %} 2 | Google Ads Dynamic Remarkting Script by Alex Czartoryski https://business.czarto.com/ 3 | 4 | This version: Sep 30, 2020 5 | The latest version of this script available here: 6 | https://github.com/Czarto/ShopifyScripts/blob/master/settings/checkout/adwords-remarketing.liquid 7 | {% endcomment %} 8 | 9 | {% comment %}Set to false if GTAG is already loaded on the page. Leave to true if unsure.{%endcomment%} 10 | {% assign load_gtag = true %} 11 | 12 | {% if first_time_accessed %} 13 | {% comment %} Enter your account specific values below {% endcomment %} 14 | {% assign google_conversion_id = "123456789" %} 15 | 16 | {% assign shopify_store_country = 'US' %} 17 | {% if shop.currency == 'CAD' %} 18 | {% assign shopify_store_country = 'CA' %} 19 | {% elsif shop.currency == 'AUD' %} 20 | {% assign shopify_store_country = 'AU' %} 21 | {% endif %} 22 | 23 | 24 | {%if load_gtag %} 25 | 26 | 27 | {% endif %} 28 | 34 | 35 | 36 | 44 | 45 | {% endif %} 46 | -------------------------------------------------------------------------------- /settings/checkout/ga-ec-funnel-report.js: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /settings/checkout/ga-new-customers.liquid: -------------------------------------------------------------------------------- 1 | {% comment %} 2 | Script based on Lars C. L. Larsen's post here: 3 | https://blog.adnudging.com/how-to-track-new-customer-acquisition-in-google-analytics-with-shopify-672d6542574b 4 | {% endcomment %} 5 | {% if first_time_accessed %} 6 | 19 | {% endif %} -------------------------------------------------------------------------------- /settings/checkout/pinterest-conversion.liquid: -------------------------------------------------------------------------------- 1 | {% comment %} 2 | Pinterest Conversion Tracking Script by Alex Czartoryski https://business.czarto.com/ 3 | The latest version of this script available here: 4 | https://github.com/Czarto/ShopifyScripts/blob/master/settings/checkout/pinterest-conversion.liquid 5 | {% endcomment %} 6 | 7 | {% if first_time_accessed %} 8 | {% comment %} Enter your account specific values below {% endcomment %} 9 | {% assign pinterest_tag_id = 1234567890123 %} 10 | 11 | {% assign shopify_store_country = 'US' %} 12 | {% if shop.currency == 'CAD' %} 13 | {% assign shopify_store_country = 'CA' %} 14 | {% elsif shop.currency == 'AUD' %} 15 | {% assign shopify_store_country = 'AU' %} 16 | {% endif %} 17 | 18 | 47 | 51 | 52 | {% endif %} 53 | 54 | -------------------------------------------------------------------------------- /settings/checkout/twitter-conversion.liquid: -------------------------------------------------------------------------------- 1 | {% comment %} 2 | Twitter Conversion Tracking Script by Alex Czartoryski https://business.czarto.com/ 3 | The latest version of this script available here: 4 | https://github.com/Czarto/ShopifyScripts/blob/master/settings/checkout/twitter-conversion.liquid 5 | {% endcomment %} 6 | 7 | {% if first_time_accessed %} 8 | {% comment %} Enter your account specific values below {% endcomment %} 9 | {% assign twitter_pixel_id = 'a123b' %} 10 | 11 | 12 | 24 | 25 | 26 | {% endif %} 27 | 28 | -------------------------------------------------------------------------------- /snippets/adwords-remarketing.liquid: -------------------------------------------------------------------------------- 1 | {% comment %} 2 | Google Ads Dynamic Remarketing Script by Alex Czartoryski 3 | https://business.czarto.com/2017/02/07/shopify-dynamic-remarketing-setup/ 4 | 5 | This version: Sept 30, 2020 6 | The latest version of this script available here: 7 | https://github.com/Czarto/ShopifyScripts/blob/master/snippets/adwords-remarketing.liquid 8 | {% endcomment %} 9 | 10 | {% comment %}Set to false if GTAG is already loaded on the page. Leave to true if unsure.{%endcomment%} 11 | {% assign load_gtag = true %} 12 | 13 | {% comment %} Enter your google conversion id below {% endcomment %} 14 | {% assign google_conversion_id = "123456789" %} 15 | 16 | {% assign shopify_store_country = 'US' %} 17 | {% if shop.currency == 'CAD' %} 18 | {% assign shopify_store_country = 'CA' %} 19 | {% elsif shop.currency == 'AUD' %} 20 | {% assign shopify_store_country = 'AU' %} 21 | {% endif %} 22 | 23 | {%if load_gtag %} 24 | 25 | 26 | {% endif %} 27 | 33 | 34 | {% assign google_event = false %} 35 | {% assign google_items = false %} 36 | {% assign google_value = false %} 37 | {% if template contains 'cart' %} 38 | {% assign google_event = 'add_to_cart' %} 39 | {% capture google_items %}{% for item in cart.items %}{'id':'shopify_{{ shopify_store_country }}_{{ item.product.id }}_{{ item.variant.id }}','google_business_vertical': 'retail'}{% unless forloop.last %}, {% endunless %}{% endfor %}{% endcapture %} 40 | {% assign google_value = cart.total_price %} 41 | {% elsif template contains 'collection' %} 42 | {% assign google_event = 'view_item_list' %} 43 | {% capture google_items %}{% for item in collection.products limit:5 %}{'id':'shopify_{{ shopify_store_country }}_{{ item.id }}_{{ item.variants.first.id }}','google_business_vertical': 'retail'}{% unless forloop.last %}, {% endunless %}{% endfor %}{% endcapture %} 44 | {% elsif template contains 'product' %} 45 | {% assign google_event = 'view_item' %} 46 | {% capture google_items %}{'id':'shopify_{{ shopify_store_country }}_{{ product.id }}_{{ product.selected_or_first_available_variant.id }}','google_business_vertical': 'retail'}{% endcapture %} 47 | {% assign google_value = product.selected_or_first_available_variant.price %} 48 | {% elsif template contains 'search' %} 49 | {% assign google_event = 'view_search_results' %} 50 | {% capture google_items %}{% for item in search.results limit:5 %}{'id':'shopify_{{ shopify_store_country }}_{{ item.id }}_{{ item.variants.first.id }}','google_business_vertical': 'retail'}{% unless forloop.last %}, {% endunless %}{% endfor %}{% endcapture %} 51 | {% endif %} 52 | 53 | {% if google_event %} 54 | 61 | {% endif %} 62 | -------------------------------------------------------------------------------- /snippets/facebook-remarketing.liquid: -------------------------------------------------------------------------------- 1 | 2 | {% comment %} 3 | Include this file at the bottom of your product page template. 4 | {% endcomment %} 5 | 33 | -------------------------------------------------------------------------------- /snippets/pinterest-remarketing.liquid: -------------------------------------------------------------------------------- 1 | {% comment %} 2 | Pinterest Remarketing Tracking Script by Alex Czartoryski https://business.czarto.com/ 3 | The latest version of this script available here: 4 | https://github.com/Czarto/ShopifyScripts/blob/master/snippets/pinterest-remarketing.liquid 5 | {% endcomment %} 6 | 7 | {% assign pinterest_tag_id = 2613156108072 %} 8 | 9 | {% assign shopify_store_country = 'US' %} 10 | {% if shop.currency == 'CAD' %} 11 | {% assign shopify_store_country = 'CA' %} 12 | {% elsif shop.currency == 'AUD' %} 13 | {% assign shopify_store_country = 'AU' %} 14 | {% endif %} 15 | 68 | -------------------------------------------------------------------------------- /snippets/product-color-swatch.liquid: -------------------------------------------------------------------------------- 1 | {% for option in product.options %} 2 | {% if option == 'Color' %} 3 | {% assign index = forloop.index0 %} 4 | {% assign colorlist = '' %} 5 | {% assign color = '' %} 6 | {% for variant in product.variants %} 7 | {% capture color %}{{ variant.options[index] }}{% endcapture %} 8 | {% unless colorlist contains color %} 9 | {{ color }} 10 | {% capture tempList %}{{colorlist | append: color | append: ‘ ‘}}{% endcapture %} 11 | {% assign colorlist = tempList %} 12 | {% endunless %} 13 | {% endfor %} 14 | {% endif %} 15 | {% endfor %} 16 | -------------------------------------------------------------------------------- /snippets/seo-collection-dynamic-titles.liquid: -------------------------------------------------------------------------------- 1 | {% comment %} 2 | Dynamic collection titles and descriptions based on currently applied filters 3 | by Alex Czartoryski https://business.czarto.com/ 4 | 5 | The latest version of this script is available here: 6 | https://github.com/Czarto/ShopifyScripts/snippets/seo-collection-dynamic-titles.liquid 7 | 8 | Documentation: TBA 9 | 10 | This snippet will inject various words into Page Title, Description, and on page text 11 | with the goal of richer and more granular SEO rankings. 12 | 13 | Currently configured to replace the text #gender# with Men's, Women's, or Children's 14 | You must include this script at the top of your Theme file if you want to modify 15 | the Title tag or meta description. 16 | You must include this script again at the top of your collection page if you want to 17 | modify the heading or text on your collection page. 18 | 19 | Usage once snippet installed: 20 | - Put #gender# in plain text in either the collection's seo title, description, or heading. 21 | - Add this to your theme collection page: 22 | {{ page_title | replace: seo_gender_placeholder, seo_gender }} 23 | - Add this to your collection template: 24 |

{{ collection.title | replace: seo_gender_placeholder, seo_gender }}

25 |

{{ collection.description | replace: seo_gender_placeholder, seo_gender }}

26 | 27 | {% endcomment %} 28 | 29 | {% assign seo_gender = "" %} 30 | {% assign seo_gender_placeholder = "#gender#" %} 31 | 32 | {% if current_tags contains "Style_Women" %} 33 | {% assign seo_gender = "Women's " %} 34 | {% elsif current_tags contains "Style_Men" %} 35 | {% assign seo_gender = "Men's " %} 36 | {% elsif current_tags contains "Style_Children" %} 37 | {% assign seo_gender = "Children's " %} 38 | {% endif%} -------------------------------------------------------------------------------- /snippets/twitter-remarketing.liquid: -------------------------------------------------------------------------------- 1 | {% comment %} 2 | Twitter Remarketing Tracking Script by Alex Czartoryski https://business.czarto.com/ 3 | The latest version of this script available here: 4 | https://github.com/Czarto/ShopifyScripts/blob/master/snippets/twitter-remarketing.liquid 5 | {% endcomment %} 6 | 7 | {% assign twitter_pixel_id = 'a123b' %} 8 | 9 | 10 | 18 | --------------------------------------------------------------------------------