VirtueMart Forum

VirtueMart Dev/Coding Central: VM1 (old version) => Virtuemart 1.1 Development (Archiv) => Quality & Testing VirtueMart 1.1.x => Topic started by: mauri on April 28, 2008, 22:21:51 pm

Title: [TRACKER 2055] Orders date not locale language
Post by: mauri on April 28, 2008, 22:21:51 pm
I´am using J!1.5.3 and VM 1.1.0 stable.
Both have finnish languages and them works.
In backend orders, account orders and order e-mails the date is in english(Monday, 28 April 2008).
In virtuemart_parser.php have $mosConfig_locale and I think J!1.5.x don´t use it anymore.
virtuemart_parser.php
Line 127 @setlocale( LC_TIME, $mosConfig_locale );

I changed it :

$language =& JFactory::getLanguage();
$locale = $language->getTag();
@setlocale( LC_TIME, $locale );

Now dates are finnish(locale fi-FI)
Title: Re: Orders date not locale language
Post by: kirbislechat on April 29, 2008, 08:40:04 am
Thank you Mauri, it's a very useful tip. It work for me in French.
Title: Re: Orders date not locale language
Post by: mauri on April 29, 2008, 16:55:18 pm
Oletan että käytössäsi on J!1.5

2. Tätä tutkiessa törmäsin ilmeiseen bugiin. Voitko toimia testaajana ja tehdä seuraavan "fixin".
Avaa palvelimelta /components/com_virtuemart/virtuemart_parser.php
Etsi(Rivillä noin 127):
@setlocale( LC_TIME, $mosConfig_locale );

Muuta rivi näin:
$language =& JFactory::getLanguage();
$locale = $language->getTag();
@setlocale( LC_TIME, $locale );

Fixi näytti toimivan, tuli seuraavanlainen päivämäärä:
Tilauspäivä:     maanantai, 28 huhtikuu 2008 00:15
*****
Comment from finnish forum http://www.joomlaportal.fi
Translate:
Fix seemed to be operating, the following date came:
Order date:   maanantai, 28 huhtikuu 2008 00:15

I add this to tracker.
Title: Re: [TRACKER 2055] Orders date not locale language
Post by: marctoms on May 07, 2008, 10:50:49 am
Thank You for this post!!

Function too german.
Title: Re: [TRACKER 2055] Orders date not locale language
Post by: atolero on May 08, 2008, 16:52:00 pm
thank you, very usefeul
Title: Re: [TRACKER 2055] Orders date not locale language
Post by: atolero on May 08, 2008, 16:58:45 pm
i still get a 4 hours delay time, but the language is ok now. any suggestion?
Title: Re: [TRACKER 2055] Orders date not locale language
Post by: mauri on May 09, 2008, 10:08:12 am
Quote
i still get a 4 hours delay time, but the language is ok now. any suggestion?
Have you try:
Joomla! GlobalConfiguration -> Server -> Time Zone
Title: Re: [TRACKER 2055] Orders date not locale language
Post by: juppjupp on May 09, 2008, 14:28:01 pm
hi mauri, do you know if this http://forum.virtuemart.net/index.php?topic=39954.0

is related to your problem (localized version)? I can´t find any solutions to my problem...   :(
Title: Re: [TRACKER 2055] Orders date not locale language
Post by: mauri on May 10, 2008, 18:06:18 pm
hi mauri, do you know if this http://forum.virtuemart.net/index.php?topic=39954.0
is related to your problem (localized version)? I can´t find any solutions to my problem...   :(
Check:
administrator/components/com_virtuemart/languages/common/norwegian.php
BUTTON_LOGOUT
NO_ACCOUNT
CREATE_ACCOUNT
If these are tranlated to norge.
Title: Re: [TRACKER 2055] Orders date not locale language
Post by: dac3d on July 23, 2008, 11:04:12 am
exelent work! thanks a loot!
Title: Re: [TRACKER 2055] Orders date not locale language
Post by: killeron on January 15, 2009, 08:47:26 am
Using J!1.5.9 and VM 1.1.2 stable.
Strange but when system legacy plugin is enabled the
Code: [Select]
@setlocale( LC_TIME, $mosConfig_locale ); gives english names on date but not with legacy disabled then
Code: [Select]
$language =& JFactory::getLanguage();
$locale = $language->getTag();
@setlocale( LC_TIME, $locale );
works

Last one works either way..