(bug 33471) compare detectProtocol to 'https'
[lhc/web/wiklou.git] / includes / OutputPage.php
index b020a8e..b69069b 100644 (file)
@@ -851,11 +851,10 @@ class OutputPage extends ContextSource {
                $this->getContext()->setTitle( $t );
        }
 
-
        /**
         * Replace the subtile with $str
         *
-        * @param $str String|Message: new value of the subtitle
+        * @param $str String|Message: new value of the subtitle. String should be safe HTML.
         */
        public function setSubtitle( $str ) {
                $this->clearSubtitle();
@@ -875,7 +874,7 @@ class OutputPage extends ContextSource {
        /**
         * Add $str to the subtitle
         *
-        * @param $str String|Message to add to the subtitle
+        * @param $str String|Message to add to the subtitle. String should be safe HTML.
         */
        public function addSubtitle( $str ) {
                if ( $str instanceof Message ) {
@@ -1990,6 +1989,9 @@ class OutputPage extends ContextSource {
                        wfProfileOut( 'Output-skin' );
                }
 
+               // This hook allows last minute changes to final overall output by modifying output buffer
+               wfRunHooks( 'AfterFinalPageOutput', array( $this ) );
+
                $this->sendCacheControl();
                ob_end_flush();
                wfProfileOut( __METHOD__ );
@@ -3545,7 +3547,7 @@ $templates
         *
         * Is equivalent to:
         *
-        *    $wgOut->addWikiText( "<div class='error'>\n" . wfMsgNoTrans( 'some-error' ) . "\n</div>" );
+        *    $wgOut->addWikiText( "<div class='error'>\n" . wfMessage( 'some-error' )->plain() . "\n</div>" );
         *
         * The newline after opening div is needed in some wikitext. See bug 19226.
         *