Simple PHP Code To Grab IP 07-09-2013, 07:42 PM
#1
Make a php file named:
anything.php
Containing the following code within:
Now in the same directory make a txt file named:
sinisterly.txt
Just send anyone to the anything.php hyperlink, and the script will automatically grab the person;s IP and will save it in sinisterly.txt
anything.php
Containing the following code within:
Code:
<html>
<?php
$file = "sinisterly.txt";
$f=fopen($file, 'a');
fwrite($f,$_SERVER['REMOTE_ADDR']."\n");
fclose($f);
?>
<p>File not found</p>
</body>
</html>Now in the same directory make a txt file named:
sinisterly.txt
Just send anyone to the anything.php hyperlink, and the script will automatically grab the person;s IP and will save it in sinisterly.txt



![[Image: znALY5V.jpg]](https://i.imgur.com/znALY5V.jpg)
![[+]](https://sinister.li/images/modern/collapse_collapsed.png)


![[Image: BAvhP6h.png]](http://i.imgur.com/BAvhP6h.png)
![[Image: social-views-signature.gif]](http://socialviewz.com/wp-content/uploads/2013/05/social-views-signature.gif)