// Used album.html.php as starting point.
// The g-info block was taken from album.html.php and $theme->album_top() was changed to $theme->dynamic_top().
// $item->title and $item->description have been changed to $title and $description.
//
// The g-album-grid block was also taken from album.html.php. The section for uploading new photos to an empty album
// has been removed. Also, $theme->context_menu has been removed as well (it was crashing the page).
?>
= $theme->add_paginator("top"); ?>
if (($theme->album_descmode == "top") and ($description)): ?>
has_thumb()):
$is_portrait = ($thumb_item->thumb_height > $thumb_item->thumb_width);
$_shift = "";
switch ($theme->thumb_imgalign):
case "center":
if (($theme->crop_factor == 1) and (!$is_portrait)):
$_shift = 'style="margin-top: ' . intval(($theme->_thumb_size_y - $thumb_item->thumb_height) / 2) . 'px;"';
elseif ($theme->crop_factor > 0):
$_shift = 'style="margin-top: -' . intval(($thumb_item->thumb_height - $theme->_thumb_size_y) / 2) . 'px;"';
endif;
break;
case "bottom":
if (($theme->crop_factor == 1) and (!$is_portrait)):
$_shift = 'style="margin-top: ' . intval($theme->_thumb_size_y - $thumb_item->thumb_height) . 'px;"';
elseif ($theme->crop_factor > 0):
$_shift = 'style="margin-top: -' . intval($thumb_item->thumb_height - $theme->_thumb_size_y) . 'px;"';
endif;
break;
case "fit":
break;
case "top":
default:
break;
endswitch;
else:
$is_portrait = FALSE;
$_shift = 'style="margin-top: 0px;"';
endif;
$content .= ($is_portrait)? " g-portrait" : " g-landscape";
$content .= '">' . $theme->thumb_top($child);
$content .= '';
$content .= $theme->thumb_bottom($child);
$content .= '';
return $content;
//print $content;
// End of modified function code.
}
?>