Page MenuHomePhabricator

Remove Google search form
Closed, ResolvedPublic

Description

With $wgDisableTextSearch = true and $wgSearchForwardUrl = false MediaWiki search falls back to Google for site searches:

image.png (621×274 px, 26 KB)

The search engine used (and the entire HTML of the form) can be customized with the searchdisabled and googlesearch messages, but it seems unusual that MediaWiki would include a proprietary service like this as default (albeit as a fallback).

We could use DuckDuckGo instead, or any other privacy-preserving search engine, but removing the feature may be more sensible.

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

I will suggest remove the search form completely for following reasons:

Yep removing it completely does sound like probably a simpler way to go. If anyone wants to use an external search engine, they can use $wgSearchForwardUrl.

Change #1114710 had a related patch set uploaded (by Samwilson; author: Samwilson):

[mediawiki/core@master] Remove Google search fallback for external search

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

Does this message sound okay? "Dev wiki1 search is disabled, and no external search URL has been configured."

image.png (732×171 px, 15 KB)

Samwilson renamed this task from Use DuckDuckGo instead of Google search to Remove Google search form .Jan 28 2025, 2:25 PM
Samwilson updated the task description. (Show Details)

Does this message sound okay? "Dev wiki1 search is disabled, and no external search URL has been configured."

I would try to avoid the sitename if possible. Maybe something like: Search is disabled on this wiki, and no external search URL has been configured.

Perhaps the message should link to https://www.mediawiki.org/wiki/Manual:$wgSearchForwardUrl too?

That's a good idea. How about this:

Search is disabled on this wiki, and no external search URL has been [[mw:Manual:$wgSearchForwardUrl|configured]].

(The mw prefix is permitted in core messages.)

Change #1114710 merged by jenkins-bot:

[mediawiki/core@master] Remove Google search fallback for external search

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

Samwilson claimed this task.

Change #1115027 had a related patch set uploaded (by Samwilson; author: Samwilson):

[mediawiki/core@master] Update searchdisabled message with docs and better link target

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

Change #1115027 merged by jenkins-bot:

[mediawiki/core@master] Update searchdisabled message with docs and better link target

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

Okay I think this time it's all done! :)

Change #1119824 had a related patch set uploaded (by Krinkle; author: Krinkle):

[mediawiki/core@master] i18n: Fix qqq.json for searchdisabled to be an actual link

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

Change #1119824 merged by jenkins-bot:

[mediawiki/core@master] i18n: Fix qqq.json for searchdisabled to be an actual link

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