有誰知道如果谷歌會懲罰一個網站,如果主頁(帶或不帶尾部斜線)返回200正確的標題響應?搜索引擎優化 - 重定向主頁或根網址 - 追蹤斜槓
我已經使用在線重定向檢查器(CNN,紐約時報,福克斯新聞,維基百科等等)測試了大量網站,並且它們都返回200「ok」,帶有或不帶有斜線。
我知道所有的內部頁面都需要使用其中一個或另一個,但是看起來主頁是個例外。你們都在想什麼?
PS,我在IIS7中使用URLRewrite來強制www,小寫,並刪除尾部斜線。看起來主頁是唯一不受尾部斜槓規則影響的頁面。
謝謝!
編輯 例如,使用這個在線工具:http://www.internetofficer.com/seo-tool/redirect-check/ 下列網址是「直接聯繫」。兩者都不是301重定向... http://www.wikipedia.org http://www.wikipedia.org/
許多其他示例產生相同的結果。
EDIT 2 這裏是我的URLRewrite代碼(web.config中)
<rules>
<rule name="CanonicalHostNameRule1" stopProcessing="true">
<match url="(.*)" />
<conditions>
<add input="{HTTP_HOST}" pattern="^www\.domain\.com$" negate="true" />
</conditions>
<action type="Redirect" redirectType="Permanent" url="http://www.kurtzandblum.com/{R:1}" />
</rule>
<rule name="LowerCaseRule1" stopProcessing="true">
<match url="[A-Z]" ignoreCase="false" />
<action type="Redirect" redirectType="Permanent" url="{ToLower:{URL}}" />
</rule>
<rule name="Remove trailing slash" stopProcessing="true">
<match url="(.*)/$" />
<conditions>
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
</conditions>
<action type="Redirect" redirectType="Permanent" url="{R:1}" />
</rule>
</rules>
感謝您的回覆。我正在刪除尾部的斜槓。但是,301重定向不會在主頁上發生。它只適用於子頁面/文件夾。我正在使用ASP.NET的推薦URLRewrite代碼。我已經在上面添加了它。 – 2012-07-06 03:32:47