Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add IIS compatibility; requires url_rewrite module; thanks to Todd Gi…
…ardina, Todd's IT
- Loading branch information
Showing
2 changed files
with
82 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<configuration> | ||
<system.webServer> | ||
<rewrite> | ||
<rules> | ||
<rule name="HTTP/S to HTTPS Redirect" enabled="false" stopProcessing="true"> | ||
<match url="(.*)" /> | ||
<conditions logicalGrouping="MatchAny"> | ||
<add input="{HTTPS}" pattern="OFF$" /> | ||
</conditions> | ||
<action type="Redirect" url="https://{HTTP_HOST}/{R:1}" redirectType="Permanent" /> | ||
</rule> | ||
<rule name="Move from subfolder to root" enabled="false" stopProcessing="true"> | ||
<match url="^testfolder/(.*)$" /> | ||
<action type="Redirect" url="/{R:1}" redirectType="Permanent" /> | ||
</rule> | ||
<rule name="Change to www." enabled="false" stopProcessing="true"> | ||
<match url="^(.*)$" ignoreCase="false" /> | ||
<conditions logicalGrouping="MatchAll"> | ||
<add input="{HTTP_HOST}" pattern="^example\.com$" /> | ||
</conditions> | ||
<action type="Redirect" url="http://www.example.com/{R:1}" redirectType="Permanent" /> | ||
</rule> | ||
<rule name="Remove www." enabled="false" stopProcessing="true"> | ||
<match url="^(.*)$" ignoreCase="false" /> | ||
<conditions logicalGrouping="MatchAll"> | ||
<add input="{HTTP_HOST}" pattern="^www\.example\.com$" /> | ||
</conditions> | ||
<action type="Redirect" url="http://example.com/{R:1}" redirectType="Permanent" /> | ||
</rule> | ||
<rule name="Convert index.html call"> | ||
<match url="^$" ignoreCase="false" /> | ||
<action type="Rewrite" url="index.html" appendQueryString="true" /> | ||
</rule> | ||
<rule name="Convert *.html call"> | ||
<match url="^([^.]+)$" ignoreCase="false" /> | ||
<action type="Rewrite" url="{R:1}.html" appendQueryString="true" /> | ||
</rule> | ||
<rule name="Psuedo login.php" enabled="false"> | ||
<match url="^login.php$" ignoreCase="false" /> | ||
<action type="Rewrite" url="login/showlogin" /> | ||
</rule> | ||
<rule name="Main SEF URL Rule" stopProcessing="true"> | ||
<match url="^(.*)$" ignoreCase="false" /> | ||
<conditions logicalGrouping="MatchAll"> | ||
<add input="{URL}" pattern="\.(css|js|pdf|shtml|htc)$" negate="true" /> | ||
<add input="{URL}" pattern="\.(jp?g|gif|png|tiff)$" negate="true" /> | ||
<add input="{URL}" pattern="\.(mp3|mp4|webm|ogv|flv|f4v)$" negate="true" /> | ||
<add input="{URL}" pattern="^/robots\.txt$" negate="true" /> | ||
<add input="{URL}" pattern="^/favicon\.ico$" negate="true" /> | ||
<add input="{REQUEST_FILENAME}" matchType="IsFile" ignoreCase="false" negate="true" /> | ||
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" ignoreCase="false" negate="true" /> | ||
</conditions> | ||
<action type="Rewrite" url="index.php" appendQueryString="true" /> | ||
</rule> | ||
</rules> | ||
</rewrite> | ||
<defaultDocument> | ||
<files> | ||
<clear /> | ||
<add value="index.php" /> | ||
</files> | ||
</defaultDocument> | ||
<httpErrors> | ||
<remove statusCode="500" subStatusCode="-1" /> | ||
<remove statusCode="404" subStatusCode="-1" /> | ||
<remove statusCode="403" subStatusCode="-1" /> | ||
<error statusCode="403" prefixLanguageFilePath="" path="/index.php?controller=notfound&action=handle_not_authorized&error=403" responseMode="ExecuteURL" /> | ||
<error statusCode="404" prefixLanguageFilePath="" path="/index.php?controller=notfound&action=handle&error=404" responseMode="ExecuteURL" /> | ||
<error statusCode="500" prefixLanguageFilePath="" path="/index.php?controller=notfound&action=handle_internal_error&error=500" responseMode="ExecuteURL" /> | ||
</httpErrors> | ||
<staticContent> | ||
<remove fileExtension=".woff" /> | ||
<mimeMap fileExtension=".woff" mimeType="application/font-woff" /> | ||
</staticContent> | ||
</system.webServer> | ||
</configuration> |