Hello Teline Fans,
I’m using Teline IV J1.6 and the nice date layout in topbar is locked in english and may be a problem for other language users, because the layout may be different (d/m/y) and the day text is obvious different.
Here’s my contribution!
Open in your favorite editor the file templates/ja_teline_iv/blocks/topbar.php and look in the first lines
Original Code
[PHP] <p class=”ja-day clearfix”>
<?php
echo “<span class=”day”>”.date (‘D’).”</span>”;
echo “<span class=”month”>”.date (‘m’).”</span>”;
echo “<span class=”date”>”.date (‘d’).”</span>”;
echo “<span class=”year”>”.date (‘Y’).”</span>”;
?>
</p>[/PHP]
New Code
[PHP] <p class=”ja-day clearfix”>
<?php
setlocale(LC_TIME, ‘pt_BR’);
echo “<span class=”day”>”.strftime(‘%a’).”</span>”;
echo “<span class=”date”>”.strftime(‘%d’).”</span>”;
echo “<span class=”month”>”.strftime(‘%m’).”</span>”;
echo “<span class=”year”>”.strftime(‘%Y’).”</span>”;
?>
</p>[/PHP]
Don’t use LC_ALL and look for your prefix languages, “pt_BR” is my need (Brazilian Portuguese). More settings in the PHP Help:
http://php.net/manual/en/function.setlocale.php
http://php.net/manual/en/function.strftime.php
Saludos!
Haldor Omar