Nextcloud PHP API (stable19)

App

This class provides functions to manage apps in ownCloud

Tags
since
4.0.0
deprecated
14.0.0

Table of Contents

getAppInfo()  : array|null
Read app metadata from the info.xml file
getAppVersion()  : string
Get the last version of the app from appinfo/info.xml
isEnabled()  : bool
checks whether or not an app is enabled
registerAdmin()  : void
Register a Configuration Screen that should appear in the Admin section.
registerPersonal()  : void
Register a Configuration Screen that should appear in the personal settings section.

Methods

getAppInfo()

Read app metadata from the info.xml file

public static getAppInfo(string $app[, bool $path = false ]) : array|null
Parameters
$app : string

id of the app or the path of the info.xml file

$path : bool = false

(optional)

Tags
deprecated
14.0.0

ise \OC::$server->getAppManager()->getAppInfo($appId)

since
4.0.0
Return values
array|null

getAppVersion()

Get the last version of the app from appinfo/info.xml

public static getAppVersion(string $app) : string
Parameters
$app : string
Tags
since
4.0.0
deprecated
14.0.0

use \OC::$server->getAppManager()->getAppVersion($appId)

Return values
string

isEnabled()

checks whether or not an app is enabled

public static isEnabled(string $app) : bool
Parameters
$app : string
Tags
since
4.0.0
deprecated
13.0.0

use \OC::$server->getAppManager()->isEnabledForUser($appId)

Return values
bool

This function checks whether or not an app is enabled.

registerAdmin()

Register a Configuration Screen that should appear in the Admin section.

public static registerAdmin(string $app, string $page) : void
Parameters
$app : string

string appid

$page : string

string page to be included

Tags
since
4.0.0
deprecated
14.0.0

Use settings section in appinfo.xml to register admin sections

registerPersonal()

Register a Configuration Screen that should appear in the personal settings section.

public static registerPersonal(string $app, string $page) : void
Parameters
$app : string

appid

$page : string

page to be included

Tags
since
4.0.0
deprecated
14.0.0

Use settings section in appinfo.xml to register personal admin sections

Search results