资源介绍给网站顶部添加一个动态的跑马灯效果,也是N年前的老特效了,不过还是蛮好看的。
WordPress&B2主题使用方法
方法一:将代码放入functions.php中:
function horseracelamp() { echo '<style>#top-grrk{background:url(https://i.ibb.co/ZWNJRZq/image.gif);height:2px;position:fixed;width:100%;Z-index:10000}</style><div id="top-grrk"></div>'; } add_action( 'wp_head', 'horseracelamp', 100 );
方法二:将代码入header.php中,不要放到head标签内,放在它下面即可。
<style> #header-pmd{ background:url(https://i.ibb.co/ZWNJRZq/image.gif); height:2px;//跑马灯高度 position:fixed; width:100%; Z-index:9999; } </style> <div id="header-pmd"></div>