1
Xtracted
Translation - short date string?
  • 2004/5/1 11:47

  • Xtracted

  • Not too shy to talk

  • Posts: 138

  • Since: 2004/1/7 2


I am trying to find where the code for the short date string is.. Its not at the same place as the full date strings ("January") etc in the database.. anyone who can guide me to the right place?

2
rabideau
Re: Translation - short date string?
  • 2004/5/1 12:00

  • rabideau

  • Home away from home

  • Posts: 1042

  • Since: 2003/4/25


Perhaps the calendar.php file in your language files will help?.?..

3
Herko
Re: Translation - short date string?
  • 2004/5/1 12:33

  • Herko

  • XOOPS is my life!

  • Posts: 4238

  • Since: 2002/2/4 1


No, that can be found in the languages/yourlanguage/global.php file, way down at the bottom.

Herko

4
Xtracted
Re: Translation - short date string?
  • 2004/5/1 18:47

  • Xtracted

  • Not too shy to talk

  • Posts: 138

  • Since: 2004/1/7 2


I have looked there but I cant figure out what to change in the global file so it shows what I want it to.. There is no definition that says "Mon" "Tue" etc.. What code do I have to change?

5
Dave_L
Re: Translation - short date string?
  • 2004/5/1 19:02

  • Dave_L

  • XOOPS is my life!

  • Posts: 2277

  • Since: 2003/11/7


The format codes are those used by the PHP date function. "D" is the format code you're looking for.

If you'll provide a complete example of how you want the date displayed, we can provide the format string.

6
Xtracted
Re: Translation - short date string?
  • 2004/5/2 12:23

  • Xtracted

  • Not too shy to talk

  • Posts: 138

  • Since: 2004/1/7 2


I dont think that you understand what I want here, but here we go.. =)


A short datestring that looks like this: "Mon 05 Apr 2004" should look like this: "Mån 05 Apr 2004"

So, I want the shorted names of the days translated like this:

Mon - Mån
Tue - Tis
Wed - Ons
Thu - Tor
Fri - Fre
Sat - Lör
Sun - Sön

7
Xtracted
Re: Translation - short date string?
  • 2004/5/3 11:57

  • Xtracted

  • Not too shy to talk

  • Posts: 138

  • Since: 2004/1/7 2


Well, anyone? I havent been able to figure out where and how to change it..

8
Dave_L
Re: Translation - short date string?
  • 2004/5/3 12:08

  • Dave_L

  • XOOPS is my life!

  • Posts: 2277

  • Since: 2003/11/7


I don't know if PHP has the capability to "localize" the month names like that in its date function.

A quick and dirty solution would be to hardcode the names into the function formatTimestamp in include/functions.php. That's where those format strings are translated into date strings.

9
Xtracted
Re: Translation - short date string?
  • 2004/5/6 20:29

  • Xtracted

  • Not too shy to talk

  • Posts: 138

  • Since: 2004/1/7 2


Um.. and how would I do that.. ? =)

10
risto
Re: Translation - short date string?
  • 2005/6/28 12:07

  • risto

  • Not too shy to talk

  • Posts: 159

  • Since: 2003/4/16


well PHP can doo this.
It should be :
setlocale (LC_ALL'no_NO.ISO8859-1');
for norwegian

It works nicly in a separet script, mut in XOOPS its not working. something is in the way. Can't find out what.
......

Login

Who's Online

260 user(s) are online (154 user(s) are browsing Support Forums)


Members: 0


Guests: 260


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits