Im new to umbraco and i wan to make a list with news ..showing only 10 per page
how can i do this..and i dont want to retrieve all the records from database and do the paging with xslt..is there any way to retrieve only 10 records per page?
You can use the postion() value to determine nodes to show
pass in first and last positions.
Not sure if this will solve your issue, but should give you and idea to start from. It's late and there might be a better solution if thought on more...
<xsl:variable name="first" select="number(/macro/firstPosition) - 1/> <!-- send in 1 -->
<xsl:variable name="last" select="number(/macro/lastPosition) + 1"/> <!-- send in 10 -->
<xsl:foreach select="$currentPage/ancestor-or-self/NewsItem [position() > $first and position() < $last]">
<!-- show news item info -->
</xsl:foreach>
Document type and paging
Im new to umbraco and i wan to make a list with news ..showing only 10 per page
how can i do this..and i dont want to retrieve all the records from database and do the paging with xslt..is there any way to retrieve only 10 records per page?
thanx
You can use the postion() value to determine nodes to show
pass in first and last positions.
Not sure if this will solve your issue, but should give you and idea to start from.
It's late and there might be a better solution if thought on more...
is working on a reply...