php - htaccess redirection is not working -
i don't know more how write htaccess code redirection.
now url : http://mydomain.com/beta/?selector=login. above link open login page,
login page available here : page/login.php
and have write following code in index.php
<?php include ("page/header.php"); if(isset($_get['selector'])){ if($_get['selector']=="feed") { include ("feeds/index.php"); } else { include ("page/".$_get['selector'].".php"); } } else{ include ("page/home.php"); } include ("page/header.php"); ?>
now want instead of above link http://mydomain.com/beta/login
i have write following code in htaccess file :
rewriteengine on
rewritebase /beta/
rewriterule ^index.php$ - [l]
rewritecond %{request_filename} !-f
rewritecond %{request_filename} !-d
rewriterule . /beta/index.php [l]
it's not working..
please me , in advance. please don't down vote , sorry language , poor english :(
will work?
rewriteengine on rewritebase /beta/ rewriterule ^index.php$ - [l] rewriterule ^feed/?$ - [l] rewritecond %{request_filename} !-f rewritecond %{request_filename} !-d rewriterule ^(.*)$ index.php?selector=$1 [l,qsa]
Comments
Post a Comment