Exit;
if (e.className = 'date') or (e.id = 'date') then begin
- AID := e.innerText;
- if AnsiPos('id', AnsiLowerCase(AID)) > 0 then begin
- AID := Copy(AID, AnsiPos('id', AnsiLowerCase(AID)) - 1, 11);
- if AnsiPos(' be:', AnsiLowerCase(AID)) > 0 then begin
- AID := Copy(AID, 1, AnsiPos(' BE:', AnsiLowerCase(AID)) - 1)
- end;
- end else begin
- stlist := TStringList.Create;
- try
- stList.DelimitedText := AID;
- AID := '';
- for i := 0 to stList.Count - 1 do begin
- if Length(WideString(stList[i])) = 8 then begin
- if GikoSys.NotDateorTimeString(stList[i]) then begin
- AID := stList[i];
- break;
- end;
- end;
- end;
- finally
- stList.Free;
- end;
- end;
+ AID := GikoSys.ExtructResID(e.innerText);
ShowSameIDAncher(AID);
end;
except
procedure GetSameIDRes(const AID : string; ThreadItem: TThreadItem;var body: TStringList); overload;
procedure GetSameIDRes(AIDNum : Integer; ThreadItem: TThreadItem;var body: TStringList); overload;
function GetResID(AIDNum: Integer; ThreadItem: TThreadItem): String;
+ function ExtructResID(ADateStr: String): String;
//! \92P\8cê\89ð\90Í
procedure SpamCountWord( const text : string; wordCount : TWordCount );
//! \8aw\8fK\83N\83\8a\83A
procedure SpamLearn( wordCount : TWordCount; isSpam : Boolean );
//! \83X\83p\83\80\93x\90\94
function SpamParse( const text : string; wordCount : TWordCount ) : Extended;
- //\88ø\90\94\82ª\81A\93ú\95t\82Å\82à\8e\9e\8d\8f\82Å\82à\82È\82¢\82±\82Æ\82ð\92²\82×\82é
- function NotDateorTimeString(const AStr : string): boolean;
//! \88ø\90\94\82É\91\97\82ç\82ê\82Ä\82«\82½\93ú\95t/ID\95\94\82ÉBE\82Ì\95¶\8e\9a\97ñ\82ª\82 \82Á\82½\82ç\81A\83v\83\8d\83t\83@\83C\83\8b\82Ö\82Ì\83\8a\83\93\83N\82ð\92Ç\89Á
function AddBeProfileLink(AID : string; ANum: Integer): string;
var
Res: TResRec;
boardPlugIn : TBoardPlugIn;
- stList: TStringList;
- i : Integer;
begin
Result := '';
if (ThreadItem <> nil) and (ThreadItem.IsLogFile)
end else begin
THTMLCreate.DivideStrLine( ReadThreadFile(ThreadItem.GetThreadFileName, AIDNum), @Res);
end;
- Result := Res.FDateTime;
- if AnsiPos('id', AnsiLowerCase(Result)) > 0 then begin
- Result := Copy(Result, AnsiPos('id', AnsiLowerCase(Result)) - 1, 11);
- if AnsiPos(' be:', AnsiLowerCase(Result)) > 0 then begin
- Result := Copy(Result, 1, AnsiPos(' BE:', AnsiLowerCase(Result)) - 1)
- end;
- end else begin
- stlist := TStringList.Create;
- try
- stList.DelimitedText := Result;
- Result := '';
- for i := 0 to stList.Count - 1 do
- if Length(WideString(stList[i])) = 8 then begin
- if NotDateorTimeString(stList[i]) then begin
- Result := stList[i];
- break;
- end;
- end;
- finally
- stList.Free;
- end;
- end;
+ Result := ExtructResID(Res.FDateTime);
end;
end;
-
{!
-\brief \8e\9e\8d\8f\82ð\8e¦\82·\95¶\8e\9a\97ñ\82Å\82Í\96³\82¢\82©\82Ç\82¤\82©
-\param AStr \92²\82×\82é\95¶\8e\9a\97ñ
-\return \8e\9e\8d\8f\82Å\82Í\96³\82¢\82È\82ç True
-\todo \94Û\92è\8c`(Not)\82æ\82è\8dm\92è\8cn(Is)
+\brief \83\8c\83X\82Ì\8e\9e\8d\8f\95\94\82©\82çID\82ð\92\8a\8fo\82·\82é
+\param ADateStr \8e\9e\8d\8f\95\94\82Ì\95¶\8e\9a\97ñ
+\return ID(ID\82Æ\82Ý\82È\82¹\82é\95\94\95ª\82ª\82È\82¢\82Æ\82«\82Í\8bó\95¶\8e\9a\97ñ)
}
-function TGikoSys.NotDateorTimeString(const AStr : string): boolean;
+function TGikoSys.ExtructResID(ADateStr: String): String;
+var
+ stlist : TStringList;
begin
- Result := false;
- try
- StrToDate(AStr);
- except
- try
- StrToTime(AStr);
- Result := false;
- except
- Result := true;
- end;
- end;
-
+ Result := '';
+ if AnsiPos('id', AnsiLowerCase(ADateStr)) > 0 then begin
+ Result := Copy(ADateStr, AnsiPos('id', AnsiLowerCase(ADateStr)), Length(ADateStr));
+ if AnsiPos(' ', Result) > 0 then begin
+ Result := Copy(Result, 1, AnsiPos(' ', Result) - 1);
+ end;
+ Result := ' ' + Result;
+ end else begin
+ stlist := TStringList.Create;
+ try
+ stList.Delimiter := ' ';
+ stList.DelimitedText := ADateStr;
+ // \93ú\95t \8e\9e\8d\8f ID \91¼\81@\82Æ\8cÅ\92è\82Å\8dl\82¦\82é
+ if (stList.Count >= 3) then begin
+ if Length(stList[3 - 1]) >= 7 then begin
+ Result := stList[3 - 1];
+ end;
+ end;
+ finally
+ stList.Free;
+ end;
+ end;
end;
{!