<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9
                            http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd">
    <url>
        <loc>https://www.theboywhofoundgoldbook.com/</loc>
        <lastmod>2025-08-21T07:16:00+00:00</lastmod>
        <changefreq>weekly</changefreq>
        <priority>1.00</priority>
    </url>
    <url>
        <loc>https://www.theboywhofoundgoldbook.com/about.html</loc>
        <lastmod>2025-08-18T14:26:43+00:00</lastmod>
        <changefreq>monthly</changefreq>
        <priority>0.80</priority>
    </url>
    <url>
        <loc>https://www.theboywhofoundgoldbook.com/buy.html</loc>
        <lastmod>2025-08-18T14:29:06+00:00</lastmod>
        <changefreq>monthly</changefreq>
        <priority>0.80</priority>
    </url>
    <url>
        <loc>https://www.theboywhofoundgoldbook.com/contest.html</loc>
        <lastmod>2025-08-18T14:32:51+00:00</lastmod>
        <changefreq>monthly</changefreq>
        <priority>0.80</priority>
    </url>
    <url>
        <loc>https://www.theboywhofoundgoldbook.com/entry.html</loc>
        <lastmod>2025-08-16T20:39:34+00:00</lastmod>
        <changefreq>monthly</changefreq>
        <priority>0.80</priority>
    </url>
    <url>
        <loc>https://www.theboywhofoundgoldbook.com/mediakits.html</loc>
        <lastmod>2025-08-18T14:38:40+00:00</lastmod>
        <changefreq>monthly</changefreq>
        <priority>0.80</priority>
    </url>
    <url>
        <loc>https://www.theboywhofoundgoldbook.com/blog.php</loc>
        <lastmod>2025-08-18T14:40:49+00:00</lastmod>
        <changefreq>weekly</changefreq>
        <priority>0.80</priority>
    </url>
    <url>
        <loc>https://www.theboywhofoundgoldbook.com/contact.html</loc>
        <lastmod>2025-08-18T14:30:43+00:00</lastmod>
        <changefreq>monthly</changefreq>
        <priority>0.80</priority>
    </url>
    <!-- Add blog posts dynamically -->
    <?php
    require_once 'Blog/database.php';
    $posts = getBlogPostsForSitemap(); // Custom function to retrieve posts
    foreach ($posts as $post) {
        echo "<url>\n";
        echo "    <loc>https://www.theboywhofoundgoldbook.com/read.php?slug=" . urlencode($post['slug']) . "</loc>\n";
        echo "    <lastmod>" . date('c', strtotime($post['date'])) . "</lastmod>\n";
        echo "    <changefreq>weekly</changefreq>\n";
        echo "    <priority>0.70</priority>\n";
        echo "</url>\n";
    }
    ?>
</urlset>