I agree; it's something to do with using the php form of invocation for the cron-job. Try the following instead:
GET 'https://your_domain/index.php?main_page=sitemapxml&rebuild=yes'
Printable View
Hello, another one short notice...
As in "box_news" table all datetime columns (not only 'news_modified_date') can be NULL, it would be wise to use IFNULL function also for checking 'news_published_date' column in sql-queries in includes\modules\pages\sitemapxml\sitemapxml_boxnews.php file:
This will help to avoid PHP-warnings by passing NULL as parameterCode:echo '<h3>' . TEXT_HEAD_BOXNEWS . '</h3>';
$last_date = $db->Execute(
"SELECT MAX(GREATEST(n.news_added_date, IFNULL(n.news_modified_date, '0001-01-01 00:00:00'), IFNULL(n.news_published_date, '0001-01-01 00:00:00'))) AS last_date
FROM " . TABLE_BOX_NEWS . " n
WHERE n.news_status = 1
AND NOW() BETWEEN n.news_start_date AND n.news_end_date"
);
$table_status = $db->Execute("SHOW TABLE STATUS LIKE '" . TABLE_BOX_NEWS . "'");
$last_date = max($table_status->fields['Update_time'], $last_date->fields['last_date']);
if ($sitemapXML->SitemapOpen('boxnews', $last_date)) {
$news = $db->Execute(
"SELECT n.box_news_id, GREATEST(n.news_added_date, IFNULL(n.news_modified_date, '0001-01-01 00:00:00'), IFNULL(n.news_published_date, '0001-01-01 00:00:00')) AS last_date, nc.languages_id AS language_id
FROM " . TABLE_BOX_NEWS . " n
INNER JOIN " . TABLE_BOX_NEWS_CONTENT . " nc
ON n.box_news_id = nc.box_news_id
AND nc.languages_id IN (" . $sitemapXML->getLanguagesIDs() . ")
AND nc.news_title != ''
WHERE n.news_status = 1
AND NOW() BETWEEN n.news_start_date AND n.news_end_date" .
(SITEMAPXML_BOXNEWS_ORDERBY !== '' ? ' ORDER BY ' . SITEMAPXML_BOXNEWS_ORDERBY : '')
);
$sitemapXML->SitemapSetMaxItems($news->RecordCount());
foreach ($news as $next_item) {
$sitemapXML->writeItem(FILENAME_MORE_NEWS, 'news_id=' . $next_item['box_news_id'], $next_item['language_id'], $next_item['last_date'], SITEMAPXML_BOXNEWS_CHANGEFREQ);
}
$sitemapXML->SitemapClose();
unset($news);
}
As "box_news" table is an 'external' table for this addon (created in another module), no additional verification can be excessive, I think
Yet another GitHub issue opened: https://github.com/lat9/sitemapxml/issues/53
I have even more...Quote:
Yet another GitHub issue opened
As $from and $where variables can be not empty in 'includes/modules/pages/sitemapxml/sitemapxml_ezpages.php' file after fixing the bug with using of quotes for TABLE_EZPAGES_TEXT constant (see earlier correspondence in this tread), "p." prefix must be added to all columns belonging to TABLE_EZPAGES table in all sql-queries, for ex:
Code:$page_query_sql =
"SELECT p.toc_chapter
FROM " . TABLE_EZPAGES . " p " . $from . "
WHERE p.alt_url_external = ''
AND (
(p.status_header = 1 AND p.header_sort_order > 0)
OR (p.status_sidebox = 1 AND p.sidebox_sort_order > 0)
OR (p.status_footer = 1 AND p.footer_sort_order > 0)
)
AND p.status_toc != 0" .
$where . "
GROUP BY p.toc_chapter";
I'm using Firefox at the moment and a new sitemap can't be created.
The popup is being openend and the Url within looks ok but the content of the popup is just blank page and the sitemap is not being re-generated.
Unfortunately I can't use chromium at the moment to have the job done.
Is this a known issue?
A log file should be generated as it sounds like a partial blank page.
https://docs.zen-cart.com/user/troub...ng/blank_page/
You're right. There's one:
Code:PHP Fatal error: Uncaught Error: Undefined constant "NAVBAR_TITLE" in /includes/modules/pages/sitemapxml/header_php.php:28
Stack trace:
#0 /index.php(36): require()
#1 {main}
thrown in /includes/modules/pages/sitemapxml/header_php.php on line 28
I now understand this is not a known issue.
I'm using the PHP 8.3 compatible European branch for German language version (1.5.7h)
I wrote a bug report at github