Active Topics

 



Notices


Reply
Thread Tools
evad's Avatar
Posts: 354 | Thanked: 151 times | Joined on Mar 2008 @ London (UK) / Zielona Góra (PL)
#1
I personally love to use Firefox's address bar (aka awesome bar) on my laptop to quickly launch specific search engine based on keyword I use as first query parameter. For example, when I type 'wiki maemo' it will automatically launch wikipedia search for 'maemo'. You can configure these keywords in search plugins manager in Firefox.

Anyhow, I really miss that feature on my N900, but now there is a solution which gives that exact functionality from default browser's address bar. Here's how to do it:

1) Open up MicroB and get into about:config
2) Find keyword.URL parameter, change its value to: http://mdseven.net/microbar.php?q=
3) Close all MicroB windows that are currently opened (including "starting" window with bookmarks)
4) Launch MicroB again and type 'wiki maemo' - see that wikipedia opens up, instead of regular Google search

Other keywords apart from 'wiki' that are currently recognized are:
go - regular Google search (not mobile!)
map - Google Maps UK
ebay - eBay UK
php - PHP manual
mysql - MySQL manual
acronym - acronymfinder.com
urban - urbandictionary.com

Please note, that not typing any matching keyword will launch default Google Mobile search, exactly the same as the one that was in MicroB by default.

That's it, really. It's pretty basic php script which I wrote in about 15 minutes as a proof of concept - and it works. :) I admit that I did it initially for my sole purpose, however I'd like to know whether you guys find it useful at all, so perhaps I could extend this further, accordingly to your feedback. What do you guys think?

UPDATE: OK, looks like I'm reinventing the wheel here. Still, if anyone find this interesting, please give me a shout.
__________________
Dawid 'evad' Lorenz * http://dawid.lorenz.co
_______________________________________________
 

The Following 6 Users Say Thank You to evad For This Useful Post:
Posts: 344 | Thanked: 73 times | Joined on Oct 2009 @ Los Angeles
#2
Very interesting. Maybe a touch UK-centric... anyway to get maps keyword to default to US or Italy, for example?

Also, lots of prefs in about:config. Think there's anyway to make word reflow (CNTRL+SHFT i) be on by default? There is only one entry with the word "flow": "overflow." Sorry, a little OT, I know...
 

The Following User Says Thank You to sorodoros For This Useful Post:
Posts: 287 | Thanked: 165 times | Joined on Oct 2009 @ The Netherlands
#3
Care to share the php file for the paranoid people ? Just create a symlink (ln -s microbar.php microbar.phps).
 

The Following User Says Thank You to robbie For This Useful Post:
evad's Avatar
Posts: 354 | Thanked: 151 times | Joined on Mar 2008 @ London (UK) / Zielona Góra (PL)
#4
Originally Posted by sorodoros View Post
Very interesting. Maybe a touch UK-centric... anyway to get maps keyword to default to US or Italy, for example?
Yes, it is UK-centric and currently all keywords are hard-coded in the file, as I created it for my personal purpose for now. If more people will find it useful, I'll consider adding a feature which would let people register/login and create their own, custom keywords for specific search engines and/or websites, so then you could create a keyword that would launch Italian Google Maps edition - for example.

How does that sound?
__________________
Dawid 'evad' Lorenz * http://dawid.lorenz.co
_______________________________________________
 

The Following User Says Thank You to evad For This Useful Post:
evad's Avatar
Posts: 354 | Thanked: 151 times | Joined on Mar 2008 @ London (UK) / Zielona Góra (PL)
#5
Originally Posted by robbie View Post
Care to share the php file for the paranoid people :) ? Just create a symlink (ln -s microbar.php microbar.phps).
If you're paranoid if I log queries people launch, then yes - I do that. Not to spy on people (I couldn't tell who's who anyway), tough, but to see whether anyone apart from me is actually using it.

Is that what you're asking, really? :)
__________________
Dawid 'evad' Lorenz * http://dawid.lorenz.co
_______________________________________________
 
Posts: 287 | Thanked: 165 times | Joined on Oct 2009 @ The Netherlands
#6
Originally Posted by evad View Post
If you're paranoid if I log queries people launch, then yes - I do that. Not to spy on people (I couldn't tell who's who anyway), tough, but to see whether anyone apart from me is actually using it.

Is that what you're asking, really?
No thats not what i'm asking

I like to have all my web things in my own hand. You never know what people will use your data for. For example: i don't sync my bookmarks with a public server but use my own. That way i know for sure that my data is in good hands.

And having the code, assures that it keeps working even if you don't support it anymore.

Your php file is probably pretty simple. A case statement for the keywords and a header redirect is all that is needed. I thought it would be easier to start with your code than start my own from scratch.
 

The Following 2 Users Say Thank You to robbie For This Useful Post:
evad's Avatar
Posts: 354 | Thanked: 151 times | Joined on Mar 2008 @ London (UK) / Zielona Góra (PL)
#7
Originally Posted by robbie View Post
Your php file is probably pretty simple. A case statement for the keywords and a header redirect is all that is needed. I thought it would be easier to start with your code than start my own from scratch. :)
It's probably simpler than that. :) See your PM.
__________________
Dawid 'evad' Lorenz * http://dawid.lorenz.co
_______________________________________________
 

The Following User Says Thank You to evad For This Useful Post:
Viqsi's Avatar
Posts: 115 | Thanked: 136 times | Joined on Mar 2008 @ Central Ohio
#8
Personally, I'd like to have a copy of the code too, if only because I have my own similar prefixes that I've set up myself (I'd be shocked if any of these services include, say, a one-letter prefix for the Internet Hockey Database ) and so would love to be able to do customization.

Please? Pretty please with sugar on top?
 
evad's Avatar
Posts: 354 | Thanked: 151 times | Joined on Mar 2008 @ London (UK) / Zielona Góra (PL)
#9
Originally Posted by Viqsi View Post
Please? Pretty please with sugar on top? ;)
And God said: let's make it open-source! ;)
Attached Files
File Type: zip microbar.php.zip (817 Bytes, 142 views)
__________________
Dawid 'evad' Lorenz * http://dawid.lorenz.co
_______________________________________________
 

The Following 2 Users Say Thank You to evad For This Useful Post:
Viqsi's Avatar
Posts: 115 | Thanked: 136 times | Joined on Mar 2008 @ Central Ohio
#10
Well, my webserver's upstream is being a PITA, and I was feeling especially perverse earlier today, so I ended up making a Javascript version of this concept. The advantage is that this is local to the n900, so you can still search Google even if these other services are down.

Nongeek HowTo:
1) Download the attached file to the Documents folder. (I believe this is the browser default)
2) Launch X-Terminal, and run the following (really basic) command:
Code:
mv MyDocs/.documents/search.txt search.htm
3 Follow steps in post #1 by evad in this thread, except that in step 2 change the configuration value to:
Code:
file:///home/user/search.htm?
The same keywords from evad's search setup are in that file. Advanced users can add more keywords pretty easily - just open search.htm in any text editor and add more search URLs to the array. Getting the necessary URLs for said keywords is left as an exercise for the reader... unless you ask really really nicely.

Hope this helps!
Attached Files
File Type: txt search.txt (1.5 KB, 1167 views)
 

The Following 4 Users Say Thank You to Viqsi For This Useful Post:
Reply


 
Forum Jump


All times are GMT. The time now is 08:25.