How to create dynamic bootstrap carousel bullets in wordpress
$number = 0;
$args = array( 'posts_per_page' => -1, 'post_type'=> 'posttype', 'orderby' => 'menu_order', 'order' => 'ASC' );
$myposts = get_posts( $args );
foreach( $myposts as $post ) : setup_postdata($post); ?>
<li data-target="#myCarousel" data-slide-to="<?php echo $number++; ?>"></li>
<?php endforeach; ?>
If you need more help don’t delay to ask me. I am here ready to give easy guideline. Just comment or send message me. I will beck you asap. Message Now .
Don’t forget to bookmark and share this code with others new learner like you.