最近、wordpress 用の Dynamic Featured Image プラグインをインストールしました。しかし、私は画像をリンクする方法がわかりません。このhttp://www.subcreative.com.au/#workのようなギャラリーを作成しようとしています- プロジェクトまでスクロールすると、 が表示されます。
このコードを functions.php に入れました
<?php
while ( have_posts() ) : the_post();
if( function_exists('dfi_get_featured_images') ) {
$featuredImages = dfi_get_featured_images();
//Now, loop through the image to display
}
endwhile;
?>
これを使用して画像をリンクしました。
echo ' <a class="fancybox" href="'. dfi_get_featured_images() .'" style="text-align:center">Take a look</a> '; ?>
しかし、画像を開こうとすると、「/array」になります