Join the community today
Become a Member

Xenforo XenForo 2.1 CDN using Cloudflare free plan :D

Discussion in 'Forum software usage' started by rdan, Oct 7, 2019.

  1. pdinh97qng

    pdinh97qng Member

    118
    14
    18
    Jan 24, 2016
    Ratings:
    +36
    Local Time:
    5:20 AM
    @rdan can you share your nginx with filter module, i tried but not working.

     
  2. rdan

    rdan Well-Known Member

    5,371
    1,353
    113
    May 25, 2014
    Ratings:
    +2,112
    Local Time:
    9:20 PM
    Mainline
    10.2
    Something like this:
    Code:
        ### Sub Filter
        sub_filter_last_modified on;
        sub_filter_once off;
    
        sub_filter 'src="/proxy.php' 'src="https://xf2-cdn.net/proxy.php';
        sub_filter 'src="/styles/'   'src="https://xf2-cdn.net/styles/';
    
        sub_filter 'href="https://xf2.com/attachments/' 'href="https://xf2-cdn.net/attachments/';
        sub_filter 'src="https://xf2.com/attachments/'   'src="https://xf2-cdn.net/attachments/';
    
     
  3. pdinh97qng

    pdinh97qng Member

    118
    14
    18
    Jan 24, 2016
    Ratings:
    +36
    Local Time:
    5:20 AM
    Thanks, some how I did the same last time but doesn't work.
     
  4. rdan

    rdan Well-Known Member

    5,371
    1,353
    113
    May 25, 2014
    Ratings:
    +2,112
    Local Time:
    9:20 PM
    Mainline
    10.2
    Put it above all your location block.
    Under server block.
     
  5. pdinh97qng

    pdinh97qng Member

    118
    14
    18
    Jan 24, 2016
    Ratings:
    +36
    Local Time:
    5:20 AM
    Got it, I also need to disable gzip in XF configuration.
     
  6. rdan

    rdan Well-Known Member

    5,371
    1,353
    113
    May 25, 2014
    Ratings:
    +2,112
    Local Time:
    9:20 PM
    Mainline
    10.2
    Ah yeah I have that disabled years ago.