Also, it is great way to monetize the forum using Adsense search ads when people search for topics on discourse.
Adsense gave me 2 codes,
- one for showing the search box and search icon
- ONE to place on the actual search page which is meta.discourse.org/search
But they both are JS script tags and if i follow this How to add custom content that only appears on your homepage and try to add the JS script tag inside the Handlebar JS code, it gives me syntax error, i am unable to put the script tag inside it.
The 2 codes look something like this:
<script async src='https://cse.google.com/cse.js?cx=3d0aca23447b4f'></script><div class="gcse-searchbox-only"></div>
And the other one
<script async src='https://cse.google.com/cse.js?cx=3d0aca234fcfb'></script><div class="gcse-searchresults-only"></div>
Where and how can i put these on my disocurse forums so they can be rendered correctly on correct places?