Gossamer Forum
Home : Products : Links 2.0 : Customization :

alta vista has changed url for translate it

(Page 1 of 2)
> >
Quote Reply
alta vista has changed url for translate it
Alta Vista has changed their url for their translator. The translate mod is no longer working. I have also checked other Links sites that have this mod and is not working on any of the sites I checked. The new url for a link after a language has been selected and entered on the alta vista site now looks like this;
http://babelfish.altavista.com/...one&frame=random

I have tried changing the url in the translate.cgi to;

Code:
$tmp = "http://babelfish.altavista.com/translate.dyn?url=$url&lp=$languages{$language}&doit=done&frame=random";
but that did not work. Does anyone know how the url needs to changed?

Also, does this line also need to be edited?
Code:
$stuff =~ s,/cgi-bin/translate\?lp=[^&]+&urltext=([^"'>]+),$ENV{'SCRIPT_NAME'}?url=$1&language=$language,g;
print "$stuff";
Thanks,

Jimmy Crow
http://www.homewithgod.com/
Quote Reply
Re: alta vista has changed url for translate it In reply to
Looks like it is time to find a new translation program...

It seems that Babelfish has added some protective .js embedded
files in their new translation program to ward off people from
"using" their program.

I changed the variables in the translate.cgi file similar to
what you did, and I got a 404 Not Found with the following
location:

http://vlib.anthrotech.com/detect.js

So, it looks like we won't be able to use Babelfish anymore
unless someone can hack through to the core of the program
and find out how to bypass the .js files.

Of course, the work-around is linking to the Babelfish progrm
in the following manner:


http://babelfish.altavista.com/translate.dyn?url=<%URL%>&lp=&doit=done&frame=random


Although I do not know if this will work since the new program places Session
IDS for translating URLs and text.

For info about adding a Translate Form, go to:

http://doc.altavista.com/...arch/babel_faq.shtml

OR finding another translation program that is easy to hack.

Thanks for bringing this problem to our attention!

Wink

Regards,

Eliot Lee
Quote Reply
Re: alta vista has changed url for translate it In reply to
Okay...Babelfish may be out but the translator at Go.com is better anyways. It has no 500 word (or whatever the limit is) cutoff.

I have seen it in use, but cannot remember where.

So, if someone is redoing the translator mod - check out http://translator.go.com

Good luck!

Quote Reply
Re: alta vista has changed url for translate it In reply to
The example translate link that I have in the first post works every time I click on it, so I was wandering if we could pass this from the link html;

Code:
http://babelfish.altavista.com/translate.dyn?url=<%URL%>&lp=$languages&doit=done&frame=random
to a trans.html. Then use a redirect script to define $languages through a form and then redirected with the selected language.

Jimmy Crow
http://www.homewithgod.com/
Quote Reply
Re: alta vista has changed url for translate it In reply to
In Reply To:
The example translate link that I have in the first post works every time I click on it, so I was wandering if we could pass this from the link html;
You could use the same translate.cgi script...however, in the translate_error.html and translate.html file, you will have to change the field values to the babelfish values and also change the Action to the action script in the FAQ page that I provided.

Regards,

Eliot Lee
Quote Reply
Re: alta vista has changed url for translate it In reply to
Alta Vista has not updated their FAQ yet, so I started playing around with the script some and could not get it to work. I then tried using a redirect script to call the translation and I kept getting directed to their default translation page. But if I view the source of my translate.html and copy the redirect link and write it as a hard link on an html page and then click on the same address it will translate the page. Apparently, Alta Vista is detecting a cgi form and not allowing it.

Jimmy Crow
http://www.homewithgod.com/
Quote Reply
Re: alta vista has changed url for translate it In reply to
Try making the url like this
($goto = "http://babelfish.altavista.com/translate.dyn?urltext=" . "$goto" . "\&doit\=done\&lp\=en_fr\&BabelFishFrontPage\=yes");

naturally, set the language preference to whatever you pick... Seems to work for me.

Jerry

Quote Reply
Re: alta vista has changed url for translate it In reply to
I have switched my forms to translator.go.com and it works pretty well...basically the same as before. I have also provided direct links to the translator.go.com query string...works just the same.

Regards,

Eliot Lee
Quote Reply
Re: alta vista has changed url for translate it In reply to
I just finished doing the same thing. Go.com seems to work even better. It will also do pages with frames where alta vista would not. Hopefully, they won't change their url...

Thanks everyone for the help!

Jimmy Crow
http://www.homewithgod.com/
Quote Reply
Re: alta vista has changed url for translate it In reply to
You're welcome....

And thank you for bringing this to our attention.

Smile

Regards,

Eliot Lee
Quote Reply
Re: alta vista has changed url for translate it In reply to
Hi all:

BTW, the query string to pass to Go.com Translator is:

http://translator.go.com/cb/trans_entry?input_type=url&submit=url&url=$url&lp=$languages{$language}

I would greatly recommend that you acknowledge the use of their services with a link to Go.com Translator.


Dan :)


Quote Reply
Re: alta vista has changed url for translate it In reply to
Wow - I always get a kick out of helping those that have helped me. Feels good. BTW - go.com does do a much better job

Quote Reply
Re: alta vista has changed url for translate it In reply to
Yes...that is a good suggestion.

Regards,

Eliot Lee
Quote Reply
Re: alta vista has changed url for translate it In reply to
Hotwheel
In Reply To:
BTW, the query string to pass to Go.com Translator is:

http://translator.go.com/cb/trans_entry?input_type=url&submit=url&url=$url&lp=$languages{$language}
I include the above in translate.cgi, and even though the Go.com page load i get the following error message with every page I tried:
In Reply To:
Sorry, we could not translate this page. It is likely that the URL is incorrect. Please re-enter the URL and try again.
Something else that I should change in the script ot in the html form?

Thanks.
Manuel


Quote Reply
Re: alta vista has changed url for translate it In reply to
If you are using templates, you need to copy the form into the translate.html file. And for your LINKS, you need to add the following in your link.html file:

Code:

<a href="<_cgi_url%>/translate.cgi?input_type=url&submit=url&url=<%URL%>&lp=">Translate Link</a>


Regards,

Eliot Lee
Quote Reply
Re: alta vista has changed url for translate it In reply to
Yes. My translate script is different in that only the URL and language is passed to the translate script which in turn constructs the query string to pass to go.com - in the form I gave. How it works for you depends on your script. BTW, I had to change the following definition table as go.com differs somewhat from AltaVista. Check yours in case (of course, again it depends on how your translate script is coded):

%languages = (
french => 'en_fr',
german => 'en_ge',
italian => 'en_it',
portugese => 'en_pt',
spanish => 'en_sp'
);

With AltaVista, German was de and Spanish was es.


Dan Smile


Quote Reply
Re: alta vista has changed url for translate it In reply to
Eliot,

What I was mising was the code in link.html as you have it. I make this changes and the one's mentioned by Dan and everything is working right!

Thanks!
Manuel

Quote Reply
Re: alta vista has changed url for translate it In reply to
Good.

Regards,

Eliot Lee
Quote Reply
Re: alta vista has changed url for translate it In reply to
this doesn't deal with this topic, sorry, but looking at go.com, which i haven't switched mine over to, it looks better for translation, and i may try to make a solution like Widgetz made before that i believe was called global.cgi, which allowed people to translate the text. I will probably put my efforts into this mostly before i do the sort mod

Quote Reply
Re: alta vista has changed url for translate it In reply to
I don't know others are doing it but my translate script opens up the page to be translated in translated form. Seamless with no hint of go.com although on the links page I give credit to go.com translator. If understand you Bmxer, you want to create a script to translate (via go.com) text submitted via a form. Simple enough unless there is more to it that I'm missing. BTW, great work on the spider script!


Dan Smile


Quote Reply
Re: alta vista has changed url for translate it In reply to
The Text translation is MUCH different than the URL translation. If you notice, when you type in text in the Text textbox, it opens to another page in http://translator.go.com, that shows two textboxes --->

1) The translated text in whatever language you chose.
2) The original text below the first textbox.

I believe what Bmxer is attempting to do is keep this translation page within your site....like the global.cgi script that Widgetz wrote a long time ago.

Wink

Regards,

Eliot Lee
Quote Reply
Re: alta vista has changed url for translate it In reply to
Hi Eliot:

Isn't that what I said? Perhaps words got in the way. But yeah, that's what I meant in terms of understanding what Bmxer meant. Two degrees including a thesis and this damn computer has turned my mind to pabulum.


Squared eyes... Dan Smile


Quote Reply
Re: alta vista has changed url for translate it In reply to
No...that is NOT what you said...and I believe you are missing my point.

Wink

Regards,

Eliot Lee
Quote Reply
Re: alta vista has changed url for translate it In reply to
Hi Eliot:

In Reply To:
If understand you Bmxer, you want to create a script to translate (via go.com) text submitted via a form.
And what I meant was that on your site you have a form text box to input text for translation - with the option, of course, to select the langauge to translate from and to (e.g., English to French). The text is translated using the go.com translator service but the output is kept onsite by means of the translate script. No intervening go.com HTML.

How about this - [Update] SCRIPT WITHDRAWN


Dan Smile
Quote Reply
Re: alta vista has changed url for translate it In reply to
Update: I'm talking to a guy (John) with GO Translator with regard to being granted permission to distribute (as freeware) my translator script. If granted (dubious at best), I'll make the script available. Otherwise, to the scrap heap with it - but there is the comparable (and excellent) script by Bmxer who may or may not make his available: http://www.gossamer-threads.com/...= collapsed&sb=5.

New Update: GO Translator has denied permission to use their services remotely in this fashion. I have withdrawn the script.


Dan Smile
> >