drupal_goto overlay page I'm using drupal_goto to redirect users on login.
Administrators and 'other' are redirected to the dashboard. All works fine but I want to redirect to the dashboard in an administrative overlay.
(Path = #overlay=nl/admin/dashboard)
Chrome and Firefox alter the # to %23 so I get a page not found error.

Can this be done?

Here is the function:

/**
 * Implements hook_user_login().
 */
function myModule_user_login(&amp;$edit, $account) {    
  $user_roles = array_intersect(array('other', 'administrator'), array_values($account-&gt;roles));
  if (!empty($user_roles)) {
    drupal_goto('admin/dashboard');
  } else {
    drupal_goto('');
  }
}
You need to pass a fragment to drupal_goto() as an option like so:

$options = array('fragment' =&gt; 'nl/admin/overlay');
drupal_goto('some-url', $options);


Reference for this can be found on the url() docs page (the docs page for drupal_goto() actually refers you to there as well).