Login   Register  
PHP Classes
elePHPant
Icontem

Anti-Harvest Download: Serve files for download preventing harvesting

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Info   View files View files (2)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Last Updated Ratings Unique User Downloads Download Rankings  
2011-01-01 (3 years ago) RSS 2.0 feedNot yet rated by the usersTotal: 397 All time: 5,921 This week: 1,397Up
Version License PHP version Categories  
antiharvest-download 1.0BSD License5.0HTTP, PHP 5, Files and Folders
Description Author  

This class can be used to serve files for download preventing harvesting.

It can look a request variable for the name of the file being requested and then performs several checks.

Currently it cleans the file name from dangerous characters by taking the file base name and then it checks if the requested file exists under a given download directory, checks if the file has an accepted file name extension, check if the user browser is not a known robot, and checks if the user address host name is not in a list of known crawler addresses.

The class serves the file for download if all conditions are satisfied.

Picture of Nico den Boer
Name: Nico den Boer <contact>
Classes: 2 packages by
Country: Czech Republic Czech Republic
Age: 47
All time rank: 209924 in Czech Republic Czech Republic
Week rank: 1909 Up21 in Czech Republic Czech Republic Up

  Files folder image Files  
File Role Description
Accessible without login Plain text file class.protector.inc.php Class class file
Accessible without login Plain text file index.php Example Usage example

 Version Control Unique User Downloads Download Rankings  
 0%Total:397All time:5,921
 This week:0This week:1,397Up