window and plug the highlighted text into a URL. This code needs to
be in a file somewhere on your computer where it can be accessed from
the browser, and won't be deleted in a fit of spring cleaning. You
could even create a new folder for it,
c:\scripts\. If you have another location in
mind, be sure to change any references to
c:\scripts\ in the following code.
Create a file
AmazonSearch.html and add this code:
var searchURL = new String("http://www.amazon.com/exec/obidos/[RETURN]
var w = window.external.menuArguments;
var d = w.document;
var s = d.selection;
var r = s.createRange( );
var term = new String(r.text);
window.open(searchURL + term);
Save it in the c:\scripts\ directory.
Next you need to add some information to your Windows registry to let
Internet Explorer know where to find
AmazonSearch.html, and when exactly it should be
executed. You could open up a registry editor
and add values manually, but it's just as easy to put the information
into a .reg file and add it by double-clicking.
Create a new file called AmazonContext.reg and
add the following code:
Windows Registry Editor Version 5.00
Backslashes, like those in filesystem paths, need to be escaped as
double-slashes (\\) in registry entry files.
Save the file on your desktop, double-click it, and confirm that you
want to add the new registry information. This setting adds a
right-click menu entry called "Search Amazon" that will appear
and will execute it when the highlighted entry is clicked.