Example #1
0
 protected function Initialise()
 {
     global $modx;
     // This is close to the maximum size allowed in the content field
     ini_set('pcre.backtrack_limit', '16000000');
     $this->itsOutputQuerySeparator = ini_get('arg_separator.output');
     if (is_null($this->itsOutputQuerySeparator)) {
         $this->itsOutputQuerySeparator = '&';
     }
     $this->itsInputQuerySeparator = ini_get('arg_separator.input');
     if (is_null($this->itsInputQuerySeparator)) {
         $this->itsInputQuerySeparator = '&';
     }
     $this->itsMODx =& $modx;
     parent::Initialise();
     //      @include( dirname( __FILE__ ) . '/../yams.config.inc.php');
     //
     //      // Check if UTF-8 is being used
     //      // (Assume the encoding of the web page output
     //      // is the same as the encoding of the manager)
     //      YamsUtils::$itsUTF8Modifier == $this->itsEncodingModifierMode;
     $this->itsUTF8Modifier = YamsUtils::UTF8Modifier();
     //      switch ( $this->itsEncodingModifierMode )
     //      {
     //      case '':
     //      case 'u':
     //        $this->itsEncodingModifier = $this->itsEncodingModiferMode;
     //        break;
     //      default:
     //        $this->itsEncodingModifier = '';
     //        if ( $this->itsMODx->config['modx_charset'] == 'UTF-8')
     //        {
     //          $this->itsEncodingModifier = 'u';
     //        }
     //      }
     $this->UpdateLanguageDependentServerNamesMode();
     $this->UpdateLanguageDependentRootNamesMode();
     $this->UpdateLanguageQueryParamMode();
     $this->UpdateUniqueMultilingualAliasMode();
     $this->UpdateMonolingualDocIds();
     $this->CacheDocumentAliasInfo();
     // Set the current language
     $this->itsCurrentLangId = $this->DetermineCurrentLangId();
     // $this->itsCurrentLangId = $this->itsDefaultLangId;
 }