Jump to content
  • разработка интернет магазинов на opencart
  • доработка интернет магазинов на opencart

Recommended Posts

Добрый гдень, воюю с гуглом, ссылку со стокового модуля не принимает, пишет ошибку 

Похоже, что файл Sitemap является страниэтот HTML. Используйте подгдерживаемый формат Sitemap.

Создала отгдельный файл 

<?php
require_once('config.php');

$siteMapSource = HTTPS_SERVER . 'index.php?route=extension/feed/google_sitemap';
$xml = file_get_contents($siteMapSource);
$siteMapContent = simplexml_load_string($xml);
 
if (!file_put_contents('sitemap.xml', $siteMapContent->asXML())) {
    error_log(date('Y-m-d H:i:s - ', time()) . 'Unable to save Google content into the file' ."\n", 3, DIR_LOGS . 'sitemap.txt');
    die('Google Sitemap data export process has been failed!');   
} else { echo 'Google Sitemap update has been successfully completed!'; } 
 
?>

при обраещёнии напрямую к файлу все в порядке, кари создалась, проблем нет, но при отправке url гуглу опять те же самые ошибки 

Link to comment
Share on other sites


Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

On our site, cookies are used and personal data is processed to improve the user interface. To find out what and what personal data we are processing, please go to the link. If you click "I agree," it means that you understand and accept all the conditions specified in this Privacy Notice.