Forum Moderators: phranque
dynamic url: [domain.com...]
i want the static url look like :
[domain.com...]
I tried the following syntax but it didn't work:
Options +FollowSymLinks
RewriteEngine on
RewriteRule ^folder/(.*)$ folder/file.php?var1=$1 [L]
I had put this code in the .htaccess file in my root folder.
Please help me out
This line results in an infinite loop. you should add a rewrite condition to it:
RewriteCond %{REQUEST_URI}!^folder/file.php
RewriteRule ^folder/(.*)$ folder/file.php?var1=$1 [L]
That will avoid applying the rule after it has already been applied. Note that there should be a space after %{REQUEST_URI}.
You might also need leading /s before folder. IE:
RewriteRule ^/folder/(.*)$
etc.
Welcome to the forums,
My First question, are you getting such urls
[domain.com...] Let's break the problem into simpler halves.
If you are getting then we can think of processing it.
AjiNIMC
The directives are working fine if I use the following:
Options +FollowSymLinks
RewriteEngine on
RewriteRule file/(.*)/(.*)/$ /folder/file.php?$1=$2
and the new static url looks like [domain.com...]
while i need the url look like
[domain.com...]
pls help