Created
November 20, 2023 05:56
-
-
Save cocoabox/9c13f4377e8abbf1cc7f2dc958cad6f2 to your computer and use it in GitHub Desktop.
google 検索結果を duckduckgo に変換するBookmarklet
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
javascript:(function() { var currentUrl = window.location.href; var searchQueryMatch = currentUrl.match(/q=([^&]+)/); if (searchQueryMatch && searchQueryMatch[1]) { var decodedSearchQuery = decodeURIComponent(searchQueryMatch[1].replace(/\+/g, ' ')); var duckDuckGoUrl = 'https://duckduckgo.com/?t=h_&q=' + encodeURIComponent(decodedSearchQuery); window.location.href = duckDuckGoUrl; } else { window.location.href = 'https://duckduckgo.com/'; } })(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment