To create a bookmarklet for a translation engine, follow these steps:
DUMMY_ADDRESS
If the dummy address is somewhere in the middle, replace it with "+escape(location.href)+". Append "; to the end of the line. Add javascript:location.href=" to the begining of the line.
For example:http://translate.google.com/translate?u=DUMMY_ADDRESS&langpair=en%7Cfr
becomes
javascript:location.href="http://translate.google.com/translate?u="+escape(location.href)+"&langpair=en%7Cfr";
If the dummy address is at the end, replace it with "+escape(location.href); and add javascript:location.href=" to the begining of the line. For example:
http://translate.google.com/translate?langpair=en%7Cfr&u=DUMMY_ADDRESS
becomes
javascript:location.href="http://translate.google.com/translate?langpair=en%7Cfr&u="+escape(location.href);
If the dummy address is nowhere to be found, then the
settings are passed in the background
and you cannot
create a bookmarklet for it.
Need to find a translation engine? Visit Google Directory.
Daniel Wang