Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Languages & Translations (http://forum.bytesforall.com/forumdisplay.php?f=11)
-   -   [SOLVED] Messed-up Date (http://forum.bytesforall.com/showthread.php?t=5588)

jdtfk Jan 29, 2010 02:33 PM

[SOLVED] Messed-up Date
 
After installing the translation for spanish for wordpress and atahualpa I crossed with this messed-up date. I even updated the whole Wordpress 2.91 to the Spanish Version (clicked the Update Now button)

The Comment section is correct, although it lacks the comma, but the Post section is still in english format: 22nd

I'm lost. I even selected another format m/d/Y, but nothing changed. Any help would be appreciated.

jdtfk Feb 1, 2010 09:15 AM

Ok, poking around I stumbled into bfa_postinfo.php

Code:

        // Date & Time
        if ( strpos($postinfo_string,'%date(') !== FALSE ) {
                $date_param = preg_match("/(.*)\%date\('(.*?)'\)(.*)/i",$postinfo_string,$date_matches);
                ob_start();
                        the_time($date_matches[2]);
                        $date = ob_get_contents();
                ob_end_clean();
                $postinfo = preg_replace("/(.*)%date\((.*?)\)%(.*)/i", "\${1}" .
        $date. "\${3}", $postinfo);
        }

I assume here's where the trouble is. I'm just wondering how to edit this, or how to work this out.

jdtfk Feb 2, 2010 07:46 AM

Found the solution.

I didn't check the ATO -> Edit Post/Page info items.
The date was set to ('F jS, Y') So it didn't matter what I had in the General Options.

S is English ordinal suffix for the day of the month, 2 characters: st, nd, rd or th.

More info here: http://php.net/manual/en/function.date.php


All times are GMT -6. The time now is 11:44 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.