Is it possible to paginate posts that are too long?
Lets say I have a post that is really long and would like to split it in 3 or 4 pages (I know they are not pages) is it possible using certain tags like <nextpage> and what is the best method?
Paginating posts...is this possible
9 posts from 4 voices-
Posted 1 year ago #
-
perhaps this is something for you?
Posted 1 year ago # -
Hi!
You need to include the wp_link_pages function in includes/loop-page.php - replace:
</div><!--end post-entry-->with:
<?php wp_link_pages('before=<div id="page-links">Pages:&after=</div>'); ?> </div><!--end post-entry-->Best regards,
PeterPosted 1 year ago # -
Hi,
I haven't found any loop-page.php file within the NEWSCAST theme files!
NEWSCAST don't have these files like CORONA, for example.So where can I add this in the NEWSCAST files please?
I also would like to paginate my posts, but when adding
<!--nextpage-->within the text, it cuts the text, yes, but no pagination is shown.Thanks.
Posted 1 year ago # -
Hi,
I think what you are looking for can be found in: wp-content\themes\newscast\index.php, and find this line of code:
kriesi_pagination($additional_loop->max_num_pages);
That line of code should do the trick, it's really weird that it's not working on your end. Try commenting those lines out, then try your pagination code.Regards,
IsmaelPosted 1 year ago # -
thanks, Ismael,
I don't mean the pagination on the frontpage, below all the posts.
I mean how to show a pagination, if I separate one post or page in several parts ("pages").
I found the pagination.php in the "framework" -> "helper_functions" folders:
and here this part of code:
if(1 != $pages){
echo "<div class='pagination'>";
echo ($paged > 2 && $paged > $range+1 && $showitems < $pages)? "«":"";
echo ($paged > 1 && $showitems < $pages)? "‹":"";for ($i=1; $i <= $pages; $i++){
if (1 != $pages &&( !($i >= $paged+$range+1 || $i <= $paged-$range-1) || $pages <= $showitems )){
echo ($paged == $i)? "<span class='current'>".$i."</span>":"".$i."";
}
}echo ($paged < $pages && $showitems < $pages) ? "›" :"";
echo ($paged < $pages-1 && $paged+$range-1 < $pages && $showitems < $pages) ? "»":"";
echo "</div>\n";
}
}
But when I add
<!--nextpage-->in the middle of a post or a page, neither the post nor pages show a pagination, so that we can go to the second part of the splitted post or page!Posted 1 year ago # -
sorry, delete my posts please, I was in the wrong forum, very sorry!
Posted 1 year ago # -
Hi colorit2,
No worries, I have found your post. :)
Regards,
IsmaelPosted 1 year ago #
Reply
You must log in to post.














