Skip to content

Instantly share code, notes, and snippets.

@evolvingweb
Created March 29, 2012 23:42
Show Gist options
  • Save evolvingweb/2244986 to your computer and use it in GitHub Desktop.
Save evolvingweb/2244986 to your computer and use it in GitHub Desktop.
mymodule_node_list()
<?php
function mymodule_node_list() {
  $items = array(
    array('Suzanne'),
    array('Alex'),
    array('Tavish'),
    array('Thomas'),
  );
  //asks Drupal to render this as a list
  return array(
    '#theme' => 'item_list',
    '#items' => $items,
    '#type' => ‘ul’,
  );
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment