test_page_test.module 566 Bytes
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<?php

/**
 * Implements hook_menu().
 */
function test_page_test_menu() {
  $items['test-page'] = array(
    'title' => 'Test front page',
    'page callback' => 'test_page_test_page',
    'access callback' => TRUE,
    'type' => MENU_CALLBACK,
  );

  return $items;
}

/**
 * Page callback: Returns a test page and sets the title.
 *
 * @see test_page_test_menu()
 */
function test_page_test_page() {
23
  drupal_add_js(array('test-setting' => 'azAZ09();.,\\\/-_{}'), array('type' => 'setting'));
24
25
26
  drupal_set_title(t('Test page'));
  return t('Test page text.');
}