1

How to add pager to the content created by the Field collection module?

I tried to achieve it with the Views module but Views takes the whole field collection content as single item, so it is not feasible.

I tried the Smart Paging module, but smart pager is for breaking one single content in many, so it is also not applicable.

3 Answers 3

1

After trial and error, I found the perfect solution to provide Paging to the content created by Field Collection module. This can be done by Views module.

You need to create the View of the your content which you have created using the field collection.

Important Part: In the Views setting as described in the following snapshot in the section of Multiple Field Setting, you need to uncheck the Display all the values in the same row. Because by default it is checked so Views considers your entire content in single row, so pager of views considers it as only one item. But if you uncheck, your each field set considered as single row and so Pager of the Views module will calculate accordingly. Hence unchecking this setting in Views and providing pager in the Views module will solve the issue.

Hope this will help others. enter image description here

0

Smart Paging

Provides splitting up long Drupal content into sub pages by number of characters/words or by a placeholder HTML tag for node, user and taxonomy term entities.

OR

you can do it using view adding contextual filter after put view field in your field collection field using views field module

2
  • Please, can you elaborate the second option? The first option may work in the long text I guess.
    – CodeNext
    Sep 28, 2015 at 11:29
  • you add node id contextual filter then go php code section write code as your requirement then return it back to node id Sep 28, 2015 at 12:53
0

Pagination might be an alternative way to do this. It allows for paging based on

Method 1: Content is paginated by a selectable "words per page" count.

Method 2: Content is paginated by manual breaks, inserted by the content creator.

Method 3: Content is paginated by manual breaks, based on tags.

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.