sakura/user/page-bangumi.php
LinGe 74d7f2adbe 给每个图片单独设置 referrerPolicy
page-bangumi.php中设置了全局referrer规则:不发送referer。如果开启了PJAX局部刷新,从追番页面去到其它页面该规则也会被保留,这会导致后面的请求也不发送referer。如果有资源比如CDN禁止空referer请求,那么这部分资源就会无法访问。
2022-06-21 20:02:20 +08:00

37 lines
956 B
PHP

<?php
/**
Template Name: Bangumi
*/
get_header();
?>
<style>
#content,.comments,.site-footer{max-width:1200px;}
.comments{display: none}
</style>
</head>
<?php while(have_posts()) : the_post(); ?>
<?php if(akina_option('patternimg') || !get_post_thumbnail_id(get_the_ID())) { ?>
<span class="linkss-title"><?php the_title();?></span>
<?php } ?>
<article <?php post_class("post-item"); ?>>
<?php the_content(); ?>
<section class="bangumi">
<?php if (akina_option('bilibili_id') ):?>
<div class="row">
<?php
$bgm = new \Sakura\API\Bilibili();
echo $bgm->get_bgm_items();
?>
<?php else: ?>
<div class="row">
<p> <?php _e("Please fill in the Bilibili UID in Sakura Options.","sakura"); ?></p>
</div>
<?php endif; ?>
</section>
</article>
<?php endwhile; ?>
<?php
get_footer();