Guest User

Untitled

a guest
Oct 3rd, 2012
192
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.79 KB | None | 0 0
  1.  
  2. RewriteEngine On
  3. RewriteBase /pages
  4.  
  5. RewriteCond %{REQUEST_FILENAME} -f [OR]
  6. RewriteCond %{REQUEST_FILENAME} -d
  7. RewriteRule .* - [L]
  8.  
  9. RewriteRule ^([_0-9a-zA-Z-]+/)?((?:am-.*)|(?:.*\.php)) $2 [L]
  10. # RewriteRule ^([_0-9a-zA-Z-]+/)?()$ $2 [L] # merged into the rule above
  11.  
  12. # RewriteCond %{REQUEST_FILENAME} !-f # superfluous, has been asserted by the first two conditions
  13. RewriteCond %{REQUEST_URI} !(.*)/$
  14. RewriteRule (.*)$ /pages/$1/ [R=301,L]
  15.  
  16. # RewriteRule ^index\.php$ - [L] # superfluous, has been handled by the first rule
  17. # RewriteCond %{REQUEST_FILENAME} !-f # superfluous, has been asserted by the first two conditions
  18. # RewriteCond %{REQUEST_FILENAME} !-d # superfluous, has been asserted by the first two conditions
  19. RewriteRule ^([a-zA-Z0-9\-_\/\s]+)/?$ /pages/index.php [L]
Advertisement
Add Comment
Please, Sign In to add comment