Authored by whb

merge

... ... @@ -151,16 +151,8 @@ EOL;
}
foreach($banners as $banner):
$res_size = json_decode($banner['res_size'], true);
if($res_size['height'] < 308 && $res_size['width']< 308)
{
$height = $res_size['height'];
$width = $res_size['width'];
}
else
{
$height = ceil($res_size['height'] * (308 / $res_size['width']));
$width = 308;
}
$height = ceil($res_size['height'] * (308 / $res_size['width']));
$width = 308;
?>
<div class="image-box" style="padding-bottom: 30px;">
<a href="<?php echo $banner['url']?>" target="_blank" style="<?php echo sprintf("height:%spx;width:%spx;overflow:hidden;", $height, $width);?>">
... ...