Page 1 of 1

News pagination in ver 1.1rc2

Posted: Sat Jun 09, 2007 6:33 pm
by kevin360
So I saw in the wiki that v1.1 of CMSMS has News pagination by default:

http://wiki.cmsmadesimple.org/index.php ... fined_Tags

I installed 1.1rc2 but I haven't been able to figure out how to get pagination turned on.  Pagination works in the admin section, but for the frontend I'm not sure how to turn it on.  I've tried both:

{news category="Editors Note" number="5"}

and

{news category="Editors Note" pagelimit="5"}

I've also looked in the help for the News module and I haven't seen anything in there about pagination either.  Am I just missing something?  Or is pagination only in the admin section right now?

Thanks!
Kevin

Re: News pagination in ver 1.1rc2

Posted: Sun Jun 10, 2007 12:07 am
by calguy1000
if this was an upgrade from an existing install, then you'll have to create a new summary template, yuo should see the smarty tags in the template for the pagination stuff.  Then it should 'just work'.

The pagination will not just automatically work for upgraded styles (I didn't want to mess with any existing templates).

Re: News pagination in ver 1.1rc2

Posted: Sun Jun 10, 2007 3:34 pm
by kevin360
I think my template has that in there, here's the template:


{if $pagecount > 1}
 
{if $pagenumber > 1}
{$firstpage} {$prevpage} 
{/if}
{$pagetext} {$pagenumber} {$oftext} {$pagecount}
{if $pagenumber
{/if}
{foreach from=$items item=entry}


{if $entry->formatpostdate}

{$entry->formatpostdate}

{/if}


{$entry->titlelink}



{$category_label} {$entry->category}


{if $entry->author}

{$author_label} {$entry->author}

{/if}

{if $entry->summary}

{eval var=$entry->summary}



[{$entry->morelink}]


{else if $entry->content}


{eval var=$entry->content}

{/if}


{/foreach}


Is this the correct one?  Still now paging info shows up and there's almost 100 articles put in the news.  I've tried the pagelimit parameter but that seems to do the same thing as the number parameter.

Re: News pagination in ver 1.1rc2

Posted: Sun Jun 10, 2007 11:15 pm
by kevin360
Alright, figured out what was wrong so I'll post it here incase anyone else runs into the same thing.

When you go into the News module and click on the 'Summary Template' tab I thought it was showing me the current default template that was being used, but it's not.  To see the actual default template you have to click on it at the bottom, which if you are upgrading from an older version will probably be different.