php - Trying to remove directory names from application URL -
my badluck i'm ui developer , given task of url rewriting please me.
i've url me /abc/def/ghi/somefile.php?id=1
want somefile?id=1
i have code in .htaccess
options +followsymlinks -multiviews rewriteengine on rewritebase / rewriterule ^/abc/def/ghi/(.*)$ /$1 [l,nc,r]
but after uploading htaccess server giving me 404 error after removing /abc/def/ghi/ part.
any appreciated.
rewriterule not receive first slash
rewriterule ^abc/def/ghi/(.*)$ /$1 [l,nc,r]
Comments
Post a Comment