Linguistics

How to search multiple websites fast (for Word research)

I’ve talked about using iMacros in the past. Basically, you click a button, a dialogue pops up and asks you “Which word do you want to look up?” and in 4 seconds, you have a Google Images link to the word, a Forvo.com recording, a bilingual dictionary entry and a monolingual dictionary entry. Magic. Typically, it’s a bit of a pain to set up, but in preparation for an upcoming workshop, I’ve decided to make it a lot easier.

The Options

[AWESOME UPDATE 2-2-16]

So our tech guys, Matthew and Leonardo, created a javascript version of the multisearch scripts that we have, which appears to be way easier than all of the versions we’ve had so far. Basically, you go to the link, type in your word, and poof – multisearch happens. You can bookmark that link and reload as needed whenever you want to search for a word. Or for even faster searching, right click (control-click on a Mac) on the link you want, select “Download Linked File.” It will download an HTML file that you can double-click and it’ll search ridiculously fast, since you won’t need to load our website every time you want to look for a word.

Our current collection of multisearch links is as follows:

Main MultiSearch Pages:
Chinese MultiSearch
Spanish MultiSearch
Russian MultiSearch
Portuguese MultiSearch
Japanese MultiSearch
Italian MultiSearch
Hungarian MultiSearch
German MultiSearch
French MultiSearch
Dutch MultiSearch
English MultiSearch (for those who want to learn English)
Cantonese MultiSearch

MultiSearch links from Visitors:
Polish MultiSearch
Korean – 5 Tabs MultiSearch
Korean – 4 Tabs MultiSearch
Korean2 MultiSearch
Hindi MultiSearch
Hebrew2 MultiSearch
Hebrew MultiSearch
French – 11 Tabs MultiSearch
Dutch2 MultiSearch
Arabic to French MultiSearch
Arabic MultiSearch

Javascript Code by: LSProgramming@yahoo.com

How to edit the code in the Javascript version (to change the sites it searches)

If you like the Javascript solution but want it to search a different site (or an additional site), then all you need to do is download one of the multisearch HTML files and edit the code in a text editor (I like Notepad++ on Windows, Textwrangler on Mac). The code is really easy to read and change. Here’s a sample one for German. Ignore all the code that isn’t in bold:

<!DOCTYPE html>
<html>
<head>
</head>
<body style=”background-color:grey”>

<p>What German word would you like to multisearch? Type below, then press enter please.</p>
<input type=”text” id=”boxu” autofocus>

