Moodle APIs 3.9
Moodle 3.9.13+ (Build: 20220325)
|
These functions are required very early in the Moodle setup process, before any of the main libraries are loaded. More...
Classes | |
class | bootstrap_renderer |
This class solves the problem of how to initialise $OUTPUT. More... | |
class | coding_exception |
Exception indicating programming error, must be fixed by a programer. More... | |
class | file_serving_exception |
An exception that indicates that file can not be served. More... | |
class | invalid_dataroot_permissions |
An exception that indicates incorrect permissions in $CFG->dataroot. More... | |
class | invalid_parameter_exception |
Exception indicating malformed parameter problem. More... | |
class | invalid_response_exception |
Exception indicating malformed response problem. More... | |
class | invalid_state_exception |
An exception that indicates something really weird happened. More... | |
class | moodle_exception |
Base Moodle Exception class. More... | |
class | require_login_exception |
Course/activity access exception. More... | |
class | require_login_session_timeout_exception |
Session timeout exception. More... | |
class | required_capability_exception |
Exceptions indicating user does not have permissions to do something and the execution can not continue. More... | |
class | webservice_parameter_exception |
Web service parameter exception class. More... | |
Functions | |
abort_all_db_transactions () | |
Unconditionally abort all database transactions, this function should be called from exception handlers only. More... | |
check_dir_exists ($dir, $create=true, $recursive=true) | |
Function to check if a directory exists and by default create it if not exists. More... | |
default_error_handler ($errno, $errstr, $errfile, $errline, $errcontext) | |
Default error handler, prevents some white screens. More... | |
default_exception_handler ($ex) | |
Default exception handler. More... | |
during_initial_install () | |
Indicates whether we are in the middle of the initial Moodle install. More... | |
format_backtrace ($callers, $plaintext=false) | |
Formats a backtrace ready for output. More... | |
generate_uuid () | |
Generate a V4 UUID. More... | |
get_backup_temp_directory ($directory) | |
Get the full path of a directory under $CFG->backuptempdir. More... | |
get_docs_url ($path=null) | |
Returns the Moodle Docs URL in the users language for a given 'More help' link. More... | |
get_exception_info ($ex) | |
Returns detailed information about specified exception. More... | |
get_real_size ($size=0) | |
Converts numbers like 10M into bytes. More... | |
get_request_storage_directory ($exceptiononerror=true, bool $forcecreate=false) | |
Get a per-request storage directory in the tempdir. More... | |
ini_get_bool ($ini_get_arg) | |
This function makes the return value of ini_get consistent if you are setting server directives through the .htaccess file in apache. More... | |
init_performance_info () | |
Initializes our performance info early. More... | |
initialise_fullme () | |
Initialises $FULLME and friends. More... | |
initialise_fullme_cli () | |
Initialises $FULLME and friends for command line scripts. More... | |
is_early_init ($backtrace) | |
This function encapsulates the tests for whether an exception was thrown in early init – either during setup.php or during init of $OUTPUT. More... | |
is_major_upgrade_required () | |
Check whether a major upgrade is needed. More... | |
make_backup_temp_directory ($directory, $exceptiononerror=true) | |
Create a directory under $CFG->backuptempdir and make sure it is writable. More... | |
make_cache_directory ($directory, $exceptiononerror=true) | |
Create a directory under cachedir and make sure it is writable. More... | |
make_localcache_directory ($directory, $exceptiononerror=true) | |
Create a directory under localcachedir and make sure it is writable. More... | |
make_request_directory ($exceptiononerror=true, bool $forcecreate=false) | |
Create a per-request directory and make sure it is writable. More... | |
make_temp_directory ($directory, $exceptiononerror=true) | |
Create a directory under tempdir and make sure it is writable. More... | |
make_unique_writable_directory ($basedir, $exceptiononerror=true) | |
Create a new unique directory within the specified directory. More... | |
make_upload_directory ($directory, $exceptiononerror=true) | |
Create a directory under dataroot and make sure it is writable. More... | |
merge_query_params (array &$target, array $values) | |
Merge parsed POST chunks. More... | |
print_error ($errorcode, $module='error', $link='', $a=null, $debuginfo=null) | |
Abort execution by throwing of a general exception, default exception handler displays the error message in most cases. More... | |
raise_memory_limit ($newlimit) | |
Function to raise the memory limit to a new value. More... | |
redirect_if_major_upgrade_required () | |
Redirect to the Notifications page if a major upgrade is required, and terminate the current user session. | |
reduce_memory_limit ($newlimit) | |
Function to reduce the memory limit to a new value. More... | |
set_access_log_user () | |
Webserver access user logging. | |
setup_get_remote_url () | |
Get the URL that PHP/the web server thinks it is serving. More... | |
setup_validate_php_configuration () | |
This function verifies the sanity of PHP configuration and stops execution if anything critical found. | |
upgrade_ensure_not_running ($warningonly=false) | |
Makes sure that upgrade process is not running. More... | |
workaround_max_input_vars () | |
Try to work around the 'max_input_vars' restriction if necessary. | |
Variables | |
const | DEBUG_ALL E_ALL & ~E_STRICT |
All problems except strict PHP warnings. | |
const | DEBUG_DEVELOPER E_ALL | E_STRICT |
DEBUG_ALL with all debug messages and strict warnings. | |
const | DEBUG_MINIMAL E_ERROR | E_PARSE |
Fatal errors only. | |
const | DEBUG_NONE 0 |
No warnings and errors at all. | |
const | DEBUG_NORMAL E_ERROR | E_PARSE | E_WARNING | E_NOTICE |
Errors, warnings and notices. | |
const | MEMORY_EXTRA -3 |
Large memory limit for given platform - used in cron, upgrade, and other places that need a lot of memory. More... | |
const | MEMORY_HUGE -4 |
Extremely large memory limit - not recommended for standard scripts. | |
const | MEMORY_STANDARD -2 |
Standard memory limit for given platform. | |
const | MEMORY_UNLIMITED -1 |
Remove any memory limits. | |
These functions are required very early in the Moodle setup process, before any of the main libraries are loaded.
@subpackage lib