2013-09-24 52 views
0

我想在帖子頁面中顯示與該特定帖子的超鏈接。我知道這是來自get_the_excerpt()。如何在get_the_excerpt()中作爲超鏈接

這是如何實現的?提前致謝。

+0

http://wordpress.stackexchange.com/questions/27933/display-links-in-excerpts 檢查,這可能幫助你 –

回答

1

複製此功能在您的functions.php

function new_excerpt_more($more) { 
     global $post; 
    return '<span class="readmore"><a class="moretag" href="'. get_permalink($post->ID) . '"> Read more..</a></span>'; 
} 
add_filter('excerpt_more', 'new_excerpt_more'); 
+0

非常感謝JANAK。它工作完美。 – Jenz