LuanMartinsTI 0 Denunciar post Postado Março 22, 2017 Fala galera blz, então estou com um problema para converter um arquivo htaccess para web.config, não é muito minha are, eu queria transformar o seguinte codigo htaccess RewriteEngine On RewriteRule ^upload$ upload_photo.php [NC,END] RewriteRule ^index$ index.php [NC,END] RewriteRule ^teste$ teste2.php [NC,END] RewriteRule ^public/preview/([0-9]+)-([0-9]+).png public/preview/$1-$2.png [NC,END] RewriteRule ^public/purchased/([0-9]+)-([0-9]+).png fetch_photo.php?userId=$1&photoId=$2&tmb=0 [NC,END] RewriteRule ^public/purchased/([0-9]+)-([0-9]+)_small.png fetch_photo.php?userId=$1&photoId=$2&tmb=1 [NC,END] RewriteRule ^crossdomain.xml$ crossdomain.xml [NC,END] # Else RewriteRule ^(.*)$ - [R=404] em um web config, eu fiz da seguinte forma, mas não funcionou <?xml version="1.0" encoding="UTF-8"?> <configuration> <system.webServer> <rewrite> <rules> <rule name="rule 1N" stopProcessing="true"> <match url="^upload$" ignoreCase="true" /> <action type="Rewrite" url="/upload_photo.php" appendQueryString="true" /> </rule> <rule name="rule 2N" stopProcessing="true"> <match url="^preview/([0-9]+)-([0-9]+).png" ignoreCase="true" /> <action type="Rewrite" url="/public/preview/{R:1}-{R:2}.png" /> </rule> <rule name="rule 3N" stopProcessing="true"> <match url="^purchased/([0-9]+)-([0-9]+).png" ignoreCase="true" /> <action type="Rewrite" url="/fetch_photo.php?userId={R:1}&photoId={R:2}&tmb=0" /> </rule> <rule name="rule 4N" stopProcessing="true"> <match url="^purchased/([0-9]+)-([0-9]+)_small.png" ignoreCase="true" /> <action type="Rewrite" url="/fetch_photo.php?userId={R:1}&photoId={R:2}&tmb=1" /> </rule> <rule name="rule 5N" stopProcessing="true"> <match url="^crossdomain.xml$" ignoreCase="true" /> <action type="Rewrite" url="/crossdomain.xml" /> </rule> <rule name="rule 6N"> <match url="^(.*)$" /> <action type="CustomResponse" statusCode="404" subStatusCode="404" statusReason="Not Found" /> </rule> </rules> </rewrite> </system.webServer> </configuration> e me desculpem se está no local errado, vi html e pensei é o mais perto de XML Compartilhar este post Link para o post Compartilhar em outros sites