aboutsummaryrefslogtreecommitdiffstats
path: root/mod/friendica.php
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2012-04-30 23:07:52 -0700
committerfriendica <info@friendica.com>2012-04-30 23:07:52 -0700
commitd48cd0f9a3210c14bb98a502188358982261d9df (patch)
treed5b13e587c7b8f2d140b559f3a67fd299afdedd3 /mod/friendica.php
parent25afec0f81961665717e159aba216d1e9d9f9d86 (diff)
downloadvolse-hubzilla-d48cd0f9a3210c14bb98a502188358982261d9df.tar.gz
volse-hubzilla-d48cd0f9a3210c14bb98a502188358982261d9df.tar.bz2
volse-hubzilla-d48cd0f9a3210c14bb98a502188358982261d9df.zip
hidden plugins (add .hidden file to dir)
Diffstat (limited to 'mod/friendica.php')
-rw-r--r--mod/friendica.php23
1 files changed, 20 insertions, 3 deletions
diff --git a/mod/friendica.php b/mod/friendica.php
index 52a064224..28807b5b5 100644
--- a/mod/friendica.php
+++ b/mod/friendica.php
@@ -18,10 +18,18 @@ function friendica_init(&$a) {
$admin = false;
}
+ $visible_plugins = array();
+ if(is_array($a->plugins) && count($a->plugins)) {
+ $r = q("select * from addon where hidden = 0");
+ if(count($r))
+ foreach($r as $rr)
+ $visible_plugins[] = $rr['name'];
+ }
+
$data = Array(
'version' => FRIENDICA_VERSION,
'url' => z_root(),
- 'plugins' => $a->plugins,
+ 'plugins' => $visible_plugins,
'register_policy' => $register_policy[$a->config['register_policy']],
'admin' => $admin,
'site_name' => $a->config['sitename'],
@@ -54,9 +62,18 @@ function friendica_content(&$a) {
$o .= '<p></p>';
- if(count($a->plugins)) {
+ $visible_plugins = array();
+ if(is_array($a->plugins) && count($a->plugins)) {
+ $r = q("select * from addon where hidden = 0");
+ if(count($r))
+ foreach($r as $rr)
+ $visible_plugins[] = $rr['name'];
+ }
+
+
+ if(count($visible_plugins)) {
$o .= '<p>' . t('Installed plugins/addons/apps:') . '</p>';
- $sorted = $a->plugins;
+ $sorted = $visible_plugins;
$s = '';
sort($sorted);
foreach($sorted as $p) {