0

I want to write a simple Client-side Application that will send a following request to Google

http://www.google.com/dictionary/json?callback=a&sl=en&tl=en&q=Hello

If you directly click on this link you will get a Json for downloading.

What I want to achieve here is that I will have a textbox and a button, when user enters something in the textbox and click on the button I will prepare the above url and get the json which I will parse and display in a paragraph on my web page.

I am relatively new to this WebAPI stuff but I know JavaScript. So can anyone tell me what is the better way to achieve this and do I need to create a OAuth (Authorization) for this.

Apoorva sahay
  • 1,900
  • 3
  • 28
  • 45

1 Answers1

0

Use This and i know you can improve it

<form method="post" action="http://www.google.com/dictionary/json?callback=a&sl=en&tl=en">
    <input type="text" name="q">
    <input type="submit" value="download" />
</form>
Nanhe Kumar
  • 15,498
  • 5
  • 79
  • 71
  • I don't want to use form tag. I want to send this request onClick event of a paragraph. you can refer the code here http://jsfiddle.net/apoorvasahay/WbQ4W/4/ – Apoorva sahay Aug 14 '13 at 10:55