I'm trying to compress the image on moodle server, so far:
- I have tried to use optipng and jpegoptim in the server (elearning filedir/) (Linux Centos server)
- of course the hash value is changed, so i rename the file to the new hash value
- and repositioned the location according to the first 2digithash/second2digithash/
- change the value of field "content hash" in database table "mdl3w_files"
I though I had succesfully compress the image. The compressed image did show up briefly (example in quiz preview) , but few moments later it does not (after the page loads completely).
think there is a script that check another hash value that runs in the end of the page load.
so the question is :
- does anybody knew any image / pdf compressor script /app that can compress image /pdf already saved in the moodle server?
- OR, any step that I missed above? perhaps another table that being used to crosscheck hash?
- OR plugin to compress image as the user uploads it in moodle? (i only find the ones that resize it as the user retrieve the image in browser)
thanks ini advance.