Function __global->get_page_permission_where_clause
Definitions
sources/permissions.php
- Get an SQL WHERE clause for checking member access to a page.
- Visibility: public
- Is abstract?: No
- Is static?: No
- Is final?: No
- Returns: string
Parameters
| Name | Type | Passed by reference? | Variadic? | Default | Set | Range | Description |
|---|---|---|---|---|---|---|---|
| $zone_field | ID_TEXT | No | No | required parameter | N/A | N/A | The field in the main query row that holds the zone |
| $page_field | ID_TEXT | No | No | required parameter | N/A | N/A | The field in the main query row that holds the page |
| $member_id | ?MEMBER | No | No | required parameter | N/A | N/A | The member to check individual access for (null: none) |
| $groups | string | No | No | required parameter | N/A | N/A | SQL from get_permission_where_clause_groups |
| $row_alias | ID_TEXT | No | No | r | N/A | N/A | The alias for the main query row |
Returns
- SQL
- Type: string
- Set: N/A
- Range: N/A
Preview
Code (PHP)
/**
* Get an SQL WHERE clause for checking member access to a page.
*
* @param ID_TEXT $zone_field The field in the main query row that holds the zone
* @param ID_TEXT $page_field The field in the main query row that holds the page
* @param ?MEMBER $member_id The member to check individual access for (null: none)
* @param string $groups SQL from get_permission_where_clause_groups
* @param ID_TEXT $row_alias The alias for the main query row
* @return string SQL
*/
function get_page_permission_where_clause(string $zone_field, string $page_field, ?int $member_id, string $groups, string $row_alias = 'r') : string
* Get an SQL WHERE clause for checking member access to a page.
*
* @param ID_TEXT $zone_field The field in the main query row that holds the zone
* @param ID_TEXT $page_field The field in the main query row that holds the page
* @param ?MEMBER $member_id The member to check individual access for (null: none)
* @param string $groups SQL from get_permission_where_clause_groups
* @param ID_TEXT $row_alias The alias for the main query row
* @return string SQL
*/
function get_page_permission_where_clause(string $zone_field, string $page_field, ?int $member_id, string $groups, string $row_alias = 'r') : string
