I have pasted the code in a webpage I have full of links. And it worked nicely brining up search results from sites I linked to from my webpage. But how can I tie this up to my AdSense account?
The code Google provides for "on the fly" Custom Search Engine is as follows:
<form name="cse" id="searchbox_demo" action="http://www.google.com/cse">
<input type="hidden" name="cref" value="" />
<input name="q" type="text" size="40" />
<input type="submit" name="sa" value="Search" />
</form>
<script type="text/javascript" src="http://www.google.com/cse/tools/onthefly?form=searchbox_demo"></script>
Do I change by hand the id value from "searchbox_demo" to my AdSense id? I have not read that but its just a guess.
Seems there is NO way to integrate AdSense into the "on the fly" custom search engine unless you are using "linked custom search engines" through xml files you'd have to maintain, which is not something I want to do.