Working with a taxonomy termpath (hierarchy) the replacement pattern in Entity Path gives a different result than pathauto.

The correct way to do this in Drupal 7 is:
[term:vocabulary]/[term:parents:join-path]/[term:name]

If we have a deep taxonomy this works:

Pathauto: my_voc/sublevel/term
Entity path: my_voc/sublevel/term

But if the term is att root level:

Pathauto: my_voc/term
Entity path: my_voc//term

In fact the Entity path version is in fact literal from the pattern - but its not the wanted result.

There should not be any double-slashes, or it should be optional.

(Drupal 7.22)

Comments

derhasi’s picture

Category: bug » feature

Yes, we should make that behavior configurable.

criznach’s picture

Status: Active » Needs review
StatusFileSize
new1.33 KB

I've created a patch that adds a setting to optionally fix double slashes. The default behavior is unchanged. In my case, it's working for a parent path pattern:

where-we-work/[term:parents:join-path]/[term:name]