Page 1 of 1

Refresh the pgae!

Posted: Wed Jan 29, 2003 6:56 pm
by Nik
Pls go to http://www.nikolas.tk and download logreader.exe by clicking the button!

My question is that can the above program be written in php and work as exe is working. Can this be done to the browsers output?

Posted: Thu Jan 30, 2003 1:37 am
by evilcoder
hey Nik, you'll find that 0% of people on these forums are going to download an exe file and open it on either their PC or Server.

Sorry, but there is too much malicous stuff on the net nowadays, we must be careful.

Posted: Thu Jan 30, 2003 2:24 am
by twigletmac
Maybe if you send us to a web page with some screen shots and give a good description of what the program does we'll be able to help better.

Mac

Posted: Thu Jan 30, 2003 3:44 am
by Nik
Well ok guys! u r right! that .exe would be anything! so iam giving u the c++ source from logreader.exe

#include <conio.h>
#include <iostream.h>

int main()
{
int i,flag=0;
char x,y,c,letter;
char *log;
char *arxeio="c:\\progra~1\\mirc\\logs\\";
FILE *stream;

cout << "Dose to log pou theleis na diavaseis => ";
cin >> log;

strcat(arxeio, log);

if(!(stream = fopen(arxeio, "r")))
{
textcolor(LIGHTCYAN);
cprintf("To %s den vrethike! Doste to log se morfi filename.log!", arxeio);
cout << '\7';
getch();
exit(0);
}

clrscr();

while(!feof(stream) && !(c==27))
{
textcolor(WHITE);
for (i=0; i<30000000; i++);

if (y=='\n')
{
cprintf("\r\n\r\n");
y='\t';
}

if (x!='\n') cprintf("%c", x);
else cprintf("\r\n");

while ((x=fgetc(stream))=='<')
{
x=fgetc(stream);
cprintf("\r\n");
if (flag++==0) letter=x;

if (x==letter)
{
textcolor(LIGHTGREEN);
cprintf("%c", '<');
cprintf("%c", x);
while ((y=x=fgetc(stream))!='\n')
{
cprintf("%c", x);
for (i=0; i<30000000; i++);
if (kbhit())
if (getch()==27)
{
cout << "\7\r\n\r\n ********** DIAKOPH KATOPIN AITHSEWS XRHSTH **********";
getch();
cout << "\7\r\n\r\n !!! Made by Skias !!!";
getch();
exit(0);
}
else getch();
}
}
else
{
textcolor(YELLOW);
cprintf("%c", '<');
cprintf("%c", x);
while ((y=x=fgetc(stream))!='\n')
{
cprintf("%c", x);
for (i=0; i<30000000; i++);
if (kbhit())
if (getch()==27)
{
cout << "\7\r\n\r\n ********** DIAKOPH KATOPIN AITHSEWS XRHSTH **********";
getch();
cout << "\7\r\n\r\n !!! Made by Skias !!!";
getch();
exit(0);
}
else getch();
}
}
}
}

if (feof(stream)) cout << "\7\r\n\r\n********** TELOS TOY LOG **********";

getch();
cout << "\7\r\n\r\n!!! Made by Skias !!!";
getch();
}

And my question is:
Can it be done with php script?
Now u can run it of course! :)

Posted: Thu Jan 30, 2003 8:54 am
by Kriek
I thought I answered all your questions on PHP Builder the other day.

Posted: Thu Jan 30, 2003 9:05 am
by Nik
well actually no, because i never asked this question before, so pls do!