• Resolved tibewww

    (@tibewww)


    Hi,

    I’m trying to use your plugin for images optimisation and get reach in the google speed test of the alert about image which need to be compress and resize.

    the link of my website is below:

    https://www.firmfitfloor.com

    I have purchase the HQ version.

    In the options of OPtimus, only WebP files optin is ticked.

    I have also install the Cache Enable.

    I then optimise all images. I can see in my wp/content/upload all the image in webp have been created.

    Otherwise on the website, When I am checking the code, I can see only jpg files are being call.

    My Htaccess is as below:

    `
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteCond %{HTTP_ACCEPT} image/webp
    RewriteCond %{DOCUMENT_ROOT}/$1.webp -f
    RewriteRule ^(wp-content/uploads.+)\.(jpe?g|png)$ $1.webp [T=image/webp,E=accept:1]
    </IfModule>

    <IfModule mod_headers.c>
    Header append Vary Accept env=REDIRECT_accept
    </IfModule>

    AddType image/webp .webp

    #<IfModule mod_rewrite.c>
    # RewriteEngine On
    # RewriteCond %{HTTP_ACCEPT} image/webp
    # RewriteCond %{DOCUMENT_ROOT}/$1.webp -f
    # RewriteRule ^(wp-content/uploads.+)\.(jpe?g|png)$ $1.webp [T=image/webp,E=accept:1]
    #</IfModule>

    #<IfModule mod_headers.c>
    # Header append Vary Accept env=REDIRECT_accept
    #</IfModule>

    ## ENABLE GZIP COMPRESSION ##
    AddOutputFilterByType DEFLATE text/plain
    AddOutputFilterByType DEFLATE text/html
    AddOutputFilterByType DEFLATE text/xml
    AddOutputFilterByType DEFLATE text/css
    AddOutputFilterByType DEFLATE application/xml
    AddOutputFilterByType DEFLATE application/xhtml+xml
    AddOutputFilterByType DEFLATE application/rss+xml
    AddOutputFilterByType DEFLATE application/javascript
    AddOutputFilterByType DEFLATE application/x-javascript
    ## ENABLE GZIP COMPRESSION ##

    ## LEVERAGE BROWSER CACHING ##
    <IfModule mod_expires.c>
    ExpiresActive On
    ExpiresByType image/jpg “access 1 year”
    ExpiresByType image/jpeg “access 1 year”
    ExpiresByType image/gif “access 1 year”
    ExpiresByType image/png “access 1 year”
    ExpiresByType text/css “access 1 month”
    ExpiresByType application/pdf “access 1 month”
    ExpiresByType application/x-javascript “access 1 month”
    ExpiresByType application/javascript “access 1 month”
    ExpiresByType application/x-shockwave-flash “access 1 month”
    ExpiresByType image/x-icon “access 1 year”
    ExpiresDefault “access 2 days”
    </IfModule>
    ## LEVERAGE BROWSER CACHING ##

    #FONT LEVERAGE ##

    # Fonts
    # Add correct content-type for fonts
    AddType application/vnd.ms-fontobject .eot
    AddType application/x-font-ttf .ttf
    AddType application/x-font-opentype .otf
    AddType application/x-font-woff .woff
    AddType image/svg+xml .svg

    # Compress compressible fonts
    # only uncomment if you dont have compression turned on already. Otherwise it will cause all other filestypes not to get compressed
    # AddOutputFilterByType DEFLATE application/x-font-ttf application/x-font-opentype image/svg+xml

    ExpiresActive on

    # Add a far future Expires header for fonts
    ExpiresByType application/vnd.ms-fontobject “access plus 1 year”
    ExpiresByType application/x-font-ttf “access plus 1 year”
    ExpiresByType application/x-font-opentype “access plus 1 year”
    ExpiresByType application/x-font-woff “access plus 1 year”
    ExpiresByType image/svg+xml “access plus 1 year”

    ## WEBP SUPPORT ##

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ – [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    RewriteCond %{HTTP_ACCEPT} image/webp
    RewriteCond %{DOCUMENT_ROOT}/$1.webp -f
    RewriteRule ^(wp-content/uploads.+)\.(jpe?g|png)$ $1.webp [T=image/webp,E=accept:1]
    </IfModule>

    <IfModule mod_headers.c>
    Header append Vary Accept env=REDIRECT_accept
    </IfModule>

    # END WordPress

    AddHandler application/x-httpd-php56 .php .php5 .php4 .php3
    AddType image/webp .webp
    AddType image/webp webp

    Which I have follow from your article:

    https://optimus.keycdn.com/support/configuration-to-deliver-webp/

    Aswell this is the answer I had from my hosting:

    Hello Thomas,

    MIME types are enabled on all our servers.

    You even have a MIME type tool in your cPanel. I added the webp type in there for you.

    I also added the code in the article on top of the site .htaccess file.

    And then restarted the Apache just in case.

    Any help will be more than welcome, I need the website to be speed optimise, and to get reach of this behaviour ( asking to compress and resize the images) from google speed test and gtmetrix ??

    Thanks a lot for your time ??

    • This topic was modified 7 years, 7 months ago by tibewww.

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Hi,

    I just checked your site and your images are being delivered with the .webp extension. If you’re using Cache Enabler you don’t need the WebP .htaccess code. That can be removed.

    Be sure that you check your site while logged out in order to get the WebP cached version generated by Cache Enabler.

Viewing 1 replies (of 1 total)
  • The topic ‘WEBP is not being call in HQ Version ?’ is closed to new replies.