SproutCMS

This is the code documentation for the SproutCMS project

function originCleanup()

Specify what the protocol and/or hostname which should be for requests
If this doesn't match the current values, then a 301 redirect will occur

Default version of this method does nothing, but commented-out examples
for common adjustments are included

Usage

array BootstrapConfig::originCleanup ( string $proto , string $hostname );

Arguments

  1. string $proto
    Current request protocol, either 'http' or 'https'
  2. string $hostname
    Current request hostname, e.g. 'example.com'

Return value

  • array
    New values for $proto and $hostname vars.
         If these are different from the incoming values, then a redirect will occur
         First element is protocol, second element is hostname
         Example: ['https', 'www.example.com']