VirtueMart Forum

VirtueMart 2 + 3 + 4 => Templating & Layouts => Topic started by: pm4698 on October 21, 2014, 12:25:06 PM

Title: CSS final price at no discount
Post by: pm4698 on October 21, 2014, 12:25:06 PM
Hello there,

I use virtuemart 2.6.10 and joomla 2.5.x and i was wondering at category layout how to do this:

I have set up really nice below product Title a row with prices at left and quantity-addtocart buttons at right. When i have discount then prices show up good. When i don't have discount, then salesprice shows up to top position of div. How could i make this final price get stuck at bottom or middle, either i have discount or not? Thank you in advance
Title: Re: CSS final price at no discount
Post by: jenkinhill on October 21, 2014, 13:13:06 PM
Impossible to advise without a URL.
Title: Re: CSS final price at no discount
Post by: pm4698 on October 21, 2014, 13:50:48 PM
http://petcity.gr/neweshop/index.php/dog/dog-food/solid-food-dog

Check 2nd row of products. 1st has discount price 2nd and 3rd not. I would like for non-discount products the red price to appear at bottom or middle if possible
Title: Re: CSS final price at no discount
Post by: GJC Web Design on October 21, 2014, 18:41:19 PM
don't see how you can do it with css alone

the div Price-old-price is what is pushing down the PricesalesPrice div
if it isn't there then it will be where it is

You need either logic to provide a blank Price-old-price, or if Price-old-price is empty to add a class to PricesalesPrice which will have some top margin
Title: Re: CSS final price at no discount
Post by: pm4698 on October 22, 2014, 09:05:43 AM
You were right.

I added an else to the if responsible to check if there is a discount in order to show old price and echoed a div with min-height.

Problem solved!