Re: Right click word look up
- From: "Ramesh, MS-MVP" <ramesh@xxxxxxxxxxxx>
- Date: Mon, 22 May 2006 21:26:34 +0530
See also:
Right-Click Dictionary Download - MSN Encarta:
http://uk.encarta.msn.com/encnet/features/dictionary/quick_dictionary_download.aspx
--
Regards,
Ramesh Srinivasan, Microsoft MVP [Windows XP Shell/User]
Windows® XP Troubleshooting http://www.winhelponline.com
"Ramesh, MS-MVP" <ramesh@xxxxxxxxxxxx> wrote in message
news:%23Yl37UbfGHA.3888@xxxxxxxxxxxxxxxxxxxxxxx
Hi Antonio,
JS or VBS would be fine. This is what I use (searches Dictionary.com). The
following code base is actually from "Google Search" menu extension, and
I've modified it a bit.
<html>
<script language="JavaScript" defer>
var parentwin = external.menuArguments;
var doc = parentwin.document;
var sel = doc.selection;
var rng = sel.createRange();
var strhtml = new String(rng.htmlText);
var str = strhtml.replace(/<[^>]*>/g," ");
str = str.replace(/\s+/g, " ");
str = str.replace(/^\s*/,"");
str = str.replace(/\s*$/,"");
if (str.indexOf(" ") != -1)
str = '"' + str + '"';
var bnewwindow = external.menuArguments.event.shiftKey;
var url = "http://www.dictionary.com/search?q=" + escape(str);
try {
url = gg.Search(String(str));
bnewwindow = gg.OpenNewWindow();
} catch (ex) { }
if(bnewwindow)
window.open(url);
else
parentwin.navigate(url);
</script>
</html>
And here is the REG info:
- - -
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\MenuExt\&Dictionary]
"Contexts"=hex:10,00,00,00
@="C:\\WINDOWS\\WEB\\dictionary.htm"
- - -
So for Encarta, use this
<html>
<script language="JavaScript" defer>
var parentwin = external.menuArguments;
var doc = parentwin.document;
var sel = doc.selection;
var rng = sel.createRange();
var strhtml = new String(rng.htmlText);
var str = strhtml.replace(/<[^>]*>/g," ");
str = str.replace(/\s+/g, " ");
str = str.replace(/^\s*/,"");
str = str.replace(/\s*$/,"");
if (str.indexOf(" ") != -1)
str = '"' + str + '"';
var bnewwindow = external.menuArguments.event.shiftKey;
var url = "http://encarta.msn.com/dictionary_/" + escape(str) + ".html";
try {
url = gg.Search(String(str));
bnewwindow = gg.OpenNewWindow();
} catch (ex) { }
if(bnewwindow)
window.open(url);
else
parentwin.navigate(url);
</script>
</html>
Save as c:\windows\web\encarta.htm
And the REG file for this.
- - -
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\MenuExt\Encarta]
"Contexts"=hex:10,00,00,00
@="C:\\WINDOWS\\WEB\\encarta.htm"
- - -
--
Regards,
Ramesh Srinivasan, Microsoft MVP [Windows XP Shell/User]
Windows® XP Troubleshooting http://www.winhelponline.com
"Antonio" <Antonio@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:8B3403AB-69CE-4036-AFB0-F838B513E395@xxxxxxxxxxxxxxxx
Hi Alan,
Thank you for the link.
That is exactly what I needed.
I am familiar with VB Express and VBA. Can the script be in any of those two
languages?
Thanks,
Antonio
"Alan Edwards" wrote:
Try here (or around this area)
Adding Entries to the Standard Context Menu:
http://msdn.microsoft.com/workshop/browser/ext/tutorials/context.asp
....Alan
--
Alan Edwards, MS MVP Windows - Internet Explorer
http://dts-l.org/index.html
On Mon, 22 May 2006 03:25:02 -0700, in
microsoft.public.windows.inetexplorer.ie6.setup, Antonio
<Antonio@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote:
Hi Don,
Thank you for your suggestion.
It helps and I have downloaded the dictionary.com tool bar.
I still like Encarta better, amont other things because it has free
pronunciation sample which dictionary.com does not.
Is it possible to program IE myself, or change the registry, to do it?
Regards,
Antonio
"Don Varnau" wrote:
Hi,
I don't know of a tool which would use the Encarta dictionary. But,
both
www.dictionary.com and www.m-w.com offer such a tool.
http://dictionary.reference.com/tools/
http://www.m-w.com/downloads.htm
Hope this helps,
Don
[MS MVP- IE]
"Antonio" <Antonio[at]discussions.microsoft.com> wrote in message
news:6E3B2C38-DBC1-4148-855C-800A2D33ACC2@xxxxxxxxxxxxxxxx
I would like to have an option to open the Microsoft Encarta
dictionary
definition of a word when I right click on it on any web page.
Can it be done?
Thanks,
Antonio
.
- References:
- Re: Right click word look up
- From: Don Varnau
- Re: Right click word look up
- From: Alan Edwards
- Re: Right click word look up
- From: Antonio
- Re: Right click word look up
- From: Ramesh, MS-MVP
- Re: Right click word look up
- Prev by Date: Re: Right click word look up
- Next by Date: how do I setup an ftp
- Previous by thread: Re: Right click word look up
- Next by thread: how do I setup an ftp
- Index(es):
Relevant Pages
|