Central de Ajuda DigiHost

Configurando o arquivo web.config URLs amigáveis no painel de controle Plesk  Imprimir este Artigo

165 visualizações

Configurando o arquivo web.config. Por padrão ele se encontra dentro da pasta httpdocs.

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
      <system.webServer>
            <defaultDocument>
                  <files>
                       <clear />
                       <add value="index.php" />
                  </files>
            </defaultDocument>
            <rewrite>
                   <rules>
                         <clear />
                         <rule name="WordPress Rule" stopProcessing="true">
                               <match url=".*" />
                               <conditions logicalGrouping="MatchAll" trackAllCaptures="false">
                                      <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
                                      <add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
                               </conditions>
                               <action type="Rewrite" url="index.php" />
                         </rule>
                    </rules>
                    <outboundRules>
                           <clear />
                    </outboundRules>
              </rewrite>
       </system.webServer>
</configuration>

Com o uso de URLs amigáveis você consegue deixar seu site mais legível para os usuários e assim também otimiza o SEO (torna o site mais bem reputado pelo Google e demais motores de busca)

Esta resposta lhe foi útil?

Veja também