How can I change $0 products to 'Get a Quote' on my website?

Hi There,
Can anyone please help me to change products on my site with $0 to show Get a quote and a contact us button to replace Add to cart & Buy now.
site: https://testingmysite4.myshopify.com/

I have attached an image to show what im trying to achieve. thanks

Hi @mihalmaruf

This is fairly simple to do, how is your Liquid knowledge? As this will be the main factor for the solution. Let us know!

I have coding knowledge, if you can let me know what to add to what folder, that would be great. thanks.

Fantastic, so you’re going to be looking at the product.liquid template there, and search for the price display field.

Where it display the price you have to replace it with the following:

{% if product.price == 0 %}
Call for Price
{%else%}
What Was Already used to display the price
{%endif%}

Let me know if that works!

I dont see any mention of price on the product.liquid file. I am using warehouse theme from shopify

Hover of the “product-template” section name and scope to the file. You should be able to find all that info below

{%- capture section_settings -%}
{
“showShippingEstimator”: {% if template == ‘product.quick-view’ or product.available == false %}false{% else %}{{ section.settings.show_shipping_estimator | json }}{% endif %},
“showQuantitySelector”: {{ section.settings.show_quantity_selector | json }},
“showPaymentButton”: {% if product.template_suffix == ‘pre-order’ %}false{% else %}{{ section.settings.show_payment_button | json }}{% endif %},
“showInventoryQuantity”: {% if product.template_suffix != ‘pre-order’ %}{{ section.settings.show_inventory_quantity | json }}{% else %}false{% endif %},
“lowInventoryThreshold”: {{ section.settings.low_inventory_threshold | json }},
“galleryTransitionEffect”: {{ section.settings.carousel_effect | json }},
“enableImageZoom”: {% if template == ‘product.quick-view’ %}false{% else %}{{ section.settings.enable_image_zoom | json }}{% endif %},
“zoomEffect”: {{ section.settings.zoom_effect | json }},
“enableVideoLooping”: {{ section.settings.enable_video_looping | json }},
“productOptions”: {{ product.options | json | escape }},
“enableHistoryState”: {% if template == ‘product.quick-view’ %}false{% else %}true{% endif %},
“infoOverflowScroll”: {% if template == ‘product.quick-view’ %}false{% else %}true{% endif %},
“isQuickView”: {% if template == ‘product.quick-view’ %}true{% else %}false{% endif %}
}
{%- endcapture -%}

{%- if template != 'product.quick-view' -%}
  1. {{ 'general.breadcrumb.home' | t }} {%- render 'icon', icon: 'arrow-right' -%}
  2. {%- if collection -%} {{ collection.title }} {%- render 'icon', icon: 'arrow-right' -%} {%- else -%} {{- 'collection.general.all_products' | t -}} {%- render 'icon', icon: 'arrow-right' -%} {%- endif -%}
  3. {{ product.title | truncate: 40 }}

{%- if collection.previous_product or collection.next_product -%}

{%- endif -%}
{%- if product.media.size > 0 -%}
{% render 'product-gallery' %}
{%- endif -%}
{% render 'product-info' %}

{%- if product.description != blank -%}

{%- if section.settings.content_display_mode == 'collapse_all' -%} {{ 'product.general.description' | t }}
{{ product.description | remove: 'data-section-type="product"' }}
{%- else -%}

{{ 'product.general.description' | t }}

{%- if section.settings.content_display_mode == ‘show_all_and_expand_description’ -%}

{{ product.description | remove: 'data-section-type="product"' }}
{%- else -%}
{{ product.description | remove: 'data-section-type="product"' }}
{{- 'product.general.view_more' | t -}}
{%- endif -%} {%- endif -%}
{%- endif -%}

{%- comment -%}

TABS

{%- endcomment -%}

{%- for i in (1..5) -%}
{%- assign unique_tab_title = ‘’ -%}
{%- assign unique_tab_content = ‘’ -%}

{%- comment -%}First check for metafields{%- endcomment -%}

