Using OC 2.3.0.2, and I want to display the word 'From' before the prices on the products on the category page. (On product grid/list)
I have achieved this by adding the text in the 'category.tpl' file, BUT, of course this adds it to all products in all categories.
I need it to display only on products that have different price options. I feel it gives better transparency to the pricing.
Any help or gentle nudging in the right direction would be appreciated.
Professional OpenCart extensions, support and custom work.
Contact me via email or Skype by support@thekrotek.com
What also needs to be considered, in this case, is the product options can also be optional versus others that can be a required field before adding the whole product to the cart which can also be misleading to your customers. Granted, there might be a specific way to indicate a 'from' statement in front of only those products that may contain optional product options to fill but, at the same time, would also be a downside to the category list of your store as it would bring more questions by your customers.of course this adds it to all products in all categories.
I need it to display only on products that have different price options. I feel it gives better transparency to the pricing.
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
Professional OpenCart extensions, support and custom work.
Contact me via email or Skype by support@thekrotek.com
In language file i did replace "price" for "" so original text price is not shown.
In extra field i can add anything like price per meter or price Starting from or Just price.
Koeltechnische deurrubbers eenvoudig online op maat bestellen.
Alle niet stekplichtige onderdelen zoals scharnieren, sloten, randverwarming en verlichting voor alle typen koelingen en vriezers.
https://koelcel-onderdelen.com
This analogy is based on the product detail page while your first post refers to the category.tpl as my last reply is also based on the category.tpl file. Noticing that there are no indications of price on the category pages but do have a '+' sign after the base price on the product page itself still won't cover the facts that the product category listing page will bring up more questions whether knowing which products would imply a range of prices versus the products that contains mandatory product options to fulfill before adding those products to the cart.Mosstyn wrote: ↑Sun Jun 10, 2018 3:37 pmStraightlight, I get what you're saying. I've just had a look on Etsy, where I also sell, and they don't have any indications of variations of price on the category pages, but have a '+' sign after the base price on the product page. This disappears after the options have been selected and the price changes. Maybe this would be better. (Good enough for Etsy, etc).
While being the case, I would rather suggest to use an extension module from the Marketplace that can filter the price range which already mentions From x - To y which will ease the search for your customers.
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
in the product i added the From:
Code: Select all
{% if price %}
<ul class="list-unstyled">
{% if not special %}
<li>
<h2>From: {{ price }}</h2>
</li>
{% else %}
in the category i added the From:
Code: Select all
{% if product.price %}
<p class="price"> {% if not product.special %}
From: {{ product.price }}
{% else %} <span class="price-new">{{ product.special }}</span> <span class="price-old">{{ product.price }}</span> {% endif %}
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
Code: Select all
{% if product.price %}
<div class="price">
<div>
{% if product.special %}
<span class="price-new">{{ product.special }}</span> <span class="price-old">{{ product.price }}</span>
{% elseif heading_title == 'YOUR CATEGORY TITLE' or heading_title == 'ANOTHER CATEGORY TITLE' or heading_title == 'A THIRD CATEGORY TITLE' %}
<span style="font-size:13px">From  </span><span class="price-normal">{{ product.price }}</span>
{% else %}
<span class="price-normal">{{ product.price }}</span>
{% endif %}
</div>
{% if product.tax %}
<span class="price-tax">{{ text_tax }}{{ product.tax }}</span>
{% endif %}
</div>
{% endif %}
Users browsing this forum: No registered users and 35 guests