Elgg  Version 6.1
Static Public Member Functions | Public Attributes | List of all members
Elgg\Project\Paths Class Reference

Find Elgg and project paths. More...

Static Public Member Functions

static project ()
 Get the project root (where composer is installed) path with "/". More...
 
static elgg ()
 Get the Elgg codebase path with "/". More...
 
static projectConfig ()
 Get the project's elgg-config/ path. More...
 
static settingsFile ($file=self::SETTINGS_PHP)
 Get path of the Elgg settings file. More...
 
static sanitize ($path, $append_slash=true)
 Sanitize file paths ensuring that they begin and end with slashes etc. More...
 

Public Attributes

const SETTINGS_PHP = 'settings.php'
 Default settings filename. More...
 
const PATH_TO_CONFIG = 'elgg-config'
 Path from project root to config folder. More...
 

Detailed Description

Find Elgg and project paths.

Definition at line 8 of file Paths.php.

Member Function Documentation

static Elgg\Project\Paths::elgg ( )
static

Get the Elgg codebase path with "/".

Returns
string

Definition at line 44 of file Paths.php.

static Elgg\Project\Paths::project ( )
static

Get the project root (where composer is installed) path with "/".

Returns
string

Definition at line 25 of file Paths.php.

static Elgg\Project\Paths::projectConfig ( )
static

Get the project's elgg-config/ path.

Returns
string

Definition at line 53 of file Paths.php.

static Elgg\Project\Paths::sanitize (   $path,
  $append_slash = true 
)
static

Sanitize file paths ensuring that they begin and end with slashes etc.

Parameters
string$pathThe path
bool$append_slashAdd trailing slash
Returns
string

Definition at line 76 of file Paths.php.

static Elgg\Project\Paths::settingsFile (   $file = self::SETTINGS_PHP)
static

Get path of the Elgg settings file.

Parameters
string$fileFile basename
Returns
string

Definition at line 64 of file Paths.php.

Member Data Documentation

const Elgg\Project\Paths::PATH_TO_CONFIG = 'elgg-config'

Path from project root to config folder.

Definition at line 18 of file Paths.php.

const Elgg\Project\Paths::SETTINGS_PHP = 'settings.php'

Default settings filename.

Definition at line 13 of file Paths.php.


The documentation for this class was generated from the following file: