Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I've noticed this when working on #394560: DBTNG: Statistics module.
When there are multiple pagers, the following notice is displayed for each additional pager query, because it assumes that there will be a page argument for every of them.
Notice: Undefined offset: 1 in PagerDefault->execute() (line 69 of /home/berdir/workspace/drupal7/includes/pager.inc).
Comment | File | Size | Author |
---|---|---|---|
#1 | pager.notice_fix.patch | 843 bytes | Berdir |
Comments
Comment #1
BerdirThis also happens when a function that uses the Pager is called multiple time, this is done for example in do_search (With the patch I'm working on, see #394182: DBTNG search.module).
Attached is a small patch that fixes the notice. However, It doesn't address the real problem (That is that every call of a function results in a new pager)
Comment #2
Crell CreditAttribution: Crell commentedThe bot likes it and so do I.
Comment #3
Dries CreditAttribution: Dries commentedCommitted to CVS HEAD. Thanks!
Comment #5
hass CreditAttribution: hass commented#559482: Invalid parameter number (placeholders) with complex SQL statement in pager_query() could be a follow up.