Support » Plugin: WP Bootstrap Tabs » Advanced custom fields inside tab content?

  • Hi Folks,

    I’m trying to bring up content through my advanced custom fields inside of the content in a tab. Is it possible?

    This is the code that I would like to get working:

    <?php
    		$the_query = new WP_Query(array(
    			'post_type' => 'portfolioitems',
    			'posts_per_page' => -1
    			));
    
    		while ($the_query->have_posts()) :
    			$the_query->the_post();
    		endwhile;
    	?>
    
    	<div class="portfolio-item">
    
    		<div class="portfolio-image">
    
    			<?php the_field('portfolio_website_image'); ?>
    
    		</div>
    
    		<div class="portfolio-description">
    
    			<h2><?php the_field('portfolio_website_name'); ?></h2>
    
    			<p><?php the_field('portfolio_website_description'); ?></p>
    
    			<span><?php the_field('portfolio_website_hyperlink'); ?></span>
    
    		</div>
    
    	</div>

    I’ve tried to modify wp-bootstrap-tab.php and I added the code between:

    <p>[bootstrap_tab name="Tab 2" link="tab2-slug" ]</p>
    my code here
    <p>[/bootstrap_tab]</p>

    but without success. So where should I put it?

    https://wordpress.org/plugins/wp-bootstrap-tabs/

  • The topic ‘Advanced custom fields inside tab content?’ is closed to new replies.