<:
my $img_prev = Prev(This_Image, $opt->{image_loop});
my $img_next = Next(This_Image, $opt->{image_loop});
my $prev_w_or_h = Get($img_prev,'thumb','x') > Get($img_prev,'thumb','y') ? "width=\"50\"" : "height=\"50\"";
my $next_w_or_h = Get($img_next,'thumb','x') > Get($img_next,'thumb','y') ? "width=\"50\"" : "height=\"50\"";
_:>
<:=Get($img_prev,'href','image_page'):>
<:=$prev_w_or_h:> />
<:=Name($img_prev):>
<:=Caption($img_prev):>
<:=Get($img_next,'href','image_page'):>
<:=$next_w_or_h:> />
<:=Name($img_next):>
<:=Caption($img_next):>