X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;ds=sidebyside;f=perl%2FSesse%2Fpr0n%2FCommon.pm;h=e3b33324bcb8de120b80187cc777360d6deb63c5;hb=1a9cbb3a4dd482391f3a3d9f36d4f8ab3282fe58;hp=0b2fa2488f1df4e7e3e463e015d6db0a13a4663e;hpb=08c2d6184b4ad4c1fbe1e15b8e8563dfd3136f02;p=pr0n diff --git a/perl/Sesse/pr0n/Common.pm b/perl/Sesse/pr0n/Common.pm index 0b2fa24..e3b3332 100644 --- a/perl/Sesse/pr0n/Common.pm +++ b/perl/Sesse/pr0n/Common.pm @@ -134,8 +134,12 @@ sub get_query_string { } sub print_link { - my ($r, $title, $baseurl, $param, $defparam) = @_; - my $str = "$title"; + my ($r, $title, $baseurl, $param, $defparam, $accesskey) = @_; + my $str = "print($str); } @@ -182,10 +186,10 @@ sub update_width_height { # Also find the date taken if appropriate (from the EXIF tag etc.) my $info = Image::ExifTool::ImageInfo(get_disk_location($r, $id)); my $datetime = undef; - + if (defined($info->{'DateTimeOriginal'})) { # Parse the date and time over to ISO format - if ($info->{'DateTimeOriginal'} =~ /^(\d{4}):(\d\d):(\d\d) (\d\d):(\d\d):(\d\d)$/ && $1 > 1990) { + if ($info->{'DateTimeOriginal'} =~ /^(\d{4}):(\d\d):(\d\d) (\d\d):(\d\d):(\d\d)(?:\+\d\d:\d\d)?$/ && $1 > 1990) { $datetime = "$1-$2-$3 $4:$5:$6"; } }