Go to the first, previous, next, last section, table of contents.


Example installed

When Catalog is installed, it builds an example database and copies two catalog configuration profiles. An HTML page gives access to the example and is installed in the same directory as the documentation (HTMLDIR when Catalog is installed). If you've installed the documentation in the HTMLDIR/Catalog/ directory, the URL http://www.mymachine.com/Catalog/ will display the following page:



The admin configuration is stored in a subdirectory of the cgi-bin directory (CGIDIR when Catalog is installed). It customizes the administration interface of the catalogs.

The browse configuration is stored in a subdirectory of the cgi-bin directory. It customizes the user view of the catalogs.

The resources database is a set of URLs, stored in the urldemo table that have the following structure:

create table urldemo (
  #
  # Table management information 
  #
  rowid int auto_increment not null,
  created datetime not null,
  modified timestamp not null,

  info enum ('active', 'inactive') default 'active',
  url char(128),
  comment char(255),

  unique cdemo1 (rowid)
)

The rowid member and the cdemo1 index are mandatory. The url field stores the URL of a WEB site, the comment field stores a comment that shortly explains the purpose of the WEB site, the created field is the date of the insertion of the record in the database.

The URLs found in the urldemo table relate to full text indexing and searching the WEB. Based on this table we have created three catalogs:

`urlcatalog'
is a thematic tree that classifies the resources found in the urldemo table. This catalog defines a small hierarchical tree containing /Directory, Full text/Conferences, Full text/Software and so on. The classification is done by associating each record in the urldemo table to a specific category in the thematic tree. This association is maintained in an administrative table of the urlcatalog and is not contained in the urldemo table.
`urldate'
is a chronological catalog. We have chosen to chronologically order the records of the urldemo table according to their creation date (created field). All what is needed when creating a chronological catalog is to specify which table to use and which field in this table contains the date field to consider. The chronological presentation is inferred from the dates contained in each record.
`urlalpha'
is an alphabetical catalog. We have chosen to alphabetically order the records of the urldemo table according to the content of the comment field. All what is needed when creating a alphabetical catalog is to specify which table to use and which field in this table contains the character field to consider. The alphabetical presentation is inferred from the strings contained in each record.

It must be clearly understood that any number of catalog can be created for a given table (urldemo for instance) with no need to duplicate the data of this table. The catalogs are maintained using administrative tables that are not directly related to the table containing the records classified.

The example database created is named catalog_example and is loaded with three catalogs (urlcatalog, urldate and urlalpha) based on the urldemo table. The database may be dropped if you want to get rid of it at a later time with the following MySQL instruction:

drop database catalog_example;

In short the example is installed in the following files/bases:

`HTMLDIR/Catalog/index.html'
The entry point.
`CGIDIR/admin/'
Catalog administration configuration.
`CGIDIR/browse/'
Catalog user view configuration.
`catalog_example database'
The example database.


Go to the first, previous, next, last section, table of contents.