1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
 /* * * I double checked tab 2 and echo'd out the result and I see it is FALSE * * */

<?php echo get_post_meta($post->ID, 'tab_service', true); ?>


 /* * * This is the code you have me, I just added 2 more tabs and updated the names of the custom fields appropriately * * */
		
		<?php
		
		$result = '';
		
		$result .= '[tabs style="boxed"]';
		if ( get_post_meta( $post->ID, 'tab_contact', true ) ) {
		    $result .= '[tab title="1"][some content here][/tab]';
		}
		if ( get_post_meta( $post->ID, 'tab_service', true ) ) {
		    $result .= '[tab title="2"]' . get_the_excerpt() . '[/tab]';
		}
		if ( get_post_meta( $post->ID, 'tab_review', true ) ) {
		    $result .= '[tab title="3"]' . get_the_excerpt() . '[/tab]';
		}
		if ( get_post_meta( $post->ID, 'tab_jobs', true ) ) {
		    $result .= '[tab title="4"]' . get_the_excerpt() . '[/tab]';
		}
		$result .= '[/tabs]';
		
		echo do_shortcode( $result );
		
		?>