Is the limitation to views with fields artificial with Views 2?
robertDouglass - February 4, 2009 - 15:43
| Project: | Custom Pagers |
| Version: | 6.x-1.x-dev |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Jump to:
Description
This code determines which views can be used for pagers:
<?php
$all_views = views_get_all_views();
foreach ($all_views as $view) {
// Only views that have fields will work for our purpose.
if (!empty($view->display['default']->display_options['fields']) && $view->base_table == 'node') {
$options[$view->name] = $view->name;
}
}
?>Is this an artificial limitation for Views 2? Do views really need fields to be viable for pagers?

#1
Uh, I also bumped into this.
So I cannot user custom pagers on views that just show teasers or full nodes?
#2
There is a quick and easy workaround for this. Create your view as a fields view, set up your custom pagers, THEN switch your view back to node. Voila! The custom pagers still show up.
#3
subscribing