-


- 2


if

(Pos('#',Str) <> 1) and

(Pos('http://',Str) <> 1) and

(Pos('mailto:',Str) <> 1) and

(Pos('news:',Str) <> 1) and

(Pos('ftp://',Str) <> 1) and

(Pos('.exe?',Str) = 0) then { skip external links & exe }

begin

if

Pos('file:///',Str) = 1 then

Delete(Str,1,8);

if

(Pos('#',Str) 0) and

(Pos('#',Str) < Pos('"',Str)) then Str[Pos('#',Str)] := '"';

if

not

FileExists(Copy(Str,1,Pos('"',Str)-1)) then

writeln(Path,'\',SRec.Name,': [',Copy(Str,1,Pos('"',Str)-1),']')

end

end

end;

Close(f);

if

IOResult <> 0 then { skip }

until

FindNext(SRec) <> 0;

FindClose(SRec);

// check sub-directories recursively

if

FindFirst('*.*', faDirectory, SRec) = 0 then

repeat

if

((SRec.Attr AND faDirectory) = faDirectory) and

(SRec.Name[1] <> '.') then

begin

ChDir(SRec.Name);

CheckHTML(Path+'\'+SRec.Name);

ChDir('..')

end

until

FindNext(SRec) <> 0;

FindClose(SRec)

end

{CheckHTML};

 

begin

writeln('HTMLinks 4.0 (c) 1997-2000 by Bob Swart (aka Dr.Bob - www.drbob42.com)');

writeln;

FileMode := $40;

GetDir(0,Path);

CheckHTML(Path)

end.