Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter bermaneyal

    (@bermaneyal)

    thanks,

    any idea how to pass a tab name?
    maybe i can use custom field to pass an array of string for tabs name?

    <div class="entry-content">
    						<?php// the_content(); ?>
    						<?php $multiparts_content_array = explode("<!--more-->", $post->post_content);
    						$i = 0;
    						?>
    						<div id="tabs">
    							<ul>
    						<?php
    						foreach ($multiparts_content_array as &$value) {
    							echo '<li><a href="#tabs-'.$i.'">name of tab</a></li>';
    						$i++;
    						}
    						?>
    							</ul>
    						<?php
    						$i = 0;
    						foreach ($multiparts_content_array as &$value) {
    							echo '<div id="tabs-'.$i.'">'.wpautop($value).'</div>';
    							$i++;
    						}
    						?>
    						</div>
    						<script>
    jQuery(function() {
    		jQuery( "#tabs" ).tabs();
    	});
    	</script>
    
    						<?php wp_link_pages( array( 'before' => '<div class="page-link">' . __( 'Pages:', 'amief' ), 'after' => '</div>' ) ); ?>
    					</div><!-- .entry-content -->
    Thread Starter bermaneyal

    (@bermaneyal)

    great, i tried the first way and it’s work,

    now just to implement some jquery and everything will work fine

    wordpress forever!

Viewing 2 replies - 1 through 2 (of 2 total)