Page 1 of 1

Sitemap to submit to Google Webmaster Tools

Posted: Tue May 26, 2020 5:21 am
by YarniaPDX
Can someone point me in the right direction for how to find/create the sitemap for my site (https://customyarn.com), in order to submit it to Google Webmaster Tools?

Thanks so much!
- Lindsey

Re: Sitemap to submit to Google Webmaster Tools

Posted: Tue May 26, 2020 5:36 am
by sw!tch
Admin -> Extensions -> Feeds -> Google Sitemap.

Then you get to it by. https://www.customyarn.com/index.php?ro ... le_sitemap

Re: Sitemap to submit to Google Webmaster Tools

Posted: Tue May 26, 2020 12:57 pm
by cedcommerceteam
YarniaPDX wrote:
Tue May 26, 2020 5:21 am
Can someone point me in the right direction for how to find/create the sitemap for my site (https://customyarn.com), in order to submit it to Google Webmaster Tools?

Thanks so much!
- Lindsey
Hello there,

Hope you are doing well.

The first step is to go to your OpenCart admin and go to Extensions and then Extensions again.

Click the dropdown and select Feeds.

You will see the Google Sitemap extension. Hit the install button and then click Edit.

The first field is to just enable and disable the status of the sitemap. The second field is to enter the data feed URL.

Or

You can choose modules by visiting following link -

https://www.opencart.com/index.php?rout ... ch=sitemap

Thanks!!!

Re: Sitemap to submit to Google Webmaster Tools

Posted: Tue May 26, 2020 1:16 pm
by letxobnav
The second field is to enter the data feed URL
There is nothing to enter, the sitemap url is fixed to the controller unless you adjust it via htaccess.

Re: Sitemap to submit to Google Webmaster Tools

Posted: Tue May 26, 2020 3:21 pm
by uksitebuilder
If you have enabled SEO URLs in your website and have therefore already enabled the .htaccess file, you can also access your sitemap, once enabled in the settings, by visiting yourdomain.com/sitemap.xml as there is already a rewrite rule in the default opencart htaccess for that.

If you want more control over your sitemap, there are extensions available in the OpenCart Marketplace to do that.

Re: Sitemap to submit to Google Webmaster Tools

Posted: Tue May 26, 2020 7:12 pm
by paulfeakins
If you have a lot of products and categories it can be possible that sitemap.xml loads too slowly for Google, in which case you'll need to cache it.

Re: Sitemap to submit to Google Webmaster Tools

Posted: Sun May 31, 2020 6:56 am
by YarniaPDX
Thanks! I enabled the sitemap and can view it here:

https://www.customyarn.com/index.php?ro ... le_sitemap

However, when I submit it to Google, it tells me the sitemap could not be read (see screenshot). What am I doing wrong?

Re: Sitemap to submit to Google Webmaster Tools

Posted: Sun May 31, 2020 9:08 am
by letxobnav
Suggest you reduce your sitemap first.
Default OC sitemap duplicates product urls, it lists the product urls excluding the category path (canonical) as well as the product url including the category path. The latter is useless and only makes your sitemap needlessly big.

Re: Sitemap to submit to Google Webmaster Tools

Posted: Wed Jun 03, 2020 4:11 am
by YarniaPDX
That makes sense, but how do I reduce the sitemap?

Re: Sitemap to submit to Google Webmaster Tools

Posted: Wed Jun 03, 2020 12:52 pm
by letxobnav
by removing this part:

Code: Select all

			$products = $this->model_catalog_product->getProducts(array('filter_category_id' => $result['category_id']));

			foreach ($products as $product) {
				$output .= '<url>';
				$output .= '  <loc>' . $this->url->link('product/product', 'path=' . $new_path . '&product_id=' . $product['product_id']) . '</loc>';
				$output .= '  <changefreq>weekly</changefreq>';
				$output .= '  <priority>1.0</priority>';
				$output .= '</url>';
			}
from catalog/controller/extension/feed/google_sitemap.php