{%- assign metafield_tab_title_option = ‘tab_’ | append: i | append: ‘title’ -%}
{%- assign metafield_tab_content_option = 'tab
’ | append: i | append: ‘_content’ -%}

{%- if product.metafields.sf_product_tabs[metafield_tab_title_option] != blank and product.metafields.sf_product_tabs[metafield_tab_content_option] != blank -%}
{%- assign unique_tab_title = product.metafields.sf_product_tabs[metafield_tab_title_option] -%}
{%- assign unique_tab_content = product.metafields.sf_product_tabs[metafield_tab_content_option] -%}
{%- else -%}
{%- assign tab_to_look = ‘__tab’ | append: i | append: ‘:’ -%}

{%- for tag in product.tags -%}
{%- if tag contains tab_to_look -%}
{%- assign unique_tab_handle = tag | split: tab_to_look | last -%}
{%- assign unique_tab_page = pages[unique_tab_handle] -%}

{%- unless unique_tab_page.empty? -%}
{%- assign unique_tab_title = unique_tab_page.title -%}
{%- assign unique_tab_content = unique_tab_page.content -%}
{%- break -%}
{%- endunless -%}
{%- endif -%}
{%- endfor -%}
{%- endif -%}

{%- if unique_tab_title != blank and unique_tab_content != blank -%}

{%- if section.settings.content_display_mode == 'collapse_all_except_description' or section.settings.content_display_mode == 'collapse_all' -%} {{ unique_tab_title }}
{{ unique_tab_content }}
{%- else -%}

{{ unique_tab_title }}

{{ unique_tab_content }}
{{- 'product.general.view_more' | t -}}
{%- endif -%}
{%- endif -%} {%- endfor -%}

{%- for i in (1..3) -%}
{%- assign global_tab_option = ‘tab_page_’ | append: i | append: ‘_handle’ -%}
{%- assign global_tab_page = pages[section.settings[global_tab_option]] -%}

{%- unless global_tab_page.empty? -%}

{%- if section.settings.content_display_mode == 'collapse_all_except_description' or section.settings.content_display_mode == 'collapse_all' -%} {{ global_tab_page.title }}
{{ global_tab_page.content }}
{%- else -%}

{{ global_tab_page.title }}

{{ global_tab_page.content }}
{{- 'product.general.view_more' | t -}}
{%- endif -%}
{%- endunless -%} {%- endfor -%}

{%- comment -%}

REVIEWS

{%- endcomment -%}

{%- if section.settings.enable_reviews -%}

{%- assign reviews_count = product.metafields.spr.reviews | split: '' | first | times: 1 -%}
{{ product.metafields.spr.reviews }}
{%- endif -%}

{%- comment -%}

SECURITY BADGES

{%- endcomment -%}

{%- if section.settings.show_payment_icons and shop.enabled_payment_types.size > 0 -%}
{%- assign show_payment_icons = true -%}
{%- else -%}
{%- assign show_payment_icons = false -%}
{%- endif -%}

{%- if section.settings.custom_security_badge or show_payment_icons -%}

{{ section.settings.trust_title | escape }}

{%- render ‘icon’, icon: ‘lock’, width: 22, height: 24 -%}

{%- if show_payment_icons -%} {%- if section.settings.custom_security_badge -%}

{{ 'product.general.payment' | t }}

{%- endif -%}
{% for type in shop.enabled_payment_types %} {{ type | payment_type_svg_tag: class: 'payment-list__item' }} {% endfor %}

{{ 'product.general.payment_notice' | t }}

{%- endif -%}

{%- if show_payment_icons and section.settings.custom_security_badge -%}


{%- endif -%}

{%- if section.settings.custom_security_badge -%}
{%- if show_payment_icons -%}

{{ 'product.general.security' | t }}

{%- endif -%}

{%- assign badge_width = section.settings.custom_security_badge.width | at_most: 450 | append: ‘x’ -%}
{{ section.settings.custom_security_badge.alt | escape }}
{%- endif -%}

{%- endif -%}

{%- comment -%}

