streams/Zotlabs/Widget/Mailmenu.php

40 lines
1 KiB
PHP
Raw Normal View History

2017-03-16 03:56:12 +00:00
<?php
namespace Zotlabs\Widget;
2021-12-02 23:02:31 +00:00
class Mailmenu
{
2017-03-16 03:56:12 +00:00
2021-12-02 23:02:31 +00:00
public function widget($arr)
{
2017-03-16 03:56:12 +00:00
2021-12-03 03:01:39 +00:00
if (!local_channel()) {
2021-12-02 23:02:31 +00:00
return;
2021-12-03 03:01:39 +00:00
}
2017-03-16 03:56:12 +00:00
2021-12-02 23:02:31 +00:00
return replace_macros(get_markup_template('message_side.tpl'), array(
'$title' => t('Private Mail Menu'),
'$combined' => array(
'label' => t('Combined View'),
'url' => z_root() . '/mail/combined',
'sel' => (argv(1) == 'combined'),
),
'$inbox' => array(
'label' => t('Inbox'),
'url' => z_root() . '/mail/inbox',
'sel' => (argv(1) == 'inbox'),
),
'$outbox' => array(
'label' => t('Outbox'),
'url' => z_root() . '/mail/outbox',
'sel' => (argv(1) == 'outbox'),
),
'$new' => array(
'label' => t('New Message'),
'url' => z_root() . '/mail/new',
'sel' => (argv(1) == 'new'),
)
));
}
2017-03-16 03:56:12 +00:00
}