function SubString(html,Cstr_L,Cstr_R:string):string;
var
sPosB,sPosE:integer;
Lwhtml,LwCstr_L,LwCstr_R:string;
begin
Result:='';
if trim(html)='' then exit;
Lwhtml:=LowerCase(html);
LwCstr_L :=LowerCase(Cstr_L);
LwCstr_R :=LowerCase(Cstr_R);
sPosB:=Pos(LwCstr_L,Lwhtml)+Length(LwCstr_L);
sPosE:=PosEx(LwCstr_R,Lwhtml,sPosB);
if (sPosB0) then
Result:=copy(html,sPosB,sPosE-sPosB);
end;