Index: trunk/extensions/MobileFrontend/MobileFrontend.php |
— | — | @@ -108,8 +108,7 @@ |
109 | 109 | global $wgRequest; |
110 | 110 | $footerlinks = $tpl->data['footerlinks']; |
111 | 111 | $mobileViewUrl = $wgRequest->getRequestURL(); |
112 | | - $delimiter = ( strpos( $mobileViewUrl, "?" ) !== false ) ? "&" : "?"; |
113 | | - $mobileViewUrl .= $delimiter . 'useFormat=mobile'; |
| 112 | + $mobileViewUrl = wfAppendQuery( $mobileViewUrl, 'useFormat=mobile' ); |
114 | 113 | $mobileViewUrl = htmlspecialchars( $mobileViewUrl ); |
115 | 114 | |
116 | 115 | $tpl->set('mobileview', "<a href='{$mobileViewUrl}'>".wfMsg( 'mobile-frontend-view')."</a>"); |