Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

Data Model Questions /

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba

Controlling pages in groups of certain size


Go to End
Reply


10 Posts   2846 Views

Avatar
Boogiez

Community Member, 17 Posts

7 February 2009 at 8:21am

Got it!

I modified function Grouping() to be this:

	function Grouping() { 
		return (($this->iteratorPos % 6 == 0) && ($this->iteratorPos != 0)); 
	}

and modified the relevant stuff in the template to be:

<div id="group1">
<% control MyChildren %>
	<% if Grouping %>
		</div>
		<div id="group{$GroupNum}">
	<% end_if %>
	<p>Child: $Title</p>
	<% if Last %>
		</div>
	<% end_if %>
<% end_control %>

Works like a charm! Thanks so much for your help. I'll post a link to the page you guys helped me make after its done!

Avatar
BLU42 Media

Community Member, 71 Posts

7 February 2009 at 9:47am

Nice work simplifying that a bit!

-John

Go to Top