<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <system.webServer>
        <rewrite>
            <rules>
                <rule name="Imported Rule 1" stopProcessing="true">
                    <match url="^(.*)index.php$" ignoreCase="false" />
                    <conditions logicalGrouping="MatchAll">
                        <add input="{THE_REQUEST}" pattern="^.*/index\.php" ignoreCase="false" />
                    </conditions>
                    <action type="Redirect" url="/{R:1}" redirectType="Permanent" />
                </rule>
                <rule name="Imported Rule 2" stopProcessing="true">
                    <match url="^admin/(.*)$" ignoreCase="false" />
                    <conditions logicalGrouping="MatchAll">
                        <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="admin/index.php?route={R:1}" appendQueryString="false" />
                </rule>
                <rule name="Imported Rule 3" stopProcessing="true">
                    <match url="^twitter/login(.*)$" ignoreCase="false" />
                    <conditions logicalGrouping="MatchAll">
                        <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?route=twitter/login" appendQueryString="true" />
                </rule>
                <rule name="Imported Rule 6" stopProcessing="true">
                <match url="^twitter-card-generator(.*)$" ignoreCase="false" />
                <conditions logicalGrouping="MatchAll">
                <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?route=twitter-card-generator" appendQueryString="true" />
                </rule>
                <rule name="Imported Rule 4" stopProcessing="true">
                    <match url="^twitter(.*)$" ignoreCase="false" />
                    <action type="Rewrite" url="index.php?route=twitter" appendQueryString="true" />
                </rule>
                <rule name="Imported Rule 5" stopProcessing="true">
                    <match url="^(.*)$" ignoreCase="false" />
                    <conditions logicalGrouping="MatchAll">
                        <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?route={R:1}" appendQueryString="false" />
                </rule>
            </rules>
        </rewrite>
    </system.webServer>
</configuration>
