Solved

Apache Redirect URL

Posted on 2013-01-25
4
428 Views
Last Modified: 2013-02-14
How can I configure apache to redirect a site from using www.website.com/nomad/index.php to www.website.com.  This is the routing of the webapp, so I am hoping I can configure a redirect in Apache.
0
Comment
Question by:Jack_son_
  • 2
4 Comments
 
LVL 50

Assisted Solution

by:Steve Bink
Steve Bink earned 334 total points
ID: 38821285
RewriteRule ^/?$ /nomad/index.php [QSA,R]

This rule should be placed in the site's virtual host container in the server's conf files, or in an .htaccess file in the root directory of the site.  You will also need to make sure mod_rewrite is loaded and turned on for the site in question.

http://httpd.apache.org/docs/2.2/mod/mod_rewrite.html
0
 
LVL 51

Assisted Solution

by:ahoffmann
ahoffmann earned 166 total points
ID: 38821639
hmm, I assume it's the other way around:

 RewriteRule ^/nomad/index.php / [QSA,R]
0
 
LVL 50

Accepted Solution

by:
Steve Bink earned 334 total points
ID: 38823493
Yeah, depending on interpretation.  Do you want requests to the root to go to the app, or do you want requests to the app to "look" like requests to the root?

One of those two will work for sure, though.
0
 

Author Comment

by:Jack_son_
ID: 38843860
I need them to go to a subdirectory; using an mvc, so I just want to redirect right to the home page, like in IIS, although have not done it in Apache
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Join & Write a Comment

Linux users are sometimes dumbfounded by the severe lack of documentation on a topic. Sometimes, the documentation is copious, but other times, you end up with some obscure "it varies depending on your distribution" over and over when searching for …
It is possible to boost certain documents at query time in Solr. Query time boosting can be a powerful resource for finding the most relevant and "best" content. Of course the more information you index, the more fields you will be able to use for y…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now