[pmwiki-users] problem with utf-8 chars and TimeFmt

Sebastian Siedentopf schlaefer at macnews.de
Thu Mar 2 04:28:45 CST 2006


Am 01.03.2006 um 19:00 schrieb Patrick R. Michaud:

> On Wed, Mar 01, 2006 at 01:31:46PM +0100, Sebastian Siedentopf wrote:
> If that doesn't work, you might try using utf8_encode around the
> date/time strings that PmWiki generates.  Try the following in
> local/config.php:
>
>     $FmtPV['$LastModified'] =
>       'utf8_encode(strftime($GLOBALS["TimeFmt"], $page["time"]))';
>     $CurrentTime = utf8_encode(strftime($TimeFmt,$Now));

This was my solution for $CurrentTime too. {$LastModified} works  
also. The history is a little bit tricky and I haven't found a  
solution without modifying one of the core files. Beside just putting

     $FmtV['$DiffTime'] = utf8_encode(strftime($TimeFmt,$diffgmt));

into the pagerev.php the most flexible I can think of is

     $DiffStartFmt = "<div class='diffbox'><div class='difftime'>\ 
$DiffTimeUTF-8 ...";
     $FmtPV['$DiffTimeUTF-8'] = 'utf8_encode($FmtV[\'$DiffTime\'])';

in the config.php, if $FmtV would be a global variable in PageVar().

Thanks
Sebastian

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 2369 bytes
Desc: not available
Url : /pipermail/pmwiki-users/attachments/20060302/c26a569f/attachment.bin 


More information about the pmwiki-users mailing list