Solved

IIS - redirect to root site

Posted on 2013-01-03
3
583 Views
Last Modified: 2013-04-08
We have a site at store.mysite.com.

Some of the links marketing as published link to store.mysite.com/store/

If a user clicks this link, it just goes to a 403 error page. Is it possible to make IIS redirect requests to store.mysite.com/store/ back to store.mysite.com?

Thanks!
0
Comment
Question by:dthansen
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 29

Assisted Solution

by:Randy Downs
Randy Downs earned 167 total points
ID: 38742571
0
 
LVL 80

Assisted Solution

by:David Johnson, CD, MVP
David Johnson, CD, MVP earned 166 total points
ID: 38742835
which version of iis? you will need the url rewrite module

--- web.config ---
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <system.webServer>
       <rewrite>
  <rules>
   <rule name="Redirect to Root" stopProcessing="true">
     <match url="^store/(.*)" />
       <conditions>
                        <add input="{HTTP_HOST}" pattern="^(www\.)?mysite.com$" />
       </conditions>
      <action type="Redirect" url="http://{C:0}/{R:1}" redirectType="Permanent" />
   </rule>
  </rules>
</rewrite>
    </system.webServer>
</configuration>
-----
0
 
LVL 10

Accepted Solution

by:
Monica P earned 167 total points
ID: 38787085
Incase of IIS 7

Set the Default Document for the Website  IIS
------------------------------------------------------------------------
http://www.serverintellect.com/support/windowsserver2008/Default-document-IIS7.aspx

Allow directory browsing option Enabled if you still face any error and check


Or Set in webconfig file
-----------------------------

<configuration>
   <system.webServer>
      <defaultDocument enabled="true">
         <files>
            <add value="index.php" />
         </files>
      </defaultDocument>
   </system.webServer>
</configuration>
0

Featured Post

Edgartown IT Case Study

Learn about Edgartown's quest to ensure the safety and security of the entire town's employee and citizen data. Read the case study!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Slowly Changing Dimension Transformation component in data task flow is very useful for us to manage and control how data changes in SSIS.
This article shows gives you an overview on SQL Server 2016 row level security. You will also get to know the usages of row-level-security and how it works
Using examples as well as descriptions, and references to Books Online, show the documentation available for date manipulation functions and by using a select few of these functions, show how date based data can be manipulated with these functions.
This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function

763 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