Topic on Project:Support desk

Bad formatting of search result with MediaWiki 1.26.3

7
Summary by FriedhelmW

CSS fixed

Stefanomenci (talkcontribs)

I just upgraded my company's internal wiki and now the search results appear badly formatted.

The image below shows the H2 containing the text Page text matches on the right of the page, below the Page title matches. When the page shrinks or expands the search results move to the left below the title matches (as in the image) or to the right below the Page text matches text. The Page text matches text is always up there and becomes invisible if the page shrinks too much.

Is it a problem with MediaWiki 1.26.3?

Did I mess something up during the upgrade?

How do I fix it?

   MediaWiki  1.26.3
   PHP        5.5.35
   MySQL      5.5.48-37.8
   ICU        4.2.1

87.123.19.225 (talkcontribs)

I know that there are problems with the styling of the search result page in MediaWiki 1.26: The second part, which should be below the first one, does not appear below it, but it appears next to it. I think this is close to your problem or it is exactly your problem. So: Most likely it is not you, who has messed things up, but that is how it is in MW 1.26.

This somehow is a missing clear for floated content. There surely is an issue in phabricator about that, but I do not find it currently...

Ciencia Al Poder (talkcontribs)

This is task T122499 and it looks like it won't be fixed on 1.27 (which is a LTS) neither :(

Stefanomenci (talkcontribs)

The next LTS will be released with a regression? And there is an easy fix? That's weird!

Stefanomenci (talkcontribs)

Here is the workaround:

  1. Go to http://your.wiki.url/index.php?title=MediaWiki:Common.css
  2. Add the following code:
   .mw-search-results {
       float:
   }
Ciencia Al Poder (talkcontribs)

Your CSS is missing the "none":

    .mw-search-results {
        float: none;
    }
Stefanomenci (talkcontribs)

Thanks, I was victim of copy and paste with editors that (try to) preserve the formatting.