In WPLMS 1.5.3 we’ve now added a hook to customize the durations in your own labels.
These are labels such as Year, Month, week, day, hour, minute, second , since these are taken directly from conversion of time, these could not be added into translation files.
Using this tip you can customize the names of these labels using WPLMS Customizer plugin.
0. Install the WPLMS Customizer plugin.
1. Go to WP Admin -> Plugins -> Editor -> WPLMS Customizer -> customizer_class.php
2. Add following code in the _construct function:
PHP Code:
add_filter('wplms_time_labels',array($this,'wplms_time_labels'));
3. Add following code in the class :
PHP Code:
function wplms_time_labels($label){ switch($label){ case 'year': $label = 'godina'; break; case 'years': $label = 'godinas'; break; case 'month': $label = 'mjeseci'; break; case 'months': $label = 'mjesecis'; break; case 'week': $label = 'tjedna'; break; case 'weeks': $label = 'tjednas'; break; case 'day': $label = 'dana'; break; case 'days': $label = 'danas'; break; case 'hour': $label = 'sati'; break; case 'hours': $label = 'satis'; break; case 'minute': $label = 'minuta'; break; case 'minutes': $label = 'minutas'; break; case 'second': $label = 'sekundi'; break; case 'seconds': $label = 'sekundis'; break; } return $label; }