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

XF 1.4 Specific .htaccess question from phpbb3 to XF

Discussion in 'XenForo Questions and Support' started by Sap1ent, Jun 4, 2015.

  1. Sap1ent

    Sap1ent New Member

    Hi guys,

    I've asked a lot of questions lately and had some great responses (and learnt a lot in the process!).

    A few of those questions have been around .htaccess - indeed, i've learnt a lot about how it works recently.

    I originally ran a phpbb3 forum and i've successfully got almost all traffic redirecting from any old urls that are still lingering around, however, one i'm having particular trouble with is structured like this:


    And i'm getting tons of crawls errors in webmaster tools specifically from those structured urls.

    This appears to be because the query string doesn't include the 'f=xxxx' element.

    i.e. this URL is redirected perfectly:


    And is captured by these two elements of the htaccess:

    (this strips the 'phpbb3' off)
    RewriteBase /
    RewriteRule ^phpbb3/(.*)$ /$1 [R=301,NC,L]
    (this manipulates the bit before the query string)
    RewriteCond %{QUERY_STRING} (^|\?)f=([0-9]+)&t=([0-9]+)($|&)
    RewriteRule ^viewtopic\.php$ /index.php?threads/%3/ [R=301,L]
    Does anyone know how i'd redirect those broken URLs properly?

    As always, thanks in advance. :D
  2. Mike

    Mike XenForo Developer Staff Member

  3. Sap1ent

    Sap1ent New Member

    Thanks for that Mike - even if I don't use it, I can probably manipulate it's inclusions!

Share This Page