Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/.htaccess/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
.htaccess SEO-这个url重写会索引特定的图像吗?_.htaccess_Url Rewriting_Google Image Search_Google Index - Fatal编程技术网

.htaccess SEO-这个url重写会索引特定的图像吗?

.htaccess SEO-这个url重写会索引特定的图像吗?,.htaccess,url-rewriting,google-image-search,google-index,.htaccess,Url Rewriting,Google Image Search,Google Index,例如,如果我有特定图像的URL,如(服务器上不存在): domain.com/news/12/imgname.jpg 我需要动态生成并向最终用户显示它,我将使用一些htaccess重写以前的url,以: domain.com/image.php?img=12/imgname 我的问题是:图像imgname.jpg是否会被搜索引擎索引(在这种情况下,image.php将始终返回动态生成的相同图像)?您是在重写还是重定向?是否要为其编制索引?如果你想要的话,robots.txt文件可以阻止它被索引。

例如,如果我有特定图像的URL,如(服务器上不存在):

domain.com/news/12/imgname.jpg

我需要动态生成并向最终用户显示它,我将使用一些htaccess重写以前的url,以:

domain.com/image.php?img=12/imgname


我的问题是:图像
imgname.jpg
是否会被搜索引擎索引(在这种情况下,image.php将始终返回动态生成的相同图像)?

您是在重写还是重定向?是否要为其编制索引?如果你想要的话,robots.txt文件可以阻止它被索引。我正在重写。我希望生成的图像被索引,但不保存在服务器上:)如果您正在重写,那么所有内容都是Web服务器内部的,并且图像将按照搜索引擎对任何图像使用的相同条件进行索引。