views:

22

answers:

3

I'm creating a search form using an asp:button control with the urlpostback set to a results page. The problem is, the asp:button uses Visual Basic and the search results from Google require Javascript.

Is there a way to take the data from an asp: textbox in VB and then send it to another page that uses Javascript and use the data?

A: 

You can always save the search results into a hidden form field, and set the page's form option to post to your "destination" page. From there, you can use your typical JavaScript methods to pull the data out of the posted form.

Dillie-O
I don't understand. How would I go about doing this?
Andrew
Actually, it wouldn't work anyway since Javascript can't read the values of the textbox when it's in a masterpage.
Andrew
A: 

I'm not sure if it helps you but its worth a try: http://www.google.com/support/forum/p/AdSense/thread?tid=2a9b892b35120b56&hl=en

Tim Schmelter
A: 

You could try

  1. Response.Redirect - and redirect to google.com with the search query appended (as a test I just manupulated the string in my browser and it seems to work. Look at the querystring parameter "q"

  2. Try the google search api

Saif Khan