Index: globalredirect.module =================================================================== RCS file: /cvs/drupal-contrib/contributions/modules/globalredirect/globalredirect.module,v retrieving revision 1.1.2.4.2.7 diff -r1.1.2.4.2.7 globalredirect.module 19,26c19,20 < if(isset($_REQUEST['q']) && function_exists('drupal_get_path_alias') && !isset($_REQUEST['destination'])) { < < // Get the Query String (minus the 'q'). If none set, set to NULL < $query_string = drupal_query_string_encode($_GET, array('q')); < if (empty($query_string)) { < $query_string = NULL; < } < --- > > if(isset($_REQUEST['q']) && function_exists('drupal_get_path_alias') && !isset($_REQUEST['destination'])) { 29c23,25 < drupal_goto('', $query_string, NULL, 301); --- > if (!in_array($_REQUEST['q'], array_keys(i18n_language_list()))) { > drupal_goto('', $query_string, NULL, 301); > } 31c27 < --- > 33a30,44 > > if(function_exists('i18n_get_normal_path')) { > $path = i18n_get_normal_path($request); > $alias = drupal_get_path_alias($path); > $reqalias = drupal_get_path_alias($request); > if($alias && $alias != $request) { > if (i18n_get_lang_prefix($request) && i18n_get_lang_prefix($request) != i18n_get_lang()) { > $alias = i18n_path($path,i18n_get_lang_prefix($request)); > drupal_goto($alias, $query_string, NULL, 301); > return; > } > drupal_goto($alias, $query_string, NULL, 301); > return; > } > } 35d45 < // Check the path (eg, node/123) for an request. 37,38d46 < < // If alias is different to the request, redirect... 40c48,49 < drupal_goto($alias, $query_string, NULL, 301); --- > drupal_goto($alias, $query_string, NULL, 301); > return; 42,43c51 < < // If the trimmed request differs to the request then redirect (basically, de-slash the source path) --- > 45a54 > return; 50,52c59,62 < drupal_goto($request, $query_string, NULL, 301); < } < } --- > drupal_goto($request, $query_string, NULL, 301); > return; > } > }