Hi,
I did find this old post over on the wiki, but....
-----
Friday, July 20, 2007
YubNub "default" parameter for overriding default command (Google)
If you don't want Google as the default YubNub command, here's how you
can override it:
http://yubnub.org/parser/parse?default=y&command=abcde
In this example, we set the default to the "y" command (Yahoo).
posted by Jonathan at 7/20/2007 08:38:00 PM 0 comments
----
it doesn't solve my problem. :(
I made a search page to my liking, loads in new tabs, with an embedded
yubnub search form.
I'd love to swap the default search to duckduckgo (ddg), but I can't
even get his example to make it default to yahoo, as he describes...
Any help would be greatly appreciated.
Here's the script from the head (irrelevant?), and then the form from
the body:
----
<script type="text/javascript">
function focus(){document.input_box.command.focus();}
function prepend(arg){
oldVal = document.input_box.command.value;
document.input_box.command.value = arg + oldVal;
focus();
}
</script>
---
<form action="
http://yubnub.org/parser/parse?default=y&command=abcde"
method="get" name="input_box">
<input type="text" name="command" size="45" value=""
class="searchbox" />
<div class="divbox">
<input type="reset" class="button1a" value="clear">
<input type="submit" class="button1b" value="send">
</div>
<div class="divbox">
<input type="button" class="button2" onclick="prepend('ddg ')"
value="ddg">
<input type="button" class="button2" onclick="prepend('!gi ')"
value="ddg img">
<input type="button" class="button2" onclick="prepend('wp ')"
value="wp">
<br />
<input type="button" class="button2" onclick="prepend('g ')"
value="g">
<input type="button" class="button2" onclick="prepend('gmaps ')"
value="maps">
<input type="button" class="button2" onclick="prepend('imdb ')"
value="imdb">
</div>
</form>
----
Shouldn't the form action default line drive the destination even with
this whole thing external to yubnub? It doesn't - it returns google no
matter what....
Thanks in advance,
Eric