Swiftype

Posted in: Newspaper
Post count: 27

Hi I am trying to get the API for the search Swiftype to work.

I have applied the suggested code to the javascript footer section (before the </body> tag in HTML)

<script type=”text/javascript”>
(function(w,d,t,u,n,s,e){w[‘SwiftypeObject’]=n;w[n]=w[n]||function(){
(w[n].q=w[n].q||[]).push(arguments);};s=d.createElement(t);
e=d.getElementsByTagName(t)[0];s.async=1;s.src=u;e.parentNode.insertBefore(s,e);
})(window,document,’script’,’//s.swiftypecdn.com/install/v2/st.js’,’_st’);

_st(‘install’,’X9BNG2bfdQNHgCke8b74′,’2.0.0′);
</script>

But the wordpress default search still is being used

Can you help me please on how to install this.

Dan Kosmayer

Post count: 35449

Hi,

So if I understand correctly, you get this code:
<script type="text/javascript">
(function(w,d,t,u,n,s,e){w['SwiftypeObject']=n;w[n]=w[n]||function(){
(w[n].q=w[n].q||[]).push(arguments);};s=d.createElement(t);
e=d.getElementsByTagName(t)[0];s.async=1;s.src=u;e.parentNode.insertBefore(s,e);
})(window,document,'script','//s.swiftypecdn.com/install/v2/st.js','_st');
_st('install','X9BNG2bfdQNHgCke8b74′,'2.0.0′);
</script>

That need to be set in the theme to use a different search ? there are some indications where the code should be set in a theme ?
Please provide someone details about the api code.

Thank you!

Viewing 2 posts - 1 through 2 (of 2 total)
The forum ‘Newspaper’ is closed to new topics and replies.