Created
August 21, 2011 23:56
-
-
Save dublado/1161361 to your computer and use it in GitHub Desktop.
Creating a 1×1 transparent GIF response in PHP
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//saves ip address and timestamp | |
$str=date("Y-m-d H:i:s") . ": ". $_SERVER['REMOTE_ADDR'] . "n"; | |
file_put_contents("ip_list.txt", $str, FILE_APPEND); | |
Sourced from: | |
header("content-type: image/gif"); | |
//43byte 1x1 transparent pixel gif | |
echo base64_decode("R0lGODlhAQABAIAAAAAAAAAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw=="); | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment