Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

HElp! Building a Translator

Status
Not open for further replies.

LadyClaire

Technical User
Dec 10, 2002
26
0
0
US
Ok, this is in detail what I am trying to do. I am trying to build a language translator to tanslate back and forth between English and Elvish. I have an Elvish dictionary already. I would like to know the best way to build it. An example of what I am trying to build can be found at This page was done in CGI script, but I have no idea how to do CGI, Perl, PHP or ASP. I am willing to learn though and I learn quickly. I was wondering if there is a way I can make a simple text file of the dictionary, then write some code up where once the word and or phrase is put in the text box, the program will searh the text file and give out the translation to that word? I have tried this in JavaScript but it will take forever and a day since I have to type out each word, its translation as well as phrases and their translations. THankyou for any help offered.
 
Yes, you can create a text file but....

in order for any script/program to find the correct translation, you're going to have to have each possible word/phrase combination in the text file. Ideally, each line in the text file should contain a single word or phrase.

If you have access to a MySql database, I'd recommend that you put this info into a MySql table, then use PHP to access the table and use am SQL statement to do the searching.

Anyway you look at it, it's going to take a lot of time to develop the dictionary. Of course, you might get away with a rudimentary "translator" that would just collect the elvish words and then string them together but I doubt if you'd get much of a meaningful translation. I'm basing this on an assumption that "elvish" is syntactically sensitive - much like French or Spanish - where word meanings change based on other words in the sentence.

Good luck! There's always a better way...
 
I already have a dictionary in text format and in doc format. so thats no problem. What the problem is, is actually using ASP or CGI or PHP or MySql to where what ever code I write, it searches the database (dictionary I have)and pulls out the words or phases one does a search for.
 
Again, this is not a problem. You're code will ask for the user to type in a word or phrase. Then you'll search the database using an SQL query. If the word or phrase is found, the translation will be returned. If not, then ??? There's always a better way...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top