title: How to get 2 post_type work with each other
body: <p>How do i get the permalink from cubeportofolio, and the title/thumbnail from posts? With the post_type syntax from wordpress.
  here is my code:</p>
  
  <pre><code>&lt;?php 
  
  $posts = get_posts(array(
  'posts_per_page'   =&gt; 1,
  'post_type'            =&gt; 'cubeportfolio' ));
  
  if( $posts  ): ?&gt;
  &lt;?php foreach( $posts as $post ): setup_postdata( $post ) ?&gt;
      &lt;li&gt;
        &lt;a href="&lt;?php the_permalink(); ?&gt;"&gt;
  </code></pre>
  
  <p>until here the code is oke.
  So i am getting the good permalink but my title is wrong, i havent even tried to get the thumbnail.</p>
  
  <pre><code>&lt;?php
  $args = array(
  'post_type'=&gt; 'post',
  'order'    =&gt; 'date'
  );              
  
  echo get_the_title($recent)."&lt;br/&gt;";   
  wp_reset_postdata();                                
  ?&gt;                                      
  
  
  &lt;/a&gt;
  &lt;/li&gt;
  
          &lt;?php endforeach; ?&gt;
          &lt;/ul&gt;
  
      &lt;?php wp_reset_postdata(); ?&gt;
  
  &lt;?php endif; ?&gt;
  </code></pre>
  
  <p>I have read some things in the documentation but i still cant figure it out.
  i want an ul so people can click through the posts but the problem is, i am making my blogs in an plugin. thats the wrong title and thumbnail, So i want the permalink of cubeportfolio(this is an post_type). and I want the title from posts(this is an post_type)</p>
  
  <p>Hole code:</p>
  
  <pre><code>$posts = get_posts(array(
  'post_type'         =&gt; 'cubeportfolio',
  'order'    =&gt; 'date' ));
  
  if( $posts  ): ?&gt;
  &lt;?php foreach( $posts as $post ): setup_postdata( $post ) ?&gt;
  &lt;li&gt;
  &lt;a href="&lt;?php the_permalink(); ?&gt;"&gt;
  
  &lt;?php wp_reset_postdata(); ?&gt;
  
  &lt;?php
  $args = array(
  'post_type'=&gt; 'post',
  'order'    =&gt; 'date'
  );              
  
  
  
  
  
   echo get_the_title($recent)."&lt;br/&gt;";   
  
  
   wp_reset_postdata();                               
   ?&gt;                                     
  
  
   &lt;/a&gt;
   &lt;/li&gt;
  
   &lt;?php endforeach; ?&gt;
   &lt;/ul&gt;
  
   &lt;?php wp_reset_postdata(); ?&gt;
  
   &lt;?php endif; ?&gt;
  </code></pre>
  
  <p>Any help would be appreciated,</p>