I love WoW, too. Well, I made one that goes to dictionary.com, based directly off this widget. [although, for myself, m-w.com] With the improved code, as per these comments. So I uploaded it -- it looks the same as WoW, but for the favicon for Dictionary.com. It's my first widget... but I really didn't DO anything except change 2 urls a graphic and then test it... I guess it may take a biit for it to join the ranks of the other widgets, but watch for it...
November 01, 2005 ·
version 1.0 JFR
I love this thing, its so small, but does so much! i use it all the time.
Could you pleease make a widget just like this, that searches dictionary.com. That would complete my (useful) widget library.
September 29, 2005 ·
version 1.0 gnunes
I notice that my previous message was truncated. I'll provide just the change to the script below and hope it fits into the 1000 character limit. The change is to the onKeyDown clause. It becomes:
<onKeyPress>
if (system.event.keyString == 'Return' || system.event.keyString == 'Enter') {
SearchString.rejectKeyPress()
openURL("http://en.wikipedia.org/wiki/" + escape(SearchString.data))
}
</onKeyPress> …
and the rejectKeyPress() call removes the return/enter key from the search sting.
I notice when using this widget on my Mac that, when the search string is ended by pressing return or enter (as opposed to pressing the "W" image), the search string is passed to my browser (Safari) with the return (or enter) key appended to the end of the string. Safari doesn't like this and the search fails.
A simple change in the widget script fixes this problem. Here is the modified widget script which prevents the return/enter key from being appended to the search string and… results in successful searches: