2011-04-17 49 views
0

自从我添加了一个.htaccess文件后,我遇到了这个网站的问题。谷歌机器人不抓取新的链接。.htaccess和谷歌爬虫错误

这里是我的htaccess:

Options +FollowSymlinks 
RewriteEngine On 

RewriteCond %{HTTP_HOST} !^www.grantsimeonphoto.com$ 
RewriteRule ^(.*)$ http://www.grantsimeonphoto.com/$1 [R=301] 

RewriteRule ^accueil$  index.php?page=accueil 
RewriteRule ^services$ index.php?page=services 
RewriteRule ^portfolio$ index.php?page=portfolio 
RewriteRule ^contact$  index.php?page=contact 
RewriteRule ^epreuves$ index.php?page=epreuves 

,如果你做对谷歌搜索,你会看到:

site:grantsimeonphoto.com 

here is my robot.txt: 
User-agent: * 
Allow:/

这里是我的sitemap.xml:

<?xml version="1.0" encoding="UTF-8"?> 
<urlset 
     xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" 
     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
     xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9 
      http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd"> 
<!-- created with Free Online Sitemap Generator www.xml-sitemaps.com --> 

<url> 
    <loc>http://www.grantsimeonphoto.com/</loc> 
    <priority>1.00</priority> 
</url> 
<url> 
    <loc>http://www.grantsimeonphoto.com/accueil</loc> 
    <priority>0.80</priority> 
</url> 
<url> 
    <loc>http://www.grantsimeonphoto.com/services</loc> 
    <priority>0.80</priority> 
</url> 
<url> 
    <loc>http://www.grantsimeonphoto.com/portfolio</loc> 
    <priority>0.80</priority> 
</url> 
<url> 
    <loc>http://www.grantsimeonphoto.com/contact</loc> 
    <priority>0.80</priority> 
</url> 
<url> 
    <loc>http://www.grantsimeonphoto.com/epreuves</loc> 
    <priority>0.80</priority> 
</url> 
</urlset> 

感谢帮助

+0

不是答案,但是您的robots.txt没有配置,因为没有'只允许''不允许'。所以你的语法应该是:'不允许:'(没有任何跟随它)。另外,您可以在robot.txt中引用您的XML站点地图以获得更多曝光。 – 2011-04-17 07:23:02

+0

即使Allow不在基本的robots.txt规范中,Allow仍然是常用的(并且可以通过google了解),即:http://www.google.com/robots.txt这样就不是问题 – 2011-04-20 07:01:45

+0

嗨,可以只是,.htaccess重定向不起作用,请参阅:http://www.grantsimeonphoto.com/index.php?page=services HTTP 200,http://www.grantsimeonphoto.com/accueil HTTP 404 .. 。所以谷歌将不会索引新页面,因为它们是HTTP 404。 – 2011-04-20 07:03:33

回答

0

呦你可以尝试通过Google Webmaster Central重新提交你的站点地图。

而且您的多个重写规则应该被合并为1这样的:

RewriteRule ^(accueil|services|portfolio|contact|epreuves)$ /index.php?page=$1 [L,NC,QSA,NE] 

同样重要的是采用L,QSA和NC国旗上述规则。

1

您不需要添加允许,通常所有的搜索引擎都会抓取您的链接,当它没有明确禁止指定的URL。