पर पुनर्निर्देशित करने के लिए मुझे http और https urls दोनों के लिए www url पर गैर-www urls को रीडायरेक्ट करने की आवश्यकता है। मैंने web.config में नियमों का पालन करने की कोशिश की।web.config गैर-www को www
<rule name="Redirect to WWW" stopProcessing="true">
<match url=".*" />
<conditions>
<add input="{HTTP_HOST}" pattern="^domain.com$" />
</conditions>
<action type="Redirect" url="http://www.domain.com/{R:0}" redirectType="Permanent" />
<rule name="Redirect to WWW https" stopProcessing="true">
<match url=".*" />
<conditions>
<add input="{HTTPS}" pattern="^domain.com$" />
</conditions>
<action type="Redirect" url="https://www.domain.com/{R:0}" redirectType="Permanent" />
यह गैर- SSL यूआरएल के लिए पूरी तरह से काम करता है लेकिन ssl के मामले में यह https://domain.com से http://www.domain.com
को अनुप्रेषित कृपया सहायता से आप अपने नियम को दूर करने के।
पहला नियम दोनों अनुरोधों के प्रकार को पकड़ता है और दूसरा संसाधित नहीं किया जाएगा – Dima