PEAK XOOPS - d3pipes and calendar format in englishin japanese

d3pipes and calendar format

  • You cannot open a new topic into this forum
  • Guests cannot post into this forum
Previous post - Next post | Parent - Children.1 | Posted on 2008/10/26 19:54
hamid  Private   Posts: 2
Hi Gijoe
We use d3pipe on persian xoops support website, but we have one problem,
Whene we change xoops language to persian all of modules use Jalali Calendar, but d3pipes use gregorian calendar and we can't change It.
For example in this page I want change publish time to this format ( 1/4/1387 or 1 فروردين 1387 )like other modules that we use.

http://www.irxoops.org/modules/d3pipes/

regards
Votes:13 Average:7.69
Previous post - Next post | Parent - Children.1 | Posted on 2008/10/30 18:32
GIJOE  Gunnery Sergeant   Posts: 4110
hi hamid.

Quote:

We use d3pipe on persian xoops support website, but we have one problem,
Whene we change xoops language to persian all of modules use Jalali Calendar, but d3pipes use gregorian calendar and we can't change It.
Just an issue of your language constants or templates.

d3pipes displays datetime like:

				<{$smarty.const._MEDIUMDATESTRING|date:$entry.pubtime+$timezone_offset}>

Check _MEDIUMDATESTRING of your language set.
Or, modify the template as you like.
Votes:18 Average:7.22
Previous post - Next post | Parent - Children.1 | Posted on 2009/2/27 11:56 | Last modified
irmtfan  Sergeant   Posts: 96
Hi GIJ
the problem is not in the format of displaying but in how to fetch and parse hegira dates.
now you use date function like this:
date:$entry.pubtime+$timezone_offset
but for persians it should be localize in the way they can fetch and parse from other persian sites.
in xoops we localize "formatTimestamp" function for this purpose therefor if you show me where this "pubtime" come from (in which files) maybe i can change it. but it seems it is not that simple.

EDIT:
ok i add formatTimestamp like this:
<{$entry.pubtime|formatTimestamp}>

now it shows correct but i want to add $timezone_offset too. could you help me?
Votes:15 Average:8.00
Previous post - Next post | Parent - No child | Posted on 2009/3/31 5:16
GIJOE  Gunnery Sergeant   Posts: 4110
Quote:

irmtfan wrotes:
ok i add formatTimestamp like this:
<{$entry.pubtime|formatTimestamp}>

now it shows correct but i want to add $timezone_offset too. could you help me?

Though I don't know formatTimestamp() for persian...
try it once
				<{$entry.pubtime|formatTimestamp:"l":$timezone_offset}>
Votes:7 Average:10.00

  Advanced search


Login
Username or e-mail:

Password:

Remember Me

Lost Password?

Register now!