D
D
doriulbool2016-01-17 20:28:43
PHP
doriulbool, 2016-01-17 20:28:43

Why doesn't image compression work?

I welcome everyone.
Updated php to 5.4, installed GD. I downloaded files from adaptive-images.com , uploaded them, created a folder for the cache, inserted the code into html and the images themselves are not compressed. How to check at what stage the error is, maybe GD is not working? The installation instructions couldn't be easier, but I can't understand why it doesn't work...
Note: everything is in one place, index.html, php file, image, folder, etc...

Answer the question

In order to leave comments, you need to log in

2 answer(s)
Y
Yuri, 2016-01-23
@riky

insert at the beginning of the script at least

ini_set("display_errors", 1);
error_reporting(E_ALL);

see errors

D
doriulbool, 2016-02-01
@doriulbool

In short ... I have nginx handling static, so I just have to figure out why inserting this:
location assets {
}
location ai-cache {
}
location / {
rewrite \.(?:jpe?g|gif|png)$ /adaptive -images.php
}
doesn't work....
Pictures don't open, they become 12 kilobyte miracle, they are sent to php file and of course the result is zero

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question