Returned content not displaying I have created a custom page which has a db query to return content, which is using the pagerdefault extender on a Drupal 7 install.

However when I return the content the pager shows but not the content.  This is the code after the query:

$content = array();
foreach ($result AS $events)
{
    $content[] = '&lt;div class=\'event\'&gt;' . $events-&gt;type . ' - ' . $events-&gt;nid . ' - ' . $events-&gt;tutorial_start . $events-&gt;event_start . '&lt;/div&gt;';
}
$build += $content;
$build['pager'] = array(
    '#theme' =&gt; 'pager',
    '#weight' =&gt; 1,
);
return $build;


I can see the $content rows if I dsm $build, but not display them on the page.  How do I render them on the page?
There are two things you should know to make it works:


Your query should extend PagerDefault.
Element inside content should be Rendered Array


here is a working example adjust the code to your needs:

//- Build array
  $build = array();
  /**
   * @TODO: adjust the query to your needs.
   */
  //- Prepare the Query to Extend PagerDefault
  $query = db_select('node', 'n')-&gt;extend('PagerDefault');
  $nids = $query
    -&gt;fields('n', array('nid'))
    -&gt;condition('type', 'page')
    -&gt;condition('status', 1)
    -&gt;execute()
    -&gt;fetchCol();
  if (!empty($nids)) {
    $nodes = node_load_multiple($nids);
    $content = array();
    foreach ($nodes as $event) {
      //- Prepare the content
      $content[] = array(
        '#type'   =&gt; 'markup',
        '#markup' =&gt; '&lt;div class="event"&gt;' . $event-&gt;type . ' - ' . $event-&gt;nid . '&lt;/div&gt;',
      );
    }
    //- Add Content to the build
    $build += $content;
    $build['pager'] = array(
      '#theme'  =&gt; 'pager',
      '#weight' =&gt; 5,
    );
  }
  return $build;