Elgg
Version master
|
Go to the source code of this file.
Functions | |
elgg_group_tool_gatekeeper (string $tool_name, int $group_guid=null) | |
Checks if a group has a specific tool enabled. More... | |
elgg_signed_request_gatekeeper () | |
Validates if the HMAC signature of the current request is valid Issues 403 response if signature is invalid. More... | |
elgg_gatekeeper () | |
Used at the top of a page to mark it as logged in users only. More... | |
elgg_admin_gatekeeper () | |
Used at the top of a page to mark it as admin only. More... | |
elgg_entity_gatekeeper (int $guid, string $type=null, string $subtype=null, bool $validate_can_edit=false) | |
Can the viewer see this entity? More... | |
elgg_ajax_gatekeeper () | |
Require that the current request be an XHR. More... | |
elgg_admin_gatekeeper | ( | ) |
Used at the top of a page to mark it as admin only.
Definition at line 75 of file gatekeepers.php.
elgg_ajax_gatekeeper | ( | ) |
Require that the current request be an XHR.
If not, execution of the current function will end and a 400 response page will be sent.
Definition at line 112 of file gatekeepers.php.
elgg_entity_gatekeeper | ( | int | $guid, |
string | $type = null , |
||
string | $subtype = null , |
||
bool | $validate_can_edit = false |
||
) |
Can the viewer see this entity?
Tests if the entity exists and whether the viewer has access to the entity if it does. If the viewer cannot view this entity, it forwards to an appropriate page.
int | $guid | Entity GUID |
string | $type | Optional required entity type |
string | $subtype | Optional required entity subtype |
bool | $validate_can_edit | flag to check canEdit access |
Exception | |
Definition at line 99 of file gatekeepers.php.
elgg_gatekeeper | ( | ) |
Used at the top of a page to mark it as logged in users only.
Definition at line 64 of file gatekeepers.php.
elgg_group_tool_gatekeeper | ( | string | $tool_name, |
int | $group_guid = null |
||
) |
Checks if a group has a specific tool enabled.
Forward to the group if the tool is disabled.
string | $tool_name | The name of the group tool to check |
int | $group_guid | The group that owns the page. If not set, this will be pulled from elgg_get_page_owner_guid(). |
GroupToolGatekeeperException |
Definition at line 20 of file gatekeepers.php.
elgg_signed_request_gatekeeper | ( | ) |
Validates if the HMAC signature of the current request is valid Issues 403 response if signature is invalid.
Definition at line 49 of file gatekeepers.php.