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.
API page: http://api.drupal.org/api/views/views.api.php/function/hook_views_ajax_d...
Inside the foreach loop shown as an example for this function command
should be used as the a key and not method
, method is not a defined index of the $commands array.
For example
This:
foreach ($commands as $command) {
if ($command['method'] == 'viewsScrollTop') {
$command['method'] .= 'myScrollTop';
}
}
Should be:
foreach ($commands as $command) {
if ($command['command'] == 'viewsScrollTop') {
$command['command'] .= 'myScrollTop';
}
}
Isssue posted for drupal8 - https://drupal.org/node/1887892
Comment | File | Size | Author |
---|---|---|---|
#2 | incorrect-array-index-2211253-1.patch | 546 bytes | sandipmkhairnar |
Comments
Comment #1
sandipmkhairnar CreditAttribution: sandipmkhairnar commentedComment #2
sandipmkhairnar CreditAttribution: sandipmkhairnar commentedComment #3
sandipmkhairnar CreditAttribution: sandipmkhairnar commentedComment #4
amool CreditAttribution: amool commentedTested it. It works!
Comment #5
DamienMcKennaComment #6
DamienMcKennaComment #7
DamienMcKennaHow do we re-trigger the tests when they never finished the first time?
Comment #8
dawehnerThis doc fix looks perfect. Let's commit it.