FindinSite-MS: Search engine for an ASP.NET website   .
Powered by FindinSite-MS
. Home | Installation | Indexing | Control Panel | Web services | Advanced | Purchasing .
. .
  Web.Config options | Look and Feel | Languages | Word highlighting | Runtime parameters | Rules | Subsets | Meta-data fields


findinsite-ms field searches

Information about a file (or parts of a file) is called meta-data.  For example, the HTML TITLE tag defines meta-data for a web page - a "title" field.  Similarly, this HTML can be used to define an "author" field for a page:
<META NAME=author CONTENT="Chris Cant">
findinsite-ms indexes this information, so it will be found by an ordinary search. 

To exclude one or more fields from the search database, specify the field names in a comma-separated list in the FieldsToExclude advanced indexing run option. Here is a typical set of field names that are stored: title, description, keywords, author, comments, lang, img, url. A document subject is stored as the "description" field. The whole URL or path is stored as the "url" field.

You can also set up field search forms so that users can only search the required fields, eg search for author "Cant".

Field search

The standard findinsite-ms form can be extended to search specific fields, as shown by the following example.

Fields must be specified by form elements whose names start with fld_.  For example, a search of the "author" field should be specified by an INPUT element named fld_Author. The letter case of the element name does not matter. Other form element tags can be used, eg BUTTON, SELECT/OPTION and TEXTAREA.

findinsite-ms will report an error if a field does not exist in the search database.

<FORM method='get' action="/findinsite/search.aspx">
Search for:	<INPUT NAME="Text" TYPE="text" SIZE=30 MAXLENGTH=80><BR>
Keywords:		<INPUT NAME='fld_Keywords' TYPE=text SIZE=30 MAXLENGTH=80><BR>
Language:		<SELECT NAME="fld_lang" MULTIPLE SIZE="3" ALIGN=top>
		<OPTION VALUE="en">English
		<OPTION VALUE="zh">Chinese
		<OPTION VALUE="zh TW">Chinese Traditional
		<OPTION VALUE="de">German
		<OPTION VALUE="ja">Japanese

Try an online version of this form, searching the phdcc site:

Search for:

The search terms are shown in the top and bottom template using the %SEARCH_TEXT% and %FIELDS_TEXT% template variables. Examples:

User input Displayed output Template variable
red red %SEARCH_TEXT%
Keywords field: search
Language field: English and Chinese
[keywords:search] [lang:en zh] %FIELDS_TEXT%
  All site Copyright © 1996-2014 PHD Computer Consultants Ltd, PHDCC   Privacy  

Last modified: 4 July 2008