Go Back   CodingForums.com > :: Server side development > Apache configuration

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 05-07-2011, 10:56 AM   PM User | #1
howie2009
Regular Coder

 
howie2009's Avatar
 
Join Date: May 2009
Location: Ireland
Posts: 202
Thanks: 37
Thanked 0 Times in 0 Posts
howie2009 is an unknown quantity at this point
htaccess question

Hi Guys,
I'm sure there a way to do this.
If I have a site called eg www.mysite.com and the site files are in a directory called site so www.mysite.com/site/index.php..

Is there a way in htaccess or other so that I can hide "site" in the url so that that it looks like the user is in the root? I'm just building a new site into an existing site and would like to be able to switch over easily to the new directory but not have "site" in the url. I don't want the user to know they are in a directory called site.

Hope i explained this well.

Thanks
howie2009 is offline   Reply With Quote
Old 05-07-2011, 07:44 PM   PM User | #2
howie2009
Regular Coder

 
howie2009's Avatar
 
Join Date: May 2009
Location: Ireland
Posts: 202
Thanks: 37
Thanked 0 Times in 0 Posts
howie2009 is an unknown quantity at this point
This kinda does it for just redirecting the root

Code:
RewriteEngine On
RewriteRule ^(.*)$ subdirectory/$1 [L]
but I need navigation links in the website to drop the word site in the url too.
howie2009 is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 01:46 PM.


Advertisement
Log in to turn off these ads.