XHanch Studio Log in | Register | Cart

Forum

Notifications
Clear all

Change Language Settings

3 Posts
2 Users
0 Reactions
3,354 Views
(@rochecr)
Posts: 2
New Member
Topic starter
 

Hello I am using Xhanch Twitter plugin Versión 2.7.5
I need to change the language pluging in order to reflect the month, days names in spanish

Does it support it?

 
Posted : 02/12/2012 12:00 am
(@rochecr)
Posts: 2
New Member
Topic starter
 

If someone can tell me how to change the Days name and Months days I really appreciate

 
Posted : 02/12/2012 3:15 am
(@crosswind)
Posts: 1
New Member Guest
 

had the same problem...

for a german translation  you can try to change the following code:

no warranty but in my case it works. careful with updates!

---

replace:
$periods = array("Sekunde(n)", "Minute(n)", "Stunde(n)", "Tag(e)", "Woche(n)", "Monat(e)", "Jahr(e)", "decade");

with:
$periods = array("Sekunde", "Minute", "Stunde", "Tag", "Woche", "Monat", "Jahr", "decade");
$periodsN = array('Sekunden','Minuten','Stunden','Tagen','Wochen','Monaten','Jahren','decade');

---

replace:

if($now > $unix_date){
$difference = $now - $unix_date;
$tense = "vor";
}else{
$difference = $unix_date - $now;
$tense = "from now";
}

with:

if($now > $unix_date){
$difference = $now - $unix_date;
$tense = "vor %d %s";
}else{
$difference = $unix_date - $now;
$tense = "%d %s from now";
}

---

replace:
if($difference != 1)
$periods[$j].= " ";
$per = __($periods[$j], 'xmt');

with:

if($difference != 1){
$per=__($periodsN[$j],'xmt');
}else{
$per=__($periods[$j],'xmt');
}

---

replace:
return __($tense, 'xmt').' '.$difference.' '.$per;

with:
return sprintf(__($tense, 'xmt'),$difference,$per);

---

 
Posted : 25/02/2013 7:21 pm
Share:

× Close Menu