Copy file to new location using PhP

Associate
Joined
18 Oct 2002
Posts
710
Location
Somerset
I am using a couple of programs to record and process game stats for UT2004 which results in a database that outputs to a web page (basically a copy of the epic stats logging)

Both programs are PhP

the problem i have is that one program takes the games log files and transfers the data to the database of the other program, after this is done i am left with no log files.

I really want to keep a copy of each log file so i can restore the dtabase if needed.

Is there any way in Php to copy a file to another location?

I am looking for something i can add to the start of the PhP file that carrys out the log parseing.

I have no idea if this is possible, would be greatful for any help

Thanks
Keith
 
Thanks i will take a look at that, i think the main problem is going to be that the log files will not have the same name each time they are created,
I will go and do some digging.
 
I am using a couple of programs to record and process game stats for UT2004 which results in a database that outputs to a web page (basically a copy of the epic stats logging)

Both programs are PhP

the problem i have is that one program takes the games log files and transfers the data to the database of the other program, after this is done i am left with no log files.

I really want to keep a copy of each log file so i can restore the dtabase if needed.

Is there any way in Php to copy a file to another location?

I am looking for something i can add to the start of the PhP file that carrys out the log parseing.

I have no idea if this is possible, would be greatful for any help

Thanks
Keith

Can you not alter the application so that it doesn't delete the logs?
 
Back
Top Bottom