Improved text for multidate events announcements; bumped version to 0.5.1
This commit is contained in:
parent
da718747be
commit
9e82a10bf4
1 changed files with 6 additions and 4 deletions
10
gancioff
10
gancioff
|
@ -18,7 +18,7 @@
|
|||
|
||||
$SNAME='GancioF2F';
|
||||
$ENAME=strtolower($SNAME);
|
||||
$SVERS='0.5';
|
||||
$SVERS='0.5.1';
|
||||
|
||||
require __DIR__.'/lib/ckmkeys.php';
|
||||
require __DIR__.'/lib/gettlds.php';
|
||||
|
@ -398,8 +398,10 @@ foreach ($feed as $item) {
|
|||
$itemsToPost++;
|
||||
$postHead="{$item['title']}\n\n";
|
||||
if ($item['multidate']) {
|
||||
$dfmt=datefmt_create($conf['posts_language'],0,0,$conf['timezone'],null,"eeee d MMMM '"._('alle')."' HH:mm");
|
||||
$postHead.=_('Da').' '.datefmt_format($dfmt,$item['start_datetime']).' '._('a').' '.datefmt_format($dfmt,$item['end_datetime']);
|
||||
$dfmt=datefmt_create($conf['posts_language'],0,0,$conf['timezone'],null,"eeee d MMMM");
|
||||
$postHead.=_('Tutti i giorni da').' '.datefmt_format($dfmt,$item['start_datetime']).' '._('a').' '.datefmt_format($dfmt,$item['end_datetime']).', ';
|
||||
$dfmt=datefmt_create($conf['posts_language'],0,0,$conf['timezone'],null,"HH:mm");
|
||||
$postHead.=_('dalle').' '.datefmt_format($dfmt,$item['start_datetime']).' '._('alle').' '.datefmt_format($dfmt,$item['end_datetime']);
|
||||
} else {
|
||||
$dfmt=datefmt_create($conf['posts_language'],0,0,$conf['timezone'],null,"eeee d MMMM '"._('dalle')."' HH:mm");
|
||||
$postHead.=mb_ucfirst(datefmt_format($dfmt,$item['start_datetime']));
|
||||
|
@ -408,9 +410,9 @@ foreach ($feed as $item) {
|
|||
$postHead.=' '._('alle').' '.datefmt_format($dfmt,$item['end_datetime']);
|
||||
}
|
||||
}
|
||||
// if (isset($item['parentId']))// this probably means it's a recurring event, but i see no way to check *when* it is recurring
|
||||
$postHead.=', '._('presso')." {$item['place']['name']}, {$item['place']['address']}";
|
||||
if (is_array($item['online_locations']) && count($item['online_locations'])>0) $postHead.='; '._('e anche online su ').implode(' - ',$item['online_locations']);
|
||||
// if (isset($item['parentId']))// this probably means it's a recurring event, but i see no way to check *when* it is recurring
|
||||
$postBody='';
|
||||
if (!is_null($item['description']) && $item['description']!='' && $item['description']!='<p></p>') $postBody.=html2text($item['description']);
|
||||
if ($postBody!='') $postBody="\n\n{$postBody}";
|
||||
|
|
Loading…
Reference in a new issue