Count lines in Drupal views plugin
I wrote myself a Drupal Views plugin and want to count the lines so I can do something with the output of every Nth line.
I can do this in the plugin preprocessor function, but if it is used more than once (for example in panels) I cannot reset the counter to zero.
Can anyone point me in the right direction here?
+2
a source to share
2 answers
You can take a look at the views_customfield module. ( http://drupal.org/project/views_customfield ) This module gives access to the line number in the view, as well as the ability to add PHP code to each line. Quite convenient ...
0
a source to share