title: how to use URL of upload featured image in wordpress
body: <p>in wordpress I am creating a theme but I need a help,</p>
  
  <pre><code>&lt;? the_post_thumbnail();?&gt;
  </code></pre>
  
  <p>when I do that it gives me the entire <code>&lt;img src=#&gt;.....</code></p>
  
  <p>everything is fine so far but I want to do something like </p>
  
  <pre><code>&lt;a href="UPLOADEDIMAGEURL"&gt;&lt;? the_post_thumbnail();?&gt;&lt;/a&gt;
  </code></pre>
  
  <p>Hence,
  I need to take uploaded Image URL and wrap it with anchors then replace the uploaded image url how can I do that ?  I have tried some in jQuery but I think I can also do that from php also ?</p>
  
  <p>Here is the jQuery version (for that I couldnt take the img src attribute and replace to a href.)</p>
  
  <pre><code>$('.floatedImg').find('img').wrap( "&lt;a href='#' class='colorbox'&gt;&lt;/a&gt;" );
  </code></pre>
  
  <p>Solution 1 : can be handled via jQuery
  Solution 2 : can be via php</p>
  
  <p>Regards</p>