0

We have a asp.net listview displaying news item on a page and it has paging functionality to load the next set of news which works fine.

A requirement now is to implement more modern Read more functionality. By default the 10 latest news items are displayed (publishing pages). At the bottom of the listview there should be, instead of paging, a Read more link. This link should keep the 10 latest news plus display 10 more. There are clunky ways of doing this with repeater, updatepanel etc. but what is the best way these days, jQuery and WCF?

I'm not looking at something where we load 10 items by default, click Read more and reload everything but use .Take(20), second time we click reload everything again with .Take(30) etc.

Any ideas?

2 Answers 2

0

I'd recommend that you do all of the formatting on the client and use the SharePoint REST api to get the data, then on ReadMore you can do $skip=x*10&$take=10.

To get started on the REST api see Using the REST Interface

0
0

For this, you can try to combine both jQuery and RespAPI or SharePoint ecmaScript to achive this.

Ex:) Using SharePoint ecmaScript get the latest items and show them in an element. If the user clicks the Read More link, call the same script method to append the items below the same element.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.