大家好,希望你们一切都好。我正在为我的 wordpress 网站上构建的滑块寻找一些帮助。我似乎无法弄清楚如何显示滑块中显示的每个帖子的类别并将其突出显示。有谁知道我怎么能做到这一点?我当前的代码如下
<div id="slides">
<?php if (function_exists('yg_randomposts')) {
$parameters = array(
'limit' => 10, //Number of posts to show
//'excerpt' => 60, //excerpt length (letters)
'actcat' => true, //get posts current
'cusfield' => 'post-image', //custom field name of thumbnail image
'w' => 250, //width
'h' => 250, //height
'firstimage' => true, //get first image of post content
'atimage' => true, //get first attached image of post
'defimage' => 'http://watchthefeed.com/wp-content/uploads/2012/04/random-post-default.jpg' //default thumbnail image
);
//print random posts
yg_randomposts($parameters);
} ?>
</div><!--slider container-->