Viewing 4 replies - 1 through 4 (of 4 total)
  • That is not normal. WebP will still work whether pre-compression is enabled or disabled. Depending upon your server, you might need to disable pre-compression if it isn’t working.

    A few quick questions:

    1. Do you have the advanced snippet in place?
    2. Are your images converted to WebP by the Optimus plugin or by another tool? Cache Enabler only supports WebP converted by Optimus or EWWW.

    3. If you have converted images already, have you tried browsing to one of them to verify they exist? For example, copy a URL of one of your PNGs or JPGs and replace with WebP on the end to see if it exists on server.

    Thanks

    Plugin Author KeyCDN

    (@keycdn)

    The pre-compression is not directly related to the webp integration.

    Check this dir if there are different cached version /wp-content/cache/cache-enabler/www.example.com/

    E.g.

    index.html
    index.html.gz
    index-webp.html
    index-webp.html.gz

    Thread Starter jarylw

    (@jarylw)

    @brian Jackson

    1.Advanced snippet? Do you mean the htaccess file? Yes I do.

    2. Another Tool. EWWW.

    3. Yes they exist.

    @keycdn

    When precompression is enabled, I do get served the webp (index-webp.html) – verified by looking what is printed at the bottom by viewing source.

    However, when precompression is disabled, the index-webp.html still gets created since I had checked that option in the cache settings in wordpress admin, but viewing source, checking what was printed and the html code, it is not serving me the webp cached file.

    Thread Starter jarylw

    (@jarylw)

    Edited the htaccess as below and made the changes. The code snippet keycdn provided didnt take into consideration webp for non gzipped pages. Works now/

    # RewriteCond %{HTTP:Accept-Encoding} gzip
    RewriteCond %{HTTP:Accept} image/webp
    # RewriteCond %{DOCUMENT_ROOT}/wp-content/cache/cache-enabler/%{HTTP_HOST}%{REQUEST_URI}index-webp.html.gz -f
    # RewriteRule ^(.*) /wp-content/cache/cache-enabler/%{HTTP_HOST}%{REQUEST_URI}index-webp.html.gz [L]
    RewriteCond %{DOCUMENT_ROOT}/wp-content/cache/cache-enabler/%{HTTP_HOST}%{REQUEST_URI}index-webp.html -f
    RewriteRule ^(.*) /wp-content/cache/cache-enabler/%{HTTP_HOST}%{REQUEST_URI}index-webp.html [L]

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Unable to serve webp’ is closed to new replies.