السلام عليكم
بسبب صداع في راسي اكتب هذا...
نحن اليوم بتاريخ 6 6 6 !
اليوم السادس من الشهر السادس من السنة السادسة بعد الألفين حسب التقويم الغربي
بدون ثرثرة، الكود و البريمج مرفق
program sHTML;
{$APPTYPE CONSOLE}
uses
sysutils;
var
Bt: Byte;
Pff: String;
Huh: TextFile;
F: File of Byte;
begin
WriteLn;
WriteLn('sHTML - simple HTML encoder.');
WriteLn;
if paramcount=0 then Begin
WriteLn('sHTML FILE.HTML');
WriteLn('Or Drag & Drop an HTML file on me!');
Writeln(#10#13'Press ENTER');
Readln;
Halt(1);
End;
Pff := 'index.htm';
if paramcount<>0 then Pff:=Paramstr(1);
Write('Opening :'+Pff);
AssignFile(F, Pff);
Reset(F);
WriteLn(' OK.');
AssignFile(Huh, Pff+'.HTM');
ReWrite(Huh);
WriteLn(Huh,'<!--This HTML page was tampeted by sHTML--!>');
Write(Huh,'<script LANGUAGE=JAVASCRIPT>document.write(unescape("');
Write('eNcoding: ');
Repeat
Read(f,bt);
Write(Huh,'\x'+inttoHex(bt,2));
Until Eof(F);
WriteLn(' OK.');
WriteLn(Huh, '"));</SCRIPT>');
CloseFile(Huh);
CloseFile(F);
WriteLn(#10#13+'Press ENTER');
Readln;
end.