ページにあるこの href はサイクル 2 スライダーに含まれているため、画像の下にキャプションが表示されます。ただし、クリックして新しいタブを開くと機能しません。右クリックしてから「...に移動」をクリックした場合にのみ機能します。誰かが理由を知っていますか?
wordpress のプラグイン: http://www.advancedcustomfields.com/
コード:
<a class="alt-caption" href="http://<?php the_field('url_site'); ?>"><?php the_field('url_site'); ?></a>
<div class="paginawrap no_overflow">
<div class="wraptest">
<div class="cycle-slideshow"
data-cycle-fx="carousel"
data-cycle-speed="500"
data-cycle-delay=5000
data-cycle-next=" > img"
data-cycle-caption=".alt-caption"
data-cycle-caption-template="{{alt}}"
data-cycle-carousel-fluid=true
data-allow-wrap=false
>
<?php $args = array(
'post_type' => 'project',
'posts_per_page' => 10
);
$query = new WP_Query( $args );
if ( $query->have_posts()) :
while ( $query->have_posts()) : $query->the_post();
the_post_thumbnail('home');
endwhile; wp_reset_postdata();
endif; ?>
<a href=" http://<?php the_field('url_site'); ?> "> <div class="alt-caption"></div></a>
</div>
<div class="archief1">
</div>
</div>
</div>