ALgoritmus na hledani "podobnych" retezcu

Zdenek Wagner - Ustav chemickych procesu AV wagner at cesnet.cz
Fri Jan 21 14:24:24 CET 2000


On Fri, 21 Jan 2000, Ladislav Dobias wrote:

> On Fri, 21 Jan 2000, Daniel Korcak wrote:
>
> > A to takovy, ktery by byl schopen v realnem case nalezt jestli je jeden
> > retezec podobny druhemu.
>
> Mozna se muzete podivat, jestli neco neni v modulu do Apache
> (web server), ktery se jmenuje mod_spell (nebo tak nejak).
>
> Ten dela to, ze pokud uzivatel napise spatnou www adresu,
> tak mu nabidne nejakou podobnou nebo - ted ani nevim co se
> stane, kdyz se zadny dokument na serveru nehodi :-)
>
Zkopiroval jsem uvod manualu na mod_speling. Chcete-li si precist manualy
na Apache a nemate je zrovna u sebe, muzete se podivat na
http://hroch486.icpf.cas.cz/manual (je tam sice stara verze 1.3.7, ale od
verze 1.3.9 se moc nelisi).

Summary

Requests to documents sometimes cannot be served by the core apache server
because the request was misspelled or
miscapitalized. This module addresses this problem by trying to find a
matching document, even after all other modules
gave up. It does its work by comparing each document name in the requested
directory against the requested document
name without regard to case, and allowing up to one misspelling (character
insertion / omission / transposition or
wrong character). A list is built with all document names which were
matched using this strategy.

If, after scanning the directory,

     no matching document was found, Apache will proceed as usual and
return a "document not found" error.
     only one document is found that "almost" matches the request, then it
is returned in the form of a redirection
     response.
     more than one document with a close match was found, then the list of
the matches is returned to the client, and
     the client can select the correct candidate.



> Zdravi
> Lada Dobias
>
> --
>
> %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
>                                                       ,v
>   ##       ##   #####   #####            Ladislav DOBIAS
>   ##      ####  ##  ## ##O-O##         Xdobiasl at fel.cvut.cz
>   ##     ##  ## ##  ## ## > ##   <http://cs.felk.cvut.cz/~xdobiasl/>
>   ##     ###### ##  ## ## v ##   I study Czech Technical University,
>   ###### ##  ## #####   #####      Faculty of Electrical Engeneering
>
> %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
>
>

Zdenek Wagner
e-mail: wagner at mbox.cesnet.cz  or  wagner at icpf.cas.cz

see also http://www.icpf.cas.cz/wagner/
         http://members.xoom.com/z_wagner/




More information about the csTeX mailing list