Topic on Project:Support desk

No links in the mobile view

13
Uri Even-Chen (talkcontribs)

I recently created Speedypedia [www.speedypedia.info], which is based on MediaWiki. I noticed that in the mobile view, links to articles which don't exist yet are removed, probably with JavaScript (for example, in the article about Haggai Matar there is no link to Anat Matar, and I think it changes after the page loads). Is it possible to remove this feature and display the links in the mobile view, like in the desktop view?

Thanks, Uri.

FriedhelmW (talkcontribs)

I see the red links.

Florianschmidtwelzow (talkcontribs)

Add the following to your LocalSettings.php after the require_once line of MobileFrontend:

$wgMFShowRedLinks = true;
$wgMFShowRedLinksAnon = true;

That's it.

Uri Even-Chen (talkcontribs)

Thank you, it worked! what are these options? @Fried, the red link only didn't appear in the mobile view, not in the desktop view.

Florianschmidtwelzow (talkcontribs)

Redlinks are deactivated in mobile for performance reason and because the mobile editor wasn't a really good function to welcome users (especially newcomers). So we deactivated them and added these two options to activate them, e.g. if third party wikis want to use them. The first one is for logged in users (if set to true, logged in users always see redlinks, but logged out users doesn't) and the second one is for logged out users.

Btw.: In the next release (1.26), redlinks will be enabled by default with a Click-to-action banner, if the user really wants to create a new page or not (redlinks are well known in the editing community, but a new user maybe doesn't know what it is, and the mobile editor doesn't have the nce warnings, like on desktop).

Uri Even-Chen (talkcontribs)

I have another problem - in the mobile view, if I search for an article which doesn't exist yet, I don't have a link to create this article (I only get this link in the desktop view). Is it also a feature we have to enable?

Florianschmidtwelzow (talkcontribs)

No, that is disabled by design. The mobile editor is a plain wikitext editor, which is a worse experience for newcomers. So, the eitor isn't really suitable for creating pages, too and we've disabled the create link for search. If you really want to enable it, you could do the following:

.mw-search-createlink {
    display: inherit !important;
}
  • Save and reload the search page (maybe you have to clear your browser cache and maybe any other existing cache layers, depends on your setup)
Uri Even-Chen (talkcontribs)

I have another question about Speedypedia. In Speedypedia one has to login or register to edit or create articles. When a user is not logged in in the mobile view, if he clicks on the "Edit" of any page he receives the message: "This page is protected to prevent vandalism." But the page is not protected, logged in users can edit it. I want the user to see the message "Would you like to edit this page? Login or register to edit articles.", unless the page is really protected (which is not the case in the page I tested). In the desktop view it's fine, if I'm not logged in I can view source, or create account or log in. But in the mobile view I receive this message if I try to edit the page.

Florianschmidtwelzow (talkcontribs)

Yeah, the problem is, that we never tested MobileFrontend with wikis, where you have to register to edit :) MF (=MobileFrontend) show this error message, whenever the page can not be edited by the current user, there is no configuration to handle this. Would you like to file a task in Phabricator for it? (Please note, that you're using REL1_25, so the WMF team(s) can decide what to do, normally we don't support other branches as master :)).

Uri Even-Chen (talkcontribs)
Florianschmidtwelzow (talkcontribs)

REL1_25 is the 1.25.X release branch in our git repository, it reflects the latest release of MediaWiki 1.25 :)

Reply to "No links in the mobile view"