SHARE
TWEET

Untitled

a guest May 19th, 2017 42 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function mymodule_menu() {
  2.   $items['page-example'] = array(
  3.     'title' => 'Page callback example',
  4.     'page callback' => 'my_page_callback',
  5.     'access arguments' => array('access content'),
  6.   );
  7.   return $items;
  8. }
  9.  
  10. function my_page_callback() {
  11.   return array(
  12.     '#theme' => 'html_tag',
  13.     '#tag' => 'div',
  14.     '#attributes' => array(),
  15.     '#value' => 'Hello world',
  16.   );
  17. }
RAW Paste Data
Top