Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

get permalink by id wordpress

<?php
if(count($related)) {
    echo "<div>Read More<ul>";
    foreach($related as $id) {
        echo '<li><a href="'.get_permalink( $id ).'">'.get_the_title( $id ).'</a></li>';
    }
    echo "</ul></div>";
  }
?>
Source by wordpress.stackexchange.com #
 
PREVIOUS NEXT
Tagged: #permalink #id #wordpress
ADD COMMENT
Topic
Name
5+3 =