function get_cached_youtube_videos() {

    $cache_file = get_template_directory() . '/yt-cache.json';

    // 🔥 Cache 10 minutes
    if (file_exists($cache_file) && (time() - filemtime($cache_file)) < 600) {
        return json_decode(file_get_contents($cache_file), true);
    }

    $rss = "https://www.youtube.com/feeds/videos.xml?channel_id=UCPl2JKCzGWp39DBFVzOHaoQ";

    $xml = @simplexml_load_file($rss);

    $videos = [];

    if ($xml) {
        foreach ($xml->entry as $entry) {

            $videos[] = [
                'title' => (string)$entry->title,
                'id'    => (string)$entry->children('yt', true)->videoId
            ];

        }
    }

    // Save cache
    file_put_contents($cache_file, json_encode($videos));

    return $videos;
}<?xml version="1.0" encoding="UTF-8"?><?xml-stylesheet type="text/xsl" href="//channeldurjoy.com/wp-content/plugins/wordpress-seo/css/main-sitemap.xsl"?>
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
	<sitemap>
		<loc>https://channeldurjoy.com/post-sitemap.xml</loc>
		<lastmod>2026-07-11T09:14:02+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://channeldurjoy.com/page-sitemap.xml</loc>
		<lastmod>2026-07-10T16:42:00+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://channeldurjoy.com/bs_templates-sitemap.xml</loc>
		<lastmod>2026-07-10T07:54:00+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://channeldurjoy.com/category-sitemap.xml</loc>
		<lastmod>2026-07-11T09:14:02+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://channeldurjoy.com/post_tag-sitemap.xml</loc>
		<lastmod>2026-07-10T14:29:28+00:00</lastmod>
	</sitemap>
	<sitemap>
		<loc>https://channeldurjoy.com/author-sitemap.xml</loc>
		<lastmod>2026-07-10T05:59:31+00:00</lastmod>
	</sitemap>
</sitemapindex>
<!-- XML Sitemap generated by Yoast SEO -->