[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

[MacPerl] Loose search criteria



I am looking for a way to allow loose search criteria in perl.

Here are two examples of what I am trying to do:

1 - I have a text database that is converted to HTML. My script
automatically convert the input search string from ISO-Latin to HTML (with
a little help from my friend Entities.pm :-), so if I input the word
'Stˇphane' the script searches for 'Stéphane' in the database.

Let's say I am now looking for the word 'Stephane' (without the acute
accent) how can I have the script match 'Stéphane'? (I want to keep
the database in HTML format for other functionalities).

2 - This DB also contains city names that are separated by hyphens, as in
'Saint-Alexandre-des-Lacs '. Right now the input 'Saint-Alexandre' will
match 'Saint-Alexandre-des-Lacs ', but 'Saint Alexandre' (no hyphen) won't.
Is there a way to allow this?

I have seen search engines that offer different levels of precision or that
are relatively forgiving to misspellings. I am looking for a way to
implement this in my script.

Any pointers to examples, librairies, modules will be helpful.

TIA,

Stˇphane


        	___S__t__ˇ__p__h__a__n__e_____J__o__s__e___

		        mailto:jose.stephane@uqam.ca
	            http://www.er.uqam.ca/nobel/m206474/


                - Hiroshima 45, Tchernobyl 86, Windows 95 -