Skip to main content

Display "Available in 24/48h" for some products ot

More
12 years 6 months ago #147697 by raulpiscoi
-- url of the page with the problem -- : www.airsoft-romania.com
-- HikaShop version -- : 2.2.3
-- Joomla version -- : 2.5.19
-- PHP version -- : 5.3

Hi,
How can I display the message "Available in 24h/48h" for some products that are out of stock?

Regards,
Raul

Please Log in or Create an account to join the conversation.

More
12 years 6 months ago #147734 by Xavier
Hi,

I think that the best way is to create a custom field on the product table.
For example, "availability", for the desired products set the value 24/48h for this custom field in the product edition page.

Then edit the view "product / quantity" and replace the line:
Code:
echo JText::_('NO_STOCK').'<br/>';
By:
Code:
if(!empty($this->row->availability)){ echo JText::sprintf('AVAILABLE_IN',$this->row->availability).'<br/>'; }else{ echo JText::_('NO_STOCK').'<br/>'; }
And add the following line in the translation file:

AVAILABLE_IN="Available in %s"


By this way you will have the desired result, and you can set different periods of times for different products.
The following user(s) said Thank You: raulpiscoi

Please Log in or Create an account to join the conversation.

More
12 years 6 months ago #147843 by raulpiscoi
It works like a charm :)

Regards,
Raul

Please Log in or Create an account to join the conversation.

Time to create page: 0.167 seconds
Powered by Kunena Forum