Forum Moderators: martinibuster

Message Too Old, No Replies

AdSense for Search and DotNet

AdSense for Search and DotNet

         

gavd

7:45 pm on Aug 1, 2005 (gmt 0)

10+ Year Member



Hi everyone.
I'm new in the group, and I have my first question.
We have a site programmed with Microsoft Dot.Net where we like to include Google's AdSense for Search.
The pages (aspx) of DotNet need to have a "form" tag to make the dynamic response to the server. The script for the AdSense for Search need to have his own "form" to make a redirection to the site of Google, but that is not possible to do with aspx pages (compiler does not accept two "form" in a page). Does any body know how to program that?
I did send an E-mail to Google asking the question, but no answer until now.
Thanks.

Gustavo

PatrickDeese

7:51 pm on Aug 1, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



This may not work, but could you include the adsense for search box inside of an iframe - would that possibly make a difference somehow?

dutch_dude

9:04 pm on Aug 1, 2005 (gmt 0)

10+ Year Member



Shouldn't be a problem as long as you dont include a runat="server" attribute. You can have as may client side forms as you want but only one serverside on a aspx page.

Also make sure the forms aren't nested as I don't think that would work :)

gavd

7:43 am on Aug 2, 2005 (gmt 0)

10+ Year Member



Thanks to both for your answers.
1 - An iFrame is not working. The form of aspx takes the control in any way
2 - Yes, I know that only one form with runat=server is possible, and I have only one. But I need to conserve it in the page to make possible the working of the rest of the page. And the nested question: yes, that is precisely the problem, but I can't do any thing about that, they need to be nested because they are controls before and after the Google form, and they need to run at the server.
Any idea will be appreciated.
Gustavo

Ossifer

7:52 am on Aug 2, 2005 (gmt 0)

10+ Year Member



I have an asp.net programmed site, and use an iframe. I do have it working well. The iframe is not an asp.net file (plain .html one) which contains all of the Adsense code and the Form tags. i.e.

<form method="get" action="http://www.google.com/custom" target="_top" ID="Form1">

<!-- adsense for search code

</form>

and that's it. No other stuff in there.

gavd

7:12 pm on Aug 2, 2005 (gmt 0)

10+ Year Member



Yes, it's working. Thanks people. An iFrame did the miracle; I was wrong with my assumption that an iFrame "form" tag had less priority that the aspx "form". Thanks again.

Gustavo

[edited by: jatar_k at 8:08 pm (utc) on Aug. 2, 2005]
[edit reason] no urls thanks [/edit]