Is it possible to pre-fill the search field with text when the Google Custom Search page is loaded using the standard copy and paste code (free with ads)?
If yes, how can this be achieved?
Below is the code snippet:
<div id="cse" style="width: 100%;">Loading</div>
<script src="//www.google.com/jsapi" type="text/javascript"></script>
<script type="text/javascript">
google.load('search', '1', {language : 'en'});
google.setOnLoadCallback(function() {
var customSearchControl = new google.search.CustomSearchControl('000203232594935527974:aspio6dmwkq');
customSearchControl.setResultSetSize(google.search.Search.FILTERED_CSE_RESULTSET);
customSearchControl.draw('cse');
}, true);
</script>
<link rel="stylesheet" href="//www.google.com/cse/style/look/default.css" type="text/css" />
I don't mind the floating default Google logo and the "Custom Search" text.
Additionally, I am interested to know if it's possible to trigger the custom search on page load.