Support » Plugins and Hacks » Hacks » Pulling custom meta into widget

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hi Keith,

    Using “PHP Code Widget” you can do this with such code:

    <?php
    if(is_single())
    {
      global $post;
      $post_link = get_post_meta($post->ID, 'soy_post_link', true);
    
      echo "<a href=\"$post_link\">Visit Source</a>";
    }
    ?>

    Let me know if you need something more.

    Thank you!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Pulling custom meta into widget’ is closed to new replies.