GoogleScript

Here’s an AppleScript to look up phone numbers using Google.

OS version: OS X

tell application "Finder"
  try
    display dialog "enter full first name lowercase" default answer ¬
      "joe" buttons {"OK"} default button 1
    set first_name to text returned of the result
    display dialog "enter last name lower case" default answer ¬
      "blow" buttons {"OK"} default button 1
    set last_name to text returned of the result
    set full_name to first_name & " " & last_name
    -- The next three lines should be entereed as ONE LINE:
    display dialog ¬
      "Enter city in lower case, leave blank if you don't know it."
      default answer "my city" buttons {"OK"} default button 1
    set my_city to text returned of the result
    display dialog "Enter state as two letter abbreviation" default answer ¬
      "ca" buttons {"OK"} default button 1
    set my_state to text returned of the result
    tell application "Safari"
    -- The next two lines should be entereed as ONE LINE:
      open location "http://www.google.com/search?q=rphonebook:" & 
        first_name & " " & last_name & " " & my_city & " " & my_state
    end tell
  end try
end tell