title: Wordpress: create loop in widget api for defined post id
body: <p>Using <a href="http://codex.wordpress.org/Widgets_API" rel="nofollow">WP_Widget class</a>, I coded html layout to output single post meta(title, thumb, url, author avatar and name.</p>
  
  <p>Now I need to output meta strings in PHP defined by post ID:</p>
  
  <pre><code>public function widget( $args, $instance ) {
    // outputs the content of the widget
    echo __( '
        &lt;h4&gt;&lt;a href="the_permalink"&gt;the_title&lt;/a&gt;&lt;/h4&gt;
        &lt;img src="the_thumbnail"&gt;
        &lt;div&gt;the_category&lt;/div&gt;
        .....
        ', 'text_domain' );
  }
  </code></pre>
  
  <p>and if possible to define the post id as outputs the options form on admin:</p>
  
  <pre><code>public function form( $instance ) {
      // outputs the options form on admin
  }
  </code></pre>