aboutsummaryrefslogtreecommitdiffstats
path: root/i.php
diff options
context:
space:
mode:
authorrvelices <rv-github@modusoptimus.com>2012-01-26 21:15:16 +0000
committerrvelices <rv-github@modusoptimus.com>2012-01-26 21:15:16 +0000
commit4a73d939e03ea8d57719f52681dd919dc106ed5f (patch)
tree359d195741c5e2324adac9f06e8d729d02511576 /i.php
parent4f216a5caceb53072c6062a7e7af2a19cc3bb341 (diff)
feature 2548 multisize - small fixes
git-svn-id: http://piwigo.org/svn/trunk@12958 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to '')
-rw-r--r--i.php14
1 files changed, 9 insertions, 5 deletions
diff --git a/i.php b/i.php
index 225c087a0..ea521b90a 100644
--- a/i.php
+++ b/i.php
@@ -73,20 +73,20 @@ function ilog()
if (!mkgetdir($dir) or ! ($ilogfh=fopen($dir.'i.log', 'a')) )
return;
}
- fwrite($ilogfh, date("c") );
+ $line = date("c");
foreach( func_get_args() as $arg)
{
- fwrite($ilogfh, ' ' );
+ $line .= ' ';
if (is_array($arg))
{
- fwrite($ilogfh, implode(' ', $arg) );
+ $line .= implode(' ', $arg);
}
else
{
- fwrite($ilogfh, $arg);
+ $line .= $arg;
}
}
- fwrite($ilogfh, "\n");
+ fwrite($ilogfh, $line."\n");
}
function ierror($msg, $code)
@@ -396,6 +396,10 @@ if (!$changes)
ierror( $page['src_url'], 301);
}
+if ($d_size[0]*$d_size[1] < 100000)
+{// strip metadata for small images
+ $image->strip();
+}
$image->set_compression_quality( $params->quality );
$image->write( $page['derivative_path'] );
$image->destroy();