This repository has been archived on 2024-08-19. You can view files and clone it, but cannot push or open issues or pull requests.
core/Zotlabs/Widget/Notes.php
2018-09-24 11:46:18 +02:00

30 lines
511 B
PHP

<?php
namespace Zotlabs\Widget;
use Zotlabs\Lib\Apps;
class Notes {
function widget($arr) {
if(! local_channel())
return EMPTY_STR;
if(! Apps::system_app_installed(local_channel(), 'Notes'))
return EMPTY_STR;
$text = get_pconfig(local_channel(),'notes','text');
$tpl = get_markup_template('notes.tpl');
$o = replace_macros($tpl, array(
'$banner' => t('Notes'),
'$text' => $text,
'$save' => t('Save'),
'$app' => ((isset($arr['app'])) ? true : false)
));
return $o;
}
}