SproutCMS

This is the code documentation for the SproutCMS project

function getAbsRoot()

Returns the abs root (including protocol and server name) of the specified subsite
Falls back to the current root if no abs root can be found in the database

Usage

string Subsites::getAbsRoot ( int $id [, string $protocol ] );

Arguments

  1. int $id
    The subsite ID, e.g. SubsiteSelector::$subsite_id
  2. string $protocol = NULL
    The protocol to use for the link. Specifying null (the default)
           will cause the protocol to be automatically determined based on the request.

Return value

  • string
    An absolute URL including protocol