• Resolved sibermedya

    (@sibermedya)


    Hi,

    I have windows server 2025 and IIS web server with Php 8.4 and Imagick- GD.

    i tested all Image loading mode

    your plugin manuel convert images to wp-content\uploads-webpc folder

    How can i your plugin on windows server IIs

Viewing 7 replies - 1 through 7 (of 7 total)
  • Thread Starter sibermedya

    (@sibermedya)

    <rule name="WebP Rewrite" enabled="true" stopProcessing="false">
    <match url="wp-content/uploads/(.*)\.(jpg|jpeg|png)$" />
    <conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
    <action type="Rewrite" url="wp-content/uploads-webpc/uploads/{R:1}.{R:2}.webp" />
    </rule>

    Windows IIS rewrite rule

    Plugin Author Mateusz Gbiorczyk

    (@mateuszgbiorczyk)

    Hi @sibermedya,

    Thank you for your message.

    Please tell me if your solution worked?

    Best,
    Mateusz

    Thread Starter sibermedya

    (@sibermedya)

    yes, Windows IIS rewrite rule worked.

    Image loading mode: via .htaccess / Nginx (recommended)

    only still alert message wp control panel

    Server configuration error

    Error codes: rewrites_cached

    Plugin Author Mateusz Gbiorczyk

    (@mateuszgbiorczyk)

    Thank you for confirming, @sibermedya! This is a completely different error. Did you understand the instructions in this error message?

    Thread Starter sibermedya

    (@sibermedya)

    plugin support linux but not full support Windows iis.

    Thread Starter sibermedya

    (@sibermedya)

    I have good news. I found the settings and code that work flawlessly under Windows Server and IIS.

    Now work without any message or warning like Nginx

    Image loading mode: via .htaccess / Nginx (recommended)

    output formats: WebP

    I can not test AVIF format (available in the PRO version)

    Windows IIS rewrite rule in web.config file

    <?xml version="1.0" encoding="UTF-8"?>
    <configuration>
    <system.webServer>

    <httpProtocol>
    <customHeaders>
    <add name="Vary" value="Accept" />
    <add name="Cache-Control" value="private" />
    </customHeaders>
    </httpProtocol>

    <staticContent>
    <clientCache cacheControlMode="UseMaxAge" cacheControlCustom="private" cacheControlMaxAge="1.00:00:00" />
    </staticContent>

    <rewrite>
    <rules>

    <rule name="Serve AVIF if supported" stopProcessing="true">
    <match url="^wp-content/(.+)\.(jpg|jpeg|png|gif)$" ignoreCase="true" />
    <conditions logicalGrouping="MatchAll" trackAllCaptures="true">
    <add input="{HTTP_ACCEPT}" pattern="image/avif" />
    <add input="{APPL_PHYSICAL_PATH}wp-content\uploads-webpc\{R:1}.{R:2}.avif" matchType="IsFile" />
    </conditions>
    <action type="Rewrite" url="wp-content/uploads-webpc/{R:1}.{R:2}.avif" />
    </rule>

    <rule name="Serve WebP if supported" stopProcessing="true">
    <match url="^wp-content/(.+)\.(jpg|jpeg|png|gif)$" ignoreCase="true" />
    <conditions logicalGrouping="MatchAll" trackAllCaptures="true">
    <add input="{HTTP_ACCEPT}" pattern="image/webp" />
    <add input="{APPL_PHYSICAL_PATH}wp-content\uploads-webpc\{R:1}.{R:2}.webp" matchType="IsFile" />
    </conditions>
    <action type="Rewrite" url="wp-content/uploads-webpc/{R:1}.{R:2}.webp" />
    </rule>

    </rules>
    </rewrite>

    </system.webServer>
    </configuration>

    • This reply was modified 6 months ago by sibermedya.
    • This reply was modified 6 months ago by sibermedya.
    • This reply was modified 6 months ago by sibermedya.
    • This reply was modified 6 months ago by sibermedya.
    • This reply was modified 6 months ago by sibermedya.
    Plugin Author Mateusz Gbiorczyk

    (@mateuszgbiorczyk)

    Thank you very much for your commitment, @sibermedya. I appreciate you sharing the solution here. It will definitely be useful to others.

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘Windows Server IIS Support?’ is closed to new replies.