<script>
document.getElementById(“boxu”).onkeydown = function(e) {searchy(e)};
function searchy(e)
{
if (e.which == 13)
{
var q = document.getElementById(“boxu”).value;
window.open(“http://translate.google.com/translate?hl=en&sl=de&tl=en&u=http%3A%2F%2Fwww.google.de%2Fsearch%3Fq%3D” + q + “%26num%3D10%26hl%3Dde%26tbo%3Dd%26site%3Dimghp%26tbm%3Disch%26sout%3D1%26biw%3D1075%26bih%3D696”);
window.open(“http://www.forvo.com/word/” + q + “/#de”);
window.open(“http://www.dict.cc/?s=” + q);
window.open(“http://translate.google.com/translate?sl=de&tl=en&u=http%3A%2F%2Fde.thefreedictionary.com%2F” + q);
document.getElementById(“boxu”).value = “”;
}
}
</script>
</body>
</html>

Basically, all you need to care about are those window.open parts. In the example with “window.open(“http://www.forvo.com/word/” + q + “/#de”);“, it’s opening a new tab in your browser. The address it goes to is http://www.forvo.com/word/SOMETHING/#de, where SOMETHING is whatever you typed in when it asked you “What German word would you like to multisearch?”. So if you want that link to be a link to a German Wiktionary article on your word, then you’d go to an example page, and check out the URL. Here’s a page about rabbits (Hase): https://de.wiktionary.org/wiki/Hase – you can see that the word is the very end of the URL. So the new code you want would be this: window.open(“https://de.wiktionary.org/wiki/” + q);

If you wanted that link to be a Google Translated version of the same link, you do the same process, finding an example page, figuring out where in the URL you can see your search word, and then replacing it with “q“. So here’s our Rabbit page in Google Translate (I put Hase in bold):

https://translate.google.com/translate?sl=de&tl=en&js=y&prev=_t&hl=en&ie=UTF-8&u=https%3A%2F%2Fde.wiktionary.org%2Fwiki%2FHase&edit-text=

And our code would be:

window.open(“https://translate.google.com/translate?sl=de&tl=en&js=y&prev=_t&hl=en&ie=UTF-8&u=https%3A%2F%2Fde.wiktionary.org%2Fwiki%2F” + q + “&edit-text=”);

If you want to search additional websites, just add more of those “window.open” lines, instead of changing the ones that are there. Then save the file and open it in your browser.

If you make an awesome script that would be helpful to other folks (rather than just a slightly changed website or two), please drop it in the comments so we can add it to our collection of links above!

 

Older Versions, in case you prefer not to use the Javascript one:

Depending upon your operating system, you may have a few different options available to you. If you’re on a Mac, you’re in luck. A reader of mine designed an Applescript that is lightning fast for this purpose, and it runs great in both Chrome and Safari. I’m linking that first, because it’s by far my favorite option. Your second option is iMacros for Firefox. It does the job quite well, it’s not too difficult to set up, and it runs on both Macs and PCs. Due to some changes in how Google Translate works, it wasn’t working for a period of about 6 months, but it appears that Google’s fixed their engine, and the Firefox solution is back. Next, you can do this in iMacros for Chrome. I’ll be honest, it’s a royal pain in the ass to set up, and it can be somewhat buggy, but it’s the only option that seems to survive whenever Google does any major changes. Last, Peter Carroll from Rhinospike just coded a javascript version that will run in any browser. I haven’t been able to get it to behave with Google Translate quite yet, but that’s coming!

Video: How to set this up, and how to modify the code if you want to search different websites

How to do it with Applescript (Macs using Safari or Chrome):

A reader of mine designed the following Applescripts. They are language learning heaven in the form of little applets. Basically, you’ll just download your language, fix your security settings in System Preferences, double-click, and you’re done:

1. Download your language

I’m working on filling out this list, but as it has to be done by hand, bear with me! The Chrome links rely on Chrome’s auto-translate function (or you can use Chrome’s Google Translate plugin), and Safari uses a more brute-force Google Translate link, which currently works fine but did break once upon a time.

Mandarin Chinese (Chrome | Safari )
Dutch (Chrome)
French (Chrome | Safari )
German (Chrome | Safari
Hungarian (Safari)
Italian (Chrome | Safari )
Japanese (Chrome | Safari )
Portuguese (Safari)
Russian (Chrome | Safari )
Spanish (Chrome | Safari )

2. Doubleclick the file to unzip. Inside, you’ll find two files: A .scpt Applescript file (you can open this in Applescript and run it or modify it), and a little applet, that you can double-click to instantly search for a bunch of information on a word. The only issue with the applets is that you won’t be able to use them with standard security settings, so you’ll need to make your Mac less secure to open them. Sorry. To make your Mac less secure, begin by saying out loud, “I’m not holding Gabe liable if I download a virus and blow up my computer.” Next, open up System Preferences (Apple menu -> System Preferences).

3. Click on “Security and Privacy,” in the top row of preferences.

4. Click the padlock on the bottom left, type in your password and hit ‘Unlock’

5. Towards the bottom of the window, click ‘Allow apps downloaded from … Anywhere’

6. It’s going to warn you that this is a bad idea. Ignore that. Click ‘Allow from Anywhere’.

Nice. Now double-click on your newly downloaded Applet, type in your favorite word, and bask in the ridiculous speed of these applets!

How to do it in Firefox (Macs and PCs):

Firefox Instructions:

This tutorial shows you each step in Firefox. I’m not having much luck getting this set up in Chrome (iMacros is apparently more buggy in Chrome). When I click one of these bookmarks in Chrome, nothing happens. If you have more luck, then let me know what you did in the comments!

  1. Get Firefox.
  2. Get and install iMacros for Firefox imacros
  3. Now bookmark the first link, and then choose your language (and bookmark that). I’d suggest you put the two links up in your bookmarks bar, so they’re easy to access:
  • Open 6 Tabs (4x Empty, 1x Google Images Basic Mode, 1x Google Translate) – These bookmarklets only work properly when you have 4 tabs open and you’re in the leftmost tab. This little script opens up a bunch of tabs and puts you in the leftmost one. You’ll only need to use it once per session.

Links for English Speakers (Your native language is English)

Links for German Speakers (Your native language is German):

Links for Russian Speakers (Your native language is Russian)

Links for Bulgarian Speakers (Your native language is Bulgarian)

Links for Romanian Speakers (Your native language is Romanian)

* – The links with asterisks are preloaded into Google Translate. Mouse-over to see the original text in your target language.

How to do this in Chrome

Sigh. Chrome is a pain. Basically, there’s no way for me to send you pre-packaged bookmarks like I can in Firefox, so you need to follow the ugly instructions over at the original link. The good news is that my Pastebin has code for Chrome pre-done in a wide variety of languages, so you don’t need to really code…you just need to go through all the stupid steps and then copy + paste.

To change the websites used

If you’d like to change any of the dictionaries/websites used, then all of the code is available at my Pastebin. Go there, edit the code, and put it into iMacros. You’ll use the other iMacros tutorial for that.

Many thanks to everyone who donated code on the last thread. I still have to do Japanese, Mandarin, Korean and Arabic, at the very least, so if you’re studying one of those languages, either let me know what resources you use, or (even better), make your own script and share the code in the comments, and I’ll turn it into a bookmarklet, put it in my pastebin and share it here.

Try the Fluent Forever App

By the way, did you know the book is now an app. Check out our Fluent Forever app!

Discover our immersive method rooted in neuroscience designed to take you to fluency in < 30 minutes a day through four steps:

  • 1. Train your ears with pronunciation lessons.
  • 2. Learn vocabulary through images instead of translations.
  • 3. Learn grammar naturally through stories relevant to you.
  • 4. Practice your speech to fluency with native tutors.

Check out our Fluent Forever app!

Enjoy what you're reading?
Sign up for more

Think In Any New Language

GET THE APP