Hans schrieb: > Thursday, January 31, 2008, 6:14:20 PM, noskule wrote: > >> I would like show 10 blogposts on a page and have a link at the bottom >> of the page that shows me the next 10 posts. > >> To show 10 posts is not the problem but to do the link i can't figure >> out how to do. > > Is each post a separate page, or are they all on one page? > > http://www.pmwiki.org/wiki/Cookbook/BreakPage is a nice recipe to show > a page in sections, with links to the other sections. > > I modified this for FoxForum, and added in foxforum.php a version > which works for the forum type where each post is a separate page. > > But you may try a simpler solution which employs a markup expression > to calculate the next post (bunch). > You use a var for your post count, and MarkupExprPlus for the math > http://www.pmwiki.org/wiki/Cookbook/MarkupExprPlus > You can use markup expressions in links and in pagelist etc. > > > ~Hans >
oky, I got a simple solution so far see: http://netstreams.org/test/cms/index.php/Blog/HomePage explanation: Link to erlier posts: [[{*$FullName}?plcount={(math {$plcount}+1)}|$[Earlier Posts]]] Link to recent posts: [[{*$FullName}?plcount={(math {$plcount}-1)}|$[Recent Posts]]] pagelist (:pagelist count={(math '( ( {$plcount}+0) * 5 ) + 1' )}..{(math '( ({$plcount}+0) * 5 ) + 5' )}:) the only problem is, that I don't no how to find out if it still needs a "Earlier Posts" link. To get that to work I have to find out how many pages does pagelist find. with the pagelist arg "fmt=count" i get the number but only as text in the page. Is there a way to get this value as variable? grz nos ------------------------------------------------------------ %center%[[{*$FullName}?plcount={(math {$plcount}+1)}|$[Earlier Posts]]] {(math '( ({$plcount}+0) * 5 ) + 5' )}...{(math '( ( {$plcount}+0) * 5 ) + 1' )} (:if expr ! equal {$plcount} '' && ! equal {$plcount} '0':)[[{*$FullName}?plcount={(math {$plcount}-1)}|$[Recent Posts]]] (:ifend:) (:if expr ! equal {$plcount} '' && ! equal {$plcount} '0':) (:pagelist group={*$Group} $:pagetype=Blog $:Livecycle=1-Publish fmt=#Teasers count={(math '( ( {$plcount}+0) * 5 ) + 1' )}..{(math '( ({$plcount}+0) * 5 ) + 5' )} order=-ctime:) (:else:) (:pagelist group={*$Group} $:pagetype=Blog $:Livecycle=1-Publish fmt=#Teasers count=0..5 order=-ctime:) (:ifend:) --------------------------------------------------------------- _______________________________________________ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users