php_begins Posted November 17, 2011 Share Posted November 17, 2011 I need help with .htaccess redirects. I need to redirect /members/member_test.php to members/test (Note: there is no test directory) Link to comment https://forums.phpfreaks.com/topic/251339-htacess/ Share on other sites More sharing options...
phporcaffeine Posted November 17, 2011 Share Posted November 17, 2011 Not the right forum however, you'll need a combination of mod_rewrite and mod_alias http://httpd.apache.org/docs/current/mod/mod_rewrite.html http://httpd.apache.org/docs/2.0/mod/mod_alias.html Link to comment https://forums.phpfreaks.com/topic/251339-htacess/#findComment-1289130 Share on other sites More sharing options...
php_begins Posted November 17, 2011 Author Share Posted November 17, 2011 i forgot to mention i actually dont want to redirect. It should just show /members/test in the url. Link to comment https://forums.phpfreaks.com/topic/251339-htacess/#findComment-1289132 Share on other sites More sharing options...
requinix Posted November 17, 2011 Share Posted November 17, 2011 Are there any other member_*.php files you'll want to "redirect"? Link to comment https://forums.phpfreaks.com/topic/251339-htacess/#findComment-1289141 Share on other sites More sharing options...
php_begins Posted November 18, 2011 Author Share Posted November 18, 2011 Quote Are there any other member_*.php files you'll want to "redirect"? No just redirect member_test.php.(Just show the redirect in the browser without actually redirecting that page) Link to comment https://forums.phpfreaks.com/topic/251339-htacess/#findComment-1289287 Share on other sites More sharing options...
requinix Posted November 18, 2011 Share Posted November 18, 2011 Use an Alias if you know the full path to the files, or a simple RewriteRule if you don't. Link to comment https://forums.phpfreaks.com/topic/251339-htacess/#findComment-1289414 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.