* @see print_r
*/
function dbg($val){
print '';
print_r($val);
print '';
}
/**
* Creates a directory hierachy.
*
* @link http://www.php.net/manual/en/function.mkdir.php
* @author
* @author Andreas Gohr
*/
function mkdir_p($target){
if (@is_dir($target)||empty($target)) return 1; // best case check first
if (@file_exists($target) && !is_dir($target)) return 0;
//recursion
if (mkdir_p(substr($target,0,strrpos($target,'/')))){
$ret = @mkdir($target); // crawl back up & create dir tree
return $ret;
}
return 0;
}
function hsc($string){
return htmlspecialchars($string);
}
function clp($path){
return str_replace('//','/',$path);
}
/*
* Yes, hacking this function will work, but please consider paying for the
* noadcode instead
*/
function adv($s='big'){
$conf = core_object('Conf');
if($conf->get('noadhash') == 'ddaffd539e8b6055df398b73329d86e7') return;
if($s == 'small'){
$w = 234; $h = 60;
}else{
$w = 250; $h = 250;
}
?>
* @link http://www.php.net/manual/en/function.utf8-encode.php
*/
function utf8_check($Str) {
for ($i=0; $i