if aecrire;
// enlever l', s' , d' , j' et n'
for d = 1 to %len(%trimr(mot))-1;
if %subst(mot : d : 2) = 'l'''
or %subst(mot : d : 2) = 's'''
or %subst(mot : d : 2) = 'd''' or %subst(mot : d : 2) = 'j'''
or %subst(mot : d : 2) = 'n''' ;
%subst(mot : d : 2) = ' ';
ENDIF;
// HTML : recherche et remplacement de é par é, etc...
if %subst(mot : d : 1) = '&';
f = %scan(';':mot:d);
if f>0;
caridx = %lookup(%subst(mot:d:(f-d)+1):carspc);
if caridx >0;
mot = %replace(car(caridx):mot:d:(f-d)+1);
ENDIF;
ENDIF;
ENDIF;
ENDFOR;
// enlever certains caractères spéciaux, remplacés par espace
mot = %xlate('["-;,.]+>!?&' : ' ' : mot) ;
// derniers tests (lg > 2 et peu d'autres caractères spéciaux) if %len(%trimr(mot)) > 2;
// dans la base en minuscules sans accent ;
mot = %xlate('àâéèêë{}ÈÉÊîÎïöôÔ' : 'aaeeeeeeeeeiiiooo' : mot); mot = %xlate('ABCDEFGHIJKLMNOPQRSTUVWXYZ' : 'abcdefghijklmnopqrstuvwxyz' : mot); // écriture dans la base; if isAlphaNum(mot); // on note la position du mot dans le fichier afin de proposer des recherches
// de type "SMTP" près de "POP3"
Nbm += 1; mot = %triml(mot); chemin = curfile; position = nbm; write af4motf1; ENDIF; endif; endif;
mot = *blanks;
//------------------------
/END-FREE
CSR endsr
/DEFINE ERRNO_LOAD_PROCEDURE
/COPY IFSEBOOK/QRPGLESRC,ERRNO_H
|