Install Scripts

Installation scripts are required to get up a running. EETech has done the hard work to automate script generation so you can get started sooner.

EETS requires one JS scripts and two HTML elements to be installed on a site. These scripts are generated automatically when the engine is created and can be found in the user portal. Instructions on where to place the scripts can be found below.

The three scripts are aptly described as Script, Input, and Results and we'll use those names as references throughout this page.

Script code belongs in the web page head block and grants functionality to the Input and Results elements. Input is the search box element and should be placed where you want your users to use your search, typically in top navigation. Results is the SERP element. Place Results on a dedicated blank page or anywhere you want users to view search results.

Simple instructions are as follows:

  1. Add the install Script code to your site, between the <body> & </body> HTML tags on the pages with the search box and the results page.

  2. Insert the Input tag, or add the id to an existing input on your site to link the input with bz-search.

  3. Add the Results HTML tag on the same page as the script and input.

  4. Enjoy the new search experience.

Each of the scripts can be edited directly or by entering the following information on the script page:

  • Results per page

  • Search result page redirect

  • Search box selector

  • Search box placeholder text

  • No results text

  • Description size

  • Enable URL Rewriting

Results Per Page

The default number of results returned on a search engine result page (SERP).

Default value: 10 pages

Options include:

  • 10

  • 20

  • 40

  • 60

This attribute is a part of the Input script as bz-results-per-page.

Users can also change the number of results they see on the SERP, using the "Results per page" dropdown.

Search Result Page Redirect

Search Result Page Redirect reflects your SERP URL and instructs the search box where to send your user after they enter a query. Since you are able to define the path of your SERP, this attribute must match.

Default value: /search-results

You must follow the standards of HTTP URLs for absolute implicit domain names. For more information on this, please visit Mozilla.com.

Search Box Selector

Search Box Selector adds an input id to the search box tag. Only ID limitations apply. With HTML5, those are an ID must contain at least one character and may not contain any space characters. You can read more in the HTML5 specification here.

Search Box Placeholder Text

Placeholder text is the text that appears in the search box prior to a user typing and provides a smoother experience for your UI by making the purpose and function of the search box obvious before they even use it.

In other words, this text should reflect the objective of using EETS search on your site, which may change business to business. Some examples are "Search for parts", "Search our site", and "Search our content and cross-reference".

Placeholder Text attribute is stored in the Input element as bz-searchPlaceholder.

No Results Text

This text displays when a query returns zero matched results, including Smart Box matches. There are no limits on the number of characters.

Default value: "Your search found no results. Please try again."

Description Size

Description size controls the character length of returned result descriptions. Some descriptions may be shorter than this value depending on the size of content for that document.

Default value: 500 characters

Limits: Numerical characters only, number must be non-zero.

Enable URL Rewriting

URL Rewriting is a specialized tool used to redirect index documents based off a pattern. The primary use case for this tool is for maintaining an engine across stage(s) of website development as the subdomain changes.

Scripts

Three scripts are provided to place Keyword Search on your site.

  1. Script

  2. Input

  3. Results

Script

Place the first script at the top of your cms in the head section.

Input

Place the input script in your html where you would like to place the search box.

Results

Place the results script on a page for results to display using the provided view template. It is recommended to use a blank page to allow space and a smooth user experience.

Last updated