Hi all!
Since I'm using Internationalization module (D6, v1.5), I've noticed that during the redirection AFTER the login, the lang prefix is being added once again.

After poking around with the code, I've found the solution:

On line 77, add

  global $language;

On line 83, add

     // Check for path prefix and strip it out if its found.
      $prefix = $language->language .'/';
      $path = str_replace($prefix, '', drupal_urlencode($_REQUEST['q']));

Finally, on the following line, change the routine to this:

    // using drupal_goto() with destination set causes a recursive redirect loop
    header('Location: '. url('user/login', array('query' => 'destination='. $path, 'absolute' => TRUE)), TRUE, 302);

And the problem is solved. It always redirects me to the correct language and page.
I hope I've helped.

Many thanks for this wonderful module!

Comments

deekayen’s picture

Status: Active » Fixed
deekayen’s picture

Status: Fixed » Closed (duplicate)