I seem to be having a duplicate error when creating a XML site map for Google. It does not like the language_code=fr, language_code=fi etc. If i delete all the URLs with the language code in then the site map is accepted, it means going through every product and deleting every language code manually or have I missed some settings again?
sitemap1.xml Sitemap Feb 1, 2012 1,956 errors Web 5,660 Pending
Thank you
tuck
1 Feb 2012 3:30 PM
Quick fix
in admin/admin_site_map_xml_build.php
line 53
change
$sql = "SELECT language_code FROM " . $table_prefix . "languages WHERE show_for_user = '1' ";
To
$sql = "SELECT language_code FROM " . $table_prefix . "languages WHERE language_name = '' ";
I am sure there is a better way but don't have time to look into it at the moment may be Viart support can provide a better way
Thank you
quick edit
I have just realised that it generates some of the products twice
I will spend a bit of time on this to see if i can find a better way
Last modified: 1 Feb 2012 4:29 PM
karakash
1 Feb 2012 4:43 PM
Making it null added all the languages into sitemap which I have disabled.
Anyhow I found the solution for my specific problem. I disabled the English language too.
If your site is setup for single language, you need to disable every language including the default from Settings > System > Static Tables > Languages
karakash
1 Feb 2012 4:45 PM
I need to edit .htaccess to stop urls working with ?language_code=en parameters. Otherwise no use of removing them from the sitemap.