Index can't be accessed anymore

Zero duplicate support forum. Personalized HTTP 301 dynamic redirections for phpBB.

Moderator: Moderators

Index can't be accessed anymore

Postby JanMarques » Sun Jul 29, 2007 11:06 am

Hi there,
recently installed all the phpBB 3 SEO mods.
All went fine, but when installing "phpBB3 SEO Zero Duplicate" it goes wrong.

I can access neither /forum/ neiter /forum/index.php ...
It just gives me the indexpage of my site...

When changing
Code: Select all
$this->seo_opt['zero_dupe'] = array( 'on' => true,

to
Code: Select all
$this->seo_opt['zero_dupe'] = array( 'on' => false,


I can access it via /forum/index.php and not with /forum/.

But of course, the mod is disabled then...

My .htaccess file might be usefull:
Code: Select all
##
# SEO SITE
##

DirectoryIndex /index.php
ErrorDocument 403 /
ErrorDocument 404 /

Options All -Indexes


Options +FollowSymLinks
RewriteEngine on
RewriteCond %(REQUEST_URI) !^/forum/.*

RewriteBase /
RewriteRule ^index\.html   /index.php   [NC,L]
RewriteRule ^([a-zA-Z0-9_-]*)/$ /index.php?page=$1   [NC,L]
RewriteRule ^([a-zA-Z0-9_-]*)\.html$ /index.php?page=$1    [NC,L]
RewriteRule ^([a-zA-Z0-9_-]*)/([a-zA-Z0-9_-]*)\.html$ /index.php?page=$1&seoext=$2    [NC,L]
RewriteRule (.*)\.xml(.*) $1.php$2 [nocase] 

##
# SEO FORUM
##
RewriteRule ^forum/index\.html$ /forum/index.php [QSA,L]
RewriteRule ^forum/[a-z0-9_-]*-f([0-9]+)(-([0-9]+))?/?$ /forum/viewforum.php?f=$1&start=$3 [QSA,L,NC]
RewriteRule ^forum/[a-z0-9_-]*-f([0-9]+)/[a-z0-9_-]*-t([0-9]+)(-([0-9]+))?\.html$ /forum/viewtopic.php?f=$1&t=$2&start=$4 [QSA,L,NC]
RewriteRule ^forum/announces/[a-z0-9_-]*-t([0-9]+)(-([0-9]+))?\.html$ /forum/viewtopic.php?t=$1&start=$3 [QSA,L,NC]
RewriteRule ^forum/post([0-9]+)\.html$ /forum/viewtopic.php?p=$1 [QSA,L]
RewriteRule ^forum/member([0-9]+)\.html$ /forum/memberlist.php?mode=viewprofile&u=$1 [QSA,L]
RewriteRule ^forum/the-team\.html$ /forum/memberlist.php?mode=leaders [QSA,L,NC]



Any idea how to solve?
JanMarques
 
Posts: 6
Joined: Sun Jul 29, 2007 9:55 am

Advertisement

Postby dcz » Fri Aug 03, 2007 3:01 pm

I think your facing several issues here.

First, it looks like the root rewriterules cold interfere with the forum ones :
Code: Select all
RewriteRule ^([a-zA-Z0-9_-]*)/([a-zA-Z0-9_-]*)\.html$ /index.php?page=$1&seoext=$2    [NC,L]


For example.

And :

Code: Select all
RewriteCond %(REQUEST_URI) !^/forum/.*


Is pretty much of no effect where it stands.

So I suggest you use this one instead :

Code: Select all
##
# SEO SITE
##

DirectoryIndex /index.php
ErrorDocument 403 /
ErrorDocument 404 /

Options All -Indexes


Options +FollowSymLinks
RewriteEngine on
RewriteBase /

##
# SEO FORUM
##
RewriteRule ^forum/index\.html$ /forum/index.php [QSA,L]
RewriteRule ^forum/[a-z0-9_-]*-f([0-9]+)(-([0-9]+))?/?$ /forum/viewforum.php?f=$1&start=$3 [QSA,L,NC]
RewriteRule ^forum/[a-z0-9_-]*-f([0-9]+)/[a-z0-9_-]*-t([0-9]+)(-([0-9]+))?\.html$ /forum/viewtopic.php?f=$1&t=$2&start=$4 [QSA,L,NC]
RewriteRule ^forum/announces/[a-z0-9_-]*-t([0-9]+)(-([0-9]+))?\.html$ /forum/viewtopic.php?t=$1&start=$3 [QSA,L,NC]
RewriteRule ^forum/post([0-9]+)\.html$ /forum/viewtopic.php?p=$1 [QSA,L]
RewriteRule ^forum/member([0-9]+)\.html$ /forum/memberlist.php?mode=viewprofile&u=$1 [QSA,L]
RewriteRule ^forum/the-team\.html$ /forum/memberlist.php?mode=leaders [QSA,L,NC]


RewriteRule ^index\.html   /index.php   [NC,L]
RewriteRule ^([a-zA-Z0-9_-]*)/$ /index.php?page=$1   [NC,L]
RewriteRule ^([a-zA-Z0-9_-]*)\.html$ /index.php?page=$1    [NC,L]
RewriteRule ^([a-zA-Z0-9_-]*)/([a-zA-Z0-9_-]*)\.html$ /index.php?page=$1&seoext=$2    [NC,L]
RewriteRule ^([^/]+)\.xml(.*) $1.php$2 [nocase]


I just changed the order and took the occasion to change the xml one :

Code: Select all
RewriteRule ^([^/]+)\.xml(.*) $1.php$2 [nocase]


This way, it won't match other folders.
The forum RegEx are pretty fast since they always first test "forum/", and your .htaccess is pretty small, so it's not a performance issue to have the site ones after.
The other possibility is to check the URI to make sure forum/ is not asked, like you first did, but you must add the line before each concerned rewriterules.

So let's first see how thing goes with this one, I'm pretty sure that the odd redirection occurring with the zero dupe will be fixed, if not all the issues.

++
Useful links :
SEO Forum || SEO Directory || SEO phpBB || Search
____________________

Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Recherche
dcz
Admin
Admin
 
Posts: 21219
Joined: Fri Apr 28, 2006 9:03 pm


Return to Zero duplicate

 


  • Related topics
    Replies
    Views
    Last post

Who is online

Users browsing this forum: No registered users and 1 guest