Admin Forum:Open search results in new tab. JS or CSS?

Is there a way to make search open in a new tab? I hate when it covers up my existing page, and I don't want to have to open up a throwaway page just to use search. This is such a poor design feature of the MediaWiki software.

Anyway, any ideas on how to fix this just for myself with JS or CSS? And what about for a whole wiki? For me personally, I use the Firefox browser. ---Timeshifter (talk) 02:32, March 9, 2012 (UTC)


 * You could use JS to add a target attribute:


 * See here for info about JS files.-- Pecoes 10:31, March 9, 2012 (UTC)


 * Thanks! Works great here:
 * http://community.wikia.com/wiki/User:Timeshifter/global.js


 * That JS and CSS cheat sheet is very helpful. ---Timeshifter (talk) 12:23, March 9, 2012 (UTC)


 * I noticed one problem though. When I search from Special:Search it does not open the search results in a new tab. Can this also be done? ---Timeshifter (talk) 15:20, March 9, 2012 (UTC)


 * That's a different form. This should do it:

-- Pecoes 16:54, March 9, 2012 (UTC)


 * Thanks. I put it here again:
 * http://community.wikia.com/wiki/User:Timeshifter/global.js
 * I substituted this JS code for the other code and it works on the Community Wiki, but only partially on my main wiki, the cannabis wiki. Results of Special:Search opens up in a new tab here, but not on the cannabis wiki:
 * http://cannabis.wikia.com/wiki/Special:Search ---Timeshifter (talk) 07:53, March 10, 2012 (UTC)