Page MenuHomePhabricator

Interwiki search results should come after local ones in HTML
Closed, ResolvedPublic

Description

A mobile user reports that interwiki search results come before normal results for them.

There is no interwiki search on m.wikipedia.org (nor full text search at all), so the user must be talking of the desktop site; indeed, if you take a busy result page and shrink the browser window, you can see that in the end the right div comes before the left div.

Should be trivial to switch the two HTML blocks.


See also: T18886: Sister projects search results box placement on IE7

Event Timeline

Nemo_bis raised the priority of this task from to Medium.
Nemo_bis updated the task description. (Show Details)
Nemo_bis added a project: MediaWiki-Search.
Nemo_bis subscribed.
gerritbot subscribed.

Change 186915 had a related patch set uploaded (by Nemo bis):
Output local search results before interwiki results

https://gerrit.wikimedia.org/r/186915

Patch-For-Review

Wouldn't this result in the interwiki search results being displayed below instead of to the side in the typical window-size case?

Change 186915 abandoned by Nemo bis:
Output local search results before interwiki results

Reason:
Per Brion

https://gerrit.wikimedia.org/r/186915

Stas and Erik, how hard is this to fix in your opinion?

Deskana lowered the priority of this task from Medium to Low.Sep 16 2015, 2:53 PM
Deskana subscribed.

It's not Discovery's priority at present to support the current version of interwiki search on the Italian Wikipedia. You can look at our goals to see what we are working on.

Nemo_bis raised the priority of this task from Low to Medium.Sep 16 2015, 5:05 PM
Nemo_bis removed a project: Discovery-ARCHIVED.
Nemo_bis raised the priority of this task from Medium to High.
Nemo_bis updated the task description. (Show Details)
Nemo_bis added a project: good first task.

Change 238808 had a related patch set uploaded (by Nemo bis):
Explicitly float local search results left so they come first

https://gerrit.wikimedia.org/r/238808

Change 238808 merged by jenkins-bot:
Explicitly float local search results left so they come first

https://gerrit.wikimedia.org/r/238808

@Nemo_bis: this patch has introduced a stray newline character below the results list (pl.wikisource).

The solution works but has a poor interaction with CirrusSearch adding section links, which can be very long. Here is how much I have to zoom out (50 %) in order to see the interwiki box for one specific search:

search-section-interwiki.png (693×928 px, 61 KB)

The section link should probably be pushed to the next line. Classes are available: searchalttitle for the span and mw-search-result-heading for the whole line.

The float-left, leads to a rather unpleasant side-effect, where the second <h2> moves to the right and the content below it (not seen in the screenshot) doesn't.

sc104.png (421×783 px, 30 KB)

Thanks for the report. We didn't notice because that only happens with the vanilla MediaWiki MySQL search, which adds the headers without any separation:

$out->wrapWikiMsg( "==$1==\n", 'titlematches' );
[...]
$out->wrapWikiMsg( "==$1==\n", 'textmatches' );

@NikiWiki: Yes please (and refer to this one that it's a followup)!

I have opened the new report, just referencing it for those who will still land here: https://phabricator.wikimedia.org/T122499