https://www.mediawiki.org/wiki/Special:Code/MediaWiki/113146

Revision: 113146
Author:   jdlrobson
Date:     2012-03-06 16:06:38 +0000 (Tue, 06 Mar 2012)
Log Message:
-----------
fix for bug 34829

this removes the mobileaction parameter from the link
to view this on the mobile site to avoid the conflict of
mobileaction and useformat querystring parameters

Modified Paths:
--------------
    trunk/extensions/MobileFrontend/MobileFrontend.body.php

Modified: trunk/extensions/MobileFrontend/MobileFrontend.body.php
===================================================================
--- trunk/extensions/MobileFrontend/MobileFrontend.body.php     2012-03-06 
16:04:35 UTC (rev 113145)
+++ trunk/extensions/MobileFrontend/MobileFrontend.body.php     2012-03-06 
16:06:38 UTC (rev 113146)
@@ -198,7 +198,9 @@
 
                if ( ! $isSpecial ) {
                        $footerlinks = $tpl->data['footerlinks'];
-                       $mobileViewUrl = $wgRequest->escapeAppendQuery( 
'useformat=mobile' );
+                       $mobileViewUrl = htmlspecialchars(
+                                       $this->removeQueryStringParameter( 
$wgRequest->appendQuery( 'useformat=mobile' ), 'mobileaction' )
+                                       );
 
                        $tpl->set( 'mobileview', "<a href='{$mobileViewUrl}' 
class='noprint'>" . wfMsg( 'mobile-frontend-view' ) . "</a>" );
                        $footerlinks['places'][] = 'mobileview';


_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to