[ Index ]

PHP Cross Reference of YOURLS

title

Body

[close]

/includes/Config/ -> Config.php (summary)

Define the YOURLS config

File Size: 236 lines (8 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

Config:: (8 methods):
  __construct()
  fix_win32_path()
  set_config()
  set_root()
  find_config()
  check_mandatory_constants()
  check_cookie_key()
  define_core_constants()


Class: Config  - X-Ref

__construct(string $config = '')   X-Ref

param: string $config Optional user defined config path
since: 1.7.3

fix_win32_path(string $path)   X-Ref
Convert backslashes to slashes

return: string  path with \ converted to /
param: string $path
since: 1.7.3

set_config(string $config)   X-Ref

return: void
param: string $config path to config file
since: 1.7.3

set_root(string $root)   X-Ref

return: void
param: string $root path to YOURLS root directory
since: 1.7.3

find_config()   X-Ref
Find config.php, either user defined or from standard location

return: string         path to found config file
since: 1.7.3

check_mandatory_constants(array $must_haves = self::MANDATORY_CONSTANTS)   X-Ref
Check that all mandatory constants are defined

return: void
param: string[] $must_haves Constant names to check, defaults to self::MANDATORY_CONSTANTS
since: 1.10.5

check_cookie_key(mixed $key)   X-Ref
Check that the cookie key is defined and is not a publicly known value

return: void
param: mixed $key Cookie key value, or null if the constant is undefined
since: 1.10.5

define_core_constants()   X-Ref
Define core constants that have not been user defined in config.php

return: void
since: 1.7.3



Generated: Sun Aug 9 05:10:27 2026 Cross-referenced by PHPXref 0.7.1