| | #1 |
| HyperActive Warrior War Room Member Join Date: 2006 Location: Spokane, WA
Posts: 416
Thanks: 221
Thanked 59 Times in 45 Posts
Blog Entries: 4 |
Hope my title is descriptive enough. ![]() I have a project management application I've installed in a subdirectory on one of my domains, i.e. mydomain.com/projectmgt In retrospect, perhaps I should have installed it in the root. At any rate, what I want to do is have the app appear as if it is installed in the root, so the user navigates to: mydomain.com to log in. Is there a simple way to accomplish this? Please let me know if you need more info. Thanks! |
| Darrel Hawes - Blog Last edited on 24th Nov 2010 at 10:32 AM. Reason: deleted extraneous words :) | |
| |
| | #2 |
| VIP Warrior War Room Member Join Date: 2007 Location: Caldwell, Idaho, USA.
Posts: 1,967
Thanks: 1,024
Thanked 2,043 Times in 1,183 Posts
|
This goes in your root-level .htaccess file: Code: RewriteEngine On
RewriteCond %{REQUEST_URI} ^/projectmgt
RewriteRule (.*) http://yourdomain.com$1 [R,L]
RewriteRule (.*) /projectmgt$1 [NC,L] The easiest solution may be just to reinstall the application in the root folder. |
|
The 2nd Amendment, 1789 - The Original Homeland Security. Gun control means never having to say, "I missed you." | |
| |
| | #3 | |
| HyperActive Warrior War Room Member Join Date: 2006 Location: Spokane, WA
Posts: 416
Thanks: 221
Thanked 59 Times in 45 Posts
Blog Entries: 4 |
Hi Steven, You're in my neck of the woods, sorta. Thanks for your prompt reply. I put your code into my .htaccess file (of course making the correct modifications for my actual domain), and here's what happens:
| |
| Darrel Hawes - Blog | ||
| |
| | #4 |
| The Chaotic Marketer War Room Member Join Date: 2007 Location: Swamplands of NJ - USA
Posts: 278
Thanks: 158
Thanked 64 Times in 52 Posts
|
my personal thinking is that you are concerned over nothing... why not just leave the domain free for use as a welcome, sales, contact, info, etc page and simply have a link in the footer and in the upper right: "log in page" this way you can tweak the content on the domain's index to your hearts content without ever need to mess with the main script's index page..? KEY (eric) |
| |
| | #5 |
| Automation Specialist War Room Member Join Date: 2009 Location: Cary, NC
Posts: 153
Thanks: 31
Thanked 13 Times in 13 Posts
Blog Entries: 2 |
why couldn't you just move the files to the root directory? What you could do (if you have this level of access) is to move the files from the project directory and move it to the root, and create a symlink for projectdir and point it to the root directory ("ln -s projectdir . " - I might have the syntax flipped).
|
| | |
| |
|
| Bookmarks |
| Tags |
| install, redirect, root, subdirectory |
| |