LinkedInAttic/inject

Add Search backed by Google to WebSite

jakobo opened this issue · 1 comments

It's possible to enable simple searching from Sean's mocks on the website. A form + Google query can do this for us.

Here's the code for a Custom Google Search Engine for our site:

<script>
(function() {
  var cx = '007454891895213570750:rm0mkbrbrmi';
  var gcse = document.createElement('script'); gcse.type = 'text/javascript';
  gcse.async = true;
  gcse.src = (document.location.protocol == 'https:' ? 'https:' : 'http:') +
      '//www.google.com/cse/cse.js?cx=' + cx;
  var s = document.getElementsByTagName('script')[0];
  s.parentNode.insertBefore(gcse, s);
})();
</script>
<gcse:search></gcse:search>

Place where the box is to appear. We may need to style it though. We can tweak based on what settings from http://www.google.com/cse/ will work best

946a699 resolves this