/**
 * Plugin Name: SEO Internal Breadcrumbs
 * Description: Adds breadcrumb-style internal links to product pages.
 */
add_action('woocommerce_before_single_product', function() {
    if (!is_product()) return;
    global $post;
    $terms = wp_get_post_terms($post->ID, 'product_cat', ['orderby' => 'parent', 'order' => 'ASC']);
    if (empty($terms) || is_wp_error($terms)) return;
    $primary = $terms[0];
    $shop_url = wc_get_page_permalink('shop');
    $cat_url  = get_term_link($primary);
    if (is_wp_error($cat_url)) return;
    echo '<nav class="seo-breadcrumb" style="font-size:0.85em;margin:0 0 15px;color:#666;">';
    echo '<a href="' . esc_url($shop_url) . '">Shop</a>';
    echo ' &rsaquo; ';
    echo '<a href="' . esc_url($cat_url) . '">' . esc_html($primary->name) . '</a>';
    echo ' &rsaquo; ';
    echo '<span>' . esc_html($post->post_title) . '</span>';
    echo '</nav>';
}, 5);<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" href="https://exoticmorphs.com/wp-sitemap-index.xsl" ?>
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"><sitemap><loc>https://exoticmorphs.com/wp-sitemap-posts-post-1.xml</loc></sitemap><sitemap><loc>https://exoticmorphs.com/wp-sitemap-posts-page-1.xml</loc></sitemap><sitemap><loc>https://exoticmorphs.com/wp-sitemap-posts-product-1.xml</loc></sitemap><sitemap><loc>https://exoticmorphs.com/wp-sitemap-taxonomies-category-1.xml</loc></sitemap><sitemap><loc>https://exoticmorphs.com/wp-sitemap-taxonomies-product_cat-1.xml</loc></sitemap><sitemap><loc>https://exoticmorphs.com/wp-sitemap-taxonomies-product_tag-1.xml</loc></sitemap><sitemap><loc>https://exoticmorphs.com/wp-sitemap-users-1.xml</loc></sitemap></sitemapindex>
