On Fri, Sep 6, 2013 at 8:51 PM, roger@rogerchrisman.com wrote:
On Fri, Sep 6, 2013 at 2:33 PM, Nikolas Everett neverett@wikimedia.org wrote:
I'm sure there is a better way but I have a hack that'll do it. Drop this in LocalSettings.php:
$wgHooks['SpecialSearchGo'][] = function($p) { $p[0] = null; return true; };
Tested against master branch so your results may vary.
Hm, in MW1.20.2, for me that causes this error:
Fatal error: Cannot use object of type Title as array in /home/bilbo/public_html/teflpedia.com/LocalSettings.php on line 162
(line 162 being $p[0] = null;)
Any suggestions on a better way to stop the 'Go [direct to article]' behavior of the Search box?
Roger
Blindly I'd guess you could do this:
$wgHooks['SpecialSearchGo'][] = function($t) { $t = null; return true; };
If that doesn't work I'm out of hacks :)
Nik