Advertisement
Guest User

Untitled

a guest
Mar 10th, 2013
157
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.04 KB | None | 0 0
  1.  
  2.  
  3. # Lines That should already be in your .htacess
  4. <Files "config.php">
  5. Order Allow,Deny
  6. Deny from All
  7. </Files>
  8. <Files "common.php">
  9. Order Allow,Deny
  10. Deny from All
  11. </Files>
  12.  
  13. # You may need to un-comment the following lines
  14. # Options +FollowSymlinks
  15. # To make sure that rewritten dir or file (/|.html) will not load dir.php in case it exist
  16. # Options -MultiViews
  17. # REMEBER YOU ONLY NEED TO STARD MOD REWRITE ONCE
  18. RewriteEngine On
  19. # Uncomment the statement below if you want to make use of
  20. # HTTP authentication and it does not already work.
  21. # This could be required if you are for example using PHP via Apache CGI.
  22. # RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization},L]
  23. # REWRITE BASE
  24. RewriteBase /
  25. # HERE IS A GOOD PLACE TO FORCE CANONICAL DOMAIN
  26. # RewriteCond %{HTTP_HOST} !^tangoresults\.com$ [NC]
  27. # RewriteRule ^(.*)$ http://tangoresults.com/$1 [QSA,L,R=301]
  28.  
  29. # DO NOT GO FURTHER IF THE REQUESTED FILE / DIR DOES EXISTS
  30. RewriteCond %{REQUEST_FILENAME} -f
  31. RewriteCond %{REQUEST_FILENAME} -d
  32. RewriteRule . - [L]
  33. #####################################################
  34. # PHPBB SEO REWRITE RULES ALL MODES
  35. #####################################################
  36. # AUTHOR : dcz www.phpbb-seo.com
  37. # STARTED : 01/2006
  38. #################################
  39. # FORUMS PAGES
  40. ###############
  41. # FORUM INDEX REWRITERULE WOULD STAND HERE IF USED. "forum" REQUIRES TO BE SET AS FORUM INDEX
  42. # RewriteRule ^forum\.html$ /index.php [QSA,L,NC]
  43. # FORUM ALL MODES
  44. RewriteRule ^(forum|[a-z0-9_-]*-f)([0-9]+)(-([0-9]+))?\.html$ /viewforum.php?f=$2&start=$4 [QSA,L,NC]
  45. # TOPIC WITH VIRTUAL FOLDER ALL MODES
  46. RewriteRule ^(forum|[a-z0-9_-]*-f)([0-9]+)/(topic|[a-z0-9_-]*-t)([0-9]+)(-([0-9]+))?\.html$ /viewtopic.php?f=$2&t=$4&start=$6 [QSA,L,NC]
  47. # TOPIC WITHOUT FORUM ID & DELIM ALL MODES
  48. RewriteRule ^([a-z0-9_-]*)/?(topic|[a-z0-9_-]*-t)([0-9]+)(-([0-9]+))?\.html$ /viewtopic.php?forum_uri=$1&t=$3&start=$5 [QSA,L,NC]
  49. # PHPBB FILES ALL MODES
  50. RewriteRule ^resources/[a-z0-9_-]+/(thumb/)?([0-9]+)$ /download/file.php?id=$2&t=$1 [QSA,L,NC]
  51. # PROFILES THROUGH USERNAME
  52. RewriteRule ^member/([^/]+)/?$ /memberlist.php?mode=viewprofile&un=$1 [QSA,L,NC]
  53. # USER MESSAGES THROUGH USERNAME
  54. RewriteRule ^member/([^/]+)/(topics|posts)/?(page([0-9]+)\.html)?$ /search.php?author=$1&sr=$2&start=$4 [QSA,L,NC]
  55. # GROUPS ALL MODES
  56. RewriteRule ^(group|[a-z0-9_-]*-g)([0-9]+)(-([0-9]+))?\.html$ /memberlist.php?mode=group&g=$2&start=$4 [QSA,L,NC]
  57. # POST
  58. RewriteRule ^post([0-9]+)\.html$ /viewtopic.php?p=$1 [QSA,L,NC]
  59. # ACTIVE TOPICS
  60. RewriteRule ^active-topics(-([0-9]+))?\.html$ /search.php?search_id=active_topics&start=$2&sr=topics [QSA,L,NC]
  61. # UNANSWERED TOPICS
  62. RewriteRule ^unanswered(-([0-9]+))?\.html$ /search.php?search_id=unanswered&start=$2&sr=topics [QSA,L,NC]
  63. # NEW POSTS
  64. RewriteRule ^newposts(-([0-9]+))?\.html$ /search.php?search_id=newposts&start=$2&sr=topics [QSA,L,NC]
  65. # UNREAD POSTS
  66. RewriteRule ^unreadposts(-([0-9]+))?\.html$ /search.php?search_id=unreadposts&start=$2 [QSA,L,NC]
  67. # THE TEAM
  68. RewriteRule ^the-team\.html$ /memberlist.php?mode=leaders [QSA,L,NC]
  69. # HERE IS A GOOD PLACE TO ADD OTHER PHPBB RELATED REWRITERULES
  70.  
  71. # FORUM WITHOUT ID & DELIM ALL MODES
  72. # THESE FOUR LINES MUST BE LOCATED AT THE END OF YOUR HTACCESS TO WORK PROPERLY
  73. RewriteCond %{REQUEST_FILENAME} !-f
  74. RewriteRule ^([a-z0-9_-]+)(-([0-9]+))\.html$ /viewforum.php?forum_uri=$1&start=$3 [QSA,L,NC]
  75. RewriteCond %{REQUEST_FILENAME} !-f
  76. RewriteRule ^([a-z0-9_-]+)\.html$ /viewforum.php?forum_uri=$1 [QSA,L,NC]
  77. # FIX RELATIVE PATHS : FILES
  78. RewriteRule ^.+/(style\.php|ucp\.php|mcp\.php|faq\.php|download/file.php)$ /$1 [QSA,L,NC,R=301]
  79. # FIX RELATIVE PATHS : IMAGES
  80. RewriteRule ^.+/(styles/.*|images/.*)/$ /$1 [QSA,L,NC,R=301]
  81. # END PHPBB PAGES
  82. #####################################################
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement