function menu_set_active_item

7.x menu.inc menu_set_active_item($path)
6.x menu.inc menu_set_active_item($path)

Set the active path, which determines which page is loaded.

Parameters

$path: A Drupal path - not a path alias.

Note that this may not have the desired effect unless invoked very early in the page load, such as during hook_boot, or unless you call menu_execute_active_handler() to generate your page output.

Related topics

3 calls to menu_set_active_item()
drupal_access_denied in drupal-6.x/includes/common.inc
Generates a 403 error if the request is not allowed.
drupal_not_found in drupal-6.x/includes/common.inc
Generates a 404 error if the request can not be handled.
user_page in drupal-6.x/modules/user/user.pages.inc
Access callback for path /user.

File

drupal-6.x/includes/menu.inc, line 1504
API for the Drupal menu system.

Code

function menu_set_active_item($path) {
  $_GET['q'] = $path;
}