r100354 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r100353‎ | r100354 | r100355 >
Date:17:37, 20 October 2011
Author:preilly
Status:ok
Tags:
Comment:
Modified paths:
  • /branches/wmf/1.18wmf1/extensions/MobileFrontend/MobileFrontend.php (modified) (history)

Diff [purge]

Index: branches/wmf/1.18wmf1/extensions/MobileFrontend/MobileFrontend.php
@@ -547,6 +547,7 @@
548548 $this->getMsg();
549549 $this->disableCaching();
550550 $this->sendXDeviceVaryHeader();
 551+ $this->sendApplicationVersionVaryHeader();
551552 $this->checkUserStatus();
552553 ob_start( array( $this, 'DOMParse' ) );
553554 }
@@ -649,6 +650,16 @@
650651 }
651652 wfProfileOut( __METHOD__ );
652653 }
 654+
 655+ private function sendApplicationVersionVaryHeader() {
 656+ global $wgOut, $wgRequest;
 657+ wfProfileIn( __METHOD__ );
 658+ if ( !empty( $_SERVER['HTTP_APPLICATION_VERSION'] ) ) {
 659+ $wgRequest->response()->header( 'Application_Version: ' . $_SERVER['HTTP_APPLICATION_VERSION'] );
 660+ $wgOut->addVaryHeader( 'Application_Version' );
 661+ }
 662+ wfProfileOut( __METHOD__ );
 663+ }
653664
654665 /**
655666 * @return string

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r100353add vary support for application version of ios applicationpreilly17:36, 20 October 2011

Status & tagging log