Index: branches/wmf/1.17wmf1/extensions/MobileFrontend/MobileFrontend.php |
— | — | @@ -65,7 +65,7 @@ |
66 | 66 | ); |
67 | 67 | |
68 | 68 | class ExtMobileFrontend { |
69 | | - const VERSION = '0.5.38'; |
| 69 | + const VERSION = '0.5.39'; |
70 | 70 | |
71 | 71 | /** |
72 | 72 | * @var DOMDocument |
— | — | @@ -242,6 +242,8 @@ |
243 | 243 | |
244 | 244 | if ( self::$disableImages == 1 ) { |
245 | 245 | $wgRequest->response()->setcookie( 'disableImages', 1 ); |
| 246 | + $location = str_replace( '?disableImages=1', '', $wgRequest->getRequestURL() ); |
| 247 | + header( 'Location: ' . $location ); |
246 | 248 | } |
247 | 249 | |
248 | 250 | if ( self::$disableImages == 0 ) { |
— | — | @@ -255,6 +257,8 @@ |
256 | 258 | $disableImages = $wgRequest->getCookie( 'disableImages' ); |
257 | 259 | if ( $disableImages ) { |
258 | 260 | $wgRequest->response()->setcookie( 'disableImages', '' ); |
| 261 | + $location = str_replace( '?enableImages=1', '', $wgRequest->getRequestURL() ); |
| 262 | + header( 'Location: ' . $location ); |
259 | 263 | } |
260 | 264 | } |
261 | 265 | |