Produce array of results from view that has a pager

by Kimberlie Davis   Last Updated June 12, 2019 06:07 AM - source

I am trying to get an array of all the view results in a views_hook_pre_render function. The problem I am running into is that the view has a pager (and needs a pager because it has thousands of results).

What I am trying is:

$views = views_get_view('out_of_stock_requests'); 
$views->query->limit = 0; 

But this only every produces the first page's results.

How can I access all of the results?

Thanks you,

Tags : views hooks

Related Questions

How to join custom table in views hook_views_data

Updated February 19, 2017 19:07 PM