opencart谷歌网站地图vqmod错误。

问题描述 投票:1回答:2

我试图提交一个谷歌网站地图在谷歌网站管理员工具,但运行到错误。在管理中,我点击了扩展>>产品饲料和启用谷歌网站地图选项。它为我提供了网站地图的链接,但当我提交的链接到谷歌网站管理员工具,它不喜欢它,并返回以下错误。

Unsupported file format
Your Sitemap does not appear to be in a supported format. Please ensure it meets our Sitemap guidelines and resubmit.

这里是我使用的URL。http:/www.techcertsolutions.comindex.php?route=feedgoogle_sitemap

错误:当我从google网站管理员工具中点击sitemap链接时,我看到以下信息。

Notice: Undefined index: limit in /home7/jardinf1/public_html/techcertsolutions/vqmod/vqcache/vq2-catalog_model_catalog_product.php on line 440

我检查了 .htaccess 文件,并在文件中看到以下条目。

RewriteRule ^sitemap.xml$ index.php?route=feed/google_sitemap [L]

所以我不知道这里到底发生了什么. 我也删除了 vqcache 并再次尝试,但没有成功。请给我一些建议。

opencart xml-sitemap
2个回答
0
投票

你的一个vQmod的编辑 /catalog/model/catalog/product.php 文件,并且由于某种原因没有设置 limit 的查询,或者是google sitemap代码没有设置限制,应该是。


-1
投票

如果有人还遇到这样的问题,有一个解决方案。

找一个文件

/catalog/controller/feed/google_sitemap.php. Open it and edit it, then just replace where it says"$products = $this->model_catalog_product->getProducts(array('filter_category_id' => $result['category_id']));"

对于

$total_ = $this->model_catalog_product->getTotalProducts();
                $data = array('start' => 0, 'limit' => $total_);
$products = $this->model_catalog_product->getProducts(array('filter_category_id' => $result['category_id'], 'start' => 0, 'limit' => $total_));
© www.soinside.com 2019 - 2024. All rights reserved.