Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Frank Goossens

    (@futtta)

    interesting …

    as it stands, autoptimize doesn’t touch svg-files. as such, so there’s no optimized .svg in cache/autoptimize and thus the expiry in cache/autoptimize/.htaccess cannot apply.

    but when looking at the svg-file, it could use some optimization (which might be pretty similar to stock html-minification). so I’ll do some tests and see if I can minify individual svg-files and if so those would be in cache/autoptimize and hence they would automagically have better expiration. maybe … ??

    frank

    Thread Starter SVTX

    (@12ax7)

    Automagically? lol, Love it!

    It seems you know exactly what you’re talking about, to me this is all reverse Chinese so I’m afraid I wont be helpful at all. (Other than pointing it out haha)

    Plugin Author Frank Goossens

    (@futtta)

    I had a better look; optimizing SVG (and specifically Genericons.svg) yields very little performance-gain and might break the SVG, so I will (for now) not add SVG optimization to Autoptimize and hence there’ll be not automagical better expiry either I’m afraid.

    frank

    Thread Starter SVTX

    (@12ax7)

    Cool and good to know, thanks. I just wondered if it could be worth just specifying the expiration time so it won’t throw these “errors”?

    If it isn’t would that be what I needed to put into my htaccess?

    ExpiresByType image/svg+xml “access plus 1 month”

    Plugin Author Frank Goossens

    (@futtta)

    It could, but as those files aren’t treated by autoptimize, AO can’t change the expiration time. Depending on your webserver (apache?) you could do that yourself?

    Thread Starter SVTX

    (@12ax7)

    Yes, I have just edited my previous post but then you replied too quickly ??

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Specify cache expiration for .svg files’ is closed to new replies.