Last active
November 27, 2017 04:55
-
-
Save dosentmatter/64ef87f29752eb0526c3acf7aa2dfee5 to your computer and use it in GitHub Desktop.
CantoDict Chrome Search Engine 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(){(function(){(function(e,n,t){t=t||"post";var o=document.createElement("form");o.style.display="none",o.method=t,o.action=e;for(var a in n){var c=document.createElement("input");c.name=a,c.value=n[a],o.appendChild(c)}document.body.appendChild(o),o.submit()})("http://www.cantonese.sheik.co.uk/scripts/wordsearch.php%3Flevel=0",{TEXT:"%s",SEARCHTYPE:4,radicaldropdown:0,searchsubmit:"search"})})()}(); |
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 post_to_url = function(path, params, method) { | |
method = method || "post"; | |
var form = document.createElement("form"); | |
form.style.display = 'none'; | |
form.method = method; | |
form.action = path; | |
for (var key in params) { | |
var input = document.createElement("input"); | |
input.name = key; | |
input.value = params[key]; | |
form.appendChild(input); | |
} | |
document.body.appendChild(form); | |
form.submit(); | |
}; | |
post_to_url( | |
'http://www.cantonese.sheik.co.uk/scripts/wordsearch.php?level=0', { | |
TEXT: '%s', | |
SEARCHTYPE: 4, | |
radicaldropdown: 0, | |
searchsubmit: 'search' | |
}); | |
})() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment