Forum Moderators: phranque

Message Too Old, No Replies

in which directory should the htaccess file be saved?

         

sonill

4:31 am on May 7, 2009 (gmt 0)

10+ Year Member



i have subdomain in my site and i want to use mod_rewrite for that subdomain. i have generated some mod_rewrite code using external online tools and paste it inside .htaccess file but it doesn't work.

I m confused if i have places the htacces file in wrong directory.

my subdomain name is investment.pokharavalley.com and i have placed the htacces file inside investment folder.

can anyone give suggestion for my prob.

the code i used is:

///
Options FollowSymLinks
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^home/msg/([^/]+)/topic/([^/]+)/$ home.php?msg=$1&topic=$2& [L,NC]
//

i have used php info() code to see if the mod_rewrite is enabled or not and it shows enabled.

here's the link to my php info file;
[pokharavalley.com...]

g1smd

11:15 am on May 7, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



The rule will not "see" any of the path parts 'higher' than its own location.

So, you probably don't need the 'home/' or 'msg/' parts in the pattern.