function _menu_example_menu_page in Examples for Developers 7
Same name and namespace in other branches
- 6 menu_example/menu_example.module \_menu_example_menu_page()
Page callback for use with most of the menu entries.
The arguments it receives determine what it outputs.
Parameters
string $content: The base content to output.
string $arg1: First additional argument from the path used to access the menu
string $arg2: Second additional argument.
Related topics
1 string reference to '_menu_example_menu_page'
- menu_example_menu in menu_example/
menu_example.module - Implements hook_menu().
File
- menu_example/
menu_example.module, line 344 - Module file for menu_example.
Code
function _menu_example_menu_page($content = NULL, $arg1 = NULL, $arg2 = NULL) {
$output = '<div>' . $content . '</div>';
if (!empty($arg1)) {
$output .= '<div>' . t('Argument 1=%arg', array(
'%arg' => $arg1,
)) . '</div>';
}
if (!empty($arg2)) {
$output .= '<div>' . t('Argument 2=%arg', array(
'%arg' => $arg2,
)) . '</div>';
}
return $output;
}