1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.2 Redirection vbseo in Nginx

Discussion in 'Installation, Upgrade, and Import Support' started by hungphutho, Aug 26, 2013.

  1. hungphutho

    hungphutho Member

    helps me to convert
    Code:
    RewriteRule [^/]+/([\d]+)-.+-([\d]+).html showthread.php?t=$1&page=$2 [NC,L]
    RewriteRule [^/]+/([\d]+)-.+.html showthread.php?t=$1 [NC,L]
    My rules current
    Code:
    location / {
        try_files $uri $uri/ /index.php?$uri&$args;
        index index.php index.html;
    }
    
    location /internal_data/ {
        internal;
    }
    location /library/ {
          internal;
    }
    
     
    Last edited: Aug 26, 2013
  2. hungphutho

    hungphutho Member

    reason why I install nginx centminmod :) http://centminmod.com/
    so I do not succeed
    I offer one solution is to use centminmod and that is the case I
    Solution :
    Fix centminmod nginx for xenforo
    EDIT file staticfiles.conf

    location ~* \.(html|htm|txt)$ {
    #add_header Pragma public;
    add_header Cache-Control "public, must-revalidate, proxy-revalidate";
    access_log off;
    expires 7d;
    break;
    }
    to

    location ~* \.(htm|txt)$ {
    #add_header Pragma public;
    add_header Cache-Control "public, must-revalidate, proxy-revalidate";
    access_log off;
    expires 7d;
    break;
    }

    Rewrite

    rewrite [^/]+/([\d]+)-.+-([\d]+).html /threads/$1 redirect;
    rewrite [^/]+/([\d]+)-.+.html /threads/$1 redirect;
    rewrite [^/]+/([\d]+)-.+-([\d]+).html /showthread.php?t=$1&page=$2 break;
    rewrite [^/]+/([\d]+)-.+.html /showthread.php?t=$1 break;
     
    BamaStangGuy likes this.
  3. DRaver

    DRaver Active Member

    For me it´s not redirect site two of an old thread to site two of the new site. Site two will redirect to site one with that rules.
     

Share This Page