Support » Plugin: WP Super Cache » Cache .ttf files on CDN

  • Resolved phpmaster

    (@rodekker2017)


    Hi,

    I have enabled CDN on a couple of sites. Works like a charm.
    One small issue though is that it seems that it doesn’t rewrite the URL for .ttf files, despite the fact they are located in the wp-content directory.

    Do I need to specify this somewhere or add somewhere a filter?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Donncha Ó Caoimh

    (@donncha)

    Are the .ttf files in one of the “include directories” listed on the settings page?

    phpmaster

    (@rodekker2017)

    Yep, its in ‘/wp-content/plugins/gp-premium/general/icons/gp-premium.ttf’ as part of GeneratePress Premium. I guess the issue that its referenced in’/wp-content/plugins/gp-premium/general/icons/icons.css’ See below

    @font-face {
      font-family: 'GP Premium';
      src:  url('gp-premium.eot');
      src:  url('gp-premium.eot#iefix') format('embedded-opentype'),
        url('gp-premium.ttf') format('truetype'),
        url('gp-premium.woff') format('woff'),
        url('gp-premium.svg#gp-premium') format('svg');
      font-weight: normal;
      font-style: normal;
    }

    Is there anything I can do to feed this into CDN part of WP Super Cache?

    • This reply was modified 3 weeks, 6 days ago by phpmaster.
    • This reply was modified 3 weeks, 6 days ago by phpmaster.
    Plugin Author Donncha Ó Caoimh

    (@donncha)

    Unfortunately not. The CDN code only modifies the html of the page, and not CSS loaded by it. That CSS doesn’t pass through PHP at all so it wouldn’t be possible to modify the URLs in it.

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.