Hello, I am using a script that adds the readmore link to the bottom of my posts after a certain amount of words. What I am trying to add is a line that would add the post title to the link after "Continue Reading" Here is what I have so far. global $post; $homepage_excerpts_more = ' ... <a href="'.get_permalink().'" class="more-link"><br/><br/>Continue Reading...</a>'; $output = $content; PHP: What I am trying to add in is this line and I can't get it to work right. I really only need the ".get_the_title" added to the line above but I don't know how to get it to work. <?php the_content("...continue reading the story called " . get_the_title('', '', false)); ?> PHP: Any help would be appreciated. Thanks for all your time
Thanks for your help, After playing around with it I got it to work using... $homepage_excerpts_more = ' ... <a href="'.get_permalink().'"class="more-link"><br/><br/>Continue Reading - '. get_the_title ('', '', false);'</a>'; PHP: Don't know if this is actually the correct way to do it, but it works. Thanks again for your help
Seems that get_the_title doesn't need a post ID after all. I think the correct way to write it is get_the_title ($post->ID); but get_the_title(); might also work then. Anyway, as long as it works!