SOLVED!!!
I have chosen the "Products Out of Stock are orderable, and the field 'Availability' below is displayed"
I face the same problem and i cannot fixed it, although i tried what you have said at the previous posts
First code from /components/com_virtuemart/views/productdetails/tmpl/default.php
Code: [Select]
<?php
// Availability Image
$stockhandle = VmConfig::get('stockhandle', 'none');
if (($this->product->product_in_stock - $this->product->product_ordered) < 1) {
if ($stockhandle == 'risetime' and VmConfig::get('rised_availability') and empty($this->product->product_availability)) {
?> <div class="availability">
<?php echo (file_exists(JPATH_BASE . DS . VmConfig::get('assets_general_path') . 'images/availability/' . VmConfig::get('rised_availability'))) ? JHTML::image(JURI::root() . VmConfig::get('assets_general_path') . 'images/availability/' . VmConfig::get('rised_availability', '7d.gif'), VmConfig::get('rised_availability', '7d.gif'), array('class' => 'availability')) : VmConfig::get('rised_availability'); ?>
</div>
<?php
} else if (!empty($this->product->product_availability)) {
?>
<div class="availability">
<?php echo (file_exists(JPATH_BASE . DS . VmConfig::get('assets_general_path') . 'images/availability/' . $this->product->product_availability)) ? JHTML::image(JURI::root() . VmConfig::get('assets_general_path') . 'images/availability/' . $this->product->product_availability, $this->product->product_availability, array('class' => 'availability')) : $this->product->product_availability; ?>
</div>
<?php
}
}
?>
Second code from /templates/theme310/html/com_virtuemart/productdetails/default.php
Code: [Select]
<?php
// Availability Image
/* TO DO add width and height to the image */
if (!empty($this->product->product_availability)) {
$stockhandle = VmConfig::get('stockhandle', 'none');
if ($stockhandle == 'risetime' and ($this->product->product_in_stock - $this->product->product_ordered) < 1) {
?> <div class="availability">
<?php echo JHTML::image(JURI::root() . VmConfig::get('assets_general_path') . 'images/availability/' . VmConfig::get('rised_availability', '7d.gif'), VmConfig::get('rised_availability', '7d.gif'), array('class' => 'availability')); ?>
</div>
<?php } else {
?>
<div class="availability">
<?php echo JHTML::image(JURI::root() . VmConfig::get('assets_general_path') . 'images/availability/' . $this->product->product_availability, $this->product->product_availability, array('class' => 'availability')); ?>
</div>
<?php
}
}
?>
If i copy/paste/overwrite the first code at the second one, then with some changes at < 1, > 1, > 0 and the number at the product status 0 or 100, then the 24h.gif it appears, but the whole product layout is being "damaged"
If i change at the second code the < 1, > 1, > 0 and the number at the product status 0 or 100, then no *.gif appears ever, and have no changes at the product layout.