Custom Meta Search Fields

Top  Previous  Next

You can specify custom meta fields that you want Zoom to index and make searchable. This is typically useful for online shops and web sites where a database-like search criteria is necessary.

For example, you may have a real estate website with the following meta tags in a HTML file:

<meta name="NUMROOMS" content="1">

<meta name="PRICE" content="300000">

<meta name="SUBURB" content="Sydney">

<meta name="AGENT" content="Bob McGuinn">

 

Note that these tags must be in the <head> ... </head> section of the page for them to be valid meta tags according to HTML standards.

By configuring Zoom's Custom Meta Fields feature, you can index this information (along with the actual page content) and make this searchable as seen below.

custommetasearch

They will also appear alongside each search result which has the meta fields specified.

To index these tags, you would create entries such as the following in the Zoom "Custom Meta Fields" configuration window:

Meta name: NUMROOMS
Type: Numeric
Show in Search Results as: Number of rooms
Search criteria name: Min. number of rooms
Search criteria method: Greater than or equal to

editcustommeta_linux

Meta names

The "Meta name" field is only used to identify the meta tag by the Indexer. It will not be seen by the end-user. By HTML standards, the name of a meta tag cannot contain spaces but it can contain underscore characters (e.g. "NUM ROOMS" is not okay, but "NUMROOMS" and "NUM_ROOMS" is acceptable). This will match against a HTML tag such as: <meta name="NUMROOMS" content="4">.

The field name that appears to the end user is defined by "Show in Search Results as" (which defines how it appears within each search result in the listing) and "Search criteria name" (which defines how it appears in the generated search form). So you can use a more verbose and user-friendly naming convention here, including space characters (e.g. "Number of rooms")

Data Types

Each custom meta field needs to be specified as a certain data type. This affects the way in which the value will be indexed, and also how it can be searched for by the end user.

The following data types are available:

Numeric
This is a numeric integer value which you can match by: exact match, or less than/greater than comparison.
Text
This is a text value suited to names, product codes, etc. The search criteria available are "Exact match" and "Partial (substring) text matching".
Drop-down text
This is a pre-determined set of text values as specified in the "Dropdown values" list. The values in your meta tags must match the ones in the list for them to be recognized. On the search page, the end user will be provided with a dropdown box to select one of these possible values to search by.
 
editcustommetadropdown
Multi-select
This is similar to the Drop-down text option, however it allows for multiple selections, while Drop-down text only allows for one value to be selected and specified per page. Multi-select also allows you to specify multiple meta values on the same page. For example, a book item may belong to multiple genres, and have the following meta values:
 
<meta name="GENRE" content="Sci-fi">
<meta name="GENRE" content="Horror">
 
As with the drop-down text option, you must have these values specified in the list for them to be recognized and supported.
 
The multi-select box on the search form is a standard HTML multi-select box. It requires the end user to hold down the CTRL button to select multiple options.
Money
A money meta field allows you to specified a monetary value. Clicking on the "Configure" button next to the data type allows you to specify the Currency unit which will be displayed next to the value in the search results. You can also configure whether you want decimals/cents to be displayed and indexed. The meta values on your page should look something like this:
 
<meta name="PRICE" content="9.99">

 
You can customize the appearance of the meta fields via CSS. This includes the way the meta fields are displayed alongside each search result, as well as the search form from which you specify the meta field search criteria. A class listing of the CSS styles can be found in "CSS class listing".