Solved

IIS - redirect to root site

Posted on 2013-01-03
3
591 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 30

Assisted Solution

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

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

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Why is this different from all of the other step by step guides?  Because I make a living as a DBA and not as a writer and I lived through this experience. Defining the name: When I talk to people they say different names on this subject stuff l…
Preparing an email is something we should all take special care with – especially when the email is for somebody you may not know very well. The pressures of everyday working life stacked with a hectic office environment can make this a real challen…
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
Via a live example, show how to extract insert data into a SQL Server database table using the Import/Export option and Bulk Insert.

623 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