Greetings,
I want to make a few changes in the available options, like bold titles and separate them with lines.
As shown in the picture, what is highlighted needs to be bold and where there is the red line, needs to be added a separation line.
Is it possible? I tried myself but had no luck so far.
Thanks in advance.
I want to make a few changes in the available options, like bold titles and separate them with lines.
As shown in the picture, what is highlighted needs to be bold and where there is the red line, needs to be added a separation line.
Is it possible? I tried myself but had no luck so far.
Thanks in advance.
Attachments
options.PNG (26.48 KiB) Viewed 801 times
You can add <hr> after each line: {% if option.type == 'radio' %}, {% if option.type == 'checkbox' %}, etc...
Upgrade Service | OC 2.3.0.2 PHP 8 | My Custom OC 3.0.3.8 | Buy me a beer
The website link and product page is here
I have tried to edit product.twig in public_html/catalog/view/theme/simplica/template/product but no changes appeared.
"Have you cleared ALL caches ??"
It may sound as a stupid question, but should I clear all the caches?
Thank you
Don't forget to refresh Ocmod modifications, clear Theme cache and Sass cache from Dashboard, right top gear.
Upgrade Service | OC 2.3.0.2 PHP 8 | My Custom OC 3.0.3.8 | Buy me a beer
well now I can see all the changes I'm making.

Still, adding lines exactly where I want isn't so easy. Same for bolding text.
Code: Select all
<div id="product"> {% if options %}
<hr>
<h3>{{ text_option }}</h3>
{% for option in options %}
{% if option.type == 'select' %}
<div class="form-group{% if option.required %} required {% endif %}">
<label class="control-label" for="input-option{{ option.product_option_id }}">{{ option.name }}</label>
<select name="option[{{ option.product_option_id }}]" id="input-option{{ option.product_option_id }}" class="form-control">
<option value="">{{ text_select }}</option>
{% for option_value in option.product_option_value %}
<option value="{{ option_value.product_option_value_id }}">{{ option_value.name }}
{% if option_value.price %}
({{ option_value.price_prefix }}{{ option_value.price }})
{% endif %} </option>
{% endfor %}
</select>
</div>
{% endif %}
Like this?
For bold, size...you can make CSS changes.
Attachments
Screenshot_2020-03-01_15-49-51.png (44.9 KiB) Viewed 715 times
Upgrade Service | OC 2.3.0.2 PHP 8 | My Custom OC 3.0.3.8 | Buy me a beer
I did it!!!

If you see the picture, there is a text line "OCHI DREPT" which is made as a checkbox option whithout options so it appeares as a title. I had only to add a line before it and voi la, done.
Now for the text bolding....
Attachments
option 1.PNG (24.21 KiB) Viewed 707 times
You can replace <hr> with <hr class="my_hr"> then in you theme css you can use:
Code: Select all
hr.my_hr{
border-top: 6px solid #8c8b8b;
}
Upgrade Service | OC 2.3.0.2 PHP 8 | My Custom OC 3.0.3.8 | Buy me a beer
Who is online
Users browsing this forum: 7cswinery and 62 guests