WordPress.org

Support

Support » How-To and Troubleshooting » Display related custom post type by title…

Display related custom post type by title…

  • how can i display the related trailers… if i have for example 5 trailers Prometeus, clips, promo..etc..

    Ex: http://www.diviziatm.ro/2.jpg

    I use:

    <div class="box-trailere">
    <div class="trailer-img">
    <a href="<?php the_permalink() ?>" rel="bookmark" title="<?php printf(__('Trailer film %s', 'kubrick'), the_title_attribute('echo=0')); ?>">
    <span class="tip"><?php $key="tip"; echo get_post_meta($post->ID, $key, true); ?></span><span class="tip_trailer"><?php $key="tip_trailer"; echo get_post_meta($post->ID, $key, true); ?></span>
    <img src="http://img.youtube.com/vi/<?php $key="trailer"; echo get_post_meta($post->ID, $key, true); ?>/<?php $key="img_trailer"; echo get_post_meta($post->ID, $key, true); ?>"></a>
    <span class="duration"><?php $key="time"; echo get_post_meta($post->ID, $key, true); ?></span>
    </div>
    <span class="trailer-title"><a href="<?php the_permalink() ?>" rel="bookmark" title="<?php printf(__('Trailer film %s', 'kubrick'), the_title_attribute('echo=0')); ?>">
    <?php the_title(); ?>
    </a></span>
    </div>

  • The topic ‘Display related custom post type by title…’ is closed to new replies.
Skip to toolbar