Saturday, December 22, 2007

Hack Google (Maps) URLs for Quick Searching

Site Meter Site Meter
Lifehacker
« || next »
URL hacking
Hack Google (Maps) URLs for Quick Searching

URLHacking.pngFrequently using Google Maps for directions? Reader Pham writes in with a simple but interesting way to save time when looking up directions.

Basically, the multi-step process of going to Google [Maps], typing in an address, clicking submit, etc., can be avoided by just putting all your info directly into the URL. For example typing this works:
http://maps.google.com/maps?q=1683 Mass Ave, Cambridge, MA

This simple observation can be coupled with Texter to speed up your searching. This kind of URL hacking isn't specific to Google Maps. You can also roll your own AutoHotkey applications to search Google, Google Maps, or any other site that allows robust URL searching. Hit the jump for the AHK code syntax.

To search Google Maps using an AutoHotkey application (start the application with ALT + 1), use the following code:

!1::
InputBox, OutputVar , Enter your location:,
if ErrorLevel
MsgBox, CANCEL was pressed.
else
Run http://maps.google.com/maps?q=%OutputVar%


To search standard Google (start the application with ALT + 2), use the following code:

!2::
InputBox, OutputVar , Enter your search criteria:,
if ErrorLevel
MsgBox, CANCEL was pressed.
else
Run http://www.google.com/search?q=%OutputVar%

"Command-Line" Hacking Google Maps [Broken Home for Lost Passwords]

6:00 AM ON SAT DEC 22 2007
BY KYLE POTT
312 views

Read More:
Check Your Airport's Delay Record Before You Travel
Make Text Links Click-able with Linkrr
Get Directions with Two Clicks with GDirections
Generate Charts On-the-Fly with Google's API
Google Maps Mobile Adds GPS-Like "My Location"

AUTOHOTKEY, DESKTOP SHORTCUTS, GOOGLE MAPS, SCRIPTS, URL HACKING

Comments
Subscribe
No commenter image uploaded BY MRJR AT 06:32 AM

With Firefox, it's as easy as making a keymark - keyboard shortcut bookmark.
Create a bookmark with '[maps.google.com]' as the URL and a short lower case abbreviation, such as 'gm' in the keyword box.
From now on (using the example in the article) type 'gm 1683 Mass Ave, Cambridge, MA' in the URL bar.

No commenter image uploaded BY JASON AT 07:28 AM

@MrJR: Just to clarify, you'll want the link in your bookmark to be of the format:
maps dot google dot com/maps?q=%s

In the first post that URL is showing as just maps.google.com (the hyperlink is correct, but what shows is truncated).

Works great!

--Jason

Image of Mr Handsome B Wonderful BY MR HANDSOME B WONDERFUL AT 07:54 AM

I discovered the beauty of this the other day in relation to Launchy - simply save your bookmark as per Jason above, and then the wonderful new shiny Launchy 2.0 will index it, and you simply have to Alt+Space your way into Launchy, type 'gm' press tab, then enter your search term.

This works for most google products, and I find it massively useful for Google Calendar, especially as hitting return in the search box on the webpage (as is instinctive) searches public calendars rather than your calendar, which drives me nuts (hence the workaround.

A Merry Festivus to all.

No comments: