NAME	search.cgi - cgi search server.

SYNTAX	serach.cgi [parametars]

DESCRIPTION

 Search.cgi is cgi search server, which search given words thru database on
local host, generated with url2data(1) robot program.

THIS IS FREE SOFTWARE AND THERE'S NO WARRANTY IF SOMETHIG HAPEND !
USE IT AT YOUR OWN RISK ! Sorry for my bad english...

PARAMETARS

 All are given on url line. Most of it are generated by search.cgi program.
Here are writen only basic and auto generated :

search	Value of this variable are all typed words. Use this name with type of
	text or textarea. E.g.:
	<INPUT TYPE="text" NAME="search" SIZE=40>

type	Value is 0 and 1.
	0 - is default and it used for ignore case search method.
	1 - is for match case search method. E.g.:
	<INPUT TYPE="radio" NAME="type" VALUE=0 CHECKED>IGNORE CASE
	<INPUT TYPE="radio" NAME="type" VALUE=1> MATCH CASE

count	Value of this variable is how many  rezults  you want disply at once.
	E.g.:
	<SELECT NAME="count"><OPTION> 10 </OPTION>
	<OPTION> 20 </OPTION></SELECT>

SecT	Value is line number of sections which are read from search.conf file
	in cgi-bin directory. E.g.:
	<INPUT TYPE="checkbox" NAME="SecT" VALUE=1> Home Pages<BR>
	<INPUT TYPE="checkbox" NAME="SecT" VALUE=2> All Pages<BR>

/Help	Use this if you want see help page, located in HELP.HTML file.

NOTE: In html files are some comments which is used like drop points for
search.cgi. You can modify this html files for own needs, but don't delete this
comments. If you delete it or modify, you can't see rezults or something else.

CONFIG FILES

search.conf
	is config file for search.cgi, there are all data for runing cgi
	search program. Definitions of variables:

HEAD_HTML	Location of head.html file which will be displayed in writing
		searched rezults.

BODY_HTML	Location of body.html file which is displayed as default page,
		if no other request is given to search.cgi.

ERROR_HTML	Location of error.html file which is displayed in case of some
		error.

HELP_HTML	Location of help.html file. This is file for display usage of
		search program. You don't need to edit this file.

HTML_COPYRIGHT	Contents of this variable is displayed on the  bottom of each
		page which generate search program. Here you can type
		information about who maintain search program and database.

REZULT_COLOR	This is color for display modification date and size of url.
		Write here 6 digits hex number of rgb color.

ALL_URLS	This is option for limitation in display rezult pages. Use on
		to diplay all pages. Use off to display only first 200 pages.

REPLACE_URL	Location of replace url file. If none given or comment, program
		don't use replacement for url.
              	In replace file you write in one line url or part of url which
		you want to replace. In next line you write replaced part for
		that url or part.

SECTION		Write here name of section, this name will be writed during
		writing rezults.

LOCATION	This variable must go after SECTION variable, it contains data
		where is database file for that  section.

NOTE: All values of variables must be in one line where is variable (line can
be longer than 80 characters). This file is by default in install directory
where search.cgi is. If you change location of this file, please edit config.h
and write new path for config file. All data for other components like system
html files are writen in config file, so you can't run search server without
config file.

By default all html files writen in config file are set to current directory,
but they are installed to directory where url2data robot program is.

Maximum section is 100. If you have only one section, during writing rezults,
name of that section will not be displayed. You can remove in body.html code
for section and insted type:

<INPUT TYPE="hidden" NAME="SecT" VALUE=1>

Data in search.h file are default values if that values don't exist in
search.conf. Do not edit this file.

config.h
	is main configuration file for search server. For all changes in it
	you must recompile program. Here is in short definition of some
	variables in file:

CONF_FILE	variable for location of configuration file, default is
		directory where search.cgi is.

WORD_LENGHT	this is number of letters in word for search, maximum letters
		per word is 255.

MAX_WORDS	this is maximum words what you can type for search.
		Lenght of each word is defined in WORD_LENGHT variable. You
		don't have limit to number of words, but memory which use is
		calcuated with: MAX_WORDS * WORD_LENGHT * 17 ,rezults are in
		bytes.

BUGS

 Currently none reported, all from v0.1.6 and earlyer are fixed.
There culd be some problems with searching if use some optimization during
compilation ( still checking that report ).

AUTHOR

Silvio Klaic (C) Copyright 1997-2000
E-mail: sklaic@student.math.hr or sklaic@jagor.srce.hr
URL: http://student.math.hr/~sklaic

Rev. 1.2                21 September 2000                       4
