Symbiote\Multisites\Extension\MultisitesSiteTreeExtension
Modifies SiteTree behaviour when in a multisite
Synopsis
class MultisitesSiteTreeExtension
extends SiteTreeExtension
{
- // members
- private static array $has_one = ;
- // methods
- public Site CurrentSite()
- public Site DefaultSite()
- public void updateCMSFields()
- public void contentcontrollerInit()
- public void onBeforeWrite()
- public void updateSiteID()
- public void alternateAbsoluteLink()
- public Site getSite()
Hierarchy
Extends
- SilverStripe\CMS\Model\SiteTreeExtension
Tasks
Line | Task |
---|---|
131+ | This will mark all child pages as modified. Should it write directly to the database to avoid the publishing workflow? |
Members
private
- $has_one
Methods
public
- CurrentSite()
- DefaultSite()
- alternateAbsoluteLink()
- contentcontrollerInit() — Make sure site home pages are loaded at the root of the site.
- getSite() — Returns the current site object in case this is a fake page (like in the case of pages served by the {@link Security} controller)
- onBeforeWrite() — Keep the SiteID field consistent.
- updateCMSFields()
- updateSiteID() — Recursively update the site ID for this page and all child pages. This writes decendents to the database, but does not write the current page as it is called from {@link onBeforeWrite}