ATTENTION: You are viewing a page formatted for mobile devices; to view the full web page, click HERE.

DonationCoder.com Software > Find And Run Robot

Web search as default when no entry was found?

(1/1)

highend01:
Hi,

is there any way to use the current text as a web search phrase if no result was found?

Of course without any additional modifiers or by putting something like search in front.

I've used launchy for a long time and I'm used to this feature that you can type in anything
and as long it's not a valid search result it will open the phrase in the current web browser
by hitting enter at the end of the line ;)

mouser:
From the help file, this is a bit tricky but it can be done:

You can now create a special alias called noresults.

If user hits enter when no results are shown, this alias will be triggered.

It can be useful if you want to do something like launch what they type directly (as if it was on path), or invoke another search program, etc.  Just use $$1 in the results.

Important: you need to set the regular expression pattern to:
^noresults (.*)$

So if you wanted to do a web search your result would be just:
http://www.google.com?q=$$1 or http://www.google.com?q=$$u1

(the u1 is for better url encoding of the parameter)

or if you wanted to show the web search inside farr's window use result
igo http://www.google.com?q=$$u1

highend01:
Thanks a lot, mouser :)

Adding this alias works as expected now.

Maybe you could add a little visual tweak to farr to make this special kind of use a bit smoother?

If you type a longer searchstring (e.g.: windows 7 registry hide user) the status bar of farr flickers a lot after you've reached the "7" because no results were found and with every additional letter that you type the statusbar switches between: Found 0 results in 0 seconds. | the directory in which farr is actually searching.

Maybe a user definable delay between 2 keystrokes after farr got two "found 0 results" in a row? Basically something like the "delay search start based on inter-keypress interval and length of search string" for this special kind of purpose?

Tia,
highend

Josh:
Mouser, perhaps this should be a configurable option that enables/disables this functionality? With this, I can now totally replace the run dialog as I use it!

Navigation

[0] Message Index

Go to full version