You know that with Google Custom Search(Google CSE), you can harness the power of Google to create a customized search experience for your own website.
What we show in this article is to explain how to insert the google CSE in a Joomla website, without installing any components or plugins, but only with the help of blank module.
First you must then install the blank module or, if you have it already installed, you need only create one with the module management.
Second you will create the necessary code from the site to Google CSE.
Our aim is to create an area in our page, which will insert the word or phrase to search, and the search result will be displayed at the center of the page where it usually shows the contents of an article.
Then proceed with the creation of the CSE, by entering its name, description, language and the sites concerned.
Among the various options you choose "Two pages", so the module containing the search box will be displayed in the pages that you want and the location that you like, while the results will show only when needed and only as if they were content.
To finish the configuration of the code that you enter you have to create a vacuum and use his article as a url parameter in the configurator.
Another option is the name of the parameter for the search string, which defaults to "q" but you can change it as you please.
In practice, if I create an article:
and wanted to search for the word "dog" to activate the search engine you should use the string:
What remains now is copy the code search box in the blank module configuration and the code results in the empty article content.
In conclusion, when you go to do a test on your CSE remember that if the site is new probably pass will not be shown any results, so let Google time to index it.
I make this simple video tutorial about this procedure: