Last active
February 15, 2020 19:16
-
-
Save ttonyh/ba040238da8d3d0ffe07127d03b50d48 to your computer and use it in GitHub Desktop.
Bookmarklet - Used while in Google Images, to transfer the current search to Bing Images (which currently has a better interface)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function( p, u, q ) { | |
p = document.location.search.substr( 1 ).split( '&' ); | |
u = 'https://www.bing.com/images/search?q='; | |
if ( p ) { | |
q = p.filter( a => String( a ).startsWith( 'q=' ) ); | |
if ( q && q.length ) { | |
q = q[ 0 ].replace( 'q=', '' ); | |
window.document.location = u + q; | |
} | |
} | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment