This week's book giveaway is in the Design forum.
We're giving away four copies of Design for the Mind and have Victor S. Yocco on-line!
See this thread for details.
Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

translate from English to Hindi

 
Anish Kumar Singh
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

can anybody help me to translate from english to hindi

i have two text boxes and of name "text" "textcopy" now when i type in text box 1
i want that text to be converted to hindi and typed at the same time in the second text box.





the above code copies the contents of the textbox 1 in real time into the second text box.

now i want to use google API to translate for which i have a sample code but that does not do the work.


 
Lester Burnham
Rancher
Posts: 1337
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
...that does not do the work...

ItDoesntWorkIsUseless

What does it do, exactly? Are there any error messages in the JavaScript console? Does the request actually go out to Google? If so, is the request structurally equivalent to successful requests made by other means?
 
Anish Kumar Singh
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator


the translation does not happen.

but when i type in the second box then after the space bar is pressed the word is translated.

actually i think i need a code to read the word before spacebar is pressed and then send that word to google for translation, and print the output in the second box.

any ideas or thoughts would be appreciable.
 
Lester Burnham
Rancher
Posts: 1337
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Lester Burnham wrote:Are there any error messages in the JavaScript console? Does the request actually go out to Google? If so, is the request structurally equivalent to successful requests made by other means?
 
Anish Kumar Singh
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are there any error messages in the JavaScript console?
no error messages are there

Does the request actually go out to Google?
i don't think so . it does not go out to google. but how do i check that if it goes out to google or not.


If so, is the request structurally equivalent to successful requests made by other means?
yes the structure is correct, the method is given in the google transliteration documentation.



i have also tried the code for checking spacebar keypress.



do you think the above if integrated can be of some help.

 
Lester Burnham
Rancher
Posts: 1337
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Anish Kumar Singh wrote:but how do i check that if it goes out to google or not.

By using an HTTP Monitor or proxy, or a Firefox plugin like LiveHttpheaders.

yes the structure is correct

You can't know that unless you observe both a successful and an unsuccessful request in one the tools mentioned above.
 
Anish Kumar Singh
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for replying Lester.

i'm posting a code below, please run and check what it does.

it work's but the transliteration does not work. it also goes out to google.

only when we type in the second text box.

the code below does english to greek.


 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic