Link to home
Start Free TrialLog in
Avatar of Zack
ZackFlag for Canada

asked on

Problem redirecting to secure

Hi All - I'm trying to get my website to forward non secure urls to secure.
ie: http://www.x.com/ to https://www.x.com/
including subdirectories
http://www.x.com/test
to https://www.x.com/test

I'm having an issue with invalid redirects and I've been trying to Google but nothing seems to work.  I was wondering if someone could help me out.

I'm using IIS7 with Plesk 10.4.4 as the frontend.

Thanks!
Avatar of Shalom Carmel
Shalom Carmel
Flag of Israel image

pls explain what errors and issues you have. It is difficult to diagnose without details.
ASKER CERTIFIED SOLUTION
Avatar of Systech Admin
Systech Admin
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Hello,

You should configure URL rewrite rule in your web.config file. Please refer http://tech.mikeal.com/blog1.php/url-rewrite-for-iis7-http-to-https-redirection

<rule name="HTTP to HTTPS redirect" stopProcessing="true">
  <match url="(.*)" />
    <conditions>
      <add input="{HTTPS}" pattern="off" ignoreCase="true" />
    </conditions>
 <action type="Redirect" redirectType="Found" url="https://{HTTP_HOST}/{R:1}" />
</rule>

Open in new window


This module is add-on and you would need to install if not installed.

Regards,
Sanjay Santoki
Avatar of Zack

ASKER

Ok thanks all for responding!  Will try out those suggestions.  Can't try any until later tonight due to heavy traffic.  Will respond back asap.

Thanks again!
Avatar of Zack

ASKER

Thanks!