Refactoring of code base - modularized code, introduced configuration, started working on a PDO based DB connector

This commit is contained in:
Simon Rupf 2012-04-29 19:15:06 +02:00
parent 241c75a5d5
commit ba90d0cae2
10 changed files with 1170 additions and 388 deletions

34
lib/filter.php Normal file
View file

@ -0,0 +1,34 @@
<?php
/**
* ZeroBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.15
*/
/**
* filter
*
* Provides data filtering functions.
*/
class filter
{
/**
* strips slashes deeply
*
* @access public
* @static
* @param mixed $value
* @return mixed
*/
public static function stripslashes_deep($value)
{
return is_array($value) ?
array_map('filter::stripslashes_deep', $value) :
stripslashes($value);
}
}