title: get the id of custom post type in single page
body: <p>I have a custom post type in my wordpress template named <strong>downloads</strong>.</p>
  
  <p>The problem is I can't get the id of post with this type in single page using these codes</p>
  
  <pre><code>global $post;
  echo $post-&gt;ID;
  </code></pre>
  
  <p>But I can get the id of posts with type page or post with that lines.</p>
  
  <p>How can i do that?</p>
  
  <p>Thank you</p>