title: wordpress get post thumbnail outside wordpress
body: <p>This is my link.php script for show latest title and tumbnail from my wordpress site. Title working fine thumbnail not work. it only show mysite/wp-includes/images/media/default.png, But my content have uloaded image. How can i get thumbnail image</p>
  
  <pre><code> &lt;?php
   require('../../wp-blog-header.php');
   ?&gt;
  
   &lt;?php
    $posts = get_posts('numberposts=10&amp;order=ASC&amp;orderby=post_title');
   foreach ($posts as $post) : setup_postdata( $post ); ?&gt;
       &lt;?php get_the_ID(); echo "&lt;br /&gt;"; ?&gt;
     &lt;?php the_title(); ?&gt;    &lt;?php echo "&lt;br /&gt;"; ?&gt;
  
  &lt;?php
     $imgId = get_post_thumbnail_id($post-&gt;ID);
     $imgUrl = wp_get_attachment_image_src($imgId,'thumbnail', true);
   ?&gt;
     &lt;a href="&lt;?php the_permalink(); ?&gt;"&gt;&lt;img src="&lt;?php echo  $imgUrl[0];  ?&gt;" /&gt;&lt;/a&gt;
   &lt;?php
   endforeach;
   ?&gt;
  </code></pre>