X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Ffriendika.php;h=1f3df565d693b1ccabc3376cf8f6aac3f7d0d384;hb=60871555f539caec07f2dcfe37f11fc090bac1be;hp=b12110bd5402a267da7d5ebc2eef1aca20314ced;hpb=273594af62c960b5a52da5ec1cf6d6bd450415ba;p=friendica.git diff --git a/mod/friendika.php b/mod/friendika.php index b12110bd54..1f3df565d6 100644 --- a/mod/friendika.php +++ b/mod/friendika.php @@ -1,68 +1,11 @@ argv[1]=="json"){ - $register_policy = Array('REGISTER_CLOSED', 'REGISTER_APPROVE', 'REGISTER_OPEN'); - - if (isset($a->config['admin_email']) && $a->config['admin_email']!=''){ - $r = q("SELECT username, nickname FROM user WHERE email='%s'", $a->config['admin_email']); - $admin = array( - 'name' => $r[0]['username'], - 'profile'=> $a->get_baseurl().'/profile/'.$r[0]['nickname'], - ); - } else { - $admin = false; - } - - $data = Array( - 'version' => FRIENDIKA_VERSION, - 'url' => z_root(), - 'plugins' => $a->plugins, - 'register_policy' => $register_policy[$a->config['register_policy']], - 'admin' => $admin, - 'site_name' => $a->config['sitename'], - 'platform' => FRIENDIKA_PLATFORM, - 'info' => ((x($a->config,'info')) ? $a->config['info'] : '') - ); +require_once('mod/friendica.php'); - echo json_encode($data); - killme(); - } +function friendika_init(&$a) { + friendica_init($a); } - - function friendika_content(&$a) { - - $o = ''; - $o .= '

Friendika

'; - - - $o .= '

'; - - $o .= t('This is Friendika version') . ' ' . FRIENDIKA_VERSION . ' '; - $o .= t('running at web location') . ' ' . z_root() . '

'; - - $o .= t('Please visit Project.Friendika.com to learn more about the Friendika project.') . '

'; - - $o .= t('Bug reports and issues: please visit') . ' ' . 'Bugs.Friendika.com

'; - $o .= t('Suggestions, praise, donations, etc. - please email "Info" at Friendika - dot com') . '

'; - - $o .= '

'; - - if(count($a->plugins)) { - $o .= '

' . t('Installed plugins/addons/apps') . '

'; - $o .= ''; - } - else - $o .= '

' . t('No installed plugins/addons/apps'); - - call_hooks('about_hook', $o); - - return $o; - + return friendica_content($a); }