hello!
i started making new website. , needed module show when company had open. downloaded timeline maker module.. (http://extensions.joomla.org/extensions ... ours/20031)
it works well. shows days , hours if 0 (zero).. example:
00 days 00 hours 20 minutes.. want days , hours deleted if zero. i'm not php. maybe use sourcecode:
sorry english..
hope can help...
i started making new website. , needed module show when company had open. downloaded timeline maker module.. (http://extensions.joomla.org/extensions ... ours/20031)
it works well. shows days , hours if 0 (zero).. example:
00 days 00 hours 20 minutes.. want days , hours deleted if zero. i'm not php. maybe use sourcecode:
code: select all
// result
$arr_vals_office=explode(':', $next_day_office);
$days=0;
$hours=$arr_vals_office[0];
$minutes=$arr_vals_office[1];
if ($arr_vals_office[0]>=24){
$days=intval($arr_vals_office[0]/24);
$hours=$arr_vals_office[0]-(24*$days);
}
$result['next_office_in']=$days.' '.($days==1?jtext::_('tlm_day'):jtext::_('tlm_days')).' '.
$hours.' '.($hours==1?jtext::_('tlm_hour'):jtext::_('tlm_hours')).' '.
$minutes.' '.($minutes==1?jtext::_('tlm_minute'):jtext::_('tlm_minutes'));
$result['next_office_in_date']=$this->formatdate($next_day_office_date,$params->get('date_format'));
}
sorry english..
hope can help...
Comments
Post a Comment