3

I have a dual language site (English and Arabic). In the English version I added a URL alias: projects/commercial.

But I can't find a way to have that translated to the Arabic version. I need that because the path is used by a breadcrumb module.

Any suggestions?

Edit: I am using pathauto, but my problem is that the URL is for a view that lists certain projects based on contextual filters. So I added the alias projects/commercial instead of projects/7 the breadcrumb works fine in English but not in Arabic

2

For URLs related to nodes, users or taxonomies

Consider using the Pathauto i18n module for this. Excerpt from its project page:

... by default Pathauto creates alias only for one language or for all languages one alias. This module provides functionality to create aliases for each language. Also this module will be helpful, if you use field translation and you want show node on all language with paths, different from node/nid.

This module contains 3 submodules which can be used to enable separate functionality for each entity:

  • pathauto_i18n_node (for nodes).
  • pathauto_i18n_user (for users).
  • pathauto_i18n_taxonomy (for taxonomy).

Example (also from project page):

When you create node without pathauto_i18n:

  • English alias: en/articles/first_article
  • Italiano alias: not exist
  • Deutsche alias: not exist

When you create node with pathauto_i18n:

  • English alias: en/articles/first_article
  • Italiano alias: it/articolo/first_article
  • Deutsche alias: de/artikel/first_article

For URLs related to views or panels

Use the i18n_path (Path Translation) sub-module of the i18n module. Refer to its Community documentation for more details about it.

1

Maybe the Path Translation module could help? Excerpt from its community documentation:

The Path translation module, part of the Internationalization (i18n) package, allows you to map together existing pages that are translations of each other. This will allow users to use the language switcher to navigate between the associated pages.

The module is meant to be used as a last resort to translate paths that can't otherwise be mapped together as translations. For example, paths to translated nodes can already be linked with the Content translation module and paths to translated taxonomy terms can be linked with the Taxonomy translation module. Path translations should be used to link generic paths, such as those provided by Views or Panels.

0

If you are using pathauto module, this could be easily taken care of.
In my site, I have two languages : English and Spanish Enabled. Pathauto is configured to use the path content:[node:title].
I created a node in English with title "Transliteration", the URL to the page was : http://mysite/content/transliteration.
I then went ahead and translated the content to Spanish. The path to the node became : http://mysite/es/content/transcripción.
So, pathauto will honour the changes, if you use the translated node title as a token.

There are other ways to translate breadcrumbs in any site. I prefer using Path Breadcrumbs module. It has a Path Breadcrumbs Translation sub module which helps in translating breadcrumbs.

  • i am using pathauto but my problem is that the url is for a view that lists certain projects based on contextual filters. So I added the alias projects/commercial instead of projects/7 the breadcrumb works fine in english but not in arabic Any further help is highly appreciated Many thanks – redamakarem Apr 21 '14 at 12:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.