SilverStripe\Subsites\Model\Subsite::accessible_sites
Return the subsites that the current user can access by given permission.
Sites will only be included if they have a Title.
Signature
public function accessible_sites(array|string
$permCode,
[boolean
$includeMainSite = true,
[string
$mainSiteTitle = 'Main site',
[int|Member
$member = NULL]]] )
Parameters
$permCode
— object- Either a single permission code or an array of permission codes.
$includeMainSite
— boolean- If true, the main site will be included if appropriate.
$mainSiteTitle
— string- The label to give to the main site
$member
— object- The member attempting to access the sites
Returns
- DataList|ArrayList
- of {@link Subsite} instances