Read more not working on pages displayed on home page
-
Hi,
Sorry about the long title, but i am unsure how else to describe this.
The problem that I am having is that I have a page that has a small paragraph with a <!–more–> tag after the first sentence.
I am trying to get only the first sentence to display before the more tag on the home page. with possibly a click through so that the user can view the page that the sentence is from.
I have got to the point with the code that it will display the title and the post on the home page but this read more problem has stumped me for about a month.
<h2 class="entry-title"> <a href="https://www.phillipvale.com/?page_id=2"> <?php $page_id = 2; $page_data = get_page( $page_id ); $title = $page_data->post_title; echo $page_data->post_title; ?> </a> </h2> <?php $page_id = 2; $page_data = get_page( $page_id ); $the_content = $page_data->post_content; echo $page_data->post_content; ?>
Any help is much appreciated!
Thank you!
Viewing 6 replies - 1 through 6 (of 6 total)
Viewing 6 replies - 1 through 6 (of 6 total)
- The topic ‘Read more not working on pages displayed on home page’ is closed to new replies.