Hi, thank you so much for this library.
Your library used to remove exif datas before. but anymore it does not remove. Google page speed tool always warn me about it. I am using v10.37 and my code is below. Can you tell me that I am making a mistake or not please?
Quote
#!/usr/bin/perl
my $rc = eval
{
require Image::ExifTool;
Image::ExifTool->import();
1;
};
if($rc){
my $exifTool = new Image::ExifTool;
$exifTool->SetNewValue('*');
$exifTool->WriteInfo("{path}");
$errorMessage = $exifTool->GetValue('Error');
$warningMessage = $exifTool->GetValue('Warning');
if(length($errorMessage)){
printf "%s", $errorMessage;
}else{
if(length($warningMessage)){
printf "%s", $warningMessage;
}else{
printf "SUCCESS";
}
}
}else{
printf "Image::ExifTool does not exist";
}
Your script works for me as long as I set {path} correctly. Could you be more specific about what happens? .
- Phil
Yes, it works but google page speed tools and gtmetrix warn me about it.
https://developers.google.com/speed/pagespeed/insights/?url=http%3A%2F%2Fberkatan.com%2Fxxxx&tab=desktop
https://gtmetrix.com/reports/berkatan.com/dIeHNmIv
what should I do?
I had a look at the reports you mentioned, the complaint is NOT about exif data at all, it is about the compression of the images. This is something you can not change with exiftool (it never touches the image data).
I have added the following command and the problem has been fixed.
system("optipng {path}");
Quote from: bigunde on December 31, 2016, 06:47:24 AM
I have added the following command and the problem has been fixed.
system("optipng {path}");
Nice! You made have a look at optipng and I might want to start using it myself :)