PHP code
echo filesize("a.jpg")."<br/>";
imagejpeg(imagecreatefromjpeg("a.jpg"), "a.jpg", 50);
echo filesize("a.jpg");
Output
73104
73104
I have change quality of image but filesize not changed!!!
However, the file size changed?!

why function filesize not updated immediate after change file?
My image(size 72k)

As the manual puts it:
Note: The results of this function are cached. See
clearstatcache()for more details.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With