We recently installed PHP SEO onto a windows 2003 server running PHP v5 cgi mode with ISAPI_Rewrite 2.8.
After generating the .htaccess file, copying it to the httpd.ini and modifying the rules somewhat we managed to get 98% of url rewriting to work.
One of issues which I cannot get around, if anyone could assist it would be highly appreciated.
View your posts not working.
When clicking on the view your posts URL an IIS 404 page not found error is returned. I've played around with the rules generated by php seo mod but cannot get this to work. (attached is a copy of the ruleset)
- Code: Select all
[ISAPI_Rewrite]
RewriteRule ^/forum\.html$ /index.php [I,L]
RewriteRule ^(/[a-z0-9_-]*-f)([0-9]+)(-([0-9]+))?\.html$ /viewforum.php?f=$2&start=$4 [I,L]
RewriteRule ^(/[a-z0-9_-]*-f)([0-9]+)/(topic|[a-z0-9_-]*-t)([0-9]+)(-([0-9]+))?\.html$ /viewtopic.php?f=$2&t=$4&start=$6 [I,L]
RewriteRule ^announces/(topic|[a-z0-9_-]*-t)([0-9]+)(-([0-9]+))?\.html$ /viewtopic.php?t=$2&start=$4 [I,L]
# TOPIC WITHOUT FORUM ID & DELIM ALL MODES
RewriteRule ^/([a-z0-9_-]*)/?(topic|[a-z0-9_-]*-t)([0-9]+)(-([0-9]+))?\.html$ /viewtopic.php?forum_uri=$1&t=$3&start=$5 [I,L]
# PHPBB FILES ALL MODES
RewriteRule ^/resources/[a-z0-9_-]+/(thumb/)?([0-9]+)$ /download/file.php?id=$2&t=$1 [I,L]
# PROFILES ALL MODES WITH ID
RewriteRule ^/(member|[a-z0-9_-]*-u)([0-9]+)\.html$ /memberlist.php?mode=viewprofile&u=$2 [I,L]
# USER MESSAGES ALL MODES WITH ID
RewriteRule ^(member|[a-z0-9_-]*-u)([0-9]+)-(topics|posts)(-([0-9]+))?\.html$ /search.php?author_id=$2&sr=$3&start=$5 [I,L]
# GROUPS ALL MODES
RewriteRule ^/(group|[a-z0-9_-]*-g)([0-9]+)(-([0-9]+))?\.html$ /memberlist.php?mode=group&g=$2&start=$4 [I,L]
# POST
RewriteRule ^/post([0-9]+)\.html$ /viewtopic.php?p=$1 [I,L]
# ACTIVE TOPICS
RewriteRule ^/active-topics(-([0-9]+))?\.html$ /search.php?search_id=active_topics&start=$2&sr=topics [I,L]
# UNANSWERED TOPICS
RewriteRule ^/unanswered(-([0-9]+))?\.html$ /search.php?search_id=unanswered&start=$2&sr=topics [I,L]
# NEW POSTS
RewriteRule ^/newposts(-([0-9]+))?\.html$ /search.php?search_id=newposts&start=$2&sr=topics [I,L]
# THE TEAM
RewriteRule ^/the-team\.html$ /memberlist.php?mode=leaders [I,L]
# HERE IS A GOOD PLACE TO ADD OTHER PHPBB RELATED REWRITERULES
# FORUM WITHOUT ID & DELIM ALL MODES (SAME DELIM)
# THESE THREE LINES MUST BE LOCATED AT THE END OF YOUR HTACCESS TO WORK PROPERLY
RewriteRule ^([a-z0-9_-]+)/?(page([0-9]+)\.html)?$ /viewforum.php?forum_uri=$1&start=$3 [I,L]
# FIX RELATIVE PATHS : FILES
RewriteRule ^.+/(style\.php|ucp\.php|mcp\.php|faq\.php|download/file.php)$ /$1 [I,L]
# FIX RELATIVE PATHS : IMAGES
RewriteRule ^.+/(styles/.*|images/.*)/$ /$1 [I,L]
# END PHPBB PAGES
#####################################################
####SHABS HACK
#RewriteRule ^/(-([0-9]+))?\.html$ /search.php?search_id=egosearch [I,L]
#RewriteRule ^/(-([0-9]+))-(-([0-9]+))?\.html$ /search.php?search_id=egosearch [I,L]
# Below is for this [url=http://www.phpbb-seo.com/en/phpbb-mod-rewrite/article2637.html]Rewriting sporadicly failed to remove SID from rewritten URL[/url]
RewriteRule ^/[a-z0-9_-]*-f([0-9]+)/[a-z0-9_-]*-t([0-9]+)(-([0-9]+))?\.html$ /viewtopic.php\?f=$1&t=$2&start=$4

English |
French