ESTIMATE SHIPPING

{%- endcomment -%}

{%- if section.settings.show_shipping_estimator and product.available -%}

{{ 'product.general.estimate_shipping' | t }}

{{ 'cart.shipping_estimator.country' | t }}
{%- render 'icon', icon: 'arrow-bottom' -%}
{{ 'cart.shipping_estimator.province' | t }}
{%- render 'icon', icon: 'arrow-bottom' -%}

{{ 'cart.shipping_estimator.zip_code' | t }}

{{ ‘cart.shipping_estimator.estimate’ | t }}

{%- if section.settings.show_refunds_policy and shop.refund_policy != blank -%}

{{ 'product.general.refund_policy' | t }} {%- render 'icon', icon: 'arrow-right' -%}
{%- endif -%}
{%- endif -%}

{%- if section.settings.show_refunds_policy and shop.refund_policy != blank -%}

{{ 'product.general.refund_policy' | t }}

{%- render 'icon', icon: 'close' -%}
{{ shop.refund_policy }}
{%- endif -%} {%- else -%} {%- comment -%}We display the quick view within the product template so we can re-use the same settings{%- endcomment -%}
{%- render 'product-gallery' -%} {%- render 'product-info' -%}
{%- endif -%}

{% schema %}
{
“name”: “Product page”,
“settings”: [
{
“type”: “checkbox”,
“id”: “show_vendor”,
“label”: “Show vendor”,
“default”: true
},
{
“type”: “checkbox”,
“id”: “show_sku”,
“label”: “Show SKU”,
“default”: false
},
{
“type”: “checkbox”,
“id”: “show_share_buttons”,
“label”: “Show share buttons”,
“default”: true
},
{
“type”: “checkbox”,
“id”: “show_taxes_included”,
“label”: “Show price taxes notice”,
“default”: false
},
{
“type”: “select”,
“id”: “selector_mode”,
“label”: “Selector type”,
“options”: [
{
“value”: “block”,
“label”: “Block”
},
{
“value”: “dropdown”,
“label”: “Dropdown”
}
],
“default”: “block”
},
{
“type”: “select”,
“id”: “color_mode”,
“label”: “Color selector type”,
“info”: “Variant image mode requires that all variant has an associated image. Learn more”,
“options”: [
{
“value”: “block”,
“label”: “Block”
},
{
“value”: “dropdown”,
“label”: “Dropdown”
},
{
“value”: “color”,
“label”: “Color swatch”
},
{
“value”: “variant_image”,
“label”: “Variant image”
}
],
“default”: “color”
},
{
“type”: “checkbox”,
“id”: “show_quantity_selector”,
“label”: “Show quantity selector”,
“default”: true
},
{
“type”: “checkbox”,
“id”: “show_payment_button”,
“label”: “Show dynamic checkout button”,
“info”: “Each customer will see their preferred payment method from those available on your store, such as PayPal or Apple Pay. Learn more”,
“default”: true
},
{
“type”: “checkbox”,
“id”: “show_pickup_availability”,
“label”: “Show local pickup availability”,
“info”: “Show customers where they can pick up the product. Learn more”,
“default”: false
},
{
“type”: “header”,
“content”: “Media”
},
{
“type”: “paragraph”,
“content”: “Learn more about media types
},
{
“type”: “select”,
“id”: “image_size”,
“label”: “Size”,
“options”: [
{
“value”: “small”,
“label”: “Small”
},
{
“value”: “medium”,
“label”: “Medium”
},
{
“value”: “large”,
“label”: “Large”
}
],
“default”: “small”
},
{
“type”: “checkbox”,
“id”: “enable_video_looping”,
“label”: “Enable video looping”,
“default”: false
},
{
“type”: “checkbox”,
“id”: “enable_image_zoom”,
“label”: “Enable image zoom”,
“default”: true
},
{
“type”: “select”,
“id”: “zoom_effect”,
“label”: “Desktop zoom effect”,
“options”: [
{
“value”: “inside”,
“label”: “Inside”
},
{
“value”: “outside”,
“label”: “Outside”
}
],
“default”: “outside”
},
{
“type”: “select”,
“id”: “carousel_effect”,
“label”: “Transition effect”,
“options”: [
{
“value”: “fade”,
“label”: “Fade”
},
{
“value”: “slide”,
“label”: “Slide”
}
],
“default”: “fade”
},
{
“type”: “header”,
“content”: “Inventory”
},
{
“type”: “paragraph”,
“content”: “You can also add a stock countdown. Learn more.”
},
{
“type”: “checkbox”,
“id”: “show_inventory_quantity”,
“label”: “Show inventory quantity”,
“default”: false
},
{
“type”: “range”,
“id”: “low_inventory_threshold”,
“label”: “Low inventory threshold”,
“info”: “Use low stock color when quantity is below the threshold. Choose 0 to always show in stock.”,
“min”: 0,
“max”: 100,
“step”: 1,
“default”: 0
},
{
“type”: “header”,
“content”: “Content”
},
{
“type”: “paragraph”,
“content”: “You can also add per-product tabs. Learn more.”
},
{
“type”: “select”,
“id”: “content_display_mode”,
“label”: “Display mode”,
“options”: [
{
“value”: “show_all”,
“label”: “Show all”
},
{
“value”: “show_all_and_expand_description”,
“label”: “Show all and expand description”
},
{
“value”: “collapse_all”,
“label”: “Collapse all”
},
{
“value”: “collapse_all_except_description”,
“label”: “Collapse all except description”
}
],
“default”: “show_all_and_expand_description”
},
{
“type”: “page”,
“id”: “tab_page_1_handle”,
“label”: “First page”
},
{
“type”: “page”,
“id”: “tab_page_2_handle”,
“label”: “Second page”
},
{
“type”: “page”,
“id”: “tab_page_3_handle”,
“label”: “Third page”
},
{
“type”: “header”,
“content”: “Reviews”
},
{
“type”: “paragraph”,
“content”: “You need to install Shopify’s free Product Reviews app before enabling those options.”
},
{
“type”: “checkbox”,
“id”: “enable_reviews”,
“label”: “Enable”,
“default”: false
},
{
“type”: “checkbox”,
“id”: “show_reviews_badge”,
“label”: “Show badge”,
“default”: false
},
{
“type”: “header”,
“content”: “Trust”
},
{
“type”: “text”,
“id”: “trust_title”,
“label”: “Heading”,
“default”: “Payment & Security”
},
{
“type”: “checkbox”,
“id”: “show_payment_icons”,
“label”: “Show payment icons”,
“default”: true
},
{
“type”: “image_picker”,
“id”: “custom_security_badge”,
“label”: “Security badge”,
“info”: “800 x 200px .jpg recommended”
},
{
“type”: “range”,
“id”: “custom_security_badge_width”,
“min”: 100,
“max”: 500,
“step”: 10,
“unit”: “px”,
“label”: “Security badge width”,
“default”: 200
},
{
“type”: “header”,
“content”: “Shipping estimator”
},
{
“type”: “checkbox”,
“id”: “show_shipping_estimator”,
“label”: “Show shipping estimator”,
“info”: “Only show if product is available.”,
“default”: true
},
{
“type”: “text”,
“id”: “shipping_estimator_default_country”,
“label”: “Default country”,
“info”: “If the customer is logged in, the country of their shipping address will be used.”,
“default”: “United States”
},
{
“type”: “checkbox”,
“id”: “show_refunds_policy”,
“label”: “Show refunds policy”,
“info”: “Refund policy must be added into your store policies. Learn more.”,
“default”: true
}
]
}
{% endschema %}

I am in product-template.liquid file but cant fine the section to replace the code with

can you please take a look and let me know which linke of code i need to replace it with. thanks

Which code do i need to replace it with?
or add separately?
adding separately doesn’t do anything

id be obliged if anyone can give me a solution

hy mihalmaruf
i am also using same theme my client want to replace price section into get a quote button can you plz help me?