Home › Forums › WoodMart support forum › Price From £…
Price From £…
- This topic has 12 replies, 2 voices, and was last updated 4 years ago by Elise Noromit.
-
AuthorPosts
-
November 18, 2020 at 12:19 pm #242572
T1mediaParticipantHi Guys
I have found the option Hide “to” price
This option will hide a higher price for variable products and leave only a small one. this is great for us. However we would like to put the word “From” before the price. So it would show From: £79.00 in which php file and where would i ann this please? This only needs to show on variable productsI found some code online but this returns £0:00
add_filter(‘woocommerce_variable_price_html’, ‘custom_variation_price’, 10, 2);
function custom_variation_price( $price, $product ) {
$price = ‘From: ‘;
$price .= woocommerce_price($product->min_variation_price);
$price .= ‘ – ‘;
$price .= woocommerce_price($product->max_variation_price);
return $price;
}November 18, 2020 at 12:56 pm #242599
Elise NoromitMemberHello,
Thank you very much for choosing our theme and for contacting us.
Please add this code to the Theme Settings > Custom CSS > Global:
.price:before{ content:"from "; }
Best Regards
November 18, 2020 at 12:58 pm #242606
T1mediaParticipantthank you i just tried this
http://www.t1media.co.uk/bed/product/reo-mattress/
I just get a white space.November 18, 2020 at 1:00 pm #242607
T1mediaParticipantalso, this only needs to show on variable product please. PS YOUR THEME IS AMAZING!
November 18, 2020 at 3:54 pm #242657
Elise NoromitMemberHello,
Please add this code to the Theme Settings > Custom CSS > Global:
.price span.amount:before { content:"from " }
Best Regards
November 18, 2020 at 3:57 pm #242662
T1mediaParticipantyes thank you that shows, now, i only want it on variable products, how is this done please?
November 19, 2020 at 12:46 pm #242889
Elise NoromitMemberHello,
Please replace the code for this one:
.product-type-variable .price:before{ content:"from "; }
Best Regards
November 19, 2020 at 12:48 pm #242890
T1mediaParticipantthank you i have tried that, it leaves just white space
http://www.t1media.co.uk/bed/product-category/beds/November 19, 2020 at 12:56 pm #242898
Elise NoromitMemberHello,
What do you mean? The price is shown and “from” is added both in grid https://prnt.sc/vm5tth and in the product page: https://prnt.sc/vm5ulk
If you mean the variable product should have the price range, disable “Hide “to” price” in the Theme Settings > Shop page.
Please show me the screen, what the empty space you mean.
Best Regards
November 19, 2020 at 1:00 pm #242902
T1mediaParticipantI have attached a screen shot for you. and thank you i see the others, just not in list view
November 20, 2020 at 10:18 am #243121
Elise NoromitMemberHello,
Please remove all the code I provided before and add this one:
.product-type-variable .price span.amount:before { content:"from " }
Best Regards
November 20, 2020 at 12:51 pm #243163
T1mediaParticipantthank you, one last question on mobile, when you click the menu tab, you get shown menu first, i want categories first. how can we do this please? See attachment
Attachments:
You must be logged in to view attached files.November 20, 2020 at 1:55 pm #243180
Elise NoromitMemberHello,
Please switch to the mobile view of the Header and enter the Mobile menu item, you will find the option “Swap menu” https://prnt.sc/vmuzya
This option would exchange the tabs on the mobile menu.
Best Regards
-
AuthorPosts
- You must be logged in to create new topics. Login / Register