From 342fda94e4162634eeb67c18c1d284e7d78f217f Mon Sep 17 00:00:00 2001 From: redmatrix Date: Thu, 18 Feb 2016 15:24:58 -0800 Subject: Provide Zotlabs\Project and System class for querying details about the project/version info. Move these out of /boot.php --- mod/help.php | 2 +- mod/import.php | 2 +- mod/linkinfo.php | 2 +- mod/settings.php | 2 +- mod/siteinfo.php | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) (limited to 'mod') diff --git a/mod/help.php b/mod/help.php index 1539978f7..19bf251bd 100644 --- a/mod/help.php +++ b/mod/help.php @@ -160,7 +160,7 @@ function help_content(&$a) { $path = trim(substr($dirname,4),'/'); $o .= '
  • ' . ucwords(str_replace('_',' ',notags($fname))) . '
    ' . - str_replace('$Projectname',get_platform_name(),substr($rr['text'],0,200)) . '...

  • '; + str_replace('$Projectname',Zotlabs\Project\System::get_platform_name(),substr($rr['text'],0,200)) . '...

    '; } $o .= ''; diff --git a/mod/import.php b/mod/import.php index 0bbd38ffe..184159585 100644 --- a/mod/import.php +++ b/mod/import.php @@ -120,7 +120,7 @@ function import_account(&$a, $account_id) { notice($t); } if(array_key_exists('server_role',$data['compatibility']) - && $data['compatibility']['server_role'] != get_server_role()) { + && $data['compatibility']['server_role'] != Zotlabs\Project\System::get_server_role()) { notice( t('Server platform is not compatible. Operation not permitted.') . EOL); return; } diff --git a/mod/linkinfo.php b/mod/linkinfo.php index 5d9e2bc67..07eaa02a0 100644 --- a/mod/linkinfo.php +++ b/mod/linkinfo.php @@ -115,7 +115,7 @@ function linkinfo_content(&$a) { // If this is a Red site, use zrl rather than url so they get zids sent to them by default - if( x($siteinfo,'generator') && (strpos($siteinfo['generator'], get_platform_name() . ' ') === 0)) + if( x($siteinfo,'generator') && (strpos($siteinfo['generator'], Zotlabs\Project\System::get_platform_name() . ' ') === 0)) $template = str_replace('url','zrl',$template); if($siteinfo["title"] == "") { diff --git a/mod/settings.php b/mod/settings.php index ea9c73435..467cccfc7 100644 --- a/mod/settings.php +++ b/mod/settings.php @@ -1044,7 +1044,7 @@ function settings_content(&$a) { '$h_prv' => t('Security and Privacy Settings'), '$permissions_set' => $permissions_set, - '$server_role' => get_server_role(), + '$server_role' => Zotlabs\Project\System::get_server_role(), '$perms_set_msg' => t('Your permissions are already configured. Click to view/adjust'), '$hide_presence' => array('hide_presence', t('Hide my online presence'),$hide_presence, t('Prevents displaying in your profile that you are online'), $yes_no), diff --git a/mod/siteinfo.php b/mod/siteinfo.php index f7423506f..29c7d7d2c 100644 --- a/mod/siteinfo.php +++ b/mod/siteinfo.php @@ -12,7 +12,7 @@ function siteinfo_init(&$a) { function siteinfo_content(&$a) { if(! get_config('system','hidden_version_siteinfo')) { - $version = sprintf( t('Version %s'), get_project_version()); + $version = sprintf( t('Version %s'), Zotlabs\Project\System::get_project_version()); if(@is_dir('.git') && function_exists('shell_exec')) { $commit = @shell_exec('git log -1 --format="%h"'); $tag = get_std_version(); // @shell_exec('git describe --tags --abbrev=0'); -- cgit v1.2.3