Login   Register  
PHP Classes
elePHPant
Icontem

FileDB: Stores (binary) files in a database

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 (6)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Last Updated Ratings Unique User Downloads Download Rankings  
2003-07-22 (11 years ago) RSS 2.0 feedStarStarStarStar 65%Total: 2,969 This week: 2All time: 1,141 This week: 874Up
Version License Categories  
filedb 1.0GNU Lesser General Publ...Databases, Files and Folders
Description Author  

With this class you can easily store, display and send files from a db.
It has a built-in hit counter and stores information of last edition, upload, etc..


This class uses my db abstraction layer, AbstractDB
(http://www.phpclasses.org/browse.html/package/846.html) , which allows a unified and easy access to databases, which you can see in this class.


CONSTRUCTOR:
function FileDB(&$db, $host, $database, $user, $password)

FUNCTIONS:
function add($file_name, $file_descr = '')
function remove($id)
function get($id, $addHit = true)
function getWhere($from, $where = '', $addHit = true)
function getFile($id, $addHit = true)
function getFileData($id)
function getIds()
function sendFile($id)

function _getFileContent($file_name)

PUBLIC VARS:
var $file_count

Picture of L
Name: L <contact>
Classes: 13 packages by
Country: Germany Germany
Age: 40
All time rank: 486 in Germany Germany
Week rank: 315 Down11 in Germany Germany Down

  Files folder image Files  
File Role Description
Accessible without login HTML file FileDB.html Doc. php doc
Plain text file FileDB.php Class main class
Plain text file files.sql Conf. sql definition
Accessible without login Plain text file showFile.php Appl. example
Accessible without login Plain text file testFileDB.php Example example
Accessible without login Plain text file testFileDB2.php Example example using Uploader.php

 Version Control Unique User Downloads Download Rankings  
 0%Total:2,969All time:1,141
 This week:2This week:874Up
 User Ratings  
 
 All time
Utility:81%StarStarStarStarStar
Consistency:93%StarStarStarStarStar
Documentation:75%StarStarStarStar
Examples:75%StarStarStarStar
Tests:-
Videos:-
Overall:65%StarStarStarStar
Rank:483