<?php
require __DIR__ . '/includes/site.php';
header('Content-Type: application/xml; charset=utf-8');
$paths = ['/', '/about/', '/topics/', '/authors/', '/contact/', '/category/video-tutorial/', '/category/life-video/', '/category/industry-observation/'];
foreach (article_data() as $article) { $paths[] = $article['path']; }
echo '<?xml version="1.0" encoding="UTF-8"?>' . "\n";
?>
<urlset xmlns="<?php echo e(sitemap_namespace()); ?>">
<?php foreach ($paths as $path): ?>
  <url>
    <loc><?php echo e(site_url($path)); ?></loc>
    <lastmod><?php echo e(iso_today()); ?></lastmod>
    <changefreq><?php echo $path === '/' ? 'daily' : 'weekly'; ?></changefreq>
    <priority><?php echo $path === '/' ? '1.0' : '0.8'; ?></priority>
  </url>
<?php endforeach; ?>
</urlset>
