On an clean multi-language installation, the language prefixes returned by Path Filter are not as expected. (See examples below.)

Drupal-6.8 installation, with the following modules activated:

  • Path (Core)
  • Locale (Core)
  • Content translation (Core)
  • Internationalization (Multilanguage)

And the following settings:

  • File system | Download method: Public.
  • Language negotiation: Path prefix with language fallback.
  • Multilingual system | Content selection mode: Mixed current language (if available) or default language (if not) and language neutral.
  • Default language: English (path prefix 'en')
  • Other language: Spanish (path prefix 'es')

If the administrator is using the English language, then Path Filter returns all paths prefixed with 'en', regardless of the page's language:

  • "internal:otherpage" in 'en/page' links to 'en/otherpage'.
  • "internal:otherpage" in 'es/page' links to 'en/otherpage' instead of 'es/otherpage'.

If the administrator switches to the Spanish language, and clears the cache, the reverse situation occurs: all paths get prefixed with 'es', now.

Using no prefix at all for the default language makes no real difference. the returned URLs still depend on the language the administrator is using, instead of the page's language.

Using 'Content selection mode: Current language and language neutral.' doesn't help either.

Comments

alexanderpas’s picture

Title: Path Filter conflicts with i18n Internationalization » [Push #3]: Path Filter conflicts with i18n Internationalization
Version: 6.x-1.0 » 6.x-1.x-dev
Priority: Normal » Critical
mrfelton’s picture

Status: Active » Fixed

I believe this is the same issue as the one I fixed at #408086: Use correct alias for translated nodes.. Please recheck with the latest CVS code.

jjalocha’s picture

I would like to test this, because I think this is an ugly bug. But I don't know how to "get" something from CVS. Maybe someone could guide me, or make the new package for me?

mrfelton’s picture

jjalocha’s picture

:)

The test scenario outlined in the first post works perfect now, with the following modules:

Drupal 6.12
i18n 6.x 1.0
pathfilter CVS

Thank you so much, Tom for fixing the code, pointing out the fix, and helping me out with CVS!

Cheers,
Jerzy

mrfelton’s picture

Excellent, I'm glad this issue is resolved - it was quite a serious one. Thanks for testing.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.