VirtueMart Forum

VirtueMart 2 + 3 + 4 => Templating & Layouts => Topic started by: Pcwolf on February 02, 2014, 17:13:11 PM

Title: How i can delete css Display:block ?
Post by: Pcwolf on February 02, 2014, 17:13:11 PM
Hello,

I just can't find out how i can delete this. In template overrides (category) i found this:

<div class="product-price marginbottom12" id="productPrice<?php echo $product->virtuemart_product_id ?>">
<?php
if ($this->show_prices == '1') {
if ($product->prices['salesPrice']<=and VmConfig::get ('askprice'1) and  !$product->images[0]->file_is_downloadable) {
echo JText::('COM_VIRTUEMART_PRODUCT_ASKPRICE');
}
//todo add config settings
if ($this->showBasePrice) {
echo $this->currency->createPriceDiv ('basePrice''COM_VIRTUEMART_PRODUCT_BASEPRICE'$product->prices);
echo $this->currency->createPriceDiv ('basePriceVariant''COM_VIRTUEMART_PRODUCT_BASEPRICE_VARIANT'$product->prices);
}
echo $this->currency->createPriceDiv ('variantModification''COM_VIRTUEMART_PRODUCT_VARIANT_MOD'$product->prices);
if (round($product->prices['basePriceWithTax'],$this->currency->_priceConfig['salesPrice'][1]) != $product->prices['salesPrice']) {
echo '<div class="price-crossed" >' $this->currency->createPriceDiv ('basePriceWithTax''COM_VIRTUEMART_PRODUCT_BASEPRICE_WITHTAX'$product->prices) . "</div>" 
}
if (round($product->prices['salesPriceWithDiscount'],$this->currency->_priceConfig['salesPrice'][1]) != $product->prices['salesPrice']) {
echo $this->currency->createPriceDiv ('salesPriceWithDiscount''COM_VIRTUEMART_PRODUCT_SALESPRICE_WITH_DISCOUNT'$product->prices);
}
echo $this->currency->createPriceDiv ('salesPrice''COM_VIRTUEMART_PRODUCT_SALESPRICE'$product->prices);
if ($product->prices['discountedPriceWithoutTax'] != $product->prices['priceWithoutTax']) {
echo $this->currency->createPriceDiv ('discountedPriceWithoutTax''COM_VIRTUEMART_PRODUCT_SALESPRICE_WITHOUT_TAX'$product->prices);
} else {
echo $this->currency->createPriceDiv ('priceWithoutTax''COM_VIRTUEMART_PRODUCT_SALESPRICE_WITHOUT_TAX'$product->prices);
}
echo $this->currency->createPriceDiv ('discountAmount''COM_VIRTUEMART_PRODUCT_DISCOUNT_AMOUNT'$product->prices);
echo $this->currency->createPriceDiv ('taxAmount''COM_VIRTUEMART_PRODUCT_TAX_AMOUNT'$product->prices);
$unitPriceDescription JText::sprintf ('COM_VIRTUEMART_PRODUCT_UNITPRICE'$product->product_unit);
echo $this->currency->createPriceDiv ('unitPrice'$unitPriceDescription$product->prices);
?>


</div>


So it's only said: CreatePriceDiv tag  ???

This is what i want, created with display:inline-block;

(http://i61.tinypic.com/2dl918j.png)

I need to disable display:block

(http://i58.tinypic.com/zv6lt.png)

So what i want is how i can delete the

element.style {
    display: block;
}

Here is my demo site: http://6205.cloudaccess.net/nl/ (http://6205.cloudaccess.net/nl/)
Title: Re: How i can delete css Display:block ?
Post by: jenkinhill on February 02, 2014, 18:53:41 PM
So they are generated inline-styles.


<div class="PricesalesPrice" style="display : block;">
Bedrag
<span class="PricesalesPrice">7,00 €</span>
</div>
<div class="PricediscountAmount" style="element.style">
Korting
<span class="PricediscountAmount">-3,00 €</span>


When I see something like this I use ReReplacer (http://extensions.joomla.org/extensions/edition/replace/4336). So "PricesalesPrice" style="display : block;" could be replaced on the fly by, for example  "PricesalesPrice" style="display : inline;"

This save a lot of time and does not require editing any core files - or even needing to search for the right file!
Title: Re: How i can delete css Display:block ?
Post by: Pcwolf on February 03, 2014, 10:38:33 AM
Aah jenkinhill, thank you mate! ;D ;)