WordPress.org

Forums

Posts 2 Posts
[resolved] Not displaying post connection (2 posts)

  1. salocined
    Member
    Posted 4 years ago #

    Help on this one,
    The connection exist but no data is displayed.
    I am using a similar code down the page and the data displays fine.
    I have changed the variable $the_query without results.

    <?
    global $post;
      $the_query = new WP_Query( array(
      'suppress_filters' => false,
      'post_type' => 'photographer',
      'type' => 'take-photo',
       'showposts' => 1,
       'connected' => $post->ID) );
    
       if($the_query->have_posts()) :
        while ($the_query->have_posts()) : $the_query->the_post();
    ?>
         <a href="<?php get_permalink($post->ID);?>"><?php $post->post_title;?></a> 
                      <?php  endwhile; ?>
    <? endif;?>
  2. salocined
    Member
    Posted 4 years ago #

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Posts 2 Posts
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic