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

XF 1.2 phpbb URLs are not redirecting to new 'seo' URLS?

Discussion in 'Installation, Upgrade, and Import Support' started by SEOmers, Dec 15, 2013.

  1. SEOmers

    SEOmers Active Member

    Hi

    I've just moved from phpbb to xenforo -

    Site: http://motovlog.com

    Old URLS are; https://www.google.co.uk/search?q=site:motovlog.com&oq=site:&aqs=chrome.4.69i57j69i58j69i65l2j69i59.5071j0j7&sourceid=chrome&espv=210&es_sm=122&ie=UTF-8

    The above URLS are NOT redirecting to the new structure?

    I've tried this http://xenforo.com/community/resources/redirection-script-for-phpbb-3-0-x-without-seo-urls.2326/ which caused 404s

    The site is established and we have a good amount of links - If I can't fix this then it's like start new which is well, argh........

    Any hep would be appreciated

    I've password protected the site while sort it

    user; dan
    pass; getin
     
  2. Brogan

    Brogan XenForo Moderator Staff Member

    Can you post some examples of old and new URLs.

    What do you have in your .htacess file?
     
  3. SEOmers

    SEOmers Active Member

    For example;

    http://www.motovlog.com/viewtopic.php?f=6&t=5295 - Should go to http://motovlog.com/threads/ive-ditched-the-recent-topics-bit-for-a-short-while.5295/

    htaccess is below - I;ve removed the line that was suggested by the php redirect script as that broke new urls

    Code:
    #    Mod_security can interfere with uploading of content such as attachments. If you
    #    cannot attach files, remove the "#" from the lines below.
    #<IfModule mod_security.c>
    #    SecFilterEngine Off
    #    SecFilterScanPOST Off
    #</IfModule>
    
    ErrorDocument 401 default
    ErrorDocument 403 default
    ErrorDocument 404 default
    ErrorDocument 500 default
    
    <IfModule mod_rewrite.c>
        RewriteEngine On
    
        #    If you are having problems with the rewrite rules, remove the "#" from the
        #    line that begins "RewriteBase" below. You will also have to change the path
        #    of the rewrite to reflect the path to your XenForo installation.
        #RewriteBase /xenforo
    
        #    This line may be needed to enable WebDAV editing with PHP as a CGI.
        #RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
    
        RewriteCond %{REQUEST_FILENAME} -f [OR]
        RewriteCond %{REQUEST_FILENAME} -l [OR]
        RewriteCond %{REQUEST_FILENAME} -d
        RewriteRule ^.*$ - [NC,L]
        RewriteRule ^(data/|js/|styles/|install/|favicon\.ico|crossdomain\.xml|robots\.txt) - [NC,L]
        RewriteRule ^.*$ index.php [NC,L]
    </IfModule>
    AuthName "dan"
    AuthUserFile "/home/motovlog/.htpasswds/public_html/passwd"
    AuthType Basic
    require valid-user
    
     
  4. SEOmers

    SEOmers Active Member

  5. Mike

    Mike XenForo Developer Staff Member

    Because of the password, we can't see what the redirects are doing. However, if I recall, the redirects in that script only work if you've maintained IDs (it doesn't use the look up system of, say, the vB redirect scripts). Based on your examples, this should be ok though. However, if you say you didn't add the line listed in the resource, that will very likely break the resource and cause the redirects to not work.

    Also, I should note that the URLs given in Google don't appear to meet the standard phpBB structure. They're things like topic1234.html so you would need rewrites to match them (at the top of the .htaccess) to redirect them to the standard URLs (or to that phpbb.php script).
     
  6. SEOmers

    SEOmers Active Member

    password is in the OP :)


    I did add the line but that caused everything to 404 - I've added it so you can see for yourself, now, none of the URLS work at all
     
  7. Mike

    Mike XenForo Developer Staff Member

    The redirect doesn't appear as if it's being triggered - as mentioned, this is likely because of the missing line that you need to add to .htaccess.

    These are standard mod_rewrite rules that you can use to do the redirections (if you maintained IDs): http://xenforo.com/community/threads/ready-to-buy-but.54415/#post-581106

    Note that they need to go after the RewriteEngine line in the standard version.
     
    SEOmers likes this.
  8. SEOmers

    SEOmers Active Member

    I have added
    RewriteRule ^(viewforum|viewtopic)\.php phpbb.php [NC,L]

    To the file, then everything will 404



    edit - I've spotted where you linked to ;)
     

Share This Page