'',
'hover'=>'',
'link'=>''
);
$img = array_key_exists('img', $attr) ? $attr['img'] : false;
$alt = array_key_exists('hover', $attr) ? $attr['hover'] : false;
$url = array_key_exists('link', $attr) ? $attr['link'] : false;
echo $img."sss"."
";
var_dump($a);
if($img /*&& is_file($img)*/) {
$a['img'] = $img;
} else {
$a['img'] = $f3->get('RESOURCES')."img/default.png";
}
if($alt && is_file($alt)) {
$a['hover'] = $alt;
} else {
$a['hover'] = $a['img'];
}
if($url) {
$a['link'] = $url;
} else {
$a['link'] = '/';
}
//var_dump($a);
//var_dump($args);
//$out = sprintf("%s
",);
return self::hover_pic_with_link($a['img'],$a['hover'],$a['link']);
}
static function hover_pic_with_link($pic1,$pic2,$link) {
return sprintf('',$link,$pic1,$pic2);
}
static function makeImageLink($url,$href=false) {
if($href) {
return sprintf("",$href, $url);
}
return sprintf("", $url);
}
}