Mobile Gateway

MobileFrontend is the mobile interface for all Wikimedia projects. It replaced the first version of WMF projects which were originally written in Ruby.

Behind the scenes
The mobile interface can be reached by visiting langcode.m.wikipedia.org – a mobile interface for every Wikipedia we have already exists, even if there is no translation. People are sent to the mobile interface by explicitly requesting it (by visiting m.wikipedia.org) or through automatic redirection based on User-Agent (see ). The mobile interface of MediaWiki is an application that reformats a Wikipedia article into something more suited for a range of mobile devices. This page gives some information about how to make sure the mobile interface works best for your project.

Translations
The mobile application requires separate translations from the MediaWiki PHP software. The translations are done through the Translatewiki community, and by the last count there are only 29 messages that you will need to translate. If you want the application to be usable in your language, please visit Translatewiki and volunteer your services.

Please note that currently only the content languages are supported by the software for interface messages, and you cannot configure your own desired language yet when using Mediwiki Mobile. (21806).

Mobile homepage
By default, no homepage is configured for the mobile interfaces and only a search interface is provided. In order to create a homepage for a language, two different techniques can be used; Selectors or a Mobile portal.

Selectors
The original method that is used on the English Wikipedia version is to make use of selectors. You add the selectors listed below to the relevant sections of the homepage of the Wikipedia. The software then extracts the sections from the homepage and constructs a mobile homepage for that language. Currently only "Today's featured article" and "In The News" are presented.

The selectors are:

Also, any selector that is prefixed with "#mf-" will be added to the mobile main page. You also need to provide the appropriate title for the section. For example: id="mf-tfa" title="Today's Featured Article".

An example of the usage of these CSS ids can be seen in the source of the main page of the English Wikipedia (Go to the page and choose "view source" in your browser. Also see the wikicode). After you have added these IDs to your Wikipedia mainpage, create a ticket in bugzilla. Add the following information:
 * Wikipedia: lang-code.m.wikipedia.org
 * Main page: The name of your local main page. For instance: Portal:Main_page

Redirecting users
All redirects are handled by out Squid proxy using an ACL list. We are in the progress of switching our Squid to Varnish which will allow us to use the WURFL db for all device detection.

More information
If you have a question, just ask Patrick Reilly or Derk-Jan Hartman.

You can also talk to the developers in the IRC channel, via [mailto:mobile@wikipedia.org e-mail], and on Twitter

Development
Just pop into the IRC room. The code is available to anyone. Just get the repos from github and start hacking!


 * Report a new bug
 * List of known bugs