Reputation: 64854
I have installed my website in a subfolder www.server.com/folder/index.php
Is there any way to hide "folder/" in my url ?
The only solution I can think is to change Directory Root on the apache config file, but unluckily I don't have access to it
thanks
Update: all the solutions provided so far are not changing the url
Upvotes: 1
Views: 12979
Reputation: 12440
if you have your website installed on a server you can overlay it with a specific domain...
like www.example.com leads to www.server.com/folder/
In many backends it is an option to do this or even to say that www.server.com/folder/ is root directory
Upvotes: 0
Reputation: 11991
make .htaccess file, and put this:
Options +FollowSymlinks
RewriteEngine on
RewriteRule ^(.*)\.php$ http://www.server.com/folder/$1.php [nc]
everytime you access www.server.com/index.php will be redirected to www.server.com/folder/index.php
Upvotes: 1
Reputation: 5671
Can you create files on root?
Symbolic link
You could create a symbolink link on your root directory:
ln -s /folder/ index.php
Upvotes: 0