We can now drop the GET
version of DuckDuckGo, such as
https://duckduckgo.com/?q=%s
and adopt the POST
version below.
javascript:((document) => {
var meta = document.createElement('meta')
meta.name = 'referrer'
meta.content = 'no-referrer'
var form = document.createElement('form')
form.method = 'POST'
form.action = 'https://duckduckgo.com//'
form.setAttribute('accept-charset', 'UTF-8')
var input = document.createElement('input')
input.name = 'q'
input.value = `%s` (1)
document.head.appendChild(meta)
document.body.appendChild(form).appendChild(input)
form.submit()
})(document)
-
Hence the key word can contain
"
and'
but no`
minified version
javascript:(a=>{var b=a.createElement('meta'),c=a.createElement('form'),d=a.createElement('input');b.name='referrer',b.content='no-referrer',c.method='POST',c.action='https://duckduckgo.com//',c.setAttribute('accept-charset','UTF-8'),d.name='q',d.value=`%s`,a.head.appendChild(b),a.body.appendChild(c).appendChild(d),c.submit()})(document);
Note
|
It may not work when the current tab has some special Content Security Policy directives. |