![]() |
Who knows about HTACCESS
I need a piece of code that makes my server display the content in :
http://www.myserver.com/access/ if this URL is loaded http://www.myserver.com/access/[any_word]/ When loaded the URL in the adressbar still needs to be http://www.myserver.com/access/[any_word]/ Anyone? |
ErrorDocument 404 http://www.myserver.com/access/
as anyword would create a 404 error this will then redirect to the root of that folder |
If you have mod_rewite on this MIGHT work, I havent tryed it myself.
RewriteEngine On RewriteRule ^access/([/:|\s\-\'{}().&_a-zA-Z0-9+=]*) http://www.myserver.com/access/ put that in your ROOT dir (ie http://www.myserver.com/.htaccess) |
I doesnt work, my server goes 500 with it
|
hmmmm yea I forgot you cant use full URLS in a rewrite.
try these RewriteRule ^access/([/:|\s\-'{}().&_a-zA-Z0-9+=]*) /access/ RewriteRule ^access/([/:|\s\-'{}().&_a-zA-Z0-9+=]*)/ /access/ or RewriteRule /access/([/:|\s\-'{}().&_a-zA-Z0-9+=]*) /access/ RewriteRule /access/([/:|\s\-'{}().&_a-zA-Z0-9+=]*)/ /access/ Im not that good with rewrite rules. |
No luck :)
But thanks for trying |
http://www.engelschall.com/pw/apache/rewriteguide/
very simple use the "Dynamic Mirror" pass-thru option |
All times are GMT -7. The time now is 09:47 AM. |
Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123