|
|
|
% layout 'default';
|
|
|
|
% title 'Imgbin -- View';
|
|
|
|
<h1><%= l('View image') %></h1>
|
|
|
|
<div>
|
|
|
|
<div>
|
|
|
|
<%= link_to l('Upload') => "/imgbin", class => 'zerobin upload' %>
|
|
|
|
% if (config->{imgbin}->{show_latest}) {
|
|
|
|
<%= link_to l('Latest images') => "/imgbin/latest", class => 'zerobin latest' %>
|
|
|
|
% }
|
|
|
|
</div>
|
|
|
|
<hr/>
|
|
|
|
<div>
|
|
|
|
% my $image = (stash 'image') || {};
|
|
|
|
% my $style = sprintf "max-width: %dpx;", $config->{imgbin}->{css_maxwidth};
|
|
|
|
<%= link_to $image->{path} => begin %>
|
|
|
|
<%= image $image->{path}, style => $style; %>
|
|
|
|
<% end %>
|
|
|
|
</div>
|
|
|
|
<hr/>
|
|
|
|
<table>
|
|
|
|
<tr><td><%= l('Dimensions') %></td><td>:</td><td><%= "$image->{width}x$image->{height}" %></td></tr>
|
|
|
|
<tr><td><%= l('Size') %></td><td>:</td><td><%= sprintf("%.1f kb", $image->{size} / 1024) %></td></tr>
|
|
|
|
<tr><td><%= l('Name') %></td><td>:</td><td><%= $image->{name} // '-' %></td></tr>
|
|
|
|
<tr><td><%= l('Comment') %></td><td>:</td><td><%= $image->{comment} // '-' %></td></tr>
|
|
|
|
</table>
|
|
|
|
</div>
|