function theming_example_page

Initial landing page explaining the use of the module.

We create a render array and specify the theme to be used through the use of #theme_wrappers. With all output, we aim to leave the content as a render array just as long as possible, so that other modules (or the theme) can alter it.

See also

render_example.module

form_example_elements.inc

Related topics

1 string reference to 'theming_example_page'
theming_example_menu in theming_example/theming_example.module
Implements hook_menu().

File

theming_example/theming_example.module, line 152

Code

function theming_example_page() {
    $content[]['#markup'] = t('Some examples of pages and forms that are run through theme functions.');
    $content[]['#markup'] = l(t('Simple page with a list'), 'examples/theming_example/theming_example_list_page');
    $content[]['#markup'] = l(t('Simple form 1'), 'examples/theming_example/theming_example_select_form');
    $content[]['#markup'] = l(t('Simple form 2'), 'examples/theming_example/theming_example_text_form');
    $content['#theme_wrappers'] = array(
        'theming_example_content_array',
    );
    return $content;